/* CODEX RENDER CONTRACT: peak video watch-page styles are owned by config/render-contracts.json. */
:root {
  color-scheme: dark;
  --watch-bg: #0a0a0a;
  --watch-panel: #12151d;
  --watch-ink: #f7fafc;
  --watch-muted: #a8b6c6;
  --watch-stroke: rgba(255, 255, 255, 0.16);
  --watch-accent: var(--nh48-accent, #22c55e);
  --watch-accent-soft: var(--nh48-accent, #22c55e);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
  background: var(--watch-bg);
  color: var(--watch-ink);
}

body {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--watch-accent-soft);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: #bbf7d0;
}

a:focus-visible,
video:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--watch-accent-soft);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  padding: 0.6rem 0.85rem;
  border-radius: 0.45rem;
  background: var(--watch-accent);
  color: #041108;
  font-weight: 800;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

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

.watch-page {
  width: min(900px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 0.8rem 0 2.5rem;
}

.breadcrumbs {
  margin-bottom: 0.7rem;
  color: var(--watch-muted);
  font-size: 0.82rem;
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.breadcrumbs li + li::before {
  margin-right: 0.35rem;
  color: #657386;
  content: "/";
}

.watch-intro {
  margin-bottom: 0.75rem;
}

.eyebrow {
  margin: 0 0 0.25rem;
  color: var(--watch-accent-soft);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

h1,
h2,
p,
dd {
  overflow-wrap: anywhere;
}

h1 {
  max-width: 24ch;
  margin: 0;
  font-size: clamp(1.7rem, 4.7vw, 2.85rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
}

h2 {
  margin: 0 0 0.45rem;
  font-size: 1rem;
  line-height: 1.25;
}

.lede {
  max-width: 72ch;
  margin: 0.55rem 0 0;
  color: #d6e0ec;
  font-size: clamp(0.95rem, 2vw, 1.05rem);
  line-height: 1.48;
}

.metadata-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0.6rem 0 0;
  padding: 0;
  list-style: none;
}

.metadata-chips li {
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--watch-stroke);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  color: #dbe5ef;
  font-size: 0.74rem;
}

.watch-media {
  margin: 0;
}

.player-frame {
  display: grid;
  min-height: min(56vw, 32rem);
  overflow: hidden;
  place-items: center;
  border: 1px solid var(--watch-stroke);
  border-radius: 0.7rem;
  background: #000;
}

.summit-video {
  display: block;
  width: 100%;
  max-height: 72vh;
  background: #000;
  object-fit: contain;
}

.player-frame--portrait .summit-video {
  width: auto;
  max-width: 100%;
  height: min(72vh, 45rem);
}

figcaption {
  padding: 0.55rem 0.1rem 0;
  color: var(--watch-muted);
  font-size: 0.84rem;
  line-height: 1.45;
}

figcaption strong {
  color: #dbe5ef;
}

.peak-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 0.65rem;
  font-size: 0.84rem;
  font-weight: 700;
}

.watch-details {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(16rem, 0.8fr);
  gap: 1.5rem;
  margin-top: 1.15rem;
  padding-top: 1rem;
  border-top: 1px solid var(--watch-stroke);
}

.field-note p {
  margin: 0;
  color: #d6e0ec;
  line-height: 1.55;
}

.video-facts dl,
.technical-details dl {
  margin: 0;
}

.metadata-row {
  display: grid;
  grid-template-columns: minmax(5.5rem, 0.72fr) minmax(0, 1.28fr);
  gap: 0.7rem;
  padding: 0.38rem 0;
  border-top: 1px solid var(--watch-stroke);
  font-size: 0.82rem;
}

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

.metadata-row dt {
  color: var(--watch-muted);
}

.metadata-row dd {
  margin: 0;
  text-align: right;
}

.rights-line {
  margin: 0.55rem 0 0;
  color: var(--watch-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

.technical-details {
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--watch-stroke);
}

.technical-details summary {
  cursor: pointer;
  color: var(--watch-ink);
  font-size: 0.9rem;
  font-weight: 750;
}

.technical-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(16rem, 1.1fr);
  gap: 1.5rem;
  padding-top: 0.9rem;
}

.technical-grid p {
  margin: 0;
  color: #d6e0ec;
  line-height: 1.5;
}

.hash-value {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.7rem;
  word-break: break-all;
}

.siblings {
  margin-top: 1.6rem;
  padding-top: 1rem;
  border-top: 1px solid var(--watch-stroke);
}

.sibling-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(12rem, 18rem));
  gap: 0.7rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.sibling-card {
  display: grid;
  gap: 0.4rem;
  color: var(--watch-ink);
  font-size: 0.84rem;
  font-weight: 700;
  text-decoration: none;
}

.sibling-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--watch-stroke);
  border-radius: 0.5rem;
  background: var(--watch-panel);
  object-fit: cover;
}

.sibling-card:hover span {
  color: var(--watch-accent-soft);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

@media (max-width: 680px) {
  .watch-page {
    width: min(100% - 1.1rem, 900px);
  }

  .watch-details,
  .technical-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .player-frame--portrait .summit-video {
    height: min(70vh, 45rem);
    max-height: 70vh;
  }
}

@media print {
  #nav-placeholder,
  .skip-link,
  video {
    display: none;
  }

  body {
    background: #fff;
    color: #111;
  }
}
