/* Case Study Shared Styles — Simi AI Brand (Electric Blue) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@500;600;700;800;900&display=swap');

:root {
  --simi-blue: #0066FF;
  --simi-blue-dark: #0044CC;
  --simi-blue-light: #E8F0FE;
  --simi-glow: rgba(0, 102, 255, 0.15);
  --accent: #0066FF;
  --accent-glow: rgba(0, 102, 255, 0.12);
  --green: #16a34a;
  --gold: #f0b429;
  --red: #ef4444;
  --bg: #ffffff;
  --bg-soft: #f5f8ff;
  --bg-card: rgba(255, 255, 255, 0.92);
  --text: #111827;
  --text-dim: #4b5563;
  --border: #dbe1f2;
  --border-strong: #c4c9e3;
  --shadow-soft: 0 16px 40px rgba(0, 102, 255, 0.07);
  --hero-from: #ffffff;
  --hero-mid: #f0f6ff;
  --hero-to: #e8f0fe;
  --hero-glow-1: rgba(0, 102, 255, 0.10);
  --hero-glow-2: rgba(0, 102, 255, 0.06);
  --badge-bg: rgba(0, 102, 255, 0.08);
  --badge-text: #0066FF;
  --badge-border: rgba(0, 102, 255, 0.18);
  --headline-start: #111827;
  --headline-end: #0066FF;
  --track-bg: #e8f0fe;
  --card-soft: rgba(255, 255, 255, 0.72);
  --quote-bg: rgba(0, 102, 255, 0.04);
  --table-head: rgba(0, 102, 255, 0.05);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

html.dark {
  --accent: #3b82f6;
  --accent-glow: rgba(59, 130, 246, 0.18);
  --green: #22c55e;
  --gold: #f0b429;
  --red: #ef4444;
  --bg: #0a0f1a;
  --bg-soft: #0f1628;
  --bg-card: #111827;
  --text: #e2e8f0;
  --text-dim: #94a3b8;
  --border: #1e293b;
  --border-strong: #2b3a55;
  --shadow-soft: 0 18px 48px rgba(0, 0, 0, 0.28);
  --hero-from: #0f1628;
  --hero-mid: #0a0f1a;
  --hero-to: #060b14;
  --hero-glow-1: rgba(59, 130, 246, 0.14);
  --hero-glow-2: rgba(59, 130, 246, 0.08);
  --badge-bg: rgba(59, 130, 246, 0.14);
  --badge-text: #93c5fd;
  --badge-border: rgba(59, 130, 246, 0.24);
  --headline-start: #ffffff;
  --headline-end: #3b82f6;
  --track-bg: rgba(255, 255, 255, 0.05);
  --card-soft: rgba(255, 255, 255, 0.03);
  --quote-bg: rgba(59, 130, 246, 0.06);
  --table-head: rgba(255, 255, 255, 0.03);
}

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

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* SIMI BRAND BAR */
.simi-topbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 8px 24px;
  background: linear-gradient(90deg, #0066FF, #0044CC);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}
.simi-topbar svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.simi-topbar a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* THEME TOGGLE */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
}
.theme-option {
  border: 0;
  background: transparent;
  color: var(--text-dim);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.theme-option.active {
  background: var(--bg-card);
  color: var(--text);
  box-shadow: 0 8px 18px rgba(17, 24, 39, 0.08);
}

/* SIMI NAV */
.simi-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
}
.simi-nav-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.simi-nav-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  font-size: 1rem;
}
.simi-nav-brand svg {
  width: 28px;
  height: 28px;
}
.simi-nav-brand span { color: var(--accent); }
.simi-nav-links {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 0.85rem;
  align-items: center;
}
.simi-nav-links a {
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
}
.simi-nav-links a:hover,
.simi-nav-links a.active { color: var(--accent); }
.simi-nav-links .live-badge {
  color: #10b981;
  font-weight: 600;
}

/* HERO */
.cs-hero {
  background: linear-gradient(135deg, var(--hero-from) 0%, var(--hero-mid) 52%, var(--hero-to) 100%);
  padding: 72px 24px 52px;
  text-align: center;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.cs-hero::before {
  content: '';
  position: absolute;
  inset: -35% -20%;
  background:
    radial-gradient(circle at 30% 42%, var(--hero-glow-1) 0%, transparent 42%),
    radial-gradient(circle at 72% 24%, var(--hero-glow-2) 0%, transparent 30%);
  pointer-events: none;
}
.cs-badge {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: var(--badge-bg);
  color: var(--badge-text);
  border: 1px solid var(--badge-border);
  margin-bottom: 16px;
  position: relative;
}
.cs-hero h1 {
  font-size: 2.6rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--headline-start) 0%, var(--headline-end) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  position: relative;
  margin-bottom: 8px;
}
.cs-hero .subtitle {
  color: var(--text-dim);
  font-size: 1.08rem;
  position: relative;
  margin-bottom: 24px;
}
.cs-metrics {
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
  position: relative;
  margin-top: 8px;
}
.cs-metrics .metric { text-align: center; }
.cs-metrics .metric .num {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--green);
}
.cs-metrics .metric .num.gold { color: var(--gold); }
.cs-metrics .metric .num.accent { color: var(--accent); }
.cs-metrics .metric .label {
  font-size: 0.75rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

/* PODCAST PLAYER */
.podcast-player {
  background: linear-gradient(135deg, var(--bg-card), var(--hero-mid));
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px 28px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-soft);
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.podcast-player .cover {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  background: linear-gradient(135deg, #0066FF, #0044CC);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
}
.podcast-player .info { flex: 1; min-width: 160px; }
.podcast-player .info .label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-weight: 600;
}
.podcast-player .info .title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 2px 0 4px;
}
.podcast-player .info .meta {
  font-size: 0.78rem;
  color: var(--text-dim);
}
.podcast-player audio {
  width: 100%;
  max-width: 360px;
  height: 40px;
  border-radius: 8px;
}
.podcast-player audio::-webkit-media-controls-panel {
  background: var(--bg-card);
}

/* CONTENT */
.cs-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 48px 24px 56px;
}
.cs-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-soft);
}
.cs-section h2 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.cs-section h2 .icon { font-size: 1.4rem; }
.cs-section p {
  color: var(--text-dim);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 12px;
}
.cs-section p:last-child { margin-bottom: 0; }

/* SOLUTION CALLOUT */
.simi-solution-callout {
  background: linear-gradient(135deg, rgba(0, 102, 255, 0.04), rgba(0, 102, 255, 0.08));
  border: 1px solid rgba(0, 102, 255, 0.15);
  border-radius: 12px;
  padding: 20px 24px;
  margin: 16px 0;
}
.simi-solution-callout h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 6px;
}
.simi-solution-callout p {
  font-size: 0.88rem;
  margin-bottom: 0;
}

/* QUOTE BLOCK */
.cs-quote {
  border-left: 3px solid var(--accent);
  padding: 16px 20px;
  margin: 16px 0;
  background: var(--quote-bg);
  border-radius: 0 8px 8px 0;
}
.cs-quote p {
  color: var(--text) !important;
  font-style: italic;
  font-size: 0.95rem;
  margin-bottom: 6px !important;
}
.cs-quote .attribution {
  font-size: 0.8rem;
  color: var(--text-dim);
  font-style: normal;
  font-weight: 500;
}

/* CHARTS / BARS */
.roi-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0;
}
.roi-bar .bar-label {
  width: 140px;
  font-size: 0.8rem;
  color: var(--text-dim);
  text-align: right;
  flex-shrink: 0;
}
.roi-bar .bar-track {
  flex: 1;
  height: 20px;
  background: var(--track-bg);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}
.roi-bar .bar-fill {
  height: 100%;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 8px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  min-width: 40px;
}
.bar-green { background: linear-gradient(90deg, #166534, var(--green)); }
.bar-blue { background: linear-gradient(90deg, #0044CC, var(--accent)); }
.bar-gold { background: linear-gradient(90deg, #713f12, var(--gold)); }
.bar-brand { background: linear-gradient(90deg, #0044CC, #0066FF); }

/* STATS GRID */
.stats-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 16px 0;
}
.stats-3 .stat {
  background: var(--card-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}
.stats-3 .stat .big {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--green);
}
.stats-3 .stat .big.gold { color: var(--gold); }
.stats-3 .stat .big.accent { color: var(--accent); }
.stats-3 .stat .small {
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 4px;
}

/* TABLE */
.cs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  margin: 16px 0;
}
.cs-table th {
  background: var(--table-head);
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
  color: var(--text-dim);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid var(--border);
}
.cs-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
}
.cs-table td:last-child, .cs-table th:last-child { text-align: right; }
.cs-table tr:last-child td { border-bottom: none; }
.cs-table .green { color: var(--green); font-weight: 600; }
.cs-table .gold { color: var(--gold); font-weight: 600; }

/* TIMELINE */
.cs-timeline {
  position: relative;
  padding-left: 24px;
  margin: 16px 0;
}
.cs-timeline::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border);
}
.cs-timeline .item {
  position: relative;
  padding-bottom: 20px;
}
.cs-timeline .item:last-child { padding-bottom: 0; }
.cs-timeline .item::before {
  content: '';
  position: absolute;
  left: -20px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg-card);
}
.cs-timeline .item .step { font-weight: 600; font-size: 0.9rem; }
.cs-timeline .item .desc { font-size: 0.82rem; color: var(--text-dim); margin-top: 2px; }

/* CTA */
.cs-cta {
  text-align: center;
  padding: 40px 24px;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, transparent 0%, var(--bg-soft) 100%);
}
.cs-cta h3 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.cs-cta p {
  color: var(--text-dim);
  margin-bottom: 20px;
}
.cs-cta .btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  background: var(--accent);
  color: #fff;
  transition: all 0.2s;
}
.cs-cta .btn:hover { filter: brightness(1.05); transform: translateY(-1px); }
.cs-cta .btn-outline {
  background: transparent;
  border: 2px solid var(--accent);
  color: var(--accent);
  margin-left: 12px;
}
.cs-cta .btn-outline:hover { background: var(--accent); color: #fff; }

/* FOOTER */
.cs-footer {
  text-align: center;
  padding: 32px 24px;
  color: var(--text-dim);
  font-size: 0.78rem;
  border-top: 1px solid var(--border);
  background: var(--bg);
  line-height: 1.8;
}
.cs-footer .simi-brand {
  font-weight: 700;
  color: var(--accent);
  font-size: 0.9rem;
  margin-bottom: 4px;
}

/* BACK LINK */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  text-decoration: none;
  font-size: 0.85rem;
  margin-bottom: 24px;
  font-weight: 500;
}
.back-link:hover { text-decoration: underline; }

/* RESPONSIVE */
@media (max-width: 640px) {
  .cs-hero { padding: 60px 20px 40px; }
  .cs-hero h1 { font-size: 1.6rem; }
  .cs-metrics { gap: 16px; }
  .stats-3 { grid-template-columns: 1fr; }
  .roi-bar { flex-direction: column; align-items: stretch; }
  .roi-bar .bar-label { width: auto; text-align: left; }
  .podcast-player { flex-direction: column; align-items: flex-start; }
  .podcast-player audio { max-width: 100%; }
  .cs-table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .simi-nav-links { gap: 8px; font-size: 0.78rem; }
}
