/* ========================================
   SMART TOOL FACTORY — Dark Modern Theme
   Glassmorphism + Ambient + Interactive
   ======================================== */

:root {
  --bg: #06080f;
  --bg-subtle: #0a0e1a;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.07);
  --surface-strong: rgba(255, 255, 255, 0.08);
  --glass: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-border-hover: rgba(255, 255, 255, 0.15);
  --text: #e8ecf4;
  --text-secondary: rgba(255, 255, 255, 0.55);
  --text-tertiary: rgba(255, 255, 255, 0.35);
  --accent: #6366f1;
  --accent-light: #818cf8;
  --accent-glow: rgba(99, 102, 241, 0.4);
  --cyan: #22d3ee;
  --cyan-glow: rgba(34, 211, 238, 0.3);
  --purple: #a78bfa;
  --gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #a78bfa 100%);
  --gradient-text: linear-gradient(135deg, #818cf8 0%, #c084fc 50%, #22d3ee 100%);
  --gradient-subtle: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.1) 100%);
  --shadow-glow: 0 0 60px rgba(99, 102, 241, 0.15);
  --shadow-lg: 0 30px 90px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 18px 40px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 8px 20px rgba(0, 0, 0, 0.2);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --container: min(1200px, calc(100vw - 40px));
  --header-height: 80px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
p { margin: 0; }

/* ---- Canvas background ---- */
#sphere-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0.6;
}

/* ---- Ambient blobs ---- */
.ambient-blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
  animation: blobFloat 20s ease-in-out infinite;
}

.blob-1 {
  width: 600px;
  height: 600px;
  top: -200px;
  left: -100px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.3), transparent 70%);
}

.blob-2 {
  width: 500px;
  height: 500px;
  top: 40%;
  right: -150px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.2), transparent 70%);
  animation-delay: -7s;
}

.blob-3 {
  width: 400px;
  height: 400px;
  bottom: -100px;
  left: 30%;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.15), transparent 70%);
  animation-delay: -14s;
}

@keyframes blobFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -40px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.95); }
}

/* ---- Page shell ---- */
.page-shell {
  position: relative;
  z-index: 1;
}

.container {
  width: var(--container);
  margin: 0 auto;
}

.section {
  padding: 0 0 120px;
}

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 16px 0;
  transition: padding 300ms ease, backdrop-filter 300ms ease;
}

.site-header.is-scrolled {
  padding: 10px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background: rgba(6, 8, 15, 0.7);
  backdrop-filter: blur(24px) saturate(1.5);
  transition: border-color 300ms ease, background 300ms ease;
}

.site-header.is-scrolled .header-inner {
  border-color: var(--glass-border-hover);
  background: rgba(6, 8, 15, 0.85);
}

/* ---- Brand ---- */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: var(--gradient);
  box-shadow: 0 0 20px var(--accent-glow);
}

.brand-mark svg {
  width: 22px;
  height: 22px;
  stroke: white;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.3;
}

.brand-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.brand-copy strong {
  font-family: "Sora", "Inter", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

.brand-copy span {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

/* ---- Nav ---- */
.main-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.main-nav a {
  position: relative;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 200ms ease, background 200ms ease;
}

.main-nav a:hover,
.main-nav a:focus-visible {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

/* ---- Buttons ---- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 16px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: white;
  background: var(--gradient);
  border: none;
  box-shadow: 0 8px 32px var(--accent-glow);
}

.button-primary:hover {
  box-shadow: 0 12px 48px var(--accent-glow), 0 0 0 1px rgba(255,255,255,0.1);
}

.button-glow::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: var(--gradient);
  z-index: -1;
  filter: blur(16px);
  opacity: 0.5;
  transition: opacity 300ms ease;
}

.button-glow:hover::before {
  opacity: 0.8;
}

.button-glass {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--glass-border);
  backdrop-filter: blur(12px);
}

.button-glass:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--glass-border-hover);
}

.button-light {
  color: var(--bg);
  background: white;
  font-weight: 700;
  box-shadow: 0 8px 32px rgba(255,255,255,0.15);
}

.button-light:hover {
  box-shadow: 0 16px 48px rgba(255,255,255,0.2);
}

.button-glow-light::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: white;
  z-index: -1;
  filter: blur(20px);
  opacity: 0.3;
  transition: opacity 300ms ease;
}

.button-glow-light:hover::before {
  opacity: 0.5;
}

.header-cta {
  min-height: 42px;
  padding: 0 18px;
  border-radius: 12px;
  font-size: 0.85rem;
}

.header-cta svg {
  width: 16px;
  height: 16px;
}

/* ---- Hero ---- */
.hero {
  padding-top: 40px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.hero-copy {
  display: grid;
  gap: 28px;
}

.eyebrow {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 10px;
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background: var(--glass);
  color: var(--accent-light);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  backdrop-filter: blur(12px);
}

.eyebrow-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
  animation: dotPulse 2s ease-in-out infinite;
}

@keyframes dotPulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 12px var(--accent-glow); }
  50% { opacity: 0.5; box-shadow: 0 0 24px var(--accent-glow); }
}

.eyebrow-subtle {
  color: var(--accent-light);
}

.eyebrow-on-dark {
  color: rgba(255, 255, 255, 0.9);
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
}

.hero h1 {
  margin: 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: clamp(3.2rem, 5.5vw, 5.8rem);
  font-weight: 800;
  letter-spacing: -0.06em;
  line-height: 0.95;
}

.hero-line {
  display: block;
  opacity: 0;
  transform: translateY(40px);
  animation: revealLine 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero-line[data-reveal-delay="1"] { animation-delay: 0.2s; }
.hero-line[data-reveal-delay="2"] { animation-delay: 0.4s; }
.hero-line[data-reveal-delay="3"] { animation-delay: 0.6s; }

@keyframes revealLine {
  to { opacity: 1; transform: translateY(0); }
}

.hero-line-gradient {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-summary {
  max-width: 50ch;
  color: var(--text-secondary);
  font-size: 1.1rem;
  line-height: 1.8;
}

.hero-summary strong {
  color: var(--text);
}

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

/* ---- Hero stage ---- */
.hero-stage-wrap {
  position: relative;
  perspective: 1000px;
}

.hero-stage {
  position: relative;
  min-height: 620px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--glass-border);
  background: radial-gradient(ellipse at 30% 20%, rgba(99, 102, 241, 0.12), transparent 50%),
              radial-gradient(ellipse at 80% 80%, rgba(139, 92, 246, 0.08), transparent 50%),
              var(--surface);
  box-shadow: var(--shadow-glow);
  overflow: hidden;
  backdrop-filter: blur(20px);
}

.stage-badge {
  position: absolute;
  top: 20px;
  left: 20px;
  z-index: 3;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid var(--glass-border);
  background: rgba(6, 8, 15, 0.7);
  backdrop-filter: blur(16px);
}

.stage-badge strong {
  display: block;
  font-size: 0.85rem;
  color: var(--text);
}

.stage-badge span {
  display: block;
  margin-top: 2px;
  color: var(--text-tertiary);
  font-size: 0.78rem;
}

.stage-card {
  position: absolute;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: var(--shadow-lg);
  transition: transform 500ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 500ms ease;
}

.stage-card:hover {
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

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

.stage-card.stage-wide {
  top: 80px;
  right: 24px;
  width: 72%;
  aspect-ratio: 16 / 9;
}

.stage-card.stage-phone {
  width: min(38%, 220px);
  aspect-ratio: 9 / 18;
  padding: 10px;
}

.stage-card.stage-phone img {
  border-radius: 16px;
  object-fit: contain;
}

.stage-card.stage-phone-left {
  left: 32px;
  bottom: 50px;
  transform: rotate(-6deg);
}

.stage-card.stage-phone-left:hover {
  transform: rotate(-3deg) translateY(-8px);
}

.stage-card.stage-phone-right {
  right: 50px;
  bottom: 20px;
  transform: rotate(7deg);
}

.stage-card.stage-phone-right:hover {
  transform: rotate(4deg) translateY(-8px);
}

.stage-card-meta {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  color: white;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.stage-card-meta strong { font-size: 0.88rem; }
.stage-card-meta span { font-size: 0.78rem; color: rgba(255, 255, 255, 0.6); }

/* ---- Stats bar ---- */
.stats-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-top: 60px;
  padding: 28px 40px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  background: var(--glass);
  backdrop-filter: blur(24px);
}

.stat-card {
  flex: 1;
  text-align: center;
  padding: 8px 20px;
}

.stat-number {
  display: block;
  font-family: "Sora", "Inter", sans-serif;
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-card span {
  display: block;
  margin-top: 4px;
  color: var(--text-tertiary);
  font-size: 0.85rem;
  font-weight: 500;
}

.stat-divider {
  width: 1px;
  height: 48px;
  background: var(--glass-border);
  flex-shrink: 0;
}

/* ---- Section heads ---- */
.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 40px;
}

.section-head h2 {
  margin: 0;
  margin-top: 16px;
  font-family: "Sora", "Inter", sans-serif;
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.05em;
  line-height: 1;
}

.section-head p {
  max-width: 42ch;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ---- Apps grid ---- */
.apps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* ---- App card ---- */
.app-card {
  position: relative;
  display: grid;
  min-height: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  background: var(--glass);
  backdrop-filter: blur(16px);
  overflow: hidden;
  transition: border-color 400ms ease, transform 400ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 400ms ease;
}

.app-card:hover {
  border-color: var(--glass-border-hover);
  transform: translateY(-6px);
  box-shadow: var(--shadow-glow);
}

.app-media {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 260px;
  padding: 0;
  background: var(--gradient-subtle);
  overflow: hidden;
}

/* ---- 3D Circular Carousel ---- */
.carousel {
  position: relative;
  width: 100%;
  min-height: 280px;
  overflow: hidden;
  perspective: 800px;
  user-select: none;
}

.carousel-track {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-slide {
  position: absolute;
  display: grid;
  place-items: center;
  padding: 16px;
  transition: transform 500ms cubic-bezier(0.16, 1, 0.3, 1),
              opacity 500ms ease,
              z-index 0ms 250ms;
  will-change: transform, opacity;
}

.carousel-slide img {
  max-width: 200px;
  max-height: 220px;
  width: auto;
  object-fit: contain;
  border-radius: 20px;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.4));
  pointer-events: none;
}

.app-media[data-orientation="landscape"] .carousel-slide img {
  max-width: 280px;
  max-height: 180px;
  border-radius: 16px;
}

/* Slide positions: center, left, right, far-left, far-right */
.carousel-slide[data-pos="center"] {
  z-index: 3;
  transform: translateX(0) scale(1);
  opacity: 1;
}

.carousel-slide[data-pos="left"] {
  z-index: 2;
  transform: translateX(-65%) scale(0.75) rotateY(15deg);
  opacity: 0.6;
}

.carousel-slide[data-pos="right"] {
  z-index: 2;
  transform: translateX(65%) scale(0.75) rotateY(-15deg);
  opacity: 0.6;
}

.carousel-slide[data-pos="far-left"] {
  z-index: 1;
  transform: translateX(-120%) scale(0.55) rotateY(25deg);
  opacity: 0.2;
}

.carousel-slide[data-pos="far-right"] {
  z-index: 1;
  transform: translateX(120%) scale(0.55) rotateY(-25deg);
  opacity: 0.2;
}

.carousel-slide[data-pos="hidden"] {
  z-index: 0;
  transform: translateX(0) scale(0.4);
  opacity: 0;
  pointer-events: none;
}

/* Carousel arrows */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  background: rgba(6, 8, 15, 0.6);
  backdrop-filter: blur(12px);
  color: var(--text);
  cursor: pointer;
  opacity: 0;
  transition: opacity 300ms ease, background 200ms ease, transform 200ms ease, border-color 200ms ease;
}

.app-card:hover .carousel-arrow { opacity: 1; }

.carousel-arrow:hover {
  background: rgba(99, 102, 241, 0.3);
  border-color: var(--glass-border-hover);
  transform: translateY(-50%) scale(1.1);
}

.carousel-prev { left: 6px; }
.carousel-next { right: 6px; }

/* Carousel dots */
.carousel-dots {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(6, 8, 15, 0.5);
  backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  cursor: pointer;
  padding: 0;
  transition: background 300ms ease, transform 300ms ease, width 300ms ease;
}

.carousel-dot.is-active {
  background: var(--accent-light);
  width: 20px;
  border-radius: 999px;
  box-shadow: 0 0 10px var(--accent-glow);
}

.carousel-dot:hover:not(.is-active) {
  background: rgba(255, 255, 255, 0.5);
  transform: scale(1.2);
}

.app-body {
  display: grid;
  gap: 16px;
  padding: 24px;
}

.app-topline {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.app-icon {
  width: 52px;
  height: 52px;
  flex: 0 0 auto;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.app-title-wrap { min-width: 0; }

.app-kicker {
  display: block;
  color: var(--accent-light);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.app-card h3 {
  margin: 4px 0 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

.edition-pill {
  margin-left: auto;
  flex: 0 0 auto;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.app-body > p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.7;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(99, 102, 241, 0.2);
  background: rgba(99, 102, 241, 0.08);
  color: var(--accent-light);
  font-size: 0.78rem;
  font-weight: 600;
}

/* ---- Reviews ---- */
.app-reviews {
  display: grid;
  gap: 10px;
  padding-top: 4px;
}

.app-reviews-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.app-rating {
  color: #facc15;
  font-size: 0.85rem;
  letter-spacing: 1px;
}

.app-rating-label {
  color: var(--text-tertiary);
  font-size: 0.8rem;
  font-weight: 500;
}

.review-scroll {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-bottom: 4px;
}

.review-scroll::-webkit-scrollbar { display: none; }

.review-card {
  flex: 0 0 85%;
  min-width: 0;
  margin: 0;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.03);
  scroll-snap-align: start;
  transition: border-color 300ms ease;
}

.review-card:hover {
  border-color: var(--glass-border-hover);
}

.review-stars {
  color: #facc15;
  font-size: 0.72rem;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.review-card p {
  color: var(--text-secondary);
  font-size: 0.82rem;
  line-height: 1.6;
  font-style: italic;
}

.review-card cite {
  display: block;
  margin-top: 8px;
  color: var(--text-tertiary);
  font-size: 0.75rem;
  font-style: normal;
  font-weight: 600;
}

.app-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 8px;
  border-top: 1px solid var(--glass-border);
}

.install-badge {
  color: var(--text-tertiary);
  font-size: 0.85rem;
  font-weight: 500;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-light);
  font-size: 0.88rem;
  font-weight: 600;
  transition: color 200ms ease, gap 200ms ease;
}

.text-link::after {
  content: "\2192";
  transition: transform 200ms ease;
}

.text-link:hover {
  color: var(--cyan);
}

.text-link:hover::after {
  transform: translateX(4px);
}

/* ---- Family section ---- */
.family-section {
  padding-top: 20px;
}

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

.family-card {
  position: relative;
  display: grid;
  min-height: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  background: var(--glass);
  backdrop-filter: blur(16px);
  overflow: hidden;
  transition: border-color 400ms ease, transform 400ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 400ms ease;
}

.family-card:hover {
  border-color: var(--glass-border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

.family-copy {
  display: grid;
  gap: 14px;
  padding: 28px 28px 20px;
}

.family-card h3 {
  margin: 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--text);
}

.family-card p {
  color: var(--text-secondary);
  line-height: 1.72;
  font-size: 0.92rem;
}

.family-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.family-media {
  display: grid;
  gap: 12px;
  padding: 0 20px 20px;
}

.family-media.family-media-duo {
  grid-template-columns: repeat(2, 1fr);
}

.family-media.family-media-landscape {
  grid-template-columns: 1fr;
}

.family-shot {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid var(--glass-border);
  background: var(--gradient-subtle);
  min-height: 260px;
  display: grid;
  place-items: center;
  padding: 16px;
}

.family-shot img {
  position: relative;
  z-index: 1;
  max-width: min(84%, 240px);
  max-height: 230px;
  width: auto;
  object-fit: contain;
  border-radius: 20px;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.3));
}

.family-shot.wide {
  min-height: 240px;
}

.family-shot.wide img {
  width: min(100%, 92%);
  max-width: 100%;
  max-height: 200px;
  border-radius: 16px;
}

/* ---- Download CTA ---- */
.download-section {
  padding-top: 20px;
}

.download-panel {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 40px;
  padding: 60px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.1) 50%, rgba(34, 211, 238, 0.05) 100%);
  border: 1px solid rgba(99, 102, 241, 0.2);
  position: relative;
  overflow: hidden;
}

.download-panel::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.15), transparent 60%);
  pointer-events: none;
}

.download-content {
  display: grid;
  gap: 20px;
  position: relative;
  z-index: 1;
}

.download-panel h2 {
  margin: 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.05em;
  line-height: 1;
}

.download-panel p {
  max-width: 44ch;
  color: var(--text-secondary);
  line-height: 1.75;
}

.download-actions {
  margin-top: 8px;
}

.download-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
}

/* ---- Footer ---- */
.site-footer {
  padding: 0 0 42px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 28px;
  padding: 40px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--glass-border);
  background: var(--glass);
  backdrop-filter: blur(16px);
}

.footer-brand .brand-copy span {
  color: var(--text-tertiary);
}

.footer-column {
  display: grid;
  gap: 16px;
  align-content: start;
}

.footer-column h3 {
  margin: 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.footer-links {
  display: grid;
  gap: 12px;
}

.footer-links a {
  color: var(--text-tertiary);
  font-size: 0.92rem;
  transition: color 200ms ease;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: var(--text);
}

.footer-bottom {
  grid-column: 1 / -1;
  padding-top: 24px;
  border-top: 1px solid var(--glass-border);
  color: var(--text-tertiary);
  font-size: 0.82rem;
}

/* ---- Scroll reveal ---- */
/* Scroll reveal — only animate if JS adds .reveal-ready to body */
body.reveal-ready [data-reveal] {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

body.reveal-ready [data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

body.reveal-ready [data-reveal-delay="1"] { transition-delay: 0.1s; }
body.reveal-ready [data-reveal-delay="2"] { transition-delay: 0.2s; }
body.reveal-ready [data-reveal-delay="3"] { transition-delay: 0.3s; }
body.reveal-ready [data-reveal-delay="4"] { transition-delay: 0.4s; }
body.reveal-ready [data-reveal-delay="5"] { transition-delay: 0.5s; }
body.reveal-ready [data-reveal-delay="6"] { transition-delay: 0.6s; }

body.reveal-ready .app-card,
body.reveal-ready .family-card {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 400ms ease,
              box-shadow 400ms ease;
}

body.reveal-ready .app-card.is-visible,
body.reveal-ready .family-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Responsive ---- */
@media (max-width: 1160px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .section-head {
    flex-direction: column;
    align-items: start;
  }

  .apps-grid, .family-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .download-panel {
    grid-template-columns: 1fr;
  }

  .download-visual {
    display: none;
  }
}

@media (max-width: 900px) {
  .site-header {
    position: sticky;
  }

  .main-nav, .header-cta {
    display: none;
  }

  .hero {
    min-height: auto;
    padding-top: 24px;
  }

  .hero-stage {
    min-height: 540px;
  }

  .apps-grid, .family-grid, .footer-grid {
    grid-template-columns: 1fr;
  }

  .stats-bar {
    flex-wrap: wrap;
    gap: 0;
    padding: 20px;
  }

  .stat-card {
    flex: 0 0 50%;
    padding: 12px 16px;
  }

  .stat-divider {
    display: none;
  }

  .download-panel {
    padding: 36px 24px;
  }
}

@media (max-width: 720px) {
  .section { padding-bottom: 80px; }

  .hero h1 {
    font-size: clamp(2.8rem, 12vw, 4.2rem);
  }

  .hero-stage {
    min-height: 460px;
  }

  .stage-card.stage-wide {
    top: 70px;
    width: calc(100% - 32px);
    left: 16px;
    right: 16px;
  }

  .stage-card.stage-phone {
    width: 42%;
    max-width: 170px;
  }

  .stage-card.stage-phone-left { left: 14px; bottom: 42px; }
  .stage-card.stage-phone-right { right: 14px; bottom: 14px; }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .button { width: 100%; }

  .section-head h2, .download-panel h2 {
    font-size: clamp(1.8rem, 10vw, 2.8rem);
  }

  .family-media.family-media-duo {
    grid-template-columns: 1fr;
  }

  .download-panel { border-radius: var(--radius-lg); }

  .footer-grid { padding: 28px 20px; }
}

/* ---- Reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  #sphere-canvas { display: none; }
  .ambient-blob { animation: none; }

  [data-reveal], .app-card, .family-card {
    opacity: 1;
    transform: none;
  }

  .hero-line {
    opacity: 1;
    transform: none;
    animation: none;
  }
}
