@font-face {
  font-family: "Geist";
  src: url("./assets/geist.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --canvas: #fbfaf7;
  --paper: #fbfaf7;
  --ink: #0a0a0a;
  --soft-ink: #42413d;
  --muted: #77736d;
  --line: rgba(10, 10, 10, 0.1);
  --bezel: transparent;
  --ease-heavy: cubic-bezier(0.32, 0.72, 0, 1);
  font-family: "Proxima Nova", "Geist", "Avenir Next", sans-serif;
  color: var(--ink);
  background: #ecebe8;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { min-width: 320px; min-height: 100%; background: #ecebe8; }
body { margin: 0; min-height: 100dvh; background: #ecebe8; -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; cursor: pointer; }
svg { display: block; fill: none; stroke: currentColor; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 1.5px solid var(--ink); outline-offset: 4px; }

.grain {
  position: fixed;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  opacity: .012;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.58'/%3E%3C/svg%3E");
}

.phone {
  position: relative;
  width: min(100%, 393px);
  min-height: 100dvh;
  margin: 0 auto;
  overflow: hidden;
  background: var(--canvas);
  box-shadow: 0 0 0 1px rgba(10,10,10,.035);
}

.topbar {
  display: flex;
  align-items: center;
  height: 64px;
  padding: env(safe-area-inset-top) 20px 0;
  background: transparent;
}

.round-action {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--line);
  transition: transform 600ms var(--ease-heavy), background 600ms var(--ease-heavy);
}
.round-action:hover { transform: rotate(8deg) scale(1.03); background: #fff; }
.round-action:active { transform: scale(.95); }
.round-action svg { width: 18px; height: 18px; }

.setup { padding: 22px 24px calc(24px + env(safe-area-inset-bottom)); }
.intro { margin-bottom: 30px; }
.eyebrow { display: flex; align-items: center; gap: 9px; margin: 0 0 14px; color: var(--muted); font-size: 9px; font-weight: 630; letter-spacing: .18em; text-transform: uppercase; }
.eyebrow > span { width: 17px; height: 1px; background: currentColor; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 16px; font-family: "PP Right Grotesk", "Geist", sans-serif; font-size: 46px; font-weight: 450; letter-spacing: -.065em; line-height: .91; }
h1 em { color: #a7a39b; font-weight: 400; }
.intro-copy { max-width: 292px; margin: 0; color: var(--soft-ink); font-size: 14px; line-height: 1.42; }

.preview-shell { padding: 0; border-radius: 0; background: transparent; box-shadow: inset 0 1px var(--line), inset 0 -1px var(--line); }
.preview-core { overflow: hidden; min-height: 174px; border-radius: 0; color: var(--ink); background: transparent; box-shadow: none; transition: background 800ms var(--ease-heavy); }
.preview-head { display: flex; justify-content: space-between; gap: 16px; padding: 15px 0 8px; color: var(--muted); font-size: 8px; letter-spacing: .09em; text-transform: uppercase; }
.preview-head span:first-child { color: var(--ink); font-weight: 620; }
.score-sheet { position: relative; height: 122px; margin: 0; overflow: hidden; border-radius: 0; background: transparent; }
.staff { width: 100%; height: 100%; color: #22211e; transition: opacity 700ms var(--ease-heavy), transform 700ms var(--ease-heavy); }
.staff-lines { stroke: rgba(34,33,30,.29); stroke-width: 1; }
.music { fill: currentColor; stroke-width: 1.6; }
.music .barline { fill: none; stroke-width: .8; }
.cue-line { stroke: #78746d; stroke-width: 1; stroke-dasharray: 2 4; }
.screen-free-calm { position: absolute; inset: 0; display: grid; place-items: center; opacity: 0; transform: translateY(18px); transition: opacity 700ms var(--ease-heavy), transform 700ms var(--ease-heavy); }
.screen-free-calm { align-content: center; gap: 5px; color: var(--ink); }
.screen-free-calm i { grid-area: 1 / 1; width: 58px; height: 58px; border-radius: 50%; border: 1px solid rgba(10,10,10,.16); }
.screen-free-calm i:nth-child(2) { transform: scale(.68); opacity: .72; }
.screen-free-calm i:nth-child(3) { width: 8px; height: 8px; border: 0; background: var(--ink); }
.screen-free-calm span { margin-top: 13px; color: var(--muted); font-size: 8px; letter-spacing: .14em; text-transform: uppercase; }
.preview-core[data-preview="screen-free"] .staff { opacity: 0; transform: scale(.96); }
.preview-core[data-preview="screen-free"] .screen-free-calm { opacity: 1; transform: translateY(0); }
.preview-core[data-preview="screen-free"] .score-sheet { background: transparent; }

.mode-picker { display: block; margin: 30px 0 22px; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.mode-picker legend { float: none; width: 100%; margin: 0 0 7px; padding: 0; color: var(--muted); font-size: 9px; font-weight: 620; letter-spacing: .16em; text-transform: uppercase; }
.mode-list-shell { display: grid; gap: 0; box-shadow: inset 0 -1px var(--line); }
.mode-option { display: grid; grid-template-columns: 32px 1fr 18px; gap: 14px; align-items: center; width: 100%; min-height: 62px; padding: 10px 2px; border: 0; border-radius: 0; text-align: left; background: transparent; box-shadow: inset 0 1px var(--line); transition: opacity 650ms var(--ease-heavy), transform 650ms var(--ease-heavy); }
.mode-option:hover { transform: translateX(2px); }
.mode-option.is-selected { color: var(--ink); background: transparent; box-shadow: inset 0 1px rgba(10,10,10,.28); }
.mode-icon { position: relative; display: flex; align-items: flex-end; justify-content: center; gap: 2px; width: 32px; height: 32px; border-radius: 50%; color: var(--ink); background: transparent; box-shadow: inset 0 0 0 1px rgba(10,10,10,.12); }
.mode-icon > i { width: 2px; height: 10px; border-radius: 3px; background: currentColor; }
.mode-icon > i:nth-child(2) { height: 17px; }.mode-icon > i:nth-child(3) { height: 13px; }
.calm-icon { align-items: center; }
.calm-icon i { width: 10px; height: 10px; border-radius: 50%; box-shadow: 0 0 0 4px rgba(10,10,10,.07); }
.mode-copy { display: grid; gap: 3px; min-width: 0; }
.mode-copy strong { font-size: 13px; font-weight: 580; }
.mode-copy small { overflow: hidden; color: var(--muted); font-size: 9px; line-height: 1.3; text-overflow: ellipsis; white-space: nowrap; }
.mode-option.is-selected small { color: var(--muted); }
.selection-mark { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(10,10,10,.18); }
.mode-option.is-selected .selection-mark { background: transparent; box-shadow: inset 0 0 0 1px var(--ink); }
.mode-option.is-selected .selection-mark::after { width: 8px; height: 8px; border-radius: 50%; background: var(--ink); content: ""; }

.primary-action { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 56px; padding: 6px 7px 6px 21px; border: 0; border-radius: 999px; color: #fff; background: #0b0b0a; font-size: 14px; font-weight: 590; box-shadow: none; transition: transform 650ms var(--ease-heavy); }
.primary-action:hover { transform: translateY(-3px); }
.primary-action:active { transform: scale(.98); }
.action-orbit { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: #0b0b0a; background: #f4f1ea; transition: transform 650ms var(--ease-heavy); }
.primary-action:hover .action-orbit { transform: translateX(2px) scale(1.05); }
.action-orbit svg { width: 20px; height: 20px; }
.restore-note { margin: 12px 0 0; color: var(--muted); font-size: 9px; text-align: center; }

.reveal { opacity: 0; transform: translateY(28px); filter: blur(7px); transition: opacity 900ms var(--ease-heavy), transform 900ms var(--ease-heavy), filter 900ms var(--ease-heavy); }
.reveal.is-visible { opacity: 1; transform: translateY(0); filter: blur(0); }
.preview-shell.reveal { transition-delay: 90ms; }
.mode-picker.reveal { transition-delay: 170ms; }
.primary-action.reveal { transition-delay: 240ms; }
.restore-note.reveal { transition-delay: 280ms; }

.zen-experience { position: fixed; inset: 0; z-index: 3; display: grid; place-items: center; overflow: hidden; padding: 68px 24px 32px; color: #f7f3eb; background: #0b0b0a; opacity: 0; transform: scale(1.035); pointer-events: none; transition: opacity 850ms var(--ease-heavy), transform 850ms var(--ease-heavy); }
.zen-experience.is-active { opacity: 1; transform: scale(1); pointer-events: auto; }
.exit-hint { position: absolute; top: calc(18px + env(safe-area-inset-top)); left: 50%; min-height: 44px; padding: 0 18px; border: 0; border-radius: 999px; color: rgba(255,255,255,.56); background: rgba(255,255,255,.07); font-size: 9px; letter-spacing: .06em; transform: translateX(-50%); transition: color 600ms var(--ease-heavy), transform 600ms var(--ease-heavy); white-space: nowrap; }
.exit-hint:hover { color: #fff; transform: translateX(-50%) translateY(2px); }
.zen-score { width: min(100%, 620px); }
.zen-score > p { margin-bottom: 16px; color: rgba(255,255,255,.48); font-size: 10px; letter-spacing: .12em; text-align: center; text-transform: uppercase; }
.zen-paper { overflow: hidden; padding: 16px 5px; border-radius: 2px; color: #22211e; background: #f7f4ec; box-shadow: 0 38px 100px rgba(0,0,0,.22); }
.zen-paper svg { width: 100%; }
.zen-paper .staff-lines { stroke: rgba(34,33,30,.28); stroke-width: 1; }
.zen-notes { fill: currentColor; stroke-width: 1.7; }
.zen-position { display: grid; grid-template-columns: auto 1fr auto; gap: 13px; align-items: center; margin-top: 21px; color: rgba(255,255,255,.44); font-size: 9px; }
.zen-position i { height: 1px; background: rgba(255,255,255,.14); }
.zen-position i::after { display: block; width: 43%; height: 100%; background: rgba(255,255,255,.85); content: ""; }
.zen-calm { display: none; text-align: center; }
.zen-calm > p { color: rgba(255,255,255,.4); font-size: 9px; letter-spacing: .17em; text-transform: uppercase; }
.zen-calm span { color: rgba(255,255,255,.39); font-size: 10px; }
.breath { display: grid; place-items: center; width: 170px; height: 170px; margin: 0 auto 34px; }
.breath i { grid-area: 1 / 1; width: 130px; height: 130px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(255,255,255,.16); animation: breathe 5s var(--ease-heavy) infinite alternate; }
.breath i:nth-child(2) { width: 82px; height: 82px; animation-delay: -1.4s; }
.breath i:nth-child(3) { width: 14px; height: 14px; background: #f4f0e7; box-shadow: none; animation-delay: -2.7s; }
.zen-experience[data-mode="screen-free"] .zen-score { display: none; }
.zen-experience[data-mode="screen-free"] .zen-calm { display: block; }

@keyframes breathe { from { opacity: .35; transform: scale(.88); } to { opacity: 1; transform: scale(1.08); } }

.case-study-layout { display: grid; grid-template-columns: minmax(0, 460px) 393px; align-items: center; justify-content: space-between; gap: 64px; width: min(100% - 96px, 1080px); margin: 0 auto; padding: 48px 0; }
.case-study { padding: 24px 0; }
.case-study .eyebrow { margin-bottom: 30px; font-size: 10px; }
.case-study h2 { margin: 0 0 24px; font-family: "PP Right Grotesk", "Geist", sans-serif; font-size: clamp(44px, 4.6vw, 64px); font-weight: 450; letter-spacing: -.065em; line-height: 1; }
.case-lead { max-width: 370px; margin-bottom: 40px; color: var(--soft-ink); font-size: 18px; line-height: 1.5; }
.case-notes { margin: 0; }
.case-notes > div { padding: 20px 0; border-top: 1px solid var(--line); }
.case-notes dt { margin-bottom: 8px; font-size: 11px; font-weight: 600; }
.case-notes dd { max-width: 390px; margin: 0; color: var(--soft-ink); font-size: 14px; line-height: 1.6; }
.case-caption { display: flex; align-items: center; gap: 12px; margin: 25px 0 0; color: var(--muted); font-size: 11px; }
.case-study-layout .phone { min-height: 780px; border-radius: 28px; }

@media (max-width: 900px) {
  .case-study-layout { grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 40px; width: min(100% - 48px, 560px); padding: 32px 0; }
  .case-study { width: 100%; }
  .case-study h2 { font-size: 48px; }
  .case-lead, .case-notes dd { max-width: none; }
}

@media (max-width: 440px) {
  .case-study-layout { width: 100%; padding: 16px 0 0; }
  .case-study { padding: 24px; }
  .case-study-layout .phone { border-radius: 0; min-height: 100dvh; }
}

@media (max-width: 380px) {
  .setup { padding-inline: 18px; }
  h1 { font-size: 42px; }
  .mode-copy small { max-width: 205px; }
}

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