/* ==========================================================================
   CartoStudio — Design tokens
   Direction: cartographic atelier / engraved plate. The site borrows the
   product's own vocabulary — the gold-hairline "museum plaque" caption
   (place / coordinates / date) — as its structural device, instead of
   generic cards.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,340;9..144,480;9..144,560&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  --radius: 2px;
  --container: 1240px;
  --ease: cubic-bezier(.22,.61,.36,1);
}

body[data-theme="dark"] {
  --bg: #0A0D12;
  --bg-panel: #0D1420;
  --bg-raised: #111926;
  --ink: #F3EFE6;
  --ink-muted: rgba(243,239,230,.60);
  --ink-faint: rgba(243,239,230,.34);
  --gold: #C6A468;
  --gold-strong: #E0C08A;
  --slate: #7E9CB0;
  --line: rgba(243,239,230,.12);
  --line-strong: rgba(243,239,230,.22);
  --shadow: 0 40px 80px -30px rgba(0,0,0,.7);
  --scrim: rgba(6,8,11,.72);
}

body[data-theme="light"] {
  --bg: #F4F0E6;
  --bg-panel: #ECE5D4;
  --bg-raised: #FFFDF8;
  --ink: #14181F;
  --ink-muted: rgba(20,24,31,.62);
  --ink-faint: rgba(20,24,31,.38);
  --gold: #9C7A3C;
  --gold-strong: #7C6230;
  --slate: #3E5C76;
  --line: rgba(20,24,31,.14);
  --line-strong: rgba(20,24,31,.26);
  --shadow: 0 40px 80px -30px rgba(20,24,31,.22);
  --scrim: rgba(244,240,230,.82);
}

/* ---------------------------------- reset -------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background .5s var(--ease), color .5s var(--ease);
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
h1,h2,h3,h4,p,figure { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
::selection { background: var(--gold); color: #14181F; }

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

/* -------------------------------- type -------------------------------- */
.display {
  font-family: 'Fraunces', serif;
  font-weight: 340;
  letter-spacing: .01em;
}
.eyebrow {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 22px; height: 1px;
  background: var(--gold);
  display: inline-block;
}
.mono { font-family: 'JetBrains Mono', monospace; }

/* ------------------------------ plaque -----------------------------------
   The signature motif: a thin-bordered "museum label" carrying
   place / coordinates / date in tracked monospace — echoes the product. */
.plaque {
  border: 1px solid var(--line-strong);
  padding: 14px 18px;
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  background: var(--bg-raised);
}
.plaque__title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink);
}
.plaque__coords {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: .06em;
  color: var(--gold);
}
.plaque__meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  letter-spacing: .08em;
  color: var(--ink-faint);
}

/* -------------------------------- buttons -------------------------------- */
.btn {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 16px 26px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  transition: border-color .3s var(--ease), background .3s var(--ease), color .3s var(--ease), transform .3s var(--ease);
}
.btn:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-2px); }
.btn:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.btn-solid {
  background: var(--gold);
  border-color: var(--gold);
  color: #14181F;
}
.btn-solid:hover { background: var(--gold-strong); border-color: var(--gold-strong); color: #14181F; }
.btn svg { width: 14px; height: 14px; transition: transform .3s var(--ease); }
.btn:hover svg { transform: translateX(3px); }

/* --------------------------------- nav ------------------------------------ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: var(--scrim);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  transition: background .5s var(--ease), border-color .5s var(--ease);
}
.nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 84px;
}
.nav__brand { display: flex; align-items: center; gap: 12px; }
.nav__brand img { height: 34px; width: auto; }
.nav__brand span {
  font-family: 'Fraunces', serif;
  font-size: 19px;
  letter-spacing: .03em;
  font-weight: 480;
}
.nav__links {
  display: flex;
  align-items: center;
  gap: 38px;
}
.nav__links a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-muted);
  position: relative;
  padding-bottom: 4px;
}
.nav__links a::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 0; height: 1px;
  background: var(--gold);
  transition: width .3s var(--ease);
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { width: 100%; }
.nav__actions { display: flex; align-items: center; gap: 18px; }

.icon-btn {
  width: 38px; height: 38px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--ink-muted);
  transition: color .3s var(--ease), border-color .3s var(--ease), transform .3s var(--ease);
}
.icon-btn:hover { color: var(--gold); border-color: var(--gold); transform: translateY(-2px); }
.icon-btn svg { width: 16px; height: 16px; }

.nav__burger {
  display: none;
  width: 38px; height: 38px;
  border: 1px solid var(--line-strong);
  background: transparent;
  align-items: center; justify-content: center;
  color: var(--ink);
}

/* -------------------------------- hero ------------------------------------ */
.hero {
  padding: 190px 0 120px;
  position: relative;
}
.hero .wrap {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 64px;
  align-items: center;
}
.hero__kicker { margin-bottom: 28px; }
.hero h1 {
  font-size: clamp(40px, 5.4vw, 70px);
  line-height: 1.04;
  text-transform: uppercase;
  letter-spacing: .01em;
  margin-bottom: 26px;
}
.hero h1 em {
  font-style: normal;
  color: var(--gold);
}
.hero p.lede {
  font-size: 18px;
  color: var(--ink-muted);
  max-width: 46ch;
  margin-bottom: 40px;
}
.hero__ctas { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 56px; }
.hero__stats {
  display: flex;
  gap: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}
.hero__stat .n {
  font-family: 'Fraunces', serif;
  font-size: 30px;
  color: var(--gold);
  display: block;
}
.hero__stat .l {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

/* hero poster mockup */
.hero__frame-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}
.hero__frame {
  position: relative;
  width: min(100%, 380px);
  aspect-ratio: 1240/1754;
  padding: 16px;
  background: linear-gradient(155deg, #3a2c18, #171008 60%, #2a2011);
  box-shadow: var(--shadow);
  transform: rotate(1.6deg);
  transition: transform .6s var(--ease);
}
[data-theme="light"] .hero__frame {
  background: linear-gradient(155deg, #cbbfa1, #8f8267 60%, #b3a582);
}
.hero__frame:hover { transform: rotate(0deg) scale(1.015); }
.hero__frame-inner {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #111;
}
.hero__frame-inner img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.1s ease;
}
.hero__frame-inner img.is-active { opacity: 1; }
.hero__plaque { text-align: center; }

/* -------------------------------- section shell --------------------------- */
section { position: relative; padding: 120px 0; }
.section-head {
  max-width: 720px;
  margin-bottom: 64px;
}
.section-head h2 {
  font-size: clamp(30px, 3.6vw, 44px);
  text-transform: uppercase;
  margin: 20px 0 18px;
  line-height: 1.08;
}
.section-head p {
  color: var(--ink-muted);
  font-size: 16.5px;
  max-width: 56ch;
}
.section-alt { background: var(--bg-panel); }
.hairline {
  border: none;
  border-top: 1px solid var(--line);
  margin: 0;
}

/* reveal-on-scroll */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* -------------------------------- process --------------------------------- */
.process {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.process__step {
  background: var(--bg);
  padding: 44px 36px;
  position: relative;
}
.process__num {
  font-family: 'Fraunces', serif;
  font-size: 15px;
  color: var(--gold);
  letter-spacing: .08em;
  margin-bottom: 22px;
  display: block;
}
.process__step h3 {
  font-family: 'Fraunces', serif;
  font-size: 22px;
  text-transform: uppercase;
  letter-spacing: .02em;
  margin-bottom: 14px;
}
.process__step p { color: var(--ink-muted); font-size: 15px; }

/* -------------------------------- about ------------------------------------ */
.about .wrap { display: grid; grid-template-columns: .8fr 1.2fr; gap: 80px; align-items: start; }
.about__mark {
  font-family: 'Fraunces', serif;
  font-size: 120px;
  line-height: .8;
  color: var(--gold);
  opacity: .9;
}
.about__body p {
  font-size: 19px;
  line-height: 1.75;
  color: var(--ink);
  margin-bottom: 22px;
}
.about__body p:first-child { font-family: 'Fraunces', serif; font-size: 26px; line-height: 1.5; color: var(--ink); }
.about__body p.muted { color: var(--ink-muted); font-size: 16px; }
.about__sig { margin-top: 36px; display: flex; align-items: center; gap: 16px; }
.about__sig img { height: 30px; width: auto; opacity: .85; }
.about__sig span { font-family: 'JetBrains Mono', monospace; font-size: 11px; letter-spacing: .1em; color: var(--ink-faint); text-transform: uppercase; }

/* -------------------------------- templates -------------------------------- */
.tpl-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
}
.tpl-card { display: flex; flex-direction: column; gap: 14px; }
.tpl-card__frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1240/1754;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  cursor: zoom-in;
}
.tpl-card__frame img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .7s var(--ease), filter .5s ease;
}
.tpl-card:hover .tpl-card__frame img { transform: scale(1.06); }
.tpl-card__frame::after {
  content: "";
  position: absolute; inset: 0;
  border: 1px solid var(--line);
  pointer-events: none;
}
.tpl-card__zoom {
  position: absolute; right: 10px; top: 10px;
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  background: var(--scrim);
  border: 1px solid var(--line-strong);
  opacity: 0;
  transition: opacity .3s var(--ease);
}
.tpl-card__frame:hover .tpl-card__zoom { opacity: 1; }
.tpl-card__zoom svg { width: 14px; height: 14px; color: var(--ink); }
.tpl-card .plaque { padding: 10px 14px; }
.tpl-card .plaque__title { font-size: 10px; }
.tpl-card .plaque__coords { font-size: 10px; }

/* -------------------------------- frames (configurator) -------------------- */
.frames .wrap { display: grid; grid-template-columns: .95fr 1.05fr; gap: 70px; align-items: center; }
.fr-preview { display: flex; flex-direction: column; align-items: center; gap: 20px; }
.fr-preview__frame {
  width: min(100%, 340px);
  aspect-ratio: 1240/1754;
  padding: 18px;
  background: var(--frame-color, #171008);
  box-shadow: var(--shadow);
  transition: background .4s var(--ease);
}
.fr-preview__mat {
  width: 100%; height: 100%;
  background: var(--mat-color, #F3EFE6);
  padding: 14px;
  transition: background .4s var(--ease);
}
.fr-preview__mat img { width: 100%; height: 100%; object-fit: cover; }

.fr-list h3 { font-family: 'Fraunces', serif; font-size: 24px; text-transform: uppercase; margin-bottom: 8px; }
.fr-list > p { color: var(--ink-muted); margin-bottom: 30px; max-width: 44ch; }
.fr-swatches { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-bottom: 34px; }
.fr-swatch {
  display: flex; align-items: center; gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  background: var(--bg-raised);
  text-align: left;
  transition: border-color .3s var(--ease);
}
.fr-swatch:hover, .fr-swatch.is-active { border-color: var(--gold); }
.fr-swatch__dot { width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line-strong); flex-shrink: 0; }
.fr-swatch__label { display: flex; flex-direction: column; gap: 2px; }
.fr-swatch__label b { font-size: 13.5px; font-weight: 500; }
.fr-swatch__label span { font-family: 'JetBrains Mono', monospace; font-size: 10.5px; color: var(--ink-faint); text-transform: uppercase; letter-spacing: .06em; }
.fr-note { font-size: 13.5px; color: var(--ink-faint); border-top: 1px solid var(--line); padding-top: 20px; }

/* -------------------------------- partners ---------------------------------- */
.partners .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 70px; }
.partners h2 { font-size: clamp(28px,3.4vw,42px); text-transform: uppercase; margin: 20px 0 26px; line-height: 1.1; }
.partners p.lede { color: var(--ink-muted); font-size: 17px; max-width: 52ch; margin-bottom: 34px; }
.partners__list { display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--line); }
.partners__item { display: flex; gap: 20px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.partners__item svg { width: 20px; height: 20px; color: var(--gold); flex-shrink: 0; margin-top: 3px; }
.partners__item h4 { font-size: 15.5px; font-weight: 600; margin-bottom: 4px; }
.partners__item p { font-size: 14.5px; color: var(--ink-muted); }
.partners__panel {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  padding: 44px 38px;
  align-self: start;
  position: sticky;
  top: 120px;
}
.partners__panel .eyebrow { margin-bottom: 18px; }
.partners__panel h3 { font-family: 'Fraunces', serif; font-size: 24px; margin-bottom: 16px; line-height: 1.3; }
.partners__panel p { color: var(--ink-muted); font-size: 14.5px; margin-bottom: 28px; }

/* -------------------------------- gallery strip (finished works) ------------ */
.gallery-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 300px;
  gap: 20px;
  overflow-x: auto;
  padding-bottom: 12px;
  scrollbar-width: thin;
}
.gallery-strip::-webkit-scrollbar { height: 6px; }
.gallery-strip::-webkit-scrollbar-thumb { background: var(--line-strong); }
.gallery-strip img {
  width: 100%; aspect-ratio: 1240/1754; object-fit: cover;
  border: 1px solid var(--line);
}

/* -------------------------------- contact ------------------------------------ */
.contact .wrap { display: grid; grid-template-columns: .85fr 1.15fr; gap: 70px; }
.contact__info h2 { font-size: clamp(30px,3.6vw,44px); text-transform: uppercase; margin: 20px 0 22px; line-height: 1.1; }
.contact__info > p { color: var(--ink-muted); max-width: 42ch; margin-bottom: 40px; }
.contact__row { display: flex; align-items: center; gap: 16px; padding: 18px 0; border-top: 1px solid var(--line); }
.contact__row:last-of-type { border-bottom: 1px solid var(--line); }
.contact__row svg { width: 18px; height: 18px; color: var(--gold); flex-shrink: 0; }
.contact__row a, .contact__row span { font-size: 14.5px; }
.contact__social { display: flex; gap: 14px; margin-top: 28px; }

.form {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  padding: 44px;
}
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field.full { grid-column: 1 / -1; }
.field label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.field input, .field select, .field textarea {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line-strong);
  padding: 10px 2px;
  color: var(--ink);
  font-family: 'Inter', sans-serif;
  font-size: 14.5px;
  transition: border-color .3s var(--ease);
}
.field select { appearance: none; -webkit-appearance: none; background: transparent; cursor: pointer; }
.field select option { background: var(--bg-raised); color: var(--ink); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--gold); }
.field textarea { resize: vertical; min-height: 100px; }
.form__foot { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 10px; flex-wrap: wrap; }
.form__note { font-size: 12.5px; color: var(--ink-faint); max-width: 32ch; }
.form__status { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: var(--gold); min-height: 16px; }

/* -------------------------------- footer -------------------------------------- */
footer {
  border-top: 1px solid var(--line);
  padding: 60px 0 36px;
}
.footer__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; flex-wrap: wrap; margin-bottom: 48px; }
.footer__brand { display: flex; align-items: center; gap: 12px; }
.footer__brand img { height: 30px; }
.footer__brand span { font-family: 'Fraunces', serif; font-size: 18px; }
.footer__tag { color: var(--ink-faint); font-size: 13.5px; margin-top: 12px; max-width: 34ch; }
.footer__cols { display: flex; gap: 64px; flex-wrap: wrap; }
.footer__col h5 {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 16px;
}
.footer__col a, .footer__col p { display: block; font-size: 14px; color: var(--ink-muted); margin-bottom: 10px; }
.footer__col a:hover { color: var(--gold); }
.footer__bottom {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  padding-top: 28px; border-top: 1px solid var(--line);
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px; letter-spacing: .04em;
  color: var(--ink-faint);
}

/* -------------------------------- lightbox ------------------------------------ */
.lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(6,8,11,.92);
  display: flex; align-items: center; justify-content: center;
  padding: 40px;
  opacity: 0; pointer-events: none;
  transition: opacity .35s var(--ease);
}
.lightbox.is-open { opacity: 1; pointer-events: all; }
.lightbox__inner { max-width: 560px; width: 100%; display: flex; flex-direction: column; align-items: center; gap: 20px; }
.lightbox__inner img { width: 100%; border: 1px solid rgba(255,255,255,.18); }
.lightbox__close {
  position: absolute; top: 30px; right: 30px;
  width: 44px; height: 44px;
  border: 1px solid rgba(255,255,255,.24);
  background: transparent; color: #F3EFE6;
  display: flex; align-items: center; justify-content: center;
}
.lightbox__close svg { width: 18px; height: 18px; }

/* -------------------------------- responsive ------------------------------------ */
@media (max-width: 1080px) {
  .tpl-grid { grid-template-columns: repeat(2, 1fr); }
  .about .wrap, .partners .wrap, .contact .wrap, .frames .wrap { grid-template-columns: 1fr; }
  .about__mark { display: none; }
  .partners__panel { position: static; }
  .hero .wrap { grid-template-columns: 1fr; }
  .hero__frame-wrap { order: -1; margin-bottom: 20px; }
}
@media (max-width: 760px) {
  .wrap { padding: 0 20px; }
  .nav__links { display: none; }
  .nav__burger { display: flex; }
  .hero { padding: 140px 0 80px; }
  .process { grid-template-columns: 1fr; }
  .tpl-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  section { padding: 80px 0; }
  .form__row { grid-template-columns: 1fr; }
  .hero__stats { gap: 26px; flex-wrap: wrap; }
  .footer__cols { gap: 36px; }
}
@media (max-width: 480px) {
  .tpl-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
}

/* nav mobile drawer */
.nav__drawer {
  position: fixed; inset: 84px 0 0 0; z-index: 99;
  background: var(--bg);
  padding: 32px;
  display: none;
  flex-direction: column;
  gap: 26px;
  border-top: 1px solid var(--line);
}
.nav__drawer.is-open { display: flex; }
.nav__drawer a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink);
}
