/* ─────────────────────────────────────────────────────────────
   RW x GEMS OtoColor — style.css
   Ultra Responsive — Mobile-First (375 / 640 / 768 / 1024 / 1440)
   Primary Font: Montserrat (Variable) + Inter (Google Fonts)
   ───────────────────────────────────────────────────────────── */

@font-face {
  font-family: 'Montserrat';
  src: url('Montserrat/Montserrat-VariableFont_wght.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Montserrat';
  src: url('Montserrat/Montserrat-Italic-VariableFont_wght.ttf') format('truetype');
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

/* ─── DESIGN TOKENS ─── */
:root {
  /* Colors */
  --color-black: #05070a;
  --color-surface-1: #0a0e14;
  --color-surface-2: #121821;
  --color-surface-3: #1a2332;
  --color-primary: #6366f1;
  --color-primary-hover: #4f46e5;
  --color-primary-glow: rgba(99, 102, 241, 0.15);
  --color-emerald: #10b981;
  --color-emerald-glow: rgba(16, 185, 129, 0.1);
  --color-amber: #f59e0b;
  --color-text: #f8fafc;
  --color-text-muted: #94a3b8;
  --color-text-dim: #64748b;
  --color-border: #1e293b;
  --color-border-bright: #334155;

  /* Typography */
  --font-body: 'Montserrat', system-ui, -apple-system, sans-serif;
  --font-display: 'Montserrat', sans-serif;

  /* Spacing — 8pt grid */
  --space-2: 0.5rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;

  /* Layout */
  --header-height: 64px;
  --header-height-mobile: 56px;
  --container-max: 1400px;
  --gutter: clamp(1rem, 5vw, 2rem);

  /* Borders */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 32px;

  /* Z-index scale */
  --z-bg: -10;
  --z-content: 10;
  --z-header: 100;
  --z-overlay: 200;
}

/* ─── RESET ─── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background-color: var(--color-black);
  color: var(--color-text);
  font-family: var(--font-body);
  line-height: 1.5;
  font-size: 16px;
  /* Never disable zoom — accessibility */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ─── LAYOUT ─── */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

header, main, footer { width: 100%; }

main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* ─── HEADER ─── */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height-mobile);
  z-index: var(--z-header);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  /* Safe area for notch */
  padding-top: env(safe-area-inset-top, 0px);
  display: flex;
  align-items: center;
  border-bottom: 1px solid transparent;
}

@media (min-width: 768px) {
  .site-header {
    height: var(--header-height);
  }
}

/* Glass State on Scroll */
.site-header.scrolled {
  background: rgba(10, 14, 20, 0.7);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.header-inner {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  justify-content: center;
  align-items: center;
}

.logo {
  text-decoration: none;
  display: flex;
  align-items: center;
  min-height: 44px;
  z-index: 10;
}

.logo-wrapper {
  position: relative;
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
}

.logo-text {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 3vw, 1.5rem);
  font-weight: 900;
  transition: clip-path 0.1s linear;
}

.text-white {
  color: #fff;
}

.text-black {
  color: #000;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  clip-path: polygon(100% 0, 100% 0, 100% 100%, 100% 100%);
}




/* ─── BACKGROUND COMPARISON ─── */
.bg-comparison {
  position: fixed;
  inset: 0;
  z-index: var(--z-bg);
  overflow: hidden;
  background-color: #0c0e14;
  pointer-events: none;
}

.color-layer,
.sketch-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  will-change: clip-path;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  animation: cinematicDrift 20s ease-in-out infinite;
  transform-origin: center;
  /* Prevent layout shift */
  aspect-ratio: 16/9;
}

@keyframes cinematicDrift {
  0%   { transform: scale(1.05) translate(-1%, -1%); }
  50%  { transform: scale(1.05) translate(1%, 1%); }
  100% { transform: scale(1.05) translate(-1%, -1%); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-bg-img { animation: none; }
  .scan-line    { animation: none !important; }
}

.color-layer {
  z-index: -2;
}

.sketch-layer {
  z-index: -1;
  clip-path: polygon(var(--slider-pos, 50%) 0, 100% 0, 100% 100%, var(--slider-pos, 50%) 100%);
  filter: contrast(1.1) brightness(1.1);
}

.compare-divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--slider-pos, 50%);
  width: 2px;
  background: rgba(255, 255, 255, 0.5);
  z-index: 5;
  transform: translateX(-50%);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
  pointer-events: none;
}

.divider-handle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  /* Touch target: 44px min */
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  color: #0c0e14;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  gap: 2px;
}

.divider-handle svg {
  width: 16px;
  height: 16px;
}

/* ─── HERO SECTION ─── */
.hero-section {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: visible; /* allow proper scroll */
  /* Tight padding for single-screen fit */
  padding-top: calc(var(--header-height) + var(--space-4));
  padding-bottom: calc(48px + var(--space-4));
  /* Safe area insets */
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
}

.hero-content {
  width: 100%;
  position: relative;
  z-index: var(--z-content);
}

/* ─── HERO GRID ─── */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  align-items: center;
  width: 100%;
}

/* Tablet and up: 2-column */
@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr 1.4fr;
    gap: clamp(2rem, 4vw, 4rem);
  }
}

/* ─── TEXT PANEL (LEFT) ─── */
.hero-text-side {
  position: relative;
  width: 100%;
  /* Height adapts to content */
}

.panel-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Fluid padding */
  padding: clamp(1rem, 3vw, 2.5rem);
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  pointer-events: none;
}

/* Base Night Layer — sits in flow (relative) */
.panel-night {
  position: relative;       /* MUST stay in flow */
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.5);
  z-index: 1;
  pointer-events: auto;     /* Allow clicks through night layer */
}

.panel-night .hero-title--accent {
  color: #6366f1;
}

/* Top Paper Layer — revealed by slider */
.panel-paper {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.1);
  color: #000;
  z-index: 2;
  clip-path: polygon(100% 0, 100% 0, 100% 100%, 100% 100%);
  pointer-events: none;
}

.panel-paper .hero-title,
.panel-paper .hero-description,
.panel-paper .download-title {
  color: #000;
}

.panel-paper .hero-title--accent {
  color: transparent;
  -webkit-text-stroke: 1.5px #000;
  text-shadow: none;
}

.panel-paper .platform-btn {
  border-color: #000;
  color: #000;
  background: transparent;
  box-shadow: none;
}

.panel-paper .platform-btn:hover {
  background: #000;
  border-color: #000;
}

.panel-paper .platform-btn:hover svg {
  fill: #fff;
  color: #fff;
}

/* ─── TYPOGRAPHY ─── */
.hero-title {
  font-family: var(--font-display);
  /* Fluid: 2rem on 375px → 4.5rem on 1440px */
  font-size: clamp(2rem, 6vw, 4.5rem);
  font-weight: 800;
  line-height: 0.85;          /* tighter for single screen */
  letter-spacing: -0.04em;
  margin: 0;
  text-transform: uppercase;
  color: #fff;
  /* Prevent horizontal overflow */
  word-break: break-word;
  overflow-wrap: break-word;
}

.hero-title--accent {
  position: relative;
  display: inline-block;
  letter-spacing: -0.02em;
  line-height: 1;
}

.hero-description {
  /* Fluid: 0.85rem on mobile → 1rem on desktop */
  font-size: clamp(0.85rem, 1.8vw, 1rem);
  font-weight: 300;
  color: #fff;
  opacity: 0.9;
  line-height: 1.5;
  max-width: 100%;
}

/* ─── DOWNLOAD / CTA ─── */
.hero-actions {
  margin-top: var(--space-2);
}

.download-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-4);
  margin-top: var(--space-4);
}

.download-title {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #fff;
}

.platform-btn {
  background: rgba(99, 102, 241, 0.08);
  border: 1.5px solid var(--color-primary);
  border-radius: var(--radius-md);
  /* Touch-friendly: min 44×44px */
  min-width: 60px;
  min-height: 54px;
  padding: 0 clamp(0.75rem, 2vw, 1.25rem);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.1);
  touch-action: manipulation;   /* Eliminate 300ms tap delay */
}

.platform-btn:hover,
.platform-btn:focus-visible {
  background: var(--color-primary);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.platform-btn:active {
  transform: scale(0.97) translateY(0);
}

.platform-btn:hover svg { fill: #fff !important; color: #fff !important; }

.platform-btn svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.platform-btn--active {
  background: rgba(99, 102, 241, 0.1);
  border-color: var(--color-primary);
  color: #fff;
}

.platform-btn--active svg {
  opacity: 1;
  color: var(--color-primary);
}

/* ─── DEMO CARD (RIGHT) ─── */
.hero-demo-side {
  width: 100%;
  display: flex;
  justify-content: center;
}

@media (min-width: 1024px) {
  .hero-demo-side {
    justify-content: flex-end;
  }
}

.demo-card {
  width: 100%;
  max-width: 820px;
  background: rgba(10, 14, 20, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.8);
  overflow: hidden;
  position: relative;
  transition: transform 0.3s ease;
}

.demo-card:hover {
  transform: translateY(-4px);
}

.demo-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-primary), transparent);
}

.demo-card__header {
  height: 44px;
  background: rgba(18, 24, 33, 0.4);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  padding: 0 var(--space-4);
  justify-content: space-between;
}

.header-dots { display: flex; gap: 6px; }
.header-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-border-bright);
}

.header-title {
  font-size: 0.75rem;
  color: var(--color-text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 50%;
  text-align: right;
}

.demo-card__body {
  display: flex;
  flex-direction: column;
}

.demo-viewport {
  display: flex;
  background: rgba(11, 13, 17, 0.5);
  /* Fluid height: reduced for single-screen fit */
  height: clamp(200px, 35vw, 380px);
}

/* On large screens restore bigger height */
@media (min-width: 1024px) {
  .demo-viewport {
    height: clamp(280px, 25vw, 420px);
  }
}

.demo-canvas-area {
  flex: 1;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0; /* Prevent flex overflow */
}

.canvas-mesh {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.15;
  filter: hue-rotate(240deg);
}

.scan-line {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 2px;
  background: var(--color-emerald);
  box-shadow: 0 0 15px var(--color-emerald);
  z-index: 10;
  display: none;
  animation: scan 3s linear infinite;
}

@keyframes scan {
  0%   { top: 0%; }
  100% { top: 100%; }
}

.overlay-info {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: var(--space-4);
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  color: var(--color-text-dim);
  font-size: clamp(0.7rem, 1.5vw, 0.8rem);
  text-align: center;
}

/* ─── DEMO SIDEBAR ─── */
.demo-sidebar {
  background: rgba(18, 24, 33, 0.4);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  padding: var(--space-4);
  /* Fluid width: hidden on tiny, narrow on mobile, normal on desktop */
  width: clamp(100px, 18vw, 160px);
  flex-shrink: 0;
}

/* Hide sidebar below 400px to avoid crushing canvas */
@media (max-width: 399px) {
  .demo-sidebar {
    display: none;
  }
}

.sidebar-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-dim);
  margin-bottom: var(--space-4);
  white-space: nowrap;
}

.swatch-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: clamp(0.65rem, 1.2vw, 0.75rem);
  color: var(--color-text-muted);
  margin-bottom: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.swatch {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  flex-shrink: 0;
}

.swatch-add {
  height: 32px;
  border: 1px dashed var(--color-border-bright);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-dim);
  border-radius: 4px;
  font-size: 1.1rem;
  cursor: pointer;
  touch-action: manipulation;
}

/* ─── DEMO FOOTER ─── */
.demo-card__footer {
  padding: var(--space-4);
  background: transparent;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  gap: clamp(8px, 2vw, 16px);
  flex-wrap: wrap;
}

.progress-wrap {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.progress-bar-container {
  flex: 1;
  min-width: 0;
  height: 4px;
  background: var(--color-surface-3);
  border-radius: 99px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: var(--color-emerald);
  transition: width 0.3s ease;
  border-radius: 99px;
}

.progress-pct {
  font-size: 0.75rem;
  color: var(--color-emerald);
  font-weight: 700;
  width: 35px;
  text-align: right;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}

.btn-start-demo {
  /* Touch target */
  min-height: 44px;
  padding: 10px clamp(10px, 2vw, 18px);
  background: var(--color-primary);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: clamp(0.75rem, 1.5vw, 0.85rem);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  touch-action: manipulation;
  font-family: var(--font-body);
}

.btn-start-demo:hover,
.btn-start-demo:focus-visible {
  background: var(--color-primary-hover);
  transform: translateY(-1px);
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.btn-start-demo:active {
  transform: scale(0.97);
}

.btn-start-demo:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* ─── PREVIEW CHARACTER ─── */
.preview-character {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.preview-character svg {
  /* Fluid size */
  width: clamp(120px, 25vw, 220px);
  height: clamp(120px, 25vw, 220px);
}

/* ─── FOOTER ─── */
.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 48px;
  z-index: var(--z-header);
  border-top: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  background: rgba(5, 7, 10, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  /* Safe area bottom */
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--color-text-dim);
  width: 100%;
}

.footer-copy {
  text-align: center;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ─── BADGE / STATUS ─── */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: var(--color-emerald-glow);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 99px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-emerald);
}

.status-dot {
  width: 6px;
  height: 6px;
  background: var(--color-emerald);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--color-emerald);
  animation: pulse 2s infinite;
  flex-shrink: 0;
}

@keyframes pulse {
  0%   { transform: scale(1); opacity: 1; }
  50%  { transform: scale(1.5); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}

/* ─── NAV CTA ─── */
.nav-link--cta {
  padding: 8px 20px;
  background: var(--color-surface-2);
  border: 1px solid var(--color-border-bright);
  border-radius: 99px;
  color: #fff;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: all 0.2s;
  touch-action: manipulation;
}

.nav-link--cta:hover { border-color: var(--color-primary); }

/* ─── FOCUS STYLES (Accessibility) ─── */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ─── CREEPY BUTTON (if used) ─── */
.creepy-btn {
  position: relative;
  border: none;
  background: #fff;
  color: var(--color-black);
  padding: 18px 32px;
  border-radius: 16px;
  font-size: 1.1rem;
  font-weight: 900;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.2s;
  touch-action: manipulation;
  font-family: var(--font-body);
}

.creepy-btn__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-eyes {
  position: absolute;
  top: -50px;
  left: 0; right: 0;
  height: 50px;
  display: flex;
  justify-content: center;
  gap: 12px;
  transition: top 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}

.creepy-btn:hover .btn-eyes { top: -25px; }

.eye {
  width: 28px;
  height: 28px;
  background: #fff;
  border-radius: 50%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.pupil {
  width: 12px;
  height: 12px;
  background: var(--color-black);
  border-radius: 50%;
}

/* ─── DEMO CHARACTER (svg inline only) ─── */
#demo-character-svg {
  overflow: visible;
}

/* ─── STRAY SCROLLBAR (keep minimal) ─── */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--color-surface-1);
}
::-webkit-scrollbar-thumb {
  background: var(--color-border-bright);
  border-radius: 99px;
}

/* ─────────────────────────────────────────────────────────────
   BREAKPOINTS (mobile-first)
   375   → base mobile (already above)
   640   → large phone / compact tablet
   768   → tablet portrait
   1024  → tablet landscape / small laptop
   1440  → desktop
   ───────────────────────────────────────────────────────────── */

/* ── 640px: Large phone ── */
@media (min-width: 640px) {
  :root {
    --header-height: 60px;
  }

  .hero-title {
    line-height: 0.88;
  }

  .panel-layer {
    gap: var(--space-6);
  }
}

/* ── 768px: Tablet portrait ── */
@media (min-width: 768px) {
  .demo-viewport {
    height: clamp(280px, 35vw, 400px);
  }
}

/* ── 1024px: Tablet landscape / laptop ── */
@media (min-width: 1024px) {
  :root {
    --header-height: 64px;
  }

  .hero-title {
    line-height: 0.85;
  }

  .hero-section {
    /* On large screens, perfect vertical centering */
    align-items: center;
  }

  .panel-layer {
    gap: var(--space-6);
  }
}

/* ── 1440px: Desktop ── */
@media (min-width: 1440px) {
  .hero-title {
    font-size: 4.5rem;
  }
}

/* ─── LANDSCAPE PHONE (height constrained) ─── */
@media (max-height: 500px) and (orientation: landscape) {
  .hero-section {
    min-height: auto;
    padding-top: calc(var(--header-height) + 0.5rem);
    padding-bottom: 3.5rem;
    align-items: flex-start;
  }

  .hero-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    align-items: start;
  }

  .demo-viewport {
    height: clamp(160px, 25vh, 220px);
  }

  .hero-title {
    font-size: clamp(1.6rem, 5vw, 2.5rem);
  }
}

/* ─── VERY SMALL PHONES (<= 360px) ─── */
@media (max-width: 360px) {
  .demo-card__footer {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-start-demo {
    width: 100%;
    justify-content: center;
  }

  .progress-wrap {
    width: 100%;
  }
}

/* ─── PRINT ─── */
@media print {
  .bg-comparison,
  .compare-divider,
  .scan-line,
  .btn-start-demo { display: none; }

  body { overflow: visible; background: white; color: black; }
  .panel-night { background: white; border: 1px solid #ccc; }
  .hero-title, .hero-description { color: black; }
}
