/* ── Google Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=Inter:wght@300;400;500;600&display=swap');

/* ── Reset & base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --brown:   #3B1F0A;
  --gold:    #C8922A;
  --cream:   #FAF3E0;
  --green:   #2D5016;
  --muted:   #8B6E52;
  --border:  #D6C4A0;
  --card-bg: #F5EDD8;
  --serif:   'Playfair Display', Georgia, serif;
  --sans:    'Inter', system-ui, sans-serif;
}

html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--sans); background: var(--cream); color: var(--brown); line-height: 1.7; -webkit-font-smoothing: antialiased; }
h1,h2,h3,h4,h5 { font-family: var(--serif); color: var(--brown); line-height: 1.2; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

/* ── Layout ── */
.container { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 1.5rem; }
.container--narrow { max-width: 800px; }

/* ── Navbar ── */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 243, 224, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.navbar .container { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 1rem; }
.navbar .logo { display: flex; align-items: center; gap: 0.5rem; font-family: var(--serif); font-size: 1.5rem; font-weight: 700; color: var(--brown); flex-shrink: 0; }
.navbar .logo svg { width: 22px; height: 22px; color: var(--green); }
.nav-links { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.nav-links a { font-size: 0.85rem; font-weight: 500; color: rgba(59,31,10,0.75); transition: color .2s; white-space: nowrap; }
.nav-links a:hover, .nav-links a.active { color: var(--gold); }

/* hamburger */
.hamburger { display: none; flex-direction: column; justify-content: center; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px; }
.hamburger span { display: block; width: 24px; height: 2px; background: var(--brown); border-radius: 2px; transition: all .3s; }
.hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* mobile menu */
.mobile-menu { display: none; position: fixed; top: 64px; left: 0; right: 0; background: var(--cream); border-bottom: 1px solid var(--border); z-index: 99; padding: 1.5rem; box-shadow: 0 8px 24px rgba(59,31,10,.12); }
.mobile-menu.open { display: block; }
.mobile-menu a { display: block; padding: .75rem 0; font-size: 1.05rem; font-weight: 500; color: var(--brown); border-bottom: 1px solid var(--border); }
.mobile-menu a:last-child { border-bottom: none; }

@media (max-width: 900px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
}

/* ── Footer ── */
.footer { background: #26150a; color: var(--cream); padding: 3.5rem 0 2rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2.5rem; padding-bottom: 2.5rem; border-bottom: 1px solid rgba(250,243,224,.1); }
.footer-logo { display: flex; align-items: center; gap: .5rem; font-family: var(--serif); font-size: 1.4rem; font-weight: 700; margin-bottom: 1rem; }
.footer-logo svg { width: 20px; height: 20px; color: var(--gold); }
.footer-desc { font-size: .85rem; color: rgba(250,243,224,.6); max-width: 280px; line-height: 1.7; margin-bottom: 1rem; }
.sitio-badge { display: inline-block; font-size: .72rem; font-weight: 600; color: var(--gold); border: 1px solid rgba(200,146,42,.3); background: rgba(200,146,42,.1); padding: .3rem .8rem; border-radius: 100px; }
.footer h4 { font-family: var(--serif); font-size: 1rem; font-weight: 600; color: var(--gold); margin-bottom: 1rem; }
.footer ul li { margin-bottom: .5rem; }
.footer ul a { font-size: .85rem; color: rgba(250,243,224,.6); transition: color .2s; }
.footer ul a:hover { color: var(--gold); }
.footer-bottom { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; padding-top: 2rem; flex-wrap: wrap; }
.footer-bottom p { font-size: .75rem; color: rgba(250,243,224,.45); line-height: 1.6; }
@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* ── Back to top ── */
#back-top { display: none; position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 90; width: 44px; height: 44px; align-items: center; justify-content: center; background: var(--gold); color: var(--brown); border: none; border-radius: 50%; cursor: pointer; box-shadow: 0 4px 16px rgba(59,31,10,.25); font-size: 1.2rem; transition: background .2s, transform .2s; }
#back-top:hover { background: var(--cream); transform: translateY(-3px); }

/* ── Hero ── */
.hero { position: relative; min-height: 90vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; background: var(--brown); overflow: hidden; padding: 4rem 1.5rem; }
.hero-gradient { position: absolute; inset: 0; background: linear-gradient(135deg, rgba(45,80,22,.35) 0%, rgba(59,31,10,1) 50%, rgba(200,146,42,.25) 100%); }
.hero-glow { position: absolute; top: 0; right: 0; width: 65%; height: 100%; background: radial-gradient(ellipse at 80% 30%, rgba(200,146,42,.18), transparent 65%); }
.hero-glow2 { position: absolute; bottom: 0; left: 0; width: 55%; height: 70%; background: radial-gradient(ellipse at 20% 80%, rgba(45,80,22,.28), transparent 60%); }
.hero-content { position: relative; z-index: 2; max-width: 800px; }
.sitio-badge { display: inline-flex; align-items: center; border: 1px solid rgba(250,243,224,.2); background: rgba(250,243,224,.08); backdrop-filter: blur(4px); padding: .4rem 1rem; border-radius: 100px; font-size: .8rem; font-weight: 500; color: var(--cream); margin-bottom: 1.5rem; letter-spacing: .04em; }
.hero h1 { font-size: clamp(2.8rem, 8vw, 5.5rem); font-weight: 700; color: var(--cream); line-height: 1.1; margin-bottom: 1.25rem; }
.hero h1 em { color: var(--gold); font-style: italic; }
.hero-sub { font-size: 1.15rem; color: rgba(250,243,224,.75); max-width: 560px; margin: 0 auto 2rem; line-height: 1.7; font-weight: 300; }
.hero-btn { display: inline-flex; align-items: center; gap: .5rem; background: var(--gold); color: var(--brown); font-weight: 600; font-size: 1rem; padding: .9rem 2rem; border: none; cursor: pointer; transition: background .25s; text-decoration: none; }
.hero-btn:hover { background: var(--cream); }
.hero-disclaimer { position: absolute; bottom: 1.5rem; left: 0; right: 0; text-align: center; font-size: .65rem; color: rgba(250,243,224,.35); letter-spacing: .08em; text-transform: uppercase; padding: 0 1rem; }

/* ── Page hero ── */
.page-hero { background: var(--brown); padding: 7rem 1.5rem 5rem; text-align: center; position: relative; overflow: hidden; }
.page-hero::before { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(45,80,22,.3), transparent 60%, rgba(200,146,42,.2)); }
.page-hero-inner { position: relative; z-index: 1; }
.page-hero .eyebrow { display: block; font-size: .75rem; font-weight: 600; letter-spacing: .15em; text-transform: uppercase; color: var(--gold); margin-bottom: .75rem; }
.page-hero h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 700; color: var(--cream); max-width: 700px; margin: 0 auto .75rem; }
.page-hero p { font-size: 1.1rem; color: rgba(250,243,224,.7); max-width: 560px; margin: 0 auto; font-weight: 300; }
.page-hero.green { background: var(--green); }

/* ── Sections ── */
section { padding: 5rem 1.5rem; }
.section-label { font-size: .75rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 600; color: var(--gold); margin-bottom: .5rem; display: block; }
.section-title { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 700; color: var(--brown); margin-bottom: .5rem; }
.section-rule { width: 40px; height: 3px; background: var(--gold); margin: 1.25rem 0 2.5rem; }
.section-rule--center { margin: 1.25rem auto 2.5rem; }
.text-muted { color: var(--muted); }

/* ── Cards grid ── */
.cards-grid { display: grid; gap: 1.5rem; }
.cards-grid--4 { grid-template-columns: repeat(4, 1fr); }
.cards-grid--3 { grid-template-columns: repeat(3, 1fr); }
.cards-grid--2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 1000px) { .cards-grid--4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px) {
  .cards-grid--4, .cards-grid--3, .cards-grid--2 { grid-template-columns: 1fr; }
}

.card { background: var(--card-bg); border: 1px solid var(--border); padding: 2rem; display: flex; flex-direction: column; transition: border-color .25s; }
.card:hover { border-color: var(--gold); }
.card-icon { font-size: 1.6rem; margin-bottom: 1.25rem; }
.card h3 { font-family: var(--serif); font-size: 1.3rem; font-weight: 700; margin-bottom: .75rem; }
.card p { font-size: .9rem; color: var(--muted); line-height: 1.7; }
.card .tag { display: inline-block; font-size: .7rem; font-weight: 600; color: var(--gold); letter-spacing: .1em; text-transform: uppercase; margin-bottom: .5rem; }

/* region card special */
.region-card { background: var(--card-bg); border: 1px solid var(--border); overflow: hidden; transition: border-color .25s; }
.region-card:hover { border-color: var(--gold); }
.region-card .region-bar { height: 5px; width: 100%; }
.region-card .region-body { padding: 1.75rem; }
.region-card h3 { font-family: var(--serif); font-size: 1.4rem; margin-bottom: .25rem; }
.region-card .region-dept { font-size: .8rem; color: var(--muted); margin-bottom: 1rem; }
.region-stats { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; margin-bottom: 1rem; }
.region-stat { background: rgba(59,31,10,.04); padding: .6rem .75rem; }
.region-stat .stat-label { font-size: .65rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.region-stat .stat-value { font-size: .85rem; font-weight: 600; color: var(--brown); margin-top: .2rem; }
.region-profile { font-size: .8rem; font-style: italic; color: var(--brown); border-left: 3px solid var(--gold); padding-left: .75rem; margin-bottom: .75rem; line-height: 1.6; }
.region-notes { font-size: .82rem; color: var(--muted); line-height: 1.7; }

/* ── Prose sections ── */
.prose { max-width: 720px; }
.prose p { font-size: 1.05rem; color: rgba(59,31,10,.82); line-height: 1.8; margin-bottom: 1.25rem; }
.prose strong { color: var(--brown); font-weight: 600; }

/* ── Pull quote ── */
.pull-quote { background: var(--brown); padding: 4rem 2rem; text-align: center; }
.pull-quote blockquote { font-family: var(--serif); font-size: clamp(1.3rem, 3vw, 1.9rem); font-style: italic; color: var(--cream); max-width: 800px; margin: 0 auto; line-height: 1.5; }

/* ── Steps list ── */
.steps { display: flex; flex-direction: column; gap: 0; }
.step { display: flex; gap: 2rem; padding: 2.5rem 0; border-bottom: 1px solid var(--border); }
.step:last-child { border-bottom: none; }
.step-num { font-family: var(--serif); font-size: 4rem; font-weight: 700; color: rgba(200,146,42,.25); line-height: 1; flex-shrink: 0; min-width: 70px; transition: color .2s; }
.step:hover .step-num { color: rgba(200,146,42,.5); }
.step-body h3 { font-family: var(--serif); font-size: 1.35rem; font-weight: 700; margin-bottom: .6rem; }
.step-body p { font-size: .95rem; color: var(--muted); line-height: 1.75; }

/* ── Table ── */
.data-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.data-table th { text-align: left; padding: .75rem 1rem; font-family: var(--serif); font-weight: 600; border-bottom: 2px solid rgba(200,146,42,.4); }
.data-table td { padding: .75rem 1rem; color: var(--muted); }
.data-table tr:nth-child(even) td { background: rgba(59,31,10,.03); }
.data-table .td-name { font-weight: 600; color: var(--brown); }
.table-wrap { overflow-x: auto; }

/* ── Pillar list ── */
.pillar-list { display: flex; flex-direction: column; border: 1px solid var(--border); }
.pillar-item { display: flex; gap: 1.5rem; padding: 1.75rem 2rem; border-bottom: 1px solid var(--border); transition: background .2s; }
.pillar-item:last-child { border-bottom: none; }
.pillar-item:hover { background: rgba(200,146,42,.04); }
.pillar-bar { width: 4px; background: rgba(200,146,42,.3); border-radius: 4px; flex-shrink: 0; }
.pillar-body h3 { font-family: var(--serif); font-size: 1.1rem; margin-bottom: .5rem; }
.pillar-body p { font-size: .9rem; color: var(--muted); line-height: 1.7; }

/* ── Certification list ── */
.cert-list { display: flex; flex-direction: column; border: 1px solid var(--border); }
.cert-item { display: flex; gap: 1.5rem; padding: 1.5rem 2rem; border-bottom: 1px solid var(--border); }
.cert-item:last-child { border-bottom: none; }
.cert-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); flex-shrink: 0; margin-top: .6rem; }
.cert-body h3 { font-family: var(--serif); font-size: 1.05rem; margin-bottom: .4rem; }
.cert-body p { font-size: .88rem; color: var(--muted); line-height: 1.7; }

/* ── FAQ ── */
.faq-list { border: 1px solid var(--border); }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-item:last-child { border-bottom: none; }
.faq-trigger { width: 100%; background: none; border: none; padding: 1.5rem 1.75rem; text-align: left; cursor: pointer; display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; font-family: var(--serif); font-size: 1.05rem; font-weight: 600; color: var(--brown); line-height: 1.4; transition: color .2s; }
.faq-trigger:hover { color: var(--gold); }
.faq-icon { font-size: 1.2rem; flex-shrink: 0; transition: transform .3s; line-height: 1; }
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-body { display: none; padding: 0 1.75rem 1.5rem; }
.faq-item.open .faq-body { display: block; }
.faq-body p { font-size: .95rem; color: var(--muted); line-height: 1.8; }

/* ── Glossary ── */
.glossary-search-bar { position: sticky; top: 64px; z-index: 50; background: var(--cream); border-bottom: 1px solid var(--border); padding: 1.25rem 1.5rem; }
.glossary-search-bar .container { max-width: 700px; position: relative; }
.search-icon { position: absolute; left: 1rem; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 1rem; pointer-events: none; }
#glossary-search { width: 100%; padding: .8rem 1rem .8rem 2.8rem; border: 1px solid var(--border); background: var(--cream); font-family: var(--sans); font-size: 1rem; color: var(--brown); outline: none; border-radius: 0; }
#glossary-search:focus { border-color: var(--gold); }
.glossary-group { margin-bottom: 3rem; }
.glossary-letter { font-family: var(--serif); font-size: 3.5rem; font-weight: 700; color: rgba(200,146,42,.25); line-height: 1; margin-bottom: 1rem; }
.glossary-terms { border-top: 1px solid var(--border); }
.glossary-term { display: grid; grid-template-columns: 1fr 2fr; gap: 1.5rem; padding: 1.25rem 0; border-bottom: 1px solid rgba(214,196,160,.4); }
.term-name { font-family: var(--serif); font-weight: 700; font-size: 1rem; color: var(--brown); }
.term-def { font-size: .88rem; color: var(--muted); line-height: 1.7; }
@media (max-width: 600px) {
  .glossary-term { grid-template-columns: 1fr; gap: .5rem; }
}

/* ── Sitemap ── */
.sitemap-section { margin-bottom: 3rem; }
.sitemap-section h2 { font-family: var(--serif); font-size: 1.25rem; margin-bottom: .5rem; }
.sitemap-rule { width: 32px; height: 2px; background: var(--gold); margin-bottom: 1.25rem; }
.sitemap-list { border: 1px solid var(--border); }
.sitemap-link { display: flex; align-items: center; gap: 1rem; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); color: var(--brown); transition: background .2s; }
.sitemap-link:last-child { border-bottom: none; }
.sitemap-link:hover { background: rgba(200,146,42,.06); }
.sitemap-arrow { font-size: 1rem; color: var(--gold); transition: transform .2s; flex-shrink: 0; }
.sitemap-link:hover .sitemap-arrow { transform: translateX(4px); }
.sitemap-link-info { }
.sitemap-link-name { font-weight: 600; font-size: .95rem; }
.sitemap-link-desc { font-size: .82rem; color: var(--muted); }

/* ── Legal page ── */
.legal-body section { padding: 0; margin-bottom: 2.5rem; }
.legal-body h2 { font-family: var(--serif); font-size: 1.4rem; margin-bottom: .75rem; }
.legal-body p { font-size: .95rem; color: var(--muted); line-height: 1.8; margin-bottom: .75rem; }
.legal-body strong { color: var(--brown); }

/* ── Feature link cards (home) ── */
.feature-card { background: var(--card-bg); border: 1px solid var(--border); padding: 2rem; display: flex; flex-direction: column; gap: .75rem; color: var(--brown); transition: border-color .25s; text-decoration: none; }
.feature-card:hover { border-color: var(--gold); }
.feature-card .fc-icon { width: 44px; height: 44px; background: rgba(200,146,42,.1); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; transition: background .25s; }
.feature-card:hover .fc-icon { background: var(--gold); }
.feature-card h3 { font-family: var(--serif); font-size: 1.25rem; font-weight: 700; }
.feature-card p { font-size: .88rem; color: var(--muted); line-height: 1.7; flex: 1; }
.feature-card .fc-more { font-size: .85rem; font-weight: 600; color: var(--green); margin-top: .5rem; display: flex; align-items: center; gap: .3rem; }

/* ── alt bg sections ── */
.bg-cream  { background: var(--cream); }
.bg-card   { background: var(--card-bg); }
.bg-brown  { background: var(--brown); }
.bg-green  { background: var(--green); }
.bg-white  { background: #fff; }

/* ── text colours ── */
.text-cream { color: var(--cream); }
.text-gold  { color: var(--gold); }
.text-brown { color: var(--brown); }
.text-muted-fg { color: rgba(250,243,224,.7); }

.text-center { text-align: center; }

/* ── process methods ── */
.method-cards { display: grid; grid-template-columns: repeat(3,1fr); gap: 1.5rem; }
.method-card { background: var(--card-bg); border: 1px solid var(--border); padding: 2rem; }
.method-card .mc-icon { font-size: 2rem; margin-bottom: 1rem; }
.method-card h3 { font-family: var(--serif); font-size: 1.4rem; margin-bottom: .25rem; }
.method-card .mc-sub { font-size: .85rem; font-style: italic; color: var(--gold); margin-bottom: 1rem; }
.method-card p { font-size: .88rem; color: var(--muted); line-height: 1.7; }
@media (max-width: 700px) { .method-cards { grid-template-columns: 1fr; } }

/* ── varietal grid ── */
.varietal-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 1.25rem; }
@media (max-width: 900px) { .varietal-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 500px) { .varietal-grid { grid-template-columns: 1fr; } }
.varietal-card { background: var(--card-bg); border: 1px solid var(--border); padding: 1.5rem; }
.varietal-card h3 { font-family: var(--serif); font-size: 1.1rem; margin-bottom: .5rem; }
.varietal-card p { font-size: .85rem; color: var(--muted); line-height: 1.7; }

/* ── green text section ── */
.green-section { background: var(--green); padding: 4rem 1.5rem; }
.green-section .container { max-width: 800px; text-align: center; }
.green-section h2 { color: var(--cream); font-size: clamp(1.6rem, 4vw, 2.4rem); margin-bottom: .5rem; }
.green-section .section-rule { background: var(--gold); margin: 1.25rem auto 2rem; }
.green-section .prose p { color: rgba(250,243,224,.8); }

/* ── intro text strip ── */
.intro-strip { padding: 3.5rem 1.5rem; border-bottom: 1px solid var(--border); }

/* ── disclaimer strip ── */
.disclaimer-strip { background: var(--brown); padding: 3rem 1.5rem; text-align: center; }
.disclaimer-strip p { font-size: .8rem; color: rgba(250,243,224,.55); font-family: monospace; letter-spacing: .04em; max-width: 700px; margin: 0 auto; line-height: 1.8; }

/* ── narrative section ── */
.narrative { background: var(--card-bg); border-top: 1px solid var(--border); padding: 4.5rem 1.5rem; }
.narrative .container { max-width: 780px; text-align: center; }
.narrative p { font-family: var(--serif); font-style: italic; font-size: clamp(1.2rem, 2.5vw, 1.6rem); color: var(--brown); line-height: 1.6; }

/* ── utility ── */
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mb-6 { margin-bottom: 3rem; }
