/* ===== Highwire Wines — theme ===== */
@font-face {
  font-family: "Athelas";
  src: url("Athelas-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}

:root {
  --maroon: #6e1423;
  --maroon-deep: #4f0d18;
  --maroon-soft: #8c2f3a;
  --gold: #b08d57;
  --gold-soft: #cbb07e;
  --cream: #f7f2e7;
  --cream-deep: #efe7d4;
  --paper: #fbf8f0;
  --ink: #2a1a1d;
  --ink-soft: #5b4a4d;
  --line: #e0d4bf;
  --shadow: 0 10px 30px rgba(78, 13, 24, 0.10);
  --shadow-lg: 0 18px 50px rgba(78, 13, 24, 0.18);
  --radius: 10px;
  --maxw: 1640px;
  --serif-display: "Cormorant Garamond", "Athelas", Georgia, serif;
  --serif-body: "EB Garamond", "Athelas", Georgia, serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--serif-body);
  font-size: 19px;
  line-height: 1.65;
  color: var(--ink);
  background-color: var(--cream);
  background-image:
    radial-gradient(circle at 20% 0%, rgba(176,141,87,0.07), transparent 45%),
    radial-gradient(circle at 90% 10%, rgba(110,20,35,0.05), transparent 40%);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { font-family: var(--serif-display); font-weight: 600; line-height: 1.15; color: var(--maroon-deep); margin: 0 0 .4em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); letter-spacing: .5px; }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.5rem); }
h3 { font-size: 1.5rem; }
a { color: var(--maroon); text-decoration: none; transition: color .15s; }
a:hover { color: var(--maroon-soft); }
p { margin: 0 0 1em; }
img { max-width: 100%; display: block; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: 64px 0; }
.center { text-align: center; }
.muted { color: var(--ink-soft); }
.eyebrow { text-transform: uppercase; letter-spacing: .28em; font-size: .72rem; color: var(--gold); font-family: var(--serif-body); font-weight: 600; }

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247, 242, 231, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand img { height: 38px; width: auto; }
.brand .wordmark { font-family: var(--serif-display); font-size: 1.5rem; font-weight: 600; color: var(--maroon-deep); letter-spacing: .5px; }
.nav { display: flex; align-items: center; gap: 26px; }
.nav a { font-size: .95rem; letter-spacing: .03em; color: var(--ink); }
.nav a.active, .nav a:hover { color: var(--maroon); }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.6rem; color: var(--maroon); cursor: pointer; }

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav { position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--cream); border-bottom: 1px solid var(--line); max-height: 0; overflow: hidden; transition: max-height .25s ease; }
  .nav.open { max-height: 420px; }
  .nav a { width: 100%; padding: 14px 24px; border-top: 1px solid var(--line); }
}

/* ===== Hero ===== */
.hero {
  position: relative;
  text-align: center;
  padding: 90px 24px 80px;
  background:
    linear-gradient(180deg, rgba(247,242,231,0) 0%, rgba(247,242,231,1) 92%),
    radial-gradient(ellipse at 50% 35%, rgba(176,141,87,0.16), transparent 60%);
  border-bottom: 1px solid var(--line);
}
.hero img.crest { height: 160px; margin: 0 auto 24px; opacity: 1; }
.hero h1 { margin-bottom: .15em; }
.hero .lead { font-size: 1.3rem; color: var(--ink-soft); max-width: 640px; margin: 0 auto 28px; font-style: italic; }
.hero .stat-row { display: flex; gap: 40px; justify-content: center; flex-wrap: wrap; margin-top: 34px; }
.hero .stat { text-align: center; }
.hero .stat b { display: block; font-family: var(--serif-display); font-size: 2.4rem; color: var(--maroon); line-height: 1; }
.hero .stat span { font-size: .78rem; text-transform: uppercase; letter-spacing: .18em; color: var(--gold); }

/* ===== Buttons ===== */
.btn {
  display: inline-block; cursor: pointer;
  font-family: var(--serif-body); font-size: .95rem; letter-spacing: .04em;
  padding: 11px 26px; border-radius: 40px; border: 1px solid var(--maroon);
  background: var(--maroon); color: var(--cream); transition: all .15s;
}
.btn:hover { background: var(--maroon-deep); color: var(--cream); }
.btn.ghost { background: transparent; color: var(--maroon); }
.btn.ghost:hover { background: var(--maroon); color: var(--cream); }
.btn.gold { background: var(--gold); border-color: var(--gold); color: #fff; }
.btn.gold:hover { background: #9a784a; border-color: #9a784a; }

/* ===== Filter bar ===== */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: center; margin-bottom: 34px; }
.toolbar input, .toolbar select {
  font-family: var(--serif-body); font-size: .95rem; color: var(--ink);
  padding: 9px 14px; border: 1px solid var(--line); border-radius: 40px; background: var(--paper);
}
.toolbar input { min-width: 220px; }
.toolbar input:focus, .toolbar select:focus { outline: 2px solid var(--gold-soft); border-color: var(--gold); }

/* ===== Cellar by year ===== */
.year-group { margin-bottom: 52px; }
.year-head { display: flex; align-items: baseline; gap: 16px; margin-bottom: 22px; padding-bottom: 8px; border-bottom: 2px solid var(--gold-soft); }
.year-head .year-num { font-family: var(--serif-display); font-size: clamp(2rem, 3vw, 2.8rem); font-weight: 600; color: var(--maroon-deep); line-height: 1; }
.year-head .year-count { font-size: .82rem; text-transform: uppercase; letter-spacing: .18em; color: var(--gold); }

/* ===== Wine grid / cards ===== */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 30px; }
.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); transition: transform .18s, box-shadow .18s;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card .label-wrap { background: var(--cream-deep); padding: 18px; display: flex; align-items: center; justify-content: center; aspect-ratio: 4/3; }
.card .label-wrap img { max-height: 100%; width: auto; border-radius: 4px; box-shadow: 0 4px 14px rgba(0,0,0,.12); }
.card .card-body { padding: 18px 22px 22px; flex: 1; display: flex; flex-direction: column; text-align: center; }
.card .vintage { font-family: var(--serif-display); color: var(--gold); font-size: 1.25rem; letter-spacing: .1em; }
.card h3 { font-size: 1.7rem; margin: 2px 0 10px; color: var(--maroon-deep); line-height: 1.1; }
.card .meta { font-size: 1.05rem; color: var(--ink-soft); margin-top: auto; padding-top: 6px; }
.card .chips { margin-top: 12px; display: flex; gap: 7px; flex-wrap: wrap; justify-content: center; }
.chip { font-size: .82rem; letter-spacing: .04em; padding: 4px 13px; border-radius: 30px; background: var(--cream-deep); color: var(--maroon); border: 1px solid var(--line); }
.chip.type-White { background: #f3f4e9; color: #6b6a33; }
.chip.type-Blend { background: #f0e6ea; color: var(--maroon-soft); }

.empty-state { text-align: center; padding: 60px 0; color: var(--ink-soft); }

/* ===== Wine detail ===== */
.wine-detail { display: grid; grid-template-columns: minmax(280px, 420px) 1fr; gap: 56px; align-items: start; }
.wine-label-card { background: var(--cream-deep); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); position: sticky; top: 96px; }
.wine-label-card img { border-radius: 6px; box-shadow: var(--shadow-lg); width: 100%; }
.wine-head .eyebrow { margin-bottom: 8px; display: block; }
.wine-head h1 { margin-bottom: .1em; }
.wine-head .sub { font-size: 1.15rem; color: var(--ink-soft); font-style: italic; margin-bottom: 22px; }

.specs { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 2px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 26px 0; }
.spec { background: var(--paper); padding: 16px 18px; }
.spec .k { font-size: .68rem; text-transform: uppercase; letter-spacing: .14em; color: var(--gold); }
.spec .v { font-family: var(--serif-display); font-size: 1.5rem; color: var(--maroon-deep); }
.spec .v.empty { color: #c7bba2; font-size: 1.1rem; font-style: italic; }

.block { margin: 30px 0; }
.block h3 { border-bottom: 2px solid var(--gold-soft); padding-bottom: 6px; display: inline-block; }
.blend-bar { display: flex; height: 30px; border-radius: 30px; overflow: hidden; border: 1px solid var(--line); margin: 14px 0; }
.blend-seg { display: flex; align-items: center; justify-content: center; font-size: .72rem; color: #fff; white-space: nowrap; }
.blend-legend { display: flex; flex-wrap: wrap; gap: 16px; }
.blend-legend span { font-size: .9rem; display: flex; align-items: center; gap: 7px; }
.dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }

/* notes */
.note-list { display: grid; gap: 14px; margin: 16px 0; }
.note { background: var(--paper); border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: 8px; padding: 14px 18px; }
.note .who { font-family: var(--serif-display); color: var(--maroon); font-size: 1.1rem; }
.note-form { background: var(--cream-deep); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-top: 18px; }
.note-form .row { display: flex; gap: 12px; flex-wrap: wrap; }
.note-form input, .note-form textarea { width: 100%; font-family: var(--serif-body); font-size: 1rem; padding: 10px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); margin-bottom: 12px; }
.note-form textarea { min-height: 90px; resize: vertical; }

@media (max-width: 820px) {
  .wine-detail { grid-template-columns: 1fr; gap: 30px; }
  .wine-label-card { position: static; max-width: 360px; margin: 0 auto; }
}

/* ===== Through the years ===== */
.years-section { background: var(--cream-deep); border-top: 1px solid var(--line); }
.chart-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 26px; }
.chart-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.chart-card h4 { font-family: var(--serif-body); text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; color: var(--gold); margin-bottom: 4px; }
.chart-card .canvas-box { position: relative; height: 240px; }
.vintage-table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: .92rem; }
.vintage-table th, .vintage-table td { padding: 9px 12px; text-align: center; border-bottom: 1px solid var(--line); }
.vintage-table th { font-family: var(--serif-body); text-transform: uppercase; letter-spacing: .08em; font-size: .72rem; color: var(--gold); }
.vintage-table td.year { font-family: var(--serif-display); color: var(--maroon); font-size: 1.05rem; }

/* ===== Misc page elements ===== */
.prose { max-width: 760px; margin: 0 auto; padding: 0 24px; }
.prose p { font-size: 1.12rem; }
.lead-quote { font-family: var(--serif-display); font-size: 1.6rem; color: var(--maroon); font-style: italic; text-align: center; margin: 30px auto; max-width: 700px; }
.pairing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; }
.pairing { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.pairing h4 { color: var(--maroon-deep); font-size: 1.3rem; }

/* ===== Footer ===== */
.site-footer { background: var(--maroon-deep); color: var(--cream); padding: 44px 0; margin-top: 60px; }
.site-footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; align-items: center; }
.site-footer a { color: var(--gold-soft); }
.site-footer a:hover { color: #fff; }
.site-footer .f-brand { font-family: var(--serif-display); font-size: 1.4rem; }
.site-footer .f-nav { display: flex; gap: 20px; flex-wrap: wrap; font-size: .9rem; }
.site-footer small { opacity: .7; font-size: .8rem; }

.breadcrumb { font-size: .85rem; color: var(--ink-soft); margin-bottom: 18px; }
.breadcrumb a { color: var(--maroon); }
hr.rule { border: 0; border-top: 1px solid var(--line); margin: 40px 0; }

/* ===== Desktop scaling (large screens only; mobile <820px untouched) ===== */
@media (min-width: 1200px) {
  body { font-size: 21px; }
  .section { padding: 80px 0; }

  .hero { padding: 110px 24px 90px; }
  .hero img.crest { height: 240px; }
  .hero .lead { font-size: 1.5rem; max-width: 780px; }
  .hero .stat b { font-size: 3rem; }
  .hero .stat span { font-size: .85rem; }

  .toolbar { gap: 16px; margin-bottom: 44px; }
  .toolbar input, .toolbar select { font-size: 1.05rem; padding: 12px 18px; }
  .toolbar input { min-width: 280px; }

  .grid { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 36px; }
  .year-head .year-num { font-size: 3.2rem; }
  .card .card-body { padding: 20px 24px 24px; }
  .card .vintage { font-size: 1.35rem; }
  .card h3 { font-size: 1.95rem; }
  .card .meta { font-size: 1.12rem; }
  .chip { font-size: .9rem; padding: 5px 15px; }

  .wine-detail { grid-template-columns: minmax(340px, 500px) 1fr; gap: 72px; }
  .spec { padding: 20px 22px; }
  .spec .v { font-size: 1.75rem; }
  .chart-card .canvas-box { height: 280px; }
  .prose p { font-size: 1.2rem; }
}

@media (min-width: 1700px) {
  :root { --maxw: 1820px; }
  body { font-size: 23px; }
  .hero h1 { font-size: 4.4rem; }
  .hero img.crest { height: 290px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 42px; }
  .card h3 { font-size: 2.1rem; }
  .year-head .year-num { font-size: 3.6rem; }
}

/* ===== Footer: centered on mobile, larger text on desktop ===== */
@media (max-width: 820px) {
  .site-footer .container { flex-direction: column; text-align: center; gap: 18px; }
  .site-footer .f-nav { justify-content: center; }
}
@media (min-width: 1200px) {
  .site-footer { padding: 56px 0; }
  .site-footer .f-brand { font-size: 1.75rem; }
  .site-footer .f-nav { font-size: 1.08rem; gap: 28px; }
  .site-footer small { font-size: .98rem; }
}

/* ===== Note confirmation panel ===== */
.note-sent { background: var(--cream-deep); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-top: 18px; }
.note-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
