/* ==========================================
   Just IPTV Player - Website Styles
   Dark Theme: bg #000, accent #E50914
   ========================================== */

:root {
  --bg: #000;
  --bg-card: #141414;
  --bg-input: #1a1a1a;
  --accent: #E50914;
  --accent-hover: #f6121d;
  --text: #fff;
  --text-secondary: #999;
  --text-muted: #666;
  --border: #333;
  --radius: 8px;
  --max-width: 960px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.6;
  min-height: 100vh;
}

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

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
}

/* Layout */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ==========================================
   Keyframe Animations
   ========================================== */

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 30px rgba(229, 9, 20, 0.3), 0 0 60px rgba(229, 9, 20, 0.1); }
  50% { box-shadow: 0 0 50px rgba(229, 9, 20, 0.5), 0 0 100px rgba(229, 9, 20, 0.2); }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes glowPulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.8; }
}

/* ==========================================
   Navbar
   ========================================== */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 20px 0;
  border-bottom: 1px solid transparent;
  transition: all 0.3s ease;
}

.navbar-scrolled {
  padding: 14px 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

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

.navbar-brand {
  font-size: 24px;
  font-weight: 900;
  color: var(--accent);
  letter-spacing: -0.5px;
}

.navbar-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.navbar-links a {
  color: var(--text-secondary);
  font-size: 14px;
  transition: color 0.2s;
}

.navbar-links a:hover {
  color: var(--text);
  text-decoration: none;
}

/* ==========================================
   Dot Pattern Background
   ========================================== */

.dot-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 24px 24px;
  pointer-events: none;
}

/* ==========================================
   Hero Section
   ========================================== */

.hero {
  text-align: center;
  padding: 160px 0 100px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(ellipse at 50% 60%, rgba(229, 9, 20, 0.06) 0%, transparent 60%);
  animation: gradientShift 8s ease infinite;
  background-size: 200% 200%;
  pointer-events: none;
}

.hero-icon {
  width: 140px;
  height: 140px;
  margin: 0 auto 40px;
  border-radius: 32px;
  animation: float 4s ease-in-out infinite, pulse 3s ease-in-out infinite;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1a0a0e, #0f0010, #0a0014);
  border: 1px solid rgba(229, 9, 20, 0.2);
}

.hero-icon svg {
  width: 80px;
  height: 80px;
}

.hero h1 {
  font-size: 56px;
  font-weight: 900;
  margin-bottom: 16px;
  letter-spacing: -1.5px;
  animation: fadeInUp 0.8s ease both;
}

.hero h1 .gradient-text {
  background: linear-gradient(90deg, #E50914, #ff4d5a, #E50914);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 4s linear infinite;
}

.hero .hero-subtitle {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 520px;
  margin: 0 auto 44px;
  animation: fadeInUp 0.8s ease 0.15s both;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease 0.3s both;
}

/* ==========================================
   Buttons
   ========================================== */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-size: 16px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  position: relative;
}

.btn:hover {
  text-decoration: none;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 0 30px rgba(229, 9, 20, 0.4);
  transform: translateY(-2px);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--text-secondary);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.05);
  transform: translateY(-2px);
}

/* ==========================================
   Section Titles
   ========================================== */

.section-title {
  text-align: center;
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}

.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  font-size: 16px;
  max-width: 480px;
  margin: 0 auto 56px;
}

/* ==========================================
   Features Section
   ========================================== */

.features {
  padding: 100px 0;
}

.features h2 {
  text-align: center;
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 16px;
}

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

.feature-card {
  background: rgba(20, 20, 20, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  padding: 36px 24px;
  text-align: center;
  transition: all 0.4s ease;
}

.feature-card:hover {
  transform: translateY(-6px) scale(1.02);
  border-color: rgba(229, 9, 20, 0.3);
  box-shadow: 0 12px 40px rgba(229, 9, 20, 0.1);
}

.feature-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 20px;
  border-radius: 14px;
  background: rgba(229, 9, 20, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-icon svg {
  width: 28px;
  height: 28px;
  color: var(--accent);
}

.feature-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}

/* ==========================================
   Stats Section
   ========================================== */

.stats {
  padding: 80px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}

.stat-item {
  padding: 24px 16px;
}

.stat-number {
  font-size: 44px;
  font-weight: 900;
  color: var(--accent);
  letter-spacing: -1px;
  margin-bottom: 4px;
  font-variant-numeric: tabular-nums;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
}

/* ==========================================
   How It Works Section
   ========================================== */

.how-it-works {
  padding: 100px 0;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  max-width: 800px;
  margin: 0 auto;
}

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

.step-number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(229, 9, 20, 0.1);
  border: 2px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 800;
  color: var(--accent);
  margin: 0 auto 20px;
}

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

.step-item p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}

/* Connector lines between steps */
.step-item:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 24px;
  left: calc(50% + 36px);
  width: calc(100% - 72px + 40px);
  height: 2px;
  background: linear-gradient(90deg, var(--accent), rgba(229, 9, 20, 0.2));
}

/* ==========================================
   CTA Section
   ========================================== */

.cta {
  padding: 100px 0;
  text-align: center;
  position: relative;
}

.cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(229, 9, 20, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.cta h2 {
  font-size: 40px;
  font-weight: 900;
  margin-bottom: 16px;
  letter-spacing: -1px;
}

.cta p {
  color: var(--text-secondary);
  font-size: 18px;
  margin-bottom: 40px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

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

/* ==========================================
   Footer
   ========================================== */

.footer {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 40px 0;
  text-align: center;
}

.footer-links {
  display: flex;
  gap: 24px;
  justify-content: center;
  list-style: none;
  margin-bottom: 16px;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 14px;
}

.footer-copy {
  color: var(--text-muted);
  font-size: 13px;
}

/* ==========================================
   Scroll Reveal
   ========================================== */

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* Staggered delays for children */
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ==========================================
   Page Content (Privacy, Terms) - PRESERVED
   ========================================== */

.page-content {
  padding: 100px 0 80px;
}

.page-content h1 {
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 8px;
}

.page-content .last-updated {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 40px;
}

.page-content h2 {
  font-size: 22px;
  font-weight: 700;
  margin-top: 36px;
  margin-bottom: 12px;
}

.page-content p,
.page-content ul {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 16px;
}

.page-content ul {
  padding-left: 24px;
}

.page-content li {
  margin-bottom: 8px;
}

/* ==========================================
   Activation Page - PRESERVED
   ========================================== */

.activation {
  padding: 120px 0 80px;
  text-align: center;
}

.activation h1 {
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 8px;
}

.activation .subtitle {
  color: var(--text-secondary);
  font-size: 16px;
  margin-bottom: 40px;
}

.activation-form {
  max-width: 460px;
  margin: 0 auto;
  text-align: left;
}

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

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

.form-group input {
  width: 100%;
  padding: 14px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus {
  border-color: var(--accent);
}

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

.activation-form .btn {
  width: 100%;
  justify-content: center;
  margin-top: 8px;
}

/* Code Display */
.code-result {
  display: none;
  max-width: 460px;
  margin: 40px auto 0;
  background: var(--bg-card);
  border: 1px solid #222;
  border-radius: 12px;
  padding: 40px 32px;
  text-align: center;
}

.code-result.visible {
  display: block;
}

.code-result .label {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 16px;
}

.code-result .code {
  font-size: 56px;
  font-weight: 900;
  letter-spacing: 12px;
  color: var(--accent);
  margin-bottom: 16px;
  font-variant-numeric: tabular-nums;
}

.code-result .copy-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  padding: 8px 20px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 13px;
  transition: all 0.2s;
}

.code-result .copy-btn:hover {
  border-color: var(--text-secondary);
  color: var(--text);
}

.code-result .expire-note {
  color: var(--text-muted);
  font-size: 13px;
  margin-top: 16px;
}

.code-result .instruction {
  color: var(--text-secondary);
  font-size: 14px;
  margin-top: 12px;
}

/* Error */
.error-msg {
  color: var(--accent);
  font-size: 14px;
  margin-top: 12px;
  display: none;
}

.error-msg.visible {
  display: block;
}

/* Steps (Activation page) */
.steps {
  max-width: 460px;
  margin: 48px auto 0;
  text-align: left;
}

.steps h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 16px;
}

.steps ol {
  color: var(--text-secondary);
  font-size: 14px;
  padding-left: 20px;
}

.steps li {
  margin-bottom: 10px;
}

/* ==========================================
   Responsive
   ========================================== */

@media (max-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .steps-grid {
    grid-template-columns: 1fr;
    gap: 32px;
    max-width: 300px;
  }

  .step-item:not(:last-child)::after {
    display: none;
  }
}

@media (max-width: 640px) {
  .hero {
    padding: 130px 0 70px;
  }

  .hero h1 {
    font-size: 36px;
  }

  .hero .hero-subtitle {
    font-size: 16px;
  }

  .hero-icon {
    width: 110px;
    height: 110px;
    border-radius: 26px;
  }

  .hero-icon svg {
    width: 60px;
    height: 60px;
  }

  .section-title,
  .features h2 {
    font-size: 28px;
  }

  .cta h2 {
    font-size: 30px;
  }

  .stat-number {
    font-size: 32px;
  }

  .navbar-links {
    gap: 16px;
  }

  .navbar-links a {
    font-size: 13px;
  }

  .code-result .code {
    font-size: 40px;
    letter-spacing: 8px;
  }

  .activation h1 {
    font-size: 28px;
  }
}
