:root {
  --font-main: "Pretendard", "Noto Sans KR", "Malgun Gothic", sans-serif;
  --ink: #1d2a24;
  --muted: #68746d;
  --paper: #f4f0e6;
  --card: #fffdf7;
  --line: #d8d7ca;
  --green: #1f6f52;
  --green-soft: #d9eadf;
  --coral: #e76445;
  --yellow: #e5ac3a;
  --red: #cb493c;
  --shadow: 0 24px 60px rgba(50, 59, 48, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  font-family: var(--font-main);
  background:
    radial-gradient(circle at 8% 5%, rgba(231, 100, 69, 0.16), transparent 23rem),
    radial-gradient(circle at 93% 18%, rgba(31, 111, 82, 0.14), transparent 27rem),
    var(--paper);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  opacity: 0.3;
  background-image: linear-gradient(rgba(29, 42, 36, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(29, 42, 36, 0.08) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 75%);
}

button,
a {
  font: inherit;
}

button {
  color: inherit;
}

.page-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 84px;
  border-bottom: 1px solid rgba(29, 42, 36, 0.16);
}

.brand {
  display: inline-flex;
  gap: 11px;
  align-items: center;
  color: var(--ink);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  color: var(--card);
  font-size: 12px;
  letter-spacing: 0.04em;
  background: var(--ink);
  border-radius: 50% 50% 50% 12px;
  place-items: center;
}

.session-state {
  display: flex;
  gap: 9px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.03em;
}

.state-dot {
  width: 8px;
  height: 8px;
  background: #9ca49f;
  border-radius: 50%;
}

.state-dot.active {
  background: var(--coral);
  box-shadow: 0 0 0 6px rgba(231, 100, 69, 0.14);
  animation: pulse 1.2s infinite;
}

.hero {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr;
  gap: 60px;
  align-items: end;
  padding: 76px 0 48px;
}

.eyebrow,
.section-kicker {
  margin: 0 0 12px;
  color: var(--coral);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-family: var(--font-main);
  font-size: clamp(38px, 4.8vw, 66px);
  font-weight: 500;
  line-height: 1.03;
  letter-spacing: -0.055em;
}

h1 em {
  color: var(--green);
  font-weight: inherit;
}

.hero-copy {
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.8;
}

.practice-card {
  overflow: hidden;
  background: var(--card);
  border: 1px solid rgba(29, 42, 36, 0.16);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.practice-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 32px 36px 26px;
}

.practice-head h2,
.results-heading h2 {
  margin-bottom: 8px;
  font-family: var(--font-main);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 500;
  letter-spacing: -0.04em;
}

.practice-head p:not(.section-kicker) {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.song-picker {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  margin: 0 0 18px;
  padding: 7px 9px 7px 12px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  background: #f2efe5;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.song-picker select {
  min-width: 180px;
  padding: 7px 30px 7px 10px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 7px;
  cursor: pointer;
}

.song-picker select:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.time-display {
  padding-top: 8px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.time-display strong {
  color: var(--ink);
  font-size: 22px;
}

.score-wrap {
  position: relative;
  height: 370px;
  overflow: hidden;
  background: #17211c;
}

#pitchCanvas {
  display: block;
  width: 100%;
  height: 100%;
}

.playhead-label {
  position: absolute;
  top: 13px;
  left: 27.5%;
  z-index: 2;
  padding: 4px 8px;
  color: #17211c;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.15em;
  background: #f5c54b;
  border-radius: 5px;
  transform: translateX(-50%);
}

.voice-wave-legend {
  position: absolute;
  top: 14px;
  right: 18px;
  z-index: 3;
  display: flex;
  gap: 7px;
  align-items: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: 9px;
  letter-spacing: 0.04em;
  pointer-events: none;
}

.voice-wave-legend span {
  width: 22px;
  height: 3px;
  background: #5ce69a;
  border-radius: 10px;
  box-shadow: 0 0 9px #5ce69a;
}

.lyric-guide {
  position: absolute;
  right: 24px;
  bottom: 17px;
  left: 24px;
  z-index: 3;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 22px;
  align-items: center;
  color: rgba(255, 255, 255, 0.38);
  font-family: var(--font-main);
  font-size: 15px;
  pointer-events: none;
}

.lyric-guide strong {
  min-width: 96px;
  color: #f5c54b;
  font-size: 25px;
  font-weight: 500;
  text-align: center;
  text-shadow: 0 3px 14px rgba(0, 0, 0, 0.42);
}

.lyric-guide span:first-child {
  text-align: right;
}

.lyric-guide span:last-child {
  text-align: left;
}

.countdown {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  color: white;
  font-family: var(--font-main);
  font-size: 110px;
  background: rgba(23, 33, 28, 0.7);
  backdrop-filter: blur(4px);
  place-items: center;
}

.empty-guide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.66);
  text-align: center;
  background: rgba(23, 33, 28, 0.28);
}

.empty-guide strong {
  color: white;
  font-size: 17px;
}

.empty-guide span:last-child {
  font-size: 13px;
}

.guide-icon {
  margin-bottom: 6px;
  color: #f5c54b;
  font-family: var(--font-main);
  font-size: 46px;
}

.live-strip {
  display: grid;
  grid-template-columns: 0.7fr 0.7fr 1.5fr 1fr;
  min-height: 82px;
  border-bottom: 1px solid var(--line);
}

.live-metric {
  display: flex;
  flex-direction: column;
  gap: 6px;
  justify-content: center;
  padding: 0 24px;
  border-right: 1px solid var(--line);
}

.live-metric span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.live-metric strong {
  overflow: hidden;
  font-size: 16px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.volume-meter {
  position: relative;
  align-self: center;
  height: 8px;
  margin: 0 25px;
  overflow: hidden;
  background: #e8e7df;
  border-radius: 100px;
}

.volume-meter::before {
  position: absolute;
  right: 0;
  bottom: 17px;
  left: 0;
  color: var(--muted);
  content: "MIC LEVEL";
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.09em;
}

#volumeFill {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--green), #f5c54b, var(--coral));
  border-radius: inherit;
  transition: width 80ms linear;
}

.controls {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  padding: 28px 30px 30px;
}

.backing-control {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) minmax(140px, 240px) 42px;
  gap: 18px;
  align-items: center;
  width: min(560px, 100%);
  margin-bottom: 4px;
  padding: 13px 18px;
  background: #f2efe5;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.backing-label {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.backing-label strong {
  font-size: 12px;
}

.backing-label small {
  color: var(--muted);
  font-size: 10px;
}

.backing-control input {
  width: 100%;
  accent-color: var(--green);
  cursor: pointer;
}

.backing-control output {
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.mic-test {
  display: grid;
  grid-template-columns: minmax(130px, 180px) auto minmax(160px, 1fr);
  gap: 14px;
  align-items: center;
  width: min(560px, 100%);
}

.mic-test > select {
  min-width: 0;
  padding: 10px 30px 10px 11px;
  color: var(--ink);
  font-size: 11px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}

.mic-test > select:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.mic-test button {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 10px 14px;
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  background: var(--green-soft);
  border: 1px solid rgba(31, 111, 82, 0.22);
  border-radius: 10px;
  cursor: pointer;
}

.mic-test button.testing {
  color: white;
  background: var(--green);
}

.mic-test button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.mic-test-icon {
  width: 8px;
  height: 8px;
  background: currentColor;
  border-radius: 50%;
}

.testing .mic-test-icon {
  animation: pulse 1s infinite;
}

.mic-test-result {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mic-test-meter {
  height: 8px;
  overflow: hidden;
  background: #e4e3da;
  border-radius: 20px;
}

#micTestFill {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--green), #f5c54b, var(--coral));
  border-radius: inherit;
  transition: width 70ms linear;
}

.mic-test-result strong {
  color: var(--muted);
  font-size: 10px;
  font-weight: 500;
}

.record-button {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
  min-width: 210px;
  padding: 16px 25px;
  color: white;
  font-weight: 700;
  background: var(--coral);
  border: 0;
  border-radius: 100px;
  box-shadow: 0 12px 24px rgba(231, 100, 69, 0.24);
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease;
}

.record-button:hover {
  background: #d95739;
  transform: translateY(-2px);
}

.record-button.recording {
  background: var(--ink);
}

.record-button:disabled {
  cursor: wait;
  opacity: 0.65;
  transform: none;
}

.record-icon {
  width: 12px;
  height: 12px;
  background: currentColor;
  border-radius: 50%;
}

.recording .record-icon {
  border-radius: 2px;
}

.controls p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.results {
  padding-top: 76px;
  animation: reveal 500ms ease both;
}

.results-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 24px;
}

.results-heading h2 {
  margin-bottom: 0;
}

.text-button {
  padding: 10px 0;
  color: var(--green);
  font-weight: 700;
  background: transparent;
  border: 0;
  cursor: pointer;
}

.score-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 16px;
}

.voice-quality-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.voice-quality-grid article {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 15px;
  align-items: start;
  padding: 20px;
  background: rgba(255, 253, 247, 0.74);
  border: 1px solid rgba(29, 42, 36, 0.15);
  border-radius: 16px;
}

.quality-icon {
  display: grid;
  width: 42px;
  height: 42px;
  color: var(--green);
  font-family: var(--font-main);
  font-size: 22px;
  background: var(--green-soft);
  border-radius: 12px;
  place-items: center;
}

.voice-quality-grid article div > span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.voice-quality-grid strong {
  font-family: var(--font-main);
  font-size: 25px;
  font-weight: 500;
}

.voice-quality-grid p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}

.progress-panel {
  display: grid;
  grid-template-columns: 1.1fr 1fr 0.9fr;
  gap: 28px;
  align-items: center;
  margin-top: 16px;
  padding: 26px 30px;
  color: white;
  background: var(--ink);
  border-radius: 20px;
}

.progress-copy h3 {
  margin-bottom: 8px;
  font-family: var(--font-main);
  font-size: 21px;
  font-weight: 500;
}

.progress-copy p:last-child {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  line-height: 1.55;
}

.progress-deltas {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.progress-deltas div {
  padding: 12px 10px;
  text-align: center;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
}

.progress-deltas span,
.history-chart-wrap > span {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.progress-deltas strong {
  color: #f5c54b;
  font-size: 13px;
}

.progress-deltas strong.positive {
  color: #67d99a;
}

.progress-deltas strong.negative {
  color: #ff8174;
}

.history-chart {
  display: flex;
  gap: 7px;
  align-items: end;
  height: 70px;
  padding-top: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.history-bar {
  position: relative;
  flex: 1;
  min-width: 10px;
  max-width: 28px;
  height: var(--score-height);
  min-height: 5px;
  background: rgba(255, 255, 255, 0.28);
  border-radius: 5px 5px 0 0;
  animation: grow-bar 500ms ease both;
}

.history-bar.current {
  background: #f5c54b;
}

.history-bar::after {
  position: absolute;
  top: -17px;
  left: 50%;
  color: rgba(255, 255, 255, 0.65);
  content: attr(data-score);
  font-size: 8px;
  transform: translateX(-50%);
}

.personal-plan {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 16px;
  margin-top: 16px;
}

.plan-profile,
.plan-schedule {
  padding: 30px;
  border-radius: 20px;
}

.plan-profile {
  color: white;
  background:
    radial-gradient(circle at 100% 0, rgba(245, 197, 75, 0.24), transparent 14rem),
    var(--green);
}

.plan-profile h3 {
  margin-bottom: 14px;
  font-family: var(--font-main);
  font-size: 29px;
  font-weight: 500;
  line-height: 1.22;
  letter-spacing: -0.035em;
}

.plan-profile > p:not(.section-kicker) {
  margin-bottom: 24px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  line-height: 1.65;
}

.profile-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.profile-facts div {
  padding: 13px 11px;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
}

.profile-facts span {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 9px;
}

.profile-facts strong {
  font-size: 13px;
}

.plan-schedule {
  background: var(--card);
  border: 1px solid rgba(29, 42, 36, 0.15);
}

.plan-item {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}

.plan-item:first-child {
  border-top: 0;
}

.plan-day {
  color: var(--coral);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.07em;
}

.plan-detail strong {
  display: block;
  margin-bottom: 5px;
  font-size: 14px;
}

.plan-detail span {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.plan-duration {
  padding: 6px 9px;
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
  background: var(--green-soft);
  border-radius: 20px;
}

.ai-trainer-panel {
  margin-top: 16px;
  padding: 30px;
  background: var(--card);
  border: 2px solid var(--green);
  border-radius: 20px;
}

.ai-trainer-head {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  justify-content: space-between;
}

.ai-trainer-head h3 {
  margin-bottom: 7px;
  font-size: 24px;
}

.ai-trainer-head p:not(.section-kicker) {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.ai-status-badge {
  flex: 0 0 auto;
  padding: 8px 11px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  background: #ecebe4;
  border-radius: 20px;
}

.ai-status-badge.loading {
  color: #8c6415;
  background: #fae8b8;
  animation: pulse 1.2s infinite;
}

.ai-status-badge.complete {
  color: var(--green);
  background: var(--green-soft);
}

.ai-trainer-content {
  margin-top: 25px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.acoustic-metrics {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 9px;
}

.acoustic-metric {
  padding: 14px 12px;
  background: #f2efe5;
  border-radius: 12px;
}

.acoustic-metric span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 9px;
}

.acoustic-metric strong {
  font-size: 15px;
}

.trainer-diagnosis {
  margin-top: 26px;
}

.trainer-diagnosis h4 {
  margin: 0 0 10px;
  font-size: 19px;
}

.trainer-diagnosis h5 {
  margin: 19px 0 10px;
  color: var(--green);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.trainer-summary {
  max-width: 850px;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.75;
}

.trainer-columns {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 28px;
}

.trainer-columns ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}

.ai-issue {
  margin-top: 8px;
  padding: 12px 14px;
  background: #f6eee5;
  border-left: 3px solid var(--coral);
  border-radius: 0 10px 10px 0;
}

.ai-issue strong,
.ai-exercise strong {
  display: block;
  margin-bottom: 4px;
  font-size: 12px;
}

.ai-issue span,
.ai-issue p,
.ai-exercise p {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

.ai-exercises {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.ai-exercise {
  padding: 15px;
  background: var(--green-soft);
  border-radius: 12px;
}

.ai-exercise time {
  display: inline-block;
  margin-top: 9px;
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
}

.score-card {
  min-height: 190px;
  padding: 26px;
  background: rgba(255, 253, 247, 0.72);
  border: 1px solid rgba(29, 42, 36, 0.15);
  border-radius: 20px;
}

.score-card > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.score-card div {
  margin: 18px 0 12px;
}

.score-card strong {
  font-family: var(--font-main);
  font-size: 64px;
  font-weight: 500;
  line-height: 1;
}

.score-card small {
  margin-left: 5px;
  font-size: 14px;
}

.score-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.primary-score {
  color: white;
  background: var(--green);
  border-color: var(--green);
}

.primary-score > span,
.primary-score p {
  color: rgba(255, 255, 255, 0.72);
}

.feedback-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 16px;
  margin-top: 16px;
}

.feedback-panel {
  padding: 30px;
  background: var(--card);
  border: 1px solid rgba(29, 42, 36, 0.15);
  border-radius: 20px;
}

.accent-panel {
  background: #f0ddc7;
}

.panel-title {
  display: flex;
  gap: 13px;
  align-items: center;
  margin-bottom: 24px;
}

.panel-title h3 {
  margin: 0;
  font-family: var(--font-main);
  font-size: 22px;
  font-weight: 500;
}

.panel-number {
  display: grid;
  width: 29px;
  height: 29px;
  color: var(--card);
  font-size: 10px;
  background: var(--ink);
  border-radius: 50%;
  place-items: center;
}

.segment-item {
  display: grid;
  grid-template-columns: 58px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.segment-item:first-child {
  border-top: 0;
}

.segment-note {
  font-family: var(--font-main);
  font-size: 19px;
}

.segment-bar {
  height: 7px;
  overflow: hidden;
  background: #e8e7df;
  border-radius: 20px;
}

.segment-bar span {
  display: block;
  height: 100%;
  background: var(--green);
  border-radius: inherit;
}

.segment-item.warn .segment-bar span {
  background: var(--yellow);
}

.segment-item.bad .segment-bar span {
  background: var(--red);
}

.segment-result {
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}

.training-lead {
  margin-bottom: 20px;
  font-family: var(--font-main);
  font-size: 21px;
  line-height: 1.55;
}

.training-step {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 10px;
  margin-top: 12px;
  font-size: 14px;
  line-height: 1.55;
}

.training-step span {
  display: grid;
  width: 26px;
  height: 26px;
  color: white;
  font-size: 11px;
  background: var(--coral);
  border-radius: 50%;
  place-items: center;
}

.safety-note {
  margin: 26px 0 0;
  padding-top: 18px;
  color: rgba(29, 42, 36, 0.65);
  font-size: 11px;
  line-height: 1.6;
  border-top: 1px solid rgba(29, 42, 36, 0.16);
}

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 88px;
  padding: 26px 0 34px;
  color: var(--muted);
  font-size: 12px;
  border-top: 1px solid rgba(29, 42, 36, 0.16);
}

footer span {
  color: var(--ink);
  font-weight: 700;
}

footer p {
  margin: 0;
}

.hidden {
  display: none !important;
}

@keyframes pulse {
  50% {
    box-shadow: 0 0 0 10px rgba(231, 100, 69, 0);
  }
}

@keyframes reveal {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
}

@keyframes grow-bar {
  from {
    height: 0;
  }
}

@media (max-width: 780px) {
  .page-shell {
    width: min(100% - 24px, 1180px);
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 48px 0 32px;
  }

  h1 {
    font-size: clamp(35px, 10.5vw, 50px);
  }

  .practice-head {
    padding: 25px 22px 21px;
  }

  .time-display {
    display: none;
  }

  .score-wrap {
    height: 330px;
  }

  .lyric-guide {
    right: 14px;
    left: 14px;
    gap: 10px;
    font-size: 12px;
  }

  .lyric-guide strong {
    min-width: 70px;
    font-size: 21px;
  }

  .live-strip {
    grid-template-columns: 1fr 1fr;
  }

  .live-metric {
    min-height: 70px;
    padding: 0 18px;
  }

  .live-metric.wide {
    border-top: 1px solid var(--line);
  }

  .volume-meter {
    margin: 0 18px;
  }

  .score-grid,
  .feedback-grid,
  .voice-quality-grid {
    grid-template-columns: 1fr;
  }

  .progress-panel {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .personal-plan {
    grid-template-columns: 1fr;
  }

  .acoustic-metrics {
    grid-template-columns: repeat(2, 1fr);
  }

  .trainer-columns,
  .ai-exercises {
    grid-template-columns: 1fr;
  }

  .history-chart-wrap {
    max-width: 320px;
  }

  .results {
    padding-top: 58px;
  }

  .results-heading {
    align-items: flex-start;
  }

  .score-card {
    min-height: 170px;
  }

  footer {
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  .session-state {
    font-size: 11px;
  }

  .hero-copy br {
    display: none;
  }

  .empty-guide {
    padding: 20px;
  }

  .empty-guide span:last-child {
    max-width: 230px;
  }

  .live-strip {
    grid-template-columns: 1fr 1fr;
  }

  .live-metric.wide {
    grid-column: 1 / -1;
  }

  .volume-meter {
    display: none;
  }

  .backing-control {
    grid-template-columns: 1fr 42px;
    gap: 10px;
  }

  .mic-test {
    grid-template-columns: 1fr;
  }

  .mic-test button {
    justify-content: center;
  }

  .backing-label {
    grid-column: 1 / -1;
  }

  .feedback-panel {
    padding: 23px 20px;
  }

  .profile-facts {
    grid-template-columns: 1fr;
  }

  .plan-item {
    grid-template-columns: 54px 1fr;
  }

  .plan-duration {
    grid-column: 2;
    justify-self: start;
  }

  .segment-item {
    grid-template-columns: 43px 1fr auto;
    gap: 9px;
  }

  footer p {
    max-width: 180px;
    text-align: right;
  }
}
