/* The app's faces (lib/ui/type): Fira Code from copies of its files (art/fonts — the deploy packs no app fonts), Asta Sans from Google Fonts (new/index.html; the
   app's static files are 2.6 MB each). */
@font-face { font-family: "FiraCodeRetina"; src: url("/assets/FiraCode-Retina-IKFTaIPY.ttf") format("truetype"); font-display: block; }
@font-face { font-family: "FiraCodeMedium"; src: url("/assets/FiraCode-Medium-DL69PIB5.ttf") format("truetype"); font-display: block; }
@font-face { font-family: "FiraCodeSemiBold"; src: url("/assets/FiraCode-SemiBold-CssfnJAs.ttf") format("truetype"); font-display: block; }

/* The marquee's left fade, animated from TvHud's Title. */
@property --sharp { syntax: "<number>"; inherits: false; initial-value: 1; }

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: #ffffff; }
body { font-family: "Asta Sans", system-ui, -apple-system, sans-serif; -webkit-font-smoothing: antialiased; overflow-x: clip; }

/* The background image under the intro cards' wash (IntroGuide CARD_BLUR 40, CARD_WASH 80% white — here 90%, Joseph
   2026-10-20: "more white"), fixed behind the page. Scaled past the edges so the blur does not pull white in at them. */
.showcase { position: relative; min-height: 100vh; min-height: 100svh; }
.showcase-ground { position: fixed; inset: 0; z-index: 0; overflow: hidden; }
.showcase-ground::before {
  content: ""; position: absolute; inset: -60px;
  background: url("/assets/background-CrPeqvzl.webp") center / cover no-repeat;
  filter: blur(24px);
}
.showcase-ground::after { content: ""; position: absolute; inset: 0; background: rgba(255, 255, 255, 0.9); }

/* Page 1: one screen tall on a wide screen — the logo, then the HUDs' room filling the rest (Showcase.tsx). */
.showcase-page1 { position: relative; z-index: 1; display: flex; flex-direction: column; height: 100vh; height: 100svh; }
.showcase-page1-narrow { height: auto; min-height: 100vh; min-height: 100svh; padding-bottom: 48px; }
.showcase-header { flex: none; display: flex; justify-content: center; padding: clamp(14px, 2.6vh, 34px) 16px clamp(16px, 3vh, 40px); }
/* The site logo is white; inverted it is black with its light inner lines. */
/* 15%, then about 30%, bigger on the video page's header (Joseph, 2026-10-20). */
.showcase-logo { display: block; aspect-ratio: 1100 / 319; width: clamp(110px, min(12vw, 21vh), 260px); height: auto; filter: invert(1); }
/* His black logo art as it is (Desktop/"logo-mask (4) 3.png"), not the white one inverted, and bigger again
   (Joseph, 2026-10-20). */
.vpage-header .showcase-logo { width: clamp(140px, min(15.5vw, 27vh), 340px); filter: none; }
@media (max-width: 759px) { .showcase-logo { width: 36vw; } }

/* Never squeezed: the phone's wall is sized by its HUDs (only page 1's fills, below). */
.showcase-wall { position: relative; flex: none; margin: 0 auto; }
/* Room above and below the HUDs, so their rows sit closer together (Joseph, 2026-10-20). */
.showcase-wall-page1 { flex: 1; width: auto; margin: clamp(12px, 4vh, 48px) 32px clamp(48px, 10vh, 120px); }

/* The tagline: JetBrains Mono Medium, black capitals, centred in page 1's room under the HUDs (Joseph, 2026-10-20). */
.showcase-tagline {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  margin: 0; white-space: nowrap; color: #000000;
  font-family: "JetBrains Mono", monospace; font-weight: 500; font-size: clamp(20px, 2.8vw, 54px); line-height: 1.2; text-transform: uppercase; letter-spacing: 0;
}
.showcase-tagline-narrow { position: static; transform: none; text-align: center; white-space: normal; font-size: 7vw; padding: 0 16px 24px; }
.tv-float { position: absolute; will-change: transform; }

/* ---- The TV HUD (TvHud.tsx) ---- */
.tv { position: absolute; }
.tv > * { position: absolute; }
.tv-glass {
  inset: 0;
  -webkit-backdrop-filter: blur(20px) saturate(1.6);
  backdrop-filter: blur(20px) saturate(1.6);
}

.tv-status { display: flex; align-items: center; white-space: nowrap; font-family: "Asta Sans", sans-serif; font-weight: 300; }
.tv-status span { display: inline-block; }

.tv-avatar { border-radius: 50%; overflow: hidden; background-size: cover; background-position: center; }
.tv-avatar-rim { position: absolute; border-radius: 50%; background: #ffffff; overflow: hidden; }
.tv-avatar-rim img { position: absolute; border-radius: 50%; object-fit: cover; }

.tv-pills { display: flex; flex-direction: row; }
.tv-pill { position: relative; overflow: hidden; flex: none; -webkit-backdrop-filter: blur(9px); backdrop-filter: blur(9px); }
.tv-pill-row { display: flex; align-items: center; justify-content: center; height: 100%; white-space: nowrap; }
.tv-chat-box { position: absolute; }
.tv-chat { display: flex; align-items: center; justify-content: center; }
/* UploadWorkingFill: the plate covering the pill, its hue turning (HueArt: cover, hue-rotate 0→360 linear). */
.tv-hue { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: tv-hue 2.5s linear infinite; }
@keyframes tv-hue { to { filter: hue-rotate(360deg); } }
.tv-badge { position: absolute; display: flex; align-items: center; justify-content: center; color: #ffffff; font-family: "Asta Sans", sans-serif; font-weight: 700; line-height: 1; }
.tv-antenna { filter: brightness(0) invert(1); }
.tv-fira, .tv-fira-medium, .tv-fira-semibold { color: #ffffff; line-height: normal; }
.tv-fira { font-family: "FiraCodeRetina", monospace; }
.tv-fira-medium { font-family: "FiraCodeMedium", monospace; }
.tv-fira-semibold { font-family: "FiraCodeSemiBold", monospace; display: inline-block; }

.tv-live { display: flex; align-items: center; justify-content: center; overflow: hidden; }

.tv-wave span { position: absolute; bottom: 0; transform-origin: bottom; animation: tv-wave ease-in-out infinite; }
@keyframes tv-wave { 50% { transform: scaleY(var(--wave-min)); } }
.tv-wave-still span { animation: none; }
.tv-title-line, .tv-title-line span, .tv-wave span { transition: color 0.3s ease, background-color 0.3s ease; }

.tv-title { overflow: hidden; }
/* A block, not inline: an inline box sits on the room's own line (the page's 16px strut) and drops at small sizes. */
.tv-title-line { display: block; width: max-content; white-space: nowrap; font-family: "Asta Sans", sans-serif; font-weight: 400; }
.tv-title-name { font-family: "Asta Sans", sans-serif; font-weight: 600; }
.tv-title-track { display: flex; flex-direction: row; width: max-content; }
/* A cut line's LETTERS fade out over its room's last --fade, through a mask. */
.tv-title-cut {
  -webkit-mask-image: linear-gradient(to right, #000 calc(100% - var(--fade)), transparent 100%);
  mask-image: linear-gradient(to right, #000 calc(100% - var(--fade)), transparent 100%);
}
/* A scrolling line fades at both ends, the left only while it moves (--sharp covers it at rest). */
.tv-title-scroll {
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 var(--fade), #000 calc(100% - var(--fade)), transparent 100%),
    linear-gradient(rgba(0, 0, 0, var(--sharp)), rgba(0, 0, 0, var(--sharp)));
  mask-image: linear-gradient(to right, transparent 0, #000 var(--fade), #000 calc(100% - var(--fade)), transparent 100%),
    linear-gradient(rgba(0, 0, 0, var(--sharp)), rgba(0, 0, 0, var(--sharp)));
  -webkit-mask-size: 100% 100%, calc(var(--fade) + 2px) 100%;
  mask-size: 100% 100%, calc(var(--fade) + 2px) 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}

@media (prefers-reduced-motion: reduce) {
  .tv-wave span, .tv-hue { animation: none; }
}

/* ---- The video page (VideoPage.tsx) ---- */
/* Heights here are in svh, the screen with the browser's bars shown: it never changes as a phone browser's bars slide in
   and out while scrolling. dvh did, and every screen-sized box — page 1, the videos, the footer — grew and shrank with
   Chrome's bottom bar on a phone (Joseph, 2026-10-20). */
/* Pure white, and it scrolls (Joseph, 2026-10-20: page 2): the header pinned at the top, page 1 one screen tall under
   it, page 2, then the footer. --vpage-header-h and --corner-reserve (the room the pinned corner pieces need) come
   from VideoPage. */
.vpage { --footer-h: 44px; position: relative; background: #ffffff; }
/* Page 1: the video as large as the room under the header allows, centred, with more room under than over, so it
   sits a little high (Joseph, 2026-10-20). */
.vpage-stage { --stage-pad: clamp(40px, 11vh, 120px); --stage-h: calc(100vh - var(--vpage-header-h, 0px)); --stage-h: calc(100svh - var(--vpage-header-h, 0px)); height: var(--stage-h); display: flex; align-items: center; justify-content: center; padding: 0 16px var(--stage-pad); }
/* 20% smaller than the room allows, then 5% smaller again, then 20% bigger (76% → 91.2%) (Joseph, 2026-10-20). A tap is its sound switch (VideoPage);
   nothing else — no long-press menu, no drag, no focus ring on a click. */
.vpage-video { display: block; max-width: 91.2%; max-height: 91.2%; width: auto; height: auto; cursor: pointer; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; outline: none; }
.vpage-video:focus-visible { outline: 2px solid #000000; outline-offset: 4px; }
.vpage-video::-webkit-media-controls { display: none !important; }
/* The bottom corners (VideoPage): IT-HIT's HUD left, the App Store badge in the HUD's glass right. The HUD is a
   button: its song on and off. */
.vpage-hud { cursor: pointer; -webkit-tap-highlight-color: transparent; outline: none; user-select: none; -webkit-user-select: none; }
.vpage-hud:focus-visible { outline: 2px solid #000000; outline-offset: 4px; border-radius: 999px; }
.vpage { position: relative; }
.vpage-corner { position: fixed; bottom: clamp(16px, 3.5vh, 40px); z-index: 2; }
.vpage-corner-left { left: clamp(16px, 2.5vw, 40px); }
.vpage-corner-right { right: clamp(16px, 2.5vw, 40px); }
.vpage-store {
  display: flex; align-items: center; justify-content: center;
  -webkit-backdrop-filter: blur(20px) saturate(1.6);
  backdrop-filter: blur(20px) saturate(1.6);
}
.vpage-store { cursor: pointer; -webkit-tap-highlight-color: transparent; outline: none; }
.vpage-store:focus-visible { outline: 2px solid #000000; outline-offset: 4px; }
.vpage-store img { display: block; width: auto; }
/* The banner behind the main video: the page's full width, under the video, ultra neon orange — written twice, sRGB
   first, then Display P3 for the screens that show it (a MacBook's), where an orange can be hotter than any sRGB one. */
.vpage-banner { position: absolute; left: 0; right: 0; z-index: 0; pointer-events: none; background: #ff6a00; background: color(display-p3 1 0.4 0); }
/* Its size written out, the phone's 720:1508 at the same 91.2% of the room either way: left to the video, it is 300x150
   until the browser has read the file, and on a phone the video and the banner open squashed (Joseph, 2026-10-30). */
.vpage-page1 .vpage-video {
  position: relative; z-index: 1; flex: none; aspect-ratio: 720 / 1508; height: auto; max-width: none; max-height: none;
  width: min(91.2%, calc((var(--stage-h) - var(--stage-pad)) * 0.912 * 720 / 1508));
}
/* The phone mockup cut out of its white (VideoPage): the stencil stretched over the video, both the phone's crop. */
.vpage-video-cutout {
  -webkit-mask-image: var(--phone-mask); mask-image: var(--phone-mask);
  -webkit-mask-size: 100% 100%; mask-size: 100% 100%; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
}
.vpage-video-still { position: absolute; z-index: 0; display: block; pointer-events: none; }
/* The go-live popups over the phone (LivePopups): iOS's banner, in em of the card. Taps go through to the video. No
   transform, opacity or filter on .vpage-popups: the cards' frost has to reach the page behind it. */
.vpage-popups { position: absolute; z-index: 2; pointer-events: none; --popup-gap: 0.55em; }
.vpage-popup {
  position: absolute; top: 0; left: 0; right: 0; box-sizing: border-box;
  display: flex; align-items: center; gap: 0.55em; padding: 0.8em 0.75em; border-radius: 1.6em;
  background: rgba(246, 246, 246, 0.5); box-shadow: 0 0.35em 1.6em rgba(0, 0, 0, 0.18);
  -webkit-backdrop-filter: blur(1.5em) saturate(1.8); backdrop-filter: blur(1.5em) saturate(1.8);
  color: #000000; font-family: -apple-system, "SF Pro Text", "Helvetica Neue", Arial, sans-serif; line-height: 1.3; letter-spacing: -0.01em;
  transform: translateY(var(--popup-off));
}
/* Down with a small overshoot, and the same again each time a newer one pushes it a slot lower. Quick (Joseph,
   2026-10-30: 0.5s → 0.3s). */
.vpage-popup[data-here="true"] { transform: translateY(calc(var(--popup-slot) * (100% + var(--popup-gap)))); transition: transform 0.3s cubic-bezier(0.22, 1.2, 0.36, 1); }
.vpage-popup-leaving { transition: transform 0.36s cubic-bezier(0.5, 0, 0.9, 0.5); }
/* The FEEL, then white, then the photo, the two bands the same width (Joseph, 2026-10-30); the rotation is the account's own, so the ring is an image of its own. */
.vpage-popup-face { position: relative; flex: none; width: 3.4em; height: 3.4em; }
.vpage-popup-ring { position: absolute; inset: 0; display: block; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.vpage-popup-photo { position: absolute; inset: 0.1em; display: block; box-sizing: border-box; width: calc(100% - 0.2em); height: calc(100% - 0.2em); border: 0.1em solid #ffffff; border-radius: 50%; object-fit: cover; background: #ffffff; }
/* LIVE on the face as on the HUD: centred across it, its bottom on the circle's, in the HUD's face and red. */
.vpage-popup-live { position: absolute; left: 50%; bottom: -0.1em; transform: translateX(-50%); display: flex; align-items: center; justify-content: center; width: 2.3em; height: 0.84em; border-radius: 0.42em; background: #ff0000; }
.vpage-popup-live span { font-size: 0.66em; }
/* The text a little bigger than iOS's, the two lines a little apart (Joseph, 2026-10-30); the side padding gives back
   the room, so the longest title still fits. */
.vpage-popup-text { flex: 1; min-width: 0; font-size: 1.05em; }
.vpage-popup-top { display: flex; align-items: baseline; justify-content: space-between; gap: 0.35em; }
.vpage-popup-title { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-weight: 600; }
.vpage-popup-time { flex: none; font-size: 0.8em; color: rgba(0, 0, 0, 0.5); }
.vpage-popup-body { margin-top: 0.2em; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
@media (prefers-reduced-motion: reduce) {
  .vpage-popup[data-here="true"], .vpage-popup-leaving { transition: none; }
}
/* The header: pinned to the top, see-through — the page scrolls visibly under the logo and tagline (Joseph,
   2026-10-20: "transparent background NOT white"). */
.vpage-header { position: sticky; top: 0; z-index: 3; background: transparent; }
/* …until the page's content reaches it (VideoPage, pages/page.ts): then a white backing fades in behind the logo and
   tagline, quickly. */
.vpage-header::before { content: ""; position: absolute; inset: 0; z-index: -1; background: #ffffff; opacity: 0; transition: opacity 0.15s ease-out; pointer-events: none; }
.vpage-header-solid::before { opacity: 1; }
.vpage-stage { position: relative; z-index: 1; }
.vpage { -webkit-touch-callout: none; }
/* The header (VideoPage): the logo left, the tagline far right, both on the corner pieces' side margins, the tagline
   in the page-1 tagline's face. The page takes no text selection. */
.vpage { -webkit-user-select: none; user-select: none; }
.vpage-header-split { justify-content: space-between; align-items: center; padding-left: clamp(16px, 2.5vw, 40px); padding-right: clamp(16px, 2.5vw, 40px); }
/* 20% bigger on a laptop (Joseph, 2026-10-20: clamp(12px, 1.5vw, 26px) × 1.2); a phone's header does not show it. */
.vpage-tagline { margin: 0; color: #000000; white-space: nowrap; font-family: "JetBrains Mono", monospace; font-weight: 500; font-size: clamp(14.4px, 1.8vw, 31.2px); text-transform: uppercase; letter-spacing: 0; }

/* Page 2 (VideoPage): four videos in one row (three until Joseph added a fourth, 2026-11-04), evenly spread. Each is as tall as the room one screen leaves under the
   header and above the footer and the corner pieces (--p2-room), 20% bigger than they first were (Joseph, 2026-10-20:
   86% of that room × 1.2), then 10% bigger again (× 1.1), or as a quarter of the width allows (31.2vw each for three → 23.4vw for four, the same share of the row). Under them a clear gap before the footer's rule
   (Joseph, 2026-10-20: "increase the padding below the bottom 3 videos"), so the page scrolls a little past one
   screen to reach the footer. */
.vpage-page2 {
  --p2-room: calc(100vh - var(--vpage-header-h, 0px) - 56px - var(--corner-reserve, 0px));
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: space-evenly;
  /* No side padding: the even spacing takes it, so the gaps between the videos open a little (Joseph, 2026-10-20). */
  padding: clamp(12px, 2vh, 24px) 0 clamp(48px, 8vh, 88px);
}
@supports (height: 100svh) {
  .vpage-page2 { --p2-room: calc(100svh - var(--vpage-header-h, 0px) - 56px - var(--corner-reserve, 0px)); }
}
.vpage-page2-video {
  display: block; height: min(calc(var(--p2-room) * 0.86 * 1.2 * 1.1), calc(23.4vw / 0.4619)); width: auto;
  cursor: pointer; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; outline: none;
}
/* The video the popups stay on (VideoPage): a box exactly its size, for them to sit in. */
.vpage-page2-popups { position: relative; flex: none; max-width: 100%; }
.vpage-page2-video:focus-visible { outline: 2px solid #000000; outline-offset: 4px; }
.vpage-page2-video::-webkit-media-controls { display: none !important; }

/* The footer: a hairline grey rule, then THE CURE AND THE CAUSE far left and CONTACT · PRIVACY · TERMS far right, in
   the tagline's face, small and light grey (Joseph, 2026-10-20) — above the corner pieces' room, so they never cover
   it. */
.vpage-footer { position: relative; z-index: 1; margin: 0 clamp(16px, 2.5vw, 40px); padding-bottom: var(--corner-reserve, 0px); }
.vpage-footer-row {
  height: var(--footer-h); border-top: 0.5px solid #d6d6d6;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.vpage-footer-links { display: flex; align-items: center; gap: clamp(16px, 2vw, 28px); }
.vpage-footer-text {
  color: #a6a6a6; text-decoration: none; white-space: nowrap; font-family: "JetBrains Mono", monospace; font-weight: 500;
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.04em; -webkit-tap-highlight-color: transparent;
}
.vpage-footer-links a:hover { color: #6f6f6f; }
.vpage-footer-links a:focus-visible { outline: 1px solid #a6a6a6; outline-offset: 3px; }

/* ---- The phone's page (VideoPage, below WIDE_MIN_PX) ---- */
.vpage-divider { display: none; }
.vpage-phone-hud, .vpage-phone-store { position: fixed; z-index: 2; bottom: calc(env(safe-area-inset-bottom, 0px) + 16px); }
.vpage-phone-store { text-decoration: none; display: flex; align-items: center; justify-content: center; border-radius: 50%; -webkit-backdrop-filter: blur(20px) saturate(1.6); backdrop-filter: blur(20px) saturate(1.6); -webkit-tap-highlight-color: transparent; }
.vpage-phone-store img { display: block; width: auto; }
.vpage-store-stack { display: flex; flex-direction: column; align-items: center; color: #000000; line-height: 1; white-space: nowrap; font-family: -apple-system, "SF Pro Text", "Helvetica Neue", Arial, sans-serif; font-weight: 500; letter-spacing: -0.01em; }
.vpage-store-stack span:last-child { font-weight: 600; letter-spacing: -0.02em; }
@media (max-width: 759px) {
  /* The logo alone, centred; the tagline moves under the video. */
  .vpage-header-split { justify-content: center; }
  /* The logo 25% bigger on a phone (Joseph, 2026-10-20). */
  .vpage-header .showcase-logo { width: 175px; }
  .vpage-header .vpage-tagline { display: none; }
  /* Page 1: the banner and the phone centred in what the screen shows between the header and the bottom pieces. */
  .vpage-stage { --stage-pad: var(--corner-reserve, 0px); }
  /* The tagline as a divider: a hairline either side of it. */
  .vpage-divider { display: flex; align-items: center; gap: 12px; padding: 8px 16px 28px; }
  .vpage-divider::before, .vpage-divider::after { content: ""; flex: 1; border-top: 0.5px solid #d6d6d6; }
  /* Twice the size it was, then a little more (Joseph, 2026-10-20: 13 → 26 → 30px): two balanced lines, centred. */
  .vpage-divider span { flex: 0 1 auto; color: #000000; text-align: center; line-height: 1.2; font-family: "JetBrains Mono", monospace; font-weight: 500; font-size: 30px; text-transform: uppercase; text-wrap: balance; max-width: 14.5ch; }
  .vpage-divider::before, .vpage-divider::after { min-width: 12px; }
  /* Page 2: the three videos one after another, each sized to the screen's free room or 78% of its width, whichever
     is less, then 20% bigger and 10% bigger again (Joseph, 2026-10-20), short of the side margins. The caption each
     recording carries in its top band grows with it, as Joseph asked. */
  .vpage-page2 { flex-direction: column; justify-content: flex-start; gap: 28px; padding: 0 16px 40px; }
  .vpage-page2-video { height: auto; width: calc(min(78vw, calc((100svh - var(--vpage-header-h, 0px) - var(--corner-reserve, 0px) - 32px) * 0.4619)) * 1.2 * 1.1); max-width: 100%; }
  /* The footer wraps onto two lines if it must. */
  .vpage-footer-row { height: auto; min-height: var(--footer-h); flex-wrap: wrap; padding: 12px 0; }
}

/* The logo is a link home (VideoPage, and pages/): it looks like nothing but the logo. */
.vpage-home { display: block; -webkit-tap-highlight-color: transparent; }
.vpage-home:focus-visible { outline: 2px solid #000000; outline-offset: 6px; border-radius: 8px; }
