/* ==========================================================================
   Encode London Hackathon 2026 - TV deck
   White ground, cyan accents, near-black type, Sora. No gradients.
   Designed as a fixed 1920x1080 stage, scaled to whatever screen it lands on.
   ========================================================================== */

:root {
  --cyan: #08b9d1;
  --cyan-soft: #e3f7fa;
  --ink: #0b0b0b;
  --muted: rgba(11, 11, 11, 0.62);
  --line: rgba(11, 11, 11, 0.12);
  --stage-w: 1920;
  --stage-h: 1080;
  --fade: 700ms;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
  background: #fff;
  color: var(--ink);
  font-family: "Sora", "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  cursor: none;
}

/* A TV should never show a scrollbar or a text caret. */
::-webkit-scrollbar {
  display: none;
}

#viewport {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  overflow: hidden;
}

#stage {
  position: relative;
  width: calc(var(--stage-w) * 1px);
  height: calc(var(--stage-h) * 1px);
  flex: none;
  transform-origin: center center;
  background: #fff;
  overflow: hidden;
}

/* --------------------------------------------------------------- chrome -- */

/* Cyan ribbon with the notched right edge, as used across the event artwork. */
#ribbon {
  position: absolute;
  top: 0;
  left: 0;
  height: 64px;
  display: flex;
  align-items: center;
  z-index: 3;
  background: var(--cyan);
  clip-path: polygon(0 0, 100% 0, calc(100% - 46px) 50%, 100% 100%, 0 100%);
}

#ribbon span {
  position: relative;
  z-index: 1;
  padding: 0 76px 0 44px;
  font-size: 23px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--ink);
}

#brandmark {
  position: absolute;
  top: 42px;
  right: 72px;
  height: 72px;
  width: auto;
  z-index: 3;
}

#stage.bare #ribbon,
#stage.bare #brandmark,
#stage.bare #footer {
  display: none;
}

/* While the deck is being held for review, the badge takes the corner
   the Encode mark normally sits in. */
#stage.paused #brandmark {
  visibility: hidden;
}

#footer {
  position: absolute;
  left: 72px;
  right: 72px;
  bottom: 34px;
  z-index: 3;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  font-size: 21px;
  font-weight: 600;
  color: var(--muted);
}

#footer .left {
  display: flex;
  align-items: center;
  gap: 18px;
}

#footer .event {
  font-weight: 700;
  color: var(--ink);
}

#footer .next {
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#footer .next b {
  color: var(--ink);
}

#progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 8px;
  background: rgba(11, 11, 11, 0.08);
  z-index: 4;
}

#progress .bar {
  height: 100%;
  width: 0;
  background: var(--cyan);
}

#dots {
  display: flex;
  gap: 9px;
  align-items: center;
}

#dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(11, 11, 11, 0.16);
  display: block;
}

#dots i.on {
  background: var(--cyan);
  width: 26px;
  border-radius: 5px;
}

/* ---------------------------------------------------------------- slides -- */

#slides {
  position: absolute;
  inset: 0;
}

.slide {
  position: absolute;
  inset: 0;
  padding: 120px 96px 104px;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--fade) ease-in-out;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.slide.on {
  opacity: 1;
  visibility: visible;
}

.slide.bare {
  padding: 0;
}

/* Headline block ---------------------------------------------------------- */

.head {
  flex: none;
  margin-bottom: 34px;
}

.head .eyebrow {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan);
  margin: 0 0 12px;
}

.head h1 {
  font-size: 72px;
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
  max-width: 1600px;
}

.head .sub {
  font-size: 30px;
  line-height: 1.3;
  font-weight: 600;
  color: var(--muted);
  margin: 16px 0 0;
  max-width: 1400px;
}

.head::after {
  content: "";
  display: block;
  width: 100%;
  height: 4px;
  background: var(--cyan);
  margin-top: 28px;
}

.body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

/* Welcome ---------------------------------------------------------------- */

.welcome {
  height: 100%;
  padding: 96px 120px 88px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.welcome .logo {
  height: 320px;
  width: auto;
  align-self: flex-start;
  margin-bottom: 54px;
}

.welcome h1 {
  font-size: 132px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0;
}

.welcome .rule {
  width: 420px;
  height: 8px;
  background: var(--cyan);
  margin: 44px 0 40px;
}

.welcome .dates {
  font-size: 60px;
  font-weight: 700;
  margin: 0 0 18px;
}

.welcome .venue {
  font-size: 40px;
  font-weight: 600;
  color: var(--muted);
  margin: 0;
}

/* Schedule / bounty rows -------------------------------------------------- */

.rows {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1 1 auto;
  min-height: 0;
}

.row {
  display: flex;
  align-items: center;
  gap: 44px;
  padding: 22px 0;
  border-top: 2px solid var(--line);
}

.row:first-child {
  border-top: 0;
}

.row .when {
  flex: none;
  width: 330px;
  font-size: 46px;
  font-weight: 800;
  color: var(--cyan);
  letter-spacing: -0.01em;
}

.row .what {
  flex: 1 1 auto;
  min-width: 0;
}

.row .what .t {
  font-size: 46px;
  font-weight: 700;
  line-height: 1.12;
}

.row .what .n {
  font-size: 34px;
  font-weight: 600;
  color: var(--muted);
  margin-top: 4px;
  line-height: 1.2;
}

/* A short list gets bigger type and sits in the middle of the slide. */
.rows.roomy {
  justify-content: center;
}

.rows.roomy .row {
  padding: 36px 0;
}

.rows.roomy .row .when {
  font-size: 50px;
}

.rows.roomy .row .what .t {
  font-size: 54px;
}

.rows.roomy .row .what .n {
  font-size: 34px;
}

/* A full day has to fit, so the rows tighten up. */
.rows.tight .row {
  padding: 7px 0;
}

.rows.tight .row .when,
.rows.tight .row .what .t {
  font-size: 38px;
}

.rows.tight .row .what .n {
  font-size: 27px;
  margin-top: 2px;
}

/* Bounties ---------------------------------------------------------------- */

.bounty {
  display: flex;
  align-items: center;
  gap: 36px;
  flex: 1 1 0;
  min-height: 0;
  border-top: 2px solid var(--line);
  padding: 14px 0;
}

.bounty:first-child {
  border-top: 0;
}

.bounty .num {
  flex: none;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  background: var(--cyan-soft);
  color: var(--ink);
  font-size: 32px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bounty .name {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 40px;
  font-weight: 700;
  line-height: 1.14;
}

.bounty .prize {
  flex: none;
  max-width: 620px;
  text-align: right;
  font-size: 34px;
  font-weight: 700;
  color: var(--cyan);
  line-height: 1.15;
}

.bounty .prize.tbc {
  color: var(--muted);
  font-weight: 600;
}

/* To be confirmed flag ---------------------------------------------------- */

.tbcbox {
  border: 3px dashed var(--cyan);
  border-radius: 18px;
  background: #fff;
}

.tbcflag {
  display: inline-block;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--cyan-soft);
  border-radius: 999px;
  padding: 6px 16px;
  white-space: nowrap;
}

/* Judges ------------------------------------------------------------------ */

.judges {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 26px 44px;
  flex: 1 1 auto;
  min-height: 0;
}

.judge {
  border-top: 3px solid var(--cyan);
  padding-top: 20px;
  min-height: 0;
  overflow: hidden;
}

.judge .nm {
  font-size: 36px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.judge .rl {
  font-size: 26px;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.22;
  margin-top: 8px;
}

.judge .og {
  font-size: 26px;
  font-weight: 700;
  margin-top: 6px;
}

/* Sponsors ---------------------------------------------------------------- */

.sponsors {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 40px;
  flex: 1 1 auto;
  min-height: 0;
}

.sponsor {
  border: 3px solid var(--line);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 64px;
  min-height: 0;
  overflow: hidden;
}

.sponsor img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

.sponsor .typeset {
  font-size: 62px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-align: center;
}

/* QR slides --------------------------------------------------------------- */

.qrwrap {
  display: flex;
  align-items: stretch;
  gap: 76px;
  flex: 1 1 auto;
  min-height: 0;
}

.qrbox {
  flex: none;
  height: 100%;
  max-height: 100%;
  aspect-ratio: 1 / 1;
  border: 4px solid var(--ink);
  border-radius: 24px;
  padding: 28px;
  background: #fff;
  display: flex;
}

.qrbox img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.qrside {
  flex: 1 1 auto;
  min-width: 0;
  align-self: center;
}

.qrside .link {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.01em;
  word-break: break-word;
  margin-bottom: 34px;
  line-height: 1.2;
}

.qrside ol {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.qrside ol li {
  counter-increment: step;
  position: relative;
  padding-left: 84px;
  font-size: 36px;
  font-weight: 600;
  line-height: 1.25;
  margin-bottom: 26px;
  min-height: 60px;
  display: flex;
  align-items: center;
}

.qrside ol li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--cyan);
  color: var(--ink);
  font-size: 30px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Placeholder ------------------------------------------------------------- */

.placeholder {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
}

.placeholder .tbcbox {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 22px;
  padding: 0 72px;
}

.placeholder .body {
  font-size: 62px;
  font-weight: 700;
  line-height: 1.16;
}

.placeholder .note {
  font-size: 30px;
  font-weight: 600;
  color: var(--muted);
  margin: 0;
}

/* Panels ------------------------------------------------------------------ */

.panels {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 32px;
  flex: 1 1 auto;
  min-height: 0;
}

.panel {
  border: 3px solid var(--line);
  border-radius: 20px;
  padding: 34px 40px;
  min-height: 0;
  overflow: hidden;
}

.panel.tbc {
  border: 3px dashed var(--cyan);
}

.panel h2 {
  font-size: 38px;
  font-weight: 800;
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}

.panel .flag {
  margin-bottom: 14px;
}

.panel ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.panel li {
  font-size: 30px;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.3;
  margin-bottom: 8px;
}

/* Closing ----------------------------------------------------------------- */

.closing {
  height: 100%;
  padding: 0 120px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 90px;
}

.closing .txt {
  min-width: 0;
  max-width: 1180px;
}

.closing h1 {
  font-size: 150px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  margin: 0;
}

.closing .rule {
  width: 360px;
  height: 8px;
  background: var(--cyan);
  margin: 40px 0 36px;
}

.closing .line {
  font-size: 46px;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.3;
  margin: 0 0 16px;
}

.closing .line.strong {
  color: var(--ink);
  font-weight: 700;
}

.closing .emark {
  flex: none;
  height: 430px;
  width: auto;
}

/* Footnote ---------------------------------------------------------------- */

.footnote {
  flex: none;
  margin-top: 26px;
  font-size: 26px;
  font-weight: 600;
  color: var(--muted);
}

/* Review helpers (only used when ?stay=1 or a single slide is being checked) */

#paused {
  position: absolute;
  top: 46px;
  right: 72px;
  z-index: 6;
  background: var(--ink);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: 999px;
  display: none;
}

#stage.paused #paused {
  display: block;
}

@media (prefers-reduced-motion: reduce) {
  .slide {
    transition-duration: 120ms;
  }
}
