/* ==========================================================================
   ChessTimer - Tournament Digital Clock Dark Theme & Ambient System
   Matches NeriQuest Android Studio AMOLED aesthetic
   ========================================================================== */

:root {
  --bg-amoled: #07090d;
  --bg-surface: #10141d;
  --bg-card: #151b27;
  --bg-card-hover: #1c2434;
  --bg-glass: rgba(21, 27, 39, 0.72);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(255, 255, 255, 0.14);

  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;

  /* Signature ChessTimer Palette */
  --accent-amber: #f59e0b;
  --accent-gold: #fbbf24;
  --accent-emerald: #10b981;
  --accent-cyan: #38bdf8;
  --accent-purple: #a855f7;
  --accent-red: #ef4444;

  --primary-gradient: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  --glow-amber: rgba(245, 158, 11, 0.35);

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 26px;
  --radius-pill: 9999px;

  --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);

  --font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent !important;
}

html {
  overflow-x: hidden;
  max-width: 100%;
  width: 100%;
  scroll-behavior: smooth;
  font-family: var(--font-family);
  background-color: var(--bg-amoled);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid rgba(245, 158, 11, 0.7);
  outline-offset: 3px;
  border-radius: inherit;
}

a, button, [role="button"], .preset-btn, .tool-btn, .player-panel, .faq-question {
  -webkit-tap-highlight-color: transparent !important;
  user-select: none;
  -webkit-user-select: none;
}

body {
  max-width: 100%;
  width: 100%;
  position: relative;
  overflow-x: hidden;
  min-height: 100vh;
  background-color: var(--bg-amoled);
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ==========================================================================
   Ambient Aurora Glow System (Subtle, blurred, atmospheric)
   ========================================================================== */
.ambient-glow-wrapper {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

/* Dynamic Continuous Hue-Shifting Keyframes (Evolving Ambient Aurora Spectrum) */
@keyframes ambientHueShift1 {
  0% {
    filter: blur(55px) hue-rotate(0deg);
  }
  50% {
    filter: blur(66px) hue-rotate(180deg);
  }
  100% {
    filter: blur(55px) hue-rotate(360deg);
  }
}

@keyframes ambientHueShift2 {
  0% {
    filter: blur(58px) hue-rotate(0deg);
  }
  50% {
    filter: blur(48px) hue-rotate(-180deg);
  }
  100% {
    filter: blur(58px) hue-rotate(-360deg);
  }
}

@keyframes ambientHueShift3 {
  0% {
    filter: blur(55px) hue-rotate(45deg);
  }
  50% {
    filter: blur(65px) hue-rotate(225deg);
  }
  100% {
    filter: blur(55px) hue-rotate(405deg);
  }
}

@keyframes ambientHueShift4 {
  0% {
    filter: blur(60px) hue-rotate(-30deg);
  }
  50% {
    filter: blur(50px) hue-rotate(150deg);
  }
  100% {
    filter: blur(60px) hue-rotate(330deg);
  }
}

.ambient-glow {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(55px);
  opacity: 0.52;
  will-change: transform, filter;
}

/* Glow 1: Continuous Morphing Emerald / Cyan / Violet / Amber */
.glow-1 {
  top: 4%;
  left: 10%;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(74, 222, 128, 0.18) 0%, rgba(34, 197, 94, 0.08) 42%, transparent 70%);
  animation: ambientHueShift1 20s linear infinite;
}

/* Glow 2: Continuous Morphing Sky Cyan / Deep Indigo / Coral */
.glow-2 {
  top: 32%;
  right: 6%;
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.16) 0%, rgba(14, 165, 233, 0.07) 42%, transparent 70%);
  animation: ambientHueShift2 26s linear infinite;
}

/* Glow 3: Continuous Morphing Lavender Violet / Rose / Emerald */
.glow-3 {
  bottom: 10%;
  left: 8%;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(192, 132, 252, 0.16) 0%, rgba(168, 85, 247, 0.06) 42%, transparent 70%);
  animation: ambientHueShift3 24s linear infinite;
}

/* Glow 4: Continuous Morphing Warm Amber / Magenta / Teal */
.glow-4 {
  top: 60%;
  left: 42%;
  width: 460px;
  height: 460px;
  background: radial-gradient(circle, rgba(251, 146, 60, 0.14) 0%, rgba(245, 158, 11, 0.05) 42%, transparent 70%);
  animation: ambientHueShift4 30s linear infinite;
}

.ambient-frosted-diffuser {
  position: absolute;
  inset: 0;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background: radial-gradient(circle at 50% 50%, transparent 65%, rgba(7, 9, 12, 0.3) 100%);
  pointer-events: none;
  z-index: 1;
}

/* ==========================================================================
   Navigation Bar
   ========================================================================== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 14, 21, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  padding: 0.85rem 0;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  transition: var(--transition-fast);
}

.back-link:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border-color);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.nav-logo-box {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  overflow: hidden;
  background: #1a1e29;
  border: 1px solid rgba(245, 158, 11, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.2);
}

.nav-logo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.brand-name {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.brand-version {
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent-gold);
  border: 1px solid rgba(245, 158, 11, 0.3);
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-pill);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: var(--transition-fast);
}

.nav-links a:hover {
  color: var(--accent-gold);
}

.btn-topbar-cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #181d28;
  color: var(--text-main);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(245, 158, 11, 0.35);
  transition: var(--transition-fast);
  overflow: hidden;
}

.btn-topbar-cta:hover {
  background: #202737;
  border-color: var(--accent-amber);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.25);
}

.topbar-cta-icon {
  width: 16px;
  height: 16px;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
  position: relative;
  z-index: 1;
  padding: 4.5rem 0 3.5rem;
  text-align: center;
}

.hero-content {
  max-width: 820px;
}

.hero-chips-container {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.75rem;
}

.hero-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
}

.chip-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.chip-amber { border-color: rgba(245, 158, 11, 0.35); color: #fef08a; background: rgba(245, 158, 11, 0.08); }
.chip-amber .chip-dot { background: var(--accent-gold); box-shadow: 0 0 6px var(--accent-gold); }

.chip-emerald { border-color: rgba(16, 185, 129, 0.35); color: #a7f3d0; background: rgba(16, 185, 129, 0.08); }
.chip-emerald .chip-dot { background: var(--accent-emerald); box-shadow: 0 0 6px var(--accent-emerald); }

.chip-amoled { border-color: rgba(255, 255, 255, 0.2); color: #e2e8f0; background: rgba(0, 0, 0, 0.4); }
.chip-amoled .chip-dot { background: #94a3b8; }

.chip-offline { border-color: rgba(56, 189, 248, 0.35); color: #bae6fd; background: rgba(56, 189, 248, 0.08); }
.chip-offline .chip-dot { background: var(--accent-cyan); box-shadow: 0 0 6px var(--accent-cyan); }

.hero-title {
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1.15;
  margin-bottom: 1.25rem;
  color: #ffffff;
}

.text-gradient-amber {
  background: linear-gradient(135deg, #fcd34d 0%, #f59e0b 50%, #d97706 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin: 0 auto 2.25rem;
  max-width: 680px;
}

.hero-cta-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.65rem;
  font-size: 0.95rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition-fast);
  border: none;
}

.btn-primary {
  background: var(--primary-gradient);
  color: #07090d;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(245, 158, 11, 0.5);
}

.play-store-svg {
  width: 18px;
  height: 18px;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* ==========================================================================
   Simulator Section & Chess Clock Card
   ========================================================================== */
.simulator-section {
  position: relative;
  z-index: 1;
  padding: 2.5rem 0 4rem;
}

.section-header {
  margin-bottom: 2.5rem;
}

.text-center { text-align: center; }

.section-tag-chip {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.85rem;
  border-radius: var(--radius-pill);
  background: rgba(245, 158, 11, 0.12);
  color: var(--accent-gold);
  border: 1px solid rgba(245, 158, 11, 0.25);
  margin-bottom: 0.85rem;
}

.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 0.75rem;
  color: #ffffff;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* Clock Simulator Card Container */
.clock-simulator-card {
  max-width: 640px;
  margin: 0 auto;
  background: rgba(16, 20, 29, 0.85);
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6), 0 0 35px rgba(245, 158, 11, 0.12);
  overflow: hidden;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}

/* Simulator Toolbar */
.sim-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.25rem;
  background: rgba(10, 13, 19, 0.95);
  border-bottom: 1px solid var(--border-color);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.sim-presets {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.sim-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-dim);
  margin-right: 0.2rem;
}

.preset-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition-fast);
}

.preset-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-main);
}

.preset-btn.active {
  background: rgba(245, 158, 11, 0.15);
  border-color: var(--accent-amber);
  color: var(--accent-gold);
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.2);
}

.sim-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.tool-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: var(--transition-fast);
}

.tool-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.2);
}

.tool-btn.btn-reset:hover {
  color: var(--accent-gold);
  border-color: rgba(245, 158, 11, 0.4);
}

/* Dual Clock Board */
.dual-clock-frame {
  position: relative;
  display: flex;
  flex-direction: column;
  background: #000000;
  user-select: none;
}

/* Player Panels */
.player-panel {
  position: relative;
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: #090c12;
  transition: background 0.25s ease, border-color 0.25s ease, transform 0.2s ease;
  overflow: hidden;
  border: 2px solid transparent;
}

.player-panel:active {
  transform: scale(0.992);
}

.player-panel.active-turn {
  background: #111722;
  border-color: rgba(245, 158, 11, 0.45);
  box-shadow: inset 0 0 25px rgba(245, 158, 11, 0.12);
}

.player-panel.active-turn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(245, 158, 11, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.player-panel.low-time {
  border-color: rgba(239, 68, 68, 0.7) !important;
  box-shadow: inset 0 0 30px rgba(239, 68, 68, 0.25) !important;
}

.player-panel.low-time .digital-time {
  color: #ef4444 !important;
  animation: pulseLowTime 0.9s infinite alternate;
}

@keyframes pulseLowTime {
  from { opacity: 0.85; transform: scale(1); }
  to { opacity: 1; transform: scale(1.03); }
}

.player-header {
  width: 100%;
  max-width: 380px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  z-index: 2;
}

.player-identity {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.player-avatar {
  font-size: 1.35rem;
}

.player-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-muted);
}

.player-panel.active-turn .player-name {
  color: var(--text-main);
}

.player-stats {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.stat-badge {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-dim);
}

.player-panel.active-turn .stat-badge {
  background: rgba(245, 158, 11, 0.12);
  color: var(--accent-gold);
}

.clock-display-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 190px;
  height: 190px;
  z-index: 2;
}

.progress-ring-container {
  position: absolute;
  inset: 0;
  transform: rotate(-90deg);
}

.progress-ring {
  width: 100%;
  height: 100%;
}

.ring-bg {
  fill: none;
  stroke: rgba(255, 255, 255, 0.05);
  stroke-width: 6;
}

.ring-indicator {
  fill: none;
  stroke: var(--accent-gold);
  stroke-width: 6;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.3s ease;
}

.player-panel:not(.active-turn) .ring-indicator {
  stroke: rgba(255, 255, 255, 0.15);
}

.digital-time {
  font-family: var(--font-mono);
  font-size: 3.4rem;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.03em;
  z-index: 3;
}

.player-panel:not(.active-turn) .digital-time {
  color: var(--text-dim);
}

.tap-hint {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-dim);
  margin-top: 0.75rem;
  z-index: 2;
  transition: var(--transition-fast);
}

.player-panel.active-turn .tap-hint {
  color: var(--accent-gold);
}

/* Face-to-Face Mode (Rotates Player 1 180 degrees) */
.player-1.face-to-face {
  transform: rotate(180deg);
}

/* Clock Divider Bar */
.clock-divider {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 1.5rem;
  background: #0e121a;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 5;
}

.match-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-gold);
  box-shadow: 0 0 8px var(--accent-gold);
}

.btn-divider-pause {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.btn-divider-pause:hover {
  background: rgba(245, 158, 11, 0.2);
  border-color: var(--accent-amber);
  color: var(--accent-gold);
}

/* Simulation Toast */
.sim-toast {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  background: rgba(15, 20, 30, 0.95);
  border: 1px solid var(--accent-gold);
  color: #ffffff;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-pill);
  font-size: 0.88rem;
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 0 20px rgba(245, 158, 11, 0.4);
  pointer-events: none;
  opacity: 0;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 20;
}

.sim-toast.show {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.sim-footer-note {
  padding: 0.85rem 1.25rem;
  background: rgba(10, 13, 19, 0.9);
  border-top: 1px solid var(--border-color);
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
}

/* ==========================================================================
   Feature Suite Section
   ========================================================================== */
.features-section {
  position: relative;
  z-index: 1;
  padding: 5rem 0;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 1.5rem;
}

.feature-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.2rem 1.8rem;
  transition: var(--transition-smooth);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(245, 158, 11, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4), 0 0 24px rgba(245, 158, 11, 0.08);
}

.feature-card-glow {
  position: absolute;
  top: -60px;
  right: -60px;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  filter: blur(50px);
  opacity: 0.2;
  pointer-events: none;
}

.glow-amber { background: var(--accent-amber); }
.glow-gold { background: var(--accent-gold); }
.glow-emerald { background: var(--accent-emerald); }
.glow-purple { background: var(--accent-purple); }
.glow-cyan { background: var(--accent-cyan); }
.glow-blue { background: #3b82f6; }

.feature-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.feature-icon-box {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  border: 1px solid var(--border-color);
}

.icon-amber { background: rgba(245, 158, 11, 0.12); border-color: rgba(245, 158, 11, 0.3); }
.icon-gold { background: rgba(251, 191, 36, 0.12); border-color: rgba(251, 191, 36, 0.3); }
.icon-emerald { background: rgba(16, 185, 129, 0.12); border-color: rgba(16, 185, 129, 0.3); }
.icon-purple { background: rgba(168, 85, 247, 0.12); border-color: rgba(168, 85, 247, 0.3); }
.icon-cyan { background: rgba(56, 189, 248, 0.12); border-color: rgba(56, 189, 248, 0.3); }
.icon-blue { background: rgba(59, 130, 246, 0.12); border-color: rgba(59, 130, 246, 0.3); }

.feature-tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-pill);
}

.tag-amber { background: rgba(245, 158, 11, 0.15); color: #fde047; border: 1px solid rgba(245, 158, 11, 0.3); }
.tag-gold { background: rgba(251, 191, 36, 0.15); color: #fef08a; border: 1px solid rgba(251, 191, 36, 0.3); }
.tag-emerald { background: rgba(16, 185, 129, 0.15); color: #6ee7b7; border: 1px solid rgba(16, 185, 129, 0.3); }
.tag-purple { background: rgba(168, 85, 247, 0.15); color: #d8b4fe; border: 1px solid rgba(168, 85, 247, 0.3); }
.tag-cyan { background: rgba(56, 189, 248, 0.15); color: #7dd3fc; border: 1px solid rgba(56, 189, 248, 0.3); }
.tag-blue { background: rgba(59, 130, 246, 0.15); color: #93c5fd; border: 1px solid rgba(59, 130, 246, 0.3); }

.feature-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.65rem;
  letter-spacing: -0.015em;
}

.feature-text {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ==========================================================================
   Screenshot Gallery Section
   ========================================================================== */
.screenshots-section {
  position: relative;
  z-index: 1;
  padding: 4rem 0;
}

.gallery-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  margin: 0 -1rem;
  padding: 1rem 0;
}

.gallery-track {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 1rem;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.gallery-track::-webkit-scrollbar {
  display: none;
}

.gallery-card {
  flex: 0 0 260px;
  scroll-snap-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  transition: var(--transition-fast);
}

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

.gallery-frame {
  width: 100%;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #0f131c;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
  transition: var(--transition-fast);
}

.gallery-card:hover .gallery-frame {
  border-color: rgba(245, 158, 11, 0.4);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.2);
}

.gallery-frame img {
  width: 100%;
  height: auto;
  display: block;
}

.gallery-caption {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
}

.gallery-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(20, 26, 38, 0.9);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  backdrop-filter: blur(12px);
  transition: var(--transition-fast);
}

.gallery-nav-btn:hover {
  background: #2a3449;
  border-color: var(--accent-gold);
  color: var(--accent-gold);
}

.prev-btn { left: 0.5rem; }
.next-btn { right: 0.5rem; }

.gallery-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.gallery-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transition: var(--transition-fast);
  cursor: pointer;
}

.gallery-dot.active {
  width: 24px;
  border-radius: var(--radius-pill);
  background: var(--accent-gold);
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
}

/* ==========================================================================
   Searchable User Guide / FAQ Section
   ========================================================================== */
.userguide-section {
  position: relative;
  z-index: 1;
  padding: 5rem 0;
}

.faq-search-wrap {
  position: relative;
  max-width: 680px;
  margin: 0 auto 2.5rem;
}

.search-icon {
  position: absolute;
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  pointer-events: none;
}

.faq-search-input {
  width: 100%;
  background: rgba(21, 27, 39, 0.8);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  font-size: 0.95rem;
  font-family: inherit;
  padding: 1rem 1.25rem 1rem 3.25rem;
  border-radius: var(--radius-pill);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: var(--transition-fast);
}

.faq-search-input:focus {
  border-color: var(--accent-amber);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.2);
}

.faq-search-input::placeholder {
  color: var(--text-dim);
}

.faq-accordion {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition-fast);
}

.faq-item:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background: var(--bg-card-hover);
}

.faq-item.active {
  border-color: rgba(245, 158, 11, 0.35);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: transparent;
  border: none;
  color: var(--text-main);
  font-size: 1rem;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  gap: 1rem;
}

.faq-chevron {
  color: var(--text-dim);
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-item.active .faq-chevron {
  transform: rotate(180deg);
  color: var(--accent-gold);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1), padding 0.35s ease;
  padding: 0 1.5rem;
}

.faq-item.active .faq-answer {
  padding: 0 1.5rem 1.4rem;
}

.faq-answer p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* ==========================================================================
   Bottom CTA Banner
   ========================================================================== */
.cta-banner-section {
  position: relative;
  z-index: 1;
  padding: 2rem 0 5rem;
}

.cta-banner-card {
  position: relative;
  background: linear-gradient(135deg, #131924 0%, #171d2b 100%);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-lg);
  padding: 3.5rem 3rem;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  align-items: center;
  gap: 2.5rem;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(245, 158, 11, 0.1);
}

.cta-banner-glow {
  position: absolute;
  top: -80px;
  left: -80px;
  width: 250px;
  height: 250px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.25) 0%, transparent 70%);
  filter: blur(60px);
  pointer-events: none;
}

.cta-badge {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-gold);
  margin-bottom: 0.75rem;
}

.cta-title {
  font-size: clamp(1.8rem, 3vw, 2.3rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 0.85rem;
  color: #ffffff;
}

.cta-subtitle {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 1.75rem;
  line-height: 1.6;
}

.cta-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.cta-banner-media {
  display: flex;
  justify-content: center;
}

.cta-media-img {
  width: 100%;
  max-width: 440px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6);
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
  position: relative;
  z-index: 1;
  background: #090c12;
  border-top: 1px solid var(--border-color);
  padding: 4rem 0 3rem;
}

.footer-container {
  display: grid;
  grid-template-columns: 1.2fr 2fr;
  gap: 3rem;
}

.footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.footer-desc {
  font-size: 0.9rem;
  color: var(--text-dim);
  max-width: 320px;
  line-height: 1.55;
}

.copyright {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 0.5rem;
}

.footer-links-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-heading {
  font-size: 0.85rem;
  font-weight: 700;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.4rem;
}

.footer-col a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  transition: var(--transition-fast);
}

.footer-col a:hover {
  color: var(--accent-gold);
}

.active-footer-link {
  color: var(--accent-gold) !important;
  font-weight: 600;
}

/* ==========================================================================
   Responsive Adaptations
   ========================================================================== */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .cta-banner-card {
    grid-template-columns: 1fr;
    padding: 2.5rem 1.8rem;
    text-align: center;
  }
  .cta-actions { justify-content: center; }
  .footer-container { grid-template-columns: 1fr; gap: 2.5rem; }
}

@media (max-width: 640px) {
  .hero-title { font-size: 2.2rem; }
  .hero-subtitle { font-size: 1rem; }
  .clock-display-wrap { width: 150px; height: 150px; }
  .digital-time { font-size: 2.6rem; }
  .footer-links-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .sim-toolbar { flex-direction: column; align-items: stretch; }
  .sim-presets, .sim-actions { justify-content: center; }
}

/* Responsive Top Navbar (Matches ExpenseMate) */
.back-link,
.brand,
.btn-topbar-cta {
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .navbar {
    padding: 10px 0;
  }

  .nav-container {
    padding: 0 16px;
    gap: 10px;
  }

  .nav-links {
    display: none;
  }

  .back-link-text {
    display: none;
  }

  .back-link {
    padding: 7px 10px;
  }
}

@media (max-width: 420px) {
  .brand-version {
    display: none;
  }

  .nav-logo-box {
    width: 34px;
    height: 34px;
  }

  .brand-name {
    font-size: 1.05rem;
  }

  .btn-topbar-cta {
    padding: 7px 12px;
    font-size: 0.82rem;
  }

  .btn-topbar-cta .topbar-cta-icon {
    width: 14px;
    height: 14px;
  }
}
