/* WORLD MEDIA V3.11.1 — Center Player Polish
   Presentation-only layer. Mobile <=620px keeps the full-screen player. */

@media (min-width: 621px) {
  .now-sheet {
    display: block;
    padding: 24px;
  }

  .now-sheet-backdrop {
    background: rgba(2, 3, 6, .72);
    backdrop-filter: blur(7px) saturate(118%);
    -webkit-backdrop-filter: blur(7px) saturate(118%);
  }

  .now-sheet-panel {
    position: absolute;
    inset: 50% auto auto 50%;
    width: min(580px, calc(100vw - 48px));
    min-height: 0;
    height: auto;
    max-height: calc(100dvh - 48px);
    padding: 24px 34px 26px;
    border: 1px solid rgba(238, 241, 246, .16);
    border-radius: 32px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: none;
    box-shadow:
      0 44px 130px rgba(0, 0, 0, .72),
      0 0 0 1px rgba(225, 191, 112, .045),
      inset 0 1px 0 rgba(255, 255, 255, .07);
    transform: translate(-50%, -47%) scale(.965);
    transform-origin: center;
    opacity: 0;
    transition:
      transform .30s cubic-bezier(.2, .82, .24, 1),
      opacity .22s ease,
      box-shadow .3s ease;
    -webkit-user-select: none;
    user-select: none;
  }

  .now-sheet-panel::-webkit-scrollbar { display: none; }

  .now-sheet.is-open .now-sheet-panel {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }

  .now-sheet-top {
    flex: 0 0 auto;
    min-height: 46px;
  }

  .now-sheet-caption {
    font-size: 10px;
    letter-spacing: .20em;
  }

  .now-sheet-close,
  .now-sheet-share {
    transition: transform .18s ease, border-color .18s ease, background .18s ease;
  }

  .now-sheet-close:hover,
  .now-sheet-share:hover {
    transform: translateY(-1px);
    border-color: rgba(236, 205, 132, .30);
    background: rgba(255, 255, 255, .08);
  }

  .now-sheet-art-wrap {
    width: min(280px, 35vh);
    margin: clamp(18px, 2.8vh, 26px) auto 0;
    flex: 0 0 auto;
  }

  .now-sheet-art {
    border-radius: 28px;
    box-shadow:
      0 32px 86px rgba(0, 0, 0, .58),
      0 0 0 1px rgba(236, 205, 132, .06),
      inset 0 1px 0 rgba(255, 255, 255, .08);
  }

  /* Reserved copy zone: title can never collide with metadata or controls. */
  .now-sheet-copy {
    width: min(100%, 500px);
    min-height: 118px;
    margin: clamp(18px, 2.6vh, 26px) auto 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 8px;
    text-align: center;
  }

  .now-sheet-copy h2 {
    width: 100%;
    max-width: 500px;
    max-height: 2.18em;
    margin: 2px auto 0;
    padding: 0 2px;
    font-size: clamp(28px, 2.65vw, 36px);
    line-height: 1.09;
    white-space: normal;
    overflow: hidden;
    text-overflow: ellipsis;
    overflow-wrap: anywhere;
    word-break: normal;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    cursor: pointer;
  }

  /* Intentional reveal: click/tap title on desktop to read the full station name. */
  .now-sheet-copy h2.is-expanded {
    display: block;
    max-height: none;
    overflow: visible;
    -webkit-line-clamp: unset;
    font-size: clamp(24px, 2.25vw, 32px);
  }

  .now-sheet-copy h2:focus-visible {
    outline: 1px solid rgba(236, 205, 132, .45);
    outline-offset: 5px;
    border-radius: 8px;
  }

  .now-sheet-copy > p:last-child {
    width: 100%;
    min-height: 20px;
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* Stable control zones stop long content from pushing buttons into each other. */
  .now-sheet-controls {
    flex: 0 0 76px;
    min-height: 76px;
    margin: 18px auto 0;
    gap: 30px;
  }

  .now-sheet-volume-row {
    flex: 0 0 auto;
    width: min(100%, 410px);
    min-height: 32px;
    margin: 18px auto 0;
  }

  .now-sheet-volume-row input {
    -webkit-user-select: auto;
    user-select: auto;
  }

  .now-sheet-source {
    margin: 18px auto 0;
    padding-top: 0;
    flex: 0 0 auto;
  }
}

/* Short desktop/tablet screens: compact art/margins before ever crushing controls. */
@media (min-width: 621px) and (max-height: 760px) {
  .now-sheet-panel {
    max-height: calc(100dvh - 28px);
    padding: 16px 28px 18px;
    border-radius: 26px;
  }

  .now-sheet-top { min-height: 42px; }
  .now-sheet-art-wrap { width: min(220px, 31vh); margin-top: 10px; }
  .now-sheet-copy { min-height: 100px; margin-top: 14px; gap: 6px; }
  .now-sheet-copy h2 { font-size: clamp(24px, 2.45vw, 31px); }
  .now-sheet-copy h2.is-expanded { font-size: clamp(21px, 2.1vw, 27px); }
  .now-sheet-copy > p:last-child { font-size: 12px; }
  .now-sheet-controls { min-height: 70px; flex-basis: 70px; margin-top: 12px; }
  .now-sheet-volume-row { margin-top: 12px; }
  .now-sheet-source { margin-top: 12px; }
}
