/* ==========================================================
   Verivine — shared styles
   Colors and fonts follow the Verivine Brand Guidelines V1.
   Change them here and the whole site updates.
   ========================================================== */

:root {
  --plum: #590a3d;         /* Merlot: headings, primary buttons */
  --plum-2: #741650;       /* Merlot, lighter: hover */
  --plum-deep: #590a3d;    /* Merlot: dark sections */
  --olive: #42630f;        /* Vineyard: accents */
  --olive-soft: #eef2e4;   /* Vineyard tint */
  --rose: #fff2f5;         /* Rose: soft backgrounds, text on Merlot */
  --bg: #ffffff;           /* White */
  --surface: #ffffff;
  --ink: #242f26;          /* Dark Grass: body text */
  --muted: #5d665f;        /* Dark Grass, softer */
  --line: #eadde2;         /* borders */
  --radius: 16px;
  --max: 1160px;
  /* Brand headings use Apollo (a licensed font). Marcellus is a free,
     similar stand-in. If you license Apollo, add it here first. */
  --serif: "Marcellus", Georgia, serif;
  --sans: "Open Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  color: var(--plum);
  line-height: 1.12;
  margin: 0 0 .5em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: 1.5rem; }
p  { margin: 0 0 1em; }

.container { width: min(var(--max), 100% - 32px); margin-inline: auto; }

.eyebrow {
  display: inline-block;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--olive);
  margin-bottom: 1rem;
}
.lead { font-size: 1.2rem; color: var(--muted); max-width: 42rem; }
.muted { color: var(--muted); }

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 76px; }

.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; line-height: 1.1; color: var(--plum); }
.brand-text { display: flex; flex-direction: column; }
.brand-mark { width: 52px; height: 52px; margin: -6px -4px; object-fit: contain; }
.brand-name { font-family: var(--serif); font-size: 1.55rem; letter-spacing: .01em; }
.brand-sub  { font-size: .62rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); }
.brand-logo { height: 40px; width: auto; }

.nav-links { display: flex; align-items: center; gap: 2rem; list-style: none; margin: 0; padding: 0; }
.nav-links a { text-decoration: none; font-size: .92rem; color: var(--muted); transition: color .2s; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--plum); }
.nav-links a[aria-current="page"] { font-weight: 600; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 8px;
  padding: .5rem .8rem;
  font: inherit;
  cursor: pointer;
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 76px; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    padding: .5rem 16px 1rem;
  }
  .nav-links.open { display: flex; }
  .nav-links a { display: block; padding: .8rem 0; font-size: 1rem; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .85rem 1.6rem;
  border-radius: 999px;
  font: 600 .9rem var(--sans);
  letter-spacing: .02em;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .2s, border-color .2s, color .2s, transform .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--plum); color: #fff; }
.btn-primary:hover { background: var(--plum-2); }
.btn-ghost { border-color: currentColor; color: var(--plum); background: transparent; }
.btn-ghost:hover { background: var(--plum); border-color: var(--plum); color: #fff; }
.btn-light { background: #fff; color: var(--plum); }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2rem; }

/* ---------- Hero ---------- */

.hero { position: relative; padding: clamp(5rem, 12vw, 9rem) 0 clamp(4rem, 10vw, 7rem); overflow: hidden; }
.hero::before {
  content: "";
  position: absolute;
  inset: -30% -15% auto auto;
  width: 65vw; height: 65vw;
  background: radial-gradient(circle, rgba(91, 11, 61, .10), transparent 62%);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto auto -40% -20%;
  width: 50vw; height: 50vw;
  background: radial-gradient(circle, rgba(75, 106, 23, .08), transparent 62%);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
.hero h1 { max-width: 15ch; color: var(--plum-deep); }
.hero h1 em { font-style: normal; color: var(--olive); }
.hero-small { padding: clamp(4rem, 9vw, 6rem) 0 3rem; }
.hero-small h1 { max-width: 20ch; }
.hero-logo { height: clamp(56px, 9vw, 96px); width: auto; margin-bottom: 2rem; }

/* ---------- Sections ---------- */

.section { padding: clamp(4rem, 9vw, 7rem) 0; }
.section-white { background: var(--rose); }
.section-dark { background: var(--plum-deep); color: var(--rose); }
.section-dark h2, .section-dark h3 { color: var(--rose); }
.section-dark .lead, .section-dark .muted { color: #cdb8c3; }
.section-dark .eyebrow { color: #b9cf8c; }
.section-head { margin-bottom: 3rem; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 6vw, 5rem); align-items: center; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } }

/* Placeholder image block — replace with a real <img> */
.media {
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 30% 20%, rgba(75, 106, 23, .35), transparent 45%),
    linear-gradient(200deg, var(--plum-2), var(--plum-deep) 85%);
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, .55);
  font-size: .75rem;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.media.wide { aspect-ratio: 16 / 10; }

/* ---------- Cards ---------- */

.grid { display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.75rem;
  text-decoration: none;
  transition: border-color .2s, transform .2s, box-shadow .2s;
}
a.card:hover { border-color: var(--plum); transform: translateY(-3px); box-shadow: 0 14px 30px -18px rgba(43, 10, 30, .35); }
.card p { color: var(--muted); font-size: .95rem; }
.card h3 { color: var(--plum-deep); }
.card .meta { margin-top: auto; font-size: .72rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--olive); }
.card-media { margin: -1.75rem -1.75rem 1.5rem; aspect-ratio: 16 / 10; border-radius: var(--radius) var(--radius) 0 0; overflow: hidden; }
.section-dark .card { background: rgba(255, 255, 255, .05); border-color: rgba(255, 255, 255, .12); }
.section-dark .card h3 { color: #fff; }
.section-dark .card p { color: #cdb8c3; }
.section-dark .card .meta { color: #b9cf8c; }
.section-dark a.card:hover { border-color: #b9cf8c; }

.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
@media (max-width: 900px) { .pillars { grid-template-columns: 1fr; } }
.pillar { padding: 2.25rem; }
.pillar .num { font-family: var(--serif); font-size: 2.5rem; color: var(--olive); line-height: 1; margin-bottom: 1rem; }

.values { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2.5rem; }
.values h3 { font-size: 1.35rem; color: var(--plum); }

/* ---------- Tabs on the Learn page ---------- */

.tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2.5rem; }
.tab {
  padding: .55rem 1.2rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font: 500 .9rem var(--sans);
  cursor: pointer;
}
.tab:hover { color: var(--plum); }
.tab[aria-selected="true"] { background: var(--plum); border-color: var(--plum); color: #fff; }
.panel[hidden] { display: none; }

/* ---------- Article ---------- */

.article { max-width: 44rem; margin-inline: auto; }
.article h2 { font-size: 2rem; margin-top: 2.5rem; color: var(--plum-deep); }
.article ol, .article ul { padding-left: 1.25rem; }
.article li { margin-bottom: .6rem; }
.back { display: inline-block; margin-bottom: 1.5rem; font-size: .9rem; color: var(--muted); text-decoration: none; }
.back:hover { color: var(--plum); }
.callout {
  border-left: 3px solid var(--olive);
  background: var(--olive-soft);
  padding: 1.25rem 1.5rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin: 2rem 0;
}

/* ---------- Blog-style articles ---------- */

.byline { font-size: .85rem; color: var(--muted); margin: -.25rem 0 2.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--line); }
.pull {
  margin: 2rem 0;
  padding: 0 0 0 1.5rem;
  border-left: 3px solid var(--olive);
  font-family: var(--serif);
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  line-height: 1.2;
  color: var(--plum);
}
.signoff { font-family: var(--serif); font-size: 1.5rem; color: var(--plum); margin-top: 2rem; }

/* ---------- Country guides ---------- */

.toc {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: 2rem 0 1rem;
  padding: 0;
  list-style: none;
}
.toc a {
  display: inline-block;
  padding: .4rem .9rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: .85rem;
  text-decoration: none;
  color: var(--muted);
}
.toc a:hover { border-color: var(--plum); color: var(--plum); }
.article h2 { scroll-margin-top: 96px; }
.article h3 { font-size: 1.6rem; margin-top: 2.25rem; margin-bottom: .1em; }
.article .where {
  display: block;
  font: 600 .72rem var(--sans);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--olive);
  margin-bottom: .9rem;
}

.grape-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin: 1.5rem 0; }
.grape-grid .card { padding: 1.4rem; }
.grape-grid h3 { font-size: 1.45rem; margin: 0 0 .15rem; }
.grape-grid .aka { font-size: .8rem; color: var(--olive); font-weight: 600; margin-bottom: .6rem; }

.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: .25rem 0 1.5rem; padding: 0; list-style: none; }
.chips li {
  margin: 0;
  padding: .25rem .7rem;
  border-radius: 999px;
  background: var(--rose);
  color: var(--plum);
  font-size: .82rem;
  font-weight: 500;
}
.chips-label { font-size: .8rem; font-weight: 600; color: var(--muted); margin: 0; }

/* ---------- Quiz ---------- */

.quiz {
  max-width: 44rem;
  margin-inline: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) * 1.5);
  padding: clamp(1.5rem, 5vw, 3rem);
  box-shadow: 0 30px 60px -40px rgba(43, 10, 30, .35);
}
.quiz-progress { height: 4px; background: var(--line); border-radius: 999px; overflow: hidden; margin-bottom: 2rem; }
.quiz-progress span { display: block; height: 100%; background: var(--olive); transition: width .3s; }
.quiz-count { font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.quiz h2 { font-size: clamp(1.6rem, 4vw, 2.2rem); margin: .5rem 0 1.5rem; color: var(--plum-deep); }
.options { display: grid; gap: .75rem; }
.option {
  text-align: left;
  padding: 1rem 1.25rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  font: 500 1rem var(--sans);
  cursor: pointer;
  transition: border-color .2s, background .2s;
}
.option:hover:not(:disabled) { border-color: var(--plum); }
.option:disabled { cursor: default; }
.option.correct { border-color: var(--olive); background: var(--olive-soft); }
.option.wrong   { border-color: #b3344a; background: #fbecee; }
.explain { margin-top: 1.5rem; color: var(--muted); }
.explain strong { color: var(--ink); }
.quiz-foot { display: flex; justify-content: flex-end; margin-top: 1.5rem; }
.score { font-family: var(--serif); font-size: 5rem; line-height: 1; color: var(--plum); margin: 1rem 0; }

/* ---------- Shop ---------- */

.notice {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  background: var(--olive-soft);
  border: 1px solid #d5e0bd;
  border-radius: var(--radius);
  margin-bottom: 3rem;
}
.notice .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--olive); flex: none; }
.product .bottle {
  aspect-ratio: 3 / 4;
  border-radius: 10px;
  margin-bottom: 1.25rem;
  background: radial-gradient(ellipse at 50% 35%, #f6eef2, #ead9e2 75%);
  display: grid;
  place-items: center;
}
.product .bottle svg { width: 26%; color: var(--plum); opacity: .55; }
.product h3 { font-size: 1.3rem; margin-bottom: .25rem; }
.product .price { color: var(--plum); font-weight: 600; margin: .5rem 0 1rem; }
.badge {
  align-self: flex-start;
  font-size: .65rem;
  font-weight: 600;
  letter-spacing: .15em;
  text-transform: uppercase;
  padding: .3rem .6rem;
  border-radius: 999px;
  background: var(--olive-soft);
  color: var(--olive);
  margin-bottom: .75rem;
}

/* ---------- Footer ---------- */

.site-footer { background: var(--plum-deep); color: #cdb8c3; padding: 3.5rem 0 2rem; font-size: .9rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; margin-bottom: 2.5rem; }
@media (max-width: 700px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer .brand { color: #fff; }
.site-footer .brand-sub { color: #cdb8c3; }
.site-footer h4 { color: #fff; font: 600 .75rem var(--sans); letter-spacing: .15em; text-transform: uppercase; margin: 0 0 1rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .5rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: #fff; }
.legal { border-top: 1px solid rgba(255, 255, 255, .12); padding-top: 1.5rem; font-size: .8rem; }
