/* ============================================
   Decode Website - Styles
   ============================================ */

:root {
  --color-primary: #6366f1;
  --color-primary-dark: #4f46e5;
  --color-secondary: #818cf8;
  --color-accent: #a78bfa;
  --color-text: #1f2937;
  --color-text-light: #6b7280;
  --color-text-lighter: #9ca3af;
  --color-bg: #ffffff;
  --color-bg-subtle: #f8f9fa;
  --color-bg-alt: #f3f4f6;
  --color-border: #e5e7eb;
  --gradient-brand: linear-gradient(135deg, #60a5fa, #818cf8, #a78bfa, #c084fc, #e879f9, #fb7185);
  --gradient-hero: linear-gradient(135deg, #0f172a 0%, #1e3a5f 25%, #2d5a87 50%, #1e3a5f 75%, #0f172a 100%);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
}

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

html {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.6;
  min-height: 100vh;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--color-primary-dark);
}

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

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navigation */
.nav {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
  z-index: 100;
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 1px;
}

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

.logo-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--color-text-light);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

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

/* Hero Section */
.hero {
  position: relative;
  padding: 6rem 0 8rem;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: var(--gradient-hero);
  z-index: -1;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 50%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
              radial-gradient(circle at 70% 80%, rgba(168, 85, 247, 0.1) 0%, transparent 40%);
}

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

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

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

.hero-subtitle {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.7;
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-badges {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Badges */
.badge {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 100px;
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
}

.badge-large {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
}

/* Sections */
.section {
  padding: 5rem 0;
}

.section-alt {
  background: var(--color-bg-subtle);
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--color-text-light);
  text-align: center;
  max-width: 600px;
  margin: 0 auto 3rem;
}

/* Problem Card */
.problem-card {
  background: #fff;
  border-radius: var(--radius-xl);
  padding: 3rem;
  text-align: center;
  box-shadow: var(--shadow-lg);
  max-width: 700px;
  margin: 0 auto;
}

.problem-icon {
  font-size: 3rem;
  margin-bottom: 1.5rem;
}

.problem-card h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 2rem;
  color: var(--color-text);
}

.problem-examples {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-bottom: 2rem;
}

.example {
  background: var(--color-bg-alt);
  padding: 0.75rem 1.25rem;
  border-radius: 100px;
  font-size: 0.95rem;
  color: var(--color-text-light);
  font-style: italic;
}

.problem-answer {
  font-size: 1.1rem;
  color: var(--color-text);
  line-height: 1.7;
}

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

.feature-card {
  background: #fff;
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.feature-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.feature-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.feature-card p {
  color: var(--color-text-light);
  line-height: 1.6;
}

/* Modes Grid */
.modes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.mode-card {
  background: #fff;
  padding: 1.75rem;
  border-radius: var(--radius-md);
  border-left: 4px solid var(--mode-color);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s ease;
}

.mode-card:hover {
  box-shadow: var(--shadow-md);
}

.mode-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--mode-color);
  margin-bottom: 1rem;
}

.mode-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--color-text);
}

.mode-card p {
  font-size: 0.95rem;
  color: var(--color-text-light);
  line-height: 1.5;
}

/* Story Section */
.story-content {
  max-width: 800px;
  margin: 0 auto;
}

.story-block {
  margin-bottom: 3rem;
}

.story-lead {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 1.5rem;
}

.story-block p {
  margin-bottom: 1.25rem;
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--color-text);
}

.story-block blockquote {
  font-size: 1.25rem;
  font-style: italic;
  color: var(--color-primary);
  border-left: 4px solid var(--color-primary);
  padding-left: 1.5rem;
  margin: 2rem 0;
}

.philosophy {
  background: #fff;
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.philosophy h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--color-text);
}

.philosophy-points {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.philosophy-point {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.philosophy-point strong {
  color: var(--color-text);
  font-weight: 600;
}

.philosophy-point span {
  color: var(--color-text-light);
}

/* CTA Section */
.cta-section {
  background: var(--gradient-hero);
  padding: 6rem 0;
}

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

.cta-content h2 {
  font-size: 2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 1rem;
}

.cta-content p {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 2rem;
}

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

/* Footer */
.footer {
  background: var(--color-bg-subtle);
  border-top: 1px solid var(--color-border);
  padding: 3rem 0;
}

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

.footer-brand {
  margin-bottom: 1.5rem;
}

.footer-logo {
  font-size: 1.25rem;
  font-weight: 800;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.footer-tagline {
  color: var(--color-text-light);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 1.5rem;
}

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

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

.footer-note {
  font-size: 0.875rem;
  color: var(--color-text-light);
  font-style: italic;
  max-width: 500px;
  margin: 0 auto 1rem;
}

.footer-copyright {
  color: var(--color-text-lighter);
  font-size: 0.75rem;
}

/* Legal Pages */
.legal-hero {
  background: var(--gradient-hero);
  padding: 4rem 0;
  text-align: center;
}

.legal-hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.5rem;
}

.legal-hero p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

.legal-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.legal-content h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: var(--color-text);
}

.legal-content h2:first-of-type {
  margin-top: 0;
}

.legal-content p {
  margin-bottom: 1rem;
  line-height: 1.7;
  color: var(--color-text);
}

.legal-content ul, .legal-content ol {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}

.legal-content li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
  color: var(--color-text);
}

.legal-content a {
  color: var(--color-primary);
}

/* Support Page */
.support-hero {
  background: var(--gradient-hero);
  padding: 4rem 0;
  text-align: center;
}

.support-hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.5rem;
}

.support-hero p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.1rem;
}

.support-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.support-card {
  background: #fff;
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  margin-bottom: 2rem;
}

.support-card h2 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--color-text);
}

.support-card p {
  color: var(--color-text-light);
  margin-bottom: 1rem;
  line-height: 1.6;
}

.support-email {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: var(--color-primary);
  color: #fff !important;
  border-radius: var(--radius-md);
  font-weight: 500;
  transition: background 0.2s ease;
}

.support-email:hover {
  background: var(--color-primary-dark);
  color: #fff !important;
}

.faq-item {
  margin-bottom: 1.5rem;
}

.faq-item h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--color-text);
}

.faq-item p {
  color: var(--color-text-light);
  line-height: 1.6;
}

/* Demo Section */
.demo-tabs {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.demo-tab {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  background: #fff;
  border: 2px solid var(--color-border);
  border-radius: 100px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text-light);
  cursor: pointer;
  transition: all 0.2s ease;
}

.demo-tab:hover {
  border-color: var(--color-primary);
  color: var(--color-text);
}

.demo-tab.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #fff;
}

.demo-tab-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.demo-tab.active .demo-tab-dot {
  background: #fff !important;
}

.demo-content {
  position: relative;
}

.demo-panel {
  display: none;
  gap: 3rem;
  align-items: flex-start;
}

.demo-panel.active {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.demo-info {
  padding: 1rem 0;
}

.demo-info h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--color-text);
}

.demo-description {
  font-size: 1.05rem;
  color: var(--color-text-light);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.demo-features {
  list-style: none;
  padding: 0;
}

.demo-features li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.75rem;
  color: var(--color-text);
  line-height: 1.5;
}

.demo-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-primary);
  font-weight: 600;
}

/* Carousel */
.demo-carousel {
  position: relative;
  background: var(--color-bg-alt);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform 0.4s ease;
}

.carousel-slide {
  flex: 0 0 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.carousel-slide img {
  max-height: 500px;
  width: auto;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 50%;
  font-size: 1.5rem;
  color: var(--color-text);
  cursor: pointer;
  box-shadow: var(--shadow-md);
  transition: all 0.2s ease;
  z-index: 10;
}

.carousel-btn:hover {
  background: #fff;
  transform: translateY(-50%) scale(1.05);
  box-shadow: var(--shadow-lg);
}

.carousel-prev {
  left: 0.75rem;
}

.carousel-next {
  right: 0.75rem;
}

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

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-border);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.carousel-dot:hover {
  background: var(--color-text-lighter);
}

.carousel-dot.active {
  background: var(--color-primary);
  transform: scale(1.2);
}

/* Placeholder slides */
.carousel-placeholder {
  background: transparent;
}

.placeholder-content {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--color-text-light);
}

.placeholder-icon {
  font-size: 3rem;
  display: block;
  margin-bottom: 1rem;
}

.placeholder-content p {
  font-size: 1rem;
  font-style: italic;
}

/* Responsive */
@media (max-width: 768px) {
  .nav-links {
    gap: 1.25rem;
  }

  .hero {
    padding: 4rem 0 5rem;
  }

  .hero-title {
    font-size: 2.25rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
  }

  .section {
    padding: 3.5rem 0;
  }

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

  .problem-card {
    padding: 2rem 1.5rem;
  }

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

  .modes-grid {
    grid-template-columns: 1fr;
  }

  .story-block p {
    font-size: 1rem;
  }

  .cta-content h2 {
    font-size: 1.5rem;
  }

  .footer-links {
    flex-direction: column;
    gap: 0.75rem;
  }

  .demo-panel.active {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .demo-info {
    order: 1;
  }

  .demo-carousel {
    order: 0;
  }

  .carousel-slide img {
    max-height: 400px;
  }

  .demo-tab {
    padding: 0.6rem 1rem;
    font-size: 0.8rem;
  }

  .carousel-btn {
    width: 36px;
    height: 36px;
    font-size: 1.25rem;
  }
}

@media (max-width: 480px) {
  .nav-container {
    flex-direction: column;
    gap: 1rem;
  }

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

  .example {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
  }

  .demo-tabs {
    gap: 0.4rem;
  }

  .demo-tab {
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
  }

  .demo-tab-dot {
    width: 8px;
    height: 8px;
  }

  .carousel-slide img {
    max-height: 350px;
  }
}
