* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: "Segoe UI", Arial, sans-serif;
  background: #fdf6e3;
  color: #2b1b1b;
}

/* Banner */
.banner {
  background: #660000;
  color: #ffd400;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 22px 32px;
}
.banner-logo img { height: 110px; }
.logo-placeholder {
  width: 120px;
  height: 110px;
  border-radius: 12px;
  background:
    radial-gradient(circle at 30% 35%, #ffd400 14px, transparent 15px),
    radial-gradient(circle at 65% 25%, #ffd400 10px, transparent 11px),
    radial-gradient(circle at 55% 70%, #ffd400 18px, transparent 19px),
    radial-gradient(circle at 25% 75%, #ffd400 9px, transparent 10px),
    #7a0f0f;
}
.banner-text h1 {
  font-size: 54px;
  letter-spacing: 2px;
  color: #ffd400;
  font-family: Georgia, serif;
}
.subtitle { font-size: 20px; font-style: italic; color: #ffdf4d; }
.issn { margin-top: 6px; font-weight: bold; color: #ffd400; }

/* Layout */
.layout { display: flex; min-height: calc(100vh - 154px); }

/* Sidebar */
.sidebar {
  width: 260px;
  background: #660000;
  color: #f5e9c9;
  padding: 20px 16px;
  flex-shrink: 0;
}
.app-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; }
.app-icon {
  width: 44px; height: 44px;
  background: #ffd400; color: #660000;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-weight: bold; font-size: 18px;
}
.app-title { font-weight: bold; font-size: 18px; }
.app-sub { font-size: 13px; opacity: .8; }
.menu-label { font-size: 12px; letter-spacing: 1px; opacity: .7; margin-bottom: 10px; }
.menu-item {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  color: #f5e9c9;
  border: none;
  padding: 12px 14px;
  margin-bottom: 6px;
  border-radius: 8px;
  font-size: 15px;
  cursor: pointer;
  transition: background .15s;
}
.menu-item:hover { background: rgba(255,255,255,.08); }
.menu-item.active { background: #8a2a2a; color: #fff; font-weight: 600; }

/* Content */
.content { flex: 1; padding: 34px 40px; }
.panel { display: none; }
.panel.active { display: block; }

.eyebrow { color: #8a1c1c; font-size: 13px; letter-spacing: 1px; font-weight: bold; }
.page-title { font-size: 40px; margin: 4px 0 8px; color: #2b1b1b; }
.based-on { color: #6b5b4b; margin-bottom: 22px; }

/* Grid */
.grid { display: grid; grid-template-columns: 2fr 1fr; gap: 22px; }

/* Snapshot */
.snapshot {
  background: #660000;
  color: #f7ecc9;
  border-radius: 16px;
  padding: 28px;
}
.pill {
  display: inline-block;
  background: #ffd400; color: #660000;
  border-radius: 20px;
  padding: 6px 16px;
  font-size: 12px; font-weight: bold;
  margin-bottom: 16px;
}
.snapshot-title { font-size: 30px; line-height: 1.15; margin-bottom: 14px; color: #fff; }
.snapshot-desc { line-height: 1.6; opacity: .92; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0; }
.chip {
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,212,0,.4);
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 14px;
}
.chip b { color: #ffd400; }
.explore { margin: 14px 0 8px; color: #ffd400; }
.findings { padding-left: 20px; line-height: 1.7; }

/* Side card */
.side-card {
  background: #fff;
  border: 1px solid #e6dcc0;
  border-radius: 16px;
  padding: 22px;
}
.side-card h4 { color: #660000; margin-bottom: 14px; font-size: 20px; }
.side-card dt { font-size: 11px; letter-spacing: 1px; color: #8a1c1c; font-weight: bold; margin-top: 12px; }
.side-card dd { font-size: 14px; }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr)); gap: 16px; }
.card {
  background: #fff;
  border: 1px solid #e6dcc0;
  border-left: 5px solid #660000;
  border-radius: 12px;
  padding: 18px;
}
.card h3 { color: #660000; margin-bottom: 8px; }
.card p { font-size: 14px; line-height: 1.5; color: #4a3b2b; }

/* Mind map */
.mindmap { text-align: center; }
.node.root {
  display: inline-block;
  background: #660000; color: #ffd400;
  padding: 14px 28px; border-radius: 30px;
  font-size: 20px; font-weight: bold; margin-bottom: 20px;
}
.branches { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px,1fr)); gap: 16px; }
.branch { background: #fff; border: 1px solid #e6dcc0; border-radius: 12px; overflow: hidden; }
.branch-head {
  background: #8a2a2a; color: #fff;
  padding: 12px; cursor: pointer; font-weight: 600;
}
.branch-body { display: none; padding: 12px 12px 12px 30px; text-align: left; line-height: 1.7; }
.branch.open .branch-body { display: block; }

/* Quiz */
.quiz .q { background: #fff; border: 1px solid #e6dcc0; border-radius: 12px; padding: 18px; margin-bottom: 16px; }
.quiz .q p { font-weight: 600; margin-bottom: 10px; color: #2b1b1b; }
.quiz button.opt {
  display: block; width: 100%; text-align: left;
  background: #f7efd8; border: 1px solid #e0d3af;
  border-radius: 8px; padding: 10px 14px; margin-bottom: 8px; cursor: pointer;
}
.quiz button.opt:hover { background: #f0e4c2; }
.quiz button.opt.correct { background: #cdeccd; border-color: #4c9a4c; }
.quiz button.opt.wrong { background: #f3cccc; border-color: #b34747; }
.score { font-size: 18px; font-weight: bold; color: #660000; }

@media (max-width: 820px) {
  .grid { grid-template-columns: 1fr; }
  .layout { flex-direction: column; }
  .sidebar { width: 100%; }
}
/* ===== General card blocks ===== */
.card-block {
  background: #fdfaf5;              /* crem/alb */
  border: 1px solid #ece3d6;
  border-radius: 10px;
  padding: 24px 28px;
  margin: 22px 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.card-block h2 {
  color: #660000;
  margin-top: 0;
  border-bottom: 2px solid #660000;
  padding-bottom: 8px;
}

/* ===== 1. Authors ===== */
.authors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
  margin: 16px 0;
}
.author-card {
  background: #fff;
  border: 1px solid #e0d4c3;
  border-left: 4px solid #660000;
  border-radius: 6px;
  padding: 8px 14px;
  font-size: 0.92rem;
  color: #3a2a2a;
}
.affil-toggle {
  background: #660000;
  color: #fff;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
  margin-top: 8px;
}
.affil-toggle:hover { background: #7d1a1a; }
.affiliations {
  margin-top: 14px;
  padding: 14px 18px;
  background: #fff;
  border: 1px dashed #d8c7b3;
  border-radius: 8px;
  font-size: 0.9rem;
  color: #4a4a4a;
}
.affiliations p { margin: 6px 0; }
.affil-note { font-style: italic; color: #8a7b6b; }
.hidden { display: none; }

/* ===== 2. Review Scope ===== */
.scope-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 16px;
}
.scope-card {
  background: #fff;
  border: 1px solid #ecdfce;
  border-top: 4px solid #660000;
  border-radius: 10px;
  padding: 18px 16px;
  text-align: center;
  transition: transform .15s, box-shadow .15s;
}
.scope-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 14px rgba(102,0,0,0.15);
}
.scope-icon { font-size: 2rem; margin-bottom: 8px; }
.scope-card h3 { color: #660000; margin: 6px 0; font-size: 1.02rem; }
.scope-card p { color: #5a5a5a; font-size: 0.86rem; margin: 0; }

/* ===== 3. Why matter ===== */
.matter-text {
  font-size: 1.02rem;
  line-height: 1.6;
  color: #3a2a2a;
}
.flow-diagram {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
}
.flow-item {
  background: #fff;
  border: 1px solid #e0d4c3;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 0.9rem;
  color: #3a2a2a;
}
.flow-plus, .flow-arrow { color: #660000; font-weight: bold; }
.flow-ai {
  background: #660000;
  color: #fff;
  border-color: #660000;
  font-weight: bold;
}
.flow-result {
  background: #f3e6d8;
  border-color: #d8c7b3;
  font-weight: bold;
}

/* ===== 4. Evidence Snapshot ===== */
.evidence-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 16px;
}
.evidence-card {
  background: #fff;
  border: 1px solid #ecdfce;
  border-radius: 12px;
  padding: 22px 16px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}
.evidence-value {
  font-size: 2.4rem;
  font-weight: 800;
  color: #660000;
  line-height: 1;
}
.evidence-metric {
  font-size: 1rem;
  font-weight: 600;
  color: #3a2a2a;
  margin: 6px 0;
}
.evidence-study { font-size: 0.85rem; color: #7a6a5a; }
.evidence-detail { font-size: 0.82rem; color: #9a8a7a; font-style: italic; }
.evidence-footnote {
  margin-top: 14px;
  font-size: 0.78rem;
  color: #8a7b6b;
  text-align: center;
}

/* ===== 5. Key Takeaway ===== */
.key-takeaway {
  background: #660000;
  color: #fff;
  border-radius: 10px;
  padding: 28px 32px;
  margin: 26px 0;
}
.key-takeaway h2 {
  margin-top: 0;
  letter-spacing: 1px;
  border-bottom: 2px solid rgba(255,255,255,0.4);
  padding-bottom: 8px;
}
.key-takeaway p {
  font-size: 1.05rem;
  line-height: 1.65;
  margin-bottom: 0;
}

/* ===== Responsive ===== */
@media (max-width: 720px) {
  .scope-grid, .evidence-grid { grid-template-columns: 1fr; }
  .flow-diagram { flex-direction: column; }
}
/* ===== Diagnostic Challenges ===== */
.challenge-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}
.challenge-card {
  border: 1px solid #e2d5d5;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.challenge-card:hover {
  border-color: #660000;
  box-shadow: 0 2px 10px rgba(102, 0, 0, 0.08);
}
.challenge-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: #faf6f6;
}
.challenge-num {
  background: #660000;
  color: #fff;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
}
.challenge-head h3 {
  margin: 0;
  flex: 1;
  font-size: 1.02rem;
  color: #3a2a2a;
}
.challenge-toggle {
  font-size: 1.5rem;
  color: #660000;
  font-weight: 700;
  line-height: 1;
}
.challenge-body {
  max-height: 0;
  overflow: hidden;
  padding: 0 18px;
  transition: max-height 0.3s ease, padding 0.3s ease;
}
.challenge-card.open .challenge-body {
  max-height: 300px;
  padding: 4px 18px 18px 18px;
}
.challenge-card.open .challenge-toggle {
  transform: rotate(45deg);
  transition: transform 0.2s;
}
.challenge-body p {
  margin: 8px 0;
  color: #4a4a4a;
  line-height: 1.5;
}
/* ===== AI Mind Map ===== */
.mindmap {
  margin-top: 20px;
}
.mm-center {
  background: #660000;
  color: #fff;
  font-size: 1.3rem;
  font-weight: 700;
  text-align: center;
  padding: 18px;
  border-radius: 12px;
  max-width: 260px;
  margin: 0 auto 24px auto;
  box-shadow: 0 4px 14px rgba(102, 0, 0, 0.25);
}
.mm-branches {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}
.mm-branch {
  border: 1px solid #e2d5d5;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.mm-branch:hover {
  border-color: #660000;
  box-shadow: 0 2px 10px rgba(102, 0, 0, 0.1);
}
.mm-node {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px;
  font-weight: 600;
  color: #3a2a2a;
  background: #faf6f6;

}
.mm-icon {
  font-size: 1.2rem;
}
.mm-plus {
  margin-left: auto;
  font-size: 1.4rem;
  font-weight: 700;
  color: #660000;
  line-height: 1;
}
.mm-children {
  max-height: 0;
  overflow: hidden;
  margin: 0;
  padding: 0 18px;
  list-style: none;
  transition: max-height 0.3s ease, padding 0.3s ease;
}
.mm-branch.open .mm-children {
  max-height: 320px;
  padding: 6px 18px 16px 18px;
}
.mm-branch.open .mm-plus {
  transform: rotate(45deg);
  transition: transform 0.2s;
}
.mm-children li {
  padding: 6px 0;
  border-bottom: 1px solid #f0e8e8;
  color: #4a4a4a;
}
.mm-children li:last-child {
  border-bottom: none;
}
/* Accent colors per branch */
.mm-data     { border-left: 4px solid #660000; }
.mm-methods  { border-left: 4px solid #a04040; }
.mm-goals    { border-left: 4px solid #7a5c00; }
.mm-challenges { border-left: 4px solid #8a3a3a; }

/* ===== Authors (Variant A) ===== */
.authors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
  margin: 16px 0;
}

.author-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid #ece2e2;
  border-radius: 12px;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.author-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(102, 0, 0, .12);
  border-color: #660000;
}

.author-avatar {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #660000;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: .5px;
}

.author-name {
  font-size: 14px;
  font-weight: 500;
  color: #2b2b2b;
  line-height: 1.3;
  white-space: normal;
  overflow: visible;
  word-break: break-word;
}
/* ============================================================
   DLB Detective Quiz
   ============================================================ */
.quiz-meta {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: .75rem; font-size: .9rem; color: #555;
}
.quiz-badge {
  background: #eef4ff; color: #2a5db0;
  padding: .25rem .7rem; border-radius: 999px; font-weight: 600;
}
.quiz-progress {
  height: 8px; background: #eee; border-radius: 999px;
  overflow: hidden; margin-bottom: 1.5rem;
}
.quiz-progress-bar {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, #4a90e2, #6dd5ed);
  transition: width .4s ease;
}
.quiz-question { font-size: 1.15rem; margin-bottom: 1.25rem; line-height: 1.5; }
.quiz-options { display: grid; gap: .6rem; }
.quiz-option {
  text-align: left; padding: .85rem 1rem;
  border: 2px solid #e2e8f0; background: #fafbfc;
  border-radius: 10px; cursor: pointer; font-size: 1rem;
  transition: all .2s ease; font-family: inherit;
}
.quiz-option:hover:not(:disabled) {
  border-color: #4a90e2; background: #f0f7ff; transform: translateY(-1px);
}
.quiz-option:disabled { cursor: default; }
.quiz-option.correct   { border-color: #22c55e; background: #ecfdf5; color: #065f46; }
.quiz-option.incorrect { border-color: #ef4444; background: #fef2f2; color: #991b1b; }

.quiz-feedback {
  margin-top: 1.25rem; padding: 1rem 1.25rem;
  border-radius: 10px; border-left: 4px solid;
}
.quiz-feedback.correct   { background: #ecfdf5; border-color: #22c55e; }
.quiz-feedback.incorrect { background: #fef2f2; border-color: #ef4444; }
.quiz-feedback p { margin: .4rem 0 0; color: #333; }

.quiz-actions { display: flex; justify-content: flex-end; margin-top: 1.25rem; }

.btn-primary {
  background: #4a90e2; color: #fff; border: none;
  padding: .7rem 1.4rem; border-radius: 10px; font-size: 1rem;
  cursor: pointer; transition: background .2s; font-family: inherit;
}
.btn-primary:hover { background: #357abd; }

.quiz-result { text-align: center; padding: 1.5rem 0; }
.score-circle {
  display: inline-flex; align-items: baseline; justify-content: center;
  width: 140px; height: 140px; border-radius: 50%;
  background: linear-gradient(135deg, #4a90e2, #6dd5ed);
  color: #fff; font-size: 2.8rem; font-weight: 700; margin: 1rem auto;
}
.score-circle small { font-size: 1.1rem; opacity: .85; margin-left: 2px; }
.quiz-badge-final {
  font-size: 1.2rem; font-weight: 600; color: #2a5db0; margin: .5rem 0 1rem;
}
.quiz-breakdown { text-align: left; max-width: 360px; margin: 0 auto; }
.quiz-breakdown ul { list-style: none; padding: 0; }
.quiz-breakdown li {
  padding: .4rem .6rem; margin: .25rem 0;
  background: #f7fafc; border-radius: 6px;
}
.hidden { display: none !important; }
/* ============================================================
   CASE SIMULATOR — Refined styling v2
   ============================================================ */

#simulator .sim-intro {
  color: #475569;
  margin-bottom: 1.75rem;
  font-size: 0.98rem;
  line-height: 1.6;
  max-width: 780px;
}

/* ---------- CONTAINER ---------- */
.sim-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.75rem;
  margin-bottom: 2rem;
}

@media (max-width: 900px) {
  .sim-container { grid-template-columns: 1fr; }
}

/* ---------- PANELS ---------- */
.sim-input,
.sim-output {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1.75rem 1.75rem 1.5rem;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
  transition: box-shadow 0.25s ease;
}

.sim-input:hover,
.sim-output:hover {
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
}

.sim-input h3,
.sim-output h3 {
  margin: 0 0 1.25rem;
  color: #0f172a;
  font-size: 1.1rem;
  font-weight: 700;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid #eff2f7;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.sim-input h3::before { content: "🧾"; }
.sim-output h3::before { content: "🧠"; }

.sim-input h4 {
  margin: 1.5rem 0 0.85rem;
  color: #475569;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  padding-left: 0.6rem;
  border-left: 3px solid #2563eb;
}

/* ---------- FIELDS ---------- */
.sim-field {
  margin-bottom: 1.1rem;
  display: flex;
  flex-direction: column;
}

.sim-field label {
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 0.45rem;
  font-size: 0.88rem;
  letter-spacing: 0.2px;
}

/* Range slider */
.sim-field input[type="range"] {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: #e2e8f0;
  accent-color: #2563eb;
  cursor: pointer;
  margin-top: 0.35rem;
}

#sim-age-val {
  display: inline-block;
  background: #eff6ff;
  color: #1d4ed8;
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.85rem;
  margin-left: 0.35rem;
}

/* Select */
.sim-field select {
  padding: 0.6rem 0.85rem;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  background: #fafbfc;
  font-size: 0.9rem;
  color: #1e293b;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2364748b' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  padding-right: 2.25rem;
}

.sim-field select:hover {
  border-color: #cbd5e1;
  background-color: #fff;
}

.sim-field select:focus {
  outline: none;
  border-color: #2563eb;
  background-color: #fff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

/* ---------- CHECKBOXES — custom cards ---------- */
.sim-checks {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch;
  gap: 0.7rem;
  margin: 0.5rem auto 1.5rem;
  max-width: 380px;      /* lățime confortabilă pentru coloană */
  width: 100%;
  padding: 0;
  list-style: none;
}

.sim-checks label {
  display: flex !important;
  align-items: center;
  gap: 0.7rem;
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  background: #fdfefe;
  cursor: pointer;
  font-size: 0.92rem;
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.sim-checks label:hover {
  border-color: #3b82f6;
  background: #f8fafc;
  transform: translateX(2px);
}

.sim-checks input[type="checkbox"] {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: #3b82f6;
}

/* Custom checkbox */
.sim-checks input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  min-width: 18px;
  border: 2px solid #cbd5e1;
  border-radius: 5px;
  background: #fff;
  cursor: pointer;
  position: relative;
  transition: all 0.18s ease;
  margin: 0;
}

.sim-checks input[type="checkbox"]:hover {
  border-color: #2563eb;
}

.sim-checks input[type="checkbox"]:checked {
  background: #2563eb;
  border-color: #2563eb;
}

.sim-checks input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 0px;
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.sim-checks label:has(input:checked) {
  background: #eff6ff;
  border-color: #2563eb;
  color: #1e3a8a;
  font-weight: 600;
}

/* ---------- ACTION BUTTONS ---------- */
.sim-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid #eff2f7;
  flex-wrap: wrap;
}

.sim-actions .btn-primary,
.sim-actions .btn-secondary {
  padding: 0.75rem 1.4rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  font-size: 0.9rem;
  font-family: inherit;
  transition: all 0.2s ease;
  letter-spacing: 0.2px;
}

.sim-actions .btn-primary {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  box-shadow: 0 3px 10px rgba(37, 99, 235, 0.28);
  flex: 1;
  min-width: 180px;
}

.sim-actions .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 14px rgba(37, 99, 235, 0.38);
}

.sim-actions .btn-primary:active {
  transform: translateY(0);
}

.sim-actions .btn-secondary {
  background: #f1f5f9;
  color: #475569;
  border: 1.5px solid #e2e8f0;
}

.sim-actions .btn-secondary:hover {
  background: #e2e8f0;
  color: #1e293b;
}

/* ---------- OUTPUT — GAUGE ---------- */
.sim-gauge {
  background: #f8fafc;
  padding: 1rem 1.25rem;
  border-radius: 10px;
  margin-bottom: 1.25rem;
  border: 1px solid #eff2f7;
}

.sim-gauge-label {
  font-size: 0.75rem;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  font-weight: 700;
  margin-bottom: 0.6rem;
}

.sim-gauge-bar {
  width: 100%;
  height: 22px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.sim-gauge-fill {
  height: 100%;
  width: 0%;
  background: #27ae60;
  border-radius: 999px;
  transition: width 0.7s cubic-bezier(0.4, 0, 0.2, 1), background 0.4s ease;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.08) inset;
}

.sim-gauge-value {
  text-align: right;
  font-size: 2rem;
  font-weight: 800;
  color: #0f172a;
  margin-top: 0.4rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: -1px;
}

.sim-gauge-value::after {
  font-size: 1.1rem;
  color: #64748b;
  font-weight: 500;
}

/* ---------- VERDICT ---------- */
.sim-verdict {
  background: linear-gradient(to right, #eff6ff, #f8fafc);
  border-left: 4px solid #2563eb;
  padding: 1rem 1.15rem;
  border-radius: 8px;
  font-size: 0.93rem;
  color: #1e293b;
  margin-bottom: 1.5rem;
  line-height: 1.55;
}

.sim-verdict strong { color: #1d4ed8; }

.sim-output h4 {
  color: #0f172a;
  font-size: 0.95rem;
  font-weight: 700;
  margin: 1.25rem 0 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.sim-output h4::before {
  content: "📊";
  font-size: 0.9rem;
}

/* ---------- XAI CONTRIBUTIONS ---------- */
.sim-contributions {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  max-height: 340px;
  overflow-y: auto;
  padding: 0.25rem 0.35rem 0.25rem 0;
}

.sim-contributions::-webkit-scrollbar { width: 6px; }
.sim-contributions::-webkit-scrollbar-track { background: #f1f5f9; border-radius: 3px; }
.sim-contributions::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
.sim-contributions::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

.sim-hint {
  color: #94a3b8;
  font-style: italic;
  font-size: 0.9rem;
  margin: 0;
  padding: 0.75rem;
  background: #f8fafc;
  border-radius: 6px;
  text-align: center;
}

.contrib-row {
  display: grid;
  grid-template-columns: 1.3fr 1.8fr 55px;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.82rem;
  padding: 0.35rem 0.5rem;
  border-radius: 6px;
  transition: background 0.15s ease;
}

.contrib-row:hover { background: #f8fafc; }

.contrib-label {
  color: #334155;
  font-weight: 500;
  line-height: 1.3;
}

.contrib-bar-wrap {
  background: #f1f5f9;
  height: 12px;
  border-radius: 6px;
  overflow: hidden;
}

.contrib-bar {
  height: 100%;
  border-radius: 6px;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.contrib-bar.contrib-pos {
  background: linear-gradient(90deg, #fbbf24, #ef4444);
}
.contrib-bar.contrib-neg {
  background: linear-gradient(90deg, #93c5fd, #2563eb);
}

.contrib-weight {
  text-align: right;
  font-weight: 700;
  color: #0f172a;
  font-family: 'SF Mono', 'Consolas', monospace;
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
}

/* ---------- DISCLAIMER ---------- */
.sim-disclaimer {
  margin-top: 1.5rem;
  padding: 0.85rem 1rem;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b;
  border-radius: 8px;
  font-size: 0.82rem;
  color: #78350f;
  line-height: 1.5;
}

/* ---------- KEY TAKEAWAY ---------- */
#simulator .key-takeaway {
  background: linear-gradient(135deg, #0f172a, #1e3a8a);
  color: #fff;
  padding: 1.75rem 2rem;
  border-radius: 14px;
  margin-top: 2rem;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.15);
}

#simulator .key-takeaway h2 {
  color: #fbbf24;
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 2px;
}

#simulator .key-takeaway p {
  margin: 0;
  line-height: 1.7;
  font-size: 0.98rem;
  color: #e2e8f0;
}

#simulator .key-takeaway em {
  color: #fbbf24;
  font-style: normal;
  font-weight: 700;
}
/* ===== Alias-uri pentru HTML actual ===== */
.sim-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.75rem;
  margin-bottom: 2rem;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
}

@media (max-width: 900px) {
  .sim-grid { grid-template-columns: 1fr; }
}

.sim-inputs {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1.75rem;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
}

.sim-inputs h3 {
  margin: 1.25rem 0 0.85rem;
  color: #0f172a;
  font-size: 1rem;
  font-weight: 700;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #eff2f7;
}
.sim-inputs h3:first-child { margin-top: 0; }

/* Checkbox-uri individuale .sim-check → același stil ca .sim-checks label */
.sim-check {
  display: flex !important;
  align-items: center;
  gap: 0.7rem;
  width: 100%;
  max-width: 380px;
  margin: 0 auto 0.7rem;
  padding: 0.75rem 1rem;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  background: #fdfefe;
  cursor: pointer;
  font-size: 0.92rem;
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.sim-check:hover {
  border-color: #3b82f6;
  background: #f8fafc;
  transform: translateX(2px);
}

.sim-check input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  min-width: 18px;
  border: 2px solid #cbd5e1;
  border-radius: 5px;
  background: #fff;
  cursor: pointer;
  position: relative;
  transition: all 0.18s ease;
  margin: 0;
}

.sim-check input[type="checkbox"]:checked {
  background: #2563eb;
  border-color: #2563eb;
}

.sim-check input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 0;
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.sim-check:has(input:checked) {
  background: #eff6ff;
  border-color: #2563eb;
  color: #1e3a8a;
  font-weight: 600;
}
/* ============================================
   INTERACTIVE MIND MAP
   ============================================ */
.mm-toolbar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px 12px 0 0;
  border-bottom: none;
  flex-wrap: wrap;
}

.mm-tool-btn {
  padding: 0.45rem 0.85rem;
  background: #fff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
  transition: all 0.15s ease;
}
.mm-tool-btn:hover {
  background: #2563eb;
  color: #fff;
  border-color: #2563eb;
  transform: translateY(-1px);
}

.mm-hint {
  margin-left: auto;
  font-size: 0.82rem;
  color: #64748b;
  font-style: italic;
}

.mm-workspace {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 0;
  border: 1px solid #e2e8f0;
  border-radius: 0 0 12px 12px;
  overflow: hidden;
  background: #fff;
  min-height: 600px;
}

.mm-canvas {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 25% 25%, #eff6ff 0%, transparent 50%),
    radial-gradient(circle at 75% 75%, #fef3f2 0%, transparent 50%),
    #fafbfc;
  cursor: grab;
  min-height: 600px;
}
.mm-canvas.mm-dragging { cursor: grabbing; }

.mm-svg {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  transform-origin: 0 0;
  transition: transform 0.05s linear;
}

.mm-nodes {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  transform-origin: 0 0;
  transition: transform 0.05s linear;
}

.mm-node {
  position: absolute;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  background: #fff;
  border: 2px solid var(--node-color, #64748b);
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  color: #0f172a;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  transition: all 0.18s ease;
  white-space: nowrap;
  font-family: inherit;
}

.mm-node:hover {
  transform: translate(-50%, -50%) scale(1.08);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.18);
  z-index: 10;
}

.mm-node-root {
  padding: 1.2rem 1.6rem;
  font-size: 1.1rem;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 8px 28px rgba(37, 99, 235, 0.4);
}
.mm-node-root:hover { transform: translate(-50%, -50%) scale(1.1); }

.mm-node-branch {
  background: #fff;
  color: var(--node-color);
}
.mm-node-branch:hover {
  background: var(--node-color);
  color: #fff;
}

.mm-node-sub {
  padding: 0.4rem 0.75rem;
  font-size: 0.78rem;
  border-width: 1.5px;
  border-style: dashed;
  background: #fdfefe;
  color: #475569;
  opacity: 0.92;
}
.mm-node-sub:hover {
  border-style: solid;
  background: var(--node-color);
  color: #fff;
}

.mm-node-selected {
  outline: 3px solid var(--node-color);
  outline-offset: 3px;
}

.mm-node-icon { font-size: 1.05em; }
.mm-node-caret {
  margin-left: 0.3rem;
  padding: 0 0.4rem;
  background: rgba(0,0,0,0.08);
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.85em;
}
.mm-node-root .mm-node-caret { background: rgba(255,255,255,0.25); }

/* Details panel */
.mm-panel {
  background: #f8fafc;
  border-left: 1px solid #e2e8f0;
  padding: 1.5rem;
  overflow-y: auto;
  max-height: 700px;
}

.mm-panel-empty {
  text-align: center;
  padding: 3rem 1rem;
  color: #64748b;
}
.mm-panel-icon {
  font-size: 3rem;
  margin-bottom: 0.75rem;
  opacity: 0.6;
}
/* ============================================================
   VENN DIAGRAM — DLB at the Crossroads
   ============================================================ */

#venn .lead {
  max-width: 780px;
  color: #475569;
  font-size: 1.05rem;
  line-height: 1.6;
  margin-bottom: 1.75rem;
}

/* ---------- Toolbar ---------- */
.venn-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid #e2e8f0;
}

.venn-tab {
  padding: 0.6rem 1.2rem;
  border-radius: 10px;
  border: 2px solid transparent;
  background: #f1f5f9;
  color: #475569;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.venn-tab:hover {
  background: #e2e8f0;
  transform: translateY(-1px);
}
.venn-tab-active {
  background: linear-gradient(135deg, #2563eb, #6366f1);
  color: #fff;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.venn-btn-ghost {
  padding: 0.55rem 1rem;
  border-radius: 8px;
  border: 1.5px solid #cbd5e1;
  background: #fff;
  color: #475569;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.venn-btn-ghost:hover {
  border-color: #6366f1;
  color: #6366f1;
  background: #eef2ff;
}

/* ---------- Workspace layout ---------- */
.venn-workspace {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 2rem;
  align-items: start;
}
@media (max-width: 960px) {
  .venn-workspace { grid-template-columns: 1fr; }
}

/* ---------- Canvas ---------- */
.venn-canvas-wrap {
  position: relative;
  background: linear-gradient(180deg, #ffffff, #f8fafc);
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1.25rem;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.venn-svg {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
}

/* ---------- Cercurile de bază ---------- */
.venn-circles circle {
  mix-blend-mode: multiply;
  transition: filter 0.3s ease;
}
.venn-canvas-wrap:hover .venn-circles circle {
  filter: saturate(1.1);
}

/* ---------- Etichetele mari ---------- */
.venn-label {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  fill: #1e293b;
  pointer-events: none;
  text-anchor: middle;
}
.venn-label-ad    { fill: #1e40af; }
.venn-label-pd    { fill: #047857; }
.venn-label-psych { fill: #b45309; }

/* ---------- Marker central DLB ---------- */
.venn-center-circle {
  fill: #fff;
  stroke: #6366f1;
  stroke-width: 2.5;
  filter: drop-shadow(0 2px 6px rgba(99, 102, 241, 0.4));
}
.venn-center-text {
  font-weight: 800;
  font-size: 0.75rem;
  fill: #6366f1;
  text-anchor: middle;
  pointer-events: none;
  letter-spacing: 0.5px;
}

/* ---------- Hit zones (click regions) ---------- */
.venn-hit {
  transition: fill 0.2s ease;
}
.venn-hit:hover {
  fill: rgba(99, 102, 241, 0.15) !important;
}

/* ---------- Chip-urile de simptome (SVG) ---------- */
.venn-chip {
  transition: opacity 0.25s ease, transform 0.25s ease;
  pointer-events: none;
}
.venn-chip-bg {
  stroke: #fff;
  stroke-width: 1;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.15));
}
.venn-chip-text {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 8.5px;
  font-weight: 600;
  fill: #fff;
  pointer-events: none;
}
.venn-chip-dim {
  opacity: 0.2;
}

/* Culori per regiune */
.venn-chip-ad       { fill: #3b82f6; }
.venn-chip-pd       { fill: #10b981; }
.venn-chip-psych    { fill: #f59e0b; }
.venn-chip-ad_pd    { fill: #8b5cf6; }
.venn-chip-ad_psych { fill: #ec4899; }
.venn-chip-pd_psych { fill: #14b8a6; }
.venn-chip-dlb      { fill: #6366f1; }

/* ---------- Tooltip ---------- */
.venn-tooltip {
  position: absolute;
  z-index: 100;
  background: #1e293b;
  color: #fff;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  font-size: 0.85rem;
  line-height: 1.4;
  pointer-events: none;
  max-width: 260px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.25);
  animation: venn-fade-in 0.15s ease;
}
.venn-tooltip-title {
  font-weight: 700;
  margin-bottom: 0.25rem;
  color: #a5b4fc;
}
.venn-tooltip-body {
  font-size: 0.8rem;
  color: #e2e8f0;
}
@keyframes venn-fade-in {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Legendă ---------- */
.venn-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
  font-size: 0.8rem;
  color: #475569;
}
.venn-legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 500;
}
.venn-legend-item .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}
.dot-ad    { background: #3b82f6; }
.dot-pd    { background: #10b981; }
.dot-psych { background: #f59e0b; }
.dot-dlb   { background: #6366f1; }
.venn-legend-item .count {
  background: #f1f5f9;
  padding: 1px 7px;
  border-radius: 10px;
  font-weight: 700;
  color: #1e293b;
  font-size: 0.75rem;
}

/* ---------- Panoul lateral ---------- */
.venn-panel {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
  min-height: 400px;
}
.venn-panel h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  color: #1e293b;
}
.venn-panel-empty {
  text-align: center;
  padding: 1rem 0;
}
.venn-panel-icon {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}
.venn-panel-empty p {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 1.25rem;
}

/* Quick legend chips */
.venn-quick-legend {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: left;
}
.venn-quick-legend li {
  padding: 0.4rem 0;
  font-size: 0.85rem;
  color: #475569;
  border-bottom: 1px solid #f1f5f9;
}
.venn-quick-legend li:last-child { border-bottom: none; }

.chip {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 5px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  margin-right: 6px;
  letter-spacing: 0.3px;
}
.chip-ad    { background: #3b82f6; }
.chip-pd    { background: #10b981; }
.chip-psych { background: #f59e0b; }
.chip-dlb   { background: #6366f1; }

/* ---------- Detail view (după click) ---------- */
.venn-detail-badge {
  display: inline-block;
  padding: 0.4rem 0.85rem;
  border-radius: 8px;
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
}
.venn-detail-desc {
  color: #475569;
  line-height: 1.55;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}
.venn-detail h4 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #64748b;
  margin: 1rem 0 0.5rem;
}
.venn-detail-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}
.venn-detail-list li {
  padding: 0.4rem 0.6rem;
  background: #f8fafc;
  border-radius: 6px;
  margin-bottom: 0.35rem;
  font-size: 0.85rem;
  color: #334155;
}
.venn-detail-list li.muted {
  color: #94a3b8;
  font-style: italic;
  background: transparent;
}

/* ---------- Differential mode ---------- */
.venn-hint-sm {
  font-size: 0.85rem;
  color: #64748b;
  margin-bottom: 1rem;
}
.venn-checklist {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}
.venn-check {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.75rem;
  border-radius: 8px;
  background: #f8fafc;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  font-size: 0.88rem;
  color: #334155;
}
.venn-check:hover {
  border-color: #cbd5e1;
  background: #fff;
}
.venn-check input {
  accent-color: #6366f1;
  cursor: pointer;
}
.venn-check:has(input:checked) {
  background: #eef2ff;
  border-color: #6366f1;
  color: #1e293b;
  font-weight: 600;
}

.venn-diff-result {
  margin-top: 1rem;
}
.venn-diff-empty {
  padding: 1rem;
  background: #f8fafc;
  border-radius: 8px;
  color: #94a3b8;
  font-size: 0.85rem;
  text-align: center;
  font-style: italic;
}
.venn-diff-match {
  padding: 1rem;
  background: #f8fafc;
  border-radius: 8px;
  color: #1e293b;
  font-size: 0.9rem;
  line-height: 1.5;
  animation: venn-fade-in 0.25s ease;
}
.venn-diff-match strong {
  display: block;
  margin-bottom: 0.4rem;
  color: #1e293b;
  font-size: 0.95rem;
}
.venn-diff-match p {
  margin: 0;
  color: #475569;
  font-size: 0.82rem;
}
/* Radar chart */

.overview-insight-card {
  margin-top: 2rem;
  padding: 1.5rem;
  border: 1px solid #e7e1d8;
  border-radius: 18px;
  background: #fffdf9;
  box-shadow: 0 8px 24px rgba(61, 42, 24, 0.08);
}

.insight-header {
  margin-bottom: 1.25rem;
}

.insight-header h2 {
  margin: 0.3rem 0;
  color: #7f1d1d;
}

.insight-sub {
  margin: 0;
  color: #625a53;
  line-height: 1.5;
}

.radar-disclaimer {
  margin-top: 0.7rem;
  padding: 0.6rem 0.8rem;
  border-left: 3px solid #f59e0b;
  background: #fffbeb;
  color: #78520b;
  font-size: 0.8rem;
  line-height: 1.4;
}

.insight-body {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  align-items: center;
}

.radar-toggle {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.radar-tab {
  border: 1px solid #d8d2ca;
  border-radius: 999px;
  padding: 0.5rem 0.9rem;
  background: white;
  color: #514943;
  cursor: pointer;
  font: inherit;
}

.radar-tab.active {
  background: #4f46e5;
  border-color: #4f46e5;
  color: white;
}

.radar-canvas-wrap {
  position: relative;
  height: 390px;
}

.radar-canvas-wrap canvas {
  width: 100% !important;
  height: 100% !important;
}

.insight-legend {
  padding: 1.2rem;
  border: 1px solid #e5e1ff;
  border-radius: 14px;
  background: #f7f5ff;
}

.insight-legend h4 {
  margin-top: 0;
  color: #312e81;
}

.radar-stats {
  display: grid;
  gap: 0.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.radar-stats li {
  display: flex;
  justify-content: space-between;
  padding: 0.45rem 0;
  border-bottom: 1px solid #e5e1ff;
  color: #4338ca;
}

.radar-stat-value {
  font-weight: bold;
  color: #1f2937;
}

@media (max-width: 760px) {
  .insight-body {
    grid-template-columns: 1fr;
  }

  .radar-canvas-wrap {
    height: 330px;
  }
}
/* ============================================================
   OVERVIEW HERO — BRAIN / DLB
   ============================================================ */

.overview-hero {
  position: relative;
  min-height: 485px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.08fr .92fr;
  gap: 28px;
  align-items: center;
  padding: 54px;
  border-radius: 28px;
  color: #fff;
  background:
    radial-gradient(circle at 82% 28%, rgba(99, 102, 241, .48), transparent 30%),
    linear-gradient(135deg, #350000 0%, #660000 46%, #241044 100%);
  box-shadow: 0 22px 55px rgba(72, 18, 18, .25);
}

.overview-hero-content {
  position: relative;
  z-index: 2;
  max-width: 650px;
}

.overview-hero-kicker {
  display: inline-flex;
  padding: 8px 13px;
  margin-bottom: 18px;
  border: 1px solid rgba(255, 212, 0, .45);
  border-radius: 999px;
  color: #ffe36b;
  background: rgba(255, 212, 0, .09);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .12em;
}

.overview-hero-title {
  margin: 0;
  color: #fff;
  font-size: clamp(2.4rem, 5vw, 4.4rem);
  line-height: .98;
  letter-spacing: -.055em;
}

.overview-hero-title span {
  display: block;
  margin-top: 8px;
  color: #ffd400;
}

.overview-hero-text {
  max-width: 600px;
  margin: 24px 0;
  color: #f5e9c9;
  font-size: 1.04rem;
  line-height: 1.7;
}

.overview-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.overview-hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 17px;
  border-radius: 12px;
  font: inherit;
  font-size: .88rem;
  font-weight: 800;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.overview-hero-btn:hover {
  transform: translateY(-3px);
}

.overview-hero-btn-primary {
  border: 1px solid #ffd400;
  color: #660000;
  background: #ffd400;
  box-shadow: 0 8px 20px rgba(255, 212, 0, .2);
}

.overview-hero-btn-secondary {
  border: 1px solid rgba(255, 255, 255, .28);
  color: #fff;
  background: rgba(255, 255, 255, .1);
}

.overview-hero-note {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 21px;
  color: #d8c7b3;
  font-size: .8rem;
}

.overview-pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 7px rgba(74, 222, 128, .12);
}

/* Hero graphic */

.overview-hero-visual {
  position: relative;
  min-height: 360px;
}

.hero-brain-core {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 3;
  display: flex;
  width: 172px;
  height: 172px;
  transform: translate(-50%, -50%);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 212, 0, .75);
  border-radius: 50%;
  background: radial-gradient(circle, #7a0f0f, #280000);
  box-shadow:
    0 0 28px rgba(255, 212, 0, .4),
    0 0 90px rgba(255, 212, 0, .16);
  animation: overview-core-float 4s ease-in-out infinite;
}

.hero-brain-icon {
  font-size: 3.3rem;
  line-height: 1;
  margin-bottom: 7px;
}

.hero-brain-core strong {
  color: #ffd400;
  letter-spacing: .16em;
}

.hero-brain-core small {
  margin-top: 4px;
  color: #f5e9c9;
  font-size: .7rem;
}

.hero-orbit {
  position: absolute;
  top: 50%;
  left: 50%;
  border: 1px solid rgba(255, 212, 0, .27);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.hero-orbit-large {
  width: 340px;
  height: 340px;
  animation: overview-orbit 20s linear infinite;
}

.hero-orbit-small {
  width: 245px;
  height: 245px;
  border-color: rgba(165, 180, 252, .35);
  animation: overview-orbit 13s linear infinite reverse;
}

.hero-data-card {
  position: absolute;
  z-index: 4;
  display: flex;
  min-width: 130px;
  padding: 10px 13px;
  flex-direction: column;
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 12px;
  background: rgba(33, 15, 36, .78);
  box-shadow: 0 10px 25px rgba(0, 0, 0, .2);
  backdrop-filter: blur(10px);
  animation: overview-data-float 5s ease-in-out infinite;
}

.hero-data-card strong {
  color: #ffd400;
  font-size: .8rem;
}

.hero-data-card span {
  margin-top: 3px;
  color: #eadfcd;
  font-size: .7rem;
}

.hero-data-clinical {
  top: 5%;
  left: 0;
}

.hero-data-imaging {
  top: 4%;
  right: 0;
  animation-delay: .7s;
}

.hero-data-eeg {
  bottom: 7%;
  left: 4%;
  animation-delay: 1.3s;
}

.hero-data-biomarkers {
  right: 0;
  bottom: 8%;
  animation-delay: 1.8s;
}

.hero-glow {
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  filter: blur(50px);
  opacity: .2;
  pointer-events: none;
}

.hero-glow-one {
  top: -130px;
  right: 20%;
  background: #ffd400;
}

.hero-glow-two {
  right: -130px;
  bottom: -130px;
  background: #818cf8;
}

/* Metrics */

.overview-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 18px 0 28px;
}

.overview-metric-card {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 10px;
  padding: 17px;
  border: 1px solid #e6dcc0;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 7px 20px rgba(102, 0, 0, .06);
}

.overview-metric-icon {
  grid-row: span 2;
  font-size: 1.45rem;
}

.overview-metric-card strong {
  color: #660000;
  font-size: 1.6rem;
  line-height: 1;
}

.overview-metric-card > span:last-child {
  margin-top: 4px;
  color: #756858;
  font-size: .75rem;
}

/* Interactive intro */

.overview-intro-grid {
  display: grid;
  grid-template-columns: 1.4fr .8fr;
  gap: 18px;
}

.overview-intro-card,
.overview-message-card {
  padding: 27px;
  border: 1px solid #e6dcc0;
  border-radius: 20px;
  background: #fff;
}

.overview-intro-card h2 {
  margin: 14px 0 12px;
  color: #660000;
  font-size: 2rem;
  line-height: 1.1;
}

.overview-intro-card > p {
  color: #5b4c40;
  line-height: 1.65;
}

.overview-flow {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 23px;
}

.overview-flow-node {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 11px;
  border: 1px solid #dfd3c1;
  border-radius: 11px;
  color: #493c33;
  background: #fffaf1;
  font: inherit;
  font-size: .8rem;
  cursor: pointer;
  transition: .2s ease;
}

.overview-flow-node:hover,
.overview-flow-node.active {
  border-color: #a04040;
  color: #660000;
  background: #f8e8d7;
  transform: translateY(-2px);
}

.overview-flow-ai {
  color: #fff !important;
  border-color: #660000 !important;
  background: #660000 !important;
}

.overview-flow-symbol {
  color: #8a1c1c;
  font-weight: 900;
}

.overview-flow-description {
  min-height: 48px;
  margin-top: 17px;
  padding: 12px 14px;
  border-left: 3px solid #ffd400;
  border-radius: 4px;
  color: #5b4c40;
  background: #fffaf1;
  font-size: .86rem;
  line-height: 1.5;
}

.overview-message-card {
  color: #fff;
  background: linear-gradient(145deg, #660000, #32104d);
}

.overview-message-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.overview-message-card .pill {
  color: #660000;
  background: #ffd400;
}

.overview-active-label {
  color: #86efac;
  font-size: .72rem;
  font-weight: 800;
}

.overview-message-icon {
  margin: 25px 0 8px;
  font-size: 3rem;
}

.overview-message-card h3 {
  margin: 0;
  color: #fff;
  font-size: 1.8rem;
}

.overview-message-card p {
  color: #f4e4d2;
  line-height: 1.6;
}

.overview-text-link {
  padding: 0;
  border: 0;
  color: #ffd400;
  background: transparent;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

/* Animations */

@keyframes overview-core-float {
  0%, 100% {
    transform: translate(-50%, -50%);
  }
  50% {
    transform: translate(-50%, -56%);
  }
}

@keyframes overview-data-float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@keyframes overview-orbit {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Responsive */

@media (max-width: 900px) {
  .overview-hero {
    grid-template-columns: 1fr;
    padding: 35px 25px;
  }

  .overview-hero-visual {
    min-height: 330px;
  }

  .overview-intro-grid {
    grid-template-columns: 1fr;
  }

  .overview-metrics {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .overview-hero-title {
    font-size: 2.6rem;
  }

  .overview-hero-actions {
    flex-direction: column;
  }

  .overview-hero-btn {
    width: 100%;
    justify-content: center;
  }

  .overview-metrics {
    grid-template-columns: 1fr;
  }

  .overview-flow-symbol {
    display: none;
  }

  .hero-data-card {
    min-width: 105px;
    padding: 8px;
  }

  .hero-data-card strong {
    font-size: .7rem;
  }

  .hero-data-card span {
    font-size: .6rem;
  }
}
