/* ── CodeBoost Landing Page Styles ────────────────────────────────────────── */

:root {
  --bg-base:     #0a1810;
  --bg-card:     #112219;
  --bg-hover:    #1a3325;
  --accent:      #4CAF50;
  --accent-light:#81c784;
  --accent-glow: rgba(76, 175, 80, 0.25);
  --text-hi:     #e8f5e9;
  --text-mid:    #9dc4a6;
  --text-lo:     #4a7060;
  --pass:        #27ae60;
  --fail:        #e74c3c;
  --radius:      24px;
  --radius-sm:   12px;
  --font:        'Segoe UI', system-ui, -apple-system, sans-serif;
  --nav-height:  80px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
}

body {
  background-color: var(--bg-base);
  color: var(--text-hi);
  font-family: var(--font);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Sections avec Scroll Snap */
section {
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

/* Sélection de texte — contraste élevé, alignée sur l’accent vert */
::selection {
  background-color: #347c3e;
  color: #f8fff9;
  text-shadow: none;
}

::-moz-selection {
  background-color: #347c3e;
  color: #f8fff9;
  text-shadow: none;
}

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

/* ─── Background ────────────────────────────────────────────────────────── */

.stars {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: radial-gradient(ellipse at bottom, #1B2735 0%, #090A0F 100%);
  z-index: -2;
}

.glowing-orb {
  position: fixed;
  top: 20%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  z-index: -1;
  filter: blur(80px);
  animation: orb-float 20s infinite alternate ease-in-out;
}

@keyframes orb-float {
  from { transform: translate(-50%, -50%) scale(1); }
  to { transform: translate(-45%, -55%) scale(1.1); }
}

/* ─── Typography ────────────────────────────────────────────────────────── */

h1, h2, h3 {
  font-weight: 800;
  line-height: 1.2;
}

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

.text-pass { color: var(--pass); }
.text-accent { color: var(--accent); }

/* ─── Navbar ────────────────────────────────────────────────────────────── */

.navbar {
  height: var(--nav-height);
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
}

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

.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.nav-logo:hover {
  transform: scale(1.05) rotate(2deg);
}

.nav-logo:hover .nav-icon {
  animation: logo-wiggle 0.5s ease-in-out infinite;
}

@keyframes logo-wiggle {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-10deg); }
  75% { transform: rotate(10deg); }
}

.nav-icon {
  width: 40px;
  height: 40px;
}

.nav-brand {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

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

.nav-link {
  color: var(--text-mid);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-link:hover { color: var(--text-hi); }

.nav-btn {
  background: var(--accent);
  color: white;
  text-decoration: none;
  padding: 10px 24px;
  border-radius: 30px;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
}

.nav-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px var(--accent-glow);
}

/* ─── Hero ──────────────────────────────────────────────────────────────── */

.hero {
  height: 100vh;
  min-height: 700px;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  scroll-snap-align: start;
}

.hero-shapes {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
  z-index: -1;
  background: radial-gradient(circle at 50% 50%, rgba(76, 175, 80, 0.05) 0%, transparent 70%);
}

.shape {
  position: absolute;
  border-radius: 50%;
  background: var(--accent);
  filter: blur(100px);
  animation: float 25s infinite alternate ease-in-out;
  opacity: 0.12;
  will-change: transform;
}

.shape-1 { width: 600px; height: 600px; top: -200px; right: -150px; background: #2e7d32; }
.shape-2 { width: 500px; height: 500px; bottom: -100px; left: -150px; background: #1b5e20; animation-delay: -7s; }
.shape-3 { width: 400px; height: 400px; top: 30%; left: 20%; background: #4caf50; animation-delay: -12s; opacity: 0.08; }

@keyframes float {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  33% { transform: translate(100px, 50px) scale(1.1) rotate(5deg); }
  66% { transform: translate(-50px, 100px) scale(0.9) rotate(-5deg); }
  100% { transform: translate(0, 0) scale(1) rotate(0deg); }
}

.hero-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
}

@media (max-width: 968px) {
  .hero-container { grid-template-columns: 1fr; text-align: center; }
  .hero-visual { display: none; }
}

.badge {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(76, 175, 80, 0.1);
  border: 1px solid var(--accent-glow);
  border-radius: 20px;
  font-size: 0.9rem;
  color: var(--accent-light);
  font-weight: 600;
  margin-bottom: 24px;
  backdrop-filter: blur(5px);
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  margin-bottom: 24px;
  letter-spacing: -2px;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-mid);
  margin-bottom: 40px;
  max-width: 600px;
}

@media (max-width: 968px) {
  .hero-subtitle { margin-left: auto; margin-right: auto; }
}

.hero-actions {
  display: flex;
  gap: 20px;
}

@media (max-width: 480px) {
  .hero-actions { flex-direction: column; }
}

@media (max-width: 968px) {
  .hero-actions { justify-content: center; }
}

/* ─── Buttons ───────────────────────────────────────────────────────────── */

.btn {
  padding: 16px 32px;
  border-radius: 40px;
  font-size: 1.1rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: inline-block;
}

.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 10px 20px var(--accent-glow);
}

.btn-primary:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 15px 30px var(--accent-glow);
  background: #5dbb61;
}

.btn-outline {
  border: 2px solid rgba(255, 255, 255, 0.1);
  color: var(--text-hi);
  backdrop-filter: blur(5px);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-4px);
}

.btn-pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.6); }
  70% { box-shadow: 0 0 0 20px rgba(76, 175, 80, 0); }
  100% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0); }
}

/* ─── Visual Mockup ─────────────────────────────────────────────────────── */

.mockup-container {
  background: #1a1a1a;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 60px rgba(0,0,0,0.5);
  overflow: hidden;
  position: relative;
  transition: transform 0.3s ease-out;
  transform-style: preserve-3d;
  animation: mockup-idle 6s infinite ease-in-out;
}

.mockup-container.is-active {
  animation: none;
}

@keyframes mockup-idle {
  0%, 100% { transform: perspective(1000px) rotateX(2deg) rotateY(-2deg) translateY(0); }
  50% { transform: perspective(1000px) rotateX(-2deg) rotateY(2deg) translateY(-10px); }
}

.mockup-header {
  background: #252525;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.mockup-dots {
  display: flex;
  gap: 6px;
}

.mockup-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
}

.mockup-address {
  background: rgba(255, 255, 255, 0.05);
  padding: 4px 12px;
  border-radius: 4px;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  flex-grow: 1;
}

.mockup-body {
  padding: 24px;
}

.mockup-stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

.mockup-stat-card {
  background: rgba(255, 255, 255, 0.03);
  padding: 16px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.stat-label { font-size: 10px; color: var(--text-lo); margin-bottom: 4px; }
.stat-value { font-size: 1.2rem; font-weight: 700; }

.mockup-chart {
  height: 120px;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  padding-top: 20px;
}

.bar {
  flex: 1;
  background: linear-gradient(to top, var(--accent), var(--accent-light));
  border-radius: 4px 4px 0 0;
  animation: bar-grow 1s ease-out forwards;
  transform-origin: bottom;
}

@keyframes bar-grow {
  from { transform: scaleY(0); }
  to { transform: scaleY(1); }
}

/* ─── Features ──────────────────────────────────────────────────────────── */

.features { padding: 100px 0; }

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-title { font-size: 2.5rem; margin-bottom: 16px; }
.section-subtitle { font-size: 1.1rem; color: var(--text-mid); max-width: 600px; margin: 0 auto; }

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.feature-card {
  background: var(--bg-card);
  padding: 40px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-10px);
  border-color: var(--accent-glow);
  background: var(--bg-hover);
}

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

.feature-card h3 { margin-bottom: 16px; }
.feature-card p { color: var(--text-mid); }

/* ─── How it Works ──────────────────────────────────────────────────────── */

.how-it-works {
  background: rgba(255, 255, 255, 0.02);
  padding: 100px 0;
  margin: 60px 0;
}

.steps-wrapper {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

@media (max-width: 768px) {
  .steps-wrapper { grid-template-columns: 1fr; text-align: center; }
}

.step-num {
  font-size: 6rem;
  font-weight: 900;
  color: #2ecc71;
  opacity: 0.15;
  margin-bottom: 5px;
  display: block;
  line-height: 1;
  transform: translateX(-10px);
}

.step {
  position: relative;
  padding-top: 40px;
}

.step h3 { margin-bottom: 12px; position: relative; z-index: 1; }
.step p { color: var(--text-mid); position: relative; z-index: 1; }

/* ─── Install Section ───────────────────────────────────────────────────── */

.install { padding: 100px 0; }

.install-card {
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.1) 0%, rgba(10, 24, 16, 0.5) 100%);
  padding: 80px 40px;
  border-radius: var(--radius);
  text-align: center;
  border: 1px solid var(--accent-glow);
  backdrop-filter: blur(10px);
}

.install-title { font-size: 3rem; margin-bottom: 16px; }
.install-subtitle { font-size: 1.25rem; color: var(--text-mid); margin-bottom: 48px; }

.store-buttons {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 32px;
}

@media (max-width: 600px) {
  .store-buttons { flex-direction: column; align-items: center; }
}

.store-btn {
  display: flex;
  align-items: center;
  gap: 16px;
  background: #000;
  color: white;
  text-decoration: none;
  padding: 12px 28px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.2s;
  min-width: 240px;
  text-align: left;
}

.store-btn:hover {
  background: #111;
  border-color: var(--accent);
  transform: translateY(-2px);
}

.store-btn img { width: 32px; height: 32px; }
.store-text { display: flex; flex-direction: column; }
.store-label { font-size: 10px; text-transform: uppercase; opacity: 0.6; }
.store-name { font-size: 1.1rem; font-weight: 600; }

.install-note { color: var(--text-lo); font-size: 0.9rem; }

/* ─── Footer ────────────────────────────────────────────────────────────── */

.footer {
  padding: 80px 0 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr; text-align: center; }
  .footer-brand .nav-logo { justify-content: center; }
}

.footer-brand p { color: var(--text-lo); margin-top: 16px; max-width: 300px; }

.disclaimer {
  font-size: 0.8rem;
  opacity: 0.6;
  font-style: italic;
  margin-top: 8px !important;
}

.footer-links h4 { margin-bottom: 24px; font-size: 1rem; }
.footer-links { display: flex; flex-direction: column; gap: 12px; }
.footer-links a {
  color: var(--text-lo);
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--accent); }

.footer-bottom {
  text-align: center;
  padding-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.03);
  color: var(--text-lo);
  font-size: 0.9rem;
}

/* ─── Animations ────────────────────────────────────────────────────────── */

.fade-up {
  opacity: 0;
  transform: translateY(30px);
  animation: fade-up 0.8s forwards cubic-bezier(0.22, 1, 0.36, 1);
}

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

.section-animate {
  opacity: 0;
  transform: translateY(50px);
  transition: all 1s cubic-bezier(0.22, 1, 0.36, 1);
}

.section-animate.is-visible {
  opacity: 1;
  transform: translateY(0);
}
