/* ==========================================
   VibeCode4Noobs - Colorful & Friendly Style
   ========================================== */

:root {
  /* Colors */
  --purple: #7c3aed;
  --purple-light: #a78bfa;
  --purple-dark: #5b21b6;
  --teal: #14b8a6;
  --teal-light: #5eead4;
  --teal-dark: #0d9488;
  --orange: #f97316;
  --orange-light: #fdba74;
  --yellow: #eab308;
  --yellow-light: #fde68a;
  --pink: #ec4899;
  --pink-light: #f9a8d4;

  /* Neutrals */
  --bg: #faf9ff;
  --bg-alt: #f0edff;
  --text: #1e1b4b;
  --text-muted: #6b7280;
  --white: #ffffff;
  --border: #e5e7eb;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(124, 58, 237, 0.08);
  --shadow-md: 0 4px 14px rgba(124, 58, 237, 0.1);
  --shadow-lg: 0 10px 30px rgba(124, 58, 237, 0.15);

  /* Spacing */
  --container: 800px;
  --radius: 16px;
  --radius-sm: 10px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

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

code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9em;
  background: var(--bg-alt);
  padding: 2px 6px;
  border-radius: 4px;
}

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

/* ==========================================
   Navigation
   ========================================== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}

.nav.scrolled {
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-logo {
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--purple);
  letter-spacing: -0.5px;
}

.nav-logo:hover {
  color: var(--purple-dark);
}

.nav-links {
  display: flex;
  gap: 4px;
}

.nav-link {
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: all 0.2s;
}

.nav-link:hover {
  color: var(--purple);
  background: var(--bg-alt);
}

.nav-link.active {
  color: var(--purple);
  background: var(--bg-alt);
}

/* ==========================================
   Hero
   ========================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding: 120px 24px 80px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #ede9fe 0%, #fae8ff 25%, #fef3c7 50%, #d1fae5 75%, #e0e7ff 100%);
  background-size: 300% 300%;
  animation: gradientShift 12s ease infinite;
}

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

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

.hero-title {
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  font-weight: 800;
  letter-spacing: -1.5px;
  line-height: 1.1;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--purple) 0%, var(--pink) 50%, var(--orange) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-emoji {
  -webkit-text-fill-color: initial;
}

.hero-tagline {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 600;
  color: var(--text);
  margin-bottom: 12px;
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto 32px;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 1.05rem;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--purple);
  color: var(--white);
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.35);
}

.btn-primary:hover {
  background: var(--purple-dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(124, 58, 237, 0.45);
}

/* ==========================================
   Steps
   ========================================== */
.step {
  padding: 80px 0;
}

.step-alt {
  background: var(--bg-alt);
}

.step-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 40px;
}

.step-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--white);
  flex-shrink: 0;
}

/* Colorful step numbers */
#step-1 .step-number { background: linear-gradient(135deg, var(--purple), var(--purple-light)); }
#step-2 .step-number { background: linear-gradient(135deg, var(--teal), var(--teal-light)); }
#step-3 .step-number { background: linear-gradient(135deg, var(--orange), var(--orange-light)); }
#step-4 .step-number { background: linear-gradient(135deg, var(--pink), var(--pink-light)); }
#step-5 .step-number { background: linear-gradient(135deg, #ef4444, #f87171); }
#step-6 .step-number { background: linear-gradient(135deg, var(--yellow), var(--orange)); }
#step-7 .step-number { background: linear-gradient(135deg, var(--purple), var(--teal)); }
#step-8 .step-number { background: linear-gradient(135deg, var(--orange), var(--yellow)); }
#step-9 .step-number { background: linear-gradient(135deg, var(--teal), var(--teal-light)); }

.step-title {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -0.5px;
}

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

/* ==========================================
   Cards
   ========================================== */
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

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

.card p {
  margin-bottom: 12px;
}

.card p:last-child {
  margin-bottom: 0;
}

.card ul, .card ol {
  padding-left: 24px;
  margin-bottom: 12px;
}

.card li {
  margin-bottom: 8px;
}

.card li:last-child {
  margin-bottom: 0;
}

.card-tip {
  border-left: 4px solid var(--yellow);
  background: linear-gradient(135deg, #fffbeb, var(--white));
}

.card-warning {
  border-left: 4px solid #ef4444;
  background: linear-gradient(135deg, #fef2f2, var(--white));
}

.card-celebrate {
  border: 2px solid var(--teal);
  background: linear-gradient(135deg, #ecfdf5, #f0fdfa);
  text-align: center;
}

.card-celebrate h3 {
  font-size: 1.5rem;
}

/* ==========================================
   Code Blocks
   ========================================== */
.code-block {
  background: #1e1b4b;
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin: 16px 0;
}

.code-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
}

.copy-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.7);
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Inter', sans-serif;
}

.copy-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  color: var(--white);
}

.copy-btn.copied {
  background: var(--teal);
  border-color: var(--teal);
  color: var(--white);
}

.code-block pre {
  padding: 16px;
  overflow-x: auto;
}

.code-block code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.88rem;
  color: #e2e8f0;
  background: none;
  padding: 0;
  line-height: 1.6;
}

.code-block-large pre {
  max-height: 400px;
  overflow-y: auto;
}

.code-block-bad {
  background: #450a0a;
  border: 1px solid #ef4444;
}

.code-block-bad .code-header {
  color: #fca5a5;
}

/* ==========================================
   Method Toggle (Desktop vs Terminal)
   ========================================== */
.method-toggle {
  display: flex;
  gap: 0;
  margin-bottom: 20px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid var(--purple);
}

.method-btn {
  flex: 1;
  padding: 14px 20px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--white);
  color: var(--purple);
}

.method-btn:hover {
  background: var(--bg-alt);
}

.method-btn.active {
  background: var(--purple);
  color: var(--white);
}

.method-content {
  display: none;
}

.method-content.active {
  display: block;
}

.card-method {
  position: relative;
}

.method-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 12px;
  border-radius: 50px;
  margin-bottom: 12px;
}

.method-badge-easy {
  background: var(--teal);
  color: var(--white);
}

.method-badge-power {
  background: var(--purple);
  color: var(--white);
}

/* ==========================================
   Expandable Sections
   ========================================== */
.expandable {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  overflow: hidden;
}

.expandable-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg);
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  font-size: 0.95rem;
  transition: background 0.2s;
}

.expandable-toggle:hover {
  background: var(--bg-alt);
}

.expand-icon {
  font-size: 0.7rem;
  transition: transform 0.2s;
  color: var(--purple);
}

.expandable.open .expand-icon {
  transform: rotate(90deg);
}

.expand-hint {
  margin-left: auto;
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 400;
}

.expandable-content {
  display: none;
  padding: 0 16px 16px;
  background: var(--white);
}

.expandable.open .expandable-content {
  display: block;
}

/* ==========================================
   Pipeline Diagram
   ========================================== */
.pipeline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px 0;
  flex-wrap: wrap;
}

.pipeline-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 20px;
  background: var(--bg-alt);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
}

.pipeline-icon {
  font-size: 1.5rem;
}

.pipeline-arrow {
  font-size: 1.2rem;
  color: var(--text-muted);
  font-weight: 700;
}

/* ==========================================
   Chat Example
   ========================================== */
.chat-example {
  margin: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-msg {
  padding: 16px;
  border-radius: var(--radius-sm);
}

.chat-user {
  background: var(--bg-alt);
  border: 1px solid var(--border);
}

.chat-claude {
  background: linear-gradient(135deg, #ede9fe, #fae8ff);
  border: 1px solid var(--purple-light);
}

.chat-label {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.chat-user .chat-label {
  color: var(--teal-dark);
}

.chat-claude .chat-label {
  color: var(--purple);
}

.chat-msg p {
  margin-bottom: 0;
  font-size: 0.95rem;
}

/* ==========================================
   Progress Tracker
   ========================================== */
.progress-tracker {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 200;
}

.progress-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  background: var(--purple);
  color: var(--white);
  border: none;
  border-radius: 50px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-lg);
  transition: all 0.2s;
}

.progress-toggle:hover {
  background: var(--purple-dark);
  transform: translateY(-2px);
}

.progress-icon {
  font-size: 1rem;
}

.progress-panel {
  display: none;
  position: absolute;
  bottom: 56px;
  right: 0;
  width: 280px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  padding: 20px;
}

.progress-panel.open {
  display: block;
}

.progress-panel h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 14px;
  color: var(--purple);
}

.progress-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 0.9rem;
  cursor: pointer;
  transition: color 0.2s;
}

.progress-item input[type="checkbox"] {
  accent-color: var(--purple);
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.progress-item.done {
  color: var(--text-muted);
  text-decoration: line-through;
}

.progress-bar-container {
  margin-top: 14px;
  height: 6px;
  background: var(--bg-alt);
  border-radius: 3px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--purple), var(--teal));
  border-radius: 3px;
  transition: width 0.4s ease;
}

/* ==========================================
   Stage Selector
   ========================================== */
.stage-selector {
  padding: 48px 0;
  background: var(--white);
}

.stage-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.stage-card {
  display: block;
  position: relative;
  padding: 28px;
  border-radius: var(--radius);
  border: 2px solid var(--border);
  transition: all 0.2s;
  color: var(--text);
}

.stage-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  color: var(--text);
}

.stage-card-easy {
  border-color: var(--teal);
  background: linear-gradient(135deg, #f0fdfa, #ecfdf5);
}

.stage-card-easy:hover {
  border-color: var(--teal-dark);
}

.stage-card-level {
  border-color: var(--purple-light);
  background: linear-gradient(135deg, #f5f3ff, #ede9fe);
}

.stage-card-level:hover {
  border-color: var(--purple);
}

.stage-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 3px 10px;
  border-radius: 50px;
  margin-bottom: 12px;
}

.stage-card-easy .stage-badge {
  background: var(--teal);
  color: var(--white);
}

.stage-card-level .stage-badge {
  background: var(--purple-light);
  color: var(--white);
}

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

.stage-card p {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  line-height: 1.5;
}

.stage-steps {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* ==========================================
   Stage Dividers
   ========================================== */
.stage-divider {
  padding: 40px 0;
  text-align: center;
  background: linear-gradient(135deg, #ecfdf5, #f0fdfa);
  border-top: 3px solid var(--teal);
  border-bottom: 3px solid var(--teal);
}

.stage-divider-level {
  background: linear-gradient(135deg, #f5f3ff, #ede9fe);
  border-top-color: var(--purple);
  border-bottom-color: var(--purple);
}

.stage-divider-title {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.stage-divider-sub {
  color: var(--text-muted);
  font-size: 1rem;
}

/* ==========================================
   Progress Stage Labels
   ========================================== */
.progress-stage-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--purple);
  margin-top: 10px;
  margin-bottom: 4px;
}

.progress-stage-label:first-of-type {
  margin-top: 0;
}

/* ==========================================
   Footer
   ========================================== */
.footer {
  padding: 48px 0;
  text-align: center;
  background: var(--text);
  color: rgba(255, 255, 255, 0.7);
}

.footer-text {
  font-size: 1rem;
  margin-bottom: 4px;
}

.footer-sub {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.4);
}

/* ==========================================
   Responsive
   ========================================== */
@media (max-width: 640px) {
  .nav-links {
    display: none;
  }

  .hero {
    padding: 100px 20px 60px;
    min-height: auto;
  }

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

  .step {
    padding: 48px 0;
  }

  .step-header {
    margin-bottom: 24px;
  }

  .step-number {
    width: 44px;
    height: 44px;
    font-size: 1.2rem;
    border-radius: 12px;
  }

  .step-title {
    font-size: 1.4rem;
  }

  .card {
    padding: 20px;
  }

  .pipeline {
    flex-direction: column;
    gap: 4px;
  }

  .pipeline-arrow {
    transform: rotate(90deg);
  }

  .expand-hint {
    display: none;
  }

  .progress-panel {
    width: 260px;
    right: -8px;
  }

  .stage-cards {
    grid-template-columns: 1fr;
  }

  .stage-divider {
    padding: 28px 0;
  }

  .stage-divider-title {
    font-size: 1.3rem;
  }
}
