/* Pairisen — pre-launch site
   Built from the Figma page "19 · Pre-launch site (pairisen.com)" in
   "Pairisen — Designed Wireframes". Monochrome + one red reserved for sale
   prices; DM Serif Display for headlines, DM Sans for reading, DM Mono for
   labels, buttons, chips, numbers and the announcement bar (as on the
   optician screens). Sharp corners; 4px grid.
   Logo: PAIRISEN in Montserrat Black, tracked, converted to paths. */

/* Self-hosted fonts (SIL Open Font License; licences in /assets/fonts) */
@font-face { font-family: "DM Sans"; src: url("/assets/fonts/dm-sans-latin-opsz-normal.woff2") format("woff2-variations"), url("/assets/fonts/dm-sans-latin-opsz-normal.woff2") format("woff2"); font-weight: 100 1000; font-style: normal; font-display: swap; }
@font-face { font-family: "DM Serif Display"; src: url("/assets/fonts/dm-serif-display-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("/assets/fonts/dm-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("/assets/fonts/dm-mono-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }

:root {
  /* Figma Foundations colour tokens */
  --ink: #111111;
  --surface: #f8f8f8;
  --white: #ffffff;
  --mid: #767676;
  --border: #cacaca;
  --tag: #e8e6e3;
  --tile: #efefef;
  --sale: #b23b2e;         /* sale price figure only */

  --serif: "DM Serif Display", Georgia, serif;
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "DM Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --gutter: clamp(16px, 4vw, 48px);
  --max: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--white); color: var(--ink); font: 400 16px/24px var(--sans); -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
p { margin: 0; }
[hidden] { display: none !important; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: var(--gutter); top: 12px; background: var(--white); padding: 8px 12px; z-index: 10; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Type ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 400; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(38px, 5.4vw, 61px); line-height: 1.23; }
h2 { font-size: clamp(28px, 3.2vw, 36px); line-height: 1.11; }
h3 { font-size: 22px; line-height: 28px; }
.eyebrow { font: 400 11px/14px var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--mid); }
.lede { font-size: 18px; line-height: 28px; }
.muted { color: var(--mid); }

/* ---------- Announcement bar + header ---------- */
.announce { background: var(--ink); color: var(--white); }
.announce p { min-height: 45px; display: flex; align-items: center; justify-content: center; gap: 0.5em; text-align: center; padding: 8px var(--gutter); font: 400 12px/16px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; }
.announce a { text-decoration: none; }
.announce a:hover { text-decoration: underline; }
.site-header { background: var(--white); border-bottom: 1px solid var(--border); }
.site-header .wrap { display: flex; align-items: center; justify-content: center; height: 72px; }
.logo { display: inline-flex; color: var(--ink); }
.logo svg { width: 155px; height: auto; }

/* ---------- Buttons (DM Mono labels, sharp corners) ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; height: 48px; padding: 0 24px; font: 400 13px/18px var(--mono); border: 1px solid var(--ink); border-radius: 0; background: none; color: var(--ink); text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn-dark { background: var(--ink); color: var(--white); }
.btn-dark:hover { background: #333333; border-color: #333333; }
.btn-outline:hover { background: var(--ink); color: var(--white); }
.btn-light { background: var(--white); color: var(--ink); border-color: var(--white); }
.btn-light:hover { background: var(--surface); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: 0.6; cursor: progress; }

/* ---------- Form fields ---------- */
.fields { display: grid; gap: 12px; }
.fields.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field label, .offers legend { font: 400 11px/14px var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--mid); }
input[type="email"], input[type="text"], input[type="tel"], textarea {
  font: 400 15px/20px var(--sans); color: var(--ink); background: var(--white);
  border: 1px solid var(--border); border-radius: 0; padding: 0 16px; height: 48px; width: 100%; min-width: 0;
}
textarea { height: 112px; padding: 14px 16px; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--mid); }
input:focus, textarea:focus { outline: none; border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.fine { font: 400 12px/16px var(--sans); color: var(--mid); }
.form-status { font: 500 14px/20px var(--sans); min-height: 20px; }
.form-status.error::before { content: ""; display: inline-block; width: 8px; height: 8px; background: currentColor; margin-right: 8px; vertical-align: 1px; }
.err { font: 500 13px/18px var(--sans); min-height: 0; }
.err:empty { display: none; }
[aria-invalid="true"] { border-color: var(--ink) !important; box-shadow: inset 0 0 0 1px var(--ink); }

/* Waitlist (dark bands) */
.waitlist .form-body { display: grid; gap: 12px; }
.on-dark .field label { color: rgba(255, 255, 255, 0.75); }
.on-dark input { background: rgba(255, 255, 255, 0.06); color: var(--white); border-color: rgba(255, 255, 255, 0.6); }
.on-dark input::placeholder { color: rgba(255, 255, 255, 0.55); }
.on-dark input:focus { border-color: var(--white); box-shadow: inset 0 0 0 1px var(--white); }
.on-dark .fine { color: rgba(255, 255, 255, 0.65); }
.waitlist.done .form-body { display: none; }
.waitlist .thanks { display: none; border-left: 2px solid currentColor; padding: 4px 0 4px 16px; }
.waitlist.done .thanks { display: block; }
.thanks strong { font-weight: 600; }
.thanks p + p { margin-top: 4px; }

/* ---------- Hero ---------- */
.hero { background: linear-gradient(rgba(17, 17, 17, 0.66), rgba(17, 17, 17, 0.74)), url("/assets/hero.jpg") 58% 30% / cover no-repeat, var(--ink); color: var(--white); text-align: center; padding: clamp(72px, 10vw, 128px) 0 clamp(64px, 8vw, 104px); }
.hero .eyebrow { color: rgba(255, 255, 255, 0.75); }
.hero h1 { margin: 20px auto 0; max-width: 13em; }
.hero .lede { max-width: 36em; margin: 24px auto 0; color: rgba(255, 255, 255, 0.9); }
.hero .waitlist { margin: 40px auto 0; max-width: 580px; text-align: left; }

/* ---------- Sections ---------- */
.section { padding: clamp(64px, 8vw, 104px) 0; }
.section-head { text-align: center; margin-bottom: clamp(32px, 4vw, 44px); }
.section-head h2 { margin: 12px auto 0; max-width: 18em; }

/* Numbered open columns with a top rule */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px; }
.steps li { border-top: 1px solid var(--ink); padding-top: 20px; }
.num { display: block; font: 400 12px/16px var(--mono); color: var(--mid); }
.steps h3 { margin-top: 32px; }
.steps p { margin-top: 12px; font-size: 14px; line-height: 20px; color: var(--mid); }

/* Chips (from the optician filter row) */
.tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tag, .tag-check span { display: inline-block; padding: 6px 12px; font: 400 13px/18px var(--mono); background: var(--white); border: 1px solid var(--border); color: var(--ink); }
.tag-check { position: relative; cursor: pointer; }
.tag-check input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.tag-check input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--white); }
.tag-check input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }

/* Shop local */
.local { background: var(--surface); }
.local .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); align-items: start; }
.local-head h2 { margin-top: 12px; }
.local-head .tags { margin-top: 20px; }
.local-copy p { max-width: 34em; font-weight: 500; font-size: 14px; line-height: 20px; }
.local-copy .muted { font-weight: 400; margin-top: 24px; }
.local-copy .btn { margin-top: 16px; }

/* Closing */
.closing { background: var(--ink); color: var(--white); }
.closing .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.closing-copy p { margin-top: 16px; color: rgba(255, 255, 255, 0.8); max-width: 30em; font-size: 14px; line-height: 20px; }

/* ---------- For opticians ---------- */
.op-intro { background: var(--surface); padding: 48px 0 88px; }
.crumbs { font: 400 12px/16px var(--mono); color: var(--mid); margin-bottom: 56px; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.crumbs span { margin: 0 8px; }
.op-intro h1 { font-size: clamp(36px, 4.4vw, 48px); line-height: 1.12; max-width: 15.5em; margin-top: 16px; }
.op-intro .lede { max-width: 38em; margin-top: 24px; }
.op-how .steps { margin-top: 32px; }
.op-form { border-top: 1px solid var(--border); padding-bottom: clamp(72px, 9vw, 104px); }
.op-form .wrap { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: clamp(40px, 7vw, 96px); align-items: start; }
.op-form-intro p { margin-top: 16px; font-size: 14px; line-height: 20px; }
.mono-note { font: 400 12px/16px var(--mono); }
.optician-form { display: grid; gap: 24px; }
.fields.grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.field.wide { grid-column: 1 / -1; }
.offers { border: 0; padding: 0; margin: 0; min-width: 0; }
.offers legend { padding: 0; margin-bottom: 12px; }
.check { display: inline-flex; align-items: center; gap: 12px; cursor: pointer; font-size: 14px; }
.check input { appearance: none; width: 16px; height: 16px; margin: 0; border: 1px solid var(--ink); border-radius: 0; background: var(--white); display: grid; place-content: center; cursor: pointer; }
.check input:checked { background: var(--ink); }
.check input:checked::after { content: ""; width: 8px; height: 4px; border: solid var(--white); border-width: 0 0 2px 2px; transform: translateY(-1px) rotate(-45deg); }
.owner .err { margin-top: 8px; }
.submit-row { display: flex; align-items: center; gap: 20px; }
.submit-row .fine { max-width: 30em; }
.op-next .eyebrow { margin-bottom: 24px; }
.next-rows { list-style: none; margin: 0 0 32px; padding: 0; }
.next-rows li { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 32px; padding: 24px 0; border-top: 1px solid var(--border); }
.next-rows h3 { margin: -6px 0 6px; }
.next-rows p { font-size: 14px; line-height: 20px; color: var(--mid); }
.when { font: 400 13px/18px var(--mono); color: var(--mid); }

/* ---------- Footer ---------- */
.site-footer { background: var(--surface); border-top: 1px solid var(--border); padding: 56px 0 40px; font-size: 14px; line-height: 20px; }
.site-footer .wrap { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); gap: 32px 48px; }
.site-footer .logo svg { width: 124px; }
.disclosure { margin-top: 20px; color: var(--mid); max-width: 36em; }
.foot-col ul { list-style: none; margin: 12px 0 0; padding: 0; }
.foot-col li + li { margin-top: 8px; }
.foot-col a { text-decoration: none; }
.foot-col a:hover { text-decoration: underline; }
.copyright { grid-column: 1 / -1; border-top: 1px solid var(--border); padding-top: 20px; margin-top: 16px; color: var(--mid); font-size: 12px; line-height: 16px; }

/* ---------- Legal pages ---------- */
.legal { padding: clamp(48px, 7vw, 88px) 0 clamp(64px, 8vw, 104px); }
.legal .wrap { max-width: 760px; }
.legal h1 { font-size: clamp(36px, 4.5vw, 48px); line-height: 1.08; }
.legal .updated { margin-top: 14px; color: var(--mid); font: 400 12px/16px var(--mono); }
.legal h2 { font-size: 28px; line-height: 34px; margin-top: 44px; }
.legal p, .legal ul { margin-top: 14px; max-width: 38em; }
.legal ul { padding-left: 1.2em; }
.legal li + li { margin-top: 6px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .local .wrap, .closing .wrap, .op-form .wrap { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: 28px; }
  .steps h3 { margin-top: 16px; }
  .site-footer .wrap { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .announce .wide { display: none; }
  .logo svg { width: 128px; }
  .site-header .wrap { height: 64px; }
  .fields.two, .fields.grid { grid-template-columns: 1fr; }
  .fields.grid { gap: 20px; }
  .submit-row { flex-direction: column; align-items: stretch; }
  .submit-row .btn { width: 100%; }
  .op-intro { padding: 24px 0 56px; }
  .crumbs { margin-bottom: 32px; }
  .next-rows li { grid-template-columns: 32px minmax(0, 1fr); gap: 16px; }
  .next-rows .when { grid-column: 2; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
