/* ============================================
   BALLARI NEURO CENTRE — Shared Design System
   ballarineurocentre.com Patient Information Pages
   ============================================ */

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

/* ---------- CSS Variables ---------- */
:root {
  --primary: #2563EB;
  --primary-dark: #1D4ED8;
  --primary-light: #60A5FA;
  --accent: #06B6D4;
  --accent-dark: #0891B2;
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --purple: #8B5CF6;

  --bg: #F0F4F8;
  --bg-card: #FFFFFF;
  --bg-glass: rgba(255, 255, 255, 0.75);
  --bg-section-alt: #EEF2FF;
  --text: #1E293B;
  --text-secondary: #475569;
  --text-muted: #94A3B8;
  --border: #E2E8F0;

  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.10);
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);

  --max-width: 900px;
  --header-h: 70px;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

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

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}

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

/* ---------- Typography ---------- */
h1,
h2,
h3,
h4,
h5 {
  font-family: 'Outfit', sans-serif;
  line-height: 1.25;
  font-weight: 700;
}

h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
}

h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
}

h3 {
  font-size: clamp(1.15rem, 2.5vw, 1.5rem);
}

h4 {
  font-size: 1.1rem;
}

p {
  margin-bottom: 1rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  height: var(--header-h);
  display: flex;
  align-items: center;
  padding: 0 1.5rem;
}

.site-header .inner {
  margin: 0;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header .logo {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-header .logo .icon {
  font-size: 1.5rem;
}

.site-header nav a {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-xs);
  transition: var(--transition);
}

.site-header nav a:hover {
  color: var(--primary);
  background: var(--bg-section-alt);
}

/* ---------- Hero Section ---------- */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, #7C3AED 60%, var(--accent) 100%);
  color: #fff;
  padding: 4rem 1.5rem 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -30%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
  border-radius: 50%;
}

.hero h1 {
  margin-bottom: 1rem;
  font-weight: 800;
}

.hero .subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  opacity: 0.92;
  max-width: 600px;
  margin: 0 auto 1.5rem;
  font-weight: 300;
}

.hero .badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.18);
  padding: 0.35rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 500;
  backdrop-filter: blur(8px);
}

/* ---------- Page Container ---------- */
.page-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

/* ---------- Section ---------- */
.section {
  margin-bottom: 3rem;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.25rem;
  color: var(--primary-dark);
}

.section-title .icon {
  font-size: 1.5rem;
}

/* ---------- Cards ---------- */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  transition: var(--transition);
  margin-bottom: 1.25rem;
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

/* Card color variants */
.card-blue .card-icon {
  background: #EFF6FF;
  color: var(--primary);
}

.card-green .card-icon {
  background: #ECFDF5;
  color: var(--success);
}

.card-purple .card-icon {
  background: #F3E8FF;
  color: var(--purple);
}

.card-orange .card-icon {
  background: #FFF7ED;
  color: #EA580C;
}

.card-cyan .card-icon {
  background: #ECFEFF;
  color: var(--accent-dark);
}

.card-red .card-icon {
  background: #FEF2F2;
  color: var(--danger);
}

/* ---------- Info Box / Callout ---------- */
.callout {
  border-left: 4px solid var(--primary);
  background: var(--bg-section-alt);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
}

.callout.warning {
  border-left-color: var(--warning);
  background: #FFFBEB;
}

.callout.danger {
  border-left-color: var(--danger);
  background: #FEF2F2;
}

.callout.success {
  border-left-color: var(--success);
  background: #ECFDF5;
}

.callout .callout-title {
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  margin-bottom: 0.3rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* ---------- Analogy Box ---------- */
.analogy-box {
  background: linear-gradient(135deg, #EEF2FF 0%, #F0F9FF 100%);
  border: 1px solid #C7D2FE;
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.analogy-box::before {
  content: '💡';
  position: absolute;
  top: -12px;
  left: 16px;
  font-size: 1.4rem;
  background: var(--bg);
  padding: 0 4px;
}

.analogy-box .analogy-title {
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  color: var(--primary-dark);
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

/* ---------- Stats Row ---------- */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  text-align: center;
  padding: 1.25rem 1rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.stat-card .num {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
}

.stat-card .label {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-top: 0.4rem;
}

/* ---------- Flowchart ---------- */
.flowchart {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 2rem 0;
}

.flow-step {
  background: var(--bg-card);
  border: 2px solid var(--primary-light);
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
  max-width: 400px;
  width: 100%;
  text-align: center;
  font-weight: 500;
  position: relative;
  box-shadow: var(--shadow);
}

.flow-step.highlight {
  background: linear-gradient(135deg, var(--primary) 0%, #7C3AED 100%);
  color: #fff;
  border-color: transparent;
}

.flow-arrow {
  font-size: 1.5rem;
  color: var(--primary);
  margin: 0.25rem 0;
}

.flow-decision {
  background: #FFF7ED;
  border: 2px solid #FDBA74;
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
  max-width: 400px;
  width: 100%;
  text-align: center;
  font-weight: 600;
  transform: rotate(0deg);
  box-shadow: var(--shadow);
}

.flow-branches {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  width: 100%;
  max-width: 500px;
}

.flow-branch {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  text-align: center;
  font-size: 0.9rem;
  box-shadow: var(--shadow);
}

.flow-branch.yes {
  border-color: var(--success);
}

.flow-branch.no {
  border-color: var(--danger);
}

.flow-branch-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.3rem;
}

.flow-branch.yes .flow-branch-label {
  color: var(--success);
}

.flow-branch.no .flow-branch-label {
  color: var(--danger);
}

/* ---------- FAQ Accordion ---------- */
.faq-list {
  margin-bottom: 2rem;
}

.faq-item {
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  margin-bottom: 0.75rem;
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  padding: 1.1rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: var(--transition);
}

.faq-question:hover {
  color: var(--primary);
}

.faq-question .arrow {
  font-size: 1.2rem;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-item.open .faq-question .arrow {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 800px;
  padding: 0 1.5rem 1.25rem;
}

.faq-answer p {
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

/* ---------- Symptom/Check List ---------- */
.check-list {
  list-style: none;
  margin-bottom: 1.5rem;
}

.check-list li {
  padding: 0.5rem 0 0.5rem 2rem;
  position: relative;
  border-bottom: 1px solid var(--border);
}

.check-list li:last-child {
  border-bottom: none;
}

.check-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--success);
  font-weight: 700;
  font-size: 1.1rem;
}

.warning-list li::before {
  content: '⚠️';
  font-size: 0.9rem;
}

.cross-list li::before {
  content: '✗';
  color: var(--danger);
}

/* ---------- Do / Don't Columns ---------- */
.do-dont {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

.do-col,
.dont-col {
  border-radius: var(--radius);
  padding: 1.25rem;
}

.do-col {
  background: #ECFDF5;
  border: 1px solid #A7F3D0;
}

.dont-col {
  background: #FEF2F2;
  border: 1px solid #FECACA;
}

.do-col h4 {
  color: #059669;
}

.dont-col h4 {
  color: #DC2626;
}

.do-col ul,
.dont-col ul {
  list-style: none;
  margin-top: 0.5rem;
}

.do-col li,
.dont-col li {
  padding: 0.35rem 0;
  font-size: 0.92rem;
}

.do-col li::before {
  content: '✅ ';
}

.dont-col li::before {
  content: '❌ ';
}

/* ---------- Grid Layout ---------- */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

/* ---------- Timeline ---------- */
.timeline {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 2rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--primary-light);
}

.timeline-item {
  position: relative;
  margin-bottom: 1.5rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -2rem;
  top: 6px;
  width: 16px;
  height: 16px;
  background: var(--primary);
  border-radius: 50%;
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 2px var(--primary-light);
}

.timeline-item h4 {
  color: var(--primary-dark);
  margin-bottom: 0.25rem;
}

.timeline-item p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin-bottom: 0;
}

/* ---------- Pill Tags ---------- */
.pill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 500;
  background: var(--bg-section-alt);
  color: var(--primary-dark);
  border: 1px solid #C7D2FE;
}

/* ---------- Visual Diagram Placeholder ---------- */
.visual-diagram {
  background: linear-gradient(135deg, #F8FAFC 0%, #EEF2FF 100%);
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  margin-bottom: 1.5rem;
  text-align: center;
}

.visual-diagram .diagram-icon {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}

.visual-diagram p {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* ---------- Table ---------- */
.info-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
  font-size: 0.92rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.info-table thead th {
  background: var(--primary);
  color: #fff;
  padding: 0.85rem 1rem;
  text-align: left;
  font-weight: 600;
  font-family: 'Outfit', sans-serif;
}

.info-table tbody td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
}

.info-table tbody tr:nth-child(even) {
  background: #F8FAFC;
}

.info-table tbody tr:hover {
  background: var(--bg-section-alt);
}

/* ---------- CTA Section ---------- */
.cta-section {
  background: linear-gradient(135deg, var(--primary) 0%, #7C3AED 100%);
  color: #fff;
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  margin-top: 2.5rem;
}

.cta-section h3 {
  margin-bottom: 0.75rem;
  color: #fff;
}

.cta-section p {
  opacity: 0.9;
  margin-bottom: 1rem;
}

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #fff;
  color: var(--primary-dark);
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  transition: var(--transition);
  text-decoration: none;
}

.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: var(--primary-dark);
}

/* ---------- Footer ---------- */
.site-footer {
  background: #1E293B;
  color: #CBD5E1;
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.85rem;
}

.site-footer .footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.site-footer .dr-name {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  color: #fff;
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

.site-footer .dr-qual {
  color: #94A3B8;
  margin-bottom: 0.75rem;
}

.site-footer .footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.5rem;
  margin-bottom: 1rem;
}

.site-footer .footer-links a {
  color: #94A3B8;
  font-size: 0.82rem;
}

.site-footer .footer-links a:hover {
  color: var(--primary-light);
}

.site-footer .copy {
  color: #64748B;
  font-size: 0.78rem;
}

/* ---------- Print Styles ---------- */
@media print {

  .site-header,
  .site-footer,
  .cta-section {
    display: none;
  }

  body {
    background: #fff;
  }

  .card {
    box-shadow: none;
    border: 1px solid #ccc;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .hero {
    padding: 3rem 1rem 2rem;
  }

  .page-container {
    padding: 1.5rem 1rem 3rem;
  }

  .card {
    padding: 1.25rem;
  }

  .do-dont {
    grid-template-columns: 1fr;
  }

  .flow-branches {
    grid-template-columns: 1fr;
  }

  .stats-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }

  .site-header nav {
    display: none;
  }
}

/* ---------- Animations ---------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}

.animate-in:nth-child(2) {
  animation-delay: 0.1s;
}

.animate-in:nth-child(3) {
  animation-delay: 0.2s;
}

.animate-in:nth-child(4) {
  animation-delay: 0.3s;
}

/* ---------- Language Toggle ---------- */
.lang-toggle {
  display: inline-flex;
  gap: 0;
  border-radius: 50px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-card);
  margin-bottom: 1.5rem;
}

.lang-toggle button {
  padding: 0.4rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  transition: var(--transition);
}

.lang-toggle button.active {
  background: var(--primary);
  color: #fff;
}

/* ---------- Illustration Container ---------- */
.illustration {
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
}

.illustration img {
  width: 100%;
  height: auto;
}

/* ---------- Numbered Steps ---------- */
.numbered-steps {
  counter-reset: step;
  list-style: none;
  margin-bottom: 1.5rem;
}

.numbered-steps li {
  counter-increment: step;
  padding: 0.75rem 0 0.75rem 3rem;
  position: relative;
  border-bottom: 1px solid var(--border);
}

.numbered-steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0.65rem;
  width: 28px;
  height: 28px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  font-weight: 700;
}

.numbered-steps li:last-child {
  border-bottom: none;
}

/* ---------- Progress Bar ---------- */
.progress-visual {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.progress-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.progress-item .label {
  font-size: 0.85rem;
  font-weight: 500;
  min-width: 120px;
}

.progress-bar {
  flex: 1;
  height: 10px;
  background: #E2E8F0;
  border-radius: 50px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 50px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width 1s ease;
}

/* ---------- Emoji Visual ---------- */
.emoji-visual {
  font-size: 3rem;
  text-align: center;
  margin: 1rem 0;
  line-height: 1.5;
}

/* ---------- Comparison Table ---------- */
.comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.comparison .col {
  border-radius: var(--radius);
  padding: 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.comparison .col h4 {
  font-family: 'Outfit', sans-serif;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

@media (max-width: 640px) {
  .comparison {
    grid-template-columns: 1fr;
  }
}