/* Anthropic-inspired palette: ivory, slate, clay + muted secondaries */
:root {
  --ivory: #faf9f5;
  --ivory-2: #f0eee6;
  --ivory-3: #e8e4d8;
  --line: #dedad0;
  --ink: #141413;
  --ink-2: #3d3d3a;
  --muted: #73726c;
  --clay: #d97757;
  --clay-d: #a34e32;
  --clay-t: #f5e4db;
  --kraft: #d4a27f;
  --olive: #788c5d;
  --olive-t: #e6eadc;
  --sky: #6a9bcc;
  --sky-t: #e1eaf3;
  --fig: #c46686;
  --heather: #cbcadb;
  --slate: #262624;
  --serif: Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", "Cascadia Code", Consolas, monospace;
}

html,
body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: #e9e6dc;
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

.deck {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
}

.slide {
  display: none;
  position: relative;
  box-sizing: border-box;
  width: min(100vw, 177.78vh);
  height: min(100vh, 56.25vw);
  font-size: min(1.8vw, 3.2vh);
  padding: 2.6em 3.6em 2.8em;
  background: var(--ivory);
  overflow: hidden;
  flex-direction: column;
  gap: 0.7em;
  box-shadow: 0 1px 3px rgba(20, 20, 19, 0.08);
}
.slide.active {
  display: flex;
}

.slide h1,
.slide h2 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.slide h1 {
  font-size: 2.7em;
  margin: 0;
  line-height: 1.08;
}
.slide h2 {
  font-size: 1.8em;
  margin: 0 0 0.35em;
  line-height: 1.15;
}
.slide h3 {
  font-size: 1em;
  margin: 0 0 0.35em;
  font-weight: 600;
  color: var(--ink);
}
.slide p {
  margin: 0.2em 0;
  line-height: 1.5;
  color: var(--ink-2);
}
.slide ul,
.slide ol {
  margin: 0.2em 0;
  padding-left: 1.2em;
  line-height: 1.6;
  color: var(--ink-2);
}
.slide li {
  margin: 0.15em 0;
}
.slide li::marker {
  color: var(--clay);
}
.slide b {
  color: var(--ink);
  font-weight: 600;
}
.slide code {
  font-family: var(--mono);
  font-size: 0.88em;
  background: var(--ivory-2);
  padding: 0.05em 0.35em;
  border-radius: 0.25em;
}
.slide pre {
  font-family: var(--mono);
  background: var(--slate);
  color: #ede9de;
  border-radius: 0.6em;
  padding: 0.8em 1.1em;
  font-size: 0.7em;
  line-height: 1.55;
  margin: 0.3em 0;
  white-space: pre-wrap;
}
.slide pre code {
  background: none;
  padding: 0;
}
.slide a {
  color: var(--clay-d);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.kicker {
  font-size: 0.68em;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--clay-d);
}
.muted {
  color: var(--muted) !important;
}
.small {
  font-size: 0.82em;
}
.tiny {
  font-size: 0.66em;
}
.center {
  text-align: center;
}
.grow {
  flex: 1;
}
.accent {
  color: var(--clay-d);
}
.blue {
  color: #355f8a;
}
.green {
  color: #56693f;
}
.red {
  color: #b0413e;
}
.yellow {
  color: #8a5e26;
}
.purple {
  color: #6b5f95;
}

.grid-2,
.grid-3,
.grid-4,
.grid-5,
.grid-6 {
  display: grid;
  gap: 0.75em;
}
.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}
.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}
.grid-4 {
  grid-template-columns: repeat(4, 1fr);
}
.grid-5 {
  grid-template-columns: repeat(5, 1fr);
}
.grid-6 {
  grid-template-columns: repeat(6, 1fr);
}
.row {
  display: flex;
  gap: 0.8em;
  align-items: center;
}

.card {
  --acc: var(--clay);
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 0.7em;
  padding: 0.75em 0.95em 0.75em 1.15em;
  font-size: 0.84em;
}
.card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.8em;
  bottom: 0.8em;
  width: 0.2em;
  border-radius: 0 0.2em 0.2em 0;
  background: var(--acc);
}
.card.c-chai {
  --acc: var(--clay);
}
.card.c-green {
  --acc: var(--olive);
}
.card.c-red {
  --acc: var(--fig);
}
.card.c-yellow {
  --acc: var(--kraft);
}
.card.c-purple {
  --acc: #8e88b8;
}
.card.c-pink {
  --acc: var(--fig);
}
.card:not([class*="c-"]) {
  --acc: var(--sky);
}
.card h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.12em;
}
.card p {
  font-size: 0.95em;
}
.card .emoji {
  display: none;
}

.big {
  font-family: var(--serif);
  font-size: 3.4em;
  font-weight: 500;
  line-height: 1;
}
.huge {
  font-family: var(--serif);
  font-size: 5em;
  font-weight: 500;
  line-height: 1;
}

/* Section dividers: dark slate */
.slide.section {
  justify-content: center;
  background: var(--slate);
}
.slide.section h1 {
  font-size: 3.3em;
  color: var(--ivory);
}
.slide.section h2,
.slide.section h3 {
  color: var(--ivory);
}
.slide.section p {
  color: #c9c5b8;
}
.slide.section b {
  color: var(--ivory);
}
.slide.section .red b,
.slide.section .accent b,
.slide.section .green b {
  color: inherit;
}
.slide.section .accent,
.slide.section b.accent,
.slide.section span.accent {
  color: var(--clay);
}
.slide.section .red {
  color: #e58a7e;
}
.slide.section .green {
  color: #a9bd8a;
}
.slide.section .muted {
  color: #9c998f !important;
}
.slide.section .kicker,
.slide.section .num {
  color: var(--clay);
}
.slide.section .num {
  font-size: 0.75em;
  font-weight: 600;
  letter-spacing: 0.16em;
  margin-bottom: 0.6em;
}
.slide.section::after {
  content: "";
  position: absolute;
  right: -8em;
  bottom: -8em;
  width: 22em;
  height: 22em;
  border-radius: 50%;
  border: 1px solid rgba(217, 119, 87, 0.35);
}

/* Title slides */
.slide.title {
  justify-content: center;
}
.slide.title h1 {
  font-size: 3.4em;
}
.slide.title::after {
  content: "";
  position: absolute;
  right: 3.6em;
  top: 2.6em;
  width: 3.2em;
  height: 3.2em;
  background: var(--clay);
  clip-path: polygon(
    50% 0,
    61% 39%,
    100% 50%,
    61% 61%,
    50% 100%,
    39% 61%,
    0 50%,
    39% 39%
  );
}
.slide.title::before {
  content: "";
  position: absolute;
  left: 3.6em;
  right: 3.6em;
  bottom: 3em;
  height: 1px;
  background: var(--line);
}

/* Pills */
.tag {
  display: inline-flex;
  gap: 0.6em;
  align-items: center;
  width: fit-content;
  background: var(--clay-t);
  color: var(--clay-d);
  font-weight: 600;
  padding: 0.3em 0.85em;
  border-radius: 99em;
  font-size: 0.7em;
  letter-spacing: 0.04em;
}
.tag.blue {
  background: var(--sky-t);
  color: #355f8a;
}
.tag.green {
  background: var(--olive-t);
  color: #56693f;
}
.tag.red {
  background: #f4dedf;
  color: #9c3b45;
}
.pill {
  display: inline-block;
  padding: 0.1em 0.6em;
  border-radius: 99em;
  font-size: 0.75em;
  font-weight: 600;
  background: var(--ivory-2);
  border: 1px solid var(--line);
}

/* Fragments */
.frag {
  opacity: 0;
  transform: translateY(0.35em);
  transition:
    opacity 0.35s ease,
    transform 0.35s ease;
}
.frag.shown {
  opacity: 1;
  transform: none;
}

/* Tables */
table.t {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.8em;
  background: #fff;
  border-radius: 0.6em;
  overflow: hidden;
  border: 1px solid var(--line);
}
table.t th,
table.t td {
  border-bottom: 1px solid var(--line);
  padding: 0.5em 0.8em;
  text-align: left;
  vertical-align: top;
  color: var(--ink-2);
}
table.t th {
  background: var(--ivory-2);
  color: var(--ink);
  font-weight: 600;
}
table.t tr:last-child td {
  border-bottom: 0;
}

table.resp {
  border-collapse: separate;
  border-spacing: 0.25em;
  width: 100%;
  font-size: 0.72em;
}
table.resp th {
  color: var(--ink);
  font-weight: 600;
  padding: 0.2em;
}
table.resp td {
  text-align: center;
  padding: 0.38em;
  border-radius: 0.35em;
  font-weight: 500;
}
table.resp td.you {
  background: var(--clay-t);
  color: var(--clay-d);
}
table.resp td.them {
  background: var(--olive-t);
  color: #4a5e35;
}
table.resp td.layer {
  background: transparent;
  text-align: right;
  color: var(--muted);
  font-weight: 400;
}

/* Timeline */
.timeline {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin-top: 1em;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 1.15em;
  height: 1px;
  background: var(--ink);
  opacity: 0.35;
}
.timeline .ev {
  position: relative;
  width: 8%;
  text-align: center;
  font-size: 0.64em;
  color: var(--ink-2);
}
.timeline .ev b {
  display: block;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.35em;
  color: var(--ink);
  background: var(--ivory);
  position: relative;
  padding-bottom: 1em;
}
.timeline .ev::before {
  content: "";
  position: absolute;
  top: 1.55em;
  left: 50%;
  width: 0.75em;
  height: 0.75em;
  margin-left: -0.375em;
  border-radius: 50%;
  background: var(--clay);
  z-index: 1;
}

/* Stacks */
.stack {
  display: flex;
  flex-direction: column;
  gap: 0.22em;
  font-size: 0.72em;
}
.stack div {
  padding: 0.4em;
  border-radius: 0.3em;
  text-align: center;
  font-weight: 500;
}
.stack .app {
  background: var(--clay-d);
  color: #fff;
}
.stack .lib {
  background: var(--clay-t);
  color: var(--clay-d);
}
.stack .os {
  background: var(--sky-t);
  color: #355f8a;
}
.stack .hv {
  background: #f1e3d3;
  color: #8a5a2e;
}
.stack .hw {
  background: var(--slate);
  color: var(--ivory);
}
.stack .rt {
  background: var(--olive-t);
  color: #4a5e35;
}
.stack .row2 {
  display: flex;
  gap: 0.22em;
  padding: 0;
}
.stack .row2 > div {
  flex: 1;
}

/* Architecture boxes */
.arch {
  display: flex;
  align-items: center;
  gap: 0.45em;
  justify-content: center;
  flex-wrap: wrap;
}
.arch .box {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 0.45em;
  padding: 0.5em 0.7em;
  font-size: 0.72em;
  text-align: center;
  min-width: 6em;
  color: var(--ink-2);
}
.arch .box.hl {
  border-color: var(--clay);
  box-shadow: 0 0 0 2px var(--clay-t);
}
.arch .arrow {
  color: var(--clay);
  font-size: 1em;
}

blockquote {
  margin: 0.4em 0;
  padding: 0.6em 1.1em;
  border-left: 2px solid var(--clay);
  font-family: var(--serif);
  font-size: 1.1em;
  color: var(--ink);
  background: transparent;
}

/* Timer */
.timer {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  width: fit-content;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 99em;
  padding: 0.25em 0.4em 0.25em 0.9em;
  font-family: var(--mono);
  font-size: 0.9em;
}
.timer .lbl {
  font-family: var(--sans);
  font-size: 0.65em;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.timer .t {
  font-size: 1.35em;
  font-weight: 600;
  min-width: 3.2em;
  text-align: center;
  color: var(--ink);
}
.timer button {
  font-family: var(--sans);
  background: var(--ink);
  color: var(--ivory);
  border: 0;
  border-radius: 99em;
  padding: 0.35em 0.9em;
  cursor: pointer;
  font-size: 0.68em;
  font-weight: 600;
}
.timer button + button {
  background: var(--ivory-2);
  color: var(--ink);
}
.timer.done {
  border-color: var(--clay);
  background: var(--clay-t);
}
.timer.done .t {
  color: var(--clay-d);
}

/* Chrome */
.progress {
  position: fixed;
  left: 0;
  bottom: 0;
  height: 3px;
  background: var(--clay);
  transition: width 0.25s;
  z-index: 10;
}
.counter {
  position: fixed;
  right: 14px;
  bottom: 10px;
  font-size: 12px;
  color: var(--muted);
  z-index: 10;
  font-variant-numeric: tabular-nums;
}
.help {
  position: fixed;
  left: 14px;
  bottom: 10px;
  font-size: 11px;
  color: var(--muted);
  z-index: 10;
}

.breaking {
  font-size: 0.7em;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--clay);
  width: fit-content;
  border: 1px solid var(--clay);
  border-radius: 99em;
  padding: 0.3em 0.9em;
}
.breaking::before {
  content: "";
  display: inline-block;
  width: 0.55em;
  height: 0.55em;
  border-radius: 50%;
  background: var(--clay);
  margin-right: 0.6em;
  animation: pulse 1.2s infinite;
}
@keyframes pulse {
  50% {
    opacity: 0.25;
  }
}

.envelope {
  margin: 0 auto;
  width: 15em;
  height: 9.5em;
  background: #ebdbbc;
  border-radius: 0.4em;
  position: relative;
  box-shadow: 0 1.2em 2.4em rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: center;
  font-weight: 700;
}
.envelope::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 58%;
  background: #dcc79f;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  border-radius: 0.4em 0.4em 0 0;
}
.envelope span {
  position: relative;
  margin-top: 3em;
  border: 2px solid var(--clay-d);
  color: var(--clay-d);
  padding: 0.2em 0.7em;
  transform: rotate(-6deg);
  letter-spacing: 0.12em;
  font-size: 0.8em;
}

/* Networking icebreakers: local QR assets stay available without a QR service. */
.network-grid {
  display: grid;
  grid-template-columns: 1fr 12em;
  gap: 1.3em;
  align-items: start;
  min-height: 0;
}
.network-profile {
  text-align: center;
}
.network-profile img {
  display: block;
  width: 9em;
  height: 9em;
  margin: 0 auto 0.45em;
  background: #fff;
}
.network-profile a {
  overflow-wrap: anywhere;
}
.network-credit {
  font-size: 0.72em;
  padding: 0.45em 0.7em;
  border-radius: 0.4em;
  background: var(--olive-t);
}
.network-activity .timer {
  margin-top: 0.5em;
}

.deck-controls {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  display: flex;
  gap: 8px;
  align-items: center;
  background: #faf9f5;
  border: 1px solid #dedad0;
  border-radius: 12px;
  padding: 8px;
  max-width: calc(100% - 24px);
  box-shadow: 0 4px 16px #14141312;
  font: 13px system-ui;
}
.deck-controls button,
.deck-controls select,
.deck-controls a {
  min-height: 44px;
  padding: 10px;
  border: 1px solid #dedad0;
  border-radius: 8px;
  background: white;
  color: #233e34;
  font: inherit;
  text-decoration: none;
}
.deck-controls select {
  max-width: 220px;
}
.deck-controls :focus-visible {
  outline: 3px solid #a34e32;
  outline-offset: 2px;
}
.reading {
  height: auto;
  overflow: auto;
  background: #f8f7f2;
}
.reading .deck {
  height: auto;
  display: block;
}
.reading .slide,
.reading .slide.active {
  display: flex;
  position: relative;
  transform: none;
  inset: auto;
  width: calc(100% - 24px);
  height: auto;
  min-height: 0;
  max-width: 1100px;
  margin: 24px auto;
  padding: 28px;
  font-size: 17px;
  overflow: visible;
  border: 1px solid #dedad0;
  border-radius: 16px;
}
.reading .slide .frag {
  visibility: visible;
  opacity: 1;
  transform: none;
}
.reading .slide h1,
.reading .slide.title h1,
.reading .slide.section h1 {
  font-size: clamp(30px, 5vw, 48px) !important;
}
.reading .slide h2 {
  font-size: 28px;
}
.reading .deck-controls {
  position: sticky;
  top: 0;
  bottom: auto;
  left: auto;
  transform: none;
  margin: 0 auto 16px;
  flex-wrap: wrap;
  max-width: 1100px;
}
.reading .help,
.reading .counter,
.reading .progress {
  display: none;
}
.reading .timeline {
  flex-wrap: wrap;
  gap: 20px;
}
.reading .timeline .ev {
  width: 25%;
  font-size: 14px;
}
.reading .slide pre {
  font-size: 14px;
  overflow: auto;
}
.reading .slide .network-grid {
  grid-template-columns: 1fr 180px;
}
.reading .slide .grid {
  min-width: 0;
}
.reading .slide .small,
.reading .slide .tiny {
  font-size: 15px;
}
.reading .slide table {
  display: block;
  max-width: 100%;
  overflow: auto;
}
.reading .slide .arch {
  flex-wrap: wrap;
}
.reading .slide .arch .box {
  min-width: 0;
}
.reading .slide .card {
  min-width: 0;
}
.reading .slide .card:before {
  display: none;
}
@media (max-width: 700px) {
  .deck-controls {
    flex-wrap: wrap;
    justify-content: center;
    width: calc(100% - 24px);
  }
  .deck-controls select {
    max-width: 100%;
    flex: 1;
    min-width: 120px;
  }
  .reading .slide {
    padding: 22px;
  }
  .reading .slide .grid,
  .reading .slide .network-grid {
    grid-template-columns: 1fr !important;
  }
  .reading .slide .timeline .ev {
    width: 40%;
  }
  .reading .slide .resp {
    font-size: 14px;
  }
}
@media print {
  .deck-controls {
    display: none !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}

.reading .slide [class*="grid-"] {
  min-width: 0;
}
.reading .slide .grow {
  flex: none;
}
.reading .deck {
  padding-top: 8px;
}
.reading .slide:first-child {
  margin-top: 12px;
}
@media (max-width: 700px) {
  .reading .slide [class*="grid-"] {
    grid-template-columns: 1fr !important;
  }
  .reading .slide .network-profile img {
    max-width: 100%;
    height: auto;
  }
  .reading .slide .timeline:before {
    display: none;
  }
}

/* Reserve a separate control rail instead of covering slide content. */
body:not(.reading) .deck {
  bottom: 100px;
}
body:not(.reading) .slide {
  width: min(100vw, calc((100vh - 100px) * 1.7778));
  height: min(calc(100vh - 100px), 56.25vw);
  font-size: min(1.8vw, calc((100vh - 100px) * 0.032));
}
.reading .deck {
  position: relative;
  inset: auto;
}
.reading .slide {
  scroll-margin-top: 150px;
}

html:has(body.reading){height:auto;overflow:auto}body.reading{overflow:visible}

.reading .slide{overflow:hidden}

/* Concept illustrations explain the workshop without changing its slide count. */
.illustrated-split{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);gap:1em;align-items:center;min-height:0}.illustrated-split.roles-split{grid-template-columns:minmax(0,1fr) minmax(0,1.4fr)}.concept-art{display:block;width:100%;height:auto;max-height:100%;object-fit:contain;background:#fff;border:1px solid var(--line);border-radius:.5em;min-width:0}.illustration-copy{min-width:0}.illustration-copy p{font-size:.86em;margin:.5em 0}.illustration-copy .small{font-size:.76em}.reading .illustrated-split{min-height:0}.reading .illustration-copy p{font-size:16px}.reading .illustration-copy .small{font-size:15px}@media(max-width:700px){.reading .illustrated-split,.reading .illustrated-split.roles-split{grid-template-columns:1fr}.reading .illustration-copy .timer{max-width:100%}}
