:root {
  color-scheme: light;
  --ink: #1b2b43;
  --muted: #596a80;
  --blue: #205dce;
  --line: #dce3ed;
  --panel: #fff;
  --canvas: #f5f7fb;
  --subtle: #edf3ff;
  --sidebar-width: 206px;
  font: 14px/1.6 Inter, -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  color: var(--ink);
  background: var(--canvas);
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { color: inherit; font: inherit; }
button, a { touch-action: manipulation; }
button { border: 0; background: none; cursor: pointer; }
button:disabled, fieldset:disabled button { opacity: .48; cursor: default; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
main:focus { outline: none; }
svg { width: 20px; height: 20px; flex: none; display: block; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(27px, 2.5vw, 36px); letter-spacing: -.035em; line-height: 1.3; font-weight: 680; }
h2 { font-size: 18px; letter-spacing: -.025em; line-height: 1.45; font-weight: 640; }
h3 { font-size: 15px; font-weight: 620; }
small, .muted { color: var(--muted); }
input, select, textarea {
  width: 100%; min-width: 0; min-height: 43px; padding: 9px 12px;
  border: 1px solid #bdcadb; border-radius: 8px; background: var(--panel);
}
input::placeholder, textarea::placeholder { color: #68798b; }
textarea { resize: vertical; min-height: 96px; }
fieldset { margin: 0; padding: 0; min-width: 0; border: 0; }
[hidden], .error:empty, #toast:empty { display: none !important; }
.skip {
  position: fixed; top: 8px; left: 8px; z-index: 20; transform: translateY(-160%);
  background: white; border: 1px solid var(--blue); border-radius: 6px; padding: 8px 14px;
}
.skip:focus { transform: none; }
.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 5; width: var(--sidebar-width);
  padding: 25px 14px; background: #fcfdff; border-right: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 8px; padding-left: 8px; color: #14253f; font-size: 26px; letter-spacing: -1.2px; font-weight: 750; }
.brand img { width: 33px; height: 33px; }
.brand span { font-size: 12px; font-weight: 500; letter-spacing: 0; color: var(--muted); }
#navigation { margin-top: 43px; display: grid; gap: 25px; }
.nav-group { display: grid; gap: 3px; }
.nav-label { color: var(--muted); font-size: 12px; margin: 0 12px 5px; }
nav a { display: flex; align-items: center; gap: 11px; padding: 10px 13px; border-radius: 8px; color: #475b74; font-weight: 520; }
nav a:hover { background: #f0f3f9; }
nav a.active { color: #174fae; background: #e6eeff; font-weight: 650; }
nav a svg { width: 18px; height: 18px; }
.shell { min-width: 0; margin-left: var(--sidebar-width); }
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px;
  padding-inline: clamp(20px, 3.4vw, 60px); border-bottom: 1px solid var(--line); background: var(--panel);
}
.breadcrumb, .topbar-meta, .today, .connection, .mobile-brand { display: flex; align-items: center; }
.breadcrumb { gap: 13px; font-size: 13px; color: var(--muted); }
.breadcrumb strong { color: #394b62; font-weight: 550; }
.crumb-slash { color: #9aa8ba; }
.topbar-meta { gap: 18px; font-size: 12px; color: var(--muted); }
.today, .connection { gap: 7px; }
.today svg { width: 15px; height: 15px; }
.connection { border-left: 1px solid var(--line); padding-left: 18px; white-space: nowrap; }
.connection i, .live-dot { width: 7px; height: 7px; background: #8594a7; border-radius: 50%; flex: none; }
.connection .online { background: #218069; }
.connection .offline, .live-dot { background: #d44849; }
.mobile-brand { display: none; }
main { max-width: 1440px; margin: auto; padding: 34px clamp(20px, 3.4vw, 60px) 48px; }
.page-head, .detail-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 23px; }
.page-head > div, .detail-head > div { min-width: 0; }
.page-head h1, .detail-head h1 { overflow-wrap: anywhere; }
.page-head p { margin-top: 6px; color: var(--muted); }
.page-head > .btn { flex: none; }
.card { min-width: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 2px 5px #1a335504; }
.pad { padding: 22px 24px; }
.section-head, .section-head h2, .section-label, .actions, .meta, .row-title { display: flex; align-items: center; }
.section-head { justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.section-head h2, .section-label { gap: 8px; }
.section-head h2 svg { width: 18px; height: 18px; color: var(--blue); }
.card-head { padding: 16px 21px; border-bottom: 1px solid var(--line); margin: 0; }
.btn, .icon-btn, .text-btn {
  display: inline-flex; justify-content: center; align-items: center; gap: 7px; font-weight: 540; line-height: 1.35;
}
.btn { min-height: 40px; padding: 9px 14px; border: 1px solid #c7d2df; border-radius: 8px; background: var(--panel); }
.btn:enabled:hover, a.btn:hover { border-color: #93b0da; background: #f3f7ff; color: #164c9e; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: white; }
.btn.primary:enabled:hover { background: #174eaf; border-color: #174eaf; color: white; }
.btn.danger { color: #ae3439; border-color: #e5c4c6; }
.btn.danger:enabled:hover { background: #fff2f2; color: #992b31; border-color: #d18a8d; }
.btn svg, .icon-btn svg, .text-btn svg { width: 16px; height: 16px; }
.text-btn { color: var(--blue); padding: 5px 0; font-size: 13px; }
.text-btn:hover { text-decoration: underline; }
.icon-btn { height: 36px; width: 36px; border-radius: 7px; color: var(--muted); }
.icon-btn:hover { color: var(--ink); background: var(--canvas); }
.actions { gap: 8px; flex-wrap: wrap; }
.home-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.setup-card { overflow: hidden; }
.setup-head { display: flex; align-items: center; gap: 13px; padding: 22px 24px; color: #173a74; background: #edf3ff; border-bottom: 1px solid #dbe6fb; }
.setup-head p { font-size: 12px; color: #465f85; }
.setup-mic, .tile, .speaker-avatar, .empty-icon { display: grid; place-items: center; flex: none; border-radius: 9px; }
.setup-mic { width: 43px; height: 43px; color: white; background: var(--blue); }
#meeting-form { padding: 22px 24px; }
.form-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 18px 14px; }
.full { grid-column: 1 / -1; }
.field, .field-group { display: flex; flex-direction: column; gap: 6px; min-width: 0; font-size: 13px; font-weight: 550; }
.field input, .field select, .field textarea, .field small { font-weight: 400; }
.optional { margin-left: 4px; color: var(--muted); font-size: 12px; font-weight: 400; }
.count-stepper { display: flex; align-items: center; border: 1px solid #bdcadb; border-radius: 8px; overflow: hidden; }
.count-stepper button { min-width: 32px; align-self: stretch; font-size: 18px; color: #3d5271; }
.count-stepper button:enabled:hover { background: var(--subtle); }
.count-stepper input { min-height: 41px; text-align: center; border: 0; padding: 0; appearance: textfield; -moz-appearance: textfield; }
.count-stepper input::-webkit-inner-spin-button { appearance: none; }
.count-stepper :focus-visible { outline-offset: -3px; }
.template-preview { display: flex; align-items: center; gap: 8px; background: #f5f7fb; border-radius: 7px; padding: 7px 10px; }
.template-preview > svg { color: var(--muted); width: 16px; height: 16px; }
.template-preview > span { min-width: 0; flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--muted); font-size: 12px; }
.template-preview button { flex: none; }
.form-foot { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-top: 22px; padding-top: 17px; border-top: 1px solid var(--line); }
.form-foot small { max-width: 240px; font-size: 12px; }
.form-foot .btn { min-height: 43px; flex: none; padding-inline: 18px; }
#meeting-error:not(:empty) { margin-top: 12px; }
.list { padding-inline: 20px; }
.row { display: flex; width: 100%; gap: 12px; align-items: center; min-width: 0; padding: 13px 0; text-align: start; border-bottom: 1px solid #e8edf4; }
.row:last-child { border-bottom: 0; }
a.row:hover .row-title strong { color: var(--blue); text-decoration: underline; }
.row > svg:last-child { color: #74859a; width: 14px; height: 14px; }
.row-main { flex: 1; min-width: 0; }
.row-title { flex-wrap: wrap; gap: 3px 8px; }
.row-title strong { font-weight: 590; overflow-wrap: anywhere; }
.recent-card .row-title strong { text-overflow: ellipsis; white-space: nowrap; overflow: hidden; min-width: 0; }
.meta { gap: 3px 12px; font-size: 12px; flex-wrap: wrap; color: var(--muted); margin-top: 4px; }
.meta span { display: inline-flex; align-items: center; gap: 4px; }
.meta svg { width: 13px; height: 13px; }
.tile, .speaker-avatar { width: 35px; height: 35px; color: #315f9c; background: #edf3fb; }
.tile svg { width: 17px; height: 17px; }
.tile.violet { color: #725b9f; background: #f3effa; }
.speaker-avatar { font-weight: 650; }
.chip { display: inline-flex; align-items: center; flex: none; color: #2459a0; background: #edf3ff; border-radius: 5px; font-size: 11px; font-weight: 500; padding: 2px 6px; white-space: nowrap; }
.chip.green { color: #23654d; background: #e7f4ed; }
.chip.gray { color: #566779; background: #eef1f5; }
.chip.red { color: #a63539; background: #ffeeef; }
.empty { text-align: center; padding: 34px 12px; color: var(--muted); }
.empty-icon { width: 38px; height: 38px; margin: 0 auto 10px; color: #637d9b; background: #edf2f9; }
.empty p { color: #41556e; font-weight: 550; }
.empty small { display: block; margin-top: 4px; font-size: 12px; }
.summary-content { overflow-wrap: anywhere; line-height: 1.85; }
.summary-content p { margin: .45em 0; }
.summary-content h3 { margin: 1em 0 .3em; font-size: 16px; }
.summary-content ul { margin: .25em 0 .7em; padding-left: 1.5em; }
.summary-content > :first-child { margin-top: 0; }
.table-wrap { overflow-x: auto; }
.summary-content table { width: 100%; border-collapse: collapse; font-size: 13px; }
.summary-content th, .summary-content td { border: 1px solid var(--line); padding: 6px 9px; text-align: start; }
.summary-content th { background: #f4f7fb; }
.utterance { display: grid; grid-template-columns: 65px minmax(0, 1fr); gap: 12px; padding: 11px 0; border-bottom: 1px solid #e8edf4; }
.utterance:last-child { border: 0; }
.utterance time, .clock { font-family: ui-monospace, monospace; font-variant-numeric: tabular-nums; }
.utterance time { padding-top: 2px; font-size: 12px; color: var(--muted); }
.utterance b { font-size: 13px; color: #285b99; }
.utterance p { margin-top: 2px; overflow-wrap: anywhere; }
.utterance.partial { color: #5b6c80; }
.utterance .clip-time { align-self: start; font-size: 12px; }
.utterance .clip-time svg { width: 11px; }
.utterance .review-note { display: block; color: #825318; }
.utterance [data-review] { font-size: 12px; margin-top: 4px; }
.banner { padding: 10px 13px; margin: 10px 0; color: #78500f; background: #fff7e9; border: 1px solid #eed8b1; border-radius: 8px; font-size: 13px; overflow-wrap: anywhere; }
.detail-head { align-items: flex-start; margin: 10px 0 20px; }
audio { width: 100%; max-width: 100%; height: 40px; }
.loading { padding: 35px; text-align: center; color: var(--muted); }
.load-error .actions { margin-top: 14px; }
dialog { width: min(520px, calc(100vw - 24px)); max-height: min(88dvh, 760px); padding: 0; border: 1px solid var(--line); border-radius: 14px; color: inherit; box-shadow: 0 20px 70px #18315438; overflow: hidden; }
dialog[open] { display: flex; flex-direction: column; }
dialog::backdrop { background: #15243968; }
.modal-head, .modal-foot { flex: none; display: flex; align-items: center; gap: 10px; padding: 14px 20px; background: var(--panel); }
.modal-head { justify-content: space-between; border-bottom: 1px solid var(--line); }
.modal-head h2 { min-width: 0; overflow-wrap: anywhere; }
.modal-foot { justify-content: flex-end; border-top: 1px solid var(--line); }
.modal-body { min-height: 0; overflow-y: auto; padding: 18px 20px; display: grid; gap: 15px; overscroll-behavior: contain; overflow-wrap: anywhere; }
.hint { font-size: 13px; color: var(--muted); }
.error { font-size: 13px; color: #ad3034; overflow-wrap: anywhere; }
.reader { height: 130px; overflow: auto; padding: 12px 15px; border: 1px solid #d4e1f6; border-radius: 8px; background: #f4f8ff; color: #254c85; font-size: 16px; line-height: 1.8; }
.reader-line { margin-bottom: 5px; }
.recorder-status { display: flex; align-items: center; justify-content: space-between; }
.progress { height: 6px; width: 100%; accent-color: var(--blue); }
#toast { position: fixed; z-index: 12; left: calc(50% + var(--sidebar-width) / 2); transform: translateX(-50%); bottom: 22px; width: max-content; max-width: min(90vw, 600px); padding: 10px 16px; color: #fff; background: #263952; border-radius: 8px; box-shadow: 0 4px 15px #14253b22; font-size: 13px; pointer-events: none; overflow-wrap: anywhere; }
@media (min-width: 781px) and (max-width: 1100px) {
  :root { --sidebar-width: 172px; }
  .brand span { font-size: 11px; }
  .sidebar { padding-inline: 10px; }
  main, .topbar { padding-inline: 22px; }
  .home-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 14px; }
  #meeting-form, .setup-head { padding-inline: 18px; }
}
@media (max-width: 950px) {
  .home-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
}
@media (max-width: 780px) {
  :root { --sidebar-width: 0px; }
  .sidebar { inset: auto 0 0; width: 100%; padding: 4px 8px calc(4px + env(safe-area-inset-bottom)); border: 0; border-top: 1px solid var(--line); background: #fff; }
  .sidebar .brand, .nav-label, .desktop-crumb { display: none; }
  #navigation { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; gap: 3px; }
  .nav-group { display: contents; }
  nav a { flex-direction: column; gap: 2px; justify-content: center; min-height: 47px; padding: 3px; font-size: 11px; }
  .topbar { min-height: 48px; padding-inline: 16px; }
  .mobile-brand { display: inline-flex; gap: 5px; font-size: 19px; font-weight: 720; letter-spacing: -.8px; color: var(--ink); }
  .mobile-brand img { width: 23px; height: 23px; }
  .breadcrumb { gap: 8px; }
  main { padding: 22px 16px calc(80px + env(safe-area-inset-bottom)); }
  .page-head { margin-bottom: 18px; }
  #toast { bottom: calc(69px + env(safe-area-inset-bottom)); }
}
@media (max-width: 580px) {
  .today { display: none; }
  .connection { border: 0; padding: 0; }
  .page-head p { font-size: 13px; }
  .page-head { flex-wrap: wrap; gap: 10px; }
  .pad, #meeting-form, .setup-head { padding: 16px; }
  .card-head { padding: 14px 16px; }
  .list { padding-inline: 15px; }
  .row { gap: 8px; }
  .row-title { gap: 3px 6px; }
  .meta { gap: 2px 8px; }
  .form-grid { gap: 14px 10px; }
  .form-foot { margin-top: 16px; padding-top: 14px; }
  .modal-head, .modal-foot, .modal-body { padding-inline: 15px; }
  .modal-body { padding-block: 15px; }
  input, select, textarea { font-size: 16px; }
  .btn, .icon-btn { min-height: 43px; }
  .utterance { grid-template-columns: 58px minmax(0, 1fr); gap: 6px; }
}
@media (max-width: 360px) {
  .form-grid { grid-template-columns: minmax(0, 1fr); }
  .form-foot { flex-wrap: wrap; gap: 10px; }
}
