/* ====== penerbit.css (VERSI FINAL: FIX WhatsApp & Header Mobile) ====== */

:root {
  --accent-color: #8d5e3c;
  --default-color: #2b2b2b;
  --light-bg: #f9f6f3;
  --heading-font: 'Merriweather', serif;
  --body-font: 'Poppins', sans-serif;
}

body {
  font-family: var(--body-font);
  color: var(--default-color);
  margin: 0;
  padding: 0;
  background-color: white;
}

.container {
  max-width: 1080px;
  margin: auto;
  padding: 1rem;
}

/* === HEADER === */
.header {
  background-color: #fdfbf8;
  border-bottom: 1px solid #ccc;
  padding: 10px 0;
  font-family: 'Georgia', serif;
}

.full-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.header-left {
  font-size: 1.5rem;
  font-weight: bold;
  color: #8c5b33;
  white-space: nowrap;
}

.header-logo {
  max-height: 70px;
  height: auto;
  width: auto;
  display: block;
}

.header-right ul {
  list-style: none;
  display: flex;
  gap: 20px;
  margin: 0;
  padding: 0;
}

.header-right a {
  text-decoration: none;
  color: var(--default-color);
  font-weight: 500;
}

/* -------------------------------------------------------------------------- */
/* === BANNER SLIDER (Proporsional Penuh) === */
.banner-slider {
  position: relative;
  overflow: hidden;
  height: 0;
  padding-bottom: 39.84%;
  background-color: #eee;
}

.slider {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  z-index: 1;
}

.slide.active {
  opacity: 1;
  z-index: 2;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
/* -------------------------------------------------------------------------- */

/* === INTRO TEXT === */
.intro {
  text-align: center;
  padding: 1rem 1rem 0.2rem;
  margin-bottom: 0rem;
}

.intro h1 {
  font-size: 2.4rem;
  font-family: var(--heading-font);
  color: var(--accent-color);
  margin-bottom: 0.2rem;
}

.intro p {
  font-size: 1.05rem;
  margin-top: 0;
}

/* === KATALOG BUKU === */
.section-title {
  text-align: center;
  margin-bottom: 1rem;
  font-size: 1.6rem;
  font-family: var(--heading-font);
  color: var(--accent-color);
  margin-top: 0;
}

.books {
  margin-top: 0.2rem;
}

.books .book-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  align-items: stretch;
}

.book-card {
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  overflow: hidden;
  width: 280px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  height: auto;
}

.book-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.book-card img {
  width: 100%;
  aspect-ratio: 3 / 4.2;
  object-fit: cover;
  display: block;
  flex-shrink: 0;
}

.book-info {
  padding: 1rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.book-info h3 {
  margin-top: 0.5rem;
  font-family: var(--heading-font);
  font-size: 1.2rem;
}

.book-info .category {
  font-size: 0.85rem;
  color: #888;
  text-transform: uppercase;
}

.btn-details {
  display: inline-block;
  margin-top: auto;
  color: var(--accent-color);
  text-decoration: none;
  font-weight: 600;
}

/* -------------------------------------------------------------------------- */
/* === KONTAK (FIX Ikon WhatsApp) === */
.contact {
  padding: 3rem 1rem;
  background-color: var(--light-bg);
  text-align: center;
}

.contact h2 {
  font-size: 1.8rem;
  font-family: var(--heading-font);
  color: var(--default-color);
  margin-bottom: 0.5rem;
}

.contact p {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.contact-buttons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.contact-buttons a.button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0.75rem 1.5rem;
  color: white;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
}

/* Warna tombol Email */
.email-button {
  background-color: #0078D4;
  transition: background-color 0.2s ease;
}

.email-button:hover {
  background-color: #005A9E;
}

/* Warna tombol WhatsApp */
.whatsapp-button {
  background-color: #25D366;
  transition: background-color 0.2s ease;
}

.whatsapp-button:hover {
  background-color: #128C7E;
}

/* --- FIX IKON --- */
.contact-buttons a.button .icon {
  width: 20px; /* Lebar ikon ditetapkan */
  height: 20px; /* Tinggi ikon ditetapkan */
  flex-shrink: 0; /* Mencegah ikon menyusut di Flexbox */
}
/* -------------------------------------------------------------------------- */

/* === FOOTER === */
.footer {
  background-color: #f2f2f2;
  padding: 1rem 1rem;
  text-align: center;
  color: #444;
}

.footer h3 {
  font-weight: 600;
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  color: #333;
}

.footer .tagline {
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.footer .social-links {
  display: flex;
  justify-content: center;
  gap: 1.2rem;
  margin-bottom: 1rem;
}

.footer .social-links img {
  width: 24px;
  height: 24px;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.footer .social-links img:hover {
  opacity: 1;
}

.footer .copyright {
  font-size: 0.85rem;
  color: #666;
}

.footer .social-links a {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #444;
}


/* -------------------------------------------------------------------------- */
/* === MOBILE VIEW FIXES (@media) === */
/* Semua penyesuaian untuk layar di bawah 768px */
@media (max-width: 768px) {
  
  /* --- HEADER MOBILE FIXES (Mengatur susunan kolom di HP) --- */
  .full-header {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  /* Mengurangi padding atas/bawah header agar tidak terlalu besar di HP */
  .header {
    padding: 5px 0;
  }
  
  .header-logo {
      max-height: 50px; /* Mengurangi ukuran logo di HP */
  }

  .header-left {
    font-size: 1.3rem;
    margin-bottom: 5px;
  }

  .header-right ul {
    /* Menu Navigasi diubah menjadi kolom */
    flex-direction: column;
    gap: 5px; /* Jarak menu lebih rapat */
  }

  .header-right a {
    font-size: 16px;
  }
  
  /* --- INTRO MOBILE FIXES --- */
  .intro h1 {
    font-size: 1.8rem;
  }
  .intro p {
    font-size: 0.95rem;
  }
  
  /* --- KONTAK MOBILE FIXES --- */
  .contact-buttons {
    flex-direction: column;
  }
  .contact-buttons a.button {
    width: 90%;
    justify-content: center;
  }
}