:root {
  --unir-blue: #0098CD;
  --unir-blue-dark: #007AA3;
  --unir-light: #E6F4F9;
  --unir-text: #404040;
  --unir-gray: #E7E6E6;
  --unir-red: #E8654A;
  --unir-orange: #F0A030;
}

.reveal {
  font-family: 'Calibri', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  font-size: 28px;
  color: var(--unir-text);
}

.reveal h1, .reveal h2, .reveal h3 {
  font-family: 'Calibri Light', 'Calibri', 'Segoe UI', Arial, sans-serif;
  color: var(--unir-blue);
  text-transform: none;
  letter-spacing: -0.02em;
  font-weight: 600;
}

.reveal h1 { font-size: 1.8em; }
.reveal h2 { font-size: 1.4em; margin-bottom: 0.6em; }
.reveal h3 { font-size: 1.1em; }

.reveal .slides section {
  text-align: left;
  padding: 20px 40px;
}

/* Corner logo on all slides except title */
.reveal .slides section:not(.title-slide)::after {
  content: '';
  position: absolute;
  top: 15px;
  right: 20px;
  width: 110px;
  height: 30px;
  background: url('figures/unir_logo.png') no-repeat center;
  background-size: contain;
  opacity: 0.8;
}

/* Bottom accent line - fixed to viewport bottom */
#bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--unir-blue), var(--unir-light));
  z-index: 50;
  pointer-events: none;
}

/* Title slide */
.title-slide {
  text-align: center !important;
}
.title-slide h1 {
  font-size: 1.5em !important;
  line-height: 1.3;
  margin-top: 0.2em;
}
.title-slide .subtitle {
  color: var(--unir-blue);
  font-size: 0.75em;
  font-weight: 600;
  margin-bottom: 0.5em;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.title-slide .meta {
  font-size: 0.65em;
  color: #666;
  line-height: 1.8;
}
.title-slide .meta strong {
  color: var(--unir-text);
}
.title-slide .logo-large {
  width: 220px;
  margin-bottom: 10px;
}
.title-slide .divider {
  width: 120px;
  height: 3px;
  background: var(--unir-blue);
  margin: 15px auto;
}

/* Thank you slide */
.thanks-slide {
  text-align: center !important;
}
.thanks-slide h1 {
  font-size: 2.5em !important;
  margin-bottom: 0.3em;
}
.thanks-slide .questions {
  font-size: 1.2em;
  color: #666;
  margin-bottom: 1em;
}

/* Two column layout */
.two-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  align-items: start;
}
.two-columns-60-40 {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 30px;
  align-items: start;
}
.two-columns-40-60 {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: 30px;
  align-items: start;
}
.three-columns {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  align-items: start;
}

/* Highlight box */
.highlight-box {
  background: var(--unir-light);
  border-left: 5px solid var(--unir-blue);
  padding: 15px 20px;
  border-radius: 0 8px 8px 0;
  margin: 15px 0;
  font-size: 0.85em;
}
.highlight-box.center-box {
  border-left: none;
  border-top: 3px solid var(--unir-blue);
  border-radius: 0 0 8px 8px;
  text-align: center;
}

/* Metric cards */
.metric-cards {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  justify-content: center;
}
.metric-card {
  background: white;
  border: 2px solid var(--unir-light);
  border-radius: 12px;
  padding: 15px 20px;
  text-align: center;
  min-width: 130px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  transition: transform 0.2s;
}
.metric-card:hover {
  transform: translateY(-2px);
}
.metric-card .number {
  font-size: 1.6em;
  font-weight: 700;
  color: var(--unir-blue);
  line-height: 1.2;
}
.metric-card .number.success { color: #2EAD4B; }
.metric-card .number.warning { color: var(--unir-orange); }
.metric-card .number.danger { color: var(--unir-red); }
.metric-card .label {
  font-size: 0.6em;
  color: #888;
  margin-top: 4px;
}

/* Data table */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.75em;
  margin: 10px 0;
}
.data-table thead th {
  background: var(--unir-blue);
  color: white;
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
}
.data-table thead th:first-child {
  border-radius: 8px 0 0 0;
}
.data-table thead th:last-child {
  border-radius: 0 8px 0 0;
}
.data-table tbody td {
  padding: 8px 14px;
  border-bottom: 1px solid var(--unir-gray);
}
.data-table tbody tr:nth-child(even) {
  background: #FAFCFE;
}
.data-table tbody tr.highlight {
  background: var(--unir-light);
  font-weight: 600;
}
.data-table tbody tr:last-child td:first-child {
  border-radius: 0 0 0 8px;
}
.data-table tbody tr:last-child td:last-child {
  border-radius: 0 0 8px 0;
}

/* Engine cards */
.engine-card {
  background: white;
  border: 2px solid var(--unir-gray);
  border-radius: 12px;
  padding: 18px;
  text-align: center;
  transition: all 0.3s;
}
.engine-card.selected {
  border-color: var(--unir-blue);
  background: var(--unir-light);
  box-shadow: 0 4px 16px rgba(0,152,205,0.2);
}
.engine-card h3 {
  margin: 0 0 5px 0;
  font-size: 0.9em;
}
.engine-card .developer {
  font-size: 0.55em;
  color: #999;
  margin-bottom: 10px;
}
.engine-card .arch {
  font-size: 0.6em;
  color: var(--unir-text);
  background: var(--unir-light);
  border-radius: 6px;
  padding: 4px 8px;
  display: inline-block;
  margin-bottom: 8px;
}
.engine-card.selected .arch {
  background: white;
}
.engine-card ul {
  text-align: left;
  font-size: 0.6em;
  margin: 0;
  padding-left: 16px;
}

/* Agenda items */
.agenda-item {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 12px 0;
  font-size: 0.85em;
}
.agenda-number {
  width: 36px;
  height: 36px;
  background: var(--unir-blue);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9em;
  flex-shrink: 0;
}

/* Tags */
.tag {
  display: inline-block;
  background: var(--unir-light);
  color: var(--unir-blue-dark);
  border-radius: 20px;
  padding: 3px 12px;
  font-size: 0.6em;
  font-weight: 600;
  margin: 2px;
}
.tag.bool { background: #FFF3E0; color: #E65100; }
.tag.cont { background: #E8F5E9; color: #2E7D32; }
.tag.fixed { background: var(--unir-gray); color: #888; }

/* Chart containers */
.chart-container {
  position: relative;
  width: 100%;
  max-height: 420px;
}
.chart-container canvas {
  max-height: 420px;
}

/* Bullet lists */
.reveal ul, .reveal ol {
  font-size: 0.8em;
  line-height: 1.6;
}
.reveal li {
  margin-bottom: 6px;
}

/* Compact list */
.compact-list { font-size: 0.7em; }
.compact-list li { margin-bottom: 3px; }

/* Objective check */
.obj-list {
  list-style: none;
  padding: 0;
  font-size: 0.72em;
}
.obj-list li {
  padding: 6px 0 6px 30px;
  position: relative;
}
.obj-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 18px;
  height: 18px;
  border: 2px solid var(--unir-blue);
  border-radius: 50%;
}
.obj-list li.done::before {
  background: var(--unir-blue);
  box-shadow: inset 0 0 0 3px white;
}

/* Conclusion items */
.contribution-item {
  display: flex;
  align-items: start;
  gap: 10px;
  margin: 8px 0;
  font-size: 0.72em;
}
.contribution-icon {
  width: 28px;
  height: 28px;
  background: var(--unir-blue);
  color: white;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}
.limitation-icon {
  width: 28px;
  height: 28px;
  background: var(--unir-orange);
  color: white;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}

/* Figure caption */
.fig-caption {
  text-align: center;
  font-size: 0.55em;
  color: #999;
  font-style: italic;
  margin-top: 5px;
}

/* Comparison table for fine-tuning vs HPO */
.compare-row {
  display: grid;
  grid-template-columns: 140px 1fr 1fr;
  gap: 0;
  font-size: 0.65em;
}
.compare-row.header > div {
  background: var(--unir-blue);
  color: white;
  padding: 8px 12px;
  font-weight: 600;
}
.compare-row > div {
  padding: 6px 12px;
  border-bottom: 1px solid var(--unir-gray);
}
.compare-row .label-col {
  font-weight: 600;
  background: #FAFCFE;
}
.compare-row .highlight-col {
  background: var(--unir-light);
}

/* Slide number */
.reveal .slide-number {
  color: var(--unir-blue);
  font-size: 14px;
  font-family: 'Calibri', sans-serif;
}

/* Progress bar */
.reveal .progress span {
  background: var(--unir-blue);
}

/* Improvements arrow */
.improvement {
  color: #2EAD4B;
  font-weight: 700;
  font-size: 0.8em;
}

/* Code/param names */
code, .param {
  font-family: 'Consolas', 'Courier New', monospace;
  background: var(--unir-light);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.85em;
}

/* Section divider */
.section-divider {
  text-align: center !important;
}
.section-divider h2 {
  font-size: 1.8em !important;
}
.section-divider .section-number {
  font-size: 3em;
  color: var(--unir-blue);
  opacity: 0.2;
  font-weight: 700;
}
