/* Tanzania 2027 sales deck shell. Everything sizes from rem; rem tracks the viewport so the
   same slide reads at 1280x720 and 1920x1080 on a screen share. */
:root {
  --terracotta: #C4754B;
  --terracotta-dark: #A65F3A;
  --earth: #2C2420;
  --charcoal: #1E1A17;
  --warm-white: #FDFBF7;
  --cream: #F5F0E8;
  --stone: #6B5D4D;
  --sand: #E8E0D4;
  --terracotta-ink: #8F5130;
  --apricot: #E9B48F;
  --img-shadow: 0 1px 4px rgba(20,16,13,0.45), 0 2px 18px rgba(20,16,13,0.4);
  --display: 'Instrument Serif', 'Times New Roman', serif;
  --body: 'DM Sans', 'Helvetica Neue', sans-serif;
}

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

html {
  /* 24px at 1920x1080, 16px at 1280x720; the height term keeps tall-narrow windows from overflowing */
  font-size: min(1.25vw, 2.222vh);
  background: var(--charcoal);
}

body {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background: var(--charcoal);
  color: var(--warm-white);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--terracotta); color: var(--warm-white); }

#deck { position: fixed; inset: 0; }

/* ============ SLIDES: one visible at a time ============ */
.slide {
  position: absolute;
  inset: 0;
  display: none;
  overflow: hidden;
  padding: 5rem 6rem;
  background: var(--earth);
  color: var(--warm-white);
}
.slide.active { display: flex; flex-direction: column; justify-content: center; }

/* One load transition per slide: the headline rises once as the slide appears. */
.slide.active > h1,
.slide.active > h2 { animation: rise 0.45s ease-out both; }
@keyframes rise {
  from { opacity: 0; transform: translateY(0.75rem); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .slide.active > h1, .slide.active > h2 { animation: none; }
}

.slide h1, .slide h2, .slide h3 { font-family: var(--display); font-weight: 400; line-height: 1.05; }
.slide h1 { font-size: 5.5rem; }
.slide h2 { font-size: 4rem; }
.slide h3 { font-size: 2.5rem; }
.slide p { font-size: 1.5rem; max-width: 40rem; }
.slide .kicker {
  margin-top: 1.25rem;
  font-size: 1.125rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--apricot);
}

.slide-title { align-items: flex-start; }

/* Light slides */
.slide.light { background: var(--cream); color: var(--earth); }
.slide.light .kicker { color: var(--terracotta-ink); }

/* Full-bleed photo slides: put the image on the slide as background-image, text above it */
.slide.photo { background-size: cover; background-position: center; justify-content: flex-end; }

/* Scrim: a gradient that carries text legibility without the photo's dark areas helping.
   Any slide with [data-overlay-text] must have this class (the checker enforces it). */
.scrim { position: absolute; }
.scrim::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(to top, rgba(20,16,13,0.88) 0%, rgba(20,16,13,0.62) 38%, rgba(20,16,13,0.18) 70%, rgba(20,16,13,0) 100%);
  pointer-events: none;
}
.scrim > * { position: relative; z-index: 1; }
[data-overlay-text] { text-shadow: var(--img-shadow); }

/* ============ COLLAGES: 3, 4 and 5 images ============ */
.collage {
  display: grid;
  gap: 0.5rem;
  flex: 1;
  min-height: 0;
  width: 100%;
}
.collage img { width: 100%; height: 100%; min-height: 0; object-fit: cover; display: block; }

/* 3: one tall hero left, two stacked right */
.collage.c3 { grid-template-columns: 1.4fr 1fr; grid-template-rows: 1fr 1fr; }
.collage.c3 > :nth-child(1) { grid-row: 1 / span 2; }

/* 4: two by two */
.collage.c4 { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; }

/* 5: large left, four small in a 2x2 right */
.collage.c5 { grid-template-columns: 1.6fr 1fr 1fr; grid-template-rows: 1fr 1fr; }
.collage.c5 > :nth-child(1) { grid-row: 1 / span 2; }
