/* ═══════════════════════════════════════════════════
   SWISS BRUTALIST THEME — ECIR 2026
   Gemini Hegemony · Dr. Madeleine I. G. Daepp
   Inspired by Weingart / Experimental Jetset /
   Herzog & de Meuron grid discipline
═══════════════════════════════════════════════════ */

/* ── Variables ─────────────────────────────────── */
:root {
  --bg:         #f5f3ef;
  --text:       #111111;
  --red:        #c8102e;
  --muted:      #767676;
  --subtle:     #cccccc;
  --panel:      #111111;
  --panel-text: #f5f3ef;
  --teal:       #1a3a3a;
  --font:       'Helvetica Neue', Helvetica, Arial, sans-serif;
}

/* ── Reveal.js base overrides ──────────────────── */
.reveal-viewport { background: var(--bg); }

.reveal {
  font-family: var(--font);
  font-size: 38px;
  color: var(--text);
}

/* Kill all Reveal defaults */
.reveal h1, .reveal h2, .reveal h3, .reveal h4,
.reveal h5, .reveal h6 {
  font-family: var(--font);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.05em;
  line-height: 0.9;
  color: var(--text);
  margin: 0;
  text-shadow: none;
  word-wrap: normal;
}

.reveal .slides section {
  text-align: left;
  padding: 56px 80px 48px;
  height: 100% !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  display: flex !important;
  flex-direction: column;
  box-sizing: border-box;
}

/* ── Dark slides ───────────────────────────────── */
.reveal .slides section.slide-dark {
  background: var(--panel);
  padding: 0;
  position: relative;
}
.slide-dark .dark-inner {
  padding: 56px 80px 48px;
  height: 100%;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}
.slide-dark .red-rule {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 8px;
  background: var(--red);
  z-index: 1;
}

/* ── Title slide ───────────────────────────────── */
.reveal .slides section.slide-title {
  background: var(--bg);
  padding: 0;
}
.slide-title .title-bar {
  background: var(--text);
  padding: 10px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}
.slide-title .title-bar span {
  font-size: 0.38em;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--panel-text);
  font-weight: 400;
}
.slide-title .title-bar span:last-child { color: var(--panel-text); }

.slide-title .title-body {
  padding: 48px 80px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.slide-title h1 {
  font-size: 3.2em;
  line-height: 0.86;
  color: var(--text);
  margin-bottom: 32px;
}
.slide-title h1 .red { color: var(--red); }

.slide-title .title-author {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.slide-title .title-vr {
  width: 3px;
  align-self: stretch;
  background: var(--text);
  flex-shrink: 0;
  margin-top: 2px;
}
.slide-title .title-name {
  font-size: 0.54em;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
  line-height: 1.2;
  margin-bottom: 4px;
}
.slide-title .title-role {
  font-size: 0.48em;
  font-weight: 300;
  color: #555555;
  line-height: 1.5;
}

.slide-title .title-tags {
  border-top: 1px solid var(--subtle);
  padding: 12px 80px;
  display: flex;
  gap: 32px;
  flex-shrink: 0;
}
.slide-title .title-tags span {
  font-size: 0.26em;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 400;
}

/* ── Typography components ─────────────────────── */
.reveal .kicker {
  font-size: 0.36em;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
  margin: 0 0 0.6em;
  flex-shrink: 0;
}

.reveal .headline {
  font-size: 1.6em;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.05em;
  line-height: 0.91;
  color: var(--text);
  margin: 0 0 0;
  flex-shrink: 0;
}
.reveal .headline-lg {
  font-size: 2.4em;
}
.reveal .headline .red  { color: var(--red); }
.reveal .headline .grey { color: var(--muted); }

.reveal .sub {
  font-size: 0.62em;
  font-weight: 300;
  line-height: 1.55;
  color: var(--text);
  max-width: 58ch;
  margin: 0;
}
.reveal .sub + .sub { margin-top: 0.5em; }
.reveal .sub.muted   { color: var(--muted); }

.reveal .rule {
  width: 100%;
  height: 3px;
  background: var(--text);
  margin: 0.5em 0 0.7em;
  flex-shrink: 0;
}
.reveal .rule-subtle {
  width: 100%;
  height: 1px;
  background: var(--subtle);
  margin: 0.4em 0;
  flex-shrink: 0;
}

/* ── Quote block ───────────────────────────────── */
.reveal .qt-block {
  display: flex;
  gap: 20px;
  flex-shrink: 0;
}
.qt-block .qt-rule {
  width: 4px;
  flex-shrink: 0;
  background: var(--red);
  align-self: stretch;
}
.qt-block .qt-rule.black { background: var(--text); }
.qt-block .qt-text {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.qt-block .qt-attr-top {
  font-size: 0.32em;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
}
.qt-block .qt-quote {
  font-size: 0.72em;
  font-weight: 300;
  line-height: 1.45;
  color: var(--panel-text);
  font-style: normal;
  margin: 0;
}
.qt-block .qt-quote strong {
  font-weight: 900;
  text-transform: uppercase;
}
/* on off-white slides */
.qt-block.light .qt-quote { color: var(--text); }
.qt-block .qt-attr-bottom {
  font-size: 0.32em;
  color: var(--muted);
  letter-spacing: 0.05em;
}

/* ── Section break (dark slides with bottom headline) */
.slide-dark .section-break-inner {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 56px 80px 48px;
  box-sizing: border-box;
}
.slide-dark .section-num {
  font-size: 0.30em;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #444;
  margin-bottom: 16px;
}
.slide-dark .section-break-inner h2 {
  font-size: 2.3em;
  color: var(--panel-text);
  margin-bottom: 24px;
}
.slide-dark .section-break-inner h2 .red { color: var(--red); }
.slide-dark .bottom-rule {
  width: 100%;
  height: 1px;
  background: #333;
}
/* Kickers on dark backgrounds need more contrast */
.slide-dark .kicker { color: #888 !important; }
/* Callout: heavier border */
.reveal .callout { border-width: 3px; }

/* ── Stat split (two numbers with hard divider) ─── */
.reveal .stat-split {
  display: grid;
  grid-template-columns: 1fr 2px 1fr;
  flex: 1;
  min-height: 0;
  margin: 0.4em 0;
}
.stat-split .stat-divider { background: var(--text); }
.stat-split .stat-cell {
  padding: 0 32px 0 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.stat-split .stat-cell:last-child { padding: 0 0 0 32px; }
.stat-split .stat-n {
  font-size: 2.9em;
  font-weight: 900;
  letter-spacing: -0.06em;
  line-height: 1;
  color: var(--text);
}
.stat-split .stat-n.faded  { color: var(--subtle); }
.stat-split .stat-l {
  font-size: 0.32em;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.4;
}
.stat-split .stat-l.faded { color: var(--subtle); }

/* ── Stat row (horizontal bordered cards) ──────── */
.reveal .stat-row {
  display: flex;
  gap: 3px;
  flex-shrink: 0;
  margin: 0.4em 0;
}
.stat-row .stat-card {
  flex: 1;
  border: 2px solid var(--text);
  padding: 18px 20px;
}
.stat-card .stat-n {
  font-size: 1.5em;
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 1;
  color: var(--text);
  margin-bottom: 6px;
}
.stat-card .stat-l {
  font-size: 0.34em;
  color: var(--muted);
  line-height: 1.4;
  font-weight: 300;
}

/* ── Bar chart ─────────────────────────────────── */
.reveal .bar-chart {
  flex-shrink: 0;
  margin: 0.4em 0;
}
.bar-chart .chart-title {
  font-size: 0.32em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-bottom: 0.7em;
}
.bar-chart .bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}
.bar-chart .bar-label {
  font-size: 0.40em;
  font-weight: 500;
  min-width: 160px;
  text-align: right;
  color: var(--text);
}
.bar-chart .bar-track {
  flex: 1;
  height: 28px;
  background: #e5e1d9;
  position: relative;
}
.bar-chart .bar-fill       { height: 100%; background: var(--text); }
.bar-chart .bar-fill.red   { background: var(--red); }
.bar-chart .bar-val {
  position: absolute;
  right: -56px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.9em;
  font-weight: 700;
  white-space: nowrap;
  color: var(--text);
}
.bar-chart .bar-val.red    { color: var(--red); }
.bar-chart .chart-caption {
  font-size: 0.32em;
  color: var(--muted);
  font-style: italic;
  margin-top: 0.8em;
  padding-top: 0.5em;
  border-top: 1px solid var(--subtle);
  line-height: 1.5;
}

/* ── Two-column layout ─────────────────────────── */
.reveal .two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  flex: 1;
  min-height: 0;
}
.two-col .col {
  display: flex;
  flex-direction: column;
  gap: 0.4em;
}
.two-col > *:first-child {
  padding-right: 28px;
  border-right: 1px solid var(--subtle);
}
.two-col > *:last-child {
  padding-left: 28px;
}

/* ── Bullet list ───────────────────────────────── */
.reveal .bullets {
  list-style: none;
  padding: 0;
  margin: 0.3em 0;
}
.reveal .bullets li {
  font-size: 0.52em;
  font-weight: 300;
  line-height: 1.4;
  padding: 0.5em 0 0.5em 1.4em;
  position: relative;
  border-bottom: 1px solid var(--subtle);
  color: var(--text);
}
.reveal .bullets li:last-child { border-bottom: none; }
.reveal .bullets li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--text);
  font-weight: 700;
}

/* ── Pipeline diagram ──────────────────────────── */
.reveal .pipeline {
  display: flex;
  align-items: stretch;
  gap: 4px;
  flex-shrink: 0;
  margin: 0.4em 0;
}
.pipeline .pipe-step {
  flex: 1;
  border: 2px solid var(--text);
  padding: 14px 14px;
}
.pipeline .pipe-label {
  font-size: 0.29em;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 6px;
}
.pipeline .pipe-text {
  font-size: 0.32em;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.4;
}
.pipeline .pipe-arrow {
  font-size: 0.5em;
  color: var(--muted);
  flex-shrink: 0;
  align-self: center;
}

/* ── Taxonomy 2×2 grid ─────────────────────────── */
.reveal .taxonomy {
  display: grid;
  grid-template-columns: 32px 1fr 1fr;
  grid-template-rows: 26px 1fr 1fr;
  gap: 3px;
  flex: 1;
  min-height: 0;
  margin: 0.3em 0;
}
.taxonomy .tax-corner { background: transparent; }
.taxonomy .tax-col-hdr,
.taxonomy .tax-row-hdr {
  background: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.28em;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--panel-text);
}
.taxonomy .tax-row-hdr {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-size: 0.24em;
}
.taxonomy .tax-cell {
  border: 2px solid var(--text);
  padding: 12px 14px;
  overflow: hidden;
}
.taxonomy .tax-cell h3 {
  font-size: 0.40em;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 1;
  margin-bottom: 5px;
  color: var(--text);
}
.taxonomy .tax-cell p {
  font-size: 0.32em;
  font-weight: 300;
  line-height: 1.4;
  color: var(--muted);
  margin: 0;
}
.taxonomy .tax-cell em {
  font-size: 0.27em;
  color: var(--muted);
  display: block;
  margin-top: 4px;
}
.taxonomy .tc-deroga h3 { color: var(--red); }

/* ── Callout box ───────────────────────────────── */
.reveal .callout {
  border: 2px solid var(--text);
  padding: 14px 18px;
  flex-shrink: 0;
}
.callout p {
  font-size: 0.44em;
  font-weight: 300;
  line-height: 1.5;
  color: var(--text);
  margin: 0;
}
.callout strong { font-weight: 700; }

.callout.callout-data .data-label {
  font-size: 0.30em;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 4px;
}
.callout.callout-data .data-value {
  font-size: 0.65em;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--text);
}
.callout.callout-data .data-value .red { color: var(--red); }
.callout.callout-data .data-note {
  font-size: 0.29em;
  color: var(--muted);
  margin-top: 5px;
  font-weight: 300;
  line-height: 1.4;
}

/* ── Placeholder ───────────────────────────────── */
.reveal .ph {
  border: 1px dashed var(--subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.32em;
  font-weight: 400;
  text-align: center;
  padding: 12px;
  min-height: 140px;
}

/* ── Progress bar ──────────────────────────────── */
.reveal .progress { height: 3px; }
.reveal .progress span { background: var(--red); }

/* ── Slide number ──────────────────────────────── */
.reveal .slide-number {
  background: transparent;
  color: var(--muted);
  font-size: 0.28em;
  font-family: var(--font);
  font-weight: 400;
  right: 20px;
  bottom: 14px;
  letter-spacing: 0.05em;
}

/* ── Lecture hall safety net ───────────────────── */
/* clamp(min, preferred, max) — minimum prevents anything
   going below ~13px in the 1280×720 slide coordinate space.
   At 1.5× projection scale (1920px wide screen) that's ~20px.  */
.reveal .kicker       { font-size: clamp(13px, 0.36em, 20px); }
.reveal .sub          { font-size: clamp(22px, 0.62em, 30px); }
.reveal .bullets li   { font-size: clamp(16px, 0.52em, 26px); }
.qt-block .qt-quote   { font-size: clamp(20px, 0.72em, 32px); }
.callout p            { font-size: clamp(14px, 0.44em, 22px); }
.bar-chart .bar-label { font-size: clamp(13px, 0.40em, 20px); }
.bar-chart .chart-caption { font-size: clamp(13px, 0.32em, 16px); }
.pipeline .pipe-text  { font-size: clamp(13px, 0.32em, 16px); }

/* ── Source citation ───────────────────────────── */
.reveal .source-cite {
  font-size: clamp(13px, 0.34em, 18px);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(44,42,39,0.75);
  font-weight: 400;
  white-space: nowrap;
}
.slide-dark .source-cite,
[data-background-color="#0f0c09"] .source-cite,
[data-background-color="#000"] .source-cite {
  color: rgba(245,243,239,0.55);
}
/* When source-cite is used in a bottom bar, allow wrapping */
.reveal .source-cite.wrap { white-space: normal; }

/* ── Accessibility: focus ring ─────────────────── */
.reveal a:focus { outline: 2px solid var(--red); outline-offset: 2px; }
