:root {
  font-family:
    Inter, "SF Pro Display", "SF Pro Text", "PingFang SC", "Microsoft YaHei",
    system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #08080a;
  background: #ffffff;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background:
    radial-gradient(circle at 50% 24%, rgba(0, 0, 0, 0.035), transparent 30%),
    #ffffff;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.page-shell {
  min-height: 100vh;
  padding-bottom: 42px;
  background:
    linear-gradient(180deg, rgba(248, 248, 249, 0.78) 0, #ffffff 72px),
    #ffffff;
}

.topbar {
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 44px;
  border-bottom: 1px solid #e5e5e7;
}

.brand {
  font-size: 25px;
  line-height: 1;
  font-weight: 760;
}

.topnav {
  display: flex;
  align-items: center;
  gap: 14px;
  color: #1a1a1c;
  font-size: 16px;
  line-height: 1;
}

.lab-link {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #696970;
  font-size: 14px;
  line-height: 1;
  font-weight: 640;
}

.lab-link:hover,
.lab-link:focus-visible {
  color: #111113;
  border-color: #d4d4d8;
  background: rgba(255, 255, 255, 0.72);
  outline: none;
}

.ai-badge {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  border: 1px solid #d4d4d8;
  border-radius: 8px;
  color: #242427;
  background: rgba(255, 255, 255, 0.72);
}

.shield {
  position: relative;
  width: 20px;
  height: 23px;
  display: inline-block;
  border: 2px solid currentColor;
  border-radius: 9px 9px 11px 11px;
  transform: scaleX(0.86);
}

.shield::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 6px;
  width: 7px;
  height: 4px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
}

.hero {
  max-width: 980px;
  margin: 49px auto 29px;
  text-align: center;
  padding: 0 24px;
}

.hero h1 {
  margin: 0;
  font-size: 74px;
  line-height: 1.08;
  font-weight: 820;
}

.hero p {
  margin: 23px 0 0;
  color: #3f3f46;
  font-size: 21px;
  line-height: 1.45;
  font-weight: 420;
}

.upload-panel {
  width: 884px;
  margin: 0 auto;
  padding: 38px 43px 39px;
  border: 1px solid #d9d9dc;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(18px);
}

.upload-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.upload-zone {
  position: relative;
  min-height: 178px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1.5px dashed #a9a9af;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.52);
  cursor: pointer;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.upload-zone:hover,
.upload-zone:focus-within,
.upload-zone.is-dragging {
  border-color: #111113;
  background: rgba(250, 250, 251, 0.92);
}

.upload-zone.has-file,
.upload-zone.has-submitted {
  border-color: #111113;
  border-style: solid;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 246, 247, 0.94)),
    #ffffff;
  box-shadow:
    inset 0 0 0 1px rgba(17, 17, 19, 0.08),
    0 12px 28px rgba(0, 0, 0, 0.08);
}

.upload-zone.has-file::before,
.upload-zone.has-submitted::before {
  content: "已选择";
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 1;
  padding: 5px 9px 6px;
  border-radius: 999px;
  color: #ffffff;
  background: #111113;
  font-size: 12px;
  line-height: 1;
  font-weight: 720;
  letter-spacing: 0;
}

.upload-zone.has-submitted::before {
  content: "本次提交";
  background: #303036;
}

.upload-zone input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.upload-zone strong {
  max-width: 286px;
  color: #0b0b0d;
  font-size: 21px;
  line-height: 1.2;
  font-weight: 720;
  text-align: center;
  overflow-wrap: anywhere;
}

.upload-zone small {
  color: #6a6a71;
  font-size: 15px;
  line-height: 1.35;
}

.upload-zone.has-file small,
.upload-zone.has-submitted small {
  color: #232328;
  font-weight: 680;
}

.file-name {
  max-width: 88%;
  padding: 8px 13px;
  border-radius: 7px;
  color: #ffffff;
  background: #111113;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
  font-size: 15px;
  line-height: 1.25;
  font-weight: 720;
  text-align: center;
  overflow-wrap: anywhere;
}

.upload-zone.has-submitted .file-name {
  background: #303036;
}

.file-glyph {
  position: relative;
  width: 54px;
  height: 58px;
  display: inline-grid;
  place-items: center;
  color: #111113;
  flex: 0 0 auto;
}

.file-shape {
  width: 42px;
  height: 52px;
  border: 2px solid #141416;
  border-radius: 4px;
  background:
    linear-gradient(135deg, transparent 0 49%, #141416 50% 54%, transparent 55%) right top / 18px 18px no-repeat,
    #ffffff;
}

.file-glyph > span:last-child,
.mini-file {
  position: absolute;
  left: 10px;
  bottom: 4px;
  min-width: 34px;
  padding: 2px 3px 3px;
  border-radius: 3px;
  color: #ffffff;
  background: #171719;
  font-size: 11px;
  line-height: 1;
  font-weight: 820;
  text-align: center;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px;
  align-items: end;
  margin-top: 28px;
}

.form-row label {
  display: grid;
  gap: 9px;
  color: #19191c;
  font-size: 16px;
  line-height: 1;
  font-weight: 560;
}

.form-row input {
  width: 100%;
  height: 48px;
  padding: 0 15px;
  color: #111113;
  border: 1px solid #cfcfd4;
  border-radius: 6px;
  outline: none;
  background: #ffffff;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease;
}

.form-row input::placeholder {
  color: #96979d;
}

.form-row input:focus {
  border-color: #0a0a0b;
  box-shadow: 0 0 0 3px rgba(10, 10, 11, 0.08);
}

.generate-button,
.download-button {
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  border: 0;
  border-radius: 6px;
  color: #ffffff;
  background: linear-gradient(180deg, #171718 0%, #050506 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 12px 22px rgba(0, 0, 0, 0.12);
  font-size: 22px;
  line-height: 1;
  font-weight: 650;
}

.generate-button:hover,
.download-button:hover {
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 15px 28px rgba(0, 0, 0, 0.16);
}

.generate-button:disabled,
.download-button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
  transform: none;
  box-shadow: none;
}

.assurance-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  margin: 28px auto 0;
  color: #27272b;
  font-size: 17px;
  line-height: 1;
}

.assurance-row span {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.assurance-row .shield {
  width: 20px;
  height: 23px;
}

.assurance-row i {
  width: 1px;
  height: 24px;
  background: #dedee2;
}

.status-note {
  width: 884px;
  margin: 18px auto 0;
  padding: 13px 16px;
  border: 1px solid #d9d9dc;
  border-radius: 8px;
  text-align: center;
  font-size: 15px;
}

.status-note strong {
  margin-right: 10px;
}

.status-detail {
  display: block;
  margin-top: 7px;
  color: inherit;
  opacity: 0.78;
}

.status-note.is-done {
  border-color: #c8e3c9;
  color: #235b28;
  background: #f0fbf1;
}

.status-note.is-error {
  border-color: #f1c4c4;
  color: #7b1d1d;
  background: #fff3f3;
}

.failure-detail {
  width: 884px;
  margin: 14px auto 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid #dedee4;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.07);
}

.failure-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 54px;
  padding: 14px 18px;
  border-bottom: 1px solid #ececf0;
  color: #111113;
  background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
  font-size: 14px;
  line-height: 1;
}

.failure-head span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  color: #ffffff;
  background: #111113;
  font-weight: 720;
  white-space: nowrap;
}

.failure-head strong {
  flex: 1;
  color: #111113;
  font-size: 16px;
}

.failure-head small {
  padding: 5px 8px;
  border: 1px solid #e2e2e7;
  border-radius: 999px;
  color: #5b5c63;
  background: #ffffff;
  white-space: nowrap;
}

.failure-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin-top: 0;
  border-bottom: 1px solid #ececf0;
}

.failure-compare article {
  min-width: 0;
  padding: 18px 20px;
  border: 0;
  border-right: 1px solid #ececf0;
  border-radius: 0;
  background: #ffffff;
}

.failure-compare article:nth-child(2) {
  border-right: 0;
  background: #fcfcfd;
}

.failure-detail h2 {
  margin: 0 0 10px;
  color: #686970;
  font-size: 12px;
  line-height: 1;
  font-weight: 720;
}

.failure-detail p {
  margin: 0;
  color: #111113;
  font-size: 16px;
  line-height: 1.48;
  font-weight: 520;
  overflow-wrap: anywhere;
}

.failure-compare article:nth-child(2) p {
  color: #7b1d1d;
}

.failure-compare p + p {
  margin-top: 9px;
  padding-top: 9px;
  border-top: 1px solid #efeff2;
}

.srt-context {
  margin-top: 0;
  padding: 16px 18px 18px;
  background: #ffffff;
}

.srt-context ol {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid #e7e7ec;
  border-radius: 8px;
  list-style: none;
}

.srt-context li {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 7px;
  align-items: start;
  padding: 11px 14px;
  border-bottom: 1px solid #eeeeef;
  background: #ffffff;
}

.srt-context li:last-child {
  border-bottom: 0;
}

.srt-context li.is-current {
  background: #fff5f5;
  box-shadow: inset 3px 0 0 #7b1d1d;
}

.srt-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  color: #62636a;
  font-size: 12px;
  line-height: 1.3;
}

.srt-meta strong {
  color: #111113;
  min-width: 38px;
  font-size: 13px;
}

.srt-meta time {
  color: #6c6d73;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.srt-meta em {
  padding: 3px 6px;
  border-radius: 999px;
  color: #ffffff;
  background: #7b1d1d;
  font-size: 11px;
  font-style: normal;
  font-weight: 680;
  white-space: nowrap;
}

.srt-context li > p {
  padding-left: 42px;
}

.report-strip {
  width: 884px;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
  margin: 14px auto 0;
}

.report-strip div {
  min-height: 74px;
  padding: 12px 14px;
  border: 1px solid #e2e2e6;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
}

.report-strip strong {
  display: block;
  color: #101012;
  font-size: 24px;
  line-height: 1.15;
}

.report-strip span {
  display: block;
  margin-top: 5px;
  color: #6c6d74;
  font-size: 13px;
}

.outputs {
  width: 1290px;
  margin: 43px auto 0;
  padding-top: 24px;
  border-top: 1px solid #e0e0e4;
}

.outputs h2 {
  margin: 0 0 23px 26px;
  color: #42434a;
  font-size: 16px;
  line-height: 1;
  font-weight: 450;
}

.outputs ul {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  margin: 0;
  padding: 0 6px;
  list-style: none;
}

.output-item {
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 0 26px;
  border-right: 1px solid #e0e0e4;
}

.output-item:last-child {
  border-right: 0;
}

.mini-file {
  position: static;
  min-width: 42px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  flex: 0 0 auto;
}

.output-item span:not(.mini-file) {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.output-item strong {
  color: #0f0f12;
  font-size: 16px;
  line-height: 1.1;
  font-weight: 760;
  white-space: nowrap;
}

.output-item small {
  color: #64656b;
  font-size: 13px;
  line-height: 1.2;
}

.download-button {
  width: 324px;
  margin: 27px auto 0;
  display: flex;
  color: #0b0b0d;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid #cfd0d5;
  box-shadow: none;
  font-size: 20px;
  font-weight: 560;
}

.download-button:hover {
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
}

.download-button.is-disabled {
  color: #9b9ca3;
  cursor: not-allowed;
  background: #f6f6f7;
}

.lab-hero {
  margin-bottom: 32px;
}

.lab-kicker {
  margin: 0 0 12px;
  color: #6b6b72;
  font-size: 14px;
  line-height: 1;
  font-weight: 720;
}

.lab-badge {
  min-height: 34px;
  color: #44444b;
  background: #f7f7f8;
}

@media (max-width: 1180px) {
  .upload-panel,
  .status-note,
  .failure-detail,
  .report-strip {
    width: calc(100% - 64px);
  }

  .outputs {
    width: calc(100% - 64px);
  }

  .outputs ul {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    row-gap: 20px;
  }

  .output-item:nth-child(2n) {
    border-right: 0;
  }

  .hero h1 {
    font-size: 60px;
  }
}

@media (max-width: 760px) {
  .topbar {
    height: auto;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    padding: 24px;
  }

  .hero {
    margin-top: 42px;
  }

  .hero h1 {
    font-size: 42px;
    line-height: 1.12;
  }

  .hero p {
    font-size: 17px;
  }

  .upload-panel,
  .status-note,
  .failure-detail,
  .report-strip,
  .outputs {
    width: calc(100% - 32px);
  }

  .upload-panel {
    padding: 24px;
  }

  .upload-grid,
  .form-row,
  .failure-compare,
  .report-strip,
  .outputs ul {
    grid-template-columns: 1fr;
  }

  .failure-detail {
    padding: 0;
  }

  .failure-head {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .failure-compare article {
    border-right: 0;
    border-bottom: 1px solid #ececf0;
  }

  .failure-compare article:nth-child(2) {
    border-bottom: 0;
  }

  .srt-context li {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .srt-meta {
    flex-wrap: wrap;
  }

  .srt-context li > p {
    padding-left: 0;
  }

  .output-item {
    border-right: 0;
    border-bottom: 1px solid #e0e0e4;
    padding: 14px 6px;
  }

  .output-item:last-child {
    border-bottom: 0;
  }

  .download-button {
    width: calc(100% - 32px);
  }

  .asr-config-actions {
    grid-template-columns: 1fr;
  }
}

/* ── MiMo ASR Section ─────────────────────────────────────────── */

.asr-section {
  width: 884px;
  margin: 32px auto 0;
  padding: 32px 40px 36px;
  border: 1px solid #d9d9dc;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, rgba(248, 248, 250, 0.88) 100%);
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.asr-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}

.asr-header h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 760;
  line-height: 1.2;
  display: flex;
  align-items: center;
  gap: 10px;
}

.asr-icon {
  font-size: 28px;
}

.asr-badge {
  border: 0;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 720;
  color: #fff;
  background: linear-gradient(135deg, #ff6a00 0%, #ee0979 100%);
  letter-spacing: 0.02em;
}

.asr-config-trigger {
  min-height: 34px;
  cursor: pointer;
}

.asr-config-trigger:hover,
.asr-config-trigger:focus-visible {
  box-shadow: 0 10px 22px rgba(238, 9, 121, 0.22);
  outline: none;
}

.asr-desc {
  margin: 0 0 24px;
  color: #52525b;
  font-size: 15px;
  line-height: 1.5;
}

.asr-form {
  margin: 0;
}

.asr-upload-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: stretch;
}

.asr-upload-zone {
  min-height: 150px;
}

.asr-controls {
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-content: center;
}

.asr-select-label {
  display: grid;
  gap: 6px;
  font-size: 14px;
  font-weight: 560;
  color: #19191c;
}

.asr-select {
  height: 40px;
  padding: 0 12px;
  border: 1px solid #cfcfd4;
  border-radius: 6px;
  background: #fff;
  font: inherit;
  font-size: 14px;
  color: #111113;
  outline: none;
  cursor: pointer;
}

.asr-key-input {
  height: 40px;
  padding: 0 12px;
  border: 1px solid #cfcfd4;
  border-radius: 6px;
  background: #fff;
  color: #111113;
  font: inherit;
  font-size: 14px;
  outline: none;
}

.asr-key-input::placeholder {
  color: #96979d;
}

.asr-select:focus,
.asr-key-input:focus {
  border-color: #0a0a0b;
  box-shadow: 0 0 0 3px rgba(10, 10, 11, 0.08);
}

.asr-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #3f3f46;
  cursor: pointer;
}

.asr-checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #111113;
}

.asr-button {
  width: 100%;
  height: 44px;
  font-size: 18px;
}

.asr-config-status {
  min-height: 20px;
  margin: 0;
  color: #696970;
  font-size: 13px;
  line-height: 1.45;
}

.asr-config-status.is-ready {
  color: #235b28;
}

.asr-config-status.is-missing {
  color: #7b1d1d;
}

.asr-config-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(10, 10, 12, 0.28);
}

.asr-config-modal[hidden] {
  display: none;
}

.asr-config-dialog {
  width: min(520px, 100%);
  padding: 24px;
  border: 1px solid #d8d8dd;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.18);
}

.asr-config-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
}

.asr-config-head h2 {
  margin: 0;
  color: #111113;
  font-size: 22px;
  line-height: 1.2;
}

.asr-config-close {
  width: 34px;
  height: 34px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #686970;
  background: transparent;
  font-size: 24px;
  line-height: 1;
}

.asr-config-close:hover,
.asr-config-close:focus-visible {
  border-color: #d4d4d8;
  color: #111113;
  background: #f8f8f9;
  outline: none;
}

.asr-config-copy {
  margin: 0 0 18px;
  color: #5a5b62;
  font-size: 14px;
  line-height: 1.55;
}

.asr-config-message {
  min-height: 20px;
  margin: 10px 0 0;
  color: #686970;
  font-size: 13px;
  line-height: 1.45;
}

.asr-config-message.is-error {
  color: #7b1d1d;
}

.asr-config-message.is-ok {
  color: #235b28;
}

.asr-config-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 18px;
}

.asr-secondary-button,
.asr-test-button {
  width: 100%;
  height: 42px;
  font-size: 16px;
}

.asr-secondary-button {
  border: 1px solid #d4d4d8;
  border-radius: 6px;
  color: #2f3035;
  background: #ffffff;
}

.asr-secondary-button:hover,
.asr-secondary-button:focus-visible {
  border-color: #111113;
  outline: none;
}

/* ── ASR Result ────────────────────────────────────────────────── */

.asr-result {
  margin-top: 24px;
  border: 1px solid #d9d9dc;
  border-radius: 8px;
  overflow: hidden;
}

.asr-result-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  background: linear-gradient(180deg, #f8f8f9 0%, #f3f3f4 100%);
  border-bottom: 1px solid #e5e5e7;
  font-size: 14px;
  color: #27272b;
}

.asr-result-meta span {
  font-weight: 720;
}

.asr-result-meta small {
  color: #71717a;
}

.asr-result-text {
  padding: 16px 20px;
  background: #fff;
}

.asr-result-text pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: inherit;
  font-size: 15px;
  line-height: 1.7;
  color: #18181b;
}

.asr-result-srt {
  padding: 12px 16px 16px;
  border-top: 1px solid #e5e5e7;
  background: #fafafa;
}

.asr-result-srt details {
  margin: 0;
}

.asr-result-srt summary {
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: #3f3f46;
  padding: 4px 0;
}

.asr-result-srt summary:hover {
  color: #18181b;
}

.asr-result-srt pre {
  margin: 8px 0 0;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: "SF Mono", "Fira Code", "Consolas", monospace;
  font-size: 13px;
  line-height: 1.6;
  color: #27272b;
  max-height: 400px;
  overflow-y: auto;
  padding: 12px;
  background: #fff;
  border: 1px solid #e5e5e7;
  border-radius: 6px;
}

.asr-note {
  margin: 10px 0 0;
  font-size: 13px;
  color: #a1a1aa;
  line-height: 1.5;
}

.asr-result.asr-error {
  border-color: #f1c4c4;
  padding: 16px 20px;
  background: #fff3f3;
  color: #7b1d1d;
}

.asr-result.asr-error strong {
  display: block;
  margin-bottom: 6px;
  font-size: 16px;
}

.asr-result.asr-error span {
  display: block;
  font-size: 14px;
  line-height: 1.5;
}

.asr-result.asr-error small {
  display: block;
  margin-top: 4px;
  opacity: 0.7;
  font-size: 13px;
}

.asr-config-note {
  margin-bottom: 20px;
}

/* ── Align Section ─────────────────────────────────────────────── */

.align-section {
  margin-top: 36px;
}

.align-title {
  max-width: 980px;
  margin: 0 auto 20px;
  padding: 0 24px;
  font-size: 24px;
  font-weight: 760;
  line-height: 1.2;
}

/* ── ASR Responsive ────────────────────────────────────────────── */

@media (max-width: 920px) {
  .asr-section {
    width: calc(100% - 32px);
    padding: 24px 20px 28px;
  }

  .asr-upload-row {
    grid-template-columns: 1fr;
  }

  .asr-header h2 {
    font-size: 20px;
  }
}

/* CODEX_LEGAL_RAIL_START */
.legacy-legal-rail {
  margin: 32px 0 0;
  border-top: 1px solid rgba(51, 65, 85, 0.1);
  background: linear-gradient(180deg, rgba(248, 250, 252, 0.34), rgba(255, 255, 255, 0.88));
  color: #64748b;
}

.legacy-legal-rail__inner {
  width: min(calc(100% - 40px), 1080px);
  min-height: 52px;
  margin: 0 auto;
  padding: 10px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 28px;
  font-size: 12px;
  line-height: 1.55;
}

.legacy-legal-rail__identity,
.legacy-legal-rail__actions {
  margin: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.legacy-legal-rail__identity {
  gap: 5px;
  white-space: nowrap;
}

.legacy-legal-rail__identity strong {
  color: #334155;
  font-weight: 650;
}

.legacy-legal-rail__actions {
  justify-content: flex-end;
  gap: 6px 18px;
}

.legacy-legal-rail a {
  color: #64748b;
  text-decoration: none;
  transition: color 160ms ease;
}

.legacy-legal-rail a:hover {
  color: #0f766e;
}

.legacy-legal-rail a:focus-visible {
  border-radius: 4px;
  outline: 2px solid rgba(13, 148, 136, 0.48);
  outline-offset: 3px;
}

.legacy-legal-rail__record {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #475569 !important;
  white-space: nowrap;
}

.legacy-legal-rail__dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #14b8a6;
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.1);
}

@media (max-width: 760px) {
  .legacy-legal-rail {
    margin-top: 24px;
  }

  .legacy-legal-rail__inner {
    width: min(calc(100% - 32px), 1080px);
    min-height: 0;
    padding: 14px 0 16px;
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
  }

  .legacy-legal-rail__identity {
    white-space: normal;
  }

  .legacy-legal-rail__actions {
    justify-content: flex-start;
    gap: 5px 14px;
  }
}
/* CODEX_LEGAL_RAIL_END */
