@import 'styles.css';

/* Custom Styles for Tide Website */

:root {
  --font-display: 'Plus Jakarta Sans', -apple-system, sans-serif;
  --font-body: 'Manrope', sans-serif;
  --font-mono: 'Roboto Mono', monospace;
}

body {
  margin: 0;
  background: var(--color-bg);
  font-family: var(--font-body);
  color: var(--color-on-surface);
  position: relative;
  overflow-x: hidden;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--color-primary-70, oklch(73% 0.15 260));
}

/* Shader animated background from the handoff */
@keyframes shaderDrift {
  0% { background-position: 0% 20%, 100% 80%, 50% 100%, 80% 0%; }
  50% { background-position: 100% 60%, 20% 20%, 70% 40%, 20% 80%; }
  100% { background-position: 0% 20%, 100% 80%, 50% 100%, 80% 0%; }
}

body::before {
  content: '';
  position: fixed;
  inset: -15%;
  z-index: 0;
  pointer-events: none;
  background-image: 
    radial-gradient(circle at center, oklch(66% 0.19 340 / 0.22), transparent 45%),
    radial-gradient(circle at center, oklch(63% 0.19 260 / 0.20), transparent 45%),
    radial-gradient(circle at center, oklch(68% 0.15 165 / 0.16), transparent 45%),
    radial-gradient(circle at center, oklch(68% 0.14 80 / 0.14), transparent 45%);
  background-size: 70% 70%;
  background-repeat: no-repeat;
  filter: blur(70px) saturate(140%);
  animation: shaderDrift 32s ease-in-out infinite;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: .045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

main, header, footer {
  position: relative;
  z-index: 2;
}

/* Header & Sticky Nav Bar */
header {
  position: sticky;
  top: 0;
  width: 100%;
  z-index: 100;
  padding: 16px 0;
  display: flex;
  justify-content: center;
  background: transparent;
  border-bottom: 1px solid rgba(255, 255, 255, 0);
  transition: all 0.3s ease;
}

header.scrolled {
  background: rgba(10, 10, 12, 0.45);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: rgba(255, 255, 255, 0.05);
}

.tide-nav {
  position: relative;
  width: calc(100% - 96px);
  max-width: 1240px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-sizing: border-box;
}

.tide-logo-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-on-surface);
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.tide-logo-link img {
  height: 32px;
  width: 32px;
}

.tide-nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: var(--radius-pill);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
}

.tide-nav-link {
  font-size: var(--text-body-sm-size, 14px);
  font-weight: 500;
  color: var(--color-on-surface-variant);
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  transition: all 0.2s;
}

.tide-nav-link:hover {
  color: var(--color-on-surface);
  background: rgba(255, 255, 255, 0.05);
}

.tide-nav-link.active {
  color: var(--color-on-surface);
  background: rgba(255, 255, 255, 0.1);
}

/* Mobile navigation — the toggle and dropdown panel are injected by initMobileNav() in
   js/main.js. Both are display:none until the breakpoint that hides .tide-nav-links (900px),
   so on desktop they cost nothing and never overlap the real link row. */
.tide-nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: var(--radius-pill);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  color: var(--color-on-surface);
  cursor: pointer;
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
  transition: background 0.2s;
}

.tide-nav-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
}

.tide-nav-mobile {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  right: 0;
  flex-direction: column;
  gap: 4px;
  padding: 8px;
  border-radius: var(--radius-lg);
  /* Nearly opaque rather than --glass-surface-strong: this panel sits over the hero headline, and
     at 0.8 alpha the text behind it reads straight through the menu items. */
  background: oklch(16% 0.02 260 / 0.97);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-3);
  backdrop-filter: blur(var(--blur-lg));
  -webkit-backdrop-filter: blur(var(--blur-lg));
}

.tide-nav-mobile .tide-nav-link {
  display: block;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 15px;
}

.tide-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  color: var(--color-on-surface);
  font-size: 14px;
  font-weight: 600;
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
  transition: all 0.2s;
  cursor: pointer;
}

.tide-nav-btn:hover {
  background: var(--color-on-surface);
  color: var(--color-bg);
  border-color: var(--color-on-surface);
}

.tide-nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-ph-badge {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-ph-badge img {
  display: block;
  /* Invert to match dark background, hue-rotate preserves PH orange */
  filter: invert(1) hue-rotate(180deg) brightness(1.05) saturate(1.5);
  border-radius: 6px;
}

.nav-ph-badge:hover {
  transform: translateY(-1px);
  opacity: 0.85;
}

/* Button & Icon Styling */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: none;
  font-family: var(--font-body);
}

.btn:active {
  transform: scale(0.96);
  filter: brightness(0.92);
}

.btn-filled {
  background: var(--accent, var(--color-primary));
  color: #fff;
}

.btn-filled:hover {
  box-shadow: 0 0 20px var(--accent-glow, rgba(99, 48, 260, 0.3));
}

.btn-ghost {
  background: transparent;
  color: var(--color-on-surface);
  border: 1px solid var(--color-outline-variant);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.05);
}

.btn-glass {
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  color: var(--color-on-surface);
  backdrop-filter: blur(var(--blur-md));
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 16px;
}

.btn-md {
  padding: 10px 22px;
  font-size: 14px;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 94vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: 0px 48px 48px;
  box-sizing: border-box;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: transparent;
  z-index: 1;
  pointer-events: none;
}

.hero-blob-a {
  position: absolute;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  background: oklch(66% 0.19 340 / 0.35);
  filter: blur(120px);
  top: -140px;
  right: -160px;
  zIndex: 1;
}

.hero-blob-b {
  position: absolute;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: oklch(63% 0.19 260 / 0.3);
  filter: blur(120px);
  bottom: -160px;
  left: -140px;
  zIndex: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 52px;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: var(--radius-pill);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
  font-size: 13px;
  font-weight: 500;
  letter-spacing: var(--tracking-label);
  color: var(--color-on-surface-variant);
  margin-bottom: 24px;
  text-transform: uppercase;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: 56px;
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: var(--tracking-tight);
  color: var(--color-on-surface);
  margin: 0 0 20px;
}

.hero p.subhead {
  font-size: 18px;
  line-height: 1.6;
  color: var(--color-on-surface-variant);
  max-width: 480px;
  margin: 0 0 32px;
}

.cta-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.hero-faq-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-on-surface-variant);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--color-outline-variant);
  padding: 8px 4px;
}

.hero-faq-link:hover {
  color: var(--color-on-surface);
  text-decoration-color: var(--color-on-surface);
}

.ph-badge-row {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 24px;
}

.ph-badge-row a {
  display: inline-block;
  transition: transform 0.2s ease, opacity 0.2s ease;
  /* Invert to dark base, re-hue to preserve PH orange */
  filter: invert(1) hue-rotate(180deg) brightness(1.05) saturate(1.4);
}

.ph-badge-row a:hover {
  transform: translateY(-2px);
  opacity: 0.85;
}

/* ─────────────────────────────────────────────────────────────
   macOS App Window Mockup
   ───────────────────────────────────────────────────────────── */
.app-window-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.app-window {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 560px;
  border-radius: 12px;
  overflow: hidden;
  background: #1a1a1e;
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow:
    0 2px 0 0 rgba(255,255,255,0.06) inset,
    0 40px 100px rgba(0,0,0,0.55),
    0 0 0 1px rgba(0,0,0,0.4);
}

.app-titlebar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: #242428;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
}

.app-titlebar-dots {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.dot-red    { background: #ff5f57; }
.dot-yellow { background: #febc2e; }
.dot-green  { background: #28c840; }

.app-titlebar-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
}

.app-titlebar-tabs::-webkit-scrollbar { display: none; }

.app-tab {
  padding: 5px 14px;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: rgba(255,255,255,0.45);
  font-size: 12px;
  font-weight: 500;
  font-family: var(--font-body);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.18s ease;
}

.app-tab:hover {
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.75);
}

.app-tab.active {
  background: rgba(255,255,255,0.10);
  color: #fff;
  font-weight: 600;
}

.app-screen-wrap {
  position: relative;
  overflow: hidden;
  line-height: 0;
}

.app-screenshot {
  width: 100%;
  height: auto;
  display: block;
  transition: opacity 0.25s ease;
}

.app-screenshot.fading {
  opacity: 0;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  font-size: 13px;
  color: var(--color-on-surface-variant);
}



.phone-glow {
  position: absolute;
  inset: 10%;
  border-radius: 50%;
  background: oklch(66% 0.19 340 / 0.45);
  filter: blur(90px);
  z-index: 0;
}

.phone-container {
  position: relative;
  z-index: 1;
}

/* ─────────────────────────────────────────────────────────────
   Android Bezel Simulator & Layout (Material Design 3 Bezel)
   ───────────────────────────────────────────────────────────── */
.android-bezel {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  background: #121114;
  border: 8px solid rgba(116, 119, 117, 0.5);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

/* ─────────────────────────────────────────────────────────────
   Android Phone Bezel (Real Screenshot Mockup)
   ───────────────────────────────────────────────────────────── */
.phone-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  width: fit-content;
  box-sizing: border-box;
  justify-self: center;
}

.phone-nav-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: nowrap;
  width: max-content;
  box-sizing: border-box;
}

.phone-nav-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1.5px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.05);
  color: rgba(255,255,255,0.5);
  font-size: 12px;
  font-weight: 500;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 0.18s ease;
  white-space: nowrap;
  box-sizing: border-box;
}

.phone-nav-tab:hover {
  background: rgba(255,255,255,0.10);
  color: rgba(255,255,255,0.85);
  border-color: rgba(255,255,255,0.22);
}

.phone-nav-tab.active {
  background: var(--tab-color);
  border-color: transparent;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 2px 12px rgba(0,0,0,0.3);
}

.android-phone-bezel {
  position: relative;
  z-index: 1;
  width: 280px;
  box-sizing: border-box;
  border-radius: 42px;
  background: #0e0e0f;
  border: 9px solid #1e1e22;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.08),
    0 40px 100px rgba(0,0,0,0.65),
    inset 0 1px 0 rgba(255,255,255,0.07);
  overflow: hidden;
  line-height: 0;
}

.ap-screen {
  width: 100%;
  line-height: 0;
  display: block;
}

.ap-screenshot {
  width: 100%;
  height: auto;
  display: block;
  transition: opacity 0.22s ease;
}

/* A live shader scene standing in for a screenshot inside a phone bezel. The 9/19.5 ratio matches
   what the android-*.png screenshots occupy, so the bezel is the same height either way. */
.ap-shader-demo {
  width: 100%;
  aspect-ratio: 9 / 19.5;
  display: block;
  background: oklch(14% 0.02 260);
}

.ap-screenshot.fading {
  opacity: 0;
}


.android-punch-hole {
  position: absolute;
  left: 50%;
  top: 8px;
  transform: translateX(-50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #2e2e2e;
}

.android-status-right {
  display: flex;
  align-items: center;
  gap: 4px;
}

.android-screen {
  flex: 1;
  position: relative;
  overflow: hidden;
  min-height: 0;
  background: var(--color-bg);
}

.android-screen-wallpaper {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, oklch(66% 0.19 340 / 0.2), transparent 85%);
  z-index: 0;
  transition: all 0.3s;
}

.android-screen-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, oklch(10% 0.01 260 / 0.15) 0%, oklch(10% 0.01 260 / 0.55) 65%, oklch(10% 0.01 260 / 0.85) 100%);
  z-index: 1;
  pointer-events: none;
}

.android-nav-bar {
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 30;
  background: transparent;
  pointer-events: none;
}

.android-nav-pill {
  width: 108px;
  height: 4px;
  border-radius: 2px;
  background: #fff;
  opacity: 0.4;
}

/* ─────────────────────────────────────────────────────────────
   Simulator Custom Top Bar Navigation
   ───────────────────────────────────────────────────────────── */
.sim-top-bar {
  position: absolute;
  top: 40px;
  left: 0;
  width: 100%;
  padding: 12px 16px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 25;
}

.sim-menu-toggle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--blur-md));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  cursor: pointer;
  transition: transform 0.420s cubic-bezier(0.34, 1.56, 0.64, 1);
  flex-shrink: 0;
}

.sim-menu-toggle.active svg {
  transform: rotate(90deg);
}

.sim-nav-chips {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.sim-nav-chips::-webkit-scrollbar {
  display: none;
}

.sim-chip {
  height: 36px;
  border-radius: 18px;
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  white-space: nowrap;
  cursor: pointer;
  opacity: 0;
  width: 0;
  border: 0;
  overflow: hidden;
  transform: translateX(18px);
  transition: all 420ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sim-chip.active-always {
  opacity: 1;
  width: auto;
  padding: 0 14px;
  border: 1px solid var(--glass-border);
  transform: translateX(0);
  background: var(--accent);
}

.sim-top-bar.expanded .sim-chip {
  opacity: 1;
  width: auto;
  padding: 0 14px;
  border: 1px solid var(--glass-border);
  transform: translateX(0);
}

.sim-chip.active {
  background: var(--accent);
}

/* ─────────────────────────────────────────────────────────────
   Simulator Screens Mockups (Handoff Visuals Recreated)
   ───────────────────────────────────────────────────────────── */
.sim-screen-container {
  position: absolute;
  inset: 0;
  z-index: 2;
  box-sizing: border-box;
}

.sim-screen {
  display: none;
  height: 100%;
  overflow-y: auto;
  scrollbar-width: none;
  padding: 52px 16px 24px;
  box-sizing: border-box;
  flex-direction: column;
}

.sim-screen::-webkit-scrollbar {
  display: none;
}

.sim-screen.active {
  display: flex;
}

/* Discover Screen */
.sim-discover-hero {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  height: 220px;
  border: 1px solid var(--glass-border);
  flex-shrink: 0;
}

.sim-discover-hero-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, oklch(66% 0.19 340 / 0.8), oklch(66% 0.19 340 / 0.1));
}

.sim-discover-hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, oklch(0% 0 0 / 0.75), transparent 60%);
}

.sim-discover-hero-content {
  position: absolute;
  left: 14px;
  bottom: 14px;
  right: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sim-discover-hero-content span {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: var(--tracking-label);
  color: var(--color-on-surface-variant);
  text-transform: uppercase;
}

.sim-discover-hero-content h4 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.sim-discover-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}

.sim-discover-section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sim-discover-section-head span.title {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-on-surface);
}

.sim-discover-section-head span.action {
  font-size: 12px;
  color: var(--color-primary);
}

.sim-discover-row {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: none;
}

.sim-discover-row::-webkit-scrollbar {
  display: none;
}

.sim-discover-card {
  width: 120px;
  height: 90px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.sim-discover-card-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02));
}

.sim-discover-card span {
  position: absolute;
  left: 8px;
  bottom: 8px;
  right: 8px;
  font-size: 11px;
  color: #fff;
  text-shadow: 0 1px 4px black;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Browse Screen */
.sim-browse-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin-bottom: 4px;
}

.sim-browse-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-pill);
  padding: 8px 12px;
  margin-bottom: 12px;
}

.sim-browse-search span {
  font-size: 12px;
  color: var(--color-on-surface-variant);
}

.sim-browse-chips {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  margin-bottom: 16px;
}

.sim-browse-chips::-webkit-scrollbar {
  display: none;
}

.sim-browse-chip {
  padding: 6px 12px;
  background: rgba(255,255,255,0.08);
  border-radius: var(--radius-pill);
  font-size: 11px;
  white-space: nowrap;
  color: var(--color-on-surface-variant);
}

.sim-browse-chip.active {
  background: var(--accent);
  color: #fff;
}

.sim-browse-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.sim-browse-item {
  aspect-ratio: 1/1;
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  background: linear-gradient(135deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
  overflow: hidden;
}

/* Create Screen */
.sim-create-steps {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.sim-create-step {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--color-surface-container-high);
  color: var(--color-on-surface-variant);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

.sim-create-step.active {
  background: var(--accent);
  color: #fff;
}

.sim-create-line {
  flex: 1;
  height: 2px;
  background: var(--color-outline-variant);
  margin: 0 4px;
}

.sim-create-line.active {
  background: var(--accent);
}

.sim-create-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--color-on-surface-variant);
  margin-bottom: 20px;
  padding: 0 4px;
}

.sim-create-labels span.active {
  color: var(--color-on-surface);
  font-weight: 600;
}

.sim-create-dropzone {
  border: 1.5px dashed var(--color-outline);
  border-radius: var(--radius-lg);
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.sim-create-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-surface-container-high);
  display: flex;
  align-items: center;
  justify-content: center;
}

.sim-create-dropzone h5 {
  font-size: 13px;
  margin: 0 0 2px;
  color: var(--color-on-surface);
}

.sim-create-dropzone p {
  font-size: 11px;
  color: var(--color-on-surface-variant);
  margin: 0;
}

/* Library Screen */
.sim-library-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin-bottom: 12px;
}

.sim-library-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.sim-library-item {
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  aspect-ratio: 1/1;
  background: linear-gradient(135deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
  overflow: hidden;
  position: relative;
}

.sim-library-item.featured {
  grid-column: span 2;
  grid-row: span 2;
  aspect-ratio: 16/10;
}

.sim-library-item span {
  position: absolute;
  left: 8px;
  bottom: 8px;
  font-size: 10px;
  color: #fff;
  text-shadow: 0 1px 4px black;
}

.sim-library-drawer {
  background: var(--glass-surface-strong);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  padding: 10px 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
  backdrop-filter: blur(var(--blur-lg));
}

.sim-library-drawer-handle {
  width: 32px;
  height: 4px;
  border-radius: 2px;
  background: var(--color-outline-variant);
  align-self: center;
}

.sim-library-drawer-header {
  display: flex;
  gap: 10px;
  align-items: center;
}

.sim-library-drawer-thumb {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  border: 1px solid var(--glass-border);
  background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.02));
  flex-shrink: 0;
}

.sim-library-drawer-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.sim-library-drawer-text span.title {
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--color-on-surface);
}

.sim-library-drawer-text span.author {
  font-size: 11px;
  color: var(--color-on-surface-variant);
}

.sim-library-drawer-play {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sim-library-drawer-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--color-on-surface-variant);
  display: flex;
  gap: 12px;
}

/* Profile Screen */
.sim-profile-header {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 12px;
}

.sim-profile-avatar-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.sim-profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(45deg, var(--color-primary), var(--accent));
}

.sim-profile-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin: 0;
}

.sim-profile-stats {
  display: flex;
  justify-content: space-around;
  text-align: center;
  margin-bottom: 18px;
}

.sim-profile-stat span.num {
  font-size: 16px;
  font-weight: 700;
  color: var(--color-on-surface);
  display: block;
}

.sim-profile-stat span.label {
  font-size: 11px;
  color: var(--color-on-surface-variant);
}

.sim-profile-tabs {
  display: flex;
  border-bottom: 1px solid var(--color-outline-variant);
  margin-bottom: 12px;
}

.sim-profile-tab {
  flex: 1;
  text-align: center;
  padding: 8px 0;
  font-size: 11px;
  color: var(--color-on-surface-variant);
  border-bottom: 2px solid transparent;
}

.sim-profile-tab.active {
  color: var(--color-on-surface);
  border-bottom-color: var(--accent);
  font-weight: 600;
}

/* Settings Screen */
.sim-settings-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin-bottom: 12px;
}

.sim-settings-card {
  border-radius: var(--radius-xl);
  background: var(--color-surface-container);
  border: 1px solid var(--glass-border);
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.sim-settings-card-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--color-outline);
}

.sim-settings-card-info {
  display: flex;
  flex-direction: column;
}

.sim-settings-card-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-on-surface);
}

.sim-settings-card-tier {
  font-size: 11px;
  color: var(--color-on-surface-variant);
}

.sim-settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 4px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.sim-settings-row-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sim-settings-row-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--color-on-surface);
}

.sim-settings-row-desc {
  font-size: 11px;
  color: var(--color-on-surface-variant);
}

.sim-settings-switch {
  width: 36px;
  height: 20px;
  border-radius: 10px;
  background: var(--accent);
  position: relative;
  cursor: pointer;
}

.sim-settings-switch-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  position: absolute;
  top: 3px;
  right: 3px;
  transition: all 0.2s;
}

/* Features Section Styles */
.features-sec {
  position: relative;
  background: transparent;
  padding: 48px 48px 24px;
  box-sizing: border-box;
}

.features-inner {
  max-width: 1240px;
  margin: 0 auto;
}

.features-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 24px;
}

.features-head h2 {
  font-family: var(--font-display);
  font-size: 42px;
  font-weight: 700;
  color: var(--color-on-surface);
  margin: 12px 0 0;
  letter-spacing: var(--tracking-tight);
}

.features-head .eyebrow {
  color: var(--color-primary);
}

.features-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 400px);
  gap: 56px;
  align-items: center;
  padding: 16px 0;
}

.features-row.reverse {
  grid-template-columns: minmax(320px, 400px) minmax(0, 1fr);
}

.features-row.reverse .features-text-col {
  order: 1;
}

.features-row.reverse .features-phone-col {
  order: -1;
}

.features-row-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: var(--tracking-label);
  color: var(--accent-color);
  margin-bottom: 14px;
  text-transform: uppercase;
}

.features-row h3 {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  color: var(--color-on-surface);
  margin: 0 0 14px;
  letter-spacing: var(--tracking-tight);
}

.features-row p.desc {
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-on-surface-variant);
  max-width: 460px;
  margin: 0 0 22px;
}

.features-row ul.bullets {
  display: flex;
  flex-direction: column;
  gap: 12px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.features-row ul.bullets li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: var(--color-on-surface-variant);
}

.features-row ul.bullets li svg {
  color: var(--accent-color);
  flex-shrink: 0;
  margin-top: 2px;
}

.features-phone-col {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 520px;
  position: relative;
}

.features-glow {
  position: absolute;
  inset: 14%;
  border-radius: 50%;
  background: var(--accent-color);
  opacity: 0.35;
  filter: blur(80px);
  z-index: 0;
}

.features-phone-col .android-bezel {
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.features-phone-col .sim-top-bar {
  display: none; /* Hide top switcher chips in features section rows */
}

/* Highlights Section */
.highlights-sec {
  position: relative;
  background: transparent;
  padding: 80px 48px;
  box-sizing: border-box;
}

.highlights-inner {
  max-width: 1240px;
  margin: 0 auto;
}

.highlights-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-top: 48px;
}

.highlight-card {
  border-radius: var(--radius-xl);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  padding: 36px 28px;
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
  box-shadow: var(--shadow-1);
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.highlight-card:hover {
  transform: translateY(-6px);
  border-color: var(--color-primary);
}

.highlight-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
}

.highlight-card h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--color-on-surface);
  margin: 0;
}

.highlight-card p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--color-on-surface-variant);
  margin: 0;
}

/* Gallery Section - Scrolling Calm Marquee */
.gallery-sec {
  position: relative;
  background: transparent;
  padding: 48px 48px;
}

.gallery-inner {
  max-width: 1240px;
  margin: 0 auto;
}

.gallery-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}

.gallery-head .eyebrow {
  color: oklch(68% 0.15 165);
}

.gallery-head h2 {
  font-family: var(--font-display);
  font-size: 38px;
  color: var(--color-on-surface);
  margin: 10px 0 0;
}

.gallery-marquee-container {
  overflow: hidden;
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  padding: 10px 0;
}

.gallery-marquee {
  display: flex;
  gap: 18px;
  width: max-content;
  /* Duration is set per-render by initLiveBackdropMarquee() from the catalog size, so a new
     shader scene lengthens the loop instead of speeding the whole strip up. */
  animation: scrollMarquee var(--marquee-duration, 48s) linear infinite;
}

.gallery-marquee-container:hover .gallery-marquee {
  animation-play-state: paused;
}

@keyframes scrollMarquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(calc(-50% - 9px)); }
}

.gallery-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  width: 240px;
  border: 1px solid var(--glass-border);
  flex-shrink: 0;
}

.gallery-card-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--gradient-start, #333), var(--gradient-end, #111));
  z-index: 0;
}

.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: relative;
  z-index: 1;
  transition: opacity 0.3s;
}

/* Shader-scene card. The canvas is the artwork itself, drawn frame-by-frame by
   js/live-bg-preview.js — there is no poster image to fall back to, so it gets a dark ground
   underneath for the moment before its first frame lands. */
.gallery-card-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 1;
  background: oklch(14% 0.02 260);
}

.gallery-card-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, oklch(0% 0 0 / 0.75) 100%);
  z-index: 2;
}

.gallery-card-meta {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 3;
}

.gallery-card-title {
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 4px;
}

.gallery-card-tag {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: oklch(100% 0 0 / 0.14);
  backdrop-filter: blur(var(--blur-sm));
  font-size: 11px;
  color: #fff;
}

/* Pricing Section */
.pricing-sec {
  position: relative;
  background: transparent;
  padding: 48px 48px;
  box-sizing: border-box;
}

.pricing-inner {
  max-width: 1240px;
  margin: 0 auto;
}

.pricing-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 48px;
}

.pricing-head .eyebrow {
  color: var(--color-primary);
}

.pricing-head h2 {
  font-family: var(--font-display);
  font-size: 42px;
  color: var(--color-on-surface);
  margin: 12px 0 0;
}

.pricing-free-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 32px;
  border-radius: var(--radius-xl);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  margin-bottom: 40px;
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
  flex-wrap: wrap;
  gap: 24px;
}

.pricing-free-info h3 {
  font-size: 20px;
  margin: 0 0 4px;
}

.pricing-free-info p {
  font-size: 14px;
  color: var(--color-on-surface-variant);
  margin: 0;
}

.pricing-bullets-inline {
  display: flex;
  gap: 24px;
  list-style: none;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
}

.pricing-bullets-inline li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--color-on-surface-variant);
}

.pricing-bullets-inline li svg {
  color: oklch(68% 0.15 165);
}

.pricing-pro-header {
  text-align: center;
  margin-bottom: 24px;
}

.pricing-pro-header h3 {
  font-size: 18px;
  color: var(--color-on-surface);
  margin: 0 0 12px;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.pricing-card {
  border-radius: var(--radius-xl);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  padding: 36px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: var(--shadow-1);
  box-sizing: border-box;
}

.pricing-card.featured {
  border-color: var(--color-primary);
  box-shadow: 0 0 30px rgba(99, 48, 260, 0.25);
  position: relative;
}

.pricing-badge {
  position: absolute;
  top: -12px;
  background: var(--color-primary);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
}

.pricing-tier {
  font-size: 18px;
  font-weight: 500;
  color: var(--color-on-surface-variant);
  margin: 0 0 8px;
}

.pricing-price {
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 700;
  color: var(--color-on-surface);
  margin: 0 0 4px;
}

.pricing-note {
  font-size: 14px;
  color: var(--color-on-surface-variant);
  margin: 0 0 28px;
}

.pricing-card button {
  width: 100%;
}

/* Download Band */
.download-band {
  padding: 96px 48px;
  box-sizing: border-box;
}

.download-panel {
  max-width: 1240px;
  margin: 0 auto;
  border-radius: var(--radius-xl);
  background: var(--glass-surface-strong);
  border: 1px solid var(--glass-border);
  padding: 80px 48px;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-2);
  box-sizing: border-box;
}

.download-panel .hero-blob-a {
  background: oklch(63% 0.19 260 / 0.18);
  top: -100px;
  right: -100px;
}

.download-panel .hero-blob-b {
  background: oklch(66% 0.19 340 / 0.14);
  bottom: -100px;
  left: -100px;
}

.download-panel-content {
  position: relative;
  z-index: 2;
  max-width: 560px;
  margin: 0 auto;
}

.download-panel h2 {
  font-family: var(--font-display);
  font-size: 42px;
  color: var(--color-on-surface);
  margin: 0 0 16px;
}

.download-panel p {
  font-size: 16px;
  color: var(--color-on-surface-variant);
  margin: 0 0 32px;
}

/* Footer */
footer {
  border-top: 1px solid var(--color-outline-variant);
  padding: 80px 48px 40px;
  background: rgba(10, 10, 10, 0.4);
  box-sizing: border-box;
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 48px;
  margin-bottom: 64px;
}

.footer-brand h3 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 12px;
  color: var(--color-on-surface);
}

.footer-brand p {
  font-size: 14px;
  color: var(--color-on-surface-variant);
  line-height: 1.6;
  max-width: 240px;
}

.footer-col h4 {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--color-on-surface-variant);
  margin: 0 0 16px;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col ul li a {
  font-size: 14px;
  color: var(--color-on-surface-variant);
  transition: color 0.2s;
}

.footer-col ul li a:hover {
  color: var(--color-on-surface);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-bottom p {
  font-size: 13px;
  color: var(--color-on-surface-variant);
  margin: 0;
}

/* Hidden admin portal link */
.admin-dot {
  opacity: 0.35;
  cursor: default;
  color: var(--color-on-surface-variant);
  margin-left: 4px;
  font-size: 14px;
}

.admin-dot:hover {
  opacity: 0.8;
  color: var(--color-primary);
}

/* Legal Pages Styling */
.legal-sec {
  max-width: 720px;
  margin: 0 auto;
  padding: 30px 24px 96px;
}

.legal-sec h1 {
  font-family: var(--font-display);
  font-size: 40px;
  color: var(--color-on-surface);
  margin-bottom: 8px;
}

.legal-meta {
  font-size: 14px;
  color: var(--color-on-surface-variant);
  margin-bottom: 48px;
}

.legal-content h2 {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--color-on-surface);
  margin-top: 36px;
  margin-bottom: 16px;
}

.legal-content p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--color-on-surface-variant);
  margin-bottom: 20px;
}

/* FAQ page (website/faq/) */
.faq-group {
  margin-top: 40px;
}

.faq-group h2 {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--color-on-surface);
  margin-bottom: 16px;
}

.faq-item {
  border-radius: var(--radius-md);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-on-surface);
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: -2px;
}

.faq-toggle {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  color: var(--color-on-surface-variant);
  transition: transform 0.2s ease;
}

.faq-item[open] .faq-toggle {
  transform: rotate(45deg);
  color: var(--color-primary);
}

.faq-item[open] summary {
  border-bottom: 1px solid var(--glass-border);
}

.faq-answer {
  padding: 4px 20px 20px;
}

.faq-answer p {
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--color-on-surface-variant);
  margin: 0;
}

.faq-answer p + p {
  margin-top: 12px;
}

.faq-answer a {
  color: var(--color-primary);
}

.faq-item:target,
.faq-item.faq-item-target {
  border-color: var(--color-primary);
}

/* Report Content page (website/report/) — public-facing form, not admin. */
.report-form {
  margin: 28px 0 40px;
  padding: 24px;
  border-radius: var(--radius-lg);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
}

.report-form .field {
  margin-bottom: 18px;
}

.report-form label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin-bottom: 6px;
}

.report-form .hint {
  font-size: 12px;
  color: var(--color-on-surface-variant);
  margin-top: 4px;
}

.report-form textarea,
.report-form input[type="email"] {
  width: 100%;
  box-sizing: border-box;
  font-family: inherit;
  font-size: 14px;
  color: var(--color-on-surface);
  background: var(--color-surface-container-high, var(--color-surface-dim));
  border: 1px solid var(--color-outline-variant);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  outline: none;
  transition: border-color 0.2s;
}

.report-form textarea {
  min-height: 120px;
  resize: vertical;
  font-family: var(--font-body);
}

.report-form textarea:focus,
.report-form input[type="email"]:focus {
  border-color: var(--color-primary);
}

.report-form .checkbox-field {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.report-form .checkbox-field input[type="checkbox"] {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  accent-color: var(--color-primary);
  flex-shrink: 0;
}

.report-form .checkbox-field label {
  font-size: 13px;
  font-weight: 400;
  color: var(--color-on-surface-variant);
  margin: 0;
}

.report-form-status {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  font-size: 14px;
  display: none;
}

.report-form-status.success {
  display: block;
  background: rgba(52, 199, 89, 0.12);
  color: #34c759;
}

.report-form-status.error {
  display: block;
  background: rgba(255, 74, 90, 0.12);
  color: #ff4a5a;
}

/* Admin Portal Styling */
.admin-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--color-bg);
}

.admin-login-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 48px;
}

.admin-login-card {
  position: relative;
  z-index: 2;
  width: 380px;
  padding: 36px;
  border-radius: var(--radius-xl);
  background: var(--glass-surface-strong);
  backdrop-filter: blur(var(--blur-lg));
  -webkit-backdrop-filter: blur(var(--blur-lg));
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-2);
  box-sizing: border-box;
}

.admin-login-card h2 {
  font-family: var(--font-display);
  font-size: 28px;
  margin: 0 0 4px;
  text-align: center;
  color: var(--color-on-surface);
}

.admin-login-card p.sub {
  font-size: 14px;
  color: var(--color-on-surface-variant);
  text-align: center;
  margin: 0 0 28px;
}

.form-field {
  margin-bottom: 18px;
}

.form-field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--tracking-label);
  color: var(--color-on-surface-variant);
  margin-bottom: 8px;
}

.form-field input {
  font-size: 14px;
  color: var(--color-on-surface);
  background: var(--color-surface-container-high);
  border: 1px solid var(--color-outline-variant);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  width: 100%;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s;
}

.form-field input:focus {
  border-color: var(--color-primary);
}

/* Admin Dashboard */
.admin-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 40px;
  border-bottom: 1px solid var(--color-outline-variant);
  box-sizing: border-box;
}

.admin-top-bar h1 {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 4px;
  color: var(--color-on-surface);
}

.admin-top-bar p {
  font-size: 13px;
  color: var(--color-on-surface-variant);
  margin: 0;
}

.admin-main {
  flex: 1;
  padding: 40px;
  max-width: 1000px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

.admin-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.admin-header-row h2 {
  font-family: var(--font-display);
  font-size: 26px;
  margin: 0;
  color: var(--color-on-surface);
}

.admin-badge {
  background: rgba(99, 48, 260, 0.2);
  color: var(--color-primary);
  font-size: 12px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
}

.admin-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.admin-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-radius: var(--radius-xl);
  background: var(--color-surface-container);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-1);
  box-sizing: border-box;
}

.admin-thumb {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-md);
  overflow: hidden;
  flex-shrink: 0;
}

.admin-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.admin-info {
  flex: 1;
  min-width: 0;
}

.admin-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin: 0 0 4px;
}

.admin-meta {
  font-size: 13px;
  color: var(--color-on-surface-variant);
  margin: 0 0 8px;
}

.admin-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.admin-tag {
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-on-surface-variant);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 4px;
}

/* Persistent caution notice — CSAM hash-matching, moderation-queue caveats, etc. */
.admin-caution-banner {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: rgba(255, 171, 0, 0.1);
  color: #ffab00;
  border: 1px solid rgba(255, 171, 0, 0.25);
  border-radius: 6px;
  padding: 10px 12px;
  font-size: 12px;
  line-height: 1.4;
  margin-bottom: 12px;
}
.admin-caution-banner strong {
  color: inherit;
}

/* AI Pre-Screening Visual Safety Badges */
.safety-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.safety-badge.clean {
  background: rgba(46, 213, 115, 0.15);
  color: #2ed573;
  border: 1px solid rgba(46, 213, 115, 0.3);
}
.safety-badge.low {
  background: rgba(46, 213, 115, 0.12);
  color: #2ed573;
  border: 1px solid rgba(46, 213, 115, 0.25);
}
.safety-badge.medium {
  background: rgba(255, 171, 0, 0.15);
  color: #ffab00;
  border: 1px solid rgba(255, 171, 0, 0.3);
}
.safety-badge.high {
  background: rgba(255, 74, 90, 0.18);
  color: #ff4a5a;
  border: 1px solid rgba(255, 74, 90, 0.4);
}
.safety-badge.severe {
  background: rgba(255, 0, 0, 0.25);
  color: #ff2a2a;
  border: 1px solid rgba(255, 0, 0, 0.6);
}
.admin-thumb-container {
  position: relative;
  width: 72px;
  height: 72px;
  flex-shrink: 0;
}
.admin-thumb-blur img {
  filter: blur(12px);
  transition: filter 0.2s ease;
}
.admin-thumb-reveal-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0, 0, 0, 0.75);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 9px;
  font-weight: 600;
  padding: 4px 6px;
  cursor: pointer;
  white-space: nowrap;
  backdrop-filter: blur(4px);
}

.admin-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.admin-empty-state {
  text-align: center;
  padding: 64px 0;
  color: var(--color-on-surface-variant);
  font-size: 16px;
}

.admin-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--glass-border);
}

.admin-tab {
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 500;
  background: none;
  border: none;
  color: var(--color-on-surface-variant);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
}

.admin-tab:hover {
  color: var(--color-on-surface);
}

.admin-tab.active {
  color: var(--color-primary);
  border-bottom-color: var(--color-primary);
}

.admin-published-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  padding: 0;
}

.published-card {
  border-radius: var(--radius-xl);
  background: var(--color-surface-container);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.2s ease;
}

.published-card:hover {
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
}

.published-card-img {
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--color-surface-dim);
}

.published-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* A live-background (renderKind: "shader") scene has no thumbnail file to fetch — its card shows
   a live LiveBgPreview canvas here instead, same square slot as an ordinary video thumbnail. */
.published-card-img canvas {
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
}

.published-card-info {
  padding: 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.published-card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin: 0 0 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.published-card-tags {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 8px;
  row-gap: 6px;
}

.pub-tag {
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-on-surface-variant);
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 3px;
  white-space: nowrap;
  flex-shrink: 0;
}

.published-card-meta {
  font-size: 12px;
  color: var(--color-on-surface-variant);
  margin: auto 0 0 0;
}

.published-card-actions {
  padding: 8px 12px;
  border-top: 1px solid var(--glass-border);
  display: flex;
  gap: 8px;
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-container {
  background: var(--color-surface);
  border-radius: var(--radius-xl);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--glass-border);
}

.modal-header {
  padding: 20px;
  border-bottom: 1px solid var(--glass-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  color: var(--color-on-surface);
}

.modal-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-on-surface-variant);
  transition: color 0.2s ease;
}

.modal-close:hover {
  color: var(--color-on-surface);
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

.modal-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--glass-border);
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

.edit-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-field label {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-on-surface);
}

.form-field input[type="text"],
.form-field input[type="number"],
.form-field select,
.form-field textarea {
  padding: 10px 12px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  background: var(--color-surface-dim);
  color: var(--color-on-surface);
  font-size: 14px;
  font-family: inherit;
  width: 100%;
  box-sizing: border-box;
}

.form-field textarea {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  resize: vertical;
}

.form-field input[type="text"]:focus,
.form-field input[type="number"]:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  background: var(--color-surface);
}

/* Live Backgrounds tab: editor modal + preview + card grid ---------------------------------- */

.modal-container.modal-wide {
  max-width: 920px;
}

.livebg-editor-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(220px, 0.7fr);
  gap: 20px;
  align-items: start;
}

@media (max-width: 760px) {
  .livebg-editor-grid {
    grid-template-columns: 1fr;
  }
}

.livebg-editor-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.livebg-form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px;
}

.livebg-editor-preview {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.livebg-preview-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-on-surface);
  margin: 0;
}

.livebg-preview-frame {
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--glass-border);
  background: #000;
}

.livebg-preview-frame canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.livebg-preview-hint {
  font-size: 11px;
  color: var(--color-on-surface-variant);
  margin: 0;
}

.livebg-error {
  padding: 10px 12px;
  border-radius: var(--radius-md);
  background: rgba(255, 74, 90, 0.12);
  color: #ff4a5a;
  font-size: 13px;
  font-weight: 500;
}

.livebg-card-preview {
  width: 100%;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  background: #000;
}

.livebg-card-preview canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.livebg-card-badges {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.tag-checkbox-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  background: var(--color-surface-dim);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 13px;
  font-weight: 500;
  color: var(--color-on-surface-variant);
  margin-right: 8px;
  margin-bottom: 8px;
}

.tag-checkbox-label:hover {
  border-color: var(--color-on-surface-variant);
  background: var(--color-surface);
}

.tag-checkbox {
  display: none;
}

.tag-checkbox:checked + .tag-checkbox-text {
  color: var(--color-primary);
}

.tag-checkbox-label:has(:checked) {
  background: rgba(var(--color-primary-rgb, 100, 200, 255), 0.15);
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.tag-checkbox-text {
  transition: color 0.2s ease;
}

/* Responsive Overrides */
@media (max-width: 900px) {
  .hero-content {
    /* minmax(0, 1fr), not 1fr: a bare 1fr track is floored at its widest item's min-content
       width, and .phone-nav-row (four un-shrinkable tab pills, ~367px) is wider than a phone
       viewport — which stretched the whole text column past .hero's overflow:hidden and clipped
       the last ~25px off every headline and paragraph. */
    grid-template-columns: minmax(0, 1fr);
    text-align: center;
  }
  .phone-wrap {
    width: 100%;
    max-width: 100%;
  }
  .phone-nav-row {
    width: 100%;
    max-width: 100%;
    flex-wrap: wrap;
  }
  .hero h1 {
    font-size: 40px;
  }
  .hero p.subhead {
    max-width: 100%;
  }
  .cta-row, .pill-row {
    justify-content: center;
  }
  .features-row, .features-row.reverse {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .features-row.reverse .features-text-col,
  .features-row.reverse .features-phone-col {
    order: 0;
  }
  .features-row p.desc {
    max-width: 100%;
  }
  .features-row ul.bullets {
    align-items: center;
  }
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  .highlights-grid {
    grid-template-columns: 1fr;
  }
  .tide-nav {
    width: calc(100% - 48px);
  }
  .tide-nav-links {
    display: none;
  }
  .tide-nav-toggle {
    display: inline-flex;
  }
  /* [hidden] stays authoritative — initMobileNav() toggles it, this only supplies the layout
     the panel uses once it's shown. */
  .tide-nav-mobile:not([hidden]) {
    display: flex;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .tide-nav-btn {
    padding: 8px 16px;
    font-size: 13px;
  }
}

@media (max-width: 680px) {
  .nav-ph-badge {
    display: none;
  }
}

/* ─────────────────────────────────────────────────────────────
   Power / efficiency stats band (homepage)
   ───────────────────────────────────────────────────────────── */
.power-sec {
  position: relative;
  padding: 40px 48px 96px;
  box-sizing: border-box;
}
.power-inner {
  max-width: 1240px;
  margin: 0 auto;
  text-align: center;
}
.power-inner h2 {
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: var(--tracking-tight);
  color: var(--color-on-surface);
  margin: 20px 0 14px;
}
.power-lead {
  font-size: 17px;
  line-height: 1.6;
  color: var(--color-on-surface-variant);
  max-width: 640px;
  margin: 0 auto 44px;
}
.power-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 36px;
}
.power-stat {
  border-radius: var(--radius-xl);
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
  box-shadow: var(--shadow-1);
  padding: 30px 20px;
}
.power-stat .num {
  font-family: var(--font-display);
  font-size: 46px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: var(--tracking-tight);
  color: var(--color-primary);
}
.power-stat .num small {
  font-size: 22px;
  font-weight: 600;
}
.power-stat .label {
  display: block;
  margin-top: 14px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-on-surface-variant);
}
.power-compare {
  display: flex;
  gap: 20px;
  max-width: 880px;
  margin: 0 auto;
  text-align: left;
}
.power-compare .col {
  flex: 1;
  border-radius: var(--radius-xl);
  padding: 26px 28px;
  border: 1px solid var(--glass-border);
  background: var(--glass-surface);
  backdrop-filter: blur(var(--blur-md));
  -webkit-backdrop-filter: blur(var(--blur-md));
}
.power-compare .col.tide {
  border-color: var(--color-primary);
}
.power-compare h4 {
  margin: 0 0 16px;
  font-size: 15px;
  font-weight: 700;
  color: var(--color-on-surface);
  display: flex;
  align-items: center;
  gap: 8px;
}
.power-compare .col.tide h4 { color: var(--color-primary); }
.power-compare ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.power-compare li {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--color-on-surface-variant);
  display: flex;
  align-items: flex-start;
  gap: 9px;
}
.power-compare li i { flex-shrink: 0; margin-top: 2px; color: var(--color-on-surface-disabled); }
.power-compare .col.tide li i { color: var(--color-primary); }

@media (max-width: 880px) {
  .power-sec { padding: 32px 20px 72px; }
  .power-inner h2 { font-size: 32px; }
  .power-stats { grid-template-columns: repeat(2, 1fr); }
  .power-compare { flex-direction: column; }
}

/* ─────────────────────────────────────────────────────────────
   Closed Testing Dialog — intercepts the Google Play buttons
   while Drift is gated behind the tester group allowlist.
   ───────────────────────────────────────────────────────────── */
.testing-dialog-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--color-scrim);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--dur-medium) var(--ease-standard), visibility 0s linear var(--dur-medium);
}

.testing-dialog-overlay.open {
  opacity: 1;
  visibility: visible;
  transition: opacity var(--dur-medium) var(--ease-standard);
}

.testing-dialog {
  position: relative;
  width: 100%;
  max-width: 440px;
  background: var(--glass-surface-strong);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-3);
  backdrop-filter: blur(var(--blur-lg));
  -webkit-backdrop-filter: blur(var(--blur-lg));
  padding: 32px 28px 28px;
  transform: translateY(28px) scale(0.94);
  opacity: 0;
  transition: transform var(--dur-spring) var(--ease-spring), opacity var(--dur-medium) var(--ease-standard);
}

.testing-dialog-overlay.open .testing-dialog {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.testing-dialog-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-on-surface-variant);
  transition: all 0.2s ease;
}

.testing-dialog-close:hover {
  color: var(--color-on-surface);
  background: var(--color-overlay-hover);
}

.testing-dialog-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-primary-container, oklch(36% 0.14 260));
  color: var(--color-primary-90, oklch(90% 0.06 260));
  margin-bottom: 16px;
}

.testing-dialog h2 {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 700;
  color: var(--color-on-surface);
}

.testing-dialog > p {
  margin: 0 0 20px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--color-on-surface-variant);
}

.testing-dialog-steps {
  list-style: none;
  margin: 0 0 24px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.testing-dialog-steps li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--color-on-surface-variant);
}

.testing-dialog-step-num {
  flex: none;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  border-radius: 50%;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.testing-dialog > p.testing-dialog-note {
  margin: 0 0 20px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--glass-border);
  background: var(--glass-surface);
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-on-surface-variant);
}

.testing-dialog-note strong {
  color: var(--color-on-surface);
  font-weight: 700;
}

.testing-dialog-note a {
  color: var(--color-primary);
  font-weight: 600;
  white-space: nowrap;
}

.testing-dialog-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.testing-dialog-actions .btn {
  width: 100%;
  justify-content: center;
}

.testing-dialog-split-actions {
  display: flex;
  gap: 10px;
  width: 100%;
}

.testing-dialog-split-actions .btn {
  flex: 1;
  min-width: 0;
  padding-left: 8px;
  padding-right: 8px;
  font-size: 13.5px;
  white-space: nowrap;
}

@media (max-width: 420px) {
  .testing-dialog-split-actions {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .testing-dialog { padding: 28px 20px 22px; }
}

/* ─────────────────────────────────────────────────────────────
   Backdrop Partner Affiliate Card Section
   ───────────────────────────────────────────────────────────── */
.backdrop-partner-sec {
  padding: 80px 48px;
  position: relative;
  z-index: 2;
}

.backdrop-partner-inner {
  max-width: 1180px;
  margin: 0 auto;
}

.backdrop-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  padding: 48px;
  border-radius: 24px;
  background: var(--glass-surface, rgba(255, 255, 255, 0.03));
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.08));
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  position: relative;
  overflow: hidden;
}

.backdrop-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, oklch(63% 0.19 260), oklch(66% 0.19 340), transparent);
}

.backdrop-card-content h2 {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  line-height: 1.2;
  margin: 12px 0 16px;
  color: var(--color-on-surface);
}

.backdrop-lead {
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-on-surface-variant);
  margin-bottom: 24px;
}

.backdrop-support-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 16px;
}

.backdrop-support-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 14px;
  color: var(--color-on-surface);
  margin-bottom: 6px;
}

.backdrop-support-box p {
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-on-surface-variant);
  margin: 0;
}

.backdrop-attribution {
  font-size: 12px;
  color: var(--color-on-surface-variant);
  opacity: 0.7;
  margin-bottom: 24px;
}

.backdrop-cta-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.backdrop-card-media {
  position: relative;
}

.backdrop-image-frame {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.backdrop-image-frame img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  image-rendering: -webkit-optimize-contrast;
  transition: transform 0.4s ease;
}

.backdrop-card:hover .backdrop-image-frame img {
  transform: scale(1.02);
}

@media (max-width: 900px) {
  .backdrop-partner-sec {
    padding: 48px 24px;
  }
  .backdrop-card {
    grid-template-columns: 1fr;
    padding: 32px 24px;
    gap: 32px;
  }
  .backdrop-card-content h2 {
    font-size: 26px;
  }
}


/* ─────────────────────────────────────────────────────────────
   Reduced motion
   Two things on this site animate indefinitely rather than in response to an
   action: the drifting colour wash behind every page, and the Community
   marquee. Both stop here. The marquee needs more than `animation: none` — a
   strip that no longer scrolls, and that the user can't scroll by hand either,
   would leave most of the catalog permanently off-screen — so it reflows into a
   wrapped grid instead. js/main.js reads the same media query and renders one
   static frame per card rather than a rAF loop.
   ───────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  body::before {
    animation: none;
  }

  .gallery-marquee-container {
    width: auto;
    left: auto;
    right: auto;
    margin-left: 0;
    margin-right: 0;
    overflow: visible;
  }

  .gallery-marquee {
    animation: none;
    width: auto;
    flex-wrap: wrap;
    justify-content: center;
  }

  /* Everything else on the page animates only as a response to input (hover, tab switches,
     dialog open), where an abrupt change is the accessible behaviour rather than a jarring one. */
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
  }
}
