/* Sky Calendar landing page. Tokens mirror ios/WatchSky/DesignSystem/Theme.swift. */

@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("assets/fonts/Inter-Regular.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 500; font-display: swap; src: url("assets/fonts/Inter-Medium.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url("assets/fonts/Inter-SemiBold.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 700; font-display: swap; src: url("assets/fonts/Inter-Bold.woff2") format("woff2"); }

:root {
  /* Palette */
  --background: #0A0B12;
  --surface: #141623;
  --surface-raised: #1B1E2E;
  --hairline: rgba(255, 255, 255, 0.07);
  --chip: rgba(255, 255, 255, 0.06);
  --glass: rgba(16, 18, 30, 0.62);
  --glass-light: rgba(255, 255, 255, 0.10);
  --text: #F3F2F8;
  --text-muted: #A4A6B9;
  --text-subtle: #8C8FA6;
  --on-light: #0A0B12;
  --accent: #C8BBFF;
  --positive: #6FD3C3;
  --warning: #E8A25C;

  --tint-meteors: #9D8CFF;
  --tint-planets: #F0B97A;
  --tint-moon: #8FB0FF;
  --tint-iss: #6FD3C3;
  --tint-seasons: #F59E7A;
  --tint-eclipses: #E0C27A;
  --tint-aurora: #7FE0A8;
  --tint-comets: #9FD4FF;
  --tint-milkyway: #D9C6F5;

  --sky-top: #05060D;
  --sky-middle: #0B1024;
  --sky-horizon: #1A1F3A;

  /* Pale lilac phone finish, matched to the accent */
  --phone-frame-hi: #F4F0FF;
  --phone-frame: #DDD4FF;
  --phone-frame-lo: #B9ABF2;
  --phone-bezel: #07070C;
  --phone-shadow: rgba(157, 140, 255, 0.30);

  /* Metrics */
  --gutter: 20px;
  --page-width: 1200px;
  --radius-card: 22px;
  --radius-hero: 28px;
  --radius-tile: 15px;
  --radius-pill: 999px;
  --button-height: 52px;

  /* Spacing scale */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 72px;
  --space-9: 120px;

  /* Typography (Inter, as in the app) */
  --font: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --text-overline: 10.5px;
  --text-caption: 11.5px;
  --text-callout: 13px;
  --text-body: 15px;
  --text-lead: clamp(16px, 1.4vw, 19px);
  --text-title: 22px;
  --text-h2: clamp(30px, 4vw, 52px);
  --text-display: clamp(40px, 6vw, 84px);
  --tracking-tight: -0.035em;
  --tracking-overline: 0.08em;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font: 400 var(--text-body)/1.55 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }

.skip-link {
  position: absolute; left: var(--space-4); top: -60px; z-index: 100;
  padding: var(--space-2) var(--space-4); border-radius: var(--radius-pill);
  background: var(--text); color: var(--on-light); text-decoration: none;
}
.skip-link:focus { top: var(--space-4); }

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

/* ---------- Backdrop: stars and drifting colour fields ---------- */

.starfield { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -2; pointer-events: none; transition: opacity 1.2s var(--ease-out); }

/* Colour only behind the hero; further down the sky goes dark and the stars fade */
.aura {
  position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden;
  --aura-a: var(--tint-meteors); --aura-b: var(--tint-moon); --aura-c: var(--accent);
  transition: opacity 1.2s var(--ease-out);
}
.aura:not([data-tone="hero"]) { opacity: 0; }
.aura:not([data-tone="hero"]) ~ .starfield { opacity: 0.3; }
.aura__blob {
  position: absolute; width: 60vmax; height: 60vmax; border-radius: 50%;
  filter: blur(90px); opacity: 0.30;
  animation: drift 26s ease-in-out infinite alternate;
}
.aura__blob--a { left: -18vmax; top: -22vmax; background-color: var(--aura-a); }
.aura__blob--b { right: -24vmax; top: 18vh; background-color: var(--aura-b); animation-duration: 32s; animation-delay: -8s; }
.aura__blob--c { left: 20vw; bottom: -36vmax; background-color: var(--aura-c); opacity: 0.22; animation-duration: 38s; animation-delay: -16s; }

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(6vmax, 4vmax, 0) scale(1.12); }
}
@media (prefers-reduced-motion: reduce) { .aura__blob { animation: none; } }

/* ---------- Layout ---------- */

.container { width: 100%; max-width: var(--page-width); margin: 0 auto; padding: 0 var(--gutter); }
.section { position: relative; padding: var(--space-9) 0; }
.section-head { max-width: 640px; display: grid; gap: var(--space-4); margin-bottom: var(--space-7); }
.section-head--center { margin-left: auto; margin-right: auto; text-align: center; justify-items: center; }

/* ---------- Type ---------- */

.display {
  font-size: var(--text-display); font-weight: 600; line-height: 1.0;
  letter-spacing: var(--tracking-tight);
}
.display__soft { color: var(--text-muted); }
.h2 { font-size: var(--text-h2); font-weight: 600; line-height: 1.06; letter-spacing: -0.03em; }
.lead { font-size: var(--text-lead); color: var(--text-muted); line-height: 1.55; }
.muted { color: var(--text-muted); }

.eyebrow {
  font-size: var(--text-overline); font-weight: 600; letter-spacing: var(--tracking-overline);
  text-transform: uppercase; color: var(--accent);
}

/* ---------- Primitives ---------- */

.chip {
  display: inline-flex; align-items: center; gap: var(--space-2);
  padding: 6px var(--space-3); border-radius: var(--radius-pill);
  background: var(--chip); border: 1px solid var(--hairline);
  font-size: var(--text-caption); font-weight: 500; color: var(--text-muted);
}
.chip--overline {
  font-size: var(--text-overline); font-weight: 600; letter-spacing: var(--tracking-overline);
  text-transform: uppercase; color: var(--text);
  background: rgba(10, 11, 18, 0.45); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  height: var(--button-height); padding: 0 var(--space-5); border-radius: var(--radius-pill);
  border: 0; font: 600 var(--text-body)/1 var(--font); text-decoration: none; cursor: pointer;
  transition: transform 0.2s var(--ease-out), background-color 0.2s, opacity 0.2s;
}
.btn:active { transform: scale(0.97); }
.btn--light { background: var(--text); color: var(--on-light); }
.btn--light:hover { background: #FFFFFF; }
.btn--glass { background: var(--chip); color: var(--text); border: 1px solid var(--hairline); }
.btn--glass:hover { background: var(--glass-light); }
.btn--sm { height: 40px; padding: 0 var(--space-4); font-size: var(--text-callout); }

/* App Store button. Swap for Apple's official badge artwork before launch. */
.store-button {
  display: inline-flex; align-items: center; gap: var(--space-3);
  height: 58px; padding: 0 var(--space-5) 0 var(--space-4); border-radius: 16px;
  background: var(--text); color: var(--on-light); text-decoration: none;
  transition: transform 0.2s var(--ease-out), box-shadow 0.3s;
  box-shadow: 0 10px 40px -10px var(--phone-shadow);
}
.store-button:hover { transform: translateY(-2px); box-shadow: 0 16px 50px -12px var(--phone-shadow); }
.store-button svg { width: 26px; height: 26px; }
.store-button span { display: grid; line-height: 1.1; font-size: 20px; font-weight: 600; letter-spacing: -0.01em; }
.store-button small { font-size: var(--text-caption); font-weight: 500; letter-spacing: 0; }

.card {
  background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--radius-card);
}

/* Frosted panel, as `.skyPanel()` in the app */
.glass {
  background: var(--glass); border: 1px solid var(--hairline);
  backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
}

/* Event icon on its tinted tile, as `IconTile` in the app */
.icon-tile {
  --size: 48px;
  --tint: var(--tint-meteors);
  flex: none; display: grid; place-items: center;
  width: var(--size); height: var(--size); border-radius: calc(var(--radius-tile) * var(--size) / 48px);
  background: radial-gradient(circle at 30% 25%,
    color-mix(in srgb, var(--tint) 42%, transparent) 0,
    color-mix(in srgb, var(--tint) 8%, transparent) calc(var(--size) * 0.85));
  color: var(--text);
}
.icon-tile svg { width: 62%; height: 62%; }
.icon-tile--sm { --size: 36px; }
.icon-tile--lg { --size: 64px; }

/* ---------- Phone mockup (pale lilac finish) ---------- */

.phone {
  --phone-w: 280px;
  position: relative; flex: none; margin: 0;
  width: var(--phone-w); aspect-ratio: 0.4794;
  padding: calc(var(--phone-w) * 0.034);
  border-radius: calc(var(--phone-w) * 0.175);
  background:
    linear-gradient(150deg, var(--phone-frame-hi) 0%, var(--phone-frame) 35%, var(--phone-frame-lo) 70%, var(--phone-frame) 100%);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.7),
    inset 0 0 calc(var(--phone-w) * 0.02) rgba(120, 100, 200, 0.35),
    0 calc(var(--phone-w) * 0.12) calc(var(--phone-w) * 0.3) calc(var(--phone-w) * -0.06) var(--phone-shadow),
    0 2px 6px rgba(0, 0, 0, 0.4);
}
/* Side buttons */
.phone::before, .phone::after {
  content: ""; position: absolute; width: calc(var(--phone-w) * 0.012);
  background: linear-gradient(90deg, var(--phone-frame-lo), var(--phone-frame));
}
.phone::before { left: calc(var(--phone-w) * -0.010); top: 22%; height: 11%; border-radius: 2px 0 0 2px;
  box-shadow: 0 calc(var(--phone-w) * 0.30) 0 var(--phone-frame-lo); }
.phone::after { right: calc(var(--phone-w) * -0.010); top: 27%; height: 15%; border-radius: 0 2px 2px 0; }

.phone__screen {
  position: relative; width: 100%; height: 100%; overflow: hidden;
  border-radius: calc(var(--phone-w) * 0.142);
  background: var(--background);
  box-shadow: 0 0 0 calc(var(--phone-w) * 0.012) var(--phone-bezel);
}
.phone__screen > img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
/* Dynamic Island */
.phone__screen::after {
  content: ""; position: absolute; z-index: 5; left: 50%; top: 1.25%;
  width: 31%; height: 4.1%; transform: translateX(-50%);
  border-radius: var(--radius-pill); background: #000;
}

/* ---------- Nav ---------- */

.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
  padding: var(--space-3) max(var(--gutter), calc((100vw - var(--page-width)) / 2 + var(--gutter)));
  transition: background-color 0.3s, border-color 0.3s;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: rgba(10, 11, 18, 0.72); border-color: var(--hairline);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
}
.brand { display: inline-flex; align-items: center; gap: var(--space-3); font-weight: 600; text-decoration: none; letter-spacing: -0.01em; }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.nav__links { display: flex; gap: var(--space-6); font-size: var(--text-callout); color: var(--text-muted); }
.nav__links a { text-decoration: none; transition: color 0.2s; }
.nav__links a:hover { color: var(--text); }
@media (max-width: 860px) { .nav__links { display: none; } }

/* ---------- Hero ---------- */

.hero { position: relative; z-index: 0; padding: calc(var(--space-9) + 20px) 0 0; text-align: center; }
.hero__copy { display: grid; justify-items: center; gap: var(--space-5); max-width: 1100px; margin: 0 auto; }
.hero__copy .lead { max-width: 620px; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: var(--space-4); }
.cta-note { font-size: var(--text-callout); color: var(--text-subtle); }

/* The next section covers the bottom of the phones */
.hero__stage {
  --front-w: clamp(220px, 24vw, 320px);
  --side-w: clamp(180px, 20vw, 270px);
  position: relative; display: flex; justify-content: center;
  margin-top: var(--space-7); height: calc(var(--front-w) * 2.086 * 0.82);
}
.hero__stage .phone { --phone-w: var(--side-w); position: absolute; top: calc(var(--front-w) * 0.22); }
.hero__stage .phone--front { --phone-w: var(--front-w); top: 0; z-index: 2; }
.hero__stage .phone--left  { transform: translateX(-80%); z-index: 1; }
.hero__stage .phone--right { transform: translateX(80%); z-index: 1; }

.rise { opacity: 0; translate: 0 40px; animation: rise 1.1s var(--ease-out) forwards; }
.rise--1 { animation-delay: 0.05s; } .rise--2 { animation-delay: 0.15s; } .rise--3 { animation-delay: 0.25s; }
.rise--4 { animation-delay: 0.4s; } .rise--5 { animation-delay: 0.55s; }
@keyframes rise { to { opacity: 1; translate: 0 0; } }
@media (prefers-reduced-motion: reduce) { .rise { animation: none; opacity: 1; translate: none; } }

@media (max-width: 760px) {
  .hero__stage { --front-w: 220px; --side-w: 170px; }
  .hero__stage .phone--left  { transform: translateX(-64%); }
  .hero__stage .phone--right { transform: translateX(64%); }
}

/* ---------- Horizontal tour (scroll moves it sideways) ---------- */

.tour { position: relative; z-index: 1; background: var(--surface); border-top: 1px solid var(--hairline); }
.tour__panel {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: var(--space-7);
  max-width: var(--page-width); margin: 0 auto; padding: var(--space-8) var(--gutter);
}
.tour__copy { display: grid; gap: var(--space-4); max-width: 480px; }
.tour__visual { position: relative; display: flex; justify-content: center; align-items: center; min-height: 0; }
.tour__visual { --shot-w: min(290px, calc((100svh - 190px) * 0.4794)); }
.tour__visual .phone { --phone-w: var(--shot-w); }
/* UI card floating over the phone's edge, half on the screen and half off */
.tour__float { position: absolute; z-index: 2; left: calc(50% + var(--shot-w) / 2 - 150px); bottom: 14%; width: 300px; }

/* Stargazing score card, as `VisibilityScoreCard` in the app */
.score-card {
  display: grid; gap: var(--space-3); padding: var(--space-4); border-radius: var(--radius-card);
  background: var(--surface-raised); border: 1px solid rgba(255, 255, 255, 0.10);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.75);
}
.score-card__title { font-size: var(--text-caption); font-weight: 600; color: var(--text-subtle); }
.score-card__head { display: flex; align-items: center; gap: var(--space-3); margin-top: calc(var(--space-2) * -1); }
.score-card__score { font-size: 34px; font-weight: 600; letter-spacing: -0.03em; line-height: 1; }
.score-card__score small { font-size: var(--text-body); font-weight: 500; color: var(--text-subtle); letter-spacing: 0; }
.score-card__verdict { font-size: var(--text-callout); font-weight: 600; line-height: 1.25; }
.score-card__best { font-size: var(--text-caption); color: var(--text-muted); }
.score-card__weather { flex: none; width: 24px; height: 24px; margin-left: auto; color: var(--text-muted); }
.score-card__chart { width: 100%; height: auto; overflow: visible; }
.score-card__grid line { stroke: var(--hairline); }
.score-card__labels, .score-card__labels text { font-size: 8.5px; fill: var(--text-subtle); font-family: var(--font); }
.score-card__line { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; }
.score-card__dot { fill: var(--accent); }
.score-card__facts { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.score-card__facts li { display: grid; grid-template-columns: 18px 1fr; gap: var(--space-2); font-size: var(--text-caption); color: var(--text-muted); line-height: 1.35; }
.score-card__facts svg { width: 16px; height: 16px; color: var(--text-subtle); }

.feature-list { list-style: none; margin: var(--space-2) 0 0; padding: 0; display: grid; gap: var(--space-3); }
.feature-list li { display: flex; align-items: center; gap: var(--space-3); color: var(--text-muted); font-size: var(--text-body); }

/* JS turns on the sideways mode; without it the panels stack */
.tour.is-horizontal { height: calc(var(--panels) * 100vh); height: calc(var(--panels) * 100svh); }
.tour.is-horizontal .tour__sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.tour.is-horizontal .tour__track { display: flex; height: 100%; width: calc(var(--panels) * 100vw); will-change: transform; }
.tour.is-horizontal .tour__panel { flex: 0 0 100vw; max-width: none; height: 100%;
  padding-left: max(var(--gutter), calc((100vw - var(--page-width)) / 2 + var(--gutter)));
  padding-right: max(var(--gutter), calc((100vw - var(--page-width)) / 2 + var(--gutter))); }

.tour__progress {
  position: absolute; left: 50%; bottom: var(--space-5); transform: translateX(-50%); z-index: 3;
  display: none; gap: var(--space-2); padding: 6px; border-radius: var(--radius-pill);
}
.tour.is-horizontal .tour__progress { display: flex; }
.tour__dot {
  position: relative; overflow: hidden; height: 34px; padding: 0 var(--space-4); border: 0; border-radius: var(--radius-pill);
  background: transparent; color: var(--text-muted); font: 500 var(--text-callout)/1 var(--font); white-space: nowrap; cursor: pointer;
  transition: color 0.3s, background-color 0.3s;
}
.tour__dot.is-active { background: var(--text); color: var(--on-light); }

@media (max-width: 860px) {
  .tour__panel { grid-template-columns: 1fr; gap: var(--space-5); align-content: center; text-align: left; }
  .tour.is-horizontal .tour__panel { padding-top: 72px; padding-bottom: 72px; }
  .tour__copy { gap: var(--space-2); }
  .tour__copy .feature-list { display: none; }
  .tour__copy .lead { font-size: var(--text-body); }
  .tour__visual { --shot-w: min(240px, calc((100svh - 400px) * 0.4794)); }
  /* Small phone: only the headline, so the card covers a corner of the screen and not all of it */
  .tour__float { left: min(50% + var(--shot-w) / 2 - 70px, 100% - 180px); bottom: 10%; width: 180px; }
  .score-card { gap: var(--space-2); padding: var(--space-3); }
  .score-card__score { font-size: 24px; }
  .score-card__verdict { font-size: var(--text-caption); }
  .score-card__weather, .score-card__chart, .score-card__facts { display: none; }
  .tour__dot { padding: 0 var(--space-3); font-size: var(--text-caption); }
}

/* ---------- Live AR demo ---------- */

.ar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-8); align-items: center; }
.ar__copy { display: grid; gap: var(--space-5); max-width: 520px; }
.segmented { display: inline-flex; padding: 4px; gap: 4px; border-radius: var(--radius-pill); width: fit-content; }
.segmented button {
  height: 40px; padding: 0 var(--space-5); border: 0; border-radius: var(--radius-pill);
  background: transparent; color: var(--text-muted); font: 600 var(--text-callout)/1 var(--font); cursor: pointer;
  transition: background-color 0.25s, color 0.25s;
}
.segmented button[aria-pressed="true"] { background: var(--text); color: var(--on-light); }
.ar__hint { display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-callout); color: var(--text-subtle); }
.ar__hint svg { width: 18px; height: 18px; }

.ar .phone { --phone-w: min(330px, 80vw); }
.ar-view { position: absolute; inset: 0; overflow: hidden; touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; }
.ar-view.is-dragging { cursor: grabbing; }
.ar-view__sky { position: absolute; left: 0; top: 0; display: flex; will-change: transform; }
.ar-view__tile { flex: none; background: url("assets/night-sky.webp") center / cover no-repeat; }
.ar-view__tile:nth-child(even) { transform: scaleX(-1); }
.ar-view__canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.ar-view__top { position: absolute; z-index: 2; top: 8.5%; left: 6%; right: 6%; display: flex; align-items: center; justify-content: center; }
.ar-view__close {
  position: absolute; left: 0; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
}
.ar-view__close svg { width: 16px; height: 16px; }
.ar-view__heading {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: var(--radius-pill);
  font-size: var(--text-callout); font-weight: 500; font-variant-numeric: tabular-nums; white-space: nowrap;
}
.ar-view__heading svg { width: 13px; height: 13px; }
.ar-view__label {
  position: absolute; z-index: 2; transform: translate(-50%, 0); padding: 6px 12px; border-radius: var(--radius-pill);
  font-size: var(--text-caption); font-weight: 600; white-space: nowrap; pointer-events: none;
  transition: opacity 0.3s;
}
.ar-view__panel {
  position: absolute; z-index: 2; left: 4.5%; right: 4.5%; bottom: 4%;
  display: grid; gap: 4px; padding: var(--space-4); border-radius: var(--radius-card);
}
.ar-view__title { font-size: var(--text-body); font-weight: 600; }
.ar-view__detail { font-size: var(--text-callout); color: var(--text-muted); }
.ar-view__note { font-size: var(--text-caption); color: var(--text-subtle); }

@media (max-width: 860px) {
  .ar { grid-template-columns: 1fr; justify-items: center; gap: var(--space-7); }
  .ar .phone { --phone-w: min(310px, 82vw); }
}

/* ---------- Event types ---------- */

.type-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); }
.types__note { margin-top: var(--space-6); font-size: var(--text-callout); color: var(--text-muted); text-align: center; }
.types__note strong { color: var(--text); }
@media (max-width: 960px) { .type-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .type-grid { grid-template-columns: 1fr; } }

/* Glowing event card, as `HeroCardLayout` in the app: art top right, title at the bottom */
.highlight-card {
  --tint: var(--tint-meteors);
  position: relative; overflow: hidden; min-height: 260px;
  display: flex; flex-direction: column; justify-content: flex-end; gap: var(--space-1);
  padding: var(--space-5); border-radius: var(--radius-hero); border: 1px solid var(--hairline);
  background:
    radial-gradient(260px circle at 75% 25%, color-mix(in srgb, var(--tint) 45%, transparent), transparent),
    radial-gradient(220px circle at 0% 100%, color-mix(in srgb, var(--tint-moon) 20%, transparent), transparent),
    var(--surface);
  transition: transform 0.3s var(--ease-out), border-color 0.3s;
}
.highlight-card:hover { transform: translateY(-3px); border-color: rgba(255, 255, 255, 0.14); }
.highlight-card__art { position: absolute; top: var(--space-3); right: var(--space-4); width: 150px; height: 150px; color: var(--text); }
.highlight-card__art svg { width: 100%; height: 100%; }
.highlight-card h3 { font-size: var(--text-title); font-weight: 600; letter-spacing: -0.02em; }
.highlight-card p { font-size: var(--text-callout); color: var(--text-muted); line-height: 1.4; max-width: 30ch; }

/* ---------- Widgets ---------- */

.widgets { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-8); align-items: center; }
.widgets .phone { --phone-w: min(300px, 78vw); }

/* Phone wallpaper */
.wallpaper { position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(5, 6, 13, 0.1), rgba(26, 31, 58, 0.55)), url("assets/night-sky.webp") center / cover; }
.wallpaper::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(circle at 80% 90%, color-mix(in srgb, var(--tint-meteors) 45%, transparent), transparent 55%); }
.wallpaper > * { position: relative; }

/* Home Screen widgets, after WatchSkyWidgets */
.widget {
  --tint: var(--tint-eclipses);
  position: relative; overflow: hidden; border-radius: 26px; padding: var(--space-4);
  border: 1px solid var(--hairline); color: var(--text);
  background:
    radial-gradient(circle at 18% 10%, color-mix(in srgb, var(--tint) 45%, transparent), transparent 62%),
    radial-gradient(circle at 0% 100%, color-mix(in srgb, var(--tint-moon) 20%, transparent), transparent 55%),
    var(--background);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.8);
}
.widget--small { width: 170px; height: 170px; display: flex; flex-direction: column; justify-content: space-between; }
.widget--medium { width: min(360px, 100%); height: 170px; display: grid; grid-template-columns: 1fr 1.15fr; gap: var(--space-4); }
.widget--wide { width: min(360px, 100%); height: 170px; display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }
.widget__kind { font-size: var(--text-caption); color: var(--text-muted); }
.widget__big { font-size: 26px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; color: var(--tint-eclipses); font-variant-numeric: tabular-nums; }
.widget__date { font-size: var(--text-caption); color: var(--text-subtle); }
.widget__title { font-size: var(--text-body); font-weight: 600; line-height: 1.2; }
.widget__col { display: flex; flex-direction: column; justify-content: space-between; min-width: 0; }
.widget__over { font-size: var(--text-caption); font-weight: 600; color: var(--text-muted); }
.widget__list { display: grid; gap: 7px; }
.widget__item { display: grid; grid-template-columns: auto 1fr; gap: var(--space-2); align-items: center; min-width: 0; }
.widget__item .icon-tile { --size: 26px; border-radius: 7px; }
.widget__item > div { min-width: 0; }
.widget__item strong { display: block; font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.widget__item span { display: block; font-size: 10.5px; color: var(--text-subtle); white-space: nowrap; }
.widget__rows { display: grid; gap: 6px; align-content: end; font-size: 12px; }
.widget__rows div { display: flex; justify-content: space-between; color: var(--text-muted); }
.widget__rows b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }

/* Partial eclipse disc: the Moon's dark disc over the gold Sun */
.eclipse-disc { position: relative; width: 38px; height: 38px; }
.eclipse-disc::before, .eclipse-disc::after { content: ""; position: absolute; border-radius: 50%; width: 30px; height: 30px; }
.eclipse-disc::before { left: 0; top: 4px; background: radial-gradient(circle at 35% 35%, #F3DCA0, var(--tint-eclipses) 70%); box-shadow: 0 0 18px color-mix(in srgb, var(--tint-eclipses) 50%, transparent); }
.eclipse-disc::after { left: 11px; top: 1px; background: #050509; }

/* Home Screen: laid out at iPhone size (410 × 889 pt), scaled to the phone by JS via --screen-scale */
.home-screen { overflow: hidden; }
.home-screen__canvas {
  width: 410px; height: 889px; padding: 64px 25px 0; transform-origin: 0 0; scale: var(--screen-scale, 0.66);
  display: flex; flex-direction: column; gap: 20px;
}
.home-screen__time { position: absolute; top: 20px; left: 52px; font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.home-screen__row { display: flex; gap: 20px; }
.home-screen__apps { display: grid; grid-template-columns: repeat(2, 64px); gap: 42px 42px; padding: 4px 0 0 0; justify-content: center; flex: 1; }
.home-screen__apps > *, .home-screen__dock > * { width: 64px; height: 64px; border-radius: 15px; }
.home-screen__apps span, .home-screen__dock span { background: rgba(255, 255, 255, 0.14); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.home-screen__dock {
  position: absolute; left: 12px; right: 12px; bottom: 12px; height: 96px; border-radius: 34px;
  display: flex; justify-content: space-around; align-items: center; padding: 0 12px;
  background: rgba(255, 255, 255, 0.10); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
}

@media (max-width: 960px) {
  .widgets { grid-template-columns: 1fr; justify-items: center; }
  .widgets .section-head { text-align: center; justify-items: center; margin-left: auto; margin-right: auto; }
}

/* ---------- Plans ---------- */

.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); max-width: 880px; margin: 0 auto; }
.plan { padding: var(--space-6); display: grid; gap: var(--space-5); align-content: start; }
.plan--plus {
  position: relative; overflow: hidden;
  background:
    radial-gradient(circle at 85% 0%, color-mix(in srgb, var(--accent) 30%, transparent), transparent 60%),
    var(--surface-raised);
  border-color: color-mix(in srgb, var(--accent) 30%, transparent);
}
.plan__name { font-size: var(--text-title); font-weight: 600; }
.plan__sub { font-size: var(--text-callout); color: var(--text-muted); }
.plan ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-3); }
.plan li { display: grid; grid-template-columns: 18px 1fr; gap: var(--space-3); font-size: var(--text-body); color: var(--text-muted); }
.plan li svg { width: 18px; height: 18px; margin-top: 3px; color: var(--positive); }
.plan--plus li svg { color: var(--accent); }
@media (max-width: 760px) { .plans { grid-template-columns: 1fr; } }

/* ---------- Closing ---------- */

.closing { text-align: center; display: grid; justify-items: center; gap: var(--space-5); }
.closing__icon { width: 96px; height: 96px; border-radius: 22px; box-shadow: 0 20px 60px -10px var(--phone-shadow); }

.footer { padding: var(--space-7) 0; border-top: 1px solid var(--hairline); font-size: var(--text-callout); color: var(--text-subtle); }
.footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-4); }
.footer nav { display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-5); }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--text); }

/* Fade-up on scroll */
.reveal { opacity: 0; translate: 0 28px; transition: opacity 0.9s var(--ease-out), translate 0.9s var(--ease-out); }
.reveal.is-visible { opacity: 1; translate: 0 0; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; translate: none; transition: none; } }
