@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
  --bg-primary: #0a0e1a;
  --bg-secondary: #111827;
  --bg-card: rgba(17, 24, 39, 0.7);
  --bg-glass: rgba(255, 255, 255, 0.03);
  --border-glass: rgba(255, 255, 255, 0.08);
  --accent-primary: #6366f1;
  --accent-secondary: #8b5cf6;
  --accent-glow: rgba(99, 102, 241, 0.3);
  --accent-rose: #f43f5e;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-cyan: #06b6d4;
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --gradient-primary: linear-gradient(135deg, #6366f1, #8b5cf6, #a78bfa);
  --gradient-rose: linear-gradient(135deg, #f43f5e, #e11d48);
  --gradient-emerald: linear-gradient(135deg, #10b981, #059669);
  --gradient-amber: linear-gradient(135deg, #f59e0b, #d97706);
  --gradient-hero: linear-gradient(135deg, rgba(99,102,241,0.15), rgba(139,92,246,0.1), rgba(6,182,212,0.08));
  --shadow-lg: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.15);
  --radius-lg: 20px;
  --radius-md: 12px;
  --radius-sm: 8px;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  min-height: 100vh;
}

h1, h2, h3, h4, h5 { font-family: 'Outfit', sans-serif; line-height: 1.2; }

/* ===== NAVBAR ===== */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 1rem 2rem;
  background: rgba(10, 14, 26, 0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glass);
  transition: all 0.3s ease;
}
.navbar.scrolled { background: rgba(10, 14, 26, 0.95); padding: 0.7rem 2rem; }
.nav-content { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; }
.nav-logo { display: flex; align-items: center; gap: 0.75rem; text-decoration: none; }
.nav-logo-icon {
  width: 42px; height: 42px; border-radius: var(--radius-sm);
  background: var(--gradient-primary); display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; box-shadow: 0 0 20px var(--accent-glow);
}
.nav-logo-text { font-family: 'Outfit', sans-serif; font-size: 1.3rem; font-weight: 700; color: var(--text-primary); }
.nav-logo-text span { background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a {
  color: var(--text-secondary); text-decoration: none; font-size: 0.9rem; font-weight: 500;
  transition: color 0.3s; position: relative; padding-bottom: 4px;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 2px;
  background: var(--gradient-primary); transition: width 0.3s;
}
.nav-links a:hover { color: var(--text-primary); }
.nav-links a:hover::after { width: 100%; }

/* ===== HERO ===== */
.hero {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 8rem 2rem 4rem; position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%;
  background: radial-gradient(circle at 30% 40%, rgba(99,102,241,0.08) 0%, transparent 50%),
              radial-gradient(circle at 70% 60%, rgba(139,92,246,0.06) 0%, transparent 50%),
              radial-gradient(circle at 50% 80%, rgba(6,182,212,0.04) 0%, transparent 40%);
  animation: heroGlow 15s ease-in-out infinite alternate;
}
@keyframes heroGlow {
  0% { transform: translate(0, 0) rotate(0deg); }
  100% { transform: translate(-3%, -3%) rotate(3deg); }
}
.hero-content { max-width: 800px; text-align: center; position: relative; z-index: 1; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1.25rem; border-radius: 50px;
  background: rgba(99,102,241,0.1); border: 1px solid rgba(99,102,241,0.2);
  font-size: 0.85rem; color: var(--accent-primary); font-weight: 500;
  margin-bottom: 2rem; animation: fadeInUp 0.8s ease;
}
.hero-badge .pulse {
  width: 8px; height: 8px; border-radius: 50%; background: var(--accent-emerald);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.5); } }
.hero h1 { font-size: clamp(2.5rem, 5vw, 4rem); font-weight: 800; margin-bottom: 1.5rem; animation: fadeInUp 0.8s ease 0.1s both; }
.hero h1 .gradient-text { background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero p { font-size: 1.15rem; color: var(--text-secondary); max-width: 600px; margin: 0 auto 2.5rem; animation: fadeInUp 0.8s ease 0.2s both; }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
.hero-cta { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; animation: fadeInUp 0.8s ease 0.3s both; }
.btn-primary, .btn-secondary {
  padding: 0.85rem 2rem; border-radius: var(--radius-sm); font-size: 0.95rem;
  font-weight: 600; cursor: pointer; transition: all 0.3s; border: none; text-decoration: none;
}
.btn-primary {
  background: var(--gradient-primary); color: white;
  box-shadow: 0 4px 15px var(--accent-glow);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 25px var(--accent-glow); }
.btn-secondary {
  background: var(--bg-glass); color: var(--text-primary);
  border: 1px solid var(--border-glass);
}
.btn-secondary:hover { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.15); }
.hero-stats {
  display: flex; gap: 3rem; justify-content: center; margin-top: 4rem;
  animation: fadeInUp 0.8s ease 0.4s both;
}
.hero-stat { text-align: center; }
.hero-stat .number {
  font-family: 'Outfit', sans-serif; font-size: 2rem; font-weight: 800;
  background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-stat .label { font-size: 0.8rem; color: var(--text-muted); margin-top: 0.25rem; }

/* ===== SECTIONS ===== */
.section { padding: 6rem 2rem; max-width: 1200px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 4rem; }
.section-label {
  display: inline-block; font-size: 0.8rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 2px; color: var(--accent-primary);
  margin-bottom: 1rem;
}
.section-title { font-size: clamp(2rem, 4vw, 2.8rem); font-weight: 800; margin-bottom: 1rem; }
.section-subtitle { font-size: 1.05rem; color: var(--text-secondary); max-width: 600px; margin: 0 auto; }

/* ===== CALCULATOR ===== */
.calculator-wrapper {
  display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: start;
}
.calc-card {
  background: var(--bg-card); border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg); padding: 2rem;
  backdrop-filter: blur(10px); box-shadow: var(--shadow-lg);
}
.calc-card-title {
  font-size: 1.3rem; font-weight: 700; margin-bottom: 0.5rem;
  display: flex; align-items: center; gap: 0.75rem;
}
.calc-card-title .icon {
  width: 36px; height: 36px; border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center; font-size: 1.1rem;
}
.calc-card-desc { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 2rem; }

.form-group { margin-bottom: 1.5rem; }
.form-label {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 0.85rem; font-weight: 500; color: var(--text-secondary); margin-bottom: 0.5rem;
}
.form-label .unit { font-size: 0.75rem; color: var(--text-muted); }
.form-label .info-tip {
  width: 18px; height: 18px; border-radius: 50%;
  background: rgba(99,102,241,0.15); color: var(--accent-primary);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 0.65rem; font-weight: 700; cursor: help; margin-left: 0.5rem;
  position: relative;
}
.form-label .info-tip .tooltip-text {
  visibility: hidden; opacity: 0; position: absolute; bottom: 130%; left: 50%;
  transform: translateX(-50%); background: var(--bg-secondary);
  border: 1px solid var(--border-glass); border-radius: var(--radius-sm);
  padding: 0.5rem 0.75rem; font-size: 0.75rem; color: var(--text-secondary);
  white-space: nowrap; transition: all 0.2s; z-index: 10; font-weight: 400;
}
.form-label .info-tip:hover .tooltip-text { visibility: visible; opacity: 1; }

.form-input, .form-select {
  width: 100%; padding: 0.8rem 1rem; border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.03); border: 1px solid var(--border-glass);
  color: var(--text-primary); font-family: 'Inter', sans-serif; font-size: 0.95rem;
  transition: all 0.3s; outline: none;
}
.form-input:focus, .form-select:focus {
  border-color: var(--accent-primary); box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}
.form-input::placeholder { color: var(--text-muted); }
.form-select option { background: var(--bg-secondary); color: var(--text-primary); }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

.radio-group { display: flex; gap: 1rem; }
.radio-option {
  flex: 1; position: relative;
}
.radio-option input { position: absolute; opacity: 0; }
.radio-option label {
  display: flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.7rem 1rem; border-radius: var(--radius-sm);
  background: var(--bg-glass); border: 1px solid var(--border-glass);
  cursor: pointer; font-size: 0.9rem; font-weight: 500; color: var(--text-secondary);
  transition: all 0.3s;
}
.radio-option input:checked + label {
  background: rgba(99,102,241,0.1); border-color: var(--accent-primary);
  color: var(--accent-primary);
}

.calc-actions { display: flex; gap: 1rem; margin-top: 2rem; }
.calc-actions .btn-primary { flex: 1; text-align: center; font-size: 1rem; padding: 1rem; }
.calc-actions .btn-reset {
  padding: 1rem 1.5rem; border-radius: var(--radius-sm); background: rgba(244,63,94,0.1);
  border: 1px solid rgba(244,63,94,0.2); color: var(--accent-rose);
  cursor: pointer; font-weight: 600; font-size: 0.9rem; transition: all 0.3s;
}
.calc-actions .btn-reset:hover { background: rgba(244,63,94,0.2); }

/* ===== RESULTS ===== */
.results-panel { position: sticky; top: 100px; }
.result-metric {
  padding: 1.25rem; border-radius: var(--radius-md);
  background: var(--bg-glass); border: 1px solid var(--border-glass);
  margin-bottom: 1rem; transition: all 0.4s;
}
.result-metric.highlight {
  border-color: var(--accent-primary); box-shadow: 0 0 30px rgba(99,102,241,0.1);
}
.result-metric .label { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.25rem; }
.result-metric .value {
  font-family: 'Outfit', sans-serif; font-size: 1.8rem; font-weight: 700;
}
.result-metric .unit-label { font-size: 0.85rem; color: var(--text-muted); font-weight: 400; }
.result-metric .status-badge {
  display: inline-block; padding: 0.25rem 0.75rem; border-radius: 50px;
  font-size: 0.75rem; font-weight: 600; margin-top: 0.5rem;
}
.status-normal { background: rgba(16,185,129,0.15); color: var(--accent-emerald); }
.status-mild { background: rgba(245,158,11,0.15); color: var(--accent-amber); }
.status-moderate { background: rgba(249,115,22,0.15); color: #f97316; }
.status-severe { background: rgba(244,63,94,0.15); color: var(--accent-rose); }

.geometry-result {
  margin-top: 1rem; padding: 1.5rem; border-radius: var(--radius-md);
  background: var(--bg-glass); border: 1px solid var(--border-glass);
  text-align: center;
}
.geometry-result .geo-label { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.geometry-result .geo-type {
  font-family: 'Outfit', sans-serif; font-size: 1.2rem; font-weight: 700;
  margin-bottom: 0.5rem;
}
.geometry-result .geo-desc { font-size: 0.8rem; color: var(--text-secondary); }

.results-empty {
  text-align: center; padding: 3rem 1rem; color: var(--text-muted);
}
.results-empty .empty-icon { font-size: 3rem; margin-bottom: 1rem; opacity: 0.3; }
.results-empty p { font-size: 0.9rem; }

/* ===== INTERACTIVE DIAGRAM ===== */
.diagram-section { padding: 6rem 2rem; }
.diagram-container {
  max-width: 1200px; margin: 0 auto;
  background: var(--bg-card); border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg); padding: 3rem;
  backdrop-filter: blur(10px); position: relative; overflow: hidden;
}
.diagram-container::before {
  content: ''; position: absolute; top: 0; right: 0; width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(99,102,241,0.08), transparent 70%);
  pointer-events: none;
}
.diagram-flow {
  display: flex; align-items: center; justify-content: center; gap: 0; flex-wrap: wrap;
  margin-top: 2rem; position: relative;
}
.flow-step {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 1.5rem; flex: 0 0 200px; position: relative; cursor: pointer;
  transition: transform 0.3s;
}
.flow-step:hover { transform: translateY(-5px); }
.flow-step .step-icon {
  width: 70px; height: 70px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 1.8rem;
  margin-bottom: 1rem; position: relative; z-index: 1;
  transition: all 0.4s; box-shadow: 0 0 25px rgba(0,0,0,0.3);
}
.flow-step.active .step-icon { transform: scale(1.1); }
.flow-step .step-num {
  position: absolute; top: 8px; right: calc(50% - 45px);
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--bg-primary); border: 2px solid var(--accent-primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem; font-weight: 700; color: var(--accent-primary); z-index: 2;
}
.flow-step .step-title { font-weight: 600; font-size: 0.9rem; margin-bottom: 0.25rem; }
.flow-step .step-desc { font-size: 0.75rem; color: var(--text-muted); }
.flow-arrow {
  font-size: 1.5rem; color: var(--text-muted); flex-shrink: 0;
  animation: arrowPulse 2s ease-in-out infinite;
}
@keyframes arrowPulse { 0%, 100% { opacity: 0.4; } 50% { opacity: 1; } }

.flow-detail-panel {
  margin-top: 2rem; padding: 2rem; border-radius: var(--radius-md);
  background: rgba(99,102,241,0.05); border: 1px solid rgba(99,102,241,0.1);
  min-height: 180px; transition: all 0.4s;
}
.flow-detail-panel h4 { font-size: 1.1rem; margin-bottom: 0.75rem; color: var(--accent-primary); }
.flow-detail-panel p { font-size: 0.9rem; color: var(--text-secondary); line-height: 1.8; }
.flow-detail-panel .formula-box {
  display: inline-block; padding: 0.75rem 1.5rem; margin-top: 1rem;
  border-radius: var(--radius-sm); background: rgba(0,0,0,0.3);
  font-family: 'Courier New', monospace; font-size: 0.85rem; color: var(--accent-cyan);
  border: 1px solid rgba(6,182,212,0.2);
}

/* ===== GEOMETRY GRID ===== */
.geometry-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; margin-top: 2rem;
}
.geo-card {
  padding: 1.5rem; border-radius: var(--radius-md);
  background: var(--bg-glass); border: 1px solid var(--border-glass);
  cursor: pointer; transition: all 0.3s; position: relative; overflow: hidden;
}
.geo-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  border-radius: var(--radius-md) var(--radius-md) 0 0; opacity: 0; transition: opacity 0.3s;
}
.geo-card:hover { border-color: rgba(255,255,255,0.15); transform: translateY(-3px); }
.geo-card:hover::before { opacity: 1; }
.geo-card.normal::before { background: var(--gradient-emerald); }
.geo-card.concentric-r::before { background: var(--gradient-amber); }
.geo-card.concentric-h::before { background: var(--gradient-rose); }
.geo-card.eccentric::before { background: linear-gradient(135deg, #6366f1, #8b5cf6); }
.geo-card .geo-card-icon { font-size: 2rem; margin-bottom: 0.75rem; }
.geo-card h4 { font-size: 1rem; font-weight: 600; margin-bottom: 0.5rem; }
.geo-card .geo-criteria { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.geo-card .geo-explanation { font-size: 0.8rem; color: var(--text-secondary); line-height: 1.6; }

/* ===== HEART VISUALIZATION ===== */
.heart-viz-container {
  display: flex; align-items: center; justify-content: center; gap: 3rem;
  margin-top: 2rem; flex-wrap: wrap;
}
.heart-svg-wrap {
  width: 280px; height: 280px; position: relative;
  display: flex; align-items: center; justify-content: center;
}
.heart-svg-wrap svg { width: 100%; height: 100%; }

/* ===== REFERENCE TABLE ===== */
.ref-table-wrap {
  overflow-x: auto; margin-top: 2rem;
  border-radius: var(--radius-md); border: 1px solid var(--border-glass);
}
.ref-table {
  width: 100%; border-collapse: collapse; font-size: 0.9rem;
}
.ref-table thead { background: rgba(99,102,241,0.1); }
.ref-table th {
  padding: 1rem; text-align: left; font-weight: 600; font-size: 0.8rem;
  text-transform: uppercase; letter-spacing: 1px; color: var(--accent-primary);
  border-bottom: 1px solid var(--border-glass);
}
.ref-table td {
  padding: 0.85rem 1rem; border-bottom: 1px solid var(--border-glass);
  color: var(--text-secondary);
}
.ref-table tbody tr { transition: background 0.2s; }
.ref-table tbody tr:hover { background: rgba(255,255,255,0.02); }
.ref-table tbody tr:last-child td { border-bottom: none; }

/* ===== FEATURES ===== */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.feature-card {
  padding: 2rem; border-radius: var(--radius-lg);
  background: var(--bg-card); border: 1px solid var(--border-glass);
  transition: all 0.3s; position: relative; overflow: hidden;
}
.feature-card:hover { border-color: rgba(99,102,241,0.3); transform: translateY(-5px); }
.feature-card .feature-icon {
  width: 50px; height: 50px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; margin-bottom: 1.25rem;
}
.feature-card h3 { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.75rem; }
.feature-card p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.7; }

/* ===== CALCULATOR LINKS GRID ===== */
.calc-links-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem;
}
.calc-link-card {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 1.5rem 1rem; border-radius: var(--radius-md);
  background: var(--bg-glass); border: 1px solid var(--border-glass);
  text-decoration: none; transition: all 0.3s; position: relative; overflow: hidden;
}
.calc-link-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: var(--gradient-primary); opacity: 0; transition: opacity 0.3s;
}
.calc-link-card:hover {
  border-color: rgba(99,102,241,0.3); transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}
.calc-link-card:hover::before { opacity: 1; }
.calc-link-icon { font-size: 1.8rem; margin-bottom: 0.75rem; }
.calc-link-title {
  font-family: 'Outfit', sans-serif; font-size: 0.95rem; font-weight: 600;
  color: var(--text-primary); margin-bottom: 0.35rem;
}
.calc-link-desc { font-size: 0.8rem; color: var(--text-muted); line-height: 1.5; }

/* ===== CONTENT SECTIONS ===== */
.content-section {
  padding: 5rem 2rem; max-width: 900px; margin: 0 auto;
}
.content-section .section-header { text-align: left; margin-bottom: 2.5rem; }
.content-section .section-title { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.content-block {
  margin-bottom: 3rem;
}
.content-block h3 {
  font-family: 'Outfit', sans-serif; font-size: 1.25rem; font-weight: 700;
  margin-bottom: 1rem; color: var(--text-primary); line-height: 1.4;
}
.content-block p {
  font-size: 0.95rem; color: var(--text-secondary); line-height: 1.85;
  margin-bottom: 1rem;
}
.content-block ul, .content-block ol {
  padding-left: 1.5rem; margin-bottom: 1rem;
}
.content-block li {
  font-size: 0.95rem; color: var(--text-secondary); line-height: 1.85;
  margin-bottom: 0.4rem;
}
.content-block strong { color: var(--text-primary); }
.content-block a {
  color: var(--accent-primary); text-decoration: none;
  transition: color 0.2s; border-bottom: 1px solid rgba(99,102,241,0.3);
}
.content-block a:hover { color: var(--accent-secondary); border-bottom-color: var(--accent-secondary); }
.footer a { transition: color 0.2s; }
.footer a:hover { color: var(--text-secondary) !important; }

.chart-table-wrap {
  overflow-x: auto; margin: 1.5rem 0 2rem;
  border-radius: var(--radius-md); border: 1px solid var(--border-glass);
}
.chart-table {
  width: 100%; border-collapse: collapse; font-size: 0.9rem;
}
.chart-table thead { background: rgba(99,102,241,0.08); }
.chart-table th {
  padding: 0.85rem 1rem; text-align: left; font-weight: 600; font-size: 0.8rem;
  text-transform: uppercase; letter-spacing: 0.5px; color: var(--accent-primary);
  border-bottom: 1px solid var(--border-glass);
}
.chart-table td {
  padding: 0.75rem 1rem; border-bottom: 1px solid var(--border-glass);
  color: var(--text-secondary);
}
.chart-table tbody tr:hover { background: rgba(255,255,255,0.02); }
.chart-table tbody tr:last-child td { border-bottom: none; }

.formula-highlight {
  display: block; padding: 1rem 1.5rem; margin: 1.25rem 0;
  border-radius: var(--radius-sm); background: rgba(6,182,212,0.06);
  font-family: 'Courier New', monospace; font-size: 0.9rem; color: var(--accent-cyan);
  border: 1px solid rgba(6,182,212,0.15); line-height: 1.6;
  overflow-x: auto;
}

.param-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 1.5rem 0;
}
.param-card {
  padding: 1rem 1.25rem; border-radius: var(--radius-sm);
  background: var(--bg-glass); border: 1px solid var(--border-glass);
}
.param-card .param-name {
  font-weight: 600; font-size: 0.85rem; color: var(--accent-primary); margin-bottom: 0.25rem;
}
.param-card .param-desc {
  font-size: 0.85rem; color: var(--text-secondary); line-height: 1.6;
}

/* ===== FAQ ===== */
.faq-section { padding: 5rem 2rem; max-width: 900px; margin: 0 auto; }
.faq-list { margin-top: 2rem; }
.faq-item {
  border: 1px solid var(--border-glass); border-radius: var(--radius-md);
  margin-bottom: 0.75rem; overflow: hidden; transition: border-color 0.3s;
}
.faq-item:hover { border-color: rgba(99,102,241,0.2); }
.faq-question {
  width: 100%; padding: 1.15rem 1.5rem; display: flex; align-items: center;
  justify-content: space-between; background: var(--bg-glass); border: none;
  color: var(--text-primary); font-family: 'Inter', sans-serif;
  font-size: 0.95rem; font-weight: 600; cursor: pointer; text-align: left;
  transition: background 0.3s;
}
.faq-question:hover { background: rgba(255,255,255,0.04); }
.faq-question .faq-icon {
  font-size: 1.2rem; color: var(--accent-primary); transition: transform 0.3s;
  flex-shrink: 0; margin-left: 1rem;
}
.faq-item.open .faq-question .faq-icon { transform: rotate(45deg); }
.faq-answer {
  max-height: 0; overflow: hidden; transition: max-height 0.4s ease, padding 0.3s ease;
  padding: 0 1.5rem; background: rgba(0,0,0,0.15);
}
.faq-item.open .faq-answer {
  max-height: 600px; padding: 1.25rem 1.5rem;
}
.faq-answer p {
  font-size: 0.9rem; color: var(--text-secondary); line-height: 1.85; margin-bottom: 0.75rem;
}
.faq-answer p:last-child { margin-bottom: 0; }
.faq-answer strong { color: var(--text-primary); }
.faq-answer code {
  display: inline-block; padding: 0.15rem 0.5rem; border-radius: 4px;
  background: rgba(6,182,212,0.1); color: var(--accent-cyan);
  font-family: 'Courier New', monospace; font-size: 0.85rem;
}

/* ===== FOOTER ===== */
.footer {
  padding: 3rem 2rem; border-top: 1px solid var(--border-glass);
  text-align: center; margin-top: 4rem;
}
.footer-content { max-width: 1200px; margin: 0 auto; }
.footer p { font-size: 0.85rem; color: var(--text-muted); }
.footer .disclaimer {
  font-size: 0.75rem; color: var(--text-muted); margin-top: 1rem;
  padding: 1rem; background: rgba(244,63,94,0.05); border-radius: var(--radius-sm);
  border: 1px solid rgba(244,63,94,0.1);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .calculator-wrapper { grid-template-columns: 1fr; }
  .results-panel { position: static; }
  .features-grid { grid-template-columns: 1fr; }
  .geometry-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 1.5rem; }
  .nav-links { display: none; }
  .diagram-flow { flex-direction: column; }
  .flow-arrow { transform: rotate(90deg); }
  .heart-viz-container { flex-direction: column; }
  .calc-links-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .form-row { grid-template-columns: 1fr; }
  .hero h1 { font-size: 2rem; }
  .calc-card { padding: 1.5rem; }
  .diagram-container { padding: 1.5rem; }
  .param-grid { grid-template-columns: 1fr; }
  .content-section { padding: 3rem 1.25rem; }
  .faq-section { padding: 3rem 1.25rem; }
}
