/* The Spiffy Dapper: the same paper, brass, type and marks as the main site. */
:root {
  --paper-2: #f2eee6;
  --paper-3: #ebe5d6;
  --ink-soft: #2a2a2c;
  --brass: #b8935a;
  --brass-deep: #856538;
  --brass-light: #d4b482;
  --content-width: 1088px;
  --page-gutter: max(32px, calc((100% - var(--content-width)) / 2));
}
html { scroll-padding-top: 104px; }
body { line-height: 1.65; -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4 { font-weight: 500; }
h1 em, h2 em, h3 em, h4 em { font-style: normal; font-weight: inherit; }
h2 { font-size: clamp(2.75rem, 4.4vw, 3.75rem); letter-spacing: -.025em; line-height: 1.08; }
a, button { transition: color .18s, background-color .18s, border-color .18s; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible { outline: 2px solid var(--brass-deep); outline-offset: 5px; }
.reading-progress { height: 2px; background: var(--brass); }
.overline, .eyebrow, .chapter-number, .lore-label { color: var(--brass-deep); font-size: .7rem; font-weight: 600; letter-spacing: .18em; }

.site-header { height: 80px; padding: 0 var(--page-gutter); gap: 32px; background: rgba(250,248,244,.9); backdrop-filter: saturate(140%) blur(10px); color: var(--ink); border-bottom: 1px solid var(--line); }
.site-header .brand { display: flex; flex: 0 0 auto; align-items: center; }
.site-header .brand img { display: block; width: auto; height: 48px; }
.site-header nav { gap: 25px; }
.site-header nav a { color: var(--ink-soft); font-size: .82rem; white-space: nowrap; }
.site-header nav a:hover, .site-header nav a[aria-current] { color: var(--brass-deep); }
.site-header nav .header-book { padding: 10px 18px; border-radius: 999px; background: var(--brass-deep); color: var(--paper); }
.site-header nav .header-book:hover { background: var(--ink); color: var(--paper); }
.menu-toggle { min-height: 40px; border: 1px solid var(--line); border-radius: 12px; background: transparent; color: var(--ink); font-size: .8rem; }
#mobile-nav { top: var(--header-height,80px); background: var(--paper); color: var(--ink); border-bottom: 1px solid var(--line); padding: 18px 24px 24px; box-shadow: 0 12px 24px #0e0e0f0a; }
#mobile-nav a { color: var(--ink); font-size: .9rem; }
#mobile-nav a:hover { color: var(--brass-deep); }
.mobile-bar-links { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 12px; display: flex; flex-wrap: wrap; gap: 28px; }

.hero { height: auto; min-height: 0; max-height: none; overflow: visible; isolation: auto; background: var(--paper); color: var(--ink); text-align: center; }
.hero-content { max-width: 840px; padding: 60px 24px 48px; margin: 0 auto; }
.hero .eyebrow { color: var(--brass-deep); margin-bottom: 28px; }
.hero-mark { display: block; width: 128px; height: auto; margin: 0 auto; }
.hero h1 { font-size: clamp(3.2rem, 5vw, 4.5rem); font-weight: 500; line-height: 1.02; letter-spacing: -.025em; margin: 32px 0 20px; }
.hero h1 em { color: var(--ink); }
.hero-description { font-size: 1rem; line-height: 1.7; color: var(--muted); max-width: 560px; margin: 0 auto 28px; }
.hero-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; }
.button { min-height: 44px; padding: 10px 21px; border: 1px solid var(--line); border-radius: 999px; font-size: .9rem; font-weight: 500; }
.button.light { margin-top: 0; background: var(--ink); border-color: var(--ink); color: var(--paper); }
.button.light:hover { background: var(--brass-deep); border-color: var(--brass-deep); }
.button-ghost { background: transparent; color: var(--ink); }
.button-ghost:hover { background: var(--paper-2); border-color: var(--brass); }
.deco-divider { display: block; margin: 42px auto 0; color: var(--brass); }
.guide-cover { position: relative; width: min(calc(100% - 64px), var(--content-width)); margin: 0 auto; overflow: hidden; border-radius: 16px; background: var(--ink); }
.guide-cover img { display: block; width: 100%; height: clamp(280px, 34vw, 420px); object-fit: cover; object-position: 68% center; }
.guide-cover::after { content: ''; position: absolute; inset: 55% 0 0; background: linear-gradient(transparent, #0e0e0fb3); pointer-events: none; }
.guide-cover figcaption { position: absolute; z-index: 1; bottom: 24px; left: 28px; right: 28px; color: var(--paper); font-size: .65rem; font-weight: 500; letter-spacing: .16em; }

.intro { padding: 80px var(--page-gutter); text-align: center; background: var(--paper); border-bottom-color: var(--line); }
.intro > .eyebrow { color: var(--brass-deep); margin-bottom: 24px; }
.intro > p:not(.eyebrow) { max-width: 840px; margin-left: auto; margin-right: auto; font-size: clamp(1.9rem, 3vw, 2.6rem); line-height: 1.4; letter-spacing: -.015em; }
.intro-bottom { justify-content: center; align-items: center; gap: 64px; margin-top: 32px; color: var(--muted); }
.intro-bottom a { color: var(--ink); }
.chapter { padding: 80px var(--page-gutter) 96px; }
.section-top, .history .section-top, .today .section-top { border-color: var(--line); }
.section-top > span:last-child, .today .section-top > span:last-child { color: var(--muted); }
.section-intro { gap: 10%; margin: 48px 0 58px; }
.section-intro > p, .today .section-intro > p { color: var(--muted); font-size: 1rem; }
.history, .gin, .sources { background: var(--paper); }
.today, .lab { background: var(--paper-2); color: var(--ink); }
.history-opening h3 { font-size: 2.15rem; }
.archive-copy h3 { font-size: clamp(2.3rem, 3.6vw, 3.25rem); line-height: 1.12; letter-spacing: -.02em; }
.archive-copy h3 em, .lore-copy h3 em { color: var(--brass-deep); }
.lore-copy h3 { font-size: clamp(2.1rem, 3.25vw, 2.9rem); letter-spacing: -.02em; }
.lore-copy summary, .lore-aside summary { line-height: 1.6; }
.lore-copy details p { color: var(--ink-soft); }
.archive-open { border: 1px solid var(--line); border-radius: 12px; }
.archive-open > span { border-radius: 999px; font-size: .65rem; padding: 8px 13px; }
.archive-figure figcaption { color: var(--muted); }
.archive-figure figcaption > a { color: var(--muted); }
.lore-art .archive-open { background: var(--paper-2); }
.bubbles-story .archive-open { background: var(--paper-3); }
.timeline-date { letter-spacing: -.02em; }
.timeline-main::before { border-color: var(--paper); }
.timeline-event h3 { font-size: 2rem; font-weight: 500; }
.segmented { border-radius: 999px; border-color: var(--line); }
.segmented button { border-radius: 999px; min-height: 40px; }
.segmented button:hover { background: var(--paper-3); }
.segmented button[aria-pressed=true] { background: var(--ink); color: var(--paper); }

.today .cite, .today .overline, .today .region-list article > span,
.comeback-opening aside > .overline, .comeback-opening aside em,
.fever-story .section-intro p:last-child, .bottle-journey article > span,
.spanish-story > h3 em, .spanish-formula > em, #garnish-result > span,
.instagram-story > p em { color: var(--brass-deep); }
.comeback-opening aside > p { color: var(--ink); }
.comeback-opening aside { border-color: var(--line); }
.comeback-opening h3 { font-size: 2.1rem; line-height: 1.25; }
.gin-passport { border: 1px solid var(--line); border-radius: 16px; background: var(--paper); padding: 8px; overflow: hidden; }
.passport-stops button { border-radius: 12px; color: var(--muted); }
.passport-stops button:hover { box-shadow: inset 0 0 0 1px var(--line); color: var(--ink); }
.passport-stops button[aria-pressed=true] { background: var(--ink); color: var(--paper); }
.passport-year { color: var(--brass-deep); }
#passport-story { min-height: 300px; }
#passport-story .overline { color: var(--brass-deep); }
.fever-story .section-intro h3 { font-size: clamp(2.8rem, 4.4vw, 3.8rem); letter-spacing: -.02em; }
.bottle-journey h4 { font-weight: 500; }
.spanish-story > h3 { font-size: clamp(2.6rem, 4vw, 3.6rem); letter-spacing: -.02em; }
.spanish-formula { border-color: var(--line); }
.garnish-choices button { background: var(--paper); color: var(--ink); border-color: var(--line); border-radius: 12px; min-height: 48px; }
.garnish-choices button::before { color: var(--brass-deep); }
.garnish-choices button:hover { background: var(--paper-3); }
.garnish-choices button[aria-pressed=true] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.garnish-choices button[aria-pressed=true]::before { color: var(--brass-light); }
.instagram-story { background: var(--paper); border-color: var(--line); border-radius: 16px; }
.instagram-story > p { font-size: 2.3rem; }
.definition-note { border-radius: 12px; border: 1px solid var(--line); background: var(--paper-2); }
.chip-group button { min-height: 42px; border-color: var(--line); }
.chip-group button:hover { background: var(--paper-3); }
.chip-group button[aria-pressed=true] { background: var(--ink); border-color: var(--ink); color: var(--paper); }

.calculator { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: 0 1px 2px #0e0e0f0a, 0 6px 18px -8px #0e0e0f14; }
.calc-controls { background: var(--paper); }
.calc-result { background: var(--ink); color: var(--paper); }
.calc-result > .overline { color: var(--brass-light); }
.abv-number { color: var(--brass-light); }
#ratio-summary, .composition-legend, .fineprint { color: #ddd7cc; }
.calc-equation { border-color: #ffffff30; }
.calc-equation > span { color: var(--brass-light); }
input[type=range] { accent-color: var(--brass-deep); }
select { border-color: var(--line); border-radius: 10px; background: var(--paper); min-height: 44px; }
.text-button { color: var(--brass-deep); border-color: var(--brass); }
.composition { border-radius: 999px; background: #242426; }
.science-panel { border-color: var(--line); border-radius: 16px; background: var(--paper); }
.market-footnote .market { border: 1px solid var(--line); border-radius: 12px; background: var(--paper-2); color: var(--ink); }
.market-footnote .stat, .market-footnote .market .cite { color: var(--brass-deep); }
.source-group, .source-group:last-child, .source-list li { border-color: var(--line); }
.source-list li:target { background: var(--paper-3); border-left: 2px solid var(--brass); }
.source-list a { font-weight: 500; }
#archive-dialog { border-radius: 16px; border: 1px solid var(--line); }
#archive-dialog::backdrop { background: #0e0e0fe6; }
.archive-dialog-head button { border-radius: 999px; }
#archive-dialog-image { border-radius: 8px; background: var(--paper-2); }

footer { display: block; background: var(--paper-2); color: var(--ink); padding: 64px var(--page-gutter) 24px; border-top: 1px solid var(--line); }
.footer-main { display: grid; grid-template-columns: 112px 1fr 220px; gap: 64px; align-items: start; }
.footer-brand img { display: block; width: 112px; height: auto; }
.footer-copy > .overline, .footer-links > .overline { font-size: .65rem; }
.footer-copy p { font-size: 2.5rem; line-height: 1.12; margin: 18px 0 22px; }
.footer-copy a { font-size: .875rem; }
.footer-links { display: grid; gap: 12px; }
.footer-links > .overline { margin-bottom: 8px; }
.footer-links a { font-size: .875rem; text-decoration: none; color: var(--muted); }
.footer-links a:hover { color: var(--brass-deep); }
.footer-bottom { border-top: 1px solid var(--line); padding-top: 24px; margin-top: 48px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: .75rem; color: var(--muted); }

@media (max-width: 1100px) {
  .site-header nav { gap: 18px; }
  .site-header nav a { font-size: .78rem; }
  .site-header nav .header-book { padding-left: 14px; padding-right: 14px; }
}
@media (max-width: 900px) {
  .site-header { min-height: 72px; height: 72px; padding: 0 24px; }
  .site-header .brand img { height: 42px; }
  .site-header nav { display: none; }
  .menu-toggle { display: block; }
  .footer-main { gap: 36px; grid-template-columns: 100px 1fr 190px; }
}
@media (max-width: 760px) {
  :root { --page-gutter: 20px; }
  html { scroll-padding-top: 92px; }
  .hero-content { padding: 42px 20px 36px; }
  .hero .eyebrow { font-size: .62rem; letter-spacing: .16em; margin-bottom: 25px; }
  .hero-mark { width: 104px; }
  .hero h1 { font-size: 3.25rem; line-height: 1.03; margin: 26px 0 18px; }
  .hero-description { font-size: .9rem; max-width: 350px; margin-bottom: 25px; }
  .hero-actions { gap: 10px; }
  .hero-actions .button { padding: 10px 17px; font-size: .8rem; }
  .deco-divider { margin-top: 32px; }
  .guide-cover { width: calc(100% - 40px); border-radius: 12px; }
  .guide-cover img { height: 270px; object-position: 65% center; }
  .guide-cover figcaption { left: 18px; right: 18px; bottom: 18px; font-size: .55rem; letter-spacing: .12em; }
  .intro { padding: 56px 24px; }
  .intro > p:not(.eyebrow) { font-size: 2rem; line-height: 1.35; }
  .intro-bottom { display: block; margin-top: 28px; font-size: .8rem; }
  .intro-bottom a { margin-top: 20px; }
  .chapter { padding: 56px 20px 64px; }
  .section-top { font-size: .6rem; }
  .chapter-number, .lore-label, .overline { font-size: .62rem; letter-spacing: .14em; }
  .section-intro { margin: 36px 0 42px; gap: 24px; }
  h2, .history .section-intro h2 { font-size: 2.75rem; }
  .history-opening h3 { font-size: 2.05rem; }
  .archive-copy h3 { font-size: 2.6rem; }
  .lore-copy h3 { font-size: 2.3rem; }
  .lore-copy > p, .timeline-event p { font-size: .95rem; }
  .lore-copy details { font-size: .82rem; }
  .archive-open > span { font-size: .6rem; }
  .timeline-event h3 { font-size: 1.9rem; }
  .comeback-opening h3 { font-size: 1.9rem; }
  #passport-story { min-height: 0; padding: 26px 18px; }
  #passport-story h3 { font-size: 2rem; }
  .fever-story .section-intro h3 { font-size: 3rem; }
  .spanish-story > h3 { font-size: 2.65rem; }
  .instagram-story { padding: 25px; }
  .instagram-story > p { font-size: 2rem; }
  .calc-controls, .calc-result { padding: 28px 22px; }
  .source-header h3 { font-size: 1.8rem; }
  footer { padding: 48px 24px 24px; }
  .footer-main { grid-template-columns: 82px 1fr; gap: 32px; }
  .footer-brand img { width: 82px; }
  .footer-copy p { font-size: 2rem; }
  .footer-copy > .overline { font-size: .58rem; }
  .footer-copy a { font-size: .78rem; }
  .footer-links { grid-column: 1 / -1; grid-template-columns: 1fr 1fr; gap: 14px 20px; }
  .footer-links > .overline { grid-column: 1 / -1; }
  .footer-links a { font-size: .8rem; }
  .footer-bottom { display: grid; margin-top: 32px; padding-top: 20px; font-size: .68rem; }
}
