/* Snugbury Paper Co. — one stylesheet. Tokens first; see DESIGN.md for the reasoning. */
@font-face { font-family: "Playfair Display"; src: url("fonts/playfair-display-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Playfair Display"; src: url("fonts/playfair-display-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Playfair Display"; src: url("fonts/playfair-display-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Lato"; src: url("fonts/lato-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Lato"; src: url("fonts/lato-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Lato"; src: url("fonts/lato-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }

:root {
  --paper: #FBF6EC;
  --paper-2: #F4ECDB;
  --ink: #2B2B2B;
  --ink-soft: #4A463F;
  --holly: #B3262E;
  --holly-dark: #8E1C23;
  --pine: #1F4D3A;
  --pine-dark: #163A2B;
  --gold: #C9A44C;
  --rule: #E2D6BD;
  --display: "Playfair Display", Georgia, "Times New Roman", serif;
  --text: "Lato", "Helvetica Neue", Arial, sans-serif;
  --wrap: 1240px;
  --gutter: clamp(20px, 4.5vw, 56px);
  --ease: cubic-bezier(.22, .61, .36, 1);
  --radius: 4px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 1.0625rem/1.6 var(--text);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--pine); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--pine-dark); }
:focus-visible { outline: 3px solid var(--pine); outline-offset: 3px; border-radius: 2px; }
.sale :focus-visible, .free-band :focus-visible, .band :focus-visible { outline-color: #FBF6EC; }
.btn:focus-visible { outline-offset: 4px; }
.window:focus-visible, .free-card:focus-visible, .pc:focus-visible, .occ:focus-visible, .hero-photo:focus-visible { outline: 3px solid var(--pine); outline-offset: 6px; border-radius: 10px; }
.free-band .free-card:focus-visible { outline-color: #FBF6EC; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; color: var(--pine); margin: 0; letter-spacing: -.01em; }
h1 { font-size: clamp(2.5rem, 5.6vw, 4.75rem); line-height: 1.04; }
h2 { font-size: clamp(1.85rem, 3.4vw, 2.9rem); line-height: 1.1; }
h3 { font-size: 1.3rem; line-height: 1.25; }
h1 + p, h1 + .lead { margin-top: .55em; }
h2 + p, h2 + .lead { margin-top: .5em; }
p { margin: 0 0 1em; max-width: 64ch; }
.lead { font-size: clamp(1.1rem, 1.5vw, 1.25rem); line-height: 1.55; color: var(--ink-soft); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--pine); color: #fff; padding: 8px 14px; z-index: 50; }
.skip:focus { left: 8px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 52px; padding: .8em 1.5em; border-radius: 999px; border: 1.5px solid transparent;
  font: 700 1rem/1.1 var(--text); letter-spacing: .01em; text-decoration: none; cursor: pointer;
  transition: background-color .18s var(--ease), color .18s var(--ease), border-color .18s var(--ease), transform .12s var(--ease);
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn-buy { background: var(--holly); color: #fff; }
.btn-buy:hover { background: var(--holly-dark); color: #fff; }
.btn-main { background: var(--pine); color: #fff; }
.btn-main:hover { background: var(--pine-dark); color: #fff; }
.btn-quiet { border-color: currentColor; color: var(--pine); background: transparent; }
.btn-quiet:hover { background: var(--pine); border-color: var(--pine); color: #fff; }
.btn-light { background: var(--paper); color: var(--pine); }
.btn-light:hover { background: #fff; color: var(--pine-dark); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.btn-wide { width: 100%; }

/* ---------- sale strip + header ---------- */
.sale { background: var(--pine); color: #F3EBD8; font-size: .95rem; }
.sale .wrap { padding-block: .55em; display: flex; gap: .75em; align-items: center; justify-content: center; flex-wrap: wrap; text-align: center; }
.sale a { color: #fff; font-weight: 700; }
.top { border-bottom: 1px solid var(--rule); background: var(--paper); position: relative; z-index: 20; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.mark { font-family: var(--display); font-size: 1.5rem; color: var(--pine); text-decoration: none; line-height: 1; white-space: nowrap; }
.mark:hover { color: var(--pine-dark); }
.nav { display: flex; align-items: center; gap: clamp(14px, 2vw, 28px); }
.nav a { color: var(--ink); text-decoration: none; font-size: 1rem; padding: .5em 0; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--pine); text-decoration: underline; }
.nav .btn { padding: .6em 1.2em; min-height: 44px; font-size: .95rem; color: #fff; }
.nav .btn:hover { text-decoration: none; }
.menu-btn { display: none; background: none; border: 1.5px solid var(--pine); color: var(--pine); border-radius: 999px; padding: .55em 1.1em; font: 700 .95rem var(--text); min-height: 44px; cursor: pointer; }
@media (max-width: 900px) {
  .menu-btn { display: inline-flex; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--paper); border-bottom: 1px solid var(--rule); flex-direction: column; align-items: stretch; gap: 0; padding: 8px var(--gutter) 20px; }
  .nav.open { display: flex; }
  .nav a { padding: .85em 0; border-bottom: 1px solid var(--rule); font-size: 1.1rem; }
  .nav .btn { margin-top: 14px; border-bottom: 0; }
}

/* ---------- sections ---------- */
.sec { padding-block: clamp(64px, 9vw, 120px); }
.sec-tight { padding-block: clamp(44px, 6vw, 80px); }
.sec-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: clamp(28px, 4vw, 48px); flex-wrap: wrap; }
.sec-head p { margin: .6em 0 0; color: var(--ink-soft); }
.rule-top { border-top: 1px solid var(--rule); }

/* ---------- hero ---------- */
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-block: clamp(36px, 6vw, 84px); }
.hero h1 { margin-bottom: .45em; }
.hero .lead { margin-bottom: 1.8em; }
.hero-photo { position: relative; aspect-ratio: 1 / 1; overflow: hidden; border-radius: 6px; background: var(--paper-2); }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }
.hero-note { margin-top: 14px; font-size: .95rem; color: var(--ink-soft); }
.hero-note a { font-weight: 700; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } .hero-photo { order: -1; aspect-ratio: 4 / 3; } }

/* entrance: one moment, on load only */
[data-enter] { opacity: 1; }
.js [data-enter] { opacity: 0; transform: translateY(14px); transition: opacity .7s var(--ease), transform .9s var(--ease); }
.js [data-enter].in { opacity: 1; transform: none; }
.js [data-enter="2"] { transition-delay: .12s; }
.js [data-enter="3"] { transition-delay: .24s; }

/* ---------- collection windows (the one bold device) ---------- */
.windows { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.6vw, 36px); }
.window { display: flex; flex-direction: column; text-decoration: none; color: var(--ink); }
.window-frame {
  position: relative; aspect-ratio: 3 / 4; overflow: hidden;
  border-radius: 50% 50% 6px 6px / 37.5% 37.5% 6px 6px;   /* a true semicircle on a 3:4 frame */
  background: var(--g); box-shadow: inset 0 0 0 1px rgba(0,0,0,.05);
  transition: transform .28s var(--ease);
}
.window-frame::after { content: ""; position: absolute; inset: 10px; border-radius: inherit; border: 1.5px solid var(--a); opacity: .65; pointer-events: none; }
.window-frame img { position: absolute; left: 15%; top: 22%; width: 70%; height: 66%; object-fit: contain; transition: transform .5s var(--ease); }
.window-frame img.matted { border-radius: 3px; box-shadow: 0 10px 24px -14px rgba(0,0,0,.6); }
.window-frame.fill img { inset: 0; width: 100%; height: 100%; object-fit: cover; }
.window:hover .window-frame { transform: translateY(-2px); }
.window:hover .window-frame img { transform: scale(1.03); }
.window-text { padding: 18px 4px 0; }
.window-text h3 { font-size: clamp(1.4rem, 2.2vw, 1.75rem); }
.window-text p { color: var(--ink-soft); margin: .35em 0 0; font-size: 1rem; }
.window-text .count { display: block; margin-top: .55em; color: var(--pine); font-weight: 700; font-size: .95rem; }
@media (max-width: 860px) {
  .windows { grid-template-columns: 1fr; gap: 40px; }
  .window-frame { max-width: 420px; }
}

/* ---------- free band ---------- */
.free-band { background: var(--pine); color: #EFE7D4; }
.free-band h2 { color: #FBF6EC; }
.free-band .sec-head p { color: #D8CFBA; }
.free-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(18px, 2.6vw, 36px); }
.free-card { display: flex; flex-direction: column; color: inherit; text-decoration: none; }
.free-sheet { background: #FBF6EC; padding: 14px 14px 0; border-radius: 160px 160px 4px 4px / 90px 90px 4px 4px; overflow: hidden; aspect-ratio: 4 / 5; transition: transform .28s var(--ease); }
.free-sheet img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 140px 140px 2px 2px / 80px 80px 2px 2px; transition: transform .5s var(--ease); }
.free-card:hover .free-sheet { transform: translateY(-2px); }
.free-card:hover .free-sheet img { transform: scale(1.02); }
.free-card h3 { color: #FBF6EC; margin-top: 18px; font-size: 1.3rem; }
.free-card p { margin: .35em 0 0; color: #D8CFBA; font-size: 1rem; }
.free-card .go { margin-top: .8em; font-weight: 700; color: #F4D990; text-decoration: underline; text-underline-offset: .2em; }
@media (max-width: 860px) { .free-grid { grid-template-columns: 1fr; gap: 44px; } .free-sheet { max-width: 420px; } }

/* ---------- product grid ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: clamp(28px, 3vw, 44px) clamp(16px, 2.2vw, 32px); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1000px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.pc { display: flex; flex-direction: column; text-decoration: none; color: var(--ink); }
.pc-img { aspect-ratio: 1 / 1; overflow: hidden; border-radius: var(--radius); background: var(--paper-2); transition: transform .28s var(--ease); }
.pc-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.pc:hover .pc-img { transform: translateY(-2px); }
.pc:hover .pc-img img { transform: scale(1.03); }
.pc-name { font-family: var(--display); font-size: 1.15rem; line-height: 1.25; color: var(--ink); margin-top: 14px; }
.pc:hover .pc-name { color: var(--pine); text-decoration: underline; text-underline-offset: .18em; text-decoration-thickness: 1px; }
.pc-meta { margin-top: 4px; color: var(--ink-soft); font-size: .98rem; }
.pc-meta strong { color: var(--ink); font-weight: 700; }

/* ---------- occasions ---------- */
.occasions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--rule); }
.occ { display: grid; grid-template-columns: 1fr auto; gap: 6px 20px; align-items: center; padding: 22px 0; border-bottom: 1px solid var(--rule); text-decoration: none; color: var(--ink); }
.occasions .occ:nth-child(odd) { padding-right: clamp(16px, 3vw, 40px); }
.occasions .occ:nth-child(even) { padding-left: clamp(16px, 3vw, 40px); border-left: 1px solid var(--rule); }
.occ h3 { font-size: 1.35rem; }
.occ p { grid-column: 1; margin: 0; color: var(--ink-soft); font-size: .98rem; }
.occ-thumbs { grid-row: 1 / span 2; grid-column: 2; display: flex; }
.occ-thumbs img { width: 56px; height: 74px; object-fit: cover; object-position: top; border-radius: 3px; border: 2px solid #fff; margin-left: -14px; background: #fff; box-shadow: 0 6px 14px -8px rgba(60,40,10,.55); transition: transform .3s var(--ease); }

.occ:hover h3 { color: var(--pine-dark); text-decoration: underline; text-underline-offset: .15em; text-decoration-thickness: 1px; }
.occ:hover .occ-thumbs img { transform: translateY(-2px); }
@media (max-width: 760px) {
  .occasions { grid-template-columns: 1fr; }
  .occasions .occ:nth-child(n) { padding-inline: 0; border-left: 0; }
  .occ-thumbs img { width: 46px; height: 60px; }
}

/* ---------- how it works ---------- */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 4vw, 56px); counter-reset: s; list-style: none; margin: 0; padding: 0; }
.steps li { counter-increment: s; }
.steps li::before { content: counter(s); display: block; font: 400 4rem/1 var(--display); color: var(--gold); margin-bottom: 12px; }
.steps h3 { margin-bottom: .4em; }
.steps p { color: var(--ink-soft); margin: 0; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

/* ---------- faq ---------- */
.faq { max-width: 820px; border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { list-style: none; cursor: pointer; padding: 20px 40px 20px 0; position: relative; font: 400 1.25rem/1.35 var(--display); color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 12px; height: 12px; border-right: 2px solid var(--pine); border-bottom: 2px solid var(--pine); transform: translateY(-70%) rotate(45deg); transition: transform .25s var(--ease); }
.faq details[open] summary::after { transform: translateY(-30%) rotate(225deg); }
.faq summary:hover { color: var(--pine); }
.faq .a { padding: 0 0 22px; color: var(--ink-soft); }

/* ---------- collection page band ---------- */
.band { background: var(--g); color: var(--i); }
.band .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-block: clamp(48px, 7vw, 96px); }
.band h1 { color: var(--i); }
.band p { color: var(--i); opacity: .88; }
.band .crumb a, .band .crumb { color: var(--i); }
.band-art { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; align-items: end; }
.band-art .big { border-radius: 50% 50% 6px 6px / 37.5% 37.5% 6px 6px; overflow: hidden; aspect-ratio: 3/4; background: rgba(255,255,255,.06); display: grid; place-items: center; }
.band-art .big img { width: 82%; height: 82%; object-fit: contain; }
.band-art .stack { display: grid; gap: 14px; }
.band-art .stack div { aspect-ratio: 1/1; border-radius: 6px; background: rgba(255,255,255,.08); display: grid; place-items: center; overflow: hidden; }
.band-art .stack img { width: 84%; height: 84%; object-fit: contain; }
.band-strip { height: 34px; background-repeat: repeat-x; background-size: auto 100%; background-position: center; }
@media (max-width: 860px) { .band .wrap { grid-template-columns: 1fr; } .band-art { max-width: 460px; } }

.crumb { font-size: .95rem; margin-bottom: 1.4em; color: var(--ink-soft); }
.crumb a { color: inherit; }

/* empty shelf */
.shelf-note { border: 1px dashed var(--rule); border-radius: 6px; padding: clamp(24px, 4vw, 40px); max-width: 760px; }
.shelf-note p:last-child { margin-bottom: 0; }

/* ---------- product page ---------- */
.pp .wrap { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(28px, 5vw, 72px); padding-block: clamp(28px, 4vw, 56px) clamp(56px, 8vw, 104px); align-items: start; }
.gallery-main { aspect-ratio: 1 / 1; border-radius: 6px; overflow: hidden; background: var(--paper-2); }
.gallery-main img { width: 100%; height: 100%; object-fit: contain; background: var(--paper-2); }
.gallery-thumbs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.gallery-thumbs button { padding: 0; border: 1.5px solid var(--rule); border-radius: 4px; background: var(--paper-2); aspect-ratio: 1/1; overflow: hidden; cursor: pointer; transition: border-color .18s var(--ease), transform .2s var(--ease); }
.gallery-thumbs button:hover { transform: translateY(-2px); }
.gallery-thumbs button[aria-current="true"] { border-color: var(--pine); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.info { position: sticky; top: 24px; }
.info h1, .fp h1 { font-size: clamp(2.1rem, 3.6vw, 3.1rem); margin-bottom: .35em; }
.price { font: 400 2rem/1 var(--display); color: var(--ink); margin: .2em 0 .5em; }
.price small { font: 400 1rem var(--text); color: var(--ink-soft); }
.sale-note { display: inline-block; background: #F7E7C4; color: #5A3D0E; padding: .3em .7em; border-radius: 4px; font-size: .95rem; margin-bottom: 1.2em; }
.facts { list-style: none; padding: 0; margin: 1.4em 0; border-top: 1px solid var(--rule); }
.facts li { padding: .7em 0 .7em 26px; border-bottom: 1px solid var(--rule); position: relative; font-size: 1rem; }
.facts li::before { content: ""; position: absolute; left: 4px; top: 1.15em; width: 9px; height: 9px; border-radius: 50%; background: var(--gold); }
.inc h2 { font-size: 1.35rem; margin: 1.6em 0 .3em; }
.inc ul { margin: 0; padding-left: 1.1em; }
.inc li { margin: .3em 0; }
.small { font-size: .92rem; color: var(--ink-soft); }
.buy-note { margin-top: 12px; }
@media (max-width: 900px) { .pp .wrap { grid-template-columns: 1fr; } .info { position: static; } }

/* ---------- shop page ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 clamp(32px, 4vw, 48px); padding: 0; list-style: none; }
.chips a { display: inline-flex; align-items: center; min-height: 44px; padding: .4em 1.05em; border: 1.5px solid var(--rule); border-radius: 999px; color: var(--ink); text-decoration: none; font-size: .98rem; transition: border-color .18s var(--ease), background-color .18s var(--ease); }
.chips a:hover { border-color: var(--pine); }
.chips a[aria-current="true"] { background: var(--pine); border-color: var(--pine); color: #fff; }
.cat { padding-top: clamp(28px, 4vw, 48px); scroll-margin-top: 24px; }
.cat + .cat { border-top: 1px solid var(--rule); margin-top: clamp(40px, 5vw, 64px); }
.cat-head { margin-bottom: 26px; }
.cat-head p { color: var(--ink-soft); margin: .4em 0 0; }
.is-hidden { display: none; }

/* ---------- free page ---------- */
.fp .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); padding-block: clamp(28px, 4vw, 56px) clamp(56px, 8vw, 104px); align-items: start; }
.fp-sheet { background: var(--paper-2); padding: clamp(16px, 2.5vw, 28px); border-radius: 220px 220px 6px 6px / 120px 120px 6px 6px; }
.fp-sheet img { border-radius: 200px 200px 2px 2px / 110px 110px 2px 2px; box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 12px 28px -18px rgba(60,40,10,.45); }
.dl { display: grid; gap: 12px; margin: 1.6em 0 1em; }
@media (max-width: 860px) { .fp .wrap { grid-template-columns: 1fr; } .fp-sheet { max-width: 520px; } }

/* ---------- article (how to print) ---------- */
.article { max-width: 760px; padding-block: clamp(40px, 6vw, 80px); }
.article h1 { margin-bottom: .4em; }
.article h2 { font-size: 1.6rem; margin: 1.8em 0 .5em; }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--rule); background: var(--paper-2); font-size: .98rem; }
.foot .wrap { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 32px; padding-block: clamp(44px, 6vw, 72px); }
.foot h2 { font-size: 1.15rem; margin-bottom: .6em; }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { margin: .4em 0; }
.foot a { color: var(--ink); }
.foot a:hover { color: var(--pine); }
.foot .mark { display: inline-block; margin-bottom: .6em; }
.foot p { color: var(--ink-soft); max-width: 46ch; }
.foot-base { border-top: 1px solid var(--rule); }
.foot-base .wrap { display: block; padding-block: 18px; color: var(--ink-soft); font-size: .9rem; }
@media (max-width: 760px) { .foot .wrap { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .js [data-enter] { opacity: 1; transform: none; }
}
