/* ==========================================================================
   KunyitPedia — Monograf Botani & Rempah Dapur Nusantara
   Theme: Warm Artisanal Spice Monograph (Sandstone Ivory, Espresso, Saffron)
========================================================================== */
:root {
  --bg-ivory: #fdf8f1;
  --bg-paper: #ffffff;
  --bg-sand: #f6ecde;
  --espresso: #3c2214;
  --saffron: #c46b12;
  --saffron-soft: #fff2df;
  --text-main: #2d1f17;
  --text-muted: #665246;
  --border-warm: #e5d5c1;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --shadow-warm: 0 8px 26px rgba(60, 34, 20, 0.07);
  --font-serif: "Palatino Linotype", Palatino, Georgia, serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --max-w: 1080px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-ivory);
  color: var(--text-main);
  line-height: 1.66;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  width: 100%;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul, ol {
  list-style: none;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(253, 248, 241, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--espresso);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 16px;
}

.brand-lockup {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-title {
  font-family: var(--font-serif);
  font-size: 1.48rem;
  font-weight: 700;
  color: var(--espresso);
  letter-spacing: 0.01em;
}

.brand-tagline {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--saffron);
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
}

.nav-links a:hover {
  color: var(--saffron);
}

.mobile-menu-btn {
  display: none;
  background: var(--bg-sand);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--espresso);
  cursor: pointer;
}

/* Monograph Split Hero */
.hero-monograph {
  padding: 46px 0 42px;
  border-bottom: 1px solid var(--border-warm);
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 38px;
  align-items: center;
}

.hero-copy-box {
  border-left: 4px solid var(--saffron);
  padding-left: 24px;
}

.chapter-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--saffron);
  margin-bottom: 10px;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 2.55rem;
  line-height: 1.16;
  color: var(--espresso);
  margin-bottom: 16px;
}

.hero-lead {
  font-size: 1.02rem;
  color: var(--text-muted);
  margin-bottom: 22px;
}

.hero-stats-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.hero-stats-inline strong {
  color: var(--espresso);
}

.hero-art-frame {
  background: var(--bg-paper);
  padding: 10px;
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-warm);
}

.hero-art-frame img {
  width: 100%;
  height: 310px;
  object-fit: cover;
  border-radius: var(--radius-md);
}

.frame-caption {
  padding: 10px 6px 4px;
  font-size: 0.79rem;
  color: var(--text-muted);
  font-style: italic;
}

/* Ribbon Facts */
.ribbon-facts {
  background: var(--bg-sand);
  border-bottom: 1px solid var(--border-warm);
  padding: 24px 0;
}

.ribbon-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.ribbon-item {
  background: var(--bg-paper);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  padding: 15px 16px;
}

.ribbon-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--saffron);
  font-weight: 700;
  margin-bottom: 3px;
}

.ribbon-val {
  font-family: var(--font-serif);
  font-size: 1.06rem;
  font-weight: 700;
  color: var(--espresso);
}

.ribbon-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* Monograph Sections */
.mono-section {
  padding: 64px 0;
  border-bottom: 1px solid var(--border-warm);
}

.mono-section.paper-bg {
  background: var(--bg-paper);
}

.section-header {
  display: flex;
  flex-direction: column;
  max-width: 720px;
  margin-bottom: 34px;
}

.section-title {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: var(--espresso);
  line-height: 1.2;
  margin-bottom: 10px;
}

.section-desc {
  font-size: 0.98rem;
  color: var(--text-muted);
}

/* Split Narrative */
.narrative-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px;
  align-items: center;
}

.narrative-prose p {
  font-size: 0.96rem;
  margin-bottom: 15px;
  color: var(--text-main);
}

.spice-notes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 18px;
}

.spice-note {
  background: var(--bg-paper);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  padding: 14px;
}

.spice-note strong {
  display: block;
  font-size: 0.88rem;
  color: var(--espresso);
  margin-bottom: 3px;
}

.spice-note span {
  font-size: 0.81rem;
  color: var(--text-muted);
}

.photo-card {
  background: var(--bg-paper);
  padding: 8px;
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-warm);
}

.photo-card img {
  width: 100%;
  height: 315px;
  object-fit: cover;
  border-radius: var(--radius-md);
}

/* Composition Table — 100% Mobile Fit */
.comp-split {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 28px;
  align-items: start;
}

.spice-table-wrap {
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-ivory);
}

.spice-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
}

.spice-table th, .spice-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-warm);
  font-size: 0.88rem;
  text-align: left;
  vertical-align: middle;
}

.spice-table th {
  background: var(--espresso);
  color: #fdf8f1;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.spice-table tr:last-child td {
  border-bottom: none;
}

.spice-table td:nth-child(2) {
  font-weight: 700;
  color: var(--saffron);
}

.spice-table-foot {
  padding: 10px 14px;
  font-size: 0.77rem;
  color: var(--text-muted);
  background: var(--bg-sand);
}

.comp-cards {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.comp-card {
  background: var(--bg-ivory);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  padding: 16px 18px;
}

.comp-card h3 {
  font-family: var(--font-serif);
  font-size: 1.08rem;
  color: var(--espresso);
  margin-bottom: 5px;
}

.comp-card p {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* Interactive Spice Ratio Calculator */
.calc-box {
  background: var(--bg-paper);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-warm);
}

.calc-controls {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  margin-bottom: 24px;
  align-items: end;
}

.control-label {
  display: block;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: var(--saffron);
  margin-bottom: 10px;
}

.recipe-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.recipe-btn {
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-warm);
  background: var(--bg-ivory);
  color: var(--espresso);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.recipe-btn.active {
  background: var(--espresso);
  color: #fdf8f1;
  border-color: var(--espresso);
}

.portion-control {
  background: var(--bg-ivory);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  padding: 14px 16px;
}

.portion-head {
  display: flex;
  justify-content: space-between;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--espresso);
  margin-bottom: 8px;
}

.portion-slider {
  width: 100%;
  accent-color: var(--saffron);
  cursor: pointer;
}

.calc-results {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}

.res-card {
  background: var(--saffron-soft);
  border: 1px solid #f0d7b4;
  border-radius: var(--radius-md);
  padding: 14px 16px;
}

.res-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--saffron);
  font-weight: 700;
  margin-bottom: 4px;
}

.res-val {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--espresso);
}

.calc-note {
  background: var(--bg-sand);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  font-size: 0.9rem;
  color: var(--espresso);
}

/* Culinary Tips 3-Col */
.tips-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 30px;
}

.tip-card {
  background: var(--bg-ivory);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  padding: 20px;
}

.tip-label {
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--saffron);
  margin-bottom: 6px;
}

.tip-card h3 {
  font-family: var(--font-serif);
  font-size: 1.12rem;
  color: var(--espresso);
  margin-bottom: 6px;
}

.tip-card p {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* FAQ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 820px;
}

.faq-row {
  background: var(--bg-paper);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.faq-q {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 18px 20px;
  font-family: var(--font-sans);
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--espresso);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.faq-sign {
  font-size: 1.2rem;
  color: var(--saffron);
  transition: transform 0.2s ease;
}

.faq-row.open .faq-sign {
  transform: rotate(45deg);
}

.faq-a {
  display: none;
  padding: 14px 20px 18px;
  border-top: 1px solid var(--bg-sand);
  font-size: 0.9rem;
  color: var(--text-muted);
}

.faq-row.open .faq-a {
  display: block;
}

.colophon-note {
  margin-top: 30px;
  background: var(--bg-sand);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Footer */
.site-footer {
  background: var(--espresso);
  color: #e4d8ca;
  padding: 48px 0 30px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 30px;
  padding-bottom: 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-brand {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: #ffffff;
  margin-bottom: 8px;
}

.footer-desc {
  font-size: 0.86rem;
  color: #cbbba8;
  max-width: 350px;
}

.footer-col h4 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #f0ae5d;
  margin-bottom: 12px;
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.86rem;
}

.footer-col a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.footer-bottom {
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.8rem;
  color: #b7a592;
}

/* Legal Subpage */
.legal-page {
  padding: 52px 0 70px;
}

.legal-panel {
  max-width: 780px;
  margin: 0 auto;
  background: var(--bg-paper);
  border: 1px solid var(--border-warm);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-warm);
}

.legal-panel h1 {
  font-family: var(--font-serif);
  font-size: 1.95rem;
  color: var(--espresso);
  margin-bottom: 14px;
}

.legal-panel h2 {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  color: var(--espresso);
  margin: 22px 0 8px;
}

.legal-panel p {
  font-size: 0.94rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.back-link {
  display: inline-block;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--saffron);
  margin-bottom: 18px;
}

/* Responsive */
@media (max-width: 900px) {
  .hero-layout,
  .narrative-grid,
  .comp-split,
  .calc-controls,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .ribbon-grid,
  .calc-results {
    grid-template-columns: repeat(2, 1fr);
  }

  .tips-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .container {
    padding: 0 16px;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: var(--bg-ivory);
    border-bottom: 1px solid var(--border-warm);
    flex-direction: column;
    align-items: flex-start;
    padding: 16px 20px;
    gap: 14px;
  }

  .nav-links.open {
    display: flex;
  }

  .mobile-menu-btn {
    display: inline-block;
  }

  .hero-monograph {
    padding: 28px 0 26px;
  }

  .hero-copy-box {
    padding-left: 16px;
  }

  .hero-title {
    font-size: 1.85rem;
  }

  .hero-art-frame img {
    height: 220px;
  }

  .photo-card img {
    height: 210px;
  }

  .spice-notes {
    grid-template-columns: 1fr;
  }

  .mono-section {
    padding: 42px 0;
  }

  .section-title {
    font-size: 1.55rem;
  }

  .spice-table th, .spice-table td {
    padding: 10px 8px;
    font-size: 0.78rem;
  }

  .calc-box {
    padding: 18px;
  }

  .legal-panel {
    padding: 24px 18px;
  }
}
