/* 청력 나이 테스트 전용 */
.hear-card {
  margin-top: 22px;
  text-align: center;
  padding: 26px 20px;
}
.hear-kicker {
  display: inline-block;
  margin: 0 0 14px;
  padding: 4px 14px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 800;
  background: color-mix(in srgb, var(--early) 16%, transparent);
  color: var(--early);
}
.hear-checks {
  list-style: none;
  margin: 0 auto 20px;
  padding: 0;
  max-width: 26em;
  display: grid;
  gap: 8px;
  text-align: left;
}
.hear-checks li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 14px;
  border-radius: 14px;
  background: var(--surface-2);
  font-size: 0.95rem;
  line-height: 1.55;
}
.hear-checks li > span:first-child {
  flex: none;
  font-size: 1.15rem;
  line-height: 1.35;
}
.hear-checks strong {
  color: var(--ink);
}
.hear-title {
  font-size: clamp(1.25rem, 5vw, 1.55rem);
  font-weight: 800;
  margin: 6px 0 6px;
  letter-spacing: -0.01em;
}
.hear-sub {
  color: var(--muted);
  margin: 0 auto;
  max-width: 28em;
  font-size: 0.95rem;
}
.hear-count {
  margin: 0;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
}
.hear-card .btn {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}
.hear-main {
  min-width: min(100%, 280px);
}

/* 파동 표시 */
.hear-wave-wrap {
  margin: 0 0 14px;
}
.wave {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  height: 76px;
}
.wave span {
  display: block;
  width: 7px;
  height: 14px;
  border-radius: 999px;
  background: var(--line);
  transition: background 0.2s ease, height 0.2s ease;
}
.wave[data-playing='true'] span {
  background: #14b8a6;
  animation: wave-bob 0.9s ease-in-out infinite;
}
.wave[data-playing='true'] span:nth-child(2),
.wave[data-playing='true'] span:nth-child(8) {
  animation-delay: -0.15s;
}
.wave[data-playing='true'] span:nth-child(3),
.wave[data-playing='true'] span:nth-child(7) {
  animation-delay: -0.3s;
}
.wave[data-playing='true'] span:nth-child(4),
.wave[data-playing='true'] span:nth-child(6) {
  animation-delay: -0.45s;
}
.wave[data-playing='true'] span:nth-child(5) {
  animation-delay: -0.6s;
}
@keyframes wave-bob {
  0%,
  100% {
    height: 14px;
  }
  50% {
    height: 64px;
  }
}
.wave-label {
  margin: 4px 0 0;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--muted);
  min-height: 1.5em;
}
.wave[data-playing='true'] + .wave-label {
  color: #0f9488;
}
@media (prefers-reduced-motion: reduce) {
  .wave[data-playing='true'] span {
    animation: none;
    height: 40px;
  }
}

/* 답 단추 */
.hear-answers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 20px auto 0;
  max-width: 420px;
}
.hear-answers .btn {
  min-height: 64px;
  font-size: 1.1rem;
  border-radius: 18px;
}
.hear-yes {
  background: var(--go);
  color: #fff;
}
.hear-no {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--line);
}
.hear-answers .btn:disabled {
  opacity: 0.45;
  cursor: default;
  transform: none;
}
.hear-tools {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 6px;
}
.hear-tools .linkish {
  font-size: 0.92rem;
  min-height: 40px;
}
.hear-card .timebar span {
  background: #14b8a6;
  transform: scaleX(0);
  transition: transform 0.4s ease;
}
.hear-card .tries {
  min-height: 1.6em;
}

/* 등급표: 좁은 화면에서는 [나이 | 주파수] 한 줄 + 설명 한 줄로 쌓는다(세 칸이면 첫 칸이 한 글자씩 꺾인다). */
@media (max-width: 520px) {
  .table-wrap thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }
  .table-wrap tr {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 2px 12px;
    padding: 11px 4px;
    border-bottom: 1px solid var(--line);
  }
  .table-wrap tr:last-child {
    border-bottom: 0;
  }
  .table-wrap td {
    padding: 0;
    border: 0;
  }
  .table-wrap td:nth-child(3) {
    grid-column: 1 / -1;
    color: var(--muted);
    font-size: 0.9rem;
  }
}

/* 결과 */
#result {
  scroll-margin-top: 80px; /* 위에 붙은 머리말에 가리지 않게 */
}
.hear-card {
  scroll-margin-top: 80px;
}
.result-warn {
  margin: 14px auto 0;
  max-width: 30em;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 0.92rem;
  background: color-mix(in srgb, var(--early) 14%, transparent);
  color: var(--ink);
}
