/* MEDIA page (media/index.html + 15 locale copies). Replaces css/videos.css on this page (10/26). */
.media-selector[hidden], .section[hidden], .video-modal[hidden], .audio-player[hidden],
.vp-error[hidden], #modal-views-wrap[hidden], #vc-words[hidden] { display: none !important; }

.page-title { color: #b22222; text-transform: uppercase; letter-spacing: 8px; font-size: 48px; text-shadow: 0 0 20px rgba(178, 34, 34, .5); }
.page-subtitle { font-family: "Courier New", monospace; letter-spacing: 4px; margin-top: 10px; }
.section-title { color: #b22222; text-align: center; text-transform: uppercase; letter-spacing: 4px; text-shadow: 0 0 20px rgba(178, 34, 34, .5); }

/* once a section is open: no "choose your format", less empty space above it */
body.media-open .page-subtitle { display: none !important; }
body.media-open .page-header { padding-bottom: .5rem; }
body.media-open .page-header .page-title { margin-bottom: 0; }
body.media-open .section { padding-top: 1rem; }

/* ---------- picker ---------- */
.media-selector { padding: var(--spacing-2xl) 0; min-height: 60vh; display: flex; align-items: center; }
.media-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; width: 100%; max-width: 1000px; margin: 0 auto; place-items: center; }
.media-icon {
  height: 200px; width: auto; max-width: 100%; cursor: pointer; filter: brightness(.8);
  transition: transform .3s ease, filter .3s ease; -webkit-tap-highlight-color: transparent;
}
.media-icon:hover, .media-icon:focus-visible { transform: scale(1.1); filter: brightness(1.2) drop-shadow(0 0 15px rgba(255, 255, 255, .3)); }
.media-icon:focus-visible { outline: 2px solid #ECE7DF; outline-offset: 6px; }

/* ---------- section heading row ---------- */
.section-head { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; margin-bottom: 1.5rem; }
.section-head .section-title { margin: 0; grid-column: 2; }
.section-head .back-button { grid-column: 1; grid-row: 1; justify-self: start; margin: 0; }
.back-button {
  display: inline-block; padding: var(--spacing-sm) var(--spacing-lg); background: var(--color-bg-secondary);
  border: 2px solid var(--color-border); color: var(--color-text-primary); font-family: var(--font-mono);
  text-transform: uppercase; letter-spacing: .1em; cursor: pointer; transition: all var(--transition-fast); white-space: nowrap;
}
.back-button:hover { background: var(--color-blood-primary); border-color: var(--color-blood-accent); }

/* ---------- video archive ---------- */
.videos-section { min-height: 60vh; padding: var(--spacing-2xl) 0; background: linear-gradient(180deg, transparent 0, rgba(178, 34, 34, .05) 55%, transparent 100%), var(--color-bg-primary); }
.videos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: var(--spacing-xl); }
.video-card {
  background-color: var(--color-bg-secondary); border: 2px solid var(--color-border); border-radius: var(--radius-lg);
  overflow: hidden; transition: transform var(--transition-normal), border-color var(--transition-normal), box-shadow var(--transition-normal);
  cursor: pointer; position: relative; -webkit-tap-highlight-color: transparent;
}
.video-card:hover, .video-card:focus-visible { transform: translateY(-6px); border-color: var(--color-blood-accent); box-shadow: 0 20px 40px rgba(178, 34, 34, .4); }
.video-card:focus-visible { outline: 2px solid var(--color-blood-accent); outline-offset: 3px; }
.video-thumbnail { position: relative; aspect-ratio: 16/9; overflow: hidden; background: #000; }
.video-thumbnail img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform var(--transition-slow); }
.video-card:hover .video-thumbnail img { transform: scale(1.06); }
.video-overlay {
  position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 0, rgba(0, 0, 0, .75) 100%);
  opacity: 0; transition: opacity var(--transition-normal); display: flex; align-items: center; justify-content: center;
}
.video-card:hover .video-overlay, .video-card:focus-visible .video-overlay { opacity: 1; }
.play-button {
  width: 60px; height: 60px; background-color: rgba(178, 34, 34, .9); border: 2px solid var(--color-blood-accent);
  border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: transform var(--transition-fast);
}
.play-button::after { content: ""; border-left: 20px solid var(--color-text-primary); border-top: 12px solid transparent; border-bottom: 12px solid transparent; margin-left: 5px; }
.video-card:hover .play-button { transform: scale(1.1); background-color: var(--color-blood-accent); }
.video-duration {
  position: absolute; bottom: var(--spacing-md); left: var(--spacing-md); padding: var(--spacing-xs) var(--spacing-sm);
  background-color: rgba(0, 0, 0, .8); color: var(--color-text-primary); font-family: var(--font-mono); font-size: .8rem; border-radius: var(--radius-sm);
}
.video-info { padding: var(--spacing-md) var(--spacing-lg) var(--spacing-lg); }
.video-title { font-family: var(--font-heading); font-size: 1.25rem; color: var(--color-text-primary); margin-bottom: var(--spacing-sm); text-transform: uppercase; letter-spacing: .05em; }
.video-meta { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: var(--spacing-sm); }
.video-artist { font-family: var(--font-mono); font-size: .875rem; color: var(--color-text-secondary); }
.video-date { font-family: var(--font-mono); font-size: .8rem; color: var(--color-text-dim); }

/* ---------- video window ---------- */
body.vm-open { overflow: hidden; }
body.vm-open #ns-lang { display: none !important; }
.video-modal {
  position: fixed; inset: 0; z-index: 1000; background: rgba(0, 0, 0, .95);
  overflow-y: auto; overscroll-behavior: contain; padding: 14px 12px 32px;
}
/* sized so the video, its title and the top of the case file fit on the screen */
.video-modal-content {
  position: relative; margin: 0 auto; background: #0a0a0a; border: 2px solid #b22222; padding: 0 16px 16px;
  width: min(1100px, 100%, calc((100vh - 280px) * 16 / 9 + 36px)); min-width: min(100%, 520px);
}
@supports (height: 100dvh) {
  .video-modal-content { width: min(1100px, 100%, calc((100dvh - 280px) * 16 / 9 + 36px)); }
}
.vm-bar { display: flex; justify-content: flex-end; align-items: center; height: 46px; }
.close-modal {
  width: 36px; height: 36px; padding: 0 !important; min-height: 0 !important; border-radius: 50%;
  border: 2px solid #b22222; background: #000; color: #b22222; display: grid; place-items: center; cursor: pointer;
}
.close-modal svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; }
.close-modal:hover, .close-modal:focus-visible { color: #ff2b2b; border-color: #ff2b2b; box-shadow: 0 0 14px rgba(255, 0, 0, .45); }

.video-container { --ctl: 52px; position: relative; background: #000; direction: ltr; user-select: none; -webkit-user-select: none; }
#modal-video { display: block; width: 100%; aspect-ratio: 16/9; height: auto; background: #000; object-fit: contain; cursor: pointer; }
.vp-osd, .vp-big, .vp-error { position: absolute; left: 0; right: 0; top: 0; bottom: var(--ctl); }
.vp-osd { pointer-events: none; padding: 14px 18px; font-family: "VT323", "Courier New", monospace; font-size: 1.35rem; letter-spacing: .08em; color: #e8e8e8; text-shadow: 2px 2px 0 #000; }
.vp-osd span { display: none; }
.video-container:not(.paused) .osd-play { display: inline; animation: vp-osd 2.2s forwards; }
.video-container.started.paused .osd-pause { display: inline; }
.video-container.buffering .vp-osd::after { content: "TRACKING..."; display: block; margin-top: 6px; animation: vp-blink 1s steps(2) infinite; }
@keyframes vp-osd { 0%, 70% { opacity: 1; } 100% { opacity: 0; } }
@keyframes vp-blink { 50% { opacity: 0; } }
.vp-big {
  margin: auto; width: 76px; height: 76px; padding: 0 !important; min-height: 0 !important; border-radius: 50%;
  background: rgba(178, 34, 34, .88); border: 2px solid #ff2b2b; color: #fff; display: none; place-items: center; cursor: pointer;
}
.vp-big svg { width: 34px; height: 34px; fill: currentColor; margin-left: 4px; }
.video-container.paused .vp-big { display: grid; }
.vp-big:hover { background: #d42020; box-shadow: 0 0 22px rgba(255, 0, 0, .55); }
.vp-error {
  display: flex; align-items: center; justify-content: center; text-align: center; padding: 20px; background: #050505;
  color: #b22222; font-family: "VT323", "Courier New", monospace; font-size: 1.6rem; letter-spacing: .12em;
}
.vp-error:not([hidden]) ~ .vp-controls { opacity: .4; pointer-events: none; }
.video-container:has(.vp-error:not([hidden])) .vp-big { display: none; }
.vp-controls {
  height: var(--ctl); display: flex; align-items: center; gap: 8px; padding: 0 8px;
  background: linear-gradient(180deg, #161212, #0b0909); border-top: 1px solid #3a1414;
}
.vp-btn {
  flex: none; width: 40px; height: 40px; padding: 0 !important; min-height: 0 !important; border: 0; background: none;
  color: #d8d8d8; display: grid; place-items: center; cursor: pointer; border-radius: 4px;
}
.vp-btn:hover, .vp-btn:focus-visible { color: #fff; background: rgba(178, 34, 34, .35); box-shadow: none; }
.vp-btn svg { width: 22px; height: 22px; fill: currentColor; }
.vp-btn svg .w, #vp-fs svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
#vp-fs svg path { fill: none; }
.i-pause, .i-muted { display: none !important; }
.video-container:not(.paused) .i-play { display: none !important; }
.video-container:not(.paused) .i-pause { display: block !important; }
.video-container.muted .i-vol { display: none !important; }
.video-container.muted .i-muted { display: block !important; }
.vp-progress { flex: 1; min-width: 60px; height: 40px; position: relative; display: flex; align-items: center; cursor: pointer; touch-action: none; }
.vp-track { position: relative; width: 100%; height: 6px; background: #2c2c2c; border: 1px solid #444; border-radius: 3px; overflow: hidden; }
.vp-buf { position: absolute; left: 0; top: 0; bottom: 0; width: var(--vp-buf, 0%); background: #4a4a4a; }
.vp-fill { position: absolute; left: 0; top: 0; bottom: 0; width: var(--vp-pos, 0%); background: linear-gradient(90deg, #8b1a1a, #ff3333); }
.vp-knob { position: absolute; left: var(--vp-pos, 0%); top: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; background: #ff3333; box-shadow: 0 0 8px rgba(255, 0, 0, .6); pointer-events: none; }
.vp-progress:focus-visible { outline: 2px solid var(--color-blood-accent); outline-offset: 2px; }
.vp-time { flex: none; font-family: "Courier New", monospace; font-size: 12px; color: #aaa; white-space: nowrap; }
.vp-vol { flex: none; width: 76px; accent-color: #b22222; cursor: pointer; }
.video-container:fullscreen, .video-container:-webkit-full-screen { display: flex; flex-direction: column; justify-content: center; width: 100%; height: 100%; }
.video-container:fullscreen #modal-video { flex: 1 1 0; min-height: 0; aspect-ratio: auto; height: auto !important; }
.video-container:-webkit-full-screen #modal-video { flex: 1 1 0; min-height: 0; aspect-ratio: auto; height: auto !important; }

.video-info-panel { margin-top: 12px; padding: 14px 18px 18px; background-color: #161616; border: 1px solid #333; }
.video-info-panel h3 { color: #b22222; margin-bottom: 6px; font-family: "VT323", monospace; font-size: 24px; }
.video-meta-info { color: #b8b8b8; font-size: 14px; margin-bottom: 14px; font-family: "IBM Plex Mono", monospace; }
.backstory-container {
  color: #ededed; font-family: "Courier New", monospace; font-size: 13px; line-height: 1.6; white-space: pre-wrap;
  background-color: #0a0a0a; padding: 18px; border: 1px solid #333;
}
.backstory-container .bs-gap { height: 1.6em; }   /* blank line between blocks of a case file */

/* ---------- audio tapes ---------- */
.audio-section { min-height: 60vh; padding: var(--spacing-2xl) 0; }
.cassette-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: var(--spacing-xl) var(--spacing-lg); margin-bottom: var(--spacing-xl); justify-items: center; }
.cassette-item {
  position: relative; width: 100%; max-width: 320px; cursor: pointer; container-type: inline-size;
  transition: transform var(--transition-fast), filter var(--transition-fast); -webkit-tap-highlight-color: transparent;
}
.cassette-item:hover, .cassette-item:focus-visible { transform: translateY(-5px) scale(1.04); filter: brightness(1.1); }
.cassette-item:focus-visible { outline: 2px solid var(--color-blood-accent); outline-offset: 4px; }
.cassette-item.loaded { filter: drop-shadow(0 0 8px rgba(178, 34, 34, .5)); }
.cassette-item.playing { transform: translateY(-6px) scale(1.04); filter: drop-shadow(0 0 16px rgba(255, 0, 0, .65)) brightness(1.1); animation: tape-glow 1.6s ease-in-out infinite; }
@keyframes tape-glow { 50% { filter: drop-shadow(0 0 7px rgba(255, 0, 0, .35)) brightness(1.03); } }
.cassette-icon { width: 100%; height: auto; display: block; }
.cassette-title {
  position: absolute; top: 20%; left: 50%; transform: translateX(-50%); width: 50%; text-align: center;
  font-family: "Courier New", monospace; font-size: max(9px, 2.9cqw); color: #000; text-transform: uppercase; letter-spacing: .2px; line-height: 1.1; pointer-events: none;
}
.cassette-item.playing .cassette-title::before { content: "▶ "; color: #b22222; }
/* sits under the tapes and sticks to the bottom of the screen while you scroll; never fixed over them */
.audio-player {
  position: sticky; bottom: 16px; z-index: 20; margin: 0 auto; max-width: 520px; text-align: center;
  background: var(--color-bg-secondary); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 12px 14px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .7);
}
.player-title { font-family: var(--font-mono); font-size: 1rem; color: var(--color-text-primary); margin-bottom: 10px; text-transform: uppercase; }
#audio-element { display: none; }
.custom-audio-player {
  display: flex; align-items: center; gap: 14px; direction: ltr; background: linear-gradient(180deg, #1a1a1a 0, #0d0d0d 100%);
  border: 1px solid #b22222; border-radius: 8px; padding: 10px 16px; box-shadow: 0 0 15px rgba(178, 34, 34, .3), inset 0 0 20px rgba(0, 0, 0, .5);
}
.play-pause-btn {
  width: 44px; height: 44px; padding: 0 !important; min-height: 0 !important; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(135deg, #b22222, #b22222); border: 2px solid #f33; color: #fff; cursor: pointer;
  display: grid; place-items: center; box-shadow: 0 0 10px rgba(255, 0, 0, .4); transition: all .2s ease;
}
.play-pause-btn:hover { background: linear-gradient(135deg, #b22222, #f00); box-shadow: 0 0 20px rgba(255, 0, 0, .6); transform: scale(1.05); }
.play-pause-btn svg { width: 20px; height: 20px; fill: currentColor; }
.play-pause-btn .i-play { margin-left: 2px; }
.audio-player:not(.paused) .play-pause-btn .i-play { display: none !important; }
.audio-player:not(.paused) .play-pause-btn .i-pause { display: block !important; }
.progress-container { flex: 1; height: 8px; background: #333; border-radius: 4px; cursor: pointer; position: relative; overflow: hidden; border: 1px solid #555; touch-action: none; }
.progress-container::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; bottom: -14px; }
.progress-bar { height: 100%; width: 0%; background: linear-gradient(90deg, #b22222, #b22222, #f33); border-radius: 4px; box-shadow: 0 0 8px rgba(255, 0, 0, .5); }
.time-display { font-family: "Courier New", monospace; font-size: 12px; color: #aaa; min-width: 84px; text-align: center; white-space: nowrap; }
.volume-container { display: flex; align-items: center; }
.volume-slider { width: 80px; accent-color: #b22222; cursor: pointer; }

/* ---------- polaroids ---------- */
.polaroid-section {
  min-height: 80vh; padding: var(--spacing-2xl) 0;
  background: linear-gradient(180deg, transparent 0, rgba(178, 34, 34, .05) 30%, transparent 75%), var(--color-bg-primary);
}
.polaroid-hint {
  text-align: center; margin: -.5rem auto .75rem; max-width: none; font-family: var(--font-mono); font-size: .95rem;
  letter-spacing: .15em; text-transform: uppercase; color: var(--color-blood-accent); opacity: .75;
}
.polaroid-gallery { position: relative; height: 560px; margin: 0 auto; user-select: none; -webkit-user-select: none; opacity: 0; transition: opacity .25s ease; }
.polaroid-gallery.ready { opacity: 1; }
.polaroid {
  position: absolute; left: 0; top: 0; width: 240px; height: 300px; background: #f4f1ea; border-radius: 2px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .08), var(--lsh, 0 0 0 transparent);
  cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
  transform-origin: 50% 50%; will-change: transform; transition: box-shadow .2s ease;
}
.polaroid:hover { box-shadow: 0 10px 26px rgba(0, 0, 0, .7), 0 0 0 1px rgba(255, 255, 255, .2), var(--lsh, 0 0 0 transparent); }
.polaroid.held { cursor: grabbing; box-shadow: 0 24px 44px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .22), var(--lsh, 0 0 0 transparent); }
.polaroid-image {
  position: relative; width: 220px; height: 220px; margin: 10px auto 0; overflow: hidden; border-radius: 1px;
  background: radial-gradient(circle at 42% 38%, #3b3a2f 0, #26261f 55%, #181913 100%);
}
.polaroid-image img {
  display: block; width: 100%; height: 100%; object-fit: cover; opacity: 0; pointer-events: none; -webkit-user-drag: none;
  transition: opacity .35s linear, filter .35s linear;
}
.polaroid-blood { position: absolute; pointer-events: none; background-size: cover; background-position: center; background-repeat: no-repeat; transition: opacity .35s linear; }
.image-blood { inset: 0; }
.border-blood { top: -10px; left: -10px; width: calc(100% + 20px); height: calc(100% + 20px); z-index: 5; }
/* v3 blood + wear (js/ns-gore.js via polaroids.js): canvases laid over the card. Wear and blood multiply into the
   paper and photo under them like a real stain; the shine on wet or crusted blood sits on top in normal blend */
.pol-layer { position: absolute; pointer-events: none; opacity: 0; }
.polaroid.gore-in .pol-layer { opacity: 1; }
.polaroid.gore-late .pol-layer { transition: opacity .4s linear; }
.pol-wear { z-index: 4; mix-blend-mode: multiply; }
.pol-blood-mul { z-index: 5; mix-blend-mode: multiply; }
.pol-gloss { z-index: 6; }
.polaroid-image .pol-fx { z-index: 3; }
/* the card's own shape: bow or curl and the sheen across it (shape() in polaroids.js) */
.pol-shape { position: absolute; inset: 0; z-index: 7; pointer-events: none; border-radius: inherit; }
/* a corner bent up: lifted into the light, a crease where it bends */
.pol-bend { position: absolute; z-index: 8; pointer-events: none; }
.pol-bend-tl { left: 0; top: 0; clip-path: polygon(0 0, 100% 0, 0 100%); background: linear-gradient(135deg, rgba(255,255,255,.16), rgba(255,255,255,.05) 42%, rgba(0,0,0,.2) 48.5%, rgba(255,255,255,.25) 50%); }
.pol-bend-tr { right: 0; top: 0; clip-path: polygon(0 0, 100% 0, 100% 100%); background: linear-gradient(225deg, rgba(255,255,255,.16), rgba(255,255,255,.05) 42%, rgba(0,0,0,.2) 48.5%, rgba(255,255,255,.25) 50%); }
.pol-bend-br { right: 0; bottom: 0; clip-path: polygon(100% 0, 100% 100%, 0 100%); background: linear-gradient(315deg, rgba(0,0,0,.05), rgba(0,0,0,.1) 42%, rgba(0,0,0,.22) 48.5%, rgba(255,255,255,.22) 50%); }
.pol-bend-bl { left: 0; bottom: 0; clip-path: polygon(0 0, 0 100%, 100% 100%); background: linear-gradient(45deg, rgba(0,0,0,.05), rgba(0,0,0,.1) 42%, rgba(0,0,0,.22) 48.5%, rgba(255,255,255,.22) 50%); }
/* corners of the photo darker, like the real film; comes up with the picture */
.polaroid-image::before {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: var(--dev, 0);
  background: radial-gradient(ellipse 75% 75% at 50% 48%, transparent 55%, rgba(18, 10, 4, var(--vig, .4)) 100%);
}
.polaroid.flash .polaroid-image::after { content: ""; position: absolute; inset: 0; z-index: 4; background: #fff; animation: pol-flash .45s ease-out forwards; }
@keyframes pol-flash { from { opacity: .7; } to { opacity: 0; } }

/* ---------- phones / narrow windows ---------- */
@media (max-width: 768px) {
  .media-selector { padding: .75rem 0 2.5rem; min-height: 0; }
  .media-options { grid-template-columns: 1fr; gap: clamp(1rem, 3vh, 1.75rem); }
  .media-icon { height: clamp(76px, 14vh, 150px); }   /* all three fit on a 568 px tall phone */
  .section-head { grid-template-columns: 1fr; gap: .75rem; margin-bottom: 1.25rem; }
  .section-head .section-title { grid-column: 1; grid-row: 2; }
  .section-head .back-button { justify-self: center; }
  .videos-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .video-title { font-size: 1.2rem; }
  .video-modal { padding: 8px 6px 24px; }
  .video-modal-content { min-width: 0; width: 100%; padding: 0 8px 10px; }
  .vm-bar { height: 52px; }
  .close-modal { width: 44px; height: 44px; }
  .video-container { --ctl: 56px; }
  .vp-btn { width: 44px; height: 44px; }
  .vp-controls { gap: 4px; padding: 0 4px; }
  .vp-vol { display: none; }
  .vp-big { width: 68px; height: 68px; }
  .video-info-panel { padding: 12px; }
  .backstory-container { font-size: 12.5px; padding: 12px; }
  .cassette-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1.5rem 1rem; }
  .audio-player { bottom: 58px; padding: 10px; }   /* clear of the language button (bottom-left) */
  .custom-audio-player { gap: 10px; padding: 8px 10px; }
  .volume-container { display: none; }
  .polaroid-hint { font-size: .85rem; letter-spacing: .1em; margin-top: 0; }
  /* a section is open: smaller heading so the table / player fits a short phone screen */
  body.media-open main > .page-header:first-child { padding-top: calc(120px + .75rem) !important; padding-bottom: 0 !important; }
  body.media-open .page-header .page-title { font-size: 2rem !important; letter-spacing: 6px; text-indent: 6px; }
  body.media-open .section { padding-top: .5rem !important; }
  html body.media-open .section-head .back-button { padding: 0 1rem !important; min-height: 40px !important; font-size: .9rem !important; }
  .section-head { gap: .5rem; margin-bottom: .75rem; }
  .section-head .section-title { font-size: 1.35rem; }
}
.mobile-device .vp-vol, .mobile-device .volume-container { display: none; }   /* phones ignore page volume */
.mobile-device .vp-btn { width: 44px; height: 44px; }
.mobile-device .video-container { --ctl: 56px; }
/* the site-wide phone rule ".mobile-device button { padding/min-height !important }" must not squash the player buttons */
.mobile-device .video-modal .vp-btn, .mobile-device .video-modal .close-modal, .mobile-device .video-modal .vp-big,
.mobile-device .audio-player .play-pause-btn { padding: 0 !important; min-height: 0 !important; }
.vp-btn svg, .close-modal svg, .vp-big svg, .play-pause-btn svg { flex: none; max-width: none; }
.vm-nw { white-space: nowrap; }   /* a wrapped meta line starts with its dot, never ends with one */
/* short computer windows (e.g. 1024x600): an open section gets the same compact heading as phones, so the table fits */
@media (min-width: 769px) and (max-height: 700px) {
  body.media-open main > .page-header:first-child { padding-top: calc(110px + .5rem) !important; padding-bottom: 0 !important; }
  body.media-open .page-header .page-title { font-size: 2.4rem !important; }
  body.media-open .section { padding-top: .5rem !important; }
  .section-head { margin-bottom: .75rem; }
}

/* touch screens: a tap leaves :hover stuck on the card / tape until the next tap elsewhere - no lifted card after closing a video */
@media (hover: none) {
  .video-card:hover:not(:focus-visible) { transform: none; border-color: var(--color-border); box-shadow: none; }
  .video-card:hover .video-thumbnail img { transform: none; }
  .video-card:hover:not(:focus-visible) .video-overlay { opacity: 0; }
  .cassette-item:hover:not(:focus-visible) { transform: none; filter: none; }
  .media-icon:hover:not(:focus-visible) { transform: none; filter: brightness(.8); }
}

/* ---- Format picker: the three objects lie on a dark desk under one lamp (28 Oct 2026) ---- */
.media-selector { min-height: 0; padding: clamp(1.5rem, 5vh, 3.5rem) 0 clamp(3rem, 8vh, 5rem);
  background: radial-gradient(ellipse 55% 65% at 50% 46%, rgba(232, 222, 202, .07), rgba(232, 222, 202, .045) 25%, rgba(232, 222, 202, .02) 50%, rgba(232, 222, 202, .006) 72%, rgba(232, 222, 202, 0) 100%); }
.media-options { max-width: 1080px; gap: clamp(24px, 4vw, 64px); align-items: end; }
.media-pick { margin: 0; display: flex; flex-direction: column; align-items: center; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.mp-obj { position: relative; display: inline-block; line-height: 0; transform: rotate(var(--tilt, 0deg)); transition: transform .35s cubic-bezier(.2, .7, .2, 1); }
.mp-vhs, .mp-tape, .mp-cam { --tilt: 0deg; }
/* contact shadow on the desk */
.mp-obj::after { content: ""; position: absolute; left: 8%; right: 8%; bottom: -7%; height: 14%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(0, 0, 0, .85), rgba(0, 0, 0, 0)); filter: blur(6px); z-index: -1; transition: transform .35s, opacity .35s; }
.media-pick .media-icon { height: 210px; filter: contrast(1.04) brightness(.95) drop-shadow(0 10px 12px rgba(0, 0, 0, .55));
  transition: filter .35s ease; outline: none; }
.mp-tape .media-icon { height: 200px; } .mp-cam .media-icon { height: 205px; }
.media-pick .media-icon:hover, .media-pick .media-icon:focus-visible { transform: none; }
.media-pick:hover .mp-obj, .media-pick:focus-within .mp-obj { transform: translateY(-10px) rotate(0deg); }
.media-pick:hover .mp-obj::after, .media-pick:focus-within .mp-obj::after { transform: translateY(10px) scale(.86); opacity: .7; }
.media-pick:hover .media-icon, .media-pick:focus-within .media-icon { filter: contrast(1.04) brightness(1.06) drop-shadow(0 18px 18px rgba(0, 0, 0, .6)); }
.media-pick:focus-within figcaption b { text-decoration: underline; text-underline-offset: 5px; }
/* marker on the tape's own white label */
/* a strip of masking tape with marker on it */
.media-pick figcaption { margin-top: 26px; text-align: center; font-family: 'Courier New', Courier, monospace; line-height: 1.5; }
.media-pick figcaption b { display: block; color: #ECE7DF; font-size: 15px; letter-spacing: .2em; }
.media-pick figcaption span { display: block; color: #8b867e; font-size: 12.5px; letter-spacing: .06em; }
@media (max-width: 768px) {
  .media-options { grid-template-columns: 1fr; gap: clamp(14px, 3vh, 26px); max-width: 420px; }
  .media-pick { display: grid; grid-template-columns: 52% 1fr; align-items: center; column-gap: 18px; width: 100%; }
  .mp-obj { justify-self: center; }
  .media-pick .media-icon, .mp-tape .media-icon, .mp-cam .media-icon { height: clamp(78px, 14vh, 140px); }
  .media-pick figcaption { margin-top: 0; text-align: left; }
  .media-selector { padding-bottom: 76px; }   /* last item clears the language button (bottom-left) */
}
@media (hover: none) { .media-pick:hover .mp-obj { transform: rotate(var(--tilt)); } .media-pick:hover .mp-obj::after { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .mp-obj, .mp-obj::after { transition: none; } }
