/* DRL Connect web client: Material Design 3 tokens, light and dark. No framework, no external files. */
:root {
  --primary: #0b57d0; --on-primary: #fff; --primary-container: #d8e2ff; --on-primary-container: #001a41;
  --secondary-container: #dde3f1; --on-secondary-container: #151c2c;
  --surface: #fdfbff; --surface-1: #f3f4fa; --surface-2: #ecedf6; --surface-3: #e6e8f2; --surface-variant: #e1e2ec;
  --on-surface: #1a1b20; --on-surface-variant: #44474f; --outline: #74777f; --outline-variant: #c4c6d0;
  --error: #ba1a1a; --on-error: #fff; --error-container: #ffdad6; --ok: #146c2e;
  --bubble-out: #d8e2ff; --bubble-in: #ecedf6;
  --shadow: 0 1px 2px rgb(0 0 0 / .18), 0 2px 6px 2px rgb(0 0 0 / .1);
  --r-s: 8px; --r-m: 12px; --r-l: 16px; --r-xl: 28px;
  font-family: Roboto, "Segoe UI Variable", "Segoe UI", system-ui, -apple-system, sans-serif;
  color-scheme: light dark;
}
:root[data-theme="dark"] {
  --primary: #adc6ff; --on-primary: #002e69; --primary-container: #0842a0; --on-primary-container: #d8e2ff;
  --secondary-container: #3f4759; --on-secondary-container: #dde3f1;
  --surface: #121318; --surface-1: #1b1b21; --surface-2: #1f1f25; --surface-3: #292a2f; --surface-variant: #44474f;
  --on-surface: #e3e2e9; --on-surface-variant: #c4c6d0; --outline: #8e9099; --outline-variant: #44474f;
  --error: #ffb4ab; --on-error: #690005; --error-container: #93000a; --ok: #7cdc95;
  --bubble-out: #0842a0; --bubble-in: #292a2f;
  --shadow: 0 1px 2px rgb(0 0 0 / .5), 0 2px 6px 2px rgb(0 0 0 / .3);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --primary: #adc6ff; --on-primary: #002e69; --primary-container: #0842a0; --on-primary-container: #d8e2ff;
    --secondary-container: #3f4759; --on-secondary-container: #dde3f1;
    --surface: #121318; --surface-1: #1b1b21; --surface-2: #1f1f25; --surface-3: #292a2f; --surface-variant: #44474f;
    --on-surface: #e3e2e9; --on-surface-variant: #c4c6d0; --outline: #8e9099; --outline-variant: #44474f;
    --error: #ffb4ab; --on-error: #690005; --error-container: #93000a; --ok: #7cdc95;
    --bubble-out: #0842a0; --bubble-in: #292a2f;
    --shadow: 0 1px 2px rgb(0 0 0 / .5), 0 2px 6px 2px rgb(0 0 0 / .3);
  }
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--surface); color: var(--on-surface); font-size: 14px; line-height: 20px; -webkit-font-smoothing: antialiased; overflow: hidden; }
#app { height: 100%; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin: 0; }
[hidden] { display: none !important; }
.ic { width: 24px; height: 24px; fill: currentColor; flex: none; }
.ic.s { width: 18px; height: 18px; }

/* ---- buttons ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 24px; border: 0; border-radius: 20px;
  background: var(--primary); color: var(--on-primary); font-weight: 500; letter-spacing: .1px; transition: box-shadow .15s, filter .15s; }
.btn:hover { filter: brightness(1.08); box-shadow: var(--shadow); }
.btn:disabled { opacity: .38; cursor: default; box-shadow: none; filter: none; }
.btn.tonal { background: var(--secondary-container); color: var(--on-secondary-container); }
.btn.text { background: transparent; color: var(--primary); padding: 0 12px; }
.btn.text:hover { background: color-mix(in srgb, var(--primary) 8%, transparent); box-shadow: none; filter: none; }
.btn.danger { background: var(--error-container); color: var(--error); }
.icon-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: transparent; color: var(--on-surface-variant); }
.icon-btn:hover { background: color-mix(in srgb, var(--on-surface) 8%, transparent); }
.icon-btn.filled { background: var(--primary); color: var(--on-primary); }
.icon-btn.filled:disabled { opacity: .38; }

/* ---- text fields (outlined) ---- */
.field { position: relative; display: block; margin-top: 16px; }
.field input { width: 100%; height: 56px; padding: 16px; border: 1px solid var(--outline); border-radius: 4px; background: transparent; outline: none; }
.field input:focus { border: 2px solid var(--primary); padding: 15px; }
.field label { position: absolute; left: 12px; top: 16px; padding: 0 4px; background: var(--surface); color: var(--on-surface-variant); pointer-events: none;
  transition: transform .12s, color .12s; transform-origin: left top; }
.field input:focus + label, .field input:not(:placeholder-shown) + label { transform: translateY(-26px) scale(.75); }
.field input:focus + label { color: var(--primary); }
.hint { color: var(--on-surface-variant); font-size: 12px; margin-top: 4px; }
.err { color: var(--error); margin-top: 12px; min-height: 20px; }

/* ---- auth ---- */
.auth { min-height: 100%; display: grid; place-items: center; padding: 16px; background: var(--surface); overflow: auto; }
.card { width: min(420px, 100%); background: var(--surface); border-radius: var(--r-xl); padding: 32px 28px 28px; box-shadow: var(--shadow); }
.brand { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.brand img { width: 40px; height: 40px; }
.brand b { font-size: 22px; font-weight: 500; }
.card h2 { font-size: 24px; line-height: 32px; font-weight: 400; margin: 16px 0 4px; }
.card .actions { display: flex; justify-content: space-between; align-items: center; margin-top: 24px; }

/* ---- shell ---- */
/* the one row must be exactly the height of the window (minmax(0, 1fr)): with plain "auto" Firefox lets a long chat stretch the whole page past the screen */
.shell { display: grid; grid-template-columns: 80px 360px 1fr; grid-template-rows: minmax(0, 1fr); height: 100%; }
.shell > .rail, .shell > .pane, .shell > .thread, .shell > .page { min-height: 0; }
.rail { background: var(--surface); display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 12px 0; border-right: 1px solid var(--outline-variant); }
.rail .logo { width: 40px; height: 40px; margin-bottom: 8px; }
.nav { display: grid; justify-items: center; gap: 4px; width: 64px; border: 0; background: none; color: var(--on-surface-variant); padding: 4px 0; font-size: 12px; position: relative; }
.nav .pill { display: grid; place-items: center; width: 56px; height: 32px; border-radius: 16px; transition: background .15s; }
.nav:hover .pill { background: color-mix(in srgb, var(--on-surface) 8%, transparent); }
.nav[aria-current="page"] { color: var(--on-surface); font-weight: 500; }
.nav[aria-current="page"] .pill { background: var(--secondary-container); color: var(--on-secondary-container); }
.nav .dot { position: absolute; top: 2px; right: 10px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--error); color: var(--on-error); font-size: 11px; line-height: 16px; text-align: center; }
.spacer { flex: 1; }
.pane { display: flex; flex-direction: column; min-width: 0; background: var(--surface-1); border-right: 1px solid var(--outline-variant); }
.appbar { display: flex; align-items: center; gap: 8px; height: 64px; padding: 0 16px; flex: none; }
.appbar h1 { font-size: 22px; line-height: 28px; font-weight: 400; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search { margin: 0 16px 8px; height: 48px; border-radius: 24px; background: var(--surface-3); display: flex; align-items: center; gap: 12px; padding: 0 16px; color: var(--on-surface-variant); }
.search input { flex: 1; border: 0; background: transparent; outline: none; min-width: 0; }
.list { overflow-y: auto; flex: 1; padding: 0 8px 16px; }
.row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px 12px; border: 0; border-radius: var(--r-l); background: transparent; text-align: left; min-height: 64px; }
.row:hover { background: color-mix(in srgb, var(--on-surface) 6%, transparent); }
.row[aria-selected="true"] { background: var(--secondary-container); }
.row .txt { flex: 1; min-width: 0; }
.row .t { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .s { color: var(--on-surface-variant); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .meta { display: grid; justify-items: end; gap: 4px; color: var(--on-surface-variant); font-size: 12px; }
.badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--primary); color: var(--on-primary); font-size: 12px; line-height: 20px; text-align: center; }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 500; font-size: 16px; color: #fff; flex: none; position: relative; }
.avatar .on { position: absolute; right: -1px; bottom: -1px; width: 12px; height: 12px; border-radius: 50%; background: var(--ok); border: 2px solid var(--surface-1); }
.empty { padding: 48px 24px; text-align: center; color: var(--on-surface-variant); }
.empty svg { width: 64px; height: 64px; opacity: .5; margin-bottom: 8px; }

/* ---- thread ---- */
.thread { display: flex; flex-direction: column; min-width: 0; background: var(--surface); }
.thread .appbar { border-bottom: 1px solid var(--outline-variant); }
.msgs { flex: 1; overflow-y: auto; padding: 16px 24px; display: flex; flex-direction: column; gap: 2px; }
.day { align-self: center; margin: 12px 0 8px; padding: 2px 12px; border-radius: 12px; background: var(--surface-3); color: var(--on-surface-variant); font-size: 12px; }
.m { max-width: min(560px, 82%); padding: 8px 12px 6px; border-radius: 18px; background: var(--bubble-in); align-self: flex-start; word-wrap: break-word; overflow-wrap: anywhere; position: relative; margin-top: 6px; }
.m.same { margin-top: 1px; }
.m.me { background: var(--bubble-out); align-self: flex-end; }
.m .who { font-size: 12px; font-weight: 500; color: var(--primary); margin-bottom: 2px; }
.m .body { white-space: pre-wrap; }
.m .time { display: flex; justify-content: flex-end; align-items: center; gap: 4px; margin-top: 2px; font-size: 11px; color: var(--on-surface-variant); }
.m .time .seen { color: var(--primary); }
.m.gone .body { font-style: italic; color: var(--on-surface-variant); }
.m .react { display: flex; gap: 4px; margin-top: 4px; flex-wrap: wrap; }
.m .react span { padding: 0 8px; border-radius: 10px; background: var(--surface-3); font-size: 12px; }
.m .tools { position: absolute; top: -14px; right: 8px; display: none; gap: 2px; background: var(--surface); border-radius: 16px; box-shadow: var(--shadow); padding: 2px; }
.m:hover .tools { display: flex; }
.m .tools .icon-btn { width: 28px; height: 28px; }
.file { display: flex; align-items: center; gap: 12px; padding: 8px 4px; min-width: 220px; cursor: pointer; border-radius: var(--r-m); }
.file:hover { background: color-mix(in srgb, var(--on-surface) 6%, transparent); }
.file .fi { width: 40px; height: 40px; border-radius: 10px; background: var(--primary-container); color: var(--on-primary-container); display: grid; place-items: center; }
.file .fn { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 280px; }
.pic { display: block; max-width: 320px; max-height: 260px; border-radius: var(--r-m); cursor: zoom-in; margin: 2px 0; background: var(--surface-3); min-width: 120px; min-height: 80px; }
.composer { display: flex; align-items: flex-end; gap: 8px; padding: 8px 16px 16px; }
.composer .box { flex: 1; background: var(--surface-3); border-radius: 24px; display: flex; align-items: flex-end; padding: 4px 4px 4px 16px; min-height: 48px; }
.composer textarea { flex: 1; border: 0; background: transparent; resize: none; outline: none; max-height: 140px; padding: 12px 0; line-height: 20px; min-width: 0; }
.progress { margin: 0 16px; height: 4px; border-radius: 2px; background: var(--surface-3); overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--primary); width: 0; transition: width .15s; }
.uploading { margin: 0 16px 4px; display: flex; gap: 8px; align-items: center; color: var(--on-surface-variant); font-size: 12px; }

/* ---- pages ---- */
.page { grid-column: 2 / 4; overflow-y: auto; background: var(--surface); }
.page .inner { max-width: 760px; margin: 0 auto; padding: 8px 24px 48px; }
.section { margin-top: 24px; }
.section h3 { font-size: 14px; font-weight: 500; color: var(--primary); margin-bottom: 8px; }
.list-card { background: var(--surface-1); border-radius: var(--r-l); padding: 4px; }
.tag { padding: 0 8px; border-radius: 8px; background: var(--secondary-container); color: var(--on-secondary-container); font-size: 12px; margin-left: 8px; }
.code { font-family: Consolas, "Cascadia Mono", monospace; font-size: 20px; letter-spacing: 2px; background: var(--surface-3); border-radius: var(--r-m); padding: 12px 16px; display: inline-block; user-select: all; }
.coming { display: grid; place-items: center; text-align: center; min-height: 60vh; color: var(--on-surface-variant); }
.coming h2 { color: var(--on-surface); font-weight: 400; font-size: 24px; margin: 8px 0; }

/* ---- dialogs and snackbar ---- */
.scrim { position: fixed; inset: 0; background: rgb(0 0 0 / .4); display: grid; place-items: center; z-index: 20; padding: 16px; }
.dialog { width: min(360px, 100%); background: var(--surface-1); border-radius: var(--r-xl); padding: 24px; box-shadow: var(--shadow); }
.dialog h3 { font-size: 24px; line-height: 32px; font-weight: 400; margin-bottom: 12px; }
.dialog .actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 24px; }
.snack { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--on-surface); color: var(--surface); padding: 12px 16px; border-radius: 4px; box-shadow: var(--shadow); z-index: 30; max-width: 90vw; }
.lightbox { position: fixed; inset: 0; background: rgb(0 0 0 / .85); display: grid; place-items: center; z-index: 25; cursor: zoom-out; }
.lightbox img { max-width: 94vw; max-height: 94vh; border-radius: 8px; }

/* ---- the landing page (the website's address, before sign-in) ---- */
.lp { position: fixed; inset: 0; overflow-x: hidden; overflow-y: auto; -webkit-overflow-scrolling: touch; background: var(--surface); color: var(--on-surface); }   /* the app's own page does not scroll, so this one scrolls by itself */
.lp-top { display: flex; align-items: center; justify-content: space-between; max-width: 1120px; margin: 0 auto; padding: 18px 20px; }
.lp-brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; font-size: 18px; }
.lp-brand img { width: 34px; height: 34px; }
.btn.ghost { background: transparent; color: var(--primary); box-shadow: none; border: 1px solid var(--outline-variant); }
.btn { text-decoration: none; display: inline-flex; align-items: center; justify-content: center; }
.lp-hero { display: grid; grid-template-columns: 1.05fr 1fr; gap: 24px; align-items: center; max-width: 1120px; margin: 0 auto; padding: 24px 20px 40px; }
.lp-copy { animation: lpin .8s ease-out both; }
.lp-kicker { color: var(--primary); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; font-size: 12px; margin: 0 0 12px; }
.lp-copy h1 { font-size: clamp(30px, 5vw, 52px); line-height: 1.08; margin: 0 0 16px; font-weight: 700; letter-spacing: -.02em; }
.lp-lead { font-size: 18px; line-height: 1.55; color: var(--on-surface-variant); max-width: 34em; margin: 0 0 26px; }
.lp-note { background: color-mix(in srgb, var(--error) 14%, transparent); color: var(--on-surface); border-radius: 10px; padding: 10px 14px; margin: 0 0 18px; }
.lp-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.lp-actions .btn { height: 48px; padding: 0 26px; font-size: 16px; }
.lp-small { color: var(--on-surface-variant); font-size: 13px; margin: 14px 0 0; }
.lp-art { animation: lpin .9s .15s ease-out both; }
.lp-art svg { width: 100%; height: auto; max-height: 460px; display: block; }
.lp-halo { animation: lpbreath 5s ease-in-out infinite; transform-origin: 260px 214px; }
.lp-ring { transform-origin: 260px 214px; animation: lpring 3.6s ease-out infinite; opacity: 0; }
.lp-ring.r2 { animation-delay: 1.8s; }
.lp-lines path { stroke-dasharray: 3 9; animation: lpflow 1.4s linear infinite; }
.lp-scan { animation: lpscan 3s ease-in-out infinite; }
.lp-float { animation: lpfloat 6s ease-in-out infinite; }
.lp-float.f2 { animation-delay: -1.5s; } .lp-float.f3 { animation-delay: -3s; } .lp-float.f4 { animation-delay: -4.5s; }
.lp-dot { animation: lptype 1.4s ease-in-out infinite; }
.lp-dot.d2 { animation-delay: .2s; } .lp-dot.d3 { animation-delay: .4s; }
.lp-call { stroke-dasharray: 30; animation: lpcheck 3.2s ease-in-out infinite; }
.lp-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; max-width: 1120px; margin: 0 auto; padding: 8px 20px 24px; }
.lp-cards article { background: var(--surface-1); border: 1px solid var(--outline-variant); border-radius: 14px; padding: 22px; transition: transform .25s, border-color .25s; }
.lp-cards article:hover { transform: translateY(-4px); border-color: var(--primary); }
.lp-cards h3 { margin: 12px 0 6px; font-size: 18px; }
.lp-cards p { margin: 0; color: var(--on-surface-variant); line-height: 1.5; }
.lp-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--primary) 16%, transparent); color: var(--primary); }
.lp-how { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; max-width: 1120px; margin: 0 auto; padding: 8px 20px 32px; }
.lp-how div { display: flex; align-items: center; gap: 12px; color: var(--on-surface-variant); }
.lp-how b { flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--primary); color: var(--on-primary); display: grid; place-items: center; font-size: 14px; }
.lp-foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; max-width: 1120px; margin: 0 auto; padding: 20px; border-top: 1px solid var(--outline-variant); color: var(--on-surface-variant); font-size: 13px; }
.lp-foot a { color: inherit; }
@keyframes lpin { from { opacity: 0; transform: translateY(16px); } }
@keyframes lpfloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
@keyframes lpring { 0% { transform: scale(.8); opacity: .7; } 100% { transform: scale(2.1); opacity: 0; } }
@keyframes lpbreath { 0%, 100% { opacity: .7; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }
@keyframes lpflow { to { stroke-dashoffset: -24; } }
@keyframes lpscan { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(28px); } }
@keyframes lptype { 0%, 60%, 100% { opacity: .35; } 30% { opacity: 1; } }
@keyframes lpcheck { 0%, 20% { stroke-dashoffset: 30; } 45%, 90% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 30; } }
@media (max-width: 860px) {
  .lp-hero { grid-template-columns: 1fr; padding-top: 8px; }
  .lp-art { order: -1; max-width: 420px; margin: 0 auto; width: 100%; }
  .lp-cards, .lp-how { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { .lp *, .lp-copy, .lp-art { animation: none !important; } .lp-ring { opacity: 0; } }

/* ---- small screens: one pane at a time, navigation at the bottom ---- */
.back { display: none; }
@media (max-width: 760px) {
  .shell { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) 80px; }
  .rail { order: 2; flex-direction: row; justify-content: space-around; padding: 0 8px; border-right: 0; border-top: 1px solid var(--outline-variant); background: var(--surface-2); gap: 0; }
  .rail .logo, .rail .spacer, .rail .rail-extra { display: none; }
  .pane, .thread, .page { grid-column: 1; grid-row: 1; }
  .shell.in-thread .pane { display: none; }
  .shell:not(.in-thread) .thread { display: none; }
  .shell.in-thread .rail { display: none; }
  .shell.in-thread { grid-template-rows: minmax(0, 1fr); }
  .back { display: inline-grid; }
  .msgs { padding: 12px; }
  .m { max-width: 88%; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---- calls ---- */
.callbanner { display: flex; align-items: center; gap: 12px; padding: 8px 16px; background: var(--primary-container); color: var(--on-primary-container); }
.callbanner span { flex: 1; }
.callbanner .btn { height: 32px; padding: 0 16px; }
.callroot { position: fixed; inset: 0; z-index: 40; background: #0f1115; color: #fff; display: flex; flex-direction: column; overflow: hidden; }
.callbg { position: absolute; inset: 0; background: #181b21; z-index: 0; }
.callroot > *:not(.callbg) { position: relative; z-index: 1; }
.callroot > .callover { position: absolute; }
.callroot.alone > .tiles { position: absolute; }
.callhead { padding: 18px 24px; font-size: 17px; text-shadow: 0 1px 6px rgb(0 0 0 / .5); }
.callhead span { opacity: .75; font-variant-numeric: tabular-nums; }
.callwait { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; }
.callwait[hidden] { display: none; }
.pulse { position: relative; width: 150px; height: 150px; display: grid; place-items: center; }
.pulse i { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgb(255 255 255 / .45); animation: ring 2.6s ease-out infinite; }
.pulse i:nth-child(2) { animation-delay: .85s; } .pulse i:nth-child(3) { animation-delay: 1.7s; }
@keyframes ring { from { transform: scale(.7); opacity: .9; } to { transform: scale(1.7); opacity: 0; } }
.pulse .avatar { width: 112px; height: 112px; border-radius: 50%; display: grid; place-items: center; font-size: 40px; font-weight: 700; background: #2f6fed; }
.waitname { font-size: 26px; font-weight: 700; text-shadow: 0 2px 10px rgb(0 0 0 / .5); }
.waitstate { opacity: .8; animation: fade 1.6s ease-in-out infinite alternate; }
@keyframes fade { from { opacity: .45; } to { opacity: .95; } }
.tiles { flex: 1; display: grid; gap: 12px; padding: 0 16px 8px; min-height: 0; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); grid-auto-rows: 1fr; }
.tiles[data-count="1"] { grid-template-columns: 1fr; }
.callroot.alone .tiles { position: absolute; right: 16px; bottom: 120px; width: 120px; height: 168px; padding: 0; display: block; z-index: 3; flex: none; }
.callroot.alone .tile { height: 100%; }
.tile { position: relative; background: #20242a; border-radius: 12px; overflow: hidden; min-height: 0; animation: tilein .35s ease-out; }
@keyframes tilein { from { opacity: 0; transform: scale(.94); } }
.tile video { width: 100%; height: 100%; object-fit: cover; background: #20242a; }
.tile.off video { opacity: .15; }
.tile .initials { display: none; position: absolute; inset: 0; place-items: center; font-size: 44px; font-weight: 700; color: rgb(255 255 255 / .85); }
.tile.novideo .initials { display: grid; }
.tile.novideo video { visibility: hidden; }
.tile .who { position: absolute; left: 12px; bottom: 10px; background: rgb(0 0 0 / .5); backdrop-filter: blur(6px); padding: 2px 10px; border-radius: 12px; font-size: 13px; }
.tile[data-state="failed"], .tile[data-state="disconnected"] { outline: 2px solid #ff6b6b; }
.callbanner2 { align-self: center; margin-bottom: 6px; padding: 6px 16px; border-radius: 20px; background: rgb(255 170 0 / .92); color: #1a1200; font-weight: 600; box-shadow: 0 4px 14px rgb(0 0 0 / .4); animation: fade 1s ease-in-out infinite alternate; }
.callbanner2[hidden] { display: none; }
.callpick { position: absolute; inset: 0; z-index: 8; display: grid; place-items: center; background: rgb(12 13 16 / .6); }
.callpick[hidden] { display: none; }
.pickbox { width: min(360px, 92vw); max-height: 70vh; display: flex; flex-direction: column; background: #20242a; border: 1px solid #30353d; border-radius: 12px; padding: 14px; box-shadow: 0 12px 32px rgb(0 0 0 / .5); }
.pickhead { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.pickhead .icon-btn { width: 34px; height: 34px; color: #fff; }
.picklist { overflow-y: auto; display: flex; flex-direction: column; gap: 4px; }
.pickrow { display: flex; align-items: center; gap: 12px; border: 0; border-radius: 8px; background: transparent; color: #fff; padding: 8px; text-align: left; font-size: 15px; }
.pickrow:hover { background: rgb(255 255 255 / .08); }
.pickrow:disabled { opacity: .5; }
.pickavatar { width: 36px; height: 36px; border-radius: 50%; background: #2f6fed; display: grid; place-items: center; font-weight: 700; }
.picknote { min-height: 22px; margin-top: 8px; color: #9db8f5; font-size: 13px; }
/* a phone: six buttons must fit in a row, and the docked call may use the width of the screen */
@media (max-width: 520px) {
  .callbar { gap: 8px; padding: 10px 6px 18px; flex-wrap: wrap; }
  .callbar .icon-btn { width: 50px; height: 50px; }
  .callbar .icon-btn.end { width: 64px; }
  .callhead { padding: 12px 14px; font-size: 16px; }
  .tiles { grid-template-columns: 1fr; padding: 0 10px 6px; gap: 8px; }
  .pickbox { width: 94vw; }
  .callroot.docked { inset: auto 8px 8px auto; width: calc(100vw - 16px); height: 230px; }
  .callroot.docked .tiles { grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); }
  .callroot.docked .callbar .icon-btn { width: 40px; height: 40px; }
  .new-menu { right: 8px; left: 8px; min-width: 0; }
}
/* docked: the call shrinks to a small window in the corner, so the chat of the call can be used beside it */
#undock { display: none; width: 30px; height: 30px; margin-left: auto; color: #fff; }
.callroot.docked { inset: auto 16px 16px auto; width: 380px; height: 260px; border-radius: 14px; border: 1px solid #30353d; box-shadow: 0 12px 32px rgb(0 0 0 / .5); }
.callroot.docked #undock { display: inline-grid; }
.callroot.docked .callhead { padding: 6px 10px; font-size: 13px; display: flex; align-items: center; gap: 6px; }
.callroot.docked .tiles { padding: 0 8px 4px; gap: 6px; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
.callroot.docked .tile { border-radius: 8px; }
.callroot.docked .tile .initials { font-size: 24px; }
.callroot.docked .callwait .pulse { transform: scale(.5); margin: -30px 0; }
.callroot.docked .waitname { font-size: 16px; }
.callroot.docked .callbar { padding: 4px 0 8px; gap: 8px; }
.callroot.docked .callbar .icon-btn { width: 38px; height: 38px; }
.callroot.docked .callbar .icon-btn.end { width: 52px; }
.callroot.docked .callbar .ic { width: 20px; height: 20px; }
.callroot.docked .callshare, .callroot.docked .callbanner2 { font-size: 12px; padding: 3px 10px; }
.new-menu { position: absolute; right: 12px; top: 56px; z-index: 20; min-width: 230px; background: var(--surface-1); border: 1px solid var(--outline-variant); border-radius: 10px; box-shadow: 0 10px 26px rgb(0 0 0 / .3); padding: 5px; animation: menuin .16s ease-out; }
.new-menu button { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; background: transparent; color: var(--on-surface); padding: 10px 12px; border-radius: 7px; font-size: 14px; text-align: left; }
.new-menu button:hover { background: color-mix(in srgb, var(--primary) 12%, transparent); }
.new-menu small { display: block; color: var(--on-surface-variant); font-size: 12px; }
@keyframes menuin { from { opacity: 0; transform: scale(.94) translateY(-4px); } }
.callshare { align-self: center; margin-bottom: 6px; padding: 6px 8px 6px 16px; border-radius: 20px; background: #2f6fed; color: #fff; font-weight: 600; display: flex; align-items: center; gap: 10px; }
.callshare[hidden] { display: none; }
.callshare .btn { height: 28px; padding: 0 12px; background: rgb(255 255 255 / .2); color: #fff; box-shadow: none; }
.tile.screen { grid-column: 1 / -1; }
.tile.screen video { object-fit: contain; background: #000; }
.callbar { display: flex; justify-content: center; gap: 18px; padding: 12px 0 26px; }
.callbar .icon-btn { width: 58px; height: 58px; background: rgb(255 255 255 / .16); color: #fff; transition: transform .15s, background .2s; }
.callbar .icon-btn:hover { transform: translateY(-2px) scale(1.05); }
.callbar .icon-btn:active { transform: scale(.94); }
.callbar .icon-btn.off { background: #fff; color: #101114; }
.callbar .icon-btn.end { background: #d93025; color: #fff; width: 78px; border-radius: 14px; }
.callover { position: absolute; inset: 0; z-index: 9; display: grid; place-items: center; background: rgb(12 13 16 / .85); backdrop-filter: blur(8px); animation: overin .3s ease-out; }
.callover[hidden] { display: none; }
@keyframes overin { from { opacity: 0; } }
.overbox { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 0 24px; animation: pop .4s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes pop { from { transform: scale(.8); opacity: 0; } }
.overicon { width: 84px; height: 84px; flex: none; margin: 0 0 14px; border-radius: 50%; background: #d93025; position: relative; }
.overicon::after { content: ''; position: absolute; left: 22px; top: 40px; width: 40px; height: 6px; border-radius: 3px; background: #fff; }
.callover[data-kind="normal"] .overicon { background: #2f6fed; }
.overtext { font-size: 24px; font-weight: 700; line-height: 1.25; max-width: 320px; overflow-wrap: anywhere; }

/* ---- files ---- */
.crumbs { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; margin: 8px 0 12px; }
.crumb { border: 0; background: transparent; color: var(--primary); padding: 4px 8px; border-radius: 12px; font-weight: 500; }
.crumb:hover { background: color-mix(in srgb, var(--primary) 8%, transparent); }
.crumbs .sep { color: var(--on-surface-variant); }
.frow { min-height: 52px; cursor: default; }
.frow .fi { color: var(--primary); display: grid; place-items: center; width: 40px; }
.frow .fname { flex: 1; min-width: 0; border: 0; background: transparent; text-align: left; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 8px 4px; border-radius: 8px; }
.frow .fname:hover { text-decoration: underline; }
.frow .fmeta { color: var(--on-surface-variant); font-size: 13px; width: 84px; text-align: right; }
.frow .facts { display: flex; opacity: 0; transition: opacity .15s; }
.frow:hover .facts, .frow:focus-within .facts { opacity: 1; }
@media (max-width: 760px) { .frow .facts { opacity: 1; } .frow .fdate { display: none; } }
.appbar .btn { height: 36px; padding: 0 16px; }

/* groups and companies */
.dialog.wide { width: min(560px, 100%); max-height: 90vh; overflow: auto; }
.dialog .check { display: flex; align-items: center; gap: 10px; margin-top: 16px; font-size: 15px; }
.dialog .sel { display: flex; flex-direction: column; gap: 4px; margin-top: 16px; font-size: 13px; color: var(--on-surface-variant); }
.dialog select, .page select { font: inherit; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--outline); background: var(--surface); color: var(--on-surface); min-width: 160px; }
.dialog .list-card { margin-top: 8px; }
