/* Altavo. Light liquid glass; the films carry the colour. Tokens from DESIGN.md. */

:root {
  --canvas: #ECEEF1;
  --ink: #1D1D1F;
  --ink-2: #5F6066;
  --ink-nav: #3A3B40;
  --hairline: rgba(0, 0, 0, 0.08);
  --film-backdrop: #16171A;
  /* Sampled from the diffuser's status LED (hue 118°), darkened to 4:1 on the panel. */
  --cut-marker: #238820;

  --sans: -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;

  --gutter: clamp(20px, 4vw, 56px);
  --section: clamp(56px, 7vw, 104px);
  --container: 1360px;

  --r-card: 28px;
  --r-panel: 36px;
  --r-film: 22px;

  --glass-faux-bg: rgba(255, 255, 255, 0.72);
  --glass-faux-border: rgba(255, 255, 255, 0.8);
  --glass-faux-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 12px 32px rgba(17, 24, 39, 0.08);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  color-scheme: light;
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 104px;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(ellipse 80% 40% at 50% 0%, #FFFFFF 0%, rgba(255, 255, 255, 0) 70%) no-repeat,
    var(--canvas);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.47;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

main { flex: 1 0 auto; }

h1, h2, h3, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, video, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }

a { color: inherit; text-underline-offset: 0.18em; text-decoration-thickness: 1px; }

::selection { background: rgba(29, 29, 31, 0.86); color: #FFFFFF; }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-top: var(--section); }

/* Mono labels: sentence case in HTML, uppercased here. */
.label {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 400;
  line-height: 1.4;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
}
@media (min-width: 600px) { .label { font-size: 11px; } }

.lead {
  font-size: clamp(17px, 1.5vw, 21px);
  line-height: 1.45;
  color: var(--ink-2);
}

/* ---------- Glass ---------- */

.glass-faux {
  background: var(--glass-faux-bg);
  border: 1px solid var(--glass-faux-border);
  box-shadow: var(--glass-faux-shadow);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 160ms var(--ease-out), transform 160ms var(--ease-out), box-shadow 160ms var(--ease-out);
}
.btn:active { transform: scale(0.98); }

.btn-primary {
  height: 46px;
  padding: 0 22px;
  background: rgba(29, 29, 31, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 6px 16px rgba(0, 0, 0, 0.18);
  color: #FFFFFF;
}
.btn-primary:hover { background: rgba(0, 0, 0, 0.92); }
.btn-large { height: 56px; font-size: 17px; padding: 0 28px; }

.btn-film {
  height: 44px;
  padding: 0 18px;
  /* DESIGN.md's white 14% glass fails 4.5:1 over the film's bright frames; a dark tint keeps white text >= 4.5:1 on any frame. */
  background: rgba(29, 29, 31, 0.55);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  backdrop-filter: blur(14px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), 0 8px 24px rgba(0, 0, 0, 0.25);
  color: #FFFFFF;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.btn-film:hover { background: rgba(29, 29, 31, 0.68); }
.btn-film:focus-visible { outline-color: #FFFFFF; }
.btn-film svg { flex: none; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 16px max(16px, calc((100% - var(--container)) / 2 + var(--gutter) - 16px)) 0;
  pointer-events: none;
}

.header-pill {
  pointer-events: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
  padding: 0 8px 0 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 8px 24px rgba(17, 24, 39, 0.08);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-decoration: none;
  color: var(--ink);
}

.header-end { display: flex; align-items: center; gap: clamp(16px, 2.2vw, 32px); }

.site-nav { display: none; }
.site-nav ul { display: flex; gap: clamp(16px, 2.2vw, 28px); }
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 15px;
  color: var(--ink-nav);
  text-decoration: none;
  transition: color 160ms var(--ease-out);
}
.site-nav a:hover { color: var(--ink); }

@media (min-width: 760px) { .site-nav { display: block; } }

@media (max-width: 400px) {
  .header-pill { height: 60px; padding-left: 20px; padding-right: 6px; }
  .header-pill .btn-primary { height: 46px; padding: 0 18px; }
}

/* ---------- Hero (home) ---------- */

.hero { padding-top: clamp(40px, 6vw, 88px); }

.display {
  font-size: clamp(40px, 5.6vw, 80px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.035em;
  max-width: 12em;
  text-wrap: balance;
}

.hero .lead { margin-top: 20px; max-width: 34em; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.chip {
  display: inline-flex;
  align-items: center;
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow: inset 0 1px 0 #FFFFFF, 0 2px 8px rgba(17, 24, 39, 0.05);
  font-size: 14px;
  color: var(--ink);
}

/* ---------- Section headings ---------- */

.h-small {
  font-size: clamp(24px, 2.4vw, 32px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
}

.h-section {
  font-size: clamp(28px, 3vw, 44px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.section-head { margin-bottom: 24px; }

/* ---------- Film (shared) ---------- */

.film {
  position: relative;
  overflow: hidden;
  aspect-ratio: 9 / 16;
  border-radius: var(--r-film);
  background: var(--film-backdrop);
  isolation: isolate;
}
.film video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.film-play {
  position: absolute;
  left: 50%;
  top: 50%;
  translate: -50% -50%;
  display: none;
}
.film.is-blocked .film-play { display: inline-flex; }

.film-sound {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 0 14px 0 12px;
}
.film-sound .icon-on { display: none; }
.film-sound[aria-pressed="true"] .icon-on { display: block; }
.film-sound[aria-pressed="true"] .icon-off { display: none; }
.film.is-blocked .film-sound { display: none; }

/* ---------- Style feature row (home, one style) ---------- */

.style-feature {
  display: grid;
  gap: 20px;
  padding: 12px;
  border-radius: var(--r-card);
}

.style-feature .film {
  width: 100%;
  max-width: calc(86svh * 9 / 16);
  justify-self: center;
}

.style-feature .film-link {
  position: absolute;
  left: 12px;
  bottom: 12px;
}

.style-meta { padding: 4px 10px 10px; }
.style-meta .style-name {
  margin-top: 6px;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
}
.style-meta .style-line {
  margin-top: 6px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--ink-2);
  max-width: 26em;
}
.style-meta .spec { margin-top: 12px; }

@media (min-width: 600px) {
  .style-feature {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: end;
    gap: clamp(32px, 4vw, 64px);
  }
  .style-feature .film {
    height: min(76svh, 720px);
    width: auto;
    max-width: none;
  }
  .style-meta { padding: 0 clamp(8px, 2vw, 32px) clamp(16px, 3vw, 40px) 0; }
  .style-meta .style-name {
    margin-top: 12px;
    font-size: clamp(32px, 3.4vw, 52px);
    line-height: 1.04;
    letter-spacing: -0.03em;
    font-weight: 700;
  }
  .style-meta .style-line { margin-top: 14px; font-size: clamp(17px, 1.5vw, 21px); }
  .style-meta .spec { margin-top: 24px; }
}

/* ---------- Style page hero + player ---------- */

.style-hero { padding-top: clamp(24px, 4vw, 56px); }

.style-hero-grid { display: grid; gap: 20px; }

.display-style {
  font-size: clamp(34px, 4.8vw, 72px);
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.style-hero .lead { margin-top: 12px; max-width: 34em; }

.player {
  justify-self: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
}

.player-panel {
  --film-h: clamp(360px, calc(100svh - 300px), 520px);
  padding: 12px;
  border-radius: var(--r-card);
}
.player-panel .film {
  height: var(--film-h);
  width: calc(var(--film-h) * 9 / 16);
  border-radius: 18px;
}

.player .spec { margin-top: 12px; text-align: center; }

@media (min-width: 900px) {
  .style-hero-grid {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: clamp(40px, 5vw, 96px);
  }
  .style-hero-text { max-width: 44rem; padding-bottom: 72px; }
  .style-hero .lead { margin-top: 20px; }
  .player-panel {
    --film-h: min(80svh, 760px, calc(100svh - 230px));
    border-radius: var(--r-panel);
  }
  .player-panel .film { border-radius: var(--r-film); }
  .player { align-items: flex-start; }
  .player .spec { text-align: left; padding-left: 14px; }
}

/* ---------- Cut timeline ---------- */

.timeline { margin-top: 12px; padding: 0 2px; }
.timeline-track {
  position: relative;
  height: 14px;
}
.timeline-track::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 6px;
  height: 2px;
  border-radius: 1px;
  background: rgba(0, 0, 0, 0.1);
}
.timeline-progress {
  position: absolute;
  left: 0; top: 6px;
  width: 100%;
  height: 2px;
  border-radius: 1px;
  background: var(--ink);
  transform-origin: 0 50%;
  transform: scaleX(0);
}
.timeline-tick {
  position: absolute;
  top: 1px;
  width: 2px;
  height: 12px;
  margin-left: -1px;
  border-radius: 1px;
  background: var(--cut-marker);
}
.timeline-head {
  position: absolute;
  left: 0; top: 3px;
  width: 8px;
  height: 8px;
  margin-left: -4px;
  border-radius: 50%;
  background: var(--ink);
  will-change: transform;
}
.timeline-times {
  position: relative;
  height: 44px;
  font-family: var(--mono);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
}
@media (min-width: 600px) { .timeline-times { font-size: 11px; } }
.timeline-end { position: absolute; top: 6px; }
.timeline-end.start { left: 0; }
.timeline-end.finish { right: 0; }
.timeline-cut {
  position: absolute;
  top: 0;
  translate: -50% 0;
  display: flex;
  align-items: flex-start;
  height: 44px;
  min-width: 44px;
  justify-content: center;
  padding: 6px 4px 0;
  border: 0;
  border-radius: 8px;
  background: none;
  font-family: var(--mono);
  font-size: inherit;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  white-space: nowrap;
  cursor: pointer;
  text-decoration: underline;
  text-decoration-color: rgba(29, 29, 31, 0.25);
  text-underline-offset: 3px;
  transition: text-decoration-color 160ms var(--ease-out);
}
.timeline-cut:hover { text-decoration-color: var(--ink); }
.timeline-cut:focus-visible { outline-offset: -2px; }
.timeline-label { margin-bottom: 8px; }

html:not(.js) .timeline { display: none; }

/* ---------- What you get ---------- */

.panel {
  display: grid;
  gap: 32px;
  padding: clamp(28px, 4vw, 56px);
  border-radius: var(--r-panel);
}
@media (max-width: 599px) { .panel { padding: 28px 22px; border-radius: var(--r-card); } }

.panel .label { margin-bottom: 14px; }
.panel-text p:not(.label) { margin-top: 16px; max-width: 32em; color: var(--ink-2); }

.deliverables { border-top: 1px solid var(--hairline); align-self: start; }
.deliverables li { padding: 16px 0; border-bottom: 1px solid var(--hairline); }
.deliverables .row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 12px;
}
.deliverables h3 {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
}
.deliverables .ratios {
  font-family: var(--mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
  white-space: nowrap;
}
.deliverables p { margin-top: 4px; font-size: 15px; line-height: 1.45; color: var(--ink-2); }

@media (min-width: 900px) {
  .panel { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px clamp(40px, 5vw, 80px); }
  .deliverables h3 { font-size: 19px; }
  .deliverables li { padding: 18px 0; }
}

/* ---------- Process ---------- */

.steps { display: grid; gap: 12px; }
.step { padding: 22px 22px 24px; border-radius: var(--r-card); }
.step .num {
  font-family: var(--mono);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
}
.step h3 {
  margin-top: 12px;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
}
.step p { margin-top: 6px; font-size: 15px; line-height: 1.45; color: var(--ink-2); }

@media (min-width: 640px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; } }
@media (min-width: 1100px) {
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .step { padding: 24px 24px 28px; }
  .step h3 { font-size: 19px; }
}

/* ---------- Contact ---------- */

.contact-panel { align-items: end; }
.contact-heading {
  font-size: clamp(34px, 4.6vw, 64px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.contact-actions .btn { width: 100%; }

.email-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 52px;
  margin-top: 12px;
  padding-left: 20px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow: inset 0 1px 0 #FFFFFF, 0 2px 8px rgba(17, 24, 39, 0.05);
}
.email-address {
  min-width: 0;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink);
  overflow-wrap: anywhere;
  user-select: all;
  -webkit-user-select: all;
}
.copy-btn {
  flex: none;
  align-self: stretch;
  min-height: 50px;
  min-width: 84px;
  padding: 0 18px;
  border: 0;
  border-left: 1px solid var(--hairline);
  border-radius: 0 999px 999px 0;
  background: none;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
  cursor: pointer;
  transition: background-color 160ms var(--ease-out);
}
.copy-btn:hover { background: rgba(0, 0, 0, 0.04); }
.copy-btn:focus-visible { outline-offset: -3px; }

.contact-note { margin-top: 16px; font-size: 15px; line-height: 1.45; color: var(--ink-2); }

@media (max-width: 360px) {
  .email-pill { padding-left: 16px; }
  .email-address { font-size: 12px; }
  .copy-btn { min-width: 72px; padding: 0 14px; }
}

/* ---------- Footer ---------- */

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding-top: 40px;
  padding-bottom: 32px;
}

/* ---------- 404 ---------- */

.not-found {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  min-height: 60svh;
  padding-top: var(--section);
  padding-bottom: var(--section);
}
.not-found .lead { margin-top: 16px; }
.not-found .btn { margin-top: 32px; }

/* ---------- Fallbacks ---------- */

@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .header-pill { background: rgba(255, 255, 255, 0.94); }
  .btn-film { background: rgba(20, 20, 22, 0.72); }
}

@media (prefers-reduced-transparency: reduce) {
  .header-pill,
  .glass-faux,
  .chip,
  .email-pill {
    background: #F7F8FA;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .btn-film { background: rgba(20, 20, 22, 0.78); -webkit-backdrop-filter: none; backdrop-filter: none; }
}

@media (prefers-reduced-motion: reduce) {
  .btn, .site-nav a, .copy-btn, .timeline-cut { transition: none; }
  .btn:active { transform: none; }
}

@media (forced-colors: active) {
  .timeline-tick, .timeline-head, .timeline-progress { background: CanvasText; }
}
