/* =========================================================
   VOICE — 07, the audio memory
   ========================================================= */

.voice {
  position: relative;
  background: var(--ink-100);
  overflow: hidden;
}

/* A low, warm band behind the waveform so the section reads as a room
   with something playing in it. */
.voice::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 12%;
  transform: translateX(-50%);
  width: min(130vw, 1600px);
  aspect-ratio: 3 / 1;
  background: radial-gradient(
    ellipse at center,
    rgba(201, 162, 39, 0.08) 0%,
    transparent 66%
  );
  pointer-events: none;
}

.voice__inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: clamp(1.25rem, 2.6vw, 2rem);
}

.voice__line {
  font-size: var(--step-4);
  line-height: 1.02;
  color: var(--bone-100);
  max-width: 20ch;
}

.voice__line em {
  font-style: italic;
  color: var(--gold-200);
}

.voice__lede {
  max-width: 52ch;
  font-size: var(--step-0);
}

/* ---------------- the player ---------------- */

.voice__player {
  width: 100%;
  max-width: 1100px;
  margin-top: clamp(0.93rem, 2.4vw, 1.74rem);
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.voice__wave {
  position: relative;
  display: flex;
  align-items: center;
  gap: clamp(1px, 0.3vw, 3px);
  height: clamp(5rem, 13vw, 10rem);
  padding-inline: 2px;
}

.voice__bar {
  flex: 1;
  min-width: 0;
  height: 100%;
  border-radius: 999px;
  background: var(--ink-500);
  transform: scaleY(0.2);
  transform-origin: center;
  will-change: transform, background-color;
}

/* The playhead. A single hairline with a bead on it — the only element in
   the section that is allowed to look like a control. */
.voice__head {
  position: absolute;
  top: -6%;
  bottom: -6%;
  left: 0;
  width: 1px;
  background: var(--bone-100);
  pointer-events: none;
}

.voice__head::after {
  content: "";
  position: absolute;
  top: -3px;
  left: 50%;
  width: 7px;
  height: 7px;
  margin-left: -3.5px;
  border-radius: 50%;
  background: var(--bone-100);
  box-shadow: 0 0 14px 2px rgba(244, 239, 230, 0.45);
}

.voice__meta {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--rule);
}

.voice__time,
.voice__dur {
  font-family: var(--font-mono);
  font-size: var(--step--2);
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
  color: var(--bone-400);
}

.voice__time {
  color: var(--gold-200);
}

.voice__label {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: var(--step--1);
  color: var(--bone-300);
}

.voice__note {
  color: var(--bone-500);
  margin-top: 0.5rem;
}

@media (max-width: 640px) {
  .voice__meta {
    grid-template-columns: auto auto;
    justify-content: space-between;
  }

  .voice__label {
    grid-column: 1 / -1;
    grid-row: 2;
    text-align: left;
  }
}
