:root {
  color-scheme: light;
  --bg: #f7f7f5;
  --panel: #ffffff;
  --text: #242424;
  --muted: #666a70;
  --line: #d9d9d6;
  --accent: #246b5a;
  --accent-soft: #e8f1ed;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.shell {
  max-width: 1120px;
  margin: 0 auto;
  padding: 28px 20px 44px;
}

.topbar {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 18px;
  margin-bottom: 24px;
}

.topbar h1 {
  margin: 0;
  font-size: 24px;
  font-weight: 650;
}

.topbar p {
  margin: 4px 0 0;
  color: var(--muted);
}

.nav {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 14px;
}

.section {
  margin-top: 26px;
}

.section h2 {
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 650;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.metric,
.empty {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

.metric strong {
  display: block;
  font-size: 28px;
  line-height: 1.1;
}

.metric span,
.muted {
  color: var(--muted);
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--panel);
  border: 1px solid var(--line);
}

th,
td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
}

tr:last-child td {
  border-bottom: 0;
}

.badge {
  display: inline-block;
  border-radius: 999px;
  padding: 2px 8px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 12px;
  font-weight: 650;
}

.transcript {
  display: grid;
  gap: 10px;
}

.turn {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
}

.turn-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 6px;
}

.turn p {
  margin: 0;
}

.turn audio {
  display: block;
  width: 100%;
  margin-top: 10px;
}

.transcript-form {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.transcript-form textarea {
  width: 100%;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  font: inherit;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.transcript-form button {
  justify-self: start;
  border: 1px solid var(--accent);
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  padding: 8px 12px;
  font: inherit;
  font-weight: 650;
}

@media (max-width: 720px) {
  .topbar {
    align-items: start;
    flex-direction: column;
  }

  table {
    display: block;
    overflow-x: auto;
  }
}
