:root {
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: #193e48;
  background: #f3f8f9;
  font-synthesis: none;
  --muted: #657d86;
  --brand: #147d78;
  --line: #dce8ea;
}
.microphone-controls { padding:12px; border:1px solid var(--line); border-radius:12px; margin:10px 0; }
.microphone-controls label { display:flex; align-items:center; flex-wrap:wrap; gap:10px; font-size:13px; }
.microphone-controls input[type=range] { width:140px; }
.microphone-controls small { display:block; margin-top:8px; color:var(--muted); }
.microphone-check { width:min(480px,90vw); padding:24px; border:1px solid var(--line); border-radius:18px; color:var(--ink,#193e48); }
.microphone-check::backdrop { background:#123b4680; }
.microphone-check meter,.microphone-check audio { display:block; width:100%; margin:14px 0; }
.microphone-check audio[hidden] { display:none; }
.welcome-popup { position:fixed; z-index:90; top:20px; left:50%; transform:translateX(-50%); display:flex; align-items:center; gap:12px; width:max-content; max-width:calc(100vw - 24px); padding:16px; border:1px solid #b7d6d2; border-radius:20px; background:#f0faf5; color:#193e48; box-shadow:0 12px 38px #123b4626; }
.welcome-popup strong,.welcome-popup span { display:block; }
.welcome-popup strong { font-size:20px; }
.welcome-popup span { font-size:12px; margin-top:4px; }
.welcome-popup button { padding:5px 10px; }
.staff-test-reminder { width:min(460px,calc(100vw - 32px)); padding:28px; border:1px solid #b7d6d2; border-radius:22px; background:#fff; color:#193e48; box-shadow:0 24px 70px #123b4640; }
.staff-test-reminder::backdrop { background:#102f3c99; }
.staff-test-reminder h2 { margin:12px 0; font-size:24px; }
.staff-test-reminder .actions { display:flex; gap:10px; flex-wrap:wrap; margin-top:20px; }
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px max(24px, calc((100vw - 1120px) / 2));
  background: #fff;
  border-bottom: 1px solid var(--line);
  gap: 20px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--brand);
  font-size: 28px;
  font-weight: 800;
  text-decoration: none;
}
.brand span {
  font-size: 17px;
  color: #193e48;
}
#identity {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 14px;
}
main {
  max-width: 1120px;
  margin: 40px auto;
  padding: 0 24px 60px;
}
h1 {
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -1.3px;
  margin: 8px 0 12px;
}
h2 {
  font-size: 23px;
  margin: 0 0 18px;
}
h3 {
  font-size: 17px;
  margin: 0 0 10px;
}
p {
  line-height: 1.6;
}
small,
.muted {
  color: var(--muted);
  line-height: 1.5;
}
.eyebrow {
  color: var(--brand);
  font-size: 12px;
  letter-spacing: 2px;
  font-weight: 800;
  text-transform: uppercase;
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 26px;
  margin-bottom: 22px;
  box-shadow: 0 8px 35px #18485006;
}
.auth {
  max-width: 470px;
  margin: 60px auto;
}
.auth h1 {
  font-size: 32px;
}
.grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px;
}
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 18px;
}
button,
.button {
  font: inherit;
  font-size: 14px;
  font-weight: 650;
  border: 0;
  border-radius: 11px;
  padding: 12px 17px;
  background: #e8f2f2;
  color: #175e5b;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}
button:hover,
.button:hover {
  filter: brightness(0.96);
}
button:disabled {
  opacity: 0.5;
  cursor: default;
}
.primary {
  background: var(--brand);
  color: #fff;
}
.danger {
  background: #ffedeb;
  color: #a23636;
}
label {
  display: block;
  font-size: 14px;
  font-weight: 650;
  margin: 16px 0 7px;
}
input,
select,
textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #cbdcdf;
  border-radius: 10px;
  font: inherit;
  background: #fff;
  color: inherit;
}
input:focus,
select:focus,
textarea:focus {
  outline: 2px solid #72bfb7;
  outline-offset: 2px;
}
textarea {
  min-height: 150px;
  resize: vertical;
  line-height: 1.55;
}
input[type="checkbox"] {
  width: auto;
}
.check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
}
.check input {
  margin-top: 4px;
}
.upload {
  border: 1px dashed #8dbdb9;
  border-radius: 14px;
  padding: 20px;
  background: #f5faf9;
}
.upload label {
  margin-top: 0;
}
audio {
  width: 100%;
  margin: 15px 0;
}
.recording {
  background: #fff0ec;
  color: #9c3726;
  padding: 12px;
  border-radius: 10px;
}
.list {
  display: grid;
  gap: 10px;
}
.record {
  width: 100%;
  text-align: left;
  background: #fff;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 13px;
  color: #193e48;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}
.record-bad {
  border: 2px solid #c83d47;
  background: #fff4f4;
  flex-wrap: wrap;
}
.record-quality-reason {
  flex-basis: 100%;
  color: #9a2530;
  font-size: 13px;
  font-weight: 650;
}
.badge-bad {
  background: #f8dfe1 !important;
  color: #9a2530 !important;
}
.record-warning { border-color: #e5b967; background: #fffaf0; flex-wrap: wrap; }
.record-warning-reason { flex-basis: 100%; color: #77561a; font-size: 13px; font-weight: 600; }
.badge-warning { background: #fff0ce !important; color: #77561a !important; }
.record strong {
  display: block;
  margin-bottom: 5px;
  overflow-wrap: anywhere;
}
.record small {
  font-weight: 400;
}
.badge {
  font-size: 12px;
  border-radius: 20px;
  padding: 6px 10px;
  background: #eaf4f2;
  color: #226e5e;
  white-space: nowrap;
}
.empty {
  text-align: center;
  padding: 35px;
  color: var(--muted);
}
details {
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 15px;
  margin: 15px 0;
}
summary {
  cursor: pointer;
  font-weight: 650;
}
.turn {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 15px;
  border-bottom: 1px solid #edf2f3;
  padding: 14px 0;
  line-height: 1.5;
}
.turn p {
  margin: 0;
  white-space: pre-wrap;
}
.transcript {
  max-height: 440px;
  overflow: auto;
  margin-top: 12px;
}
.audit-item {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.audit-points {
  display: inline-block;
  margin: 8px 0 4px;
  padding: 5px 10px;
  border-radius: 999px;
  background: #e8f4ef;
  color: #216956;
  font-size: 13px;
  font-weight: 700;
}
blockquote {
  margin: 10px 0;
  padding: 10px 15px;
  background: #f3f8f7;
  border-left: 3px solid #82bcb0;
  font-size: 14px;
  line-height: 1.5;
}
blockquote button {
  padding: 4px 8px;
  margin-top: 8px;
}
.met {
  color: #197154;
}
.not_observed {
  color: #a75b1e;
}
.unclear {
  color: #84622e;
}
.note {
  padding: 14px 16px;
  border-radius: 12px;
  background: #fff7e7;
  color: #805d27;
  font-size: 14px;
  line-height: 1.55;
}
.stats {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin: 22px 0;
}
.stat {
  flex: 1;
  min-width: 130px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: white;
  padding: 18px;
}
.stat strong {
  display: block;
  font-size: 28px;
  margin-top: 5px;
}
.back {
  margin-bottom: 22px;
}
.invite-link {
  font-size: 13px;
  margin: 16px 0;
  overflow-wrap: anywhere;
}
#notice {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  background: #193e48;
  color: #fff;
  box-shadow: 0 8px 35px #0002;
  border-radius: 12px;
  padding: 14px 22px;
  max-width: 90%;
  z-index: 20;
}
#notice:empty {
  display: none;
}
.progress {
  color: var(--brand);
  padding: 12px 0;
  font-weight: 600;
}
.subhead {
  margin-bottom: 25px;
}
.tabbar {
  display: flex;
  gap: 8px;
  margin-bottom: 25px;
  flex-wrap: wrap;
}
.tabbar .selected {
  background: var(--brand);
  color: #fff;
}
a {
  color: #147d78;
}
button:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 3px solid #46a8a0;
  outline-offset: 3px;
}
@media (max-width: 720px) {
  header {
    padding: 18px;
    align-items: flex-start;
  }
  .brand span {
    font-size: 14px;
  }
  #identity {
    align-items: flex-end;
    flex-direction: column;
    gap: 6px;
  }
  main {
    margin-top: 25px;
    padding: 0 16px 40px;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .card {
    padding: 20px;
  }
  .turn {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .record {
    align-items: flex-start;
    flex-direction: column;
  }
  .auth {
    margin: 25px auto;
  }
  .stats {
    gap: 9px;
  }
  .stat {
    min-width: 100px;
  }
  h1 {
    letter-spacing: -0.6px;
  }
}
:root .voice-choices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 16px;
  margin: 20px 0;
}
.voice-choice {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fbfdfd;
}
.voice-choice.suggested {
  border-color: #70b4a9;
  background: #f1f9f6;
}
.voice-choice blockquote {
  max-height: 160px;
  overflow: auto;
  overflow-wrap: anywhere;
}
.voice-choice button {
  margin-top: 8px;
}
.menu-toggle {
  font-size: 26px;
  line-height: 1;
  padding: 10px 14px;
  background: #e8f2f2;
  min-width: 48px;
}
.menu-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  margin: 0;
  width: min(390px, 92vw);
  height: 100dvh;
  max-height: 100dvh;
  border: 0;
  border-left: 1px solid var(--line);
  padding: 28px 24px;
  color: #193e48;
  background: #fff;
  box-shadow: -10px 0 50px #193e4820;
}
.menu-drawer::backdrop {
  background: #143a4655;
}
.menu-drawer nav {
  display: grid;
  gap: 6px;
  margin-top: 25px;
}
.menu-drawer nav button {
  text-align: left;
  padding: 15px;
  border-radius: 11px;
  background: transparent;
  color: #264b52;
}
.menu-group { display: grid; gap: 3px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.menu-group h3 { margin: 0 0 5px 15px; color: var(--muted); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.help-start { background: linear-gradient(135deg, #edf8f3, #f5fbf9); }
.help-steps, .help-guide-body ol { padding-left: 24px; }
.help-steps li, .help-guide-body li { margin: 12px 0; line-height: 1.65; }
.help-search { max-width: 720px; margin: 28px 0 20px; }
.help-guides { display: grid; gap: 14px; }
.help-guide { margin: 0; padding: 0; }
.help-guide > summary { padding: 20px 24px; cursor: pointer; }
.help-guide > summary strong { font-size: 18px; }
.help-guide > summary span { display: block; margin: 5px 0 0 20px; color: var(--muted); font-weight: 400; font-size: 14px; }
.help-guide-body { padding: 0 24px 24px; border-top: 1px solid var(--line); }
.help-guide[hidden] { display: none; }
@media (max-width: 600px) {
  .help-guide > summary { padding: 16px; }
  .help-guide-body { padding: 0 16px 16px; }
}
.menu-drawer .menu-group button { padding: 10px 15px; width: 100%; }
.menu-drawer nav button:hover {
  background: #f1f7f6;
}
.menu-drawer nav button.selected {
  background: #147d78;
  color: white;
}
.report-bars {
  display: grid;
  gap: 18px;
  margin: 26px 0;
}
.report-bar {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 2fr 45px;
  gap: 18px;
  align-items: center;
  font-size: 14px;
}
progress {
  appearance: none;
  border: 0;
  width: 100%;
  height: 14px;
  border-radius: 8px;
  overflow: hidden;
  background: #eef3f4;
}
progress::-webkit-progress-bar {
  background: #eef3f4;
}
progress::-webkit-progress-value {
  background: #8c9ba5;
  border-radius: 8px;
}
progress::-moz-progress-bar {
  background: #8c9ba5;
}
.good progress::-webkit-progress-value {
  background: #29947a;
}
.issues progress::-webkit-progress-value {
  background: #de8256;
}
.review progress::-webkit-progress-value {
  background: #d8b549;
}
.good progress::-moz-progress-bar {
  background: #29947a;
}
.issues progress::-moz-progress-bar {
  background: #de8256;
}
.review progress::-moz-progress-bar {
  background: #d8b549;
}
.month-row {
  display: grid;
  grid-template-columns: 160px repeat(4, 1fr);
  gap: 15px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.month-row > div {
  display: flex;
  align-items: center;
  gap: 7px;
}
.month-row strong {
  font-size: 13px;
}
.script-list {
  padding-left: 24px;
}
.script-list li {
  padding: 14px 4px;
  line-height: 1.6;
  border-bottom: 1px solid var(--line);
}
.doctor-script-guide {
  margin: 28px 0 24px;
  padding: 24px;
  border: 1px solid #cfe5e1;
  border-radius: 18px;
  background: #f4faf8;
}
.doctor-script-guide h3 { margin: 0 0 8px; font-size: 20px; letter-spacing: -.02em; }
.doctor-script-guide > p { margin: 0 0 18px; }
.doctor-script-example { padding: 16px 0; border-top: 1px solid #d6e9e5; }
.doctor-script-example strong { color: #155f59; font-size: 15px; }
.doctor-script-example p { margin: 7px 0 0; line-height: 1.65; }
@media (max-width: 680px) { .doctor-script-guide { padding: 18px; } }
.list {
  margin-top: 20px;
}
[hidden] {
  display: none !important;
}
.report-card h2 {
  overflow-wrap: anywhere;
}
@media (max-width: 650px) {
  .report-bar {
    grid-template-columns: 1fr 35px;
    gap: 8px;
  }
  .report-bar > span {
    grid-column: 1/-1;
  }
  .month-row {
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }
  .month-row > strong {
    grid-column: 1/-1;
  }
  #identity {
    flex-direction: row;
    align-items: center;
  }
  #identity > span {
    max-width: 150px;
    font-size: 12px;
  }
  .menu-drawer {
    padding: 22px 18px;
  }
}
.filter-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin: 20px 0;
}
.calendar-search {
  margin: 22px 0 8px;
  padding: 16px 18px;
  border: 1px solid #c9e4dc;
  border-radius: 16px;
  background: linear-gradient(120deg, #f1faf7, #ffffff);
}
.calendar-search label { display:block; margin:0 0 10px; font-weight:700; }
.calendar-controls { display:flex; align-items:center; flex-wrap:wrap; gap:10px; }
.calendar-controls input[type="date"] { width:min(220px,100%); min-height:42px; cursor:pointer; }
.calendar-controls button { min-height:42px; margin:0; }
.calendar-open { color:#fff; background:#147d70; border-radius:10px; }
.calendar-clear { color:#355c53; background:#e8f3ee; border-radius:10px; }
.calendar-clear[hidden] { display:none; }
.advanced-recording-filters { margin:12px 0 20px; }
.advanced-recording-filters summary { cursor:pointer; color:#456a60; font-size:14px; padding:10px 0; }
.advanced-recording-filters[open] summary { font-weight:650; }
.audit-item details {
  margin-top: 14px;
}
.audit-item textarea {
  min-height: 90px;
}
.audit-item button {
  margin: 6px 6px 6px 0;
}
.menu-drawer {
  overflow-y: auto;
}
.filter-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 16px !important;
}
.filter-grid input,
.filter-grid select {
  width: 100%;
  min-width: 0;
}
@media (max-width: 700px) {
  .filter-grid {
    grid-template-columns: 1fr !important;
  }
}
.header-person {
  width: 68px;
  height: 68px;
  object-fit: contain;
  flex-shrink: 0;
}
.notification-unread {
  border-left: 4px solid #d27a33;
}
.alert-count {
  background: #b64b21;
  color: #fff;
  border-radius: 20px;
  padding: 2px 7px;
  font-size: 12px;
}
@media (max-width: 700px) {
  .header-person {
    width: 44px;
    height: 44px;
  }
  .brand {
    gap: 7px !important;
    font-size: 14px !important;
  }
  header {
    gap: 10px !important;
    flex-wrap: wrap;
  }
}
@media (max-width: 700px) {
  #identity {
    width: 100%;
    justify-content: space-between;
  }
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.notification-bell {
  position: relative;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  padding: 12px;
  border-radius: 14px;
}
.notification-bell .alert-count {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 20px;
  line-height: 20px;
  padding: 0 5px;
  border: 2px solid white;
}
.notification-bell:focus-visible {
  outline: 3px solid #147d78;
  outline-offset: 3px;
}
@media (min-width: 901px) {
  .brand {
    gap: 18px;
    flex-shrink: 0;
  }
  .brand > span {
    font-size: clamp(24px, 2.3vw, 32px);
    font-weight: 800;
    letter-spacing: 0.2px;
    white-space: nowrap;
  }
  .header-person {
    width: 80px;
    height: 80px;
  }
  #identity > span {
    max-width: 260px;
    text-align: right;
  }
}
.overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
  margin: 24px 0;
}
.overview-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 22px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 18px;
  text-align: left;
}
.overview-card strong {
  font-size: 32px;
  color: var(--brand);
}
.overview-card:hover {
  border-color: var(--brand);
  background: #edf7f6;
}
.recording-timer {
  font-size: 23px;
  font-variant-numeric: tabular-nums;
  color: var(--brand);
  font-weight: 700;
}
meter {
  display: block;
  width: 100%;
  height: 16px;
  margin: 8px 0;
}
.card > progress {
  width: 100%;
  height: 14px;
}

/* Финальная визуальная система: спокойная клиническая палитра и более ясная иерархия. */
.header-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  flex-wrap: wrap;
}
.online-indicator {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 182px;
  padding: 10px 13px;
  border: 1px solid #cfe5dc;
  border-radius: 14px;
  background: #f4faf7;
  color: #21534a;
  box-shadow: 0 5px 16px #154f3510;
}
.online-indicator:not(.is-connected) { border-color: var(--line); background: #f5f8f8; color: var(--muted); }
.online-lamp { position: relative; flex: none; width: 10px; height: 10px; border-radius: 50%; background: #99aca9; }
.online-indicator.is-connected .online-lamp { background: #29b969; box-shadow: 0 0 0 3px #29b96924, 0 0 13px #29b96991; }
.online-indicator.is-connected .online-lamp::after {
  content: ''; position: absolute; inset: -5px; border: 1px solid #29b96983;
  border-radius: 50%; animation: online-pulse 2.2s ease-out infinite;
}
@keyframes online-pulse { 0% { transform: scale(.65); opacity: .95; } 100% { transform: scale(1.55); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .online-indicator.is-connected .online-lamp::after { animation: none; } }
.online-copy { display: grid; gap: 2px; line-height: 1.3; white-space: nowrap; }
.online-copy strong { font-size: 13px; font-weight: 750; }
.online-copy small { font-size: 11px; color: #55756d; }
.branch-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin:22px 0}
.branch-item,.team-member{display:grid;gap:8px;padding:18px;border:1px solid #d4e5e7;border-radius:14px;background:#fff}
.branch-item{grid-template-rows:minmax(30px,auto) auto 1fr;min-width:0;min-height:150px;box-sizing:border-box;padding:18px;border-radius:18px;background:linear-gradient(180deg,#fff,#f7fbfa);box-shadow:0 8px 24px #123b460b;font-family:"Trebuchet MS","Avenir Next","Segoe UI",sans-serif}
.branch-brand{color:#123b46;font-size:18px;font-weight:750;line-height:1.25;letter-spacing:-.02em;overflow-wrap:anywhere}
.branch-metro{justify-self:start;align-self:start;max-width:100%;box-sizing:border-box;padding:6px 10px;border:1px solid #b9dcd6;border-radius:999px;background:#e9f6f2;color:#17665f;font-size:13px;font-weight:700;line-height:1.25;overflow-wrap:anywhere}
.branch-address{align-self:start;color:#57717a;font-size:14px;line-height:1.45;overflow-wrap:anywhere}
.team-member>strong{color:#123b46;font-size:16px}
.team-member>small{color:#657d86;line-height:1.4}
.team-member details{margin:6px 0 0}
@media(max-width:900px){.branch-list{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){.branch-list{grid-template-columns:1fr}.branch-item{min-height:136px}}
.team-panel{padding:0;overflow:hidden}
.team-panel>summary{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:58px;box-sizing:border-box;padding:17px 22px;list-style:none;color:#123b46;font-family:"Trebuchet MS","Avenir Next","Segoe UI",sans-serif;font-size:18px;font-weight:750}
.team-panel>summary::-webkit-details-marker,.team-member-summary::-webkit-details-marker{display:none}
.team-panel>summary::after,.team-member-summary::after{content:"⌄";flex:none;display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#e9f6f2;color:#17665f;font-size:20px;line-height:1;transition:transform .2s}
.team-panel[open]>summary::after,.team-member[open]>.team-member-summary::after{transform:rotate(180deg)}
.team-panel[open]>summary{border-bottom:1px solid #dcebe9}
.team-panel-body{padding:18px 22px 22px}
.team-panel-body>.branch-list{margin-top:18px}
.team-member{display:block;min-width:0;padding:0;margin:0 0 8px;border-radius:12px;box-shadow:none}
.team-member-summary{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1.3fr) auto 28px;align-items:center;gap:12px;padding:12px 15px;list-style:none;font-family:"Trebuchet MS","Avenir Next","Segoe UI",sans-serif}
.team-member-summary>strong{color:#123b46;font-size:15px;line-height:1.3;overflow-wrap:anywhere}
.team-member-branch{color:#236d65;font-size:13px;line-height:1.35;overflow-wrap:anywhere}
.team-member-role{color:#657d86;font-size:12px;line-height:1.35;white-space:nowrap}
.team-member-summary::after{grid-column:4;width:26px;height:26px;font-size:18px}
.team-member-body{padding:8px 16px 16px;border-top:1px solid #e3eeed}
.team-member-body>details{margin:8px 0}
@media(max-width:700px){.team-panel>summary{padding:15px 17px;font-size:17px}.team-panel-body{padding:16px}.team-member-summary{grid-template-columns:minmax(0,1fr) 28px;gap:4px 10px}.team-member-summary>strong,.team-member-branch,.team-member-role{grid-column:1}.team-member-summary::after{grid-column:2;grid-row:1/4;align-self:center}.team-member-role{white-space:normal}}
.team-edit-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 16px}
.team-edit-grid>button{justify-self:start;margin-top:8px}
@media(max-width:650px){.team-edit-grid{grid-template-columns:1fr}}
.download-app {
  text-align: center;
  font-size: 14px;
  white-space: nowrap;
}
.staff-presence { position:relative; max-width:240px; font-size:12px; color:var(--muted); }
.staff-presence[hidden] { display:none; }
.staff-presence summary { cursor:pointer; padding:10px; border:1px solid var(--line); border-radius:12px; }
.staff-presence.has-active summary { color:#11674f; background:#e3f4ec; border-color:#afdcc7; }
#staff-presence-list { position:absolute; z-index:30; top:calc(100% + 8px); right:0; width:min(340px,85vw); max-height:50vh; overflow:auto; background:white; padding:16px; border:1px solid var(--line); border-radius:14px; box-shadow:0 12px 30px #123b4620; }
.presence-person { padding:8px 0; border-bottom:1px solid var(--line); }
.presence-person strong,.presence-person span { display:block; }
.presence-person span { color:#11674f; margin-top:4px; }
#staff-presence-list small { display:block; margin-top:12px; font-size:11px; }
.download-app span {
  display: block;
  font-size: 12px;
  font-weight: 400;
  margin-top: 4px;
}
@media (max-width: 700px), (hover: none) and (pointer: coarse) {
  .download-app, .staff-presence {
    display: none;
  }
}
.record-description {
  display: block;
  margin-top: 7px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 14px;
  font-weight: 400;
}
@media (max-width: 900px) {
  .header-right {
    width: 100%;
    justify-content: space-between;
  }
  .header-right #identity {
    flex: 1;
    min-width: 170px;
  }
  .download-app {
    padding: 10px !important;
  }
}
@media (max-width: 700px) {
  .online-indicator { min-width: 0; padding: 8px 10px; }
  .online-copy strong { font-size: 12px; }
  .online-copy small { font-size: 10px; }
  .record { flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 8px; min-width: 0; }
  .record > * { min-width: 0; max-width: 100%; box-sizing: border-box; }
  .record .badge { align-self: flex-start; white-space: normal; overflow-wrap: anywhere; }
  .record-quality-reason, .record-warning-reason { overflow-wrap: anywhere; }
  header { padding:9px 16px; gap:6px !important; }
  .header-person { display:none; }
  .brand-k { width:36px; height:36px; }
  .brand .brand-title { font-size:16px; }
}
:root {
  --ink: #123b46;
  --ink-soft: #315963;
  --muted: #667f87;
  --brand: #0f766e;
  --brand-deep: #0a5660;
  --brand-bright: #2b9d91;
  --accent: #efb866;
  --line: #d6e7e9;
  --surface: #ffffff;
  --surface-soft: #f2f8f8;
  --shadow-sm: 0 8px 24px rgba(16, 61, 70, 0.07);
  --shadow-lg: 0 20px 55px rgba(16, 61, 70, 0.11);
}

html {
  min-width: 280px;
  background: #edf6f7;
}

body {
  color: var(--ink);
  background:
    radial-gradient(
      circle at 8% 0%,
      rgba(65, 170, 159, 0.12),
      transparent 25rem
    ),
    radial-gradient(
      circle at 100% 20%,
      rgba(239, 184, 102, 0.1),
      transparent 23rem
    ),
    linear-gradient(180deg, #f8fbfb 0%, #edf6f7 100%);
}

header {
  position: sticky;
  top: 0;
  z-index: 10;
  padding-top: 16px;
  padding-bottom: 16px;
  background: rgba(255, 255, 255, 0.9);
  border-bottom-color: rgba(183, 211, 214, 0.8);
  box-shadow: 0 4px 20px rgba(18, 59, 70, 0.04);
  backdrop-filter: blur(16px);
}

.brand {
  color: var(--brand);
  letter-spacing: -0.02em;
}

.brand > span {
  color: var(--ink);
}
.brand-k { width:70px; height:70px; flex-shrink:0; object-fit:contain; }
.brand .brand-caption { display:flex; flex-direction:column; position:relative; padding-bottom:29px; min-width:250px; }
.brand .brand-title { font-size:clamp(24px,2.3vw,32px); font-weight:800; white-space:nowrap; color:var(--ink); }
.brand-sound { position:absolute; left:0; bottom:0; width:100%; height:23px; fill:none; stroke:#82bcb0; stroke-width:2.4; stroke-linecap:round; }
.brand-sound .voice-pulse { stroke:#147d78; animation:clinic-voice-pulse 2.8s ease-in-out infinite; }
.brand-sound .voice-bar { stroke:#147d78; transform-box:fill-box; transform-origin:center; animation:clinic-wave 1.5s ease-in-out infinite alternate; }
@keyframes clinic-wave { 0%,100% { transform:scaleY(.3); opacity:.55; } 45% { transform:scaleY(1); opacity:1; } 70% { transform:scaleY(.6); opacity:.8; } }
@keyframes clinic-voice-pulse { 50% { opacity:.35; } }
@media(max-width:900px) { .brand-k { width:50px; height:50px; } .brand .brand-title { font-size:20px; } }
@media(max-width:700px) { .brand-k { width:42px; height:42px; } .brand .brand-title { font-size:26px; line-height:1.15; } .brand-sound { height:20px; } .brand .brand-caption { padding-bottom:26px; min-width:205px; } }
@media(prefers-reduced-motion:reduce) { .brand-sound .voice-pulse,.brand-sound .voice-bar { animation:none; } }

.header-person {
  filter: drop-shadow(0 8px 10px rgba(15, 118, 110, 0.18));
}

main {
  max-width: 1180px;
  margin-top: 46px;
}

h1 {
  color: var(--ink);
  font-weight: 800;
  line-height: 1.08;
}

h2,
h3 {
  color: var(--ink);
  letter-spacing: -0.02em;
}

p {
  color: var(--ink-soft);
}

.card {
  padding: 28px;
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(197, 222, 224, 0.95);
  box-shadow: var(--shadow-sm);
  transition:
    box-shadow 180ms ease,
    transform 180ms ease,
    border-color 180ms ease;
}

.card:hover {
  border-color: #b7d5d6;
  box-shadow: var(--shadow-lg);
}

.auth {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: var(--shadow-lg);
}

.auth::before {
  display: block;
  width: 64px;
  height: 5px;
  margin-bottom: 26px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--accent));
  content: "";
}

.eyebrow {
  letter-spacing: 0.18em;
  color: var(--brand);
}

button,
.button {
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 12px 18px;
  color: var(--brand-deep);
  background: #e5f2f1;
  box-shadow: 0 2px 0 rgba(18, 59, 70, 0.04);
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease,
    filter 160ms ease;
}

button:hover,
.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(18, 59, 70, 0.1);
  filter: none;
}

button:active,
.button:active {
  transform: translateY(0);
}

.primary {
  background: linear-gradient(
    135deg,
    var(--brand) 0%,
    var(--brand-bright) 100%
  );
  box-shadow: 0 7px 16px rgba(15, 118, 110, 0.2);
}

.danger {
  background: #fff0ef;
  border-color: #f5d1cc;
}

input,
select,
textarea {
  border-color: #c8dfe1;
  border-radius: 12px;
  background: #fcfefe;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease;
}

input:hover,
select:hover,
textarea:hover {
  border-color: #91c6c2;
}

input:focus,
select:focus,
textarea:focus {
  outline: 0;
  border-color: var(--brand-bright);
  box-shadow: 0 0 0 4px rgba(43, 157, 145, 0.14);
  background: #fff;
}

.upload {
  border-color: #83bdb8;
  background: linear-gradient(135deg, #f5fbfa, #edf7f6);
}

.record,
.overview-card,
.stat {
  border-color: #d4e5e7;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 4px 14px rgba(16, 61, 70, 0.04);
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease;
}

.record:hover,
.overview-card:hover {
  transform: translateY(-2px);
  border-color: #8bc6c0;
  background: #fff;
  box-shadow: 0 12px 25px rgba(16, 61, 70, 0.09);
}

.record strong {
  color: var(--ink);
}

.badge {
  background: #e6f5f1;
  color: #1f7163;
  font-weight: 700;
}

.overview-card strong,
.stat strong {
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}

.overview-card span {
  color: var(--ink-soft);
  font-weight: 650;
}

.stats {
  gap: 14px;
}

.stat {
  position: relative;
  overflow: hidden;
}

.stat::after {
  position: absolute;
  right: -14px;
  bottom: -26px;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: rgba(43, 157, 145, 0.09);
  content: "";
}

.transcript {
  border: 1px solid #e0ecec;
  border-radius: 16px;
  padding: 0 16px;
  background: #fbfdfd;
}

.turn:nth-child(even) {
  background: rgba(239, 247, 247, 0.65);
}

.turn {
  padding: 16px 10px;
  border-bottom-color: #e5eeee;
}

blockquote {
  border-left-color: var(--accent);
  border-radius: 0 10px 10px 0;
  background: #fff9ed;
}

.note {
  border: 1px solid #f2dfb3;
  background: #fff9eb;
}

.menu-drawer {
  background: linear-gradient(180deg, #ffffff 0%, #f2f9f8 100%);
  box-shadow: -18px 0 55px rgba(18, 59, 70, 0.15);
}

.menu-drawer nav button {
  border: 1px solid transparent;
}

.menu-drawer nav button:hover {
  border-color: #cfe3e3;
  background: #e9f5f3;
}

.menu-drawer nav button.selected {
  background: linear-gradient(135deg, var(--brand), var(--brand-bright));
  box-shadow: 0 7px 16px rgba(15, 118, 110, 0.18);
}

.notification-unread {
  border-left-color: var(--accent);
  background: linear-gradient(90deg, #fffaf0, #fff);
}
.medical-note-paper { max-width: 850px; margin: 22px auto; padding: clamp(24px,5vw,54px); border-radius: 4px; box-shadow: 0 12px 36px #193e4815; }
.medical-note-paper h1 { text-align: center; font-size: clamp(26px,4vw,36px); margin: 18px 0 28px; }
.medical-note-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 24px; border-top: 1px solid #b8c7cb; border-bottom: 1px solid #b8c7cb; padding: 12px 0; margin-bottom: 24px; }
.medical-note-meta p { margin: 3px 0; }
.medical-note-field { margin: 0; padding: 22px 0; border-bottom: 1px solid #d8e1e3; }
.medical-note-field label { display: block; font-weight: 700; margin-bottom: 12px; color: #193e48; }
.medical-note-field textarea { width: 100%; min-height: 118px; resize: vertical; line-height: 1.6; background: #fff; }
.medical-note-field details { margin-top: 8px; white-space: pre-wrap; font-size: 13px; color: var(--muted); }
.medical-note-archive { margin: 24px 0; padding: 16px; border: 1px solid var(--line); border-radius: 10px; white-space: pre-wrap; }
.medical-note-archive h3 { margin: 16px 0 4px; }
@media (max-width: 600px) { .medical-note-paper { padding: 22px 16px; } .medical-note-meta { grid-template-columns: 1fr; } }
@media print { header, .medical-note-paper .actions, .medical-note-paper details, .medical-note-paper .note, .back { display: none !important; } body { background: #fff; } main { margin: 0; padding: 0; max-width: none; } .medical-note-paper { max-width: none; border: 0; box-shadow: none; margin: 0; padding: 0; } .medical-note-field textarea { border: 0; padding: 0; resize: none; } }
.notification-read-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #526779;
  font-size: 13px;
}
.notification-unread-dot {
  width: 9px;
  height: 9px;
  flex-shrink: 0;
  border-radius: 50%;
  background: #147d78;
  box-shadow: 0 0 0 3px #d9efea;
}

.script-list li::marker {
  color: var(--brand);
  font-weight: 800;
}

#notice {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: #123b46;
  box-shadow: 0 12px 32px rgba(18, 59, 70, 0.25);
}

@media (max-width: 700px) {
  header {
    padding-top: 12px;
    padding-bottom: 12px;
  }

  main {
    margin-top: 28px;
  }

  .card {
    padding: 22px;
    border-radius: 20px;
  }

  .auth {
    margin-top: 30px;
    border-radius: 22px;
  }

  .overview-grid {
    gap: 10px;
  }

  .overview-card {
    padding: 17px;
  }
}
@media (max-width: 700px) {
  .medical-note-paper { padding: 22px 16px; border-radius: 4px; }
  .medical-note-meta { grid-template-columns: 1fr; }
}
.staff-test-card { min-width: 0; }
.test-results-card {
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.test-results-card h2 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.025em;
}
.test-results-list { display: grid; gap: 12px; margin-top: 22px; }
.test-person-row, .test-history-row {
  display: grid;
  align-items: center;
  gap: 18px;
  min-height: 76px;
  padding: 16px 20px;
  border: 1px solid #dce9e9;
  border-radius: 16px;
  background: #f8fbfa;
}
.test-person-row { grid-template-columns: minmax(0, 1fr) auto; }
.test-history-row { grid-template-columns: minmax(0, 1fr) auto auto; }
.test-person-info { display: grid; gap: 5px; min-width: 0; }
.test-person-name {
  color: #173b43;
  font-size: 16px;
  font-weight: 650;
  line-height: 1.4;
  letter-spacing: -0.015em;
}
.test-result-date {
  color: #617b80;
  font-size: 13px;
  font-weight: 450;
  line-height: 1.4;
  font-variant-numeric: tabular-nums;
}
.test-result-status, .test-history-score {
  justify-self: end;
  padding: 10px 14px;
  border-radius: 11px;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.35;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.test-result-status.is-done, .test-history-score { color: #176457; background: #e4f5ef; }
.test-result-status.is-pending { color: #83622b; background: #fff4dc; }
.test-review-button { justify-self: end; min-width: 90px; }
.test-complete-summary, .test-review-form {
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.test-complete-summary h2 { margin-bottom: 20px; letter-spacing: -0.025em; }
.test-complete-figures { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 18px; }
.test-complete-figure {
  display: inline-flex; align-items: center; min-height: 48px; padding: 11px 17px;
  border-radius: 12px; font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.test-complete-figure.is-correct { color: #176457; background: #e4f5ef; }
.test-complete-figure.is-error { color: #9c4d3d; background: #fff0eb; }
.test-complete-summary > p { margin-bottom: 0; }
.test-review-form { display: grid; gap: 22px; }
.test-review-card { margin: 0; padding: 28px; }
.test-review-card legend { max-width: 100%; font-size: 15px; line-height: 1.4; }
.test-review-prompt {
  margin: 10px 0 22px; color: #173b43; font-size: 17px;
  font-weight: 600; line-height: 1.6; letter-spacing: -0.01em;
}
.staff-test-card.test-review-card .check { padding: 14px 16px; margin: 10px 0; line-height: 1.5; }
.staff-test-card.test-review-card .check.is-selected { background: #eef8f6; border-color: #afd8cf; }
.test-review-feedback {
  display: grid; gap: 10px; margin-top: 22px; padding: 20px 22px;
  border-radius: 15px; border: 1px solid #cbe8dd; background: #f0faf5;
  font-size: 15px; line-height: 1.6;
}
.test-review-feedback.is-error { border-color: #f0d8ce; background: #fff7f3; }
.test-review-feedback-title { color: #176457; font-size: 16px; font-weight: 750; }
.test-review-feedback.is-error .test-review-feedback-title { color: #9c4d3d; }
.test-review-feedback p { margin: 0; }
.test-review-correct-answer { font-weight: 650; }
.test-review-explanation { padding-top: 12px; border-top: 1px solid #d7e7e2; color: #526b70; }
@media (max-width: 680px) {
  .test-person-row, .test-history-row { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 16px; }
  .test-result-status, .test-history-score, .test-review-button { justify-self: start; }
  .test-person-name { font-size: 15px; }
  .test-review-card { padding: 20px 16px; }
  .test-review-feedback { padding: 17px; }
  .test-review-prompt { font-size: 16px; }
}
.staff-test-card legend { padding: 0 8px; font-weight: 750; color: #126b66; }
.staff-test-card .check { align-items: center; padding: 12px; margin: 8px 0; border: 1px solid #dce8ea; border-radius: 12px; cursor: pointer; }
.staff-test-card .check:hover { background: #f2faf8; }
.staff-test-card input[type="radio"] { width: auto; flex: none; margin: 0; }
.staff-test-bank details { border-top: 1px solid #dce8ea; padding: 12px 0; }
.staff-test-bank summary { cursor: pointer; font-weight: 700; }
.staff-test-bank .row { padding: 12px 0; border-bottom: 1px solid #edf2f3; }
.staff-test-bank .row span { flex: 1; min-width: 200px; }
.staff-test-bank-item { padding: 10px 0 14px; border-bottom: 1px solid #edf2f3; }
.staff-test-bank-item .row { border-bottom: 0; align-items: flex-start; gap: 16px; }
.staff-test-bank-item .row strong { flex: 1; min-width: 0; line-height: 1.5; }
.staff-test-bank-options { margin: 0 0 0 22px; padding-left: 20px; line-height: 1.5; }
.staff-test-bank-options li { padding: 4px 8px; }
.staff-test-bank-options li.correct { color: #126b66; background: #eaf8f2; border-radius: 8px; font-weight: 700; }
.branch-gate{position:fixed;inset:0;z-index:10000;display:grid;place-items:center;padding:20px;background:rgba(8,35,42,.72);backdrop-filter:blur(7px);overflow:auto}
.branch-gate-card{width:min(100%,480px);margin:auto;padding:30px;box-shadow:0 25px 80px rgba(0,0,0,.24)}
.branch-gate-card h1{margin:0 0 12px}.branch-gate-card .primary{margin-top:18px;width:100%}

@media(max-width:360px){.brand .brand-caption{min-width:180px}}

/* One shared size for the wordmark and animated sound line. */
.brand .brand-caption{min-width:0;width:max-content}
.brand .brand-title{font-size:44px;line-height:1.15}
@media(max-width:900px){.brand .brand-title{font-size:36px}}
@media(max-width:700px){.brand .brand-caption{min-width:0}.brand .brand-title{font-size:36px}}
@media(max-width:360px){.brand .brand-caption{min-width:0}.brand .brand-title{font-size:32px}}

.control-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:18px}.control-grid .card{margin:0}.control-grid button{margin:6px 8px 6px 0}.control-answer{white-space:pre-wrap;line-height:1.65;margin-top:18px}.control-grid p{overflow-wrap:anywhere}
