/* Margin — design B "Stationery" */
@font-face { font-family: 'Newsreader'; font-style: normal; font-weight: 200 800; font-display: swap; src: url('/fonts/newsreader-normal.woff2') format('woff2'); }
@font-face { font-family: 'Newsreader'; font-style: italic; font-weight: 200 800; font-display: swap; src: url('/fonts/newsreader-italic.woff2') format('woff2'); }
@font-face { font-family: 'Hanken Grotesk'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('/fonts/hanken-grotesk.woff2') format('woff2'); }

:root {
  --paper: #F3EEE3;
  --card: #FAF7F0;
  --sand: #E6DECD;
  --band: #EDE6D7;
  --ink: #23201A;
  --muted: #675F53;
  --rule: #D8CFBD;
  --leader: #BDB29C;
  --accent: #A9351D;
  --accent-soft: #F1DDD3;
  --serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --sans: 'Hanken Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --wrap: 1240px;
  --radius: 14px;
  --shadow-sheet: 0 1px 0 var(--rule), 0 22px 36px -22px rgba(70, 50, 20, .45);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.55; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-underline-offset: 3px; }
a:hover { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
button, input, select { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 300; line-height: 1.05; letter-spacing: -.01em; margin: 0; }
p { margin: 0; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 999px; z-index: 50; }
.skip:focus { top: 12px; color: var(--paper); }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.kicker { font-size: 13px; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); font-weight: 600; }
.eyebrow { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.muted { color: var(--muted); }
.lede { font-size: 19px; color: var(--muted); max-width: 600px; }
.serif { font-family: var(--serif); }
.display { font-size: clamp(44px, 6.4vw, 96px); font-weight: 300; }
.h2 { font-size: clamp(34px, 3.6vw, 52px); }
.h3 { font-size: 28px; font-weight: 400; }
em { font-style: italic; }
.section { padding: 88px 0; }
.section-rule { border-top: 1px solid var(--rule); }
.stack { display: flex; flex-direction: column; gap: 18px; }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.between { justify-content: space-between; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 26px; border-radius: 999px; font-weight: 600; font-size: 16px; text-decoration: none; border: 1px solid var(--ink); cursor: pointer; background: transparent; color: var(--ink); transition: background .15s, color .15s; }
.btn:hover { color: var(--ink); background: var(--card); }
.btn-dark { background: var(--ink); color: var(--paper); }
.btn-dark:hover { background: #3a362d; color: var(--paper); }
.btn-small { min-height: 44px; padding: 0 18px; font-size: 15px; }
.btn[disabled] { opacity: .6; cursor: progress; }
.btn.added { background: var(--card); color: var(--ink); }
.link-arrow { font-weight: 600; text-decoration: none; padding: 10px 0; display: inline-block; }
.link-arrow:hover { text-decoration: underline; }

/* Top bar + header */
.topbar { border-bottom: 1px solid var(--rule); text-align: center; padding: 9px 16px; font-size: 13px; color: var(--muted); }
.site-header { border-bottom: 1px solid var(--rule); background: var(--paper); }
.header-grid { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: center; padding-top: 16px; padding-bottom: 16px; }
.nav { display: flex; gap: 24px; font-weight: 500; font-size: 15px; }
.nav a, .header-actions a { text-decoration: none; padding: 10px 0; }
.nav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; }
.logo { text-decoration: none; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.logo-word { font-family: var(--serif); font-style: italic; font-size: 38px; line-height: 1; }
.logo-tag { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.header-actions { display: flex; gap: 18px; justify-content: flex-end; align-items: center; font-weight: 500; font-size: 15px; }
.basket-link { border: 1px solid var(--ink); border-radius: 999px; padding: 9px 18px !important; white-space: nowrap; }
.menu { display: none; }
.menu summary { list-style: none; cursor: pointer; min-height: 44px; display: flex; align-items: center; font-weight: 600; }
.menu summary::-webkit-details-marker { display: none; }
.menu-panel { position: absolute; left: 0; right: 0; background: var(--paper); border-bottom: 1px solid var(--rule); padding: 8px 24px 20px; z-index: 20; display: flex; flex-direction: column; }
.menu-panel a { padding: 12px 0; border-bottom: 1px solid var(--rule); text-decoration: none; font-size: 18px; font-family: var(--serif); }
@media (max-width: 860px) {
  .header-grid { grid-template-columns: auto 1fr auto; }
  .nav, .header-actions .hide-sm { display: none; }
  .menu { display: block; }
  .logo { align-items: center; }
  .logo-word { font-size: 30px; }
  .logo-tag { display: none; }
}

/* Hero */
.hero { padding: 80px 24px 24px; display: flex; flex-direction: column; align-items: center; gap: 26px; text-align: center; }
.hero h1 { max-width: 1000px; }
.hero h1 em { font-weight: 400; }
.fan { position: relative; width: min(100%, 860px); height: 500px; margin-top: 32px; overflow: hidden; }
.fan .sheet { position: absolute; left: 50%; width: 290px; margin-left: -145px; top: 40px; }
.fan .sheet.l { transform: translateX(-210px) rotate(-7deg); }
.fan .sheet.r { transform: translateX(210px) rotate(6deg); }
.fan .sheet.c { top: 0; width: 310px; margin-left: -155px; }
.fan .stamp { position: absolute; left: 50%; top: 300px; margin-left: 110px; }
@media (max-width: 700px) {
  .fan { height: 380px; }
  .fan .sheet { width: 210px; margin-left: -105px; }
  .fan .sheet.c { width: 230px; margin-left: -115px; }
  .fan .sheet.l { transform: translateX(-120px) rotate(-7deg); }
  .fan .sheet.r { transform: translateX(120px) rotate(6deg); }
  .fan .stamp { top: 230px; margin-left: 40px; transform: scale(.8) rotate(-12deg); }
}

.sheet { background: #fdfdfb; box-shadow: var(--shadow-sheet); }
.sheet img { width: 100%; height: auto; aspect-ratio: 3 / 4; }

/* Rubber stamp */
.stamp { width: 132px; height: 132px; border: 2px solid var(--accent); border-radius: 50%; transform: rotate(-12deg); display: flex; align-items: center; justify-content: center; background: rgba(243, 238, 227, .88); color: var(--accent); }
.stamp > span { width: 112px; height: 112px; border: 1px solid var(--accent); border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.stamp b { font-size: 10px; letter-spacing: .2em; font-weight: 700; }
.stamp i { font-family: var(--serif); font-size: 22px; line-height: 1; }

/* Contents list */
.toc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 56px; }
.toc { list-style: none; margin: 0; padding: 0; }
.toc li { border-bottom: 1px solid var(--rule); }
.toc a { display: flex; align-items: baseline; gap: 16px; padding: 18px 0; text-decoration: none; }
.toc .n { font-size: 13px; font-weight: 700; color: var(--accent); width: 24px; flex-shrink: 0; }
.toc .t { font-family: var(--serif); font-size: 28px; line-height: 1.1; }
.toc .leader { flex-grow: 1; border-bottom: 2px dotted var(--leader); transform: translateY(-6px); min-width: 24px; }
.toc .d { font-size: 14px; color: var(--muted); text-align: right; }
.toc a:hover .t { color: var(--accent); }
@media (max-width: 560px) { .toc .d, .toc .leader { display: none; } .toc .t { font-size: 24px; } }

/* Feature panel (collection) */
.panel { background: var(--card); border: 1px solid var(--rule); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr)); }
.panel-media { background: var(--sand); padding: 56px; display: flex; justify-content: center; align-items: center; }
.panel-body { padding: 56px; display: flex; flex-direction: column; gap: 20px; justify-content: center; }
@media (max-width: 560px) { .panel-media, .panel-body { padding: 28px; } }
.device { width: min(100%, 360px); background: #3B3832; border-radius: 20px; padding: 14px 14px 14px 40px; box-shadow: 0 30px 50px -30px rgba(40, 30, 10, .6); }
.device img { border-radius: 3px; width: 100%; aspect-ratio: 3 / 4; background: #fdfdfb; }
.price-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.price-list li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--rule); }
.price-list a { text-decoration: none; }
.price-total { font-family: var(--serif); font-size: 28px; }
.price-total s { color: var(--muted); font-size: 20px; }
.price-total small { font-family: var(--sans); font-size: 14px; color: var(--accent); font-weight: 600; }

/* Stamp card */
.stampcard { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 32px; display: flex; flex-direction: column; gap: 24px; box-shadow: 0 20px 40px -30px rgba(70, 50, 20, .4); }
.stampcard-head { display: flex; justify-content: space-between; align-items: baseline; border-bottom: 1px dashed var(--leader); padding-bottom: 14px; }
.stamps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.stamps li { list-style: none; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; font-size: 14px; font-weight: 600; }
.stamps { margin: 0; padding: 0; }
.slot { width: 96px; height: 96px; border-radius: 50%; border: 2px dashed var(--leader); display: flex; align-items: center; justify-content: center; color: var(--muted); font-family: var(--serif); font-style: italic; font-size: 26px; transition: all .3s; }
.slot.on { border: 2px solid var(--accent); color: var(--accent); transform: rotate(-8deg); }
.slot.on:nth-child(even) { transform: rotate(6deg); }
@media (max-width: 480px) { .slot { width: 72px; height: 72px; font-size: 20px; } .stampcard { padding: 20px; } }

/* Product grid + cards */
.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 44px 28px; }
.pcard { display: flex; flex-direction: column; gap: 14px; }
.pcard-media { display: block; background: var(--sand); padding: 32px 40px; position: relative; }
.pcard-media .badge { position: absolute; left: 12px; top: 12px; }
.pcard-title { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.pcard-title a { font-family: var(--serif); font-size: 23px; line-height: 1.15; text-decoration: none; }
.pcard-price { font-family: var(--serif); font-size: 21px; white-space: nowrap; }
.pcard-summary { font-size: 14px; color: var(--muted); margin-top: -6px; }
.badge { display: inline-block; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; padding: 4px 9px; border-radius: 999px; background: var(--paper); border: 1px solid var(--accent); color: var(--accent); }
.badge.free { background: var(--accent); color: #fff; }

/* Filter chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--rule); text-decoration: none; font-size: 15px; background: var(--card); }
.chip[aria-current="page"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* Dark band */
.band { background: var(--ink); color: var(--paper); }
.band a { color: var(--paper); }
.band a:hover { color: #F1C9B8; }
.band .kicker { color: #E0B8A8; }
.band-list { font-family: var(--serif); font-style: italic; font-weight: 300; font-size: clamp(34px, 4.4vw, 60px); line-height: 1.15; max-width: 1040px; }

/* Promises */
.promises { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 48px; }
.promise { border-top: 1px solid var(--ink); padding-top: 20px; display: flex; flex-direction: column; gap: 12px; }
.promise .num { font-family: var(--serif); font-style: italic; font-size: 22px; color: var(--accent); }

/* Footer */
.site-footer { border-top: 1px solid var(--rule); background: var(--band); }
.footer-grid { display: flex; flex-wrap: wrap; gap: 48px; justify-content: space-between; padding-top: 72px; }
.footer-grid nav { flex: 1 1 140px; display: flex; flex-direction: column; gap: 10px; font-size: 15px; }
.footer-grid nav a { text-decoration: none; }
.footer-news { flex: 2 1 360px; display: flex; flex-direction: column; gap: 16px; }
.footer-news h2 { font-size: 40px; }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; font-size: 13px; color: var(--muted); border-top: 1px solid var(--rule); margin-top: 56px; padding: 20px 0 32px; }
.footer-base a { color: var(--muted); }

/* Forms */
.inline-form { display: flex; flex-wrap: wrap; gap: 8px; max-width: 480px; }
.input, .select { min-height: 50px; border: 1px solid var(--leader); background: var(--card); border-radius: 999px; padding: 0 18px; font-size: 16px; }
.inline-form .input { flex: 1 1 220px; }
.select { border-radius: 12px; padding-right: 36px; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%2323201A' stroke-width='1.6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.form-msg { font-size: 14px; min-height: 1.4em; }
.form-msg.err { color: var(--accent); }
.ts-slot:empty { display: none; }

/* Breadcrumb */
.crumbs { font-size: 13px; color: var(--muted); padding-top: 28px; }
.crumbs a { color: var(--muted); }

/* Product page */
.product { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 480px), 1fr)); gap: 56px; padding: 28px 0 80px; align-items: start; }
.gallery-main { background: var(--sand); padding: 48px 24px; display: flex; justify-content: center; }
.gallery-main .device { width: min(100%, 420px); }
.thumbs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.thumbs button { padding: 6px; background: var(--card); border: 1px solid var(--rule); cursor: pointer; border-radius: 6px; }
.thumbs button[aria-pressed="true"] { border: 2px solid var(--ink); padding: 5px; }
.thumbs img { aspect-ratio: 3 / 4; width: 100%; background: #fdfdfb; }
.buy { display: flex; flex-direction: column; gap: 22px; position: sticky; top: 24px; }
.buy h1 { font-size: clamp(40px, 4.4vw, 64px); }
.buy .price { font-family: var(--serif); font-size: 36px; }
.features { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.features li { padding: 10px 0 10px 26px; border-bottom: 1px solid var(--rule); position: relative; }
.features li::before { content: ''; position: absolute; left: 4px; top: 18px; width: 10px; height: 10px; border: 1.5px solid var(--accent); border-radius: 50%; }
.note { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 18px 20px; font-size: 15px; }
.note strong { color: var(--accent); }
.details-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 40px; border-top: 1px solid var(--rule); padding: 56px 0; }
.details-grid h2 { font-size: 30px; margin-bottom: 14px; }
.device-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }

/* Cart */
.cart { display: grid; grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr); gap: 48px; align-items: start; padding: 32px 0 96px; }
@media (max-width: 900px) { .cart { grid-template-columns: 1fr; } }
.cart-lines { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--rule); }
.cart-line { display: flex; gap: 20px; align-items: center; padding: 20px 0; border-bottom: 1px solid var(--rule); }
.cart-line img { width: 72px; aspect-ratio: 3 / 4; background: #fdfdfb; box-shadow: var(--shadow-sheet); flex-shrink: 0; }
.cart-line .grow { flex-grow: 1; min-width: 0; }
.cart-line a { font-family: var(--serif); font-size: 22px; text-decoration: none; }
.icon-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--rule); background: var(--card); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.icon-btn:hover { border-color: var(--ink); }
.summary { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; gap: 14px; position: sticky; top: 24px; }
.summary dl { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.summary dl div { display: flex; justify-content: space-between; gap: 16px; }
.summary dd { margin: 0; }
.summary .total { border-top: 1px solid var(--rule); padding-top: 12px; font-family: var(--serif); font-size: 26px; }
.empty { padding: 48px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }

/* Downloads (order + library) */
.dl-list { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--rule); }
.dl-item { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 20px; padding: 22px 0; border-bottom: 1px solid var(--rule); }
.dl-item img { width: 72px; aspect-ratio: 3 / 4; background: #fdfdfb; box-shadow: var(--shadow-sheet); }
.dl-item h3 { font-size: 24px; font-weight: 400; }
.dl-controls { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; }
.dl-controls .select { min-height: 44px; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th { text-align: left; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; padding: 10px 8px; border-bottom: 1px solid var(--ink); }
.table td { padding: 14px 8px; border-bottom: 1px solid var(--rule); vertical-align: top; }
.scroll-x { overflow-x: auto; }

/* Devices */
.brand { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); gap: 40px; padding: 48px 0; border-top: 1px solid var(--rule); }
.models { list-style: none; padding: 0; margin: 0; }
.models li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--rule); }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: s; }
.steps li { counter-increment: s; display: flex; gap: 14px; padding: 12px 0; border-top: 1px solid var(--rule); }
.steps li::before { content: counter(s, decimal-leading-zero); color: var(--accent); font-weight: 700; font-size: 13px; padding-top: 3px; }

/* Prose (help + legal) */
.prose { max-width: 720px; padding: 32px 0 96px; }
.prose h2 { font-size: 30px; margin: 40px 0 12px; }
.prose p, .prose li { color: #3d3830; margin-bottom: 12px; }
.prose ul { padding-left: 20px; }
.faq details { border-bottom: 1px solid var(--rule); padding: 18px 0; }
.faq summary { cursor: pointer; font-family: var(--serif); font-size: 22px; }
.faq details p { margin-top: 10px; color: var(--muted); }
.todo { background: var(--accent-soft); padding: 0 4px; border-radius: 3px; }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 120px); background: var(--ink); color: var(--paper); padding: 14px 22px; border-radius: 999px; font-size: 15px; z-index: 60; transition: transform .25s; display: flex; gap: 14px; align-items: center; max-width: calc(100% - 32px); }
.toast.show { transform: translate(-50%, 0); }
.toast a { color: #F1C9B8; font-weight: 600; }

.page-head { padding: 48px 0 24px; display: flex; flex-direction: column; gap: 14px; }
.spinner { width: 22px; height: 22px; border: 2px solid var(--rule); border-top-color: var(--accent); border-radius: 50%; animation: spin 1s linear infinite; display: inline-block; vertical-align: middle; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* Cookie consent banner (gtag.js) */
.consent { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 55; max-width: 560px; margin-left: auto; background: var(--card); color: var(--ink); border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow-sheet); padding: 18px 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; font-size: 15px; }
.consent[hidden] { display: none; }
.consent p { margin: 0; flex: 1 1 260px; }
.consent-actions { display: flex; gap: 10px; }
