:root {
  color-scheme: light dark;
  --bg: #f5f5f2;
  --surface: #ffffff;
  --ink: #1a1a1a;
  --muted: #666666;
  --border: #e6e2da;
  --border-strong: #d9d4cb;
  --shadow: 0 28px 72px rgba(18, 18, 18, 0.08);
}

:root[data-theme="dark"] {
  --bg: #111111;
  --surface: #191919;
  --ink: #f6f4ef;
  --muted: #a3a3a3;
  --border: #2a2a2a;
  --border-strong: #363636;
  --shadow: 0 30px 84px rgba(0, 0, 0, 0.38);
}

* {
  box-sizing: border-box;
}

html {
  height: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--ink) 72%, transparent);
  outline-offset: 3px;
}

img {
  display: block;
  max-width: 100%;
}

.eyebrow,
.slide-counter {
  font-family: "JetBrains Mono", ui-monospace, monospace;
}

h1 {
  font-family: "Playfair Display", serif;
  font-weight: 600;
  letter-spacing: -0.035em;
}

.page-shell {
  min-height: 100vh;
  min-height: 100svh;
  height: 100svh;
  display: flex;
  flex-direction: column;
  padding: 0 24px 10px;
}

.site-header,
.hero {
  width: min(1140px, 100%);
  margin: 0 auto;
}

main {
  flex: 1;
  display: flex;
}

body[data-page="legal"] {
  overflow: auto;
}

body[data-page="legal"] main {
  display: block;
  flex: none;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 0 8px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 10px 24px rgba(72, 98, 255, 0.18);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-copy strong {
  font-size: 1.02rem;
}

.brand-copy span {
  font-size: 0.64rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 22px;
  border-radius: 999px;
  border: 1px solid var(--border);
  transition: transform 160ms ease, background 160ms ease, opacity 160ms ease, border-color 160ms ease;
}

.button:hover,
.slider-button:hover,
.theme-toggle:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.button-primary:hover {
  opacity: 0.92;
}

.button-secondary {
  background: transparent;
  color: var(--ink);
}

.button-small {
  min-height: 44px;
  padding: 0 18px;
}

.button-with-icon {
  gap: 10px;
}

.button-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}

.button-icon svg {
  width: 18px;
  height: 18px;
  overflow: visible;
}

.button-icon-apple {
  font-size: 1.18rem;
  line-height: 1;
  transform: translateY(-1px);
}

.theme-toggle,
.slider-button {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}

.theme-toggle {
  background: color-mix(in srgb, var(--surface) 72%, transparent);
  box-shadow: inset 0 0 0 1px var(--border);
  color: var(--ink);
}

#theme-toggle-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
}

#theme-toggle-icon svg,
.slider-button svg {
  width: 22px;
  height: 22px;
  display: block;
  color: currentColor;
}

.hero {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 560px) minmax(320px, 392px);
  justify-content: center;
  gap: clamp(36px, 4.8vw, 78px);
  align-items: center;
  padding: 8px 0 0;
}

.hero-meta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.hero-meta-divider {
  width: 20px;
  height: 1px;
  background: var(--border-strong);
  opacity: 0.7;
}

.eyebrow {
  display: inline-block;
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
}

.slide-counter {
  color: var(--muted);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 12px 0 0;
  font-size: clamp(2.8rem, 4.6vw, 4.5rem);
  line-height: 1.01;
  max-width: 13.2ch;
  min-height: 3.08em;
}

.hero-text,
.hero-point {
  color: var(--muted);
  line-height: 1.72;
}

.hero-text {
  margin: 14px 0 0;
  max-width: 38rem;
  font-size: 0.98rem;
  min-height: 3.9em;
}

.hero-points {
  display: grid;
  gap: 8px;
  margin-top: 18px;
  min-height: 7.8rem;
  align-content: start;
}

.hero-point {
  position: relative;
  padding-left: 16px;
  font-size: 0.95rem;
}

.hero-point::before {
  content: "";
  position: absolute;
  left: 0;
  top: 11px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border-strong);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 22px;
}

.hero-download-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.6;
}

.hero-device-wrap {
  display: grid;
  gap: 12px;
  justify-items: center;
  justify-self: center;
}

.site-footer {
  width: min(1180px, 100%);
  margin: auto auto 0;
  padding: 0 0 calc(env(safe-area-inset-bottom, 0px) + 2px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-size: 0.86rem;
}

.site-footer__identity {
  display: flex;
  align-items: center;
  gap: 10px;
}

.site-footer__identity strong {
  color: var(--ink);
  font-size: 0.9rem;
}

.site-footer__links {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.site-footer__links a {
  transition: color 160ms ease, opacity 160ms ease;
}

.site-footer__links a:hover {
  color: var(--ink);
}

.legal-shell {
  height: auto;
  min-height: 100vh;
  min-height: 100svh;
}

.legal-page {
  width: min(760px, 100%);
  margin: 0 auto;
  padding: 54px 0 24px;
}

.legal-page__eyebrow {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
}

.legal-page h1 {
  margin: 16px 0 18px;
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1;
}

.legal-page p {
  margin: 0;
  color: var(--muted);
  line-height: 1.78;
  font-size: 1rem;
  max-width: 68ch;
}

.legal-section {
  padding-top: 28px;
}

.legal-section h2 {
  margin: 0 0 10px;
  font-size: 1.02rem;
  color: var(--ink);
}

.legal-page a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.legal-footer {
  padding: 10px 0 24px;
}

.mockup-figure {
  width: min(100%, 392px);
  margin: 0;
}

.mockup-image {
  width: 100%;
  aspect-ratio: 2328 / 3992;
  object-fit: contain;
  object-position: center;
  filter: drop-shadow(0 34px 72px rgba(0, 0, 0, 0.26));
  transition: opacity 260ms ease, transform 380ms ease, filter 380ms ease;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 540px;
  width: min(548px, 100%);
  margin: 0 auto;
  transition: opacity 220ms ease, transform 320ms ease;
}

.hero-copy.is-transitioning {
  opacity: 0;
  transform: translateY(8px);
}

.mockup-image.is-transitioning {
  opacity: 0;
  transform: translateY(10px) scale(0.985);
  filter: drop-shadow(0 24px 50px rgba(0, 0, 0, 0.18));
}

.slider-controls {
  display: flex;
  align-items: center;
  gap: 14px;
}

.slider-dots {
  display: flex;
  align-items: center;
  gap: 10px;
}

.slider-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 0;
  padding: 0;
  background: color-mix(in srgb, var(--muted) 40%, transparent);
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease;
}

.slider-dot:hover {
  transform: scale(1.08);
}

.slider-dot.is-active {
  background: var(--ink);
}

@media (max-width: 980px) {
  body {
    overflow: auto;
  }

  .page-shell {
    height: auto;
    min-height: 100svh;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 8px 0 12px;
    align-items: start;
    justify-content: normal;
  }

  .hero-copy,
  .hero h1,
  .hero-text,
  .hero-points {
    min-height: 0;
  }

  .hero-device-wrap {
    order: -1;
    justify-items: center;
  }

  .hero-copy {
    justify-content: flex-start;
    width: min(640px, 100%);
    margin: 0 auto;
  }

  .hero-actions .button {
    width: 100%;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding-top: 22px;
  }

  .site-footer__links {
    justify-content: flex-start;
    gap: 12px 16px;
  }
}

@media (max-width: 760px) {
  .page-shell {
    padding: 0 18px 18px;
  }

  .site-header {
    padding-top: 18px;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-start;
  }

  .header-actions {
    width: auto;
    justify-content: flex-end;
    gap: 10px;
    margin-left: auto;
  }

  .hero {
    gap: 18px;
    padding-top: 6px;
  }

  .hero h1 {
    font-size: clamp(2.15rem, 9.4vw, 3.15rem);
    max-width: 11.5ch;
  }

  .hero-meta {
    flex-wrap: wrap;
    gap: 8px 10px;
    justify-content: center;
  }

  .hero-text {
    font-size: 1rem;
    max-width: none;
    text-align: center;
  }

  .hero-point {
    font-size: 0.96rem;
  }

  .hero-copy {
    text-align: center;
    align-items: center;
  }

  .hero h1 {
    text-align: center;
  }

  .hero-points {
    width: 100%;
  }

  .hero-point {
    text-align: center;
    padding-left: 0;
  }

  .hero-point::before {
    display: none;
  }

  .brand-copy span {
    display: none;
  }

  .mockup-figure {
    width: min(100%, 280px);
    margin: 0 auto;
  }

  .slider-controls {
    width: 100%;
    justify-content: center;
  }

  .legal-page {
    padding-top: 32px;
  }

  .site-footer__identity {
    flex-wrap: wrap;
    gap: 6px 10px;
  }

  .site-footer__links a {
    font-size: 0.82rem;
  }
}

@media (max-width: 420px) {
  .button-small {
    padding: 0 15px;
  }

  .hero h1 {
    font-size: clamp(1.95rem, 9vw, 2.7rem);
    max-width: 11ch;
  }

  .hero-point {
    line-height: 1.58;
  }

  .mockup-figure {
    width: min(100%, 248px);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
