/* ========================================
   SLEEP HABITS TRACKER - Main Stylesheet
   ======================================== */

/* Google Fonts loaded via <link> in HTML for reliability */

/* ---- CSS Variables ---- */
:root {
  --bg-primary:    #080614;
  --bg-secondary:  #0f0c24;
  --bg-card:       #16123a;
  --bg-card-hover: #1e1950;
  --purple-deep:   #3b0764;
  --purple-dark:   #4c1d95;
  --purple-mid:    #6d28d9;
  --purple:        #7c3aed;
  --purple-light:  #8b5cf6;
  --accent:        #a78bfa;
  --accent-light:  #c4b5fd;
  --gold:          #fbbf24;
  --teal:          #34d399;
  --text-primary:  #f5f3ff;
  --text-secondary:#c4b5fd;
  --text-muted:    #7c6baa;
  --border:        rgba(139,92,246,0.18);
  --border-hover:  rgba(167,139,250,0.4);
  --glow-sm:       0 0 20px rgba(139,92,246,0.25);
  --glow-md:       0 0 40px rgba(139,92,246,0.35);
  --glow-lg:       0 0 80px rgba(139,92,246,0.4);
  --shadow-card:   0 8px 32px rgba(0,0,0,0.4);
  --radius-sm:     8px;
  --radius-md:     16px;
  --radius-lg:     24px;
  --radius-xl:     32px;
  --transition:    0.3s cubic-bezier(0.4,0,0.2,1);
  --transition-slow: 0.6s cubic-bezier(0.4,0,0.2,1);
}

/* ---- Reset & Base ---- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Outfit', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

ul {
  list-style: none;
}

/* ---- Utility ---- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(139,92,246,0.12);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 6px 16px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

.gradient-text {
  background: linear-gradient(135deg, #fff 0%, var(--accent-light) 50%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gradient-text-gold {
  background: linear-gradient(135deg, #fbbf24, #f97316);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 100px;
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  outline: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--purple), var(--purple-mid));
  color: #fff;
  box-shadow: 0 4px 24px rgba(124,58,237,0.5);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(124,58,237,0.7);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border-hover);
  backdrop-filter: blur(10px);
}

.btn-outline:hover {
  background: rgba(139,92,246,0.1);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.btn-ghost {
  background: rgba(255,255,255,0.06);
  color: var(--text-primary);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(12px);
}

.btn-ghost:hover {
  background: rgba(139,92,246,0.15);
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

/* ---- Scroll Animations ---- */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-50px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(50px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-scale.visible {
  opacity: 1;
  transform: scale(1);
}

/* Staggered children */
.stagger > * {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.stagger.visible > *:nth-child(1) { transition-delay: 0s;    opacity: 1; transform: none; }
.stagger.visible > *:nth-child(2) { transition-delay: 0.1s;  opacity: 1; transform: none; }
.stagger.visible > *:nth-child(3) { transition-delay: 0.2s;  opacity: 1; transform: none; }
.stagger.visible > *:nth-child(4) { transition-delay: 0.3s;  opacity: 1; transform: none; }
.stagger.visible > *:nth-child(5) { transition-delay: 0.4s;  opacity: 1; transform: none; }
.stagger.visible > *:nth-child(6) { transition-delay: 0.5s;  opacity: 1; transform: none; }

/* ---- Keyframe Animations ---- */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-18px); }
}

@keyframes float-slow {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50%       { transform: translateY(-10px) rotate(2deg); }
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 20px rgba(139,92,246,0.3); }
  50%       { box-shadow: 0 0 60px rgba(139,92,246,0.6); }
}

@keyframes pulse-ring {
  0%   { transform: scale(0.95); opacity: 0.8; }
  50%  { transform: scale(1.05); opacity: 0.4; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

@keyframes shimmer {
  0%   { background-position: -200% center; }
  100% { background-position: 200% center; }
}

@keyframes rotate-slow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes slide-in-right {
  from { opacity: 0; transform: translateX(60px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes twinkle {
  0%, 100% { opacity: 0.2; transform: scale(0.8); }
  50%       { opacity: 1;   transform: scale(1.2); }
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50%       { background-position: 100% 50%; }
}

@keyframes border-glow {
  0%, 100% { border-color: rgba(139,92,246,0.2); }
  50%       { border-color: rgba(167,139,250,0.6); }
}

/* ========================================
   NAVIGATION
   ======================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0 24px;
  transition: var(--transition);
}

.navbar.scrolled {
  background: rgba(8,6,20,0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 4px 32px rgba(0,0,0,0.4);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.nav-logo-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--glow-sm);
  flex-shrink: 0;
}

.nav-logo-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.nav-logo-text {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
}

.nav-logo-text span {
  display: block;
  font-size: 0.7rem;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
  transition: width var(--transition);
}

.nav-links a:hover {
  color: var(--text-primary);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: none;
  border: none;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}

.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(8,6,20,0.97);
  backdrop-filter: blur(20px);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}

.mobile-menu.open {
  display: flex;
}

.mobile-menu a {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-primary);
  transition: var(--transition);
}

.mobile-menu a:hover {
  color: var(--accent);
}

/* ========================================
   HERO SECTION
   ======================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding-top: 72px;
}

#starfield {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
}

.hero-bg-glow {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(ellipse 60% 50% at 70% 50%, rgba(109,40,217,0.15) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 20% 30%, rgba(75,0,130,0.12) 0%, transparent 70%),
    radial-gradient(ellipse 30% 40% at 80% 80%, rgba(139,92,246,0.08) 0%, transparent 60%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  padding: 56px 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-content {
  animation: fade-in-up 0.8s ease forwards;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(139,92,246,0.1);
  border: 1px solid rgba(139,92,246,0.3);
  border-radius: 100px;
  padding: 8px 18px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent-light);
  letter-spacing: 0.05em;
  margin-bottom: 24px;
}

.hero-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
  animation: pulse-ring 2s ease infinite;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.8rem, 5vw, 4.2rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 36px;
  max-width: 480px;
}

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

/* hero store badges */
.store-badge-img {
  display: inline-block;
  line-height: 0;
  border-radius: 10px;
  transition: var(--transition);
}

.store-badge-img img {
  display: block;
  height: 52px;
  width: auto;
  border-radius: 10px;
}

.store-badge-img:hover {
  transform: translateY(-3px);
  filter: brightness(1.08);
  box-shadow: 0 10px 30px rgba(0,0,0,0.45);
}

.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #000;
  border: 1.5px solid rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: 10px 22px;
  cursor: pointer;
  transition: var(--transition);
  text-align: left;
  min-width: 176px;
}

.store-badge:hover {
  background: #111;
  border-color: rgba(255,255,255,0.35);
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.store-badge .badge-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.store-badge .badge-icon svg {
  width: 26px;
  height: 26px;
  display: block;
}

.store-badge .badge-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.store-badge .badge-text small {
  font-size: 0.62rem;
  color: rgba(255,255,255,0.65);
  font-weight: 400;
  letter-spacing: 0.02em;
}

.store-badge .badge-text strong {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.hero-stats {
  display: flex;
  gap: 32px;
}

.hero-stat {
  text-align: left;
}

.hero-stat .stat-num {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}

.hero-stat .stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: slide-in-right 0.9s ease 0.2s both;
}

.phone-wrapper {
  position: relative;
  z-index: 2;
  animation: float 5s ease-in-out infinite;
}

.phone-wrapper img {
  width: 280px;
  filter: drop-shadow(0 30px 60px rgba(109,40,217,0.5));
  border-radius: 28px;
}

.hero-glow-ring {
  position: absolute;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  border: 1px solid rgba(139,92,246,0.2);
  animation: pulse-ring 4s ease infinite;
  z-index: 1;
}

.hero-glow-ring:nth-child(2) {
  width: 420px;
  height: 420px;
  animation-delay: -1s;
  border-color: rgba(139,92,246,0.1);
}

.hero-glow-ring:nth-child(3) {
  width: 500px;
  height: 500px;
  animation-delay: -2s;
  border-color: rgba(139,92,246,0.06);
}

.hero-floating-cards {
  position: absolute;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.floating-card {
  position: absolute;
  background: rgba(30, 25, 80, 0.85);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  font-size: 0.8rem;
  white-space: nowrap;
  box-shadow: var(--shadow-card);
  animation: float-slow 6s ease-in-out infinite;
}

.floating-card:nth-child(1) {
  top: 10%;
  left: -10%;
  animation-delay: -1s;
}

.floating-card:nth-child(2) {
  bottom: 20%;
  right: -5%;
  animation-delay: -3s;
}

.floating-card .card-icon {
  font-size: 1rem;
  margin-bottom: 4px;
}

.floating-card .card-value {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.floating-card .card-label {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.75rem;
  z-index: 2;
  animation: fade-in-up 1s ease 1.2s both;
}

.scroll-mouse {
  width: 22px;
  height: 36px;
  border: 2px solid rgba(139,92,246,0.4);
  border-radius: 11px;
  position: relative;
}

.scroll-mouse::after {
  content: '';
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 3px;
  height: 6px;
  background: var(--accent);
  border-radius: 2px;
  animation: float 1.5s ease-in-out infinite;
}

/* ========================================
   STATS BAR
   ======================================== */
.stats-bar {
  background: linear-gradient(135deg, rgba(109,40,217,0.12), rgba(75,0,130,0.08));
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 24px 0;
}

.stats-bar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding: 12px;
  border-right: 1px solid var(--border);
}

.stat-item:last-child {
  border-right: none;
}

.stat-item .stat-value {
  font-size: 2rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}

.stat-item .stat-name {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ========================================
   SECTION HEADERS
   ======================================== */
.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ========================================
   FEATURES SECTION
   ======================================== */
.features {
  padding: 72px 0;
  position: relative;
}

.features::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: 100%;
  background: linear-gradient(to bottom, transparent, rgba(139,92,246,0.3), transparent);
}

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

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  cursor: default;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--purple), var(--accent), transparent);
  opacity: 0;
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-6px);
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  box-shadow: var(--glow-md), var(--shadow-card);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  position: relative;
  flex-shrink: 0;
}

.feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-icon.purple { background: rgba(124,58,237,0.15); border: 1px solid rgba(124,58,237,0.25); color: #a78bfa; }
.feature-icon.blue   { background: rgba(59,130,246,0.15);  border: 1px solid rgba(59,130,246,0.25);  color: #60a5fa; }
.feature-icon.teal   { background: rgba(52,211,153,0.15);  border: 1px solid rgba(52,211,153,0.25);  color: #34d399; }
.feature-icon.gold   { background: rgba(251,191,36,0.15);  border: 1px solid rgba(251,191,36,0.25);  color: #fbbf24; }
.feature-icon.pink   { background: rgba(236,72,153,0.15);  border: 1px solid rgba(236,72,153,0.25);  color: #f472b6; }
.feature-icon.indigo { background: rgba(99,102,241,0.15);  border: 1px solid rgba(99,102,241,0.25);  color: #818cf8; }

/* ---- Generic icon SVG ---- */
.icon-svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ---- Stat item icons ---- */
.analytics-card .analytics-icon-wrap {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  background: rgba(139,92,246,0.12);
  border: 1px solid rgba(139,92,246,0.2);
  color: var(--accent);
}

.analytics-card .analytics-icon-wrap svg {
  width: 22px;
  height: 22px;
}

/* ---- Official Store Download Badges ---- */
.store-dl-wrap {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.store-dl-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #000;
  border: 1.5px solid rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: 10px 22px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  min-width: 176px;
}

.store-dl-btn:hover {
  background: #111;
  border-color: rgba(255,255,255,0.35);
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.store-dl-btn .sd-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.store-dl-btn .sd-icon svg {
  width: 26px;
  height: 26px;
  display: block;
}

.store-dl-btn .sd-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.store-dl-btn .sd-text span {
  font-size: 0.62rem;
  color: rgba(255,255,255,0.65);
  font-weight: 400;
  letter-spacing: 0.02em;
  font-family: 'Outfit', sans-serif;
}

.store-dl-btn .sd-text strong {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.01em;
  font-family: 'Outfit', sans-serif;
  line-height: 1.2;
}

.feature-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.feature-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ========================================
   SCREENSHOTS SECTION
   ======================================== */
.screenshots {
  padding: 72px 0;
  background: linear-gradient(180deg, var(--bg-primary), var(--bg-secondary), var(--bg-primary));
  overflow: hidden;
}

.screenshots-scroll {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  padding: 24px 24px;
  scrollbar-width: none;
  -ms-overflow-style: none;
  cursor: grab;
}

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

.screenshots-scroll.grabbing {
  cursor: grabbing;
}

.screenshot-item {
  flex-shrink: 0;
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: var(--transition);
  background: var(--bg-card);
}

.screenshot-item:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: var(--border-hover);
  box-shadow: var(--glow-md);
}

.screenshot-item img {
  width: 220px;
  display: block;
}

.screenshot-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px;
  background: linear-gradient(to top, rgba(10,8,30,0.95), transparent);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* ========================================
   SHOWCASE SECTION (alternating)
   ======================================== */
.showcase {
  padding: 72px 0;
}

.showcase-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  margin-bottom: 72px;
}

.showcase-item:last-child {
  margin-bottom: 0;
}

.showcase-item.reverse {
  direction: rtl;
}

.showcase-item.reverse > * {
  direction: ltr;
}

.showcase-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.showcase-content .section-label {
  align-self: flex-start;
}

.showcase-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 700;
  line-height: 1.25;
}

.showcase-desc {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

.showcase-features-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.showcase-feature-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.showcase-feature-item .check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(52,211,153,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  color: var(--teal);
  flex-shrink: 0;
}

.showcase-visual {
  position: relative;
  display: flex;
  justify-content: center;
}

.showcase-visual .phone-img {
  width: 260px;
  filter: drop-shadow(0 20px 50px rgba(109,40,217,0.4));
  border-radius: 24px;
  transition: var(--transition);
}

.showcase-visual .phone-img:hover {
  transform: scale(1.03) rotate(-1deg);
}

.showcase-bg-circle {
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124,58,237,0.1) 0%, transparent 70%);
  z-index: -1;
}

/* ========================================
   CBT-I PILLARS SECTION
   ======================================== */
.cbt-section {
  padding: 72px 0;
  background: var(--bg-secondary);
  position: relative;
  overflow: hidden;
}

.cbt-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 60% at 10% 50%, rgba(75,0,130,0.1) 0%, transparent 70%),
    radial-gradient(ellipse 40% 50% at 90% 50%, rgba(109,40,217,0.08) 0%, transparent 70%);
}

.pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  position: relative;
  z-index: 1;
}

.pillar-card {
  background: rgba(22, 18, 58, 0.6);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

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

.pillar-number {
  font-family: 'Playfair Display', serif;
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 16px;
  background: linear-gradient(135deg, rgba(139,92,246,0.4), rgba(167,139,250,0.2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.pillar-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.pillar-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ========================================
   ANALYTICS / STATS COUNTER SECTION
   ======================================== */
.analytics-section {
  padding: 100px 0;
  position: relative;
}

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

.analytics-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px;
  text-align: center;
  transition: var(--transition);
  animation: border-glow 4s ease infinite;
}

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

.analytics-icon {
  font-size: 2rem;
  margin-bottom: 16px;
  display: block;
}

.analytics-number {
  font-family: 'Outfit', sans-serif;
  font-size: 2.8rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 8px;
  background: linear-gradient(135deg, #fff, var(--accent-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.analytics-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.analytics-sub {
  font-size: 0.78rem;
  color: var(--teal);
  margin-top: 4px;
}

/* ========================================
   DOWNLOAD / CTA SECTION
   ======================================== */
.cta-section {
  padding: 80px 0;
  position: relative;
  overflow: hidden;
}

.cta-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(76,29,149,0.2), rgba(109,40,217,0.15), rgba(75,0,130,0.2));
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.cta-bg::before {
  content: '';
  position: absolute;
  top: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124,58,237,0.12) 0%, transparent 70%);
}

.cta-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
  padding: 0 24px;
}

.cta-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.2rem, 4.5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 20px;
}

.cta-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 48px;
}

.cta-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.cta-buttons .store-badge-img img {
  height: 56px;
}

.cta-store-btn .store-info small {
  display: block;
  font-size: 0.62rem;
  color: rgba(255,255,255,0.65);
  letter-spacing: 0.02em;
}

.cta-store-btn .store-info strong {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.01em;
}

/* ========================================
   FOOTER
   ======================================== */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--border);
}

.footer-brand .logo-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.footer-brand .logo-wrap img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
}

.footer-brand .brand-name {
  font-size: 1rem;
  font-weight: 700;
}

.footer-brand p {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 24px;
  max-width: 280px;
}

.footer-col h4 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col ul li a {
  font-size: 0.9rem;
  color: var(--text-muted);
  transition: var(--transition);
}

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

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 28px;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-bottom p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-bottom-links {
  display: flex;
  gap: 24px;
}

.footer-bottom-links a {
  font-size: 0.85rem;
  color: var(--text-muted);
  transition: var(--transition);
}

.footer-bottom-links a:hover {
  color: var(--accent);
}

/* ========================================
   INNER PAGES (Privacy, Terms, etc.)
   ======================================== */
.page-hero {
  padding: 140px 0 80px;
  text-align: center;
  background: linear-gradient(180deg, rgba(76,29,149,0.12) 0%, transparent 100%);
  border-bottom: 1px solid var(--border);
  position: relative;
}

.page-hero h1 {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #ffffff 20%, var(--accent-light) 60%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.page-hero p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.page-content {
  padding: 80px 0;
  max-width: 800px;
  margin: 0 auto;
}

.page-content h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin: 40px 0 16px;
  color: var(--text-primary);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

.page-content h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 24px 0 10px;
  color: var(--accent-light);
}

.page-content p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 16px;
}

.page-content ul, .page-content ol {
  margin: 0 0 16px 24px;
}

.page-content ul { list-style: disc; }
.page-content ol { list-style: decimal; }

.page-content li {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 8px;
}

.page-content a {
  color: var(--accent);
  transition: var(--transition);
}

.page-content a:hover {
  color: var(--accent-light);
  text-decoration: underline;
}

.info-box {
  background: rgba(139,92,246,0.08);
  border: 1px solid rgba(139,92,246,0.25);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  margin: 24px 0;
}

.info-box p {
  margin-bottom: 0;
  font-size: 0.9rem;
}

/* ========================================
   CONTACT PAGE
   ======================================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 60px;
  align-items: start;
  padding: 80px 0;
  max-width: 1100px;
  margin: 0 auto;
}

.contact-info h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.contact-info p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 32px;
}

.contact-detail {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 24px;
}

.contact-detail .detail-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: rgba(139,92,246,0.12);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.contact-detail h4 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.contact-detail p {
  font-size: 0.9rem;
  color: var(--text-primary);
  margin-bottom: 0;
}

/* ========================================
   FORMS
   ======================================== */
.form-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: var(--shadow-card);
}

.form-card h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.form-card .form-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 13px 16px;
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  color: var(--text-primary);
  outline: none;
  transition: var(--transition);
  -webkit-appearance: none;
  appearance: none;
}

/* ---- Checkbox: restore native appearance + theme colour ---- */
.form-group input[type="checkbox"] {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  min-width: 20px;
  border: 2px solid rgba(139,92,246,0.5);
  border-radius: 5px;
  background: rgba(255,255,255,0.04);
  cursor: pointer;
  display: grid;
  place-content: center;
  transition: var(--transition);
  padding: 0;
}

.form-group input[type="checkbox"]:checked {
  background: var(--accent);
  border-color: var(--accent);
}

.form-group input[type="checkbox"]:checked::before {
  content: '';
  width: 11px;
  height: 8px;
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
  background: #fff;
  display: block;
}

.form-group input[type="checkbox"]:focus {
  box-shadow: 0 0 0 3px rgba(139,92,246,0.25);
  border-color: var(--accent);
}

/* ---- Select dropdown: dark background for options ---- */
.form-group select {
  cursor: pointer;
  color-scheme: dark;
  /* Custom dropdown arrow */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23a78bfa' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.form-group select option {
  background-color: #14112a;
  color: #e5e1ff;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  background: rgba(139,92,246,0.05);
  box-shadow: 0 0 0 3px rgba(139,92,246,0.15);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
  line-height: 1.6;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-submit {
  width: 100%;
  justify-content: center;
  padding: 16px;
  font-size: 1rem;
  margin-top: 8px;
}

.form-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 16px;
}

.form-success {
  display: none;
  text-align: center;
  padding: 40px 20px;
}

.form-success .success-icon {
  font-size: 3.5rem;
  margin-bottom: 16px;
}

.form-success h3 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.form-success p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ========================================
   DELETE ACCOUNT PAGE
   ======================================== */
.delete-warning {
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.25);
  border-left: 3px solid #ef4444;
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  margin-bottom: 28px;
}

.delete-warning p {
  font-size: 0.9rem;
  color: #fca5a5;
  margin-bottom: 0;
}

.delete-warning strong {
  color: #f87171;
}

.btn-danger {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  color: #fff;
  box-shadow: 0 4px 20px rgba(220,38,38,0.4);
}

.btn-danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(220,38,38,0.5);
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 1024px) {
  .features-grid,
  .pillars-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .showcase-item,
  .showcase-item.reverse {
    grid-template-columns: 1fr;
    direction: ltr;
    gap: 40px;
    text-align: center;
    margin-bottom: 80px;
  }

  .showcase-content .section-label,
  .showcase-features-list {
    align-self: center;
  }

  .showcase-visual {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .nav-links,
  .nav-cta {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .hero {
    min-height: 100svh;
    min-height: 100vh;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 32px;
    padding: 40px 20px 60px;
  }

  .hero-subtitle {
    max-width: 100%;
    font-size: 1rem;
  }

  .hero-actions {
    justify-content: center;
    gap: 10px;
  }

  .store-badge-img img {
    height: 48px;
  }

  .hero-stats {
    justify-content: center;
    gap: 20px;
  }

  .hero-visual {
    order: -1;
    min-height: 260px;
  }

  .phone-wrapper img {
    width: 200px;
  }

  .hero-glow-ring {
    width: 230px;
    height: 230px;
  }

  .hero-glow-ring:nth-child(2) { width: 290px; height: 290px; }
  .hero-glow-ring:nth-child(3) { width: 340px; height: 340px; }

  /* Hide floating cards on mobile — they overflow on small screens */
  .hero-floating-cards {
    display: none;
  }

  .floating-card:nth-child(1) {
    top: 5%;
    left: 0;
  }

  .floating-card:nth-child(2) {
    bottom: 5%;
    right: 0;
  }

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

  .stat-item:nth-child(2) {
    border-right: none;
  }

  .features-grid,
  .pillars-grid,
  .analytics-grid {
    grid-template-columns: 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .footer-top {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .cta-buttons {
    flex-direction: column;
    align-items: center;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .form-card {
    padding: 28px 20px;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: clamp(1.9rem, 8vw, 2.4rem);
  }

  .hero-badge {
    font-size: 0.72rem;
    padding: 6px 14px;
  }

  .hero-inner {
    padding: 32px 16px 48px;
    gap: 24px;
  }

  .hero-visual {
    min-height: 220px;
  }

  .phone-wrapper img {
    width: 160px;
  }

  .hero-glow-ring {
    width: 190px;
    height: 190px;
  }

  .hero-glow-ring:nth-child(2) { width: 240px; height: 240px; }
  .hero-glow-ring:nth-child(3) { width: 280px; height: 280px; }

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

  .store-badge-img {
    width: 100%;
    max-width: 210px;
    text-align: center;
  }

  .store-badge-img img {
    height: 44px;
    margin: 0 auto;
  }

  .hero-stats {
    gap: 16px;
  }

  .page-content {
    padding: 60px 24px;
  }

  .contact-grid {
    padding: 60px 24px;
  }
}

/* ---- Delete Account Grid ---- */
.da-layout {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 48px;
  align-items: start;
  padding: 80px 0;
}

@media (max-width: 768px) {
  .da-layout {
    grid-template-columns: 1fr;
    gap: 40px;
    padding: 60px 0;
  }
}

/* ---- Inner page navbar background ---- */
.navbar.page-nav {
  background: rgba(8,6,20,0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

/* ---- FAQ details styling ---- */
details > summary {
  cursor: pointer;
  user-select: none;
}

details[open] > summary > span {
  transform: rotate(45deg);
  display: inline-block;
}

details + details {
  margin-top: 0;
}

/* ========================================
   SCROLLBAR
   ======================================== */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: rgba(139,92,246,0.4);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}

/* ---- Delete account checkbox variant (red) ---- */
.form-group input[type="checkbox"].del-checkbox {
  border-color: rgba(239,68,68,0.5);
}
.form-group input[type="checkbox"].del-checkbox:checked {
  background: #ef4444;
  border-color: #ef4444;
}
.form-group input[type="checkbox"].del-checkbox:focus {
  box-shadow: 0 0 0 3px rgba(239,68,68,0.25);
  border-color: #ef4444;
}

/* ---- Button spinner animation ---- */
@keyframes spin {
  to { transform: rotate(360deg); }
}
.spin-anim {
  animation: spin 0.9s linear infinite;
  transform-origin: center;
}

/* ========================================
   SELECTION
   ======================================== */
::selection {
  background: rgba(139,92,246,0.3);
  color: var(--text-primary);
}
