/* Mobile adaptations of the Preview VHS styles in preview-vhs/export-vhs/src/styles/vhs.css. */
@media (max-width: 670px) {
  .v-vhs {
    position: relative;
    width: 100%;
    min-height: 100%;
    background: #15101f;
    color: #fdf2e6;
    font-family: var(--mono);
    overflow: hidden;
    padding: 10px 0 14px;
  }
  .v-vhs .vhs-vignette {
    position: absolute; inset: 0; pointer-events: none; z-index: 4;
    background:
      radial-gradient(ellipse 70% 50% at center, transparent 40%, rgba(0,0,0,0.7) 100%),
      linear-gradient(transparent 0%, rgba(255,80,80,0.04) 50%, transparent 100%);
  }
  .v-vhs .vhs-noise {
    position: absolute; inset: 0; pointer-events: none; z-index: 3;
    background:
      repeating-linear-gradient(transparent 0 1px, rgba(255,255,255,0.04) 1px 2px),
      repeating-linear-gradient(90deg, transparent 0 6px, rgba(255,80,80,0.02) 6px 7px);
    mix-blend-mode: screen;
  }
  .v-vhs .vhs-track {
    position: absolute; left: 0; right: 0;
    height: 28px;
    background: linear-gradient(transparent, rgba(255,255,255,0.12) 50%, transparent);
    filter: blur(1px);
    pointer-events: none;
    z-index: 5;
    mix-blend-mode: screen;
  }
  .v-vhs .vhs-track-2 { height: 12px; opacity: 0.6; }

  /* ---------- HUD ---------- */
  .vhs-hud {
    position: relative; z-index: 6;
    display: flex; justify-content: space-between; align-items: center;
    padding: 4px 14px;
    font-family: var(--crt);
    font-size: 14px;
    color: #fff;
    letter-spacing: 0.06em;
    border-bottom: 1px solid rgba(255,255,255,0.12);
  }
  .hud-l { display: inline-flex; align-items: center; gap: 6px; color: #c5afbb; }
  .hud-c { color: #a2aec0; font-size: 12px; letter-spacing: 0.13em; }
  .hud-r { color: #bdc8d9; font-variant-numeric: tabular-nums; }
  .rec-dot {
    width: 6px; height: 6px; border-radius: 50%; background: #bc8f9c;
  }

  .vhs-inner { position: relative; z-index: 2; padding: 12px 18px 0; }

  /* ---------- Hero stack ---------- */
  .vhs-stack {
    display: flex; flex-direction: column; align-items: center;
    text-align: center;
    margin: 8px 0 18px;
  }
  .vhs-name {
    font-family: var(--display);
    font-size: 39px;
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 0.92;
  }
  .vhs-name-text {
    position: relative;
    display: inline-block;
    color: #fff;
    text-shadow: -1px 0 color-mix(in srgb, var(--accent-secondary) 48%, transparent),
      1px 0 color-mix(in srgb, var(--accent) 54%, transparent);
  }
  .vhs-name-text::after {
    content: attr(data-text);
    position: absolute; inset: 0;
    color: transparent;
    background: repeating-linear-gradient(transparent 0 3px, rgba(0,0,0,0.25) 3px 4px);
    -webkit-background-clip: text; background-clip: text;
    pointer-events: none;
  }
  .vhs-sub {
    margin-top: 3px;
    font-family: var(--crt);
    font-size: 16px;
    letter-spacing: 0.12em;
    color: #bdc8d9;
  }

  .vhs-foot {
    display: flex; justify-content: center; align-items: center; gap: 10px;
    margin-top: 2px;
    padding-bottom: 2px;
    font-family: var(--crt);
    font-size: 13px;
    color: rgba(255,255,255,0.6);
    letter-spacing: 0.1em;
  }
  .vhs-cassette {
    display: inline-flex; gap: 4px; align-items: center;
    padding: 2px 5px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(0,0,0,0.4);
  }
  .vhs-cassette .reel {
    width: 10px; height: 10px; border-radius: 50%;
    border: 1.5px solid rgba(255,213,168,0.7);
    position: relative;
    animation: spin 4s linear infinite;
  }
  .vhs-cassette .reel::before {
    content: '';
    position: absolute; inset: 2px;
    border-radius: 50%;
    background: #ffd5a8;
    opacity: 0.5;
  }

  @keyframes spin { to { transform: rotate(360deg); } }
  @keyframes vhs-phone-tracking {
    0% { top: 12%; }
    100% { top: 89%; }
  }

  #projectify-pitch-designs .concept.v-vhs {
    --page: #04050a;
    --vhs-line: #9db4d236;
    --vhs-tint: #b8cde710;
    --crt: 'VT323', 'Space Mono', monospace;
    background: var(--page);
    color: #fdf2e6;
    font-family: var(--mono);
  }
  #projectify-pitch-designs .vhs-phone-hero {
    position: relative; isolation: isolate; overflow: clip; border-bottom: 1px solid var(--vhs-line);
    background: radial-gradient(ellipse at 50% 14%, #111c2d, #070a11 65%, #04050a);
  }
  #projectify-pitch-designs .vhs-phone-hero .vhs-hud { background: #05070c; }
  #projectify-pitch-designs .vhs-phone-hero .vhs-vignette { opacity: .3; }
  #projectify-pitch-designs .vhs-phone-hero .vhs-noise { opacity: .5; }
  #projectify-pitch-designs .vhs-phone-hero .vhs-track { top: 13%; }
  #projectify-pitch-designs .vhs-phone-hero .vhs-track-2 { top: 51%; }
  #projectify-pitch-designs [data-motion="on"] .vhs-phone-hero .vhs-track {
    opacity: .42; animation: vhs-phone-tracking 8s ease-in-out infinite alternate;
  }
  #projectify-pitch-designs [data-motion="on"] .vhs-phone-hero .vhs-track-2 { animation-delay: -2.6s; }
  #projectify-pitch-designs .vhs-phone-hero::after {
    content: ''; position: absolute; inset: 43% -2% auto; z-index: 5; height: 10px; opacity: 0; pointer-events: none;
    background: repeating-linear-gradient(178deg, transparent 0 2px, #a8ccef55 2px 3px, transparent 3px 5px);
    mask-image: linear-gradient(90deg, transparent, #000 25%, #000 72%, transparent);
  }
  #projectify-pitch-designs [data-motion="on"] .vhs-phone-hero::after {
    animation: projectify-head-switch 6.4s steps(1,end) .65s infinite;
  }
  #projectify-pitch-designs [data-motion="off"] .reel { animation: none; }
  #projectify-pitch-designs [data-motion="off"] .vhs-phone-hero .vhs-track { display: none; }
  #projectify-pitch-designs [data-vhs-idle] .vhs-phone-hero *,
  #projectify-pitch-designs [data-vhs-idle] .vhs-phone-hero *::before,
  #projectify-pitch-designs [data-vhs-idle] .vhs-phone-hero *::after,
  #projectify-pitch-designs [data-vhs-idle] .vhs-phone-hero::after { animation-play-state: paused; }
  #projectify-pitch-designs .vhs-phone-hero .wordmark-row { gap: clamp(8px, 2.5vw, 16px); }
  #projectify-pitch-designs .vhs-phone-hero .hero-photo {
    --frame-edge: clamp(3px, .9vw, 5px);
    width: clamp(43px, 14vw, 80px);
  }
  #projectify-pitch-designs .vhs-phone-hero .vhs-name { font-size: clamp(1.35rem, 8.3vw, 2.55rem); }
  #projectify-pitch-designs .vhs-phone-hero .vhs-name-text::after { text-shadow: none; }
  #projectify-pitch-designs .vhs-phone-hero .wordmark-echo::before { --offset: -.057em; }
  #projectify-pitch-designs .vhs-phone-hero .wordmark-echo::after { --offset: .068em; }
  #projectify-pitch-designs .vhs-phone-hero .vhs-sub {
    margin-top: 6px; font: .86rem/1.3 var(--body); letter-spacing: .02em;
  }
  #projectify-pitch-designs .vhs-phone-hero .vhs-stack { margin-bottom: 15px; }
  #projectify-pitch-designs .vhs-phone-hero .vhs-reach {
    display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); width: min(100%, 315px);
    margin: 13px 0 0; color: #b3bfd0; text-align: left;
  }
  #projectify-pitch-designs .vhs-reach > div { padding-inline: 9px; }
  #projectify-pitch-designs .vhs-reach > div + div { border-left: 1px solid var(--vhs-line); }
  #projectify-pitch-designs .vhs-reach dt { font: .66rem/1.2 var(--mono); white-space: nowrap; }
  #projectify-pitch-designs .vhs-phone-hero .vhs-reach dd { margin-top: 4px; font: .78rem/1 var(--body); }
  #projectify-pitch-designs .vhs-reach strong { color: var(--accent); font: 700 1.36rem/1.1 var(--display); }
  #projectify-pitch-designs .v-vhs .vhs-booking {
    min-height: 44px; margin-top: 14px; padding: 6px 17px; color: #e5edf9; border: 1px solid var(--accent-secondary);
    border-radius: 999px; background: #101825; font: 700 .88rem/1.2 var(--body);
  }
  #projectify-pitch-designs .v-vhs .vhs-booking:hover { background: var(--vhs-tint); }

  #projectify-pitch-designs .v-vhs .library { position: relative; padding-block: 14px 15px; }
  #projectify-pitch-designs .v-vhs .library > h2 {
    margin: 0 0 8px; font: 700 1.47rem/1.1 var(--display);
  }
  #projectify-pitch-designs .v-vhs .workspace { gap: 11px; }
  #projectify-pitch-designs .v-vhs :is(.player-screen,.player) { border-radius: 5px; }
  #projectify-pitch-designs .v-vhs .player .set-art { filter: brightness(.83); }
  #projectify-pitch-designs .v-vhs :is(.tape-id,[data-play-label]) { display: none; }
  #projectify-pitch-designs .v-vhs .duration { font: .94rem/1.1 var(--crt); }
  #projectify-pitch-designs .v-vhs .set-details h3 { font-size: 1.3rem; }
  #projectify-pitch-designs .v-vhs .set-details p { margin-top: 3px; font-size: .72rem; }
  #projectify-pitch-designs .v-vhs .watch-youtube { font: .98rem/1.25 var(--crt); }
  #projectify-pitch-designs .v-vhs .set-list { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; }
  #projectify-pitch-designs .v-vhs .catalogue .area-title { display: none; }
  #projectify-pitch-designs .v-vhs .set-button {
    grid-template-columns: minmax(41px,.7fr) minmax(0,1fr); gap: 7px; min-height: 48px; border: 1px solid #a9bbd225; border-radius: 4px;
  }
  #projectify-pitch-designs .v-vhs .set-button[aria-pressed="true"] { border-color: var(--selected); background: var(--vhs-tint); }
  #projectify-pitch-designs .v-vhs .set-thumb { border-radius: 1px; }
  #projectify-pitch-designs .v-vhs .set-copy strong { font: 700 .86rem/1.12 var(--display); }
  #projectify-pitch-designs .v-vhs .set-copy small { font: .95rem/1 var(--crt); letter-spacing: .08em; }
  #projectify-pitch-designs .v-vhs .set-upcoming {
    display: grid; align-content: center; gap: 3px; min-height: 48px;
  }
  #projectify-pitch-designs .v-vhs :is(.track-panel, .labels) .area-title {
    font: 1rem/1.15 var(--crt); letter-spacing: .11em; text-transform: uppercase;
  }
  #projectify-pitch-designs .v-vhs .track-button { font-family: var(--mono); }
  #projectify-pitch-designs .v-vhs .track-name { font-size: .8rem; }
  #projectify-pitch-designs .v-vhs .proof-band { background: #080b13; }
  #projectify-pitch-designs .v-vhs .proof { gap: 0 10px; }
  #projectify-pitch-designs .v-vhs .proof-item:is([data-summary-stat], :has(.social-links)) { display: none; }
  #projectify-pitch-designs .v-vhs .proof-item.artist-credit { grid-row: auto; border-top: 0; }
  #projectify-pitch-designs .v-vhs .proof-item :is(dt,dd) { font-family: var(--mono); }
  #projectify-pitch-designs .v-vhs .proof-item dd { font-size: .79rem; }
  #projectify-pitch-designs .v-vhs .label-credit { font-size: .72rem; }
  #projectify-pitch-designs .v-vhs > .footer { display: none; }
  #projectify-pitch-designs .v-vhs .vhs-foot { padding-inline: var(--pad); justify-content: space-between; }
  #projectify-pitch-designs .v-vhs .vhs-foot .motion-control { font: 1rem/1 var(--crt); }

  @media (prefers-reduced-motion: reduce) {
    #projectify-pitch-designs .vhs-phone-hero .vhs-track { display: none; }
    #projectify-pitch-designs .vhs-phone-hero::after,
    #projectify-pitch-designs .vhs-phone-hero .wordmark-echo::before,
    #projectify-pitch-designs .vhs-phone-hero .wordmark-echo::after { animation: none; }
    #projectify-pitch-designs .reel { animation: none; }
  }
}
