:root {
  color-scheme: light;
  font-family: Arial, Helvetica, sans-serif;
  color: #4a3328;
  background: #fff;
  --serif: Georgia, "Times New Roman", serif;
  --sidebar: #f5f0eb;
  --line: #e0d8d0;
  --muted: #7d6d61;
  --accent: #285b8f;
  --accent-hover: #204b76;
  --accent-line: #c5d5e6;
  --accent-soft: #e8eef5;
  --paper: #fff;
  --inset: #f5f7fa;
  --danger: #854c30;
  --shadow: 0 5px 25px #573b2410;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 300px; }
button, input { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .65; cursor: wait; }
button:focus-visible, input:focus-visible, .file-drop:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.shell { display: grid; grid-template-columns: 15.75rem minmax(0, 1fr); min-height: 100dvh; }
.sidebar {
  background: var(--sidebar);
  border-right: 1px solid var(--line);
  padding: 2.05rem 1.35rem;
  display: flex;
  flex-direction: column;
  min-width: 0;
  height: 100dvh;
  position: sticky;
  top: 0;
}
.brand { display: flex; align-items: center; gap: .75rem; font-size: 1.05rem; line-height: 1.28; margin-bottom: 3.25rem; }
.mark, .empty-mark { display: flex; gap: .15rem; align-items: center; justify-content: center; flex: none; }
.mark { width: 3rem; height: 3.45rem; color: var(--accent); background: var(--accent-soft); border-radius: .65rem; }
.mark i, .empty-mark i { display: block; width: .14rem; background: currentColor; border-radius: .2rem; height: 34%; }
.mark i:nth-child(2), .mark i:nth-child(4), .empty-mark i:nth-child(3), .empty-mark i:nth-child(5) { height: 49%; }
.mark i:nth-child(3), .empty-mark i:nth-child(4) { height: 63%; }
.empty-mark i:first-child, .empty-mark i:last-child { height: 20%; }
.primary, .secondary, .danger-button {
  min-height: 2.65rem;
  border-radius: .38rem;
  padding: .58rem .85rem;
  font-size: .9rem;
  font-weight: 600;
  border: 1px solid transparent;
}
.primary { color: white; background: var(--accent); }
.primary:hover { background: var(--accent-hover); }
.primary span { font-size: 1.15em; margin-right: .2em; }
.secondary { color: var(--accent); border-color: var(--accent-line); background: var(--paper); }
.secondary:hover { background: var(--inset); }
.danger-button { color: white; background: var(--danger); }
.danger-button:hover { background: #6d3d26; }
.import-button { width: 100%; text-align: left; padding-left: .95rem; }
.search { display: block; margin: .9rem 0 1.15rem; }
input:not([type="file"]) {
  width: 100%;
  font-size: 1rem;
  border: 1px solid var(--line);
  border-radius: .4rem;
  min-height: 2.6rem;
  padding: .5rem .75rem;
  background: var(--inset);
  color: inherit;
}
.search input { font-size: .9rem; background: transparent; border-color: transparent; padding-inline: .25rem; }
.search input:hover { border-color: var(--line); }
input::placeholder { color: var(--muted); opacity: 1; }
.library-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.library-heading h2 { font-size: .82rem; letter-spacing: .13em; text-transform: uppercase; }
.library-heading span { font-size: .8rem; font-weight: 700; background: var(--line); border-radius: .22rem; min-width: 1.3rem; padding: .12rem .25rem; text-align: center; }
#library { overflow-y: auto; }
.meeting-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  border: 1px solid transparent;
  border-radius: .4rem;
  margin-bottom: .25rem;
}
.meeting-row:hover { background: #ffffffcc; }
.meeting-row.selected { background: var(--paper); border-color: var(--accent-line); box-shadow: var(--shadow); }
.meeting { background: transparent; color: inherit; border: 0; border-radius: .4rem; text-align: left; padding: .75rem; }
.meeting-delete {
  width: 2rem;
  height: 2rem;
  margin-right: .3rem;
  border: 0;
  border-radius: .35rem;
  background: transparent;
  color: var(--muted);
  font-size: 1.25rem;
  line-height: 1;
}
.meeting-delete:hover, .meeting-delete:focus-visible { background: #faf1e9; color: var(--danger); }
.meeting-title { display: block; font-weight: 700; font-size: .95rem; overflow-wrap: anywhere; }
.meeting-meta, .library-empty, .storage { color: var(--muted); font-size: .82rem; }
.meeting-meta { display: block; margin-top: .18rem; }
.library-empty { margin: .25rem .4rem 1rem; }
.storage { margin-top: auto; border-top: 1px solid var(--line); padding: 1rem 0 0; }
.storage span { display: inline-block; width: .45rem; height: .45rem; background: var(--muted); border-radius: 50%; margin-right: .32rem; vertical-align: .08rem; }
main { min-width: 0; }
#panel { max-width: 75rem; margin: auto; padding: clamp(1.4rem, 4vw, 3.75rem); }
.empty { min-height: max(24rem, calc(85dvh - 5rem)); display: grid; place-content: center; justify-items: center; text-align: center; }
.empty-mark { width: 5rem; height: 5rem; color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: .75rem; margin-bottom: 1.45rem; gap: .25rem; }
.empty-mark i { width: .2rem; }
h1, h2, p { margin: 0; }
h1, .processing h2, .dialog-header h2 { font-family: var(--serif); font-weight: 400; }
h1 { font-size: clamp(2rem, 3.2vw, 3rem); line-height: 1.13; letter-spacing: -.035em; overflow-wrap: anywhere; }
.empty p { max-width: 25rem; margin: .9rem 0 1.55rem; color: var(--muted); line-height: 1.55; }
.meeting-header { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.15rem; margin: 0 0 1.65rem; padding: .75rem 0 1.4rem; border-bottom: 1px solid var(--line); }
.metadata { margin-top: .6rem; color: var(--muted); font-size: .9rem; }
.transcript-actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.transcript, .processing { background: var(--paper); border: 1px solid var(--line); border-radius: .75rem; box-shadow: var(--shadow); }
.turn { display: grid; grid-template-columns: 4.75rem minmax(0, 1fr); gap: .65rem; padding: 1.1rem 1.35rem; }
.turn + .turn { border-top: 1px solid var(--line); }
.timestamp { font-family: ui-monospace, monospace; font-size: .85rem; color: var(--muted); padding-top: .15rem; }
.speaker { color: var(--accent); font-size: .9rem; margin-bottom: .25rem; overflow-wrap: anywhere; }
.speaker[data-tone="2"] { color: inherit; }
.speaker[data-tone="3"] { color: var(--danger); }
.speaker[data-tone="0"] { color: var(--muted); }
.turn p { line-height: 1.65; overflow-wrap: anywhere; }
.processing { padding: 1.5rem; }
.processing h2, .dialog-header h2 { font-size: 1.55rem; letter-spacing: -.025em; }
.processing p { color: var(--muted); margin: .75rem 0; line-height: 1.5; }
progress { margin-top: 1rem; width: min(30rem, 100%); accent-color: var(--accent); }
dialog { width: min(32rem, calc(100% - 2rem)); color: inherit; background: var(--paper); border: 1px solid var(--line); border-radius: .75rem; padding: 1.5rem; box-shadow: 0 1.5rem 5rem #4a332833; }
dialog::backdrop { background: #4a332866; }
.dialog-header, .dialog-actions { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.dialog-header { margin-bottom: 1rem; }
.dialog-actions { justify-content: flex-end; margin-top: 1.3rem; }
.close { background: none; color: var(--muted); border: 0; border-radius: .3rem; width: 2rem; height: 2rem; font-size: 1.5rem; line-height: 1; }
.file-drop { display: grid; gap: .4rem; position: relative; text-align: center; cursor: pointer; padding: 1.3rem .8rem; background: var(--inset); border: 1px dashed var(--accent-line); border-radius: .4rem; color: var(--accent); font-weight: 700; overflow-wrap: anywhere; }
.file-drop.dragging, .file-drop:hover { background: var(--accent-soft); }
.file-drop input { position: absolute; inset: 0; width: 100%; opacity: 0; cursor: pointer; }
.file-drop small { color: var(--muted); font-weight: 500; }
.field { display: block; margin-top: .85rem; color: inherit; font-weight: 700; font-size: .9rem; }
.field span { color: var(--muted); font-weight: 500; }
.field input { display: block; margin-top: .35rem; font-weight: 500; }
.delete-message { color: var(--muted); line-height: 1.6; overflow-wrap: anywhere; }
.drive-link { display: inline-flex; align-items: center; text-decoration: none; }
.form-error { color: var(--danger); margin-top: .8rem; }
.visually-hidden { position: absolute; overflow: hidden; clip-path: inset(50%); white-space: nowrap; width: 1px; height: 1px; }
@media (max-width: 680px) {
  .shell { display: block; }
  .sidebar { position: static; height: auto; padding: 1rem; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand { margin-bottom: 1rem; }
  .mark { width: 2.4rem; height: 2.5rem; }
  .search { margin: .8rem 0; }
  #library { max-height: 9rem; }
  .storage { margin-top: .5rem; padding: .5rem 0 0; }
  .empty { min-height: 20rem; }
  .turn { grid-template-columns: 3rem minmax(0, 1fr); padding: .9rem .7rem; gap: .5rem; }
}
