:root {
  --amlab-ink: #10253c;
  --amlab-muted: #5c6d80;
  --amlab-copper: #c55a3d;
  --amlab-teal: #15736d;
  --amlab-gold: #d9a441;
  --amlab-paper: #fcf8f2;
  --amlab-paper-strong: #f1eadf;
  --amlab-deep: #0d1f31;
  --amlab-shadow: 0 18px 42px rgba(16, 37, 60, 0.14);
}

@font-face {
  font-family: "Montserrat";
  src: url("../assets/fonts/Montserrat-VariableFont_wght.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
}

@font-face {
  font-family: "Montserrat";
  src: url("../assets/fonts/Montserrat-Italic-VariableFont_wght.ttf") format("truetype");
  font-style: italic;
  font-weight: 100 900;
}

.reveal {
  font-family: "Montserrat", "Segoe UI", sans-serif;
  font-size: 34px;
  color: var(--amlab-ink);
}

.reveal .slides {
  text-align: left;
}

.reveal .slides section {
  padding: 1.1rem 0.2rem 0.4rem 0.2rem;
}

.reveal .slide-background {
  background:
    radial-gradient(circle at top right, rgba(197, 90, 61, 0.16), transparent 34%),
    radial-gradient(circle at bottom left, rgba(21, 115, 109, 0.14), transparent 36%),
    linear-gradient(135deg, #fffaf3 0%, #f4ede3 100%);
}

.reveal .title-slide {
  display: flex !important;
  align-items: center;
}

.reveal .title-slide .quarto-title-block {
  width: min(980px, 92%);
  padding: 2rem 2.2rem;
  border-radius: 32px;
  background:
    linear-gradient(145deg, rgba(13, 31, 49, 0.96) 0%, rgba(16, 37, 60, 0.92) 100%),
    var(--amlab-deep);
  color: #f8fafc;
  box-shadow: 0 26px 60px rgba(13, 31, 49, 0.34);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.reveal .title-slide h1 {
  font-size: 2.35em;
  line-height: 0.96;
  margin-bottom: 0.55rem;
  color: #f8fafc;
}

.reveal .title-slide .subtitle {
  font-size: 0.9em;
  line-height: 1.35;
  color: rgba(248, 250, 252, 0.82);
}

.reveal .title-slide .date,
.reveal .title-slide .author,
.reveal .title-slide .quarto-title-author,
.reveal .title-slide .quarto-title-authors {
  display: none;
}

.reveal h2 {
  color: var(--amlab-ink);
  font-size: 1.7em;
  line-height: 1.02;
  margin-bottom: 0.55rem;
  letter-spacing: -0.02em;
}

.reveal h3,
.reveal .panel-title {
  color: var(--amlab-teal);
  font-size: 0.62em;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 0.4rem;
}

.reveal .panel-title {
  display: block;
}

.reveal .panel-title-block {
  margin: 0 0 0.4rem 0;
}

.reveal .panel-title-block > * {
  margin: 0;
}

.reveal p,
.reveal li {
  font-size: 0.78em;
  line-height: 1.42;
}

.reveal ul,
.reveal ol {
  margin-left: 1.1em;
}

.reveal strong {
  color: var(--amlab-ink);
}

.reveal a {
  color: var(--amlab-copper);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.12em;
}

.reveal code {
  color: var(--amlab-teal);
  background: rgba(16, 37, 60, 0.08);
  border-radius: 0.3rem;
  padding: 0.08rem 0.28rem;
}

.reveal pre code {
  display: block;
  padding: 1rem 1.1rem;
  border-radius: 22px;
  background: rgba(13, 31, 49, 0.98);
  color: #eef5fb;
  box-shadow: var(--amlab-shadow);
}

.reveal blockquote {
  width: 100%;
  margin: 0.8rem 0;
  padding: 0.9rem 1.1rem;
  background: rgba(255, 255, 255, 0.66);
  border-left: 6px solid var(--amlab-copper);
  border-radius: 18px;
  box-shadow: var(--amlab-shadow);
}

.grid-2,
.grid-3,
.workflow-grid,
.metric-grid,
.link-grid {
  display: grid;
  gap: 0.9rem;
}

.grid-2,
.workflow-grid,
.metric-grid,
.link-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.formula-card,
.data-card,
.tool-card {
  padding: 1rem 1.1rem;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(16, 37, 60, 0.09);
  box-shadow: var(--amlab-shadow);
  backdrop-filter: blur(8px);
}

.card h3,
.formula-card h3,
.data-card h3,
.tool-card h3,
.card .panel-title-block,
.formula-card .panel-title-block,
.data-card .panel-title-block,
.tool-card .panel-title-block {
  margin-top: 0;
}

.metric {
  display: block;
  font-size: 1.55em;
  font-weight: 800;
  line-height: 0.95;
  color: var(--amlab-copper);
  margin-bottom: 0.2rem;
}

.eyebrow {
  display: inline-block;
  font-size: 0.42em;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--amlab-muted);
  margin-bottom: 0.45rem;
}

.small-text,
.muted {
  font-size: 0.62em;
  color: var(--amlab-muted);
}

.section-break,
.inverse {
  color: #f8fafc;
}

.section-break .slide-background,
.inverse .slide-background {
  background:
    radial-gradient(circle at top left, rgba(217, 164, 65, 0.22), transparent 24%),
    radial-gradient(circle at bottom right, rgba(21, 115, 109, 0.22), transparent 34%),
    linear-gradient(135deg, #0a1624 0%, #11283f 100%);
}

.reveal .slides section.section-break,
.reveal .slides section.inverse {
  background:
    radial-gradient(circle at top left, rgba(217, 164, 65, 0.18), transparent 24%),
    radial-gradient(circle at bottom right, rgba(21, 115, 109, 0.18), transparent 34%),
    linear-gradient(135deg, #0a1624 0%, #11283f 100%);
  border-radius: 34px;
  padding: 1.5rem 1.35rem;
  box-shadow: 0 28px 60px rgba(8, 22, 36, 0.36);
}

.reveal .slides section.section-break h2,
.reveal .slides section.section-break h3,
.reveal .slides section.section-break .panel-title,
.reveal .slides section.inverse h2,
.reveal .slides section.inverse h3,
.reveal .slides section.inverse .panel-title,
.reveal .slides section.section-break strong,
.reveal .slides section.inverse strong,
.reveal .slides section.section-break a,
.reveal .slides section.inverse a {
  color: #f8fafc;
}

.reveal .slides section.section-break .eyebrow,
.reveal .slides section.inverse .eyebrow,
.reveal .slides section.section-break .muted,
.reveal .slides section.inverse .muted,
.reveal .slides section.section-break .small-text,
.reveal .slides section.inverse .small-text {
  color: rgba(248, 250, 252, 0.75);
}

.reveal .slides section.inverse .card,
.reveal .slides section.inverse .formula-card,
.reveal .slides section.inverse .data-card,
.reveal .slides section.inverse .tool-card,
.reveal .slides section.section-break .card {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow: none;
}

.figure-frame img,
img.figure-frame,
.reveal .columns img {
  width: 100%;
  border-radius: 24px;
  border: 1px solid rgba(16, 37, 60, 0.12);
  box-shadow: var(--amlab-shadow);
}

.module-links,
.deck-links {
  margin-top: 0.6rem;
}

.module-links a,
.deck-links a {
  display: inline-block;
  margin: 0.18rem 0.24rem 0.18rem 0;
  padding: 0.42rem 0.82rem;
  border-radius: 999px;
  text-decoration: none;
  border: 1px solid rgba(16, 37, 60, 0.12);
  background: rgba(255, 255, 255, 0.78);
  color: var(--amlab-ink);
  box-shadow: var(--amlab-shadow);
}

.reveal .slides section.inverse .module-links a,
.reveal .slides section.section-break .module-links a {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.18);
  color: #f8fafc;
  box-shadow: none;
}

.two-column-note {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1rem;
  align-items: center;
}

.tight-list ul,
.tight-list ol {
  margin-top: 0.35rem;
}

.tight-list li {
  margin-bottom: 0.22rem;
}

.reveal table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.66em;
  overflow: hidden;
  border-radius: 22px;
  box-shadow: var(--amlab-shadow);
}

.reveal thead th {
  background: rgba(16, 37, 60, 0.9);
  color: #f8fafc;
}

.reveal th,
.reveal td {
  padding: 0.55rem 0.7rem;
  border: none;
}

.reveal tbody tr:nth-child(odd) td {
  background: rgba(255, 255, 255, 0.82);
}

.reveal tbody tr:nth-child(even) td {
  background: rgba(241, 234, 223, 0.76);
}

.callout {
  border: none !important;
  border-radius: 24px !important;
  box-shadow: var(--amlab-shadow);
}

@media (max-width: 1100px) {
  .grid-3,
  .grid-2,
  .workflow-grid,
  .metric-grid,
  .link-grid,
  .two-column-note {
    grid-template-columns: 1fr;
  }

  .reveal {
    font-size: 30px;
  }
}
