/* Java House coffee: components. Tokens only, except the per-coffee colours the script sets on .stage. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 124px; }
body { margin: 0; background: var(--roast); color: var(--fg-on-deep); font-family: var(--font-body); font-size: var(--t-body); line-height: 1.55; font-weight: 400; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }

.wrap { width: 100%; max-width: calc(var(--max) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: var(--section) 0; }
.section--paper { background: var(--bg); color: var(--fg); }
.section--roast { background: var(--roast); color: var(--fg-on-deep); }
.section--roast .quiet { color: var(--fg-on-deep-quiet); }
.section--paper .quiet { color: var(--fg-quiet); }
.cols { display: grid; grid-template-columns: var(--grid-2); gap: var(--head-gap) var(--col-gap); align-items: start; }
.head { display: flex; flex-direction: column; gap: var(--s-4); margin-bottom: var(--head-gap); }
.cols > .head { margin-bottom: 0; }
.stack { display: flex; flex-direction: column; gap: var(--s-5); }

.label { font-size: var(--t-small); font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; line-height: 1.6; }
.h2 { font-family: var(--font-display); font-weight: 400; font-size: var(--t-h2); line-height: 0.95; letter-spacing: -0.02em; max-width: 14em; }
.h3 { font-family: var(--font-body); font-weight: 600; font-size: var(--t-h3); line-height: 1.15; letter-spacing: -0.01em; }
.lead { font-size: var(--t-lead); line-height: 1.45; max-width: 30em; }

.concept { margin: 0; padding: var(--s-1) var(--gutter); color: var(--fg-on-deep-quiet); font-size: 11px; line-height: 1.6; text-align: center; overflow: hidden; max-height: 40px; transition: max-height .4s ease, opacity .3s ease, padding .4s ease; }
.site-head.is-scrolled .concept { max-height: 0; opacity: 0; padding-top: 0; padding-bottom: 0; }

/* Lines break evenly: no single word left alone */
h1, h2, h3, .lead, .footer__line, .close__title, .ritual__big, .label, .coffee__notes { text-wrap: balance; }
p, li, dd { text-wrap: pretty; }

/* ---------- Loading: the Java sun on dark grain ---------- */
.loader { position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s-6); background: var(--roast); transition: opacity .7s ease, visibility 0s linear .7s; }
.loader::after { content: ""; position: absolute; inset: 0; opacity: 0.55; mix-blend-mode: overlay; pointer-events: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E"); }
.loader__mark { width: 112px; height: auto; animation: sun 14s linear infinite; }
@keyframes sun { to { transform: rotate(360deg); } }
.loader__bar { position: relative; display: block; width: 120px; height: 1px; background: var(--line-on-deep); overflow: hidden; }
.loader__bar span { position: absolute; inset: 0; background: var(--cream); transform-origin: 0 50%; transform: scaleX(0); transition: transform .4s ease; }
.loader.is-done { opacity: 0; visibility: hidden; }
/* safety net: if the script never runs, the loader still lifts */
.loader { animation: loader-out .6s ease 8s forwards; }
@keyframes loader-out { to { opacity: 0; visibility: hidden; } }
.loader.is-done .loader__mark { transform: scale(.9); transition: transform .7s ease; }

/* ---------- Site header: logo left, two quiet controls right ---------- */
.site-head { position: fixed; top: 0; left: 0; right: 0; z-index: 40; pointer-events: none; }
.site-head__row { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); padding-top: var(--s-3); padding-bottom: var(--s-3); }
.site-head a, .site-head button, .site-head .concept { pointer-events: auto; }
.site-head__logo { flex-shrink: 0; display: inline-flex; align-items: center; min-height: var(--control); padding: 0 var(--s-4); border-radius: 24px; background: var(--roast); }
.site-head__logo img { height: 20px; width: auto; }
.site-head__right { display: flex; gap: var(--s-2); }
.pill { display: inline-flex; align-items: center; gap: var(--s-2); min-height: var(--control); padding: 0 var(--s-5); border: 0; border-radius: 24px; font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color .2s ease, color .2s ease, transform .15s ease; }
.pill:active { transform: scale(.97); }
.pill--solid { background: var(--cream); color: var(--roast); }
.pill--solid:hover { background: #fff; }
.pill--menu { background: var(--roast); color: var(--cream); }
.pill--menu:hover { background: var(--roast); }
.pill__icon { display: inline-flex; flex-direction: column; gap: 4px; width: 16px; }
.pill__icon i { display: block; height: 1.5px; background: currentColor; transition: transform .3s ease; }
.pill--menu[aria-expanded="true"] .pill__icon i:first-child { transform: translateY(2.75px) rotate(45deg); }
.pill--menu[aria-expanded="true"] .pill__icon i:last-child { transform: translateY(-2.75px) rotate(-45deg); }

/* ---------- Full-screen menu ---------- */
.menu { position: fixed; inset: 0; z-index: 35; background: var(--roast); color: var(--cream); overflow-y: auto; }
.menu::after { content: ""; position: absolute; inset: 0; opacity: 0.5; mix-blend-mode: overlay; pointer-events: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E"); }
.menu:not([hidden]) { animation: menu-in .45s cubic-bezier(.2, .7, .2, 1); }
@keyframes menu-in { from { opacity: 0; transform: translateY(-12px); } }
.menu__in { position: relative; z-index: 1; display: grid; grid-template-columns: var(--grid-2); gap: var(--s-7) var(--col-gap); padding-top: 120px; padding-bottom: var(--s-8); min-height: 100%; align-content: center; }
.menu__list { display: flex; flex-direction: column; }
.menu__list a { display: flex; align-items: baseline; gap: var(--s-4); padding: var(--s-3) 0; font-family: var(--font-display); font-size: clamp(40px, 7vw, 96px); line-height: 0.95; text-transform: uppercase; text-decoration: none; border-bottom: 1px solid var(--line-on-deep); transition: color .2s ease, padding-left .3s cubic-bezier(.2, .7, .2, 1); }
.menu__list a:hover { padding-left: var(--s-4); color: #fff; }
.menu__no { font-family: var(--font-body); font-size: var(--t-small); font-weight: 600; letter-spacing: 0.14em; color: var(--fg-on-deep-quiet); }
.menu__side { display: flex; flex-direction: column; gap: var(--s-4); }
.menu__side .label { color: var(--fg-on-deep-quiet); }
.menu__coffees { display: flex; flex-direction: column; }
.menu__coffees button { width: 100%; min-height: var(--control); padding: 0; border: 0; border-bottom: 1px solid var(--line-on-deep); background: none; color: var(--cream); font-size: var(--t-lead); font-weight: 500; text-align: left; cursor: pointer; }
.menu__coffees button:hover { color: #fff; }
.menu__mark { width: 72px; height: auto; margin-top: var(--s-6); opacity: 0.9; }

/* The jump back: the page shrinks to a card on black, cuts to the top, then zooms back */
html.is-jumping body { background: var(--paper); }
.site-head { transition: opacity .3s ease; }
html.is-jumping .site-head { opacity: 0; }
.page { position: relative; background: var(--roast); }
.giant.no-roll .ch { transition: none !important; }
.stage.is-intro.is-replay .stage__bg { opacity: 1; }

/* ---------- The loop: keep scrolling at the very bottom to fly back to the first bag ---------- */
.loop { display: flex; align-items: center; justify-content: center; gap: var(--s-4); padding: var(--s-7) 0 var(--s-6); color: var(--fg-on-deep-quiet); font-size: 14px; }
.loop__ring { position: relative; width: 44px; height: 44px; flex-shrink: 0; }
.loop__ring svg { width: 44px; height: 44px; transform: rotate(-90deg); }
.loop__ring circle { fill: none; stroke: var(--line-on-deep); stroke-width: 1.5; }
.loop__ring .loop__fill { stroke: var(--cream); stroke-dasharray: 125.7; stroke-dashoffset: calc(125.7 * (1 - var(--loop, 0))); }
.loop__ring img { position: absolute; left: 12px; top: 12px; width: 20px; height: 20px; }



/* ---------- The stage: one pinned screen, four coffees ---------- */
.stage { position: relative; height: calc(100svh * 6.6); color: var(--fg-on-deep);
  --c-hi: #1B3D66; --c-base: var(--kenya); --c-lo: #081830;
  --n-hi: #7E2318; --n-base: var(--yirga); --n-lo: #3B0B08;
  --wipe: 0%; }
.stage__pin { position: sticky; top: 0; height: 100svh; min-height: 560px; overflow: hidden; isolation: isolate; }
.stage__bg, .stage__wipe, .stage__grain { position: absolute; inset: 0; z-index: -1; }
.stage__bg { background: radial-gradient(ellipse 60% 70% at 50% 60%, var(--c-hi) 0%, var(--c-base) 55%, var(--c-lo) 100%); }
.stage__wipe { background: radial-gradient(ellipse 60% 70% at 50% 60%, var(--n-hi) 0%, var(--n-base) 55%, var(--n-lo) 100%); clip-path: circle(var(--wipe) at 50% 58%); }
/* Java's own pattern down both edges, like the sides of the bag; the next coffee's pattern arrives with its colour */
.stage__bg::before, .stage__bg::after, .stage__wipe::before, .stage__wipe::after { content: ""; position: absolute; top: 0; bottom: 0; width: var(--edge-w); background-repeat: repeat-y; background-size: 100% auto; opacity: 0.3; }
.stage__bg::before, .stage__bg::after { background-image: var(--edge-c); }
.stage__wipe::before, .stage__wipe::after { background-image: var(--edge-n); }
.stage__bg::before, .stage__wipe::before { left: 0; }
.stage__bg::after, .stage__wipe::after { right: 0; transform: scaleX(-1); }
.stage { --edge-w: 12px; }

/* Pattern dividers between sections */
.band { height: 20px; background-repeat: repeat-x; background-size: auto 100%; }
.band--kenya { background-image: url("../assets/patterns/kenya-aa-h.webp"); }
.band--yirga { background-image: url("../assets/patterns/yirgacheffe-h.webp"); }
.band--kivu { background-image: url("../assets/patterns/lake-kivu-h.webp"); }
.band--arabica { background-image: url("../assets/patterns/arabica-kenya-h.webp"); }

.stage__grain { opacity: 0.6; mix-blend-mode: overlay; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E"); }

.nav { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; justify-content: space-between; gap: var(--s-5); min-height: 72px; z-index: 3; }
.nav__logo { display: inline-flex; align-items: center; min-height: var(--control); }
.nav__logo img { height: 22px; width: auto; }
.nav__links { display: none; gap: var(--s-6); font-size: 14px; font-weight: 500; }
.nav__links a { text-decoration: none; display: inline-flex; align-items: center; min-height: var(--control); }
.nav__links a:hover { text-decoration: underline; text-underline-offset: 6px; }

.stage__head { position: absolute; top: 88px; left: 0; right: 0; z-index: 3; text-align: center; pointer-events: none; }
.tag { font-family: var(--font-body); font-weight: 500; font-size: var(--t-body); line-height: 1.3; letter-spacing: 0.01em; max-width: 36em; margin: 0 auto; }

/* Arrival: chrome rises in once the bag has landed (script removes .is-intro) */
.stage__bg { transition: opacity 1s ease; }
.stage.is-intro .stage__bg { opacity: 0; }
.nav, .stage__head, .stage__info, .stage__foot { transition: opacity .8s ease, transform .9s cubic-bezier(.2, .7, .2, 1); }
.stage.is-intro .nav, .stage.is-intro .stage__head, .stage.is-intro .stage__info, .stage.is-intro .stage__foot { opacity: 0; transform: translateY(14px); }
.stage__head { transition-delay: .1s; } .stage__info { transition-delay: .2s; } .stage__foot { transition-delay: .3s; }

/* The coffee in your hand, full width; the bag floats in front of it (owner's exception, see DECISIONS) */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.giant { position: absolute; left: 0; right: 0; top: 24%; z-index: 0; margin: 0; display: grid; justify-items: center; font-family: var(--font-display); font-weight: 400; font-size: var(--t-display); line-height: 0.84; letter-spacing: -0.02em; text-transform: uppercase; white-space: nowrap; overflow: hidden; padding-top: 0.06em; pointer-events: none; }
.giant__name { grid-area: 1 / 1; }
.giant .ch { display: inline-block; transition: transform .7s cubic-bezier(.2, .7, .2, 1); transition-delay: calc(var(--k) * 24ms); }
.giant__name.is-above .ch { transform: translateY(-110%); }
.giant__name.is-below .ch { transform: translateY(110%); }

.stage__bag { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.scene { position: fixed; inset: 0; z-index: 20; pointer-events: none; }
.bag__canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; transition: opacity .35s ease; }
.bag__fallback { display: none; position: absolute; left: 50%; top: 52%; height: 44%; width: auto; transform: translate(-50%, -50%); filter: drop-shadow(0 36px 40px rgba(0, 0, 0, 0.5)); }
.scene.no-webgl .bag__fallback { display: block; }
.scene.no-webgl .bag__canvas, .scene.no-webgl .beans__front { display: none; }
.bag__shadow { position: absolute; left: 50%; top: 84%; width: 220px; height: 24px; margin-left: -110px; border-radius: 50%; background: rgba(0, 0, 0, 0.45); filter: blur(12px); }
.beans__front { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; filter: blur(6px); }

.stage__info { position: absolute; left: 0; right: 0; bottom: 120px; z-index: 2; }
.info { display: grid; }
.coffee { grid-area: 1 / 1; display: flex; flex-direction: column; gap: var(--s-4); opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s; }
.coffee.is-on.is-back { opacity: 1; visibility: visible; transform: none; transition: opacity .45s ease .2s, transform .55s cubic-bezier(.2, .7, .2, 1) .2s, visibility 0s; }
.coffee__story { display: flex; flex-direction: column; gap: var(--s-3); }
.coffee__name { font-family: var(--font-name); }
.coffee__say { font-size: var(--t-body); line-height: 1.5; color: var(--fg-on-deep-quiet); max-width: 22em; }
.coffee__notes { color: var(--fg-on-deep); }

.facts { display: none; }
.coffee.is-back .facts { display: grid; }
.facts div { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: var(--s-3); align-items: center; padding: var(--s-2) 0; border-top: 1px solid var(--line-on-deep); font-size: 14px; line-height: 1.4; opacity: 0; transform: translateY(8px); transition: opacity .35s ease, transform .35s ease; }
.facts div:last-child { border-bottom: 1px solid var(--line-on-deep); }
.facts dt { font-size: var(--t-small); font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; }
.coffee.is-back .facts div { opacity: 1; transform: none; }
.facts div:nth-child(2), .facts div:nth-child(4) { display: none; }

.dots { display: inline-flex; gap: var(--s-1); vertical-align: middle; }
.dots i { width: 10px; height: 10px; border-radius: 50%; background: currentColor; }
.dots i.off { background: none; box-shadow: inset 0 0 0 1.5px currentColor; }

.stage__foot { position: absolute; left: 0; right: 0; bottom: var(--s-4); z-index: 3; display: flex; align-items: center; justify-content: space-between; gap: var(--s-5); }
.foot__scroll { white-space: nowrap; }
.foot__progress { display: flex; justify-content: flex-end; min-width: 120px; }
.progress { position: relative; display: block; width: 120px; height: 1px; background: var(--line-on-deep); }
.progress__bar { position: absolute; left: 0; top: 0; height: 1px; width: 100%; background: var(--cream); transform-origin: 0 50%; transform: scaleX(0); }
.picker { display: none; gap: var(--s-1); }
.picker__item { min-height: 44px; padding: 0 var(--s-4); border: 0; border-radius: 22px; background: none; color: var(--fg-on-deep-quiet); font-size: 14px; font-weight: 500; white-space: nowrap; cursor: pointer; transition: color .2s ease, box-shadow .2s ease; }
.picker__item:hover { color: var(--cream); }
.picker__item[aria-current="true"] { color: var(--cream); box-shadow: inset 0 0 0 1px var(--line-on-deep); }
.foot__buy { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.foot__buy:hover { text-decoration: underline; text-underline-offset: 6px; }

/* ---------- Sections after the stage ---------- */
.origins { position: relative; background: var(--roast); color: var(--fg-on-deep); padding: var(--section) 0; overflow: hidden; }
.bag-spot { position: absolute; width: 1px; pointer-events: none; }
.bag-spot--origins { right: 7%; bottom: 22%; height: 34vh; }
.ritual__in { position: relative; }
.bag-spot--ritual { right: var(--gutter); top: 0; height: 30vh; }
.lineup__item img { transition: opacity .3s ease, transform .5s cubic-bezier(.2, .7, .2, 1); }
.lineup__item img.is-hidden { opacity: 0; }
.origins__in { display: grid; grid-template-columns: var(--grid-2); gap: var(--head-gap) var(--col-gap); align-items: center; }
.origins__copy { display: flex; flex-direction: column; gap: var(--s-4); }
.origins__list { display: flex; flex-direction: column; margin-top: var(--s-5); border-top: 1px solid var(--line-on-deep); }
.origin { display: flex; flex-direction: column; align-items: flex-start; gap: var(--s-1); width: 100%; min-height: 64px; padding: var(--s-4) 0 var(--s-4) var(--s-5); border: 0; border-bottom: 1px solid var(--line-on-deep); background: none; text-align: left; cursor: pointer; position: relative; transition: padding-left .35s cubic-bezier(.2, .7, .2, 1); }
.origin::before { content: ""; position: absolute; left: 0; top: 50%; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; background: var(--tone, var(--cream)); opacity: .35; transition: opacity .3s ease, transform .3s ease; }
.origin__name { font-family: var(--font-body); font-weight: 600; font-size: var(--t-h3); line-height: 1.15; color: var(--fg-on-deep-quiet); transition: color .3s ease; }
.origin__where { font-size: 14px; color: var(--fg-on-deep-quiet); }
.origin:hover .origin__name, .origin[aria-pressed="true"] .origin__name { color: var(--cream); }
.origin[aria-pressed="true"] { padding-left: var(--s-6); }
.origin[aria-pressed="true"]::before { opacity: 1; transform: scale(1.3); }
.origins__map { margin: 0; }
.map { width: 100%; height: auto; display: block; overflow: visible; }
.map .dots { fill: none; stroke-linecap: round; }
.map .dots--other { stroke: rgba(243, 236, 223, 0.14); }
.map .dots--country { stroke: rgba(243, 236, 223, 0.42); transition: stroke .5s ease, opacity .5s ease; }
.map .dots--country.is-on { stroke: var(--tone); }
.map .country-label { font-family: var(--font-body); font-size: 15px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; fill: rgba(243, 236, 223, 0.7); transition: fill .4s ease; }
.map .country-label.is-on { fill: var(--cream); }
.map .pin { opacity: 0; transition: opacity .4s ease; }
.map .pin.is-on { opacity: 1; }
.map .pin circle { fill: var(--cream); }
.map .pin .pin__ring { fill: none; stroke: var(--cream); stroke-width: 1.5; }
.map .pin text { font-family: var(--font-name); font-size: 20px; fill: var(--cream); }

.ritual { background: var(--paper); color: var(--ink); padding: var(--section) 0; }
.ritual__head { display: flex; flex-direction: column; gap: var(--s-4); margin-bottom: var(--s-7); max-width: 40em; }
.ritual .quiet { color: var(--fg-quiet); }
.ritual__tabs { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-7); }
.ritual__tab { min-height: var(--control); padding: 0 var(--s-5); border: 1px solid var(--line); border-radius: 24px; background: none; color: var(--ink); font-size: 15px; font-weight: 500; white-space: nowrap; cursor: pointer; transition: background-color .25s ease, color .25s ease, border-color .25s ease; }
.ritual__tab:hover { border-color: var(--ink); }
.ritual__tab[aria-selected="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.ritual__panel { display: grid; grid-template-columns: var(--grid-2); gap: var(--head-gap) var(--col-gap); align-items: start; }
.ritual__panel[hidden] { display: none; }
.ritual__panel:not([hidden]) { animation: rise .6s cubic-bezier(.2, .7, .2, 1); }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }
.ritual__big { font-family: var(--font-display); font-weight: 400; font-size: clamp(40px, calc((100vw - 2 * var(--gutter)) / 4.8), 152px); line-height: 0.86; letter-spacing: -0.025em; text-transform: uppercase; color: var(--ink); }
.steps { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.steps li { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: var(--s-4); padding: var(--s-5) 0; border-bottom: 1px solid var(--line); font-size: var(--t-lead); line-height: 1.45; }
.steps__no { font-size: var(--t-small); font-weight: 600; letter-spacing: 0.14em; line-height: 2.4; color: var(--fg-quiet); }

/* Headlines rise in as they enter */
[data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .9s cubic-bezier(.2, .7, .2, 1); }
[data-reveal].is-in { opacity: 1; transform: none; }

.close { background: var(--roast); color: var(--fg-on-deep); padding: var(--section) 0 0; }
.close__head { display: flex; flex-direction: column; align-items: center; gap: var(--s-4); text-align: center; margin-bottom: var(--head-gap); }
.close__title { font-family: var(--font-display); font-weight: 400; font-size: clamp(44px, 8vw, 128px); line-height: 0.9; letter-spacing: -0.025em; text-transform: uppercase; max-width: 10em; }
.close .lead { color: var(--fg-on-deep-quiet); }
.lineup { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.lineup__item { position: relative; display: flex; flex-direction: column; align-items: center; gap: var(--s-2); padding: var(--s-7) var(--s-4) var(--s-6); text-align: center; background: radial-gradient(ellipse 70% 60% at 50% 42%, var(--hi) 0%, var(--base) 60%, var(--lo) 100%); }
.lineup__item--kenya { --hi: #1B3D66; --base: #0F2846; --lo: #081830; }
.lineup__item--yirga { --hi: #7E2318; --base: #5B1410; --lo: #3B0B08; }
.lineup__item--kivu { --hi: #17585A; --base: #0D3D3E; --lo: #072627; }
.lineup__item--arabica { --hi: #8C6A17; --base: #6A4C0D; --lo: #45300A; }
.lineup__item img { width: auto; height: 220px; margin-bottom: var(--s-5); filter: drop-shadow(0 28px 28px rgba(0, 0, 0, 0.45)); transition: transform .5s cubic-bezier(.2, .7, .2, 1); }
.lineup__item:hover img { transform: translateY(-8px); }
.lineup__name { font-family: var(--font-body); font-weight: 600; font-size: var(--t-h3); line-height: 1.1; letter-spacing: -0.01em; }
.lineup__notes span + span::before { content: "· "; }
.lineup__meta { font-size: 14px; color: var(--fg-on-deep-quiet); }
.close__foot { padding: var(--s-6) var(--gutter); text-align: center; }
.close__foot .quiet { color: var(--fg-on-deep-quiet); font-size: 14px; }

.footer { background: var(--roast); color: var(--fg-on-deep); padding: var(--section) 0 var(--s-6); overflow: hidden; }
.footer__line { font-family: var(--font-display); font-weight: 400; font-size: clamp(56px, 11.5vw, 184px); line-height: 0.86; letter-spacing: -0.02em; text-transform: uppercase; margin-bottom: var(--s-8); }
.footer__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-7) var(--col-gap); padding: var(--s-7) 0; border-top: 1px solid var(--line-on-deep); }
.footer__brand { grid-column: 1 / -1; display: flex; flex-direction: column; align-items: flex-start; gap: var(--s-4); }
.footer__brand img { height: 26px; width: auto; }
.footer .quiet { color: var(--fg-on-deep-quiet); font-size: var(--t-body); max-width: 24em; }
.footer__col { display: flex; flex-direction: column; gap: var(--s-2); font-size: var(--t-body); }
.footer__col .label { color: var(--fg-on-deep-quiet); margin-bottom: var(--s-2); }
.footer__col a { text-decoration: none; display: inline-flex; align-items: center; min-height: 32px; }
.footer__col a:hover { text-decoration: underline; text-underline-offset: 6px; }
.footer__col span { display: inline-flex; align-items: center; min-height: 32px; }
.footer__top { justify-content: flex-start; }
.footer__up { display: inline-flex; align-items: center; justify-content: center; min-height: var(--control); padding: 0 var(--s-5); border: 1px solid var(--line-on-deep); border-radius: 24px; text-decoration: none; white-space: nowrap; transition: background-color .2s ease, color .2s ease; }
.footer__up:hover { background: var(--cream); color: var(--roast); text-decoration: none; }
.footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-2) var(--s-5); padding-top: var(--s-5); border-top: 1px solid var(--line-on-deep); font-size: 13px; color: var(--fg-on-deep-quiet); }

/* ---------- Wider screens: one centre line, story left, facts right ---------- */
@media (min-width: 768px) {
  .stage { --edge-w: 20px; }
  .band { height: 24px; }
  .nav__links { display: flex; }
  .tag { font-size: var(--t-lead); }
  .giant { top: 31%; }
  .stage__info { top: 55%; bottom: auto; }
  .coffee { display: grid; grid-template-columns: minmax(0, 300px) 1fr minmax(0, 300px); align-items: start; }
  .coffee__story { grid-column: 1; }
  .facts { display: grid; grid-column: 3; }
  .facts div, .facts div:nth-child(2), .facts div:nth-child(4) { display: grid; }
  .coffee.is-back .facts div { opacity: 1; transform: none; }
  .coffee.is-back .facts div:nth-child(2) { transition-delay: .26s; }
  .coffee.is-back .facts div:nth-child(3) { transition-delay: .32s; }
  .coffee.is-back .facts div:nth-child(4) { transition-delay: .38s; }
  .coffee.is-back .facts div:nth-child(5) { transition-delay: .44s; }
  .stage__foot { bottom: var(--s-5); }
}

@media (min-width: 1024px) {
  .ritual__big { font-size: min(140px, calc((100vw - 2 * var(--gutter) - var(--col-gap)) * 5 / 12 / 4.8)); }
  .menu__in { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); align-items: end; }
  .footer__grid { grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); }
  .footer__brand { grid-column: auto; }
  .footer__top { align-items: flex-end; }
  .stage { --edge-w: 28px; }
  .lineup { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .lineup__item img { height: 320px; }
  .picker { display: flex; }
  .coffee__say { font-size: var(--t-lead); }
}

@media (max-width: 767px) {
  .lineup__notes span { display: block; }
  .lineup__notes span + span::before { content: none; }
  .pill { padding: 0 var(--s-4); font-size: 13px; }
  .site-head__logo { padding: 0 var(--s-3); }
  .site-head__logo img { height: 16px; }
  .bag-spot--ritual { display: none; }
  .origins { padding-bottom: var(--bag-lane); }
  .bag-spot--origins { right: 50%; bottom: 32px; height: 240px; }
  .lineup { grid-template-columns: minmax(0, 1fr); }
  .lineup__item img { height: 240px; }
  .giant { top: 14.5%; }
  .stage__info { bottom: 72px; }
  .coffee__say { display: none; }
  .coffee { gap: var(--s-2); }
  .beans__front { display: none; }
  .foot__scroll { display: none; }
  .stage__foot { justify-content: center; }
  .foot__buy { white-space: nowrap; }
  .progress { width: 120px; }
}

@media (prefers-reduced-motion: reduce) {
  .loader__mark { animation: none; }
  .menu:not([hidden]) { animation: none; }
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  .ritual__panel:not([hidden]) { animation: none; }
  .origin, .origin::before, .map .dots--country, .map .pin, .ritual__tab { transition: none; }
  .coffee, .coffee.is-on.is-back, .facts div, .giant .ch, .picker__item, .nav, .stage__head, .stage__info, .stage__foot, .stage__bg, .lineup__item img { transition: none; }
}
