body {
  min-height: 100vh;
  background: radial-gradient(ellipse at 68% -32%, #28382f, transparent 56%), var(--ink);
}

#account { justify-self: end; white-space: nowrap; }

.cover {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.16fr);
  min-height: clamp(520px, 49.5vw, 700px);
  margin: 30px 0 23px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: radial-gradient(ellipse at 8% 105%, #252d24, transparent 72%), #171c1c;
}

.lead {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  min-width: 0;
  padding: clamp(25px, 4vw, 68px);
}

.lead .display {
  margin: 29px 0 26px;
  font-size: clamp(69px, 8.2vw, 130px);
}

p { margin: 0; color: var(--muted); }
.lead p { max-width: 30ch; font-size: clamp(16px, 1.32vw, 20px); }
.access-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 28px; }
.access-actions .primary { min-height: 52px; padding-inline: 21px; }

.text-button {
  min-height: 44px;
  border: 0;
  padding: 6px 0;
  background: transparent;
  color: var(--chalk);
  font-size: 14px;
  text-decoration: underline;
  text-decoration-color: var(--sage);
  text-underline-offset: 4px;
  cursor: pointer;
}

.text-button:hover { color: var(--lime); }

.cover .signal-plate { border-left: 1px solid var(--line); }

footer, .sectionhead, .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

footer {
  padding: 7px 1px 24px;
  color: var(--muted);
  font: 11px/1.5 var(--mono);
  letter-spacing: .12em;
  text-transform: uppercase;
}

.studio-panel { padding: clamp(22px, 5vw, 60px) 0; }

h2 {
  margin: 0 0 20px;
  font-size: clamp(36px, 5vw, 78px);
  line-height: 1.05;
  letter-spacing: -.075em;
}

.sectionhead h2 { margin: 5px 0 16px; }
video { width: 100%; max-height: 67vh; aspect-ratio: 16 / 9; background: #070808; border-radius: 18px; }
#playerMsg, #updated { margin: 10px 0; }

.metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }

.metrics article {
  min-width: 0;
  padding: clamp(15px, 3vw, 32px);
  border-radius: 18px;
  background: var(--sage);
  color: var(--ink);
}

.metrics article + article { background: var(--iris); }
.metrics strong { display: block; font-size: clamp(40px, 7vw, 90px); line-height: 1; letter-spacing: -.075em; }
.metrics span { display: block; margin-bottom: 12px; font-size: 14px; }

.row { padding: 16px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.row > div { min-width: 0; overflow-wrap: anywhere; }
h3 { margin: 30px 0 8px; font-size: 25px; letter-spacing: -.045em; }
summary { cursor: pointer; }
details { margin-top: 7px; color: var(--muted); font-size: 14px; }

dialog {
  width: min(440px, 100% - 32px);
  max-height: calc(100dvh - 32px);
  padding: clamp(20px, 5vw, 32px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  color: var(--chalk);
}

dialog::backdrop { background: #060909c9; backdrop-filter: blur(7px); }
dialog h2 { margin: 8px 44px 12px 0; font-size: 38px; }
.dismiss { float: right; width: 44px; padding: 0; font-size: 24px; }
label { display: block; margin: 18px 0; }

input {
  display: block;
  width: 100%;
  margin-top: 7px;
  padding: 12px;
  border: 1px solid #6c7d79;
  border-radius: 10px;
  background: var(--ink);
  color: var(--chalk);
}

#error { color: #ffc6ab; margin: 14px 0; }
#error:empty { margin: 14px 0 0; }

@media (max-width: 860px) {
  .cover { min-height: auto; grid-template-columns: 1fr; margin-top: 20px; }
  .cover .signal-plate { grid-row: 1; min-height: clamp(250px, 60vw, 420px); border-left: 0; border-bottom: 1px solid var(--line); }
  .lead { padding: 27px clamp(21px, 4.5vw, 42px) 31px; }
  .lead .display { margin: 20px 0; font-size: clamp(66px, 10.5vw, 96px); }
  .access-actions { margin-top: 22px; }
}

@media (max-width: 470px) {
  .masthead { grid-template-columns: 1fr auto; padding: 10px 0; }
  .masthead .mode-switch { grid-row: 2; grid-column: 1 / -1; justify-self: start; }
  .masthead #account { grid-row: 1; grid-column: 2; }
  .lead .display { font-size: clamp(52px, 16.4vw, 75px); }
  .access-actions { column-gap: 14px; }
}
