/* Layout: one quiet column. Wordmark top-left, the video is the whole page, one control under it. */
:root {
  --bg: #ecede8;        /* cool table-linen grey, slight green bias */
  --surface: #e2e4dd;
  --ink: #1d211c;
  --muted: #5f655c;
  --line: #cfd2c9;
  --accent: #2f4a36;    /* deep basil */
  --accent-ink: #f2f3ee;

  --font-display: "Gloock", "Iowan Old Style", Georgia, serif;
  --font-body: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141713;
    --surface: #1c201b;
    --ink: #e6e8e1;
    --muted: #949a90;
    --line: #2b302a;
    --accent: #b9cdb4;
    --accent-ink: #141713;
    color-scheme: dark;
  }
}

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

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.page {
  min-height: 100%;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: clamp(20px, 4vh, 40px);
  max-width: 1080px;
  margin: 0 auto;
  padding-block: max(20px, env(safe-area-inset-top, 0px)) max(20px, env(safe-area-inset-bottom, 0px));
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}

/* Header */
.top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.mark {
  font-family: var(--font-display);
  font-size: 26px;
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
}

.mark .amp { color: var(--accent); }

.count {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

/* Video */
.stage {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 20px;
}

.screen {
  position: relative;
  width: 100%;
  max-width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
}

.screen iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.below {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.meta { min-width: 0; }

.title {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: clamp(17px, 2.2vw, 20px);
  line-height: 1.3;
  text-wrap: balance;
}

.channel {
  margin: 4px 0 0;
  font-size: 14px;
  color: var(--muted);
}

/* The one control */
.shuffle {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px 12px 20px;
  font: 500 15px/1 var(--font-body);
  color: var(--accent-ink);
  background: var(--accent);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  transition: transform 120ms ease, opacity 120ms ease;
}

.shuffle:hover { opacity: 0.9; }
.shuffle:active { transform: translateY(1px); }
.shuffle:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

.shuffle kbd {
  font: 500 11px/1 var(--font-mono);
  padding: 4px 6px;
  border-radius: 4px;
  border: 1px solid color-mix(in srgb, var(--accent-ink) 35%, transparent);
  opacity: 0.8;
}

/* Footer */
.foot p {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

@media (max-width: 560px) {
  .below { flex-direction: column; gap: 16px; }
  .shuffle { width: 100%; justify-content: center; }
  .shuffle kbd { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .shuffle { transition: none; }
}
