/* ==========================================================================
   AI Tools for Business Research — NUS Business School, 4–5 August 2026

   The slides' identity, on the web. From zenbeamer.sty:
     paper   #F2ECDD  rice paper
     ink     #2A2622  sumi
     inksoft #6E665A  secondary
     seal    #B2402F  vermillion 朱红 — the only accent
     stone   #A79D8C  rules

   Sumi ink on rice paper, one vermillion accent, generous negative space,
   a brushed enso. Palatino for prose; Optima, tracked and uppercased, for
   the micro-labels. No radii, no shadows. Motion is brushed, not animated.
   ========================================================================== */

:root {
  color-scheme: light;

  --paper:      #F2ECDD;
  --paper-deep: #E8E0CD;
  --ink:        #2A2622;
  --ink-soft:   #6E665A;
  --stone:      #A79D8C;
  --rule:       #C9C0AE;          /* stone at ~45% over paper */
  --seal:       #B2402F;
  --seal-lift:  #8E3325;
  --paper-plate: #F2ECDD;

  /* the agent surface — warm, so it stays inside one colour system */
  --wash:      #E8E0CD;
  --wash-rule: #C9C0AE;
  --mono-ink:  #3A342C;

  --serif: Palatino, "Palatino Linotype", "Iowan Old Style", "Book Antiqua",
           "URW Palladio L", Georgia, serif;
  --sans:  Optima, Candara, "Gill Sans", "Gill Sans MT", "Trebuchet MS",
           -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono:  ui-monospace, "SF Mono", SFMono-Regular, Menlo, "Cascadia Mono",
           Consolas, "Liberation Mono", monospace;

  --shell:   62rem;
  --measure: 38rem;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper:      #1E1B18;
    --paper-deep: #262220;
    --ink:        #EDE5D6;
    --ink-soft:   #A79D8C;
    --stone:      #6E665A;
    --rule:       #3D3730;
    --seal:       #D0604E;
    --seal-lift:  #E47966;
    --paper-plate: #F2ECDD;
    --wash:       #262220;
    --wash-rule:  #3D3730;
    --mono-ink:   #DCD3C2;
  }
}

/* explicit toggle wins over the OS in both directions */
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper:      #1E1B18;
  --paper-deep: #262220;
  --ink:        #EDE5D6;
  --ink-soft:   #A79D8C;
  --stone:      #6E665A;
  --rule:       #3D3730;
  --seal:       #D0604E;
  --seal-lift:  #E47966;
  --paper-plate: #F2ECDD;
  --wash:       #262220;
  --wash-rule:  #3D3730;
  --mono-ink:   #DCD3C2;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.68;
  text-rendering: optimizeLegibility;
}

/* --- shell ------------------------------------------------------------ */

.shell { max-width: var(--shell); margin: 0 auto; padding: 0 1.5rem; }
.measure { max-width: var(--measure); }

.skip {
  position: absolute; left: -9999px;
  background: var(--seal); color: var(--paper);
  padding: .6rem 1rem; z-index: 40;
}
.skip:focus { left: 1rem; top: 1rem; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

:focus-visible {
  outline: 2px solid var(--seal);
  outline-offset: 3px;
}

/* --- b. reading progress: the deck's seal bar, moved to the top ------- */

.progress {
  position: fixed; top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--rule);
  z-index: 30;
}
.progress > i {
  display: block; height: 100%; width: 0;
  background: var(--seal);
  transform-origin: 0 50%;
}

/* --- masthead --------------------------------------------------------- */

.masthead {
  border-bottom: 1px solid var(--rule);
  padding: 1.1rem 0;
}
.masthead .shell {
  display: flex; flex-wrap: wrap; gap: .75rem 1.5rem;
  align-items: center; justify-content: space-between;
}
/* the official lockup, same two assets the decks put on every page:
   crest 0.86cm + wordmark 0.50cm, so the crest sits ~1.7x the wordmark height */
.lockup {
  display: inline-flex; align-items: center; gap: .7rem;
  background-image: none; padding: 0;
}
.lockup img { display: block; width: auto; }
.lockup-crest { height: 2.05rem; }
.lockup-word  { height: 1.2rem; }

/* the logos are fixed-colour brand assets and must not be recoloured, so on the
   dark theme they sit on a small rice-paper plate — the logo printed on paper */
:root[data-theme="dark"] .lockup,
:root[data-theme="dark"] .lockup:hover { background: var(--paper-plate); padding: .35rem .6rem; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .lockup { background: var(--paper-plate); padding: .35rem .6rem; }
}

.mast-right { display: flex; align-items: baseline; gap: 1.4rem; }

.nav {
  font-family: var(--sans); font-size: .8rem; letter-spacing: .06em;
  position: relative;
}
.nav a { margin-left: 1.4rem; text-decoration: none; }
.nav a:first-child { margin-left: 0; }
.nav a { color: var(--ink-soft); }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"],
.nav a.is-here {
  color: var(--ink);
  box-shadow: inset 0 -2px 0 0 var(--seal);
}
.nav a.is-here { transition: box-shadow 200ms ease, color 200ms ease; }

/* --- i. the ink toggle ------------------------------------------------ */

.inktoggle {
  font-family: var(--sans);
  font-size: .66rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink-soft);
  background: none; border: 0; padding: .2rem 0;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: .5rem;
}
/* the button does nothing without JS, so it must stay hidden then */
.inktoggle[hidden] { display: none; }
.inktoggle:hover { color: var(--ink); }
.inktoggle::before {
  content: ""; width: .55em; height: .55em;
  background: var(--seal);
  transition: transform 180ms ease, background 180ms ease;
}
.inktoggle:hover::before { transform: rotate(3deg) scale(1.1); }

/* --- g. links: an underline brushed in from the left ------------------ */

a {
  color: var(--ink);
  text-decoration: none;
  background-image: linear-gradient(var(--seal), var(--seal));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% 1px;
  padding-bottom: 1px;
  transition: background-size 180ms ease, color 180ms ease;
}
a:hover { color: var(--seal); background-size: 100% 2px; }
main a { background-size: 0 1px; }
main a:hover, main a:focus-visible { background-size: 100% 1px; color: var(--seal); }
/* prose links need to look like links before hover */
.band p a, .plain a, .kv a, td a, figcaption a, .foot a {
  background-size: 100% 1px;
  color: var(--seal);
}
.band p a:hover, .plain a:hover, .kv a:hover, td a:hover,
figcaption a:hover, .foot a:hover { background-size: 100% 2px; color: var(--seal-lift); }

/* --- hero ------------------------------------------------------------- */

.hero { padding: 4.5rem 0 3.5rem; }
.hero .shell { position: relative; }

.eyebrow {
  font-family: var(--sans);
  font-size: .72rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 1.5rem;
}
.eyebrow b { color: var(--seal); font-weight: 600; }

.hero h1 {
  font-size: clamp(2.7rem, 7.5vw, 4.6rem);
  line-height: .98;
  font-weight: 400;
  letter-spacing: -.02em;
  margin: 0 0 1.4rem;
  max-width: 14ch;
}
.hero h1 em { font-style: italic; }

.standfirst {
  font-size: 1.2rem;
  color: var(--ink-soft);
  max-width: 34rem;
  margin: 0 0 .6rem;
  text-wrap: pretty;   /* no one-word last line; ignored where unsupported */
}

.hero h1, .band h2, .tl-body h4 { text-wrap: balance; }

.facts {
  font-family: var(--sans);
  font-size: .82rem;
  letter-spacing: .04em;
  color: var(--ink-soft);
  margin: 0 0 2.75rem;
}
.facts strong { color: var(--ink); font-weight: 600; }

/* --- a. the enso, drawn ---------------------------------------------- */

.enso {
  position: absolute;
  top: -.5rem; right: 1.5rem;
  width: 12rem; height: 12rem;
  pointer-events: none;
}
.enso svg { width: 100%; height: 100%; display: block; }
.enso .stroke { fill: var(--ink); }
.enso .fleck  { fill: var(--ink); }

/* paint it: a mask wipes along the stroke's own direction */
@keyframes enso-draw {
  from { stroke-dashoffset: var(--len); }
  to   { stroke-dashoffset: 0; }
}
.enso .wipe {
  fill: none;
  stroke: #fff;
  stroke-linecap: round;
  stroke-dasharray: var(--len);
  stroke-dashoffset: 0;
}
.enso.is-drawing .wipe {
  animation: enso-draw 1600ms cubic-bezier(.16,.72,.3,1) both;
}
@keyframes fleck-in { from { opacity: 0 } to { opacity: 1 } }
.enso.is-drawing .fleck { animation: fleck-in 400ms ease 1500ms both; }

/* --- the signature: a sentence you type ------------------------------- */

.prompt {
  margin: 0 0 1.25rem;
  background: var(--wash);
  border-left: 3px solid var(--seal);
  padding: 1.15rem 1.35rem;
  max-width: 44rem;
  position: relative;
}
.prompt pre {
  margin: 0;
  font-family: var(--mono);
  font-size: .875rem;
  line-height: 1.65;
  color: var(--mono-ink);
  white-space: pre-wrap;
  word-break: break-word;
}
.prompt .caret { color: var(--seal); font-weight: 700; user-select: none; }
.prompt figcaption {
  margin-top: .85rem;
  padding-top: .7rem;
  border-top: 1px solid var(--wash-rule);
  font-family: var(--sans);
  font-size: .8rem;
  color: var(--ink-soft);
}
.prompt--bare { border-left-color: var(--wash-rule); }

/* c. the typing caret, while the hero prompt writes itself */
.is-typing .cursor {
  display: inline-block;
  width: .5em; height: 1em;
  vertical-align: -.15em;
  background: var(--seal);
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0 } }

/* h. copy button */
.copy {
  position: absolute; top: .5rem; right: .5rem;
  font-family: var(--sans);
  font-size: .62rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-soft);
  background: none; border: 1px solid var(--wash-rule);
  padding: .25rem .5rem;
  cursor: pointer;
  opacity: 0;
  transition: opacity 160ms ease, color 160ms ease, border-color 160ms ease;
}
.prompt:hover .copy, .copy:focus-visible { opacity: 1; }
.copy:hover { color: var(--seal); border-color: var(--seal); }
.copy.is-done { color: var(--seal); border-color: var(--seal); opacity: 1; }

/* inline code sits on the same warm surface */
code {
  font-family: var(--mono);
  font-size: .855em;
  background: var(--wash);
  color: var(--mono-ink);
  padding: .12em .38em;
}
.prompt code, pre code { background: none; padding: 0; font-size: inherit; color: inherit; }
a code { color: inherit; }

/* --- sections --------------------------------------------------------- */

.band { padding: 3.25rem 0; border-top: 1px solid var(--rule); }
.band--sunk { background: var(--paper-deep); }

/* the deck's frame title: seal square, then a stone hairline under it */
.band h2 {
  font-size: clamp(1.45rem, 3vw, 1.95rem);
  font-weight: 600;
  letter-spacing: -.01em;
  line-height: 1.2;
  margin: 0 0 1.25rem;
  padding-bottom: .7rem;
  position: relative;
}
.band h2::before {
  content: "";
  display: inline-block;
  width: .55em; height: .55em;
  background: var(--seal);
  margin-right: .5em;
  vertical-align: .06em;
  transition: transform 180ms ease;
}
.band h2:hover::before { transform: rotate(3deg) scale(1.08); }
.band h2::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 13rem; max-width: 34%;
  height: 1px;
  background: var(--stone);
}
.band h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 2rem 0 .4rem;
}
.band p { margin: 0 0 1rem; max-width: var(--measure); }
.lede { font-size: 1.1rem; }

/* --- d. ink-wash reveal ---------------------------------------------- */
/* JS adds .js-reveal to <html> first, so no-JS never hides anything */

.js-reveal .reveal { opacity: 0; transform: translateY(10px); }
.js-reveal .reveal.is-inked {
  opacity: 1; transform: none;
  transition: opacity 500ms ease, transform 500ms cubic-bezier(.2,.7,.3,1);
}

/* --- outcome list ----------------------------------------------------- */

.outcomes { list-style: none; margin: 1.5rem 0 0; padding: 0; }
.outcomes li {
  border-top: 1px solid var(--rule);
  padding: 1.05rem 0;
  max-width: 44rem;
}
.outcomes b {
  display: block;
  font-family: var(--sans);
  font-size: .74rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--seal);
  margin-bottom: .3rem;
}

/* --- told / done split ------------------------------------------------ */

.split {
  display: grid; gap: 0 2.5rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 1.75rem 0 0;
}
.split > div { border-top: 2px solid var(--ink); padding-top: .9rem; }
.split > div + div { border-top-color: var(--seal); }
.split h3 {
  font-family: var(--sans);
  font-size: .74rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
  margin: 0 0 .8rem;
  color: var(--ink-soft);
}
.split > div + div h3 { color: var(--seal); }
.split ul { margin: 0; padding-left: 1.1rem; }
.split li { margin-bottom: .6rem; font-size: .98rem; }
.split li::marker { color: var(--stone); }
.split > div + div li::marker { color: var(--seal); }

/* --- plain bullet list ------------------------------------------------ */

.plain { max-width: var(--measure); padding-left: 1.1rem; margin: 0 0 1rem; }
.plain li { margin-bottom: .5rem; }
.plain li::marker { color: var(--seal); }

/* --- the two days ----------------------------------------------------- */

.dayhead {
  font-family: var(--sans);
  font-size: .74rem; font-weight: 700;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--ink);
  margin: 2.5rem 0 0;
  padding-bottom: .5rem;
  border-bottom: 2px solid var(--ink);
}
.dayhead:first-of-type { margin-top: 1.5rem; }
.dayhead span { color: var(--ink-soft); font-weight: 400; letter-spacing: .08em; }

.timeline { list-style: none; margin: 0; padding: 0; }
.timeline > li {
  display: grid;
  grid-template-columns: 8.5rem 1fr;
  gap: 0 1.75rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--rule);
}
.tl-meta { font-family: var(--sans); font-size: .78rem; line-height: 1.5; }
.tl-time {
  display: block;
  font-size: 1rem; font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.tl-dur { display: block; color: var(--ink-soft); }
.tl-who { display: block; color: var(--seal); }

.tl-body { border-left: 1px solid var(--rule); padding-left: 1.75rem; }
.tl-body h4 {
  font-size: 1.08rem; font-weight: 600;
  margin: 0 0 .1rem;
}
.tl-kicker {
  font-style: italic; color: var(--ink-soft);
  font-size: .95rem; margin: 0 0 .4rem;
}
.tl-body p { margin: 0; color: var(--ink-soft); font-size: .98rem; max-width: 34rem; }

.tl-foot {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: .5rem 1.25rem;
  margin-top: .7rem;
}
.tl-hands, .tl-tag {
  font-family: var(--sans);
  font-size: .7rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--seal);
}
.tl-hands::before {
  content: ""; display: inline-block;
  width: .5em; height: .5em; background: var(--seal);
  margin-right: .5em; vertical-align: .04em;
}
.tl-deck {
  font-family: var(--sans);
  font-size: .72rem; letter-spacing: .06em;
}

.timeline > li.is-break { color: var(--ink-soft); }
.is-break .tl-body h4 { font-weight: 400; font-style: italic; color: var(--ink-soft); }

/* --- e. deck covers --------------------------------------------------- */

.deck { display: flex; gap: 1.1rem; align-items: flex-start; margin-top: .85rem; }
.deck-cover {
  flex: 0 0 auto;
  display: block;
  background-image: none;
  padding: 0;
}
.deck-cover img {
  display: block;
  width: 9rem; height: auto;
  border: 1px solid var(--stone);
  transition: transform 200ms ease, border-color 200ms ease;
}
.deck-cover:hover img { transform: translateY(-2px); border-color: var(--seal); }

/* --- people ----------------------------------------------------------- */

.people { display: grid; gap: 2rem; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 1.5rem; }
.person h3 { margin-top: 0; }
.person .role {
  font-family: var(--sans);
  font-size: .74rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--seal); font-weight: 700;
  margin: 0 0 .3rem;
}
.person p { font-size: .98rem; }
.person .affil {
  font-family: var(--sans);
  font-size: .8rem; letter-spacing: .06em;
  color: var(--ink-soft);
  margin: .15rem 0 .7rem;
  padding-bottom: .55rem;
  border-bottom: 1px solid var(--rule);
}

.coords {
  margin-top: 2.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
  font-size: .98rem;
  color: var(--ink-soft);
}

/* --- f. pull quotes --------------------------------------------------- */

.quotes {
  display: grid; gap: 1.75rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 1.75rem 0 0;
}
blockquote.pull {
  margin: 0;
  border-left: 3px solid var(--seal);
  padding: .15rem 0 .15rem 1.15rem;
}
blockquote.pull p {
  margin: 0 0 .8rem;
  font-style: italic;
  font-size: 1.02rem;
  max-width: none;
}
blockquote.pull cite {
  display: block;
  font-family: var(--sans); font-style: normal;
  font-size: .68rem; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-soft);
}

/* --- key/value block -------------------------------------------------- */

.kv { margin: 1.5rem 0 0; display: grid; grid-template-columns: 9rem 1fr; gap: 0; max-width: 44rem; }
.kv dt {
  font-family: var(--sans);
  font-size: .74rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-soft);
  padding: .85rem 0;
  border-top: 1px solid var(--rule);
}
.kv dd {
  margin: 0;
  padding: .85rem 0;
  border-top: 1px solid var(--rule);
}

/* --- tables ----------------------------------------------------------- */

.table-wrap { overflow-x: auto; margin: 1.5rem 0 0; }
table { border-collapse: collapse; width: 100%; min-width: 34rem; font-size: .95rem; }
th, td { text-align: left; padding: .8rem 1rem .8rem 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
thead th {
  font-family: var(--sans);
  font-size: .72rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-soft);
  border-bottom: 2px solid var(--ink);
  white-space: nowrap;
}
td.num { font-variant-numeric: tabular-nums; color: var(--ink-soft); white-space: nowrap; }
td .who { display: block; font-family: var(--sans); font-size: .8rem; color: var(--ink-soft); }
td.cover { width: 7rem; }
td.cover img {
  display: block; width: 6rem; height: auto;
  border: 1px solid var(--stone);
  transition: transform 200ms ease, border-color 200ms ease;
}
td.cover a { background-image: none; padding: 0; }
td.cover a:hover img { transform: translateY(-2px); border-color: var(--seal); }

/* --- notice ----------------------------------------------------------- */

.notice {
  border: 1px solid var(--seal);
  border-left-width: 3px;
  padding: 1.1rem 1.35rem;
  max-width: 44rem;
  margin: 1.75rem 0 0;
  font-size: .96rem;
}
.notice p { margin: 0; max-width: none; }
.notice b { color: var(--seal); }

/* --- practice blocks -------------------------------------------------- */

.practice { border-top: 1px solid var(--rule); padding-top: 1.6rem; margin-top: 2rem; }
.practice > h3 { margin-top: 0; font-size: 1.25rem; }
.practice .meta {
  font-family: var(--sans);
  font-size: .74rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 .9rem;
}
.practice .meta b { color: var(--seal); }

/* --- footer ----------------------------------------------------------- */

.foot {
  border-top: 1px solid var(--rule);
  margin-top: 3rem;
  padding: 2.25rem 0 3.5rem;
  font-family: var(--sans);
  font-size: .8rem;
  color: var(--ink-soft);
}
.foot p { margin: 0 0 .4rem; max-width: 44rem; }

/* --- responsive ------------------------------------------------------- */

@media (max-width: 60rem) {
  .quotes { grid-template-columns: 1fr; gap: 1.5rem; }
  .enso { width: 9rem; height: 9rem; }
}

@media (max-width: 44rem) {
  .timeline > li { grid-template-columns: 1fr; gap: .55rem; }
  .tl-meta { display: flex; gap: .9rem; align-items: baseline; flex-wrap: wrap; }
  .tl-time { font-size: .9rem; }
  .tl-body { border-left: 0; padding-left: 0; }
  .people { grid-template-columns: 1fr; gap: 1.5rem; }
  .split { grid-template-columns: 1fr; gap: 1.5rem; }
  .kv { grid-template-columns: 1fr; }
  .kv dt { padding-bottom: 0; border-top: 1px solid var(--rule); }
  .kv dd { padding-top: .2rem; border-top: 0; }
  .hero { padding: 3rem 0 2.5rem; }
  .enso { display: none; }
  .deck-cover img { width: 7rem; }
  .mast-right { width: 100%; justify-content: space-between; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .enso .wipe { stroke-dashoffset: 0 !important; }
  .js-reveal .reveal { opacity: 1 !important; transform: none !important; }
}

@media print {
  .nav, .skip, .progress, .inktoggle, .copy, .enso { display: none; }
  body { background: #fff; color: #000; }
  .band, .hero { padding: 1rem 0; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .deck-cover, td.cover { display: none; }
}
