/* ============================================================
   LLASRT Formation — Design System
   Extracted & refactored from initiation-tld.html
   ============================================================ */

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

/* ----- CSS VARIABLES ----- */
:root {
  --bg-deep: #0a0a14;
  --bg-main: #12121f;
  --bg-card: #1a1a2e;
  --bg-card-hover: #22223a;
  --accent: #ff6a00;
  --accent-glow: rgba(255, 106, 0, 0.25);
  --accent-dim: #cc5500;
  --text-primary: #f0ece4;
  --text-secondary: #8a8a9a;
  --text-muted: #55556a;
  --border: rgba(255, 106, 0, 0.12);
  --border-strong: rgba(255, 106, 0, 0.3);
  --font-heading: 'Bebas Neue', 'Arial Narrow', sans-serif;
  --font-body: 'DM Sans', 'Segoe UI', sans-serif;
}

/* ----- BASE ----- */
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  background: var(--bg-deep);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Noise overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* ----- TYPOGRAPHY ----- */
h1 { font-family: var(--font-heading); font-size: clamp(60px, 8vw, 130px); line-height: 0.95; letter-spacing: 3px; }
h2 { font-family: var(--font-heading); font-size: clamp(48px, 5vw, 80px); line-height: 1; letter-spacing: 2px; margin-bottom: 40px; }
h3 { font-family: var(--font-heading); font-size: clamp(28px, 3vw, 44px); letter-spacing: 2px; color: var(--accent); margin-bottom: 24px; }
.lead { font-size: 22px; color: var(--text-secondary); max-width: 700px; line-height: 1.7; font-weight: 300; }
.accent { color: var(--accent); }
.dim { color: var(--text-secondary); }
.quote {
  font-style: italic; font-size: 24px; color: var(--text-secondary);
  border-left: 3px solid var(--accent); padding-left: 24px; margin: 32px 0; max-width: 700px;
}
.section-tag {
  font-family: var(--font-heading);
  font-size: 14px; letter-spacing: 6px; color: var(--accent);
  text-transform: uppercase; margin-bottom: 12px;
  display: flex; align-items: center; gap: 16px;
}
.section-tag::before { content: ''; width: 40px; height: 1px; background: var(--accent); }

/* ----- SECTION LAYOUT ----- */
.section {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 60px;
  overflow: hidden;
}
.section-inner {
  max-width: 1400px;
  width: 100%;
  position: relative;
  z-index: 2;
}
.section-divider { width: 60px; height: 2px; background: var(--accent); margin: 24px 0; }

/* Chapter number watermark */
.chapter-num {
  font-family: var(--font-heading);
  font-size: clamp(120px, 15vw, 220px);
  color: rgba(255, 106, 0, 0.04);
  position: absolute; top: -30px; left: -20px;
  line-height: 1; z-index: 0; user-select: none;
}

/* ----- GRID & CARDS ----- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-5 { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }

.card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 32px;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1); position: relative; overflow: hidden;
}
.card::before {
  content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent); opacity: 0; transition: opacity 0.4s;
}
.card:hover { border-color: var(--border-strong); background: var(--bg-card-hover); transform: translateY(-4px); }
.card:hover::before { opacity: 1; }
.card-number { font-family: var(--font-heading); font-size: 48px; color: var(--accent); line-height: 1; margin-bottom: 12px; }
.card h4 { font-family: var(--font-heading); font-size: 22px; letter-spacing: 1px; margin-bottom: 8px; }
.card p { color: var(--text-secondary); font-size: 15px; line-height: 1.5; }

/* ----- TABLE ----- */
.data-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 16px; }
.data-table thead th {
  font-family: var(--font-heading); font-size: 16px; letter-spacing: 3px; color: var(--accent);
  text-align: left; padding: 14px 20px; border-bottom: 2px solid var(--accent);
  background: rgba(255, 106, 0, 0.05);
}
.data-table tbody td { padding: 14px 20px; border-bottom: 1px solid var(--border); color: var(--text-secondary); transition: all 0.3s; }
.data-table tbody tr:hover td { background: rgba(255, 106, 0, 0.04); color: var(--text-primary); }
.data-table .value { color: var(--text-primary); font-weight: 500; }
.data-table .highlight { color: var(--accent); font-weight: 700; }

/* ----- STEP LIST ----- */
.step-list { display: flex; flex-direction: column; gap: 20px; }
.step-item {
  display: flex; gap: 20px; align-items: flex-start; padding: 20px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; transition: all 0.4s;
}
.step-item:hover { border-color: var(--border-strong); background: var(--bg-card-hover); }
.step-num { font-family: var(--font-heading); font-size: 36px; color: var(--accent); line-height: 1; min-width: 50px; }
.step-content h4 { font-family: var(--font-heading); font-size: 20px; letter-spacing: 1px; margin-bottom: 4px; }
.step-content p { color: var(--text-secondary); font-size: 15px; }

/* ----- EIT ITEMS ----- */
.eit-grid { display: flex; flex-direction: column; gap: 16px; }
.eit-item {
  display: flex; align-items: flex-start; gap: 20px; padding: 20px 24px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; transition: all 0.4s;
}
.eit-item:hover { border-color: var(--border-strong); }
.eit-icon {
  font-size: 28px; width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;
  background: rgba(255, 106, 0, 0.08); border-radius: 8px; flex-shrink: 0;
}
.eit-item h4 { font-family: var(--font-heading); font-size: 18px; letter-spacing: 2px; color: var(--accent); margin-bottom: 4px; }
.eit-item p { color: var(--text-secondary); font-size: 15px; line-height: 1.5; }

/* ----- IMAGE FRAMES ----- */
.img-frame {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 20px; text-align: center;
}
.img-frame img { max-width: 100%; max-height: 500px; object-fit: contain; border-radius: 4px; }
.img-caption { margin-top: 12px; font-size: 14px; color: var(--text-muted); font-style: italic; }

/* ----- FLOW DIAGRAMS ----- */
.flow { display: flex; align-items: center; gap: 0; justify-content: center; margin: 32px 0; flex-wrap: wrap; }
.flow-box {
  padding: 18px 32px; border: 2px solid var(--accent); border-radius: 6px;
  font-family: var(--font-heading); font-size: 22px; letter-spacing: 2px;
  color: var(--text-primary); background: rgba(255, 106, 0, 0.06);
}
.flow-arrow { font-size: 28px; color: var(--accent); padding: 0 16px; }

/* ----- CALLOUT & WARNING ----- */
.callout {
  background: rgba(255, 106, 0, 0.06); border-left: 3px solid var(--accent);
  padding: 16px 24px; border-radius: 0 8px 8px 0; margin-top: 24px; font-size: 16px; color: var(--text-secondary);
}
.callout strong { color: var(--accent); }
.warning {
  background: rgba(255, 106, 0, 0.08); border: 1px solid var(--accent);
  padding: 14px 20px; border-radius: 6px; margin-top: 20px; font-size: 15px; color: var(--accent);
}

/* ----- BUTTONS ----- */
.btn-primary {
  font-family: var(--font-heading);
  font-size: 18px;
  letter-spacing: 4px;
  padding: 16px 40px;
  background: var(--accent);
  color: var(--bg-deep);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s;
}
.btn-primary:hover { background: #ff8533; transform: translateY(-2px); }

.btn-secondary {
  font-family: var(--font-heading);
  font-size: 14px;
  letter-spacing: 3px;
  padding: 10px 24px;
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s;
}
.btn-secondary:hover { color: var(--text-primary); border-color: var(--border-strong); }

.btn-icon {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* ----- IMPACT BARS ----- */
.impact-bar-wrap { width: 100%; height: 8px; background: rgba(255, 106, 0, 0.08); border-radius: 4px; overflow: hidden; }
.impact-bar { height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent-dim)); border-radius: 4px; width: 0; transition: width 1.5s cubic-bezier(0.16, 1, 0.3, 1); }
.visible .impact-bar { width: var(--bar-w); }

/* ----- STABILITY DOTS ----- */
.stability { display: flex; gap: 4px; margin-top: 10px; }
.stability-dot { width: 24px; height: 6px; border-radius: 3px; background: var(--text-muted); }
.stability-dot.filled { background: var(--accent); }

/* ----- TABS ----- */
.tabs { display: flex; gap: 0; margin-bottom: 32px; border-bottom: 1px solid var(--border); }
.tab {
  font-family: var(--font-heading); font-size: 16px; letter-spacing: 3px;
  padding: 12px 28px; color: var(--text-muted); cursor: pointer;
  border: none; border-bottom: 2px solid transparent; transition: all 0.3s; background: none;
}
.tab:hover { color: var(--text-secondary); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ----- SCROLL REVEAL ANIMATIONS ----- */
.reveal-item { opacity: 0; transform: translateY(40px); transition: opacity 0.8s cubic-bezier(0.16,1,0.3,1), transform 0.8s cubic-bezier(0.16,1,0.3,1); }
.reveal-item.visible { opacity: 1; transform: translateY(0); }
.reveal-left { opacity: 0; transform: translateX(-60px); transition: opacity 0.8s cubic-bezier(0.16,1,0.3,1), transform 0.8s cubic-bezier(0.16,1,0.3,1); }
.reveal-left.visible { opacity: 1; transform: translateX(0); }
.reveal-right { opacity: 0; transform: translateX(60px); transition: opacity 0.8s cubic-bezier(0.16,1,0.3,1), transform 0.8s cubic-bezier(0.16,1,0.3,1); }
.reveal-right.visible { opacity: 1; transform: translateX(0); }
.stagger > *:nth-child(1) { transition-delay: 0s; }
.stagger > *:nth-child(2) { transition-delay: 0.1s; }
.stagger > *:nth-child(3) { transition-delay: 0.15s; }
.stagger > *:nth-child(4) { transition-delay: 0.2s; }
.stagger > *:nth-child(5) { transition-delay: 0.25s; }
.stagger > *:nth-child(6) { transition-delay: 0.3s; }
.stagger > *:nth-child(7) { transition-delay: 0.35s; }

/* ----- RECAP ----- */
.recap-item { display: flex; align-items: center; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--border); font-size: 20px; }
.recap-check {
  width: 32px; height: 32px; border: 2px solid var(--accent); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; color: var(--accent); font-size: 16px; flex-shrink: 0;
}

/* ----- RESPONSIVE ----- */
@media (max-width: 900px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .grid-5 { grid-template-columns: repeat(3, 1fr); }
  .section { padding: 60px 24px; }
}
