/* ============================================
   WittyKeys — Promotional Website Styles
   Dark theme, mobile-first, minimal & fast
   ============================================ */

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

:root {
  --bg-primary: #1a1a2e;
  --bg-card: #16213e;
  --accent-purple: #6C63FF;
  --accent-cyan: #00D2FF;
  --text-primary: #FFFFFF;
  --text-muted: #B0B0C0;
  --gradient-purple: linear-gradient(135deg, #6C63FF, #8B5CF6);
  --gradient-cyan: linear-gradient(135deg, #00D2FF, #6C63FF);
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

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

a {
  color: var(--accent-cyan);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--accent-purple);
}

img {
  max-width: 100%;
  height: auto;
}

/* --- Container --- */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  background: rgba(26, 26, 46, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(108, 99, 255, 0.1);
  transition: background var(--transition);
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-logo span {
  background: var(--gradient-purple);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
}

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

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

.nav-cta {
  background: var(--gradient-purple);
  color: var(--text-primary) !important;
  padding: 8px 20px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.85rem;
}

.nav-cta:hover {
  opacity: 0.9;
  color: var(--text-primary) !important;
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  margin: 6px 0;
  border-radius: 2px;
  transition: var(--transition);
}

/* --- Hero Section --- */
.hero {
  padding: 140px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 50% 30%, rgba(108, 99, 255, 0.08) 0%, transparent 50%),
              radial-gradient(circle at 30% 70%, rgba(0, 210, 255, 0.05) 0%, transparent 40%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-block;
  background: rgba(108, 99, 255, 0.15);
  color: var(--accent-purple);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.5px;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

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

.hero p {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

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

/* --- Buttons --- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--gradient-purple);
  color: var(--text-primary);
  padding: 14px 28px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 4px 20px rgba(108, 99, 255, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(108, 99, 255, 0.4);
  color: var(--text-primary);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: var(--text-muted);
  padding: 14px 28px;
  border-radius: 10px;
  font-weight: 500;
  font-size: 1rem;
  border: 1px solid rgba(176, 176, 192, 0.2);
  cursor: pointer;
  transition: var(--transition);
}

.btn-secondary:hover {
  border-color: var(--accent-purple);
  color: var(--text-primary);
}

/* Play Store badge */
.play-store-badge {
  height: 52px;
  transition: transform var(--transition);
}

.play-store-badge:hover {
  transform: scale(1.05);
}

/* --- Section Shared --- */
section {
  padding: 80px 0;
}

.section-label {
  display: inline-block;
  color: var(--accent-purple);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 12px;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 16px;
  line-height: 1.2;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 600px;
  line-height: 1.7;
}

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

.text-center .section-subtitle {
  margin-left: auto;
  margin-right: auto;
}

/* --- Problem Section --- */
.problem {
  background: var(--bg-card);
  border-top: 1px solid rgba(108, 99, 255, 0.1);
  border-bottom: 1px solid rgba(108, 99, 255, 0.1);
}

.problem-content {
  max-width: 650px;
  margin: 0 auto;
  text-align: center;
}

.problem-content .emoji-row {
  font-size: 2.5rem;
  margin-bottom: 24px;
}

.problem-content p {
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1.8;
}

/* --- Features Section --- */
.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 48px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid rgba(108, 99, 255, 0.08);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(108, 99, 255, 0.25);
  box-shadow: 0 8px 32px rgba(108, 99, 255, 0.1);
}

.feature-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 20px;
}

.feature-icon.purple { background: rgba(108, 99, 255, 0.15); }
.feature-icon.cyan { background: rgba(0, 210, 255, 0.15); }
.feature-icon.green { background: rgba(16, 185, 129, 0.15); }
.feature-icon.orange { background: rgba(251, 146, 60, 0.15); }
.feature-icon.pink { background: rgba(236, 72, 153, 0.15); }
.feature-icon.blue { background: rgba(59, 130, 246, 0.15); }

.feature-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.feature-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.feature-card ul {
  list-style: none;
  margin-top: 12px;
}

.feature-card ul li {
  color: var(--text-muted);
  font-size: 0.9rem;
  padding: 4px 0;
  padding-left: 20px;
  position: relative;
  line-height: 1.6;
}

.feature-card ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 11px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-purple);
}

/* --- How It Works --- */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 48px;
  position: relative;
}

.step {
  text-align: center;
  position: relative;
}

.step-number {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--gradient-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 800;
  margin: 0 auto 16px;
  box-shadow: 0 4px 16px rgba(108, 99, 255, 0.3);
}

.step h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
}

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

/* Step connector line */
.step-connector {
  display: none;
}

/* --- Stats Section --- */
.stats {
  background: var(--bg-card);
  border-top: 1px solid rgba(108, 99, 255, 0.1);
  border-bottom: 1px solid rgba(108, 99, 255, 0.1);
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 40px;
}

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

.stat-number {
  font-size: 2.2rem;
  font-weight: 800;
  background: var(--gradient-cyan);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* --- CTA Section --- */
.cta-section {
  text-align: center;
  position: relative;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(108, 99, 255, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.cta-section .section-title {
  font-size: 2.2rem;
  margin-bottom: 12px;
}

.cta-section .section-subtitle {
  margin-bottom: 32px;
}

.cta-note {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 20px;
}

/* --- Footer --- */
.footer {
  padding: 40px 0 32px;
  border-top: 1px solid rgba(108, 99, 255, 0.1);
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

.footer-logo {
  font-size: 1.2rem;
  font-weight: 700;
}

.footer-logo span {
  background: var(--gradient-purple);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.footer-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
}

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

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

.footer-bottom {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-top: 8px;
}

/* --- Fade-in Animation --- */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Legal Pages (Privacy / Terms) --- */
.legal-page {
  padding: 120px 0 60px;
}

.legal-page h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.legal-page .legal-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 40px;
}

.legal-page h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-top: 40px;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.legal-page h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-top: 24px;
  margin-bottom: 8px;
  color: var(--accent-cyan);
}

.legal-page p {
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 12px;
}

.legal-page ul {
  list-style: none;
  margin: 12px 0;
}

.legal-page ul li {
  color: var(--text-muted);
  padding: 4px 0 4px 20px;
  position: relative;
  line-height: 1.7;
}

.legal-page ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-purple);
}

.legal-page table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
}

.legal-page th,
.legal-page td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid rgba(108, 99, 255, 0.1);
  font-size: 0.9rem;
}

.legal-page th {
  color: var(--text-primary);
  font-weight: 600;
  background: var(--bg-card);
}

.legal-page td {
  color: var(--text-muted);
}

.legal-page a {
  word-break: break-all;
}

/* --- 404 Page --- */
.page-404 {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  text-align: center;
}

.page-404 h1 {
  font-size: 6rem;
  font-weight: 800;
  background: var(--gradient-purple);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 12px;
}

.page-404 p {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 24px;
}

/* --- Responsive: Tablet (768px+) --- */
@media (min-width: 768px) {
  .hero h1 {
    font-size: 3.2rem;
  }

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

  .steps {
    grid-template-columns: repeat(3, 1fr);
  }

  .step-connector {
    display: block;
    position: absolute;
    top: 26px;
    width: calc(100% - 52px);
    left: calc(50% + 26px);
    height: 2px;
    background: linear-gradient(90deg, var(--accent-purple), var(--accent-cyan));
    opacity: 0.3;
  }

  .step:last-child .step-connector {
    display: none;
  }

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

  .legal-page h1 {
    font-size: 2.4rem;
  }
}

/* --- Responsive: Desktop (1024px+) --- */
@media (min-width: 1024px) {
  .hero {
    padding: 160px 0 100px;
  }

  .hero h1 {
    font-size: 3.6rem;
  }

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

  section {
    padding: 100px 0;
  }

  .nav-toggle {
    display: none !important;
  }
}

/* --- Mobile Nav --- */
@media (max-width: 767px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 260px;
    height: 100vh;
    background: var(--bg-card);
    flex-direction: column;
    padding: 80px 32px 32px;
    gap: 24px;
    transition: right var(--transition);
    border-left: 1px solid rgba(108, 99, 255, 0.1);
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.3);
  }

  .nav-links.active {
    right: 0;
  }

  .nav-links a {
    font-size: 1rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 1rem;
  }

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

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

  .legal-page table {
    display: block;
    overflow-x: auto;
  }
}
