:root {
  --blue: #a9cbe2;
  --blue-deep: #79a8c8;
  --ink: #241915;
  --brown: #4c2c23;
  --burgundy: #731f33;
  --cream: #f2eadf;
  --paper: #faf6ee;
  --line: rgba(36, 25, 21, 0.32);
  --mx: 50vw;
  --my: 50vh;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--blue);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 16px;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  background: radial-gradient(circle 180px at var(--mx) var(--my), transparent 0 70%, rgba(250,246,238,0.08) 100%);
  opacity: 0;
  transition: opacity .25s ease;
}
body.skin-mode::before { opacity: 1; }
a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }

.grain {
  position: fixed;
  inset: 0;
  opacity: .17;
  pointer-events: none;
  z-index: 30;
  background-image: url("assets/grain.svg");
  mix-blend-mode: multiply;
  transition: opacity .45s ease;
}
.cleanser {
  position: fixed;
  z-index: 31;
  width: 190px;
  height: 190px;
  left: var(--mx);
  top: var(--my);
  border: 1px solid rgba(255,255,255,.65);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(.7);
  pointer-events: none;
  opacity: 0;
  box-shadow: inset 0 0 0 5px rgba(255,255,255,.08), 0 0 40px rgba(255,255,255,.12);
  transition: opacity .2s ease, transform .25s ease;
}
body.skin-mode .grain { opacity: .03; }
body.skin-mode .cleanser { opacity: 1; transform: translate(-50%, -50%) scale(1); }

.site-header {
  min-height: 74px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  padding: 14px clamp(18px, 3.6vw, 64px);
  border-bottom: 1px solid var(--ink);
  background: rgba(169, 203, 226, .9);
  backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 25;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-size: .8rem; font-weight: 800; letter-spacing: .12em; }
.brand-mark { display: grid; place-items: center; width: 38px; aspect-ratio: 1; border-radius: 50%; background: var(--ink); color: var(--cream); font: 700 .8rem Georgia, serif; }
nav { display: flex; gap: 34px; }
nav a { font-size: .75rem; letter-spacing: .13em; text-decoration: none; text-transform: uppercase; border-bottom: 1px solid transparent; }
nav a:hover, nav a:focus-visible { border-color: currentColor; }
.skin-toggle {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: transparent;
  padding: 10px 15px 10px 10px;
  cursor: pointer;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .1em;
}
.toggle-dot { width: 19px; height: 19px; border-radius: 50%; background: var(--burgundy); box-shadow: inset 0 0 0 4px var(--cream); transition: transform .35s ease, background .35s ease; }
.skin-toggle[aria-pressed="true"] .toggle-dot { background: var(--ink); transform: rotate(180deg) scale(.75); }

.hero {
  min-height: calc(100vh - 74px);
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(420px, 1.08fr);
  border-bottom: 1px solid var(--ink);
}
.hero-copy {
  min-width: 0;
  padding: clamp(42px, 6vw, 96px) clamp(22px, 5vw, 82px) 50px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-right: 1px solid var(--ink);
  position: relative;
}
.eyebrow-line { display: flex; justify-content: space-between; gap: 20px; font-size: .72rem; letter-spacing: .14em; font-weight: 800; margin-bottom: 28px; }
h1, h2, .footer-wordmark { margin: 0; font-family: "Arial Narrow", Impact, sans-serif; font-stretch: condensed; font-weight: 900; letter-spacing: -.065em; line-height: .82; text-transform: uppercase; }
h1 { font-size: clamp(4.7rem, 9.5vw, 10rem); }
h1 em, h2 em { font-family: Georgia, serif; font-weight: 400; letter-spacing: -.08em; color: var(--burgundy); }
.hero-narrative { max-width: 660px; font: 1.15rem/1.48 Georgia, serif; margin: 28px 0; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; }
.button { min-height: 54px; padding: 0 19px; display: inline-flex; align-items: center; justify-content: space-between; gap: 28px; border: 1px solid var(--ink); text-decoration: none; font-size: .78rem; font-weight: 800; letter-spacing: .08em; transition: transform .2s ease, background .2s ease, color .2s ease; }
.button:hover, .button:focus-visible { transform: translateY(-3px); }
.button-primary { background: var(--ink); color: var(--cream); min-width: 230px; }
.button-secondary { background: var(--cream); min-width: 190px; }
.contract { margin-top: 17px; border: 1px solid var(--ink); background: rgba(250,246,238,.38); }
.contract-label { padding: 8px 11px; border-bottom: 1px solid var(--ink); font-size: .65rem; font-weight: 800; letter-spacing: .12em; display: flex; justify-content: space-between; }
.contract-label span { color: var(--burgundy); }
.contract-row { display: flex; align-items: stretch; min-width: 0; }
.contract code { flex: 1; min-width: 0; padding: 15px 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .75rem; }
.copy-button { width: 83px; border: 0; border-left: 1px solid var(--ink); background: var(--burgundy); color: white; cursor: pointer; font-size: .7rem; font-weight: 800; letter-spacing: .1em; }
.copy-button:hover, .copy-button:focus-visible { background: var(--ink); }

.portrait-stage {
  min-height: 720px;
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: radial-gradient(circle at 70% 25%, rgba(255,255,255,.46), transparent 24%), linear-gradient(135deg, var(--blue) 0 58%, var(--blue-deep) 58% 100%);
}
.portrait-card { width: min(74%, 610px); margin: 0; position: relative; z-index: 2; border: 1px solid var(--ink); background: var(--paper); box-shadow: 22px 22px 0 var(--brown); transform: rotate(1.2deg); transition: box-shadow .5s ease, transform .5s ease; }
.portrait-card img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; filter: saturate(.86) contrast(1.04); }
.portrait-card figcaption { display: flex; justify-content: space-between; padding: 11px 13px; border-top: 1px solid var(--ink); font-size: .67rem; font-weight: 800; letter-spacing: .12em; }
.orbit { position: absolute; border: 1px solid rgba(36,25,21,.36); border-radius: 50%; transition: opacity .45s ease, transform .45s ease; }
.orbit-one { width: 78%; aspect-ratio: 1; }
.orbit-two { width: 112%; aspect-ratio: 1; transform: rotate(38deg); border-style: dashed; }
.sticker { position: absolute; z-index: 4; background: var(--cream); border: 1px solid var(--ink); padding: 8px 12px; font-size: .65rem; font-weight: 900; letter-spacing: .1em; box-shadow: 5px 5px 0 var(--ink); transition: opacity .35s ease, transform .35s ease; }
.sticker-one { top: 14%; left: 6%; transform: rotate(-9deg); }
.sticker-two { top: 22%; right: 4%; transform: rotate(7deg); background: var(--burgundy); color: white; }
.sticker-three { bottom: 17%; left: 3%; transform: rotate(4deg); }
.identity-tag { position: absolute; z-index: 4; right: 4%; bottom: 5%; display: flex; align-items: flex-start; gap: 5px; color: var(--cream); text-shadow: 3px 3px 0 var(--burgundy); transform: rotate(-3deg); transition: opacity .35s ease; }
.identity-tag span { font: 2rem Georgia, serif; }
.identity-tag strong { font: 900 clamp(2.6rem, 5.5vw, 5.5rem)/.75 Impact, sans-serif; letter-spacing: -.05em; }
body.skin-mode .sticker, body.skin-mode .identity-tag { opacity: 0; transform: scale(.5); }
body.skin-mode .orbit { opacity: .08; transform: scale(.82); }
body.skin-mode .portrait-card { transform: rotate(0); box-shadow: 0 0 0 1px rgba(36,25,21,.25); }

.ticker { overflow: hidden; background: var(--burgundy); color: var(--cream); border-bottom: 1px solid var(--ink); }
.ticker-track { width: max-content; display: flex; align-items: center; gap: 28px; padding: 14px 0; animation: ticker 24s linear infinite; font-size: .78rem; font-weight: 900; letter-spacing: .16em; }
.ticker-track i { font-style: normal; font-size: .5rem; }
@keyframes ticker { to { transform: translateX(-50%); } }

.story, .anatomy, .ritual { padding: clamp(70px, 9vw, 145px) clamp(22px, 6vw, 100px); border-bottom: 1px solid var(--ink); }
.story { background: var(--cream); }
.section-index { font-size: .7rem; font-weight: 800; letter-spacing: .15em; margin-bottom: 46px; }
.story-grid { display: grid; grid-template-columns: 1.3fr .7fr; gap: clamp(40px, 8vw, 140px); align-items: end; }
h2 { font-size: clamp(4.4rem, 8.6vw, 9.2rem); }
.story-copy { max-width: 550px; }
.story-copy p { font: 1.12rem/1.62 Georgia, serif; }
.story-copy .disclaimer { margin-top: 38px; padding-top: 16px; border-top: 1px solid var(--ink); font: 700 .73rem/1.45 Arial, sans-serif; letter-spacing: .08em; text-transform: uppercase; }

.anatomy { background: var(--brown); color: var(--cream); }
.anatomy .section-index { color: var(--blue); }
.anatomy h2 { max-width: 1080px; }
.specimen-grid { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid rgba(242,234,223,.55); margin-top: 70px; }
.specimen { min-height: 360px; padding: 26px; display: flex; flex-direction: column; border-right: 1px solid rgba(242,234,223,.55); position: relative; }
.specimen:last-child { border-right: 0; }
.specimen-number { font-size: .68rem; letter-spacing: .12em; }
.specimen-icon { font: 6rem/1 Georgia, serif; color: var(--blue); margin: auto 0; }
.specimen h3 { margin: 0 0 10px; font-size: 2rem; letter-spacing: -.04em; }
.specimen p { margin: 0; max-width: 300px; color: rgba(242,234,223,.78); line-height: 1.5; }

.ritual { background: var(--blue); display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(50px, 10vw, 160px); align-items: center; }
.ritual-copy p { max-width: 500px; font: 1.08rem/1.55 Georgia, serif; }
.ritual-button { margin-top: 18px; border: 1px solid var(--ink); background: var(--ink); color: var(--cream); padding: 17px 21px; font-size: .75rem; font-weight: 800; letter-spacing: .09em; cursor: pointer; }
.cleaning-card { min-height: 520px; border: 1px solid var(--ink); position: relative; overflow: hidden; padding: 26px; display: flex; flex-direction: column; justify-content: space-between; background: repeating-linear-gradient(90deg, transparent 0 40px, rgba(36,25,21,.08) 40px 41px), repeating-linear-gradient(0deg, transparent 0 40px, rgba(36,25,21,.08) 40px 41px); }
.cleaning-card strong { font: 900 clamp(4rem, 8vw, 8rem)/.78 Impact, sans-serif; letter-spacing: -.05em; }
.cleaning-card span, .cleaning-card small { font-weight: 800; letter-spacing: .12em; }
.scan-line { position: absolute; left: 0; right: 0; height: 2px; background: var(--burgundy); box-shadow: 0 0 20px var(--burgundy); animation: scan 3.3s ease-in-out infinite alternate; }
@keyframes scan { from { top: 8%; } to { top: 92%; } }

footer { background: var(--ink); color: var(--cream); padding: 70px clamp(22px, 6vw, 100px) 30px; }
.footer-wordmark { font-size: clamp(4rem, 11vw, 12rem); white-space: nowrap; }
.footer-row { display: flex; justify-content: space-between; gap: 20px; border-top: 1px solid rgba(242,234,223,.4); margin-top: 45px; padding-top: 18px; font-size: .72rem; font-weight: 800; letter-spacing: .12em; }
.toast { position: fixed; z-index: 50; left: 50%; bottom: 24px; transform: translate(-50%, 130%); background: var(--ink); color: var(--cream); padding: 14px 20px; border: 1px solid var(--cream); font-size: .72rem; font-weight: 800; letter-spacing: .1em; transition: transform .35s ease; }
.toast.show { transform: translate(-50%, 0); }

@media (max-width: 940px) {
  .site-header { grid-template-columns: 1fr auto; }
  nav { display: none; }
  .hero { grid-template-columns: 1fr; }
  .hero-copy { border-right: 0; border-bottom: 1px solid var(--ink); }
  .portrait-stage { min-height: 680px; }
  .story-grid, .ritual { grid-template-columns: 1fr; }
  .story-copy { max-width: 700px; }
  .specimen-grid { grid-template-columns: 1fr; }
  .specimen { min-height: 250px; border-right: 0; border-bottom: 1px solid rgba(242,234,223,.55); }
  .specimen:last-child { border-bottom: 0; }
  .specimen-icon { margin: 38px 0; }
}

@media (min-width: 941px) {
  h1 { font-size: clamp(4.7rem, 6.5vw, 7.8rem); }
}

@media (max-width: 560px) {
  .site-header { min-height: 64px; padding: 11px 14px; }
  .brand > span:last-child { display: none; }
  .skin-toggle { padding-right: 11px; }
  .hero { min-height: auto; }
  .hero-copy { padding: 42px 17px 35px; }
  .eyebrow-line { font-size: .59rem; }
  h1 { font-size: clamp(3.3rem, 18.5vw, 5rem); }
  .hero-narrative { font-size: 1rem; }
  .actions, .button { width: 100%; }
  .portrait-stage { min-height: 500px; }
  .portrait-card { width: 78%; box-shadow: 12px 12px 0 var(--brown); }
  .sticker-two { top: 10%; }
  .identity-tag { bottom: 2%; }
  .story, .anatomy, .ritual { padding: 64px 17px; }
  h2 { font-size: clamp(3.7rem, 18vw, 5.8rem); }
  .section-index { margin-bottom: 30px; }
  .specimen-grid { margin-top: 45px; }
  .cleaning-card { min-height: 380px; }
  .footer-wordmark { font-size: 17vw; }
  .footer-row { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

:focus-visible { outline: 3px solid var(--burgundy); outline-offset: 3px; }
body.skin-mode .sticker, body.skin-mode .orbit, body.skin-mode .identity-tag, body.skin-mode .grain { pointer-events: none; }
