/* Wobblehook Radio. Scoped under #wh-radio. */

#wh-radio {
  --whr-deep: #161416;
  --whr-footer: #121113;
  --whr-card: #1c1a1b;
  --whr-wood: #35302b;
  --whr-gold: #d7b378;
  --whr-gold-light: #f1d7a7;
  --whr-cream: #f7eddb;
  --whr-muted: #c5bdb1;
  --whr-coastal: #80a8ae;
  --whr-line: #d7b37840;
  --whr-ink: #302617;

  --whr-heading: "Bree Serif", Georgia, serif;
  --whr-label: "Barlow Condensed", "Arial Narrow", sans-serif;
  --whr-body: "Inter", Arial, sans-serif;

  position: fixed;
  z-index: 90;
  left: 0;
  right: 0;
  bottom: 0;

  color: var(--whr-cream);
  font-family: var(--whr-body);
  font-size: 14px;
  line-height: 1.4;
  letter-spacing: 0;

  pointer-events: none;
}

#wh-radio audio {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

#wh-radio button,
#wh-radio input {
  font: inherit;
  color: inherit;
  letter-spacing: inherit;
}

#wh-radio button {
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

body {
  padding-bottom: calc(var(--whr-dock-space, 92px) + env(safe-area-inset-bottom)) !important;
}

.whr-scrim {
  position: fixed;
  inset: 0;
  z-index: 1;
  border: 0;
  padding: 0;
  background: #100e1090;
  pointer-events: auto;
}

.whr-scrim[hidden],
.whr-panel[hidden] {
  display: none !important;
}

.whr-panel {
  position: absolute;
  z-index: 2;
  left: 0;
  right: 0;
  bottom: 100%;

  display: flex;
  flex-direction: column;
  max-height: min(62vh, 520px);

  background:
    linear-gradient(#ffffff08, #0000 80px),
    var(--whr-deep);
  border-top: 1px solid var(--whr-line);
  box-shadow: 0 -18px 40px #000a;

  pointer-events: auto;
}

.whr-panel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;

  padding: 16px 18px 12px;
  border-bottom: 1px solid var(--whr-line);
}

.whr-kicker {
  margin: 0 0 2px;
  color: var(--whr-gold);
  font-family: var(--whr-label);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.whr-panel-head h2 {
  margin: 0;
  color: var(--whr-cream);
  font-family: var(--whr-heading);
  font-size: 28px;
  font-weight: 400;
  line-height: 1;
}

.whr-close {
  min-height: 36px;
  padding: 6px 12px;
  border: 1px solid var(--whr-line);
  background: transparent;
  color: var(--whr-gold-light);
  font-family: var(--whr-label);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.whr-close:hover {
  border-color: var(--whr-gold);
}

.whr-list {
  margin: 0;
  padding: 8px;
  overflow: auto;
  list-style: none;
}

.whr-empty {
  margin: 0;
  padding: 22px 16px 28px;
  color: var(--whr-muted);
}

.whr-empty code {
  color: var(--whr-gold-light);
  font-size: 13px;
}

.whr-track {
  display: grid;
  grid-template-columns: 36px 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  width: 100%;

  padding: 8px;
  border: 1px solid transparent;
  background: transparent;
  text-align: left;
}

.whr-track:hover {
  background: #ffffff08;
  border-color: var(--whr-line);
}

.whr-track[aria-current="true"] {
  background: #35302b;
  border-color: #d7b37888;
}

.whr-num {
  color: var(--whr-gold);
  font-family: var(--whr-label);
  font-size: 18px;
  font-weight: 700;
  text-align: center;
}

.whr-thumb,
.whr-art,
.whr-mark {
  width: 48px;
  height: 48px;
  object-fit: cover;
  background: var(--whr-wood);
  border: 1px solid #d7b37855;
}

.whr-mark {
  display: grid;
  place-items: center;
  color: var(--whr-gold);
  font-family: var(--whr-label);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.whr-thumb-wrap {
  position: relative;
  width: 48px;
  height: 48px;
}

.whr-thumb-wrap .whr-mark,
.whr-thumb-wrap .whr-thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.whr-track-copy {
  min-width: 0;
}

.whr-track-copy strong,
.whr-title {
  display: block;
  overflow: hidden;
  color: var(--whr-cream);
  font-family: var(--whr-heading);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.whr-track-copy small,
.whr-artist {
  display: block;
  overflow: hidden;
  margin-top: 2px;
  color: var(--whr-muted);
  font-family: var(--whr-label);
  font-size: 14px;
  font-style: normal;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-transform: uppercase;
}

.whr-dock {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: auto minmax(150px, 280px) minmax(160px, 1fr) auto auto;
  gap: 8px 14px;
  align-items: center;

  min-height: 84px;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));

  background:
    linear-gradient(#ffffff0a, #0000 28px),
    var(--whr-footer);
  border-top: 2px solid #b5915866;
  box-shadow: 0 -8px 24px #0008;

  pointer-events: auto;
}

.whr-transport {
  display: flex;
  align-items: center;
  gap: 8px;
}

.whr-play,
.whr-skip {
  display: grid;
  place-items: center;
  border-radius: 2px;
}

.whr-play {
  width: 52px;
  height: 48px;
  border: 1px solid #f7d8a0;
  background:
    repeating-linear-gradient(0deg, #67390c00 0 8px, #67390c14 8px 9px),
    linear-gradient(#e6c58d, #c89d5b);
  color: var(--whr-ink);
  box-shadow:
    inset 0 0 0 3px #72532135,
    0 3px 0 #735630;
}

.whr-play:hover {
  filter: brightness(1.08);
}

.whr-play:active,
.whr-skip:active,
.whr-tracks:active {
  transform: translateY(1px);
}

.whr-skip,
.whr-tracks {
  height: 42px;
  border: 1px solid #b49a73;
  background:
    repeating-linear-gradient(0deg, #0000 0 8px, #16141618 8px 9px),
    linear-gradient(#474442, #302c2b);
  color: var(--whr-cream);
  box-shadow:
    inset 0 0 0 3px #17141660,
    0 3px 0 #121113;
}

.whr-skip {
  width: 42px;
}

.whr-now {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
}

.whr-now:hover .whr-title {
  color: var(--whr-gold-light);
}

.whr-seek {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.whr-time {
  color: var(--whr-gold-light);
  font-family: var(--whr-label);
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

.whr-progress,
.whr-volume input {
  width: 100%;
  height: 22px;
  margin: 0;
  accent-color: var(--whr-gold);
  cursor: pointer;
}

.whr-side {
  display: flex;
  align-items: center;
  gap: 12px;
}

.whr-volume {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 118px;
  color: var(--whr-muted);
  font-family: var(--whr-label);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.whr-tracks {
  min-width: 92px;
  padding: 0 14px;
  font-family: var(--whr-label);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.whr-tracks[aria-expanded="true"] {
  color: var(--whr-ink);
  border-color: #f7d8a0;
  background:
    repeating-linear-gradient(0deg, #67390c00 0 8px, #67390c14 8px 9px),
    linear-gradient(#e6c58d, #c89d5b);
}

.whr-live {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

@media (max-width: 860px) {
  .whr-dock {
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-areas:
      "transport now tracks"
      "seek seek seek";
    gap: 6px 10px;
    padding-inline: 12px;
  }

  .whr-transport { grid-area: transport; }
  .whr-now { grid-area: now; }
  .whr-tracks { grid-area: tracks; min-width: 76px; padding-inline: 10px; }
  .whr-seek { grid-area: seek; }
  .whr-volume { display: none; }

  .whr-play { width: 46px; height: 42px; }
  .whr-skip { width: 36px; height: 36px; }
  .whr-panel-head h2 { font-size: 24px; }
}

@media (max-width: 420px) {
  .whr-now .whr-art,
  .whr-now .whr-mark { display: none; }
  .whr-now { grid-template-columns: minmax(0, 1fr); }
  .whr-track-copy strong,
  .whr-title { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  #wh-radio * {
    transition: none !important;
    animation: none !important;
  }
}