:root {
  /* Course palette */
  --epfl-red: #ff0000;
  --black: #000000;
  --white: #ffffff;
  --ink: #111111;
  --muted: #555555;
  --line: #dddddd;
  --soft: #f7f7f7;

  --science-yellow: #D79B00;
  --science-green: #82B366;
  --science-purple: #9673A6;
  --science-blue: #6C8EBF;

  /* Responsive type scale */
  --font-small: clamp(0.8rem, 0.9vw, 1rem);
  --font-body: clamp(1rem, 1.35vw, 1.55rem);
  --font-lead: clamp(1.2rem, 1.9vw, 2rem);
  --font-h3: clamp(1.5rem, 2.2vw, 2.4rem);
  --font-h2: clamp(2.2rem, 3.5vw, 4.2rem);
  --font-h1: clamp(3rem, 5vw, 6rem);

  /* Responsive spacing */
  --gap-xs: clamp(0.5rem, 1vw, 1rem);
  --gap-sm: clamp(1rem, 2vw, 2rem);
  --gap-md: clamp(1.5rem, 3.5vw, 4rem);
  --gap-lg: clamp(2rem, 5vw, 6rem);
  --gap-xl: clamp(3rem, 7vw, 8rem);

  --vgap-xs: clamp(0.5rem, 1vh, 1rem);
  --vgap-sm: clamp(1rem, 2vh, 2rem);
  --vgap-md: clamp(1.5rem, 3vh, 3rem);
  --vgap-lg: clamp(2rem, 5vh, 5rem);

  --slide-padding-x: clamp(2rem, 5vw, 6rem);
  --slide-padding-y: clamp(1.5rem, 3vh, 3rem);
  --shadow-soft: 0 10px 35px rgba(0,0,0,0.08);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  width: 100%;
  min-height: 100%;
  background: var(--white);
  color: var(--black);
  font-family: Arial, Helvetica, sans-serif;
  font-size: var(--font-body);
}

body.mode-deck { overflow: hidden; }
body.mode-scroll { overflow-y: auto; overflow-x: hidden; }

button, input, select, textarea { font: inherit; }

.deck {
  width: 100vw;
  min-height: 100vh;
}

body.mode-deck .deck {
  display: flex;
  flex-direction: row;
  height: 100vh;
  transition: transform 260ms ease;
}

body.mode-scroll .deck {
  display: block;
  transform: none !important;
}

.slide {
  width: 100vw;
  height: 100vh;
  padding: var(--slide-padding-y) var(--slide-padding-x);
  background: var(--white);
  color: var(--black);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

body.mode-deck .slide {
  flex: 0 0 100vw;
}

body.mode-scroll .slide {
  min-height: 100vh;
  height: auto;
  border-bottom: 1px solid var(--line);
}

.slide-title,
.course-title {
  margin: 0;
  line-height: 1.05;
  letter-spacing: -0.035em;
  color: var(--black);
}

.slide-title {
  font-size: var(--font-h2);
  font-weight: 700;
  margin-bottom: var(--vgap-md);
}

.course-title {
  font-size: var(--font-h1);
  font-weight: 700;
}

.eyebrow {
  margin: 0 0 var(--vgap-sm) 0;
  color: var(--epfl-red);
  font-size: var(--font-small);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.subtitle,
.lead {
  font-size: var(--font-lead);
  line-height: 1.35;
  font-weight: 400;
  /* max-width: 42ch; */
}

p {
  line-height: 1.42;
  max-width: 62ch;
}

.small-text,
.caption,
figcaption {
  font-size: var(--font-small);
  color: var(--muted);
  line-height: 1.35;
}

.equation {
  font-size: var(--font-lead);
  text-align: center;
  margin-block: var(--vgap-md);
}

.minimal-list {
  margin: var(--vgap-md) 0 0 0;
  padding-left: 1.2em;
  font-size: var(--font-lead);
  line-height: 1.5;
}

.minimal-list li { margin-bottom: var(--vgap-sm); }
.minimal-list li::marker { color: var(--epfl-red); }

.debug { outline: 1px solid rgba(255,0,0,0.25); }
