/* ============ fonts ============ */
/* Montserrat 6.001: the version Ingage uses (newer versions are about 3% wider and wrap differently). */
@font-face { font-family: 'NTR Montserrat'; font-weight: 400; font-style: normal; font-display: swap; src: url('https://cdn.jsdelivr.net/gh/JulietaUla/Montserrat@6.001/fonts/webfonts/Montserrat-Regular.woff2') format('woff2'); }
@font-face { font-family: 'NTR Montserrat'; font-weight: 500; font-style: normal; font-display: swap; src: url('https://cdn.jsdelivr.net/gh/JulietaUla/Montserrat@6.001/fonts/webfonts/Montserrat-Medium.woff2') format('woff2'); }
@font-face { font-family: 'NTR Montserrat'; font-weight: 600; font-style: normal; font-display: swap; src: url('https://cdn.jsdelivr.net/gh/JulietaUla/Montserrat@6.001/fonts/webfonts/Montserrat-SemiBold.woff2') format('woff2'); }
@font-face { font-family: 'NTR Montserrat'; font-weight: 700; font-style: normal; font-display: swap; src: url('https://cdn.jsdelivr.net/gh/JulietaUla/Montserrat@6.001/fonts/webfonts/Montserrat-Bold.woff2') format('woff2'); }
@font-face { font-family: 'NTR Montserrat'; font-weight: 800; font-style: normal; font-display: swap; src: url('https://cdn.jsdelivr.net/gh/JulietaUla/Montserrat@6.001/fonts/webfonts/Montserrat-ExtraBold.woff2') format('woff2'); }
@font-face { font-family: 'NTR Montserrat'; font-weight: 400; font-style: italic; font-display: swap; src: url('https://cdn.jsdelivr.net/gh/JulietaUla/Montserrat@6.001/fonts/webfonts/Montserrat-Italic.woff2') format('woff2'); }
@font-face { font-family: 'NTR Montserrat'; font-weight: 700; font-style: italic; font-display: swap; src: url('https://cdn.jsdelivr.net/gh/JulietaUla/Montserrat@6.001/fonts/webfonts/Montserrat-BoldItalic.woff2') format('woff2'); }

/* ============ tokens ============ */
:root {
  --bg: #f3f4f6; --surface: #ffffff; --surface-2: #f8f9fa; --ink: #1c2226; --muted: #5b666e; --line: #e1e5e9; --line-2: #cfd5da;
  --accent: #e5372b; --accent-hover: #c92c21; --accent-ink: #ffffff; --accent-soft: #fdecea;
  --side: #1a2228; --side-2: #232d34; --side-ink: #eef2f4; --side-muted: #93a1ab;
  --ok: #1d7f45; --ok-soft: #e4f4ea; --warn: #9a6a00; --warn-soft: #fff4d6; --danger: #c0271d;
  --bar: #2b6cb0; --grid: #e6e9ec; --shadow: 0 1px 2px rgba(16, 24, 32, .06), 0 4px 14px rgba(16, 24, 32, .06);
  --r: 12px; --ui: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --brand: 'NTR Montserrat', 'Montserrat', 'Helvetica Neue', Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101417; --surface: #192025; --surface-2: #1f272d; --ink: #e7ecef; --muted: #9ba7af; --line: #2a333a; --line-2: #3a454d;
    --accent-soft: #3a1a18; --side: #0b0f12; --side-2: #151c21; --ok: #4cc27d; --ok-soft: #173325; --warn: #e0b54a; --warn-soft: #3a2f12; --danger: #ff6b5f;
    --bar: #5b9fe0; --grid: #2a333a; --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 6px 18px rgba(0, 0, 0, .35);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--ink); font: 15px/1.45 var(--ui); -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; overscroll-behavior: none; }
body.presenting, body.editing { overflow: hidden; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: var(--accent); }
h1, h2, h3, h4 { font-family: var(--brand); margin: 0; letter-spacing: -.01em; text-wrap: balance; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.strong { font-weight: 600; }
.err { color: var(--danger); min-height: 1em; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.tight { gap: 6px; flex-wrap: nowrap; }
.row.wrap { flex-wrap: wrap; }
.stack { display: grid; gap: 12px; }
.right { text-align: right; }
.loading { padding: 40px 0; color: var(--muted); }

/* ============ controls ============ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font-weight: 600; font-size: 14px; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s; }
.btn:hover { background: var(--surface-2); }
.btn:disabled { opacity: .5; cursor: default; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { background: var(--accent-hover); }
.btn.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.small { min-height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.danger-text { color: var(--danger) !important; }
.icon-btn { display: inline-grid; place-items: center; min-width: 32px; height: 32px; padding: 0 6px; border-radius: 8px; border: 0; background: transparent; color: var(--muted); font-size: 15px; }
.icon-btn:hover { background: var(--surface-2); color: var(--ink); }
.icon-btn:disabled { opacity: .35; }
.icon-btn.small { height: 26px; min-width: 26px; font-size: 13px; }
.field { width: 100%; min-height: 42px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font: inherit; }
.field:focus { outline: 2px solid color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 1px; border-color: var(--accent); }
.field.compact { min-height: 34px; padding: 5px 9px; border-radius: 8px; font-size: 14px; }
.field.mono { font: 13px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; }
select.field { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 55%, calc(100% - 13px) 55%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
.lbl { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.check { display: flex; gap: 10px; align-items: center; font-size: 14px; }
.check input { width: 20px; height: 20px; accent-color: var(--accent); }
.seg { display: inline-flex; padding: 3px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; padding: 7px 12px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--muted); }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.seg.small button { padding: 5px 9px; font-size: 12px; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 99px; font-size: 12px; font-weight: 600; }
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.wait { background: var(--warn-soft); color: var(--warn); }
.progress { height: 8px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; }
.progress-fill { height: 100%; width: 0; background: var(--accent); transition: width .25s; }
.spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; display: inline-block; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.log { margin: 12px 0 0; padding-left: 20px; display: grid; gap: 4px; font-size: 14px; }

/* ============ dialogs, menus, toasts ============ */
.dlg-wrap { position: fixed; inset: 0; z-index: 1000; background: rgba(10, 14, 18, .45); display: grid; place-items: center; padding: 16px; animation: fade .15s; }
.dlg { width: min(440px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: var(--surface); color: var(--ink); border-radius: 16px; padding: 22px; box-shadow: 0 20px 60px rgba(0, 0, 0, .3); }
.dlg.wide { width: min(620px, 100%); }
.dlg-title { font-size: 19px; margin-bottom: 12px; }
.dlg-body p { margin: 0 0 8px; }
.dlg-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.popmenu { position: fixed; z-index: 1100; min-width: 190px; background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; padding: 6px; box-shadow: 0 12px 40px rgba(0, 0, 0, .2); display: grid; animation: fade .12s; }
.popmenu button { text-align: left; border: 0; background: transparent; padding: 10px 12px; border-radius: 8px; font-size: 14px; }
.popmenu button:hover { background: var(--surface-2); }
.popmenu button.danger { color: var(--danger); }
.toasts { position: fixed; left: 50%; bottom: max(24px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 2000; display: grid; gap: 8px; pointer-events: none; }
.toast { background: #1c2226; color: #fff; padding: 11px 18px; border-radius: 12px; font-size: 14px; box-shadow: 0 8px 30px rgba(0, 0, 0, .3); transition: opacity .4s, transform .4s; text-align: center; }
.toast.ok { background: #17663a; }
.toast.out { opacity: 0; transform: translateY(8px); }
.toast.undo { pointer-events: auto; display: flex; align-items: center; gap: 16px; }
.toast-btn { border: 0; background: transparent; color: #ffb3ab; font-weight: 700; font-size: 14px; padding: 4px 2px; }
@keyframes fade { from { opacity: 0; } }

/* ============ sign-in ============ */
#app { min-height: 100%; }
.gate { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 24px max(16px, env(safe-area-inset-right)) 24px max(16px, env(safe-area-inset-left)); background: radial-gradient(1200px 600px at 20% -10%, #2a353d 0%, transparent 60%), var(--side); }
.gate-card { width: min(420px, 100%); background: var(--surface); color: var(--ink); border-radius: 20px; padding: 32px 28px; box-shadow: 0 30px 80px rgba(0, 0, 0, .35); display: grid; gap: 14px; }
.gate-card h1 { font-size: 24px; margin-top: 8px; }
.gate-card p { margin: 0; }
.gate .brand { color: var(--ink); }
.gate .brand-sub { color: var(--muted); }
.btn.google { min-height: 50px; font-size: 16px; background: var(--surface); border: 1px solid var(--line-2); }
.btn.google .g { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; background: conic-gradient(#ea4335 0 25%, #fbbc05 0 50%, #34a853 0 75%, #4285f4 0); font-family: Arial, sans-serif; font-size: 15px; }

/* ============ app shell ============ */
.shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100%; }
.side { background: var(--side); color: var(--side-ink); display: flex; flex-direction: column; padding: max(18px, env(safe-area-inset-top)) 14px max(16px, env(safe-area-inset-bottom)) max(14px, env(safe-area-inset-left)); position: sticky; top: 0; height: 100vh; height: 100dvh; }
.brand { display: flex; gap: 12px; align-items: center; padding: 4px 6px 18px; }
.brand-logo { width: 40px; height: 40px; border-radius: 10px; }
.brand-name { font-family: var(--brand); font-weight: 700; font-size: 15px; line-height: 1.2; }
.brand-sub { font-size: 12px; color: var(--side-muted); text-transform: uppercase; letter-spacing: .08em; }
.side-nav { display: grid; gap: 4px; }
.side-link { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 10px; color: var(--side-ink); text-decoration: none; font-weight: 600; font-size: 15px; opacity: .82; }
.side-link:hover { background: var(--side-2); opacity: 1; }
.side-link.on { background: var(--side-2); opacity: 1; box-shadow: inset 3px 0 0 var(--accent); }
.side-ic { width: 22px; text-align: center; color: var(--side-muted); }
.side-link.on .side-ic { color: var(--accent); }
.side-foot { margin-top: auto; display: grid; gap: 12px; }
.side-off { font-size: 12px; color: var(--side-muted); padding: 8px 10px; border-radius: 8px; background: var(--side-2); }
.side-off.ok { color: #8fd7a8; }
.side-user { display: flex; gap: 10px; align-items: center; padding: 4px 6px; }
.side-user img, .av { width: 34px; height: 34px; border-radius: 50%; flex: none; }
.av { display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 700; }
.su-name { font-weight: 600; font-size: 14px; line-height: 1.2; word-break: break-all; }
.su-role { font-size: 12px; color: var(--side-muted); }
.side-signout { border: 1px solid #33414b; background: transparent; color: var(--side-ink); border-radius: 9px; padding: 8px; font-size: 13px; }
.main { min-width: 0; }
.page { padding: max(28px, env(safe-area-inset-top)) max(24px, env(safe-area-inset-right)) 48px 28px; max-width: 1240px; }
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 8px; }
.page-head h1 { font-size: 28px; }
.search { width: 240px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 10px 0 20px; }
.tab { padding: 10px 14px; text-decoration: none; color: var(--muted); font-weight: 600; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab.on { color: var(--ink); border-bottom-color: var(--accent); }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; margin-bottom: 18px; box-shadow: var(--shadow); min-width: 0; }
.panel h2 { font-size: 17px; margin-bottom: 8px; }
.panel h3 { font-size: 14px; margin: 18px 0 8px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; font-family: var(--ui); }
.panel > p { margin: 0 0 14px; }
.two-col { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 18px; }
.two-col .panel { margin-bottom: 0; }
.two-col + .panel { margin-top: 18px; }

/* library */
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; margin-top: 18px; }
.lib-group { margin-top: 30px; }
.page-head + .lib-group, .page-head + * + .lib-group { margin-top: 18px; }
.lib-group-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.lib-group-head h2 { font-size: 19px; }
.lib-group-head p { margin: 3px 0 0; }
.lib-all { font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.lib-group .lib-grid { margin-top: 16px; }
.lib-empty { margin-top: 14px; padding: 18px 20px; border: 1px dashed var(--line-2); border-radius: 12px; color: var(--muted); font-size: 14px; max-width: 640px; }
.card-text { min-width: 0; display: grid; gap: 2px; justify-items: start; }
.card-text .pill { margin-top: 7px; background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.card-text .pill.private { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.side-groups { display: grid; gap: 1px; margin: -2px 0 6px; }
.side-link.sub { padding: 7px 12px 7px 46px; font-size: 14px; font-weight: 500; }
.side-label { flex: 1; min-width: 0; }
.side-count { font-size: 12px; color: var(--side-muted); background: rgba(255, 255, 255, .07); border-radius: 99px; padding: 1px 8px; font-weight: 600; }
.side-install { border: 1px solid #33414b; background: var(--side-2); color: var(--side-ink); border-radius: 9px; padding: 9px; font-size: 13px; font-weight: 600; }
.side-install:hover { background: #2c3840; }
.linkish { border: 0; background: none; color: var(--accent); font-weight: 600; padding: 6px 0; justify-self: center; }
.steps { margin: 0; padding-left: 22px; display: grid; gap: 8px; }
.copyrow { display: flex; gap: 8px; }
.copyrow .field { flex: 1; min-width: 0; }
.grid2.gap { gap: 12px; }
.btn.big { min-height: 52px; font-size: 17px; }
.gate.cust .gate-card { width: min(480px, 100%); }
@media (max-width: 520px) { .dlg .grid2 { grid-template-columns: minmax(0, 1fr); } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); }
.card-cover { position: relative; display: block; width: 100%; padding: 0; border: 0; background: #0d1114; aspect-ratio: 4 / 3; overflow: hidden; }
.card-cover .thumb { width: 100% !important; height: 100% !important; border-radius: 0; }
.thumb.blank { width: 100%; height: 100%; background: linear-gradient(135deg, #2a343b, #1a2228); }
.card-play { position: absolute; left: 12px; bottom: 12px; background: rgba(0, 0, 0, .62); color: #fff; padding: 7px 12px; border-radius: 99px; font-size: 13px; font-weight: 600; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); opacity: 0; transform: translateY(4px); transition: .18s; }
.card-cover:hover .card-play, .card-cover:focus-visible .card-play { opacity: 1; transform: none; }
@media (hover: none) { .card-play { opacity: 1; transform: none; } }
.card-meta { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; padding: 14px 14px 16px 16px; }
.card-title { font-family: var(--brand); font-weight: 700; font-size: 16px; }
.card-sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.card-more { border: 0; background: transparent; color: var(--muted); font-size: 16px; padding: 4px 8px; border-radius: 8px; letter-spacing: 1px; }
.card-more:hover { background: var(--surface-2); }
.empty { grid-column: 1 / -1; text-align: center; padding: 60px 20px; border: 1.5px dashed var(--line-2); border-radius: 16px; display: grid; gap: 10px; justify-items: center; }
.empty h3 { font-size: 20px; }
.empty p { margin: 0 0 8px; }

/* tables */
.table-wrap { overflow-x: auto; margin: 0 -4px; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 11px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.who { display: flex; gap: 10px; align-items: center; }
.who img { width: 34px; height: 34px; border-radius: 50%; }

/* manage */
.invite { display: grid; grid-template-columns: minmax(0, 1fr) 150px auto; gap: 10px; }
.edit-row { display: flex; gap: 10px; align-items: flex-end; margin-bottom: 10px; }
.edit-row .grow { flex: 1; min-width: 0; }
.w120 { width: 130px; } .w160 { width: 170px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 14px 0; }
.panel .lbl + .grid3, .panel .lbl { margin-bottom: 4px; }
.plan-edit { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; background: var(--surface-2); }
.plan-edit.off { opacity: .6; }
.plan-edit-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.grid-plan { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.grid-plan .span2 { grid-column: span 2; }
.savebar { position: sticky; top: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; margin: 0 0 16px; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--line); border-radius: 12px; }

/* analytics */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 18px 0; }
.kpis.small { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; box-shadow: var(--shadow); min-width: 0; }
.kpi-label { font-size: 13px; color: var(--muted); font-weight: 600; }
.kpi-value { font-family: var(--brand); font-size: 30px; font-weight: 700; margin: 4px 0 2px; font-variant-numeric: tabular-nums; }
.kpis.small .kpi-value { font-size: 24px; }
.kpi-sub { font-size: 12px; }
.chg { font-weight: 700; }
.chg.up { color: var(--ok); } .chg.down { color: var(--danger); } .chg.flat { color: var(--muted); }
.chart-wrap { position: relative; }
.chart { width: 100%; height: auto; display: block; }
.chart .grid { stroke: var(--grid); stroke-width: 1; }
.chart .axis { fill: var(--muted); font-size: 11px; font-family: var(--ui); }
.chart .bar { fill: var(--bar); }
.chart .hit { fill: transparent; cursor: pointer; outline: none; }
.chart .hit:hover, .chart .hit:focus { fill: color-mix(in srgb, var(--ink) 6%, transparent); }
.chart-tip { position: absolute; transform: translate(-50%, -120%); background: var(--ink); color: var(--surface); font-size: 12px; font-weight: 600; padding: 5px 9px; border-radius: 7px; pointer-events: none; white-space: nowrap; }
.slide-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.sb-top { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; }
.sb-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-val { font-variant-numeric: tabular-nums; color: var(--muted); }
.sb-track { height: 8px; background: var(--surface-2); border-radius: 99px; margin: 5px 0 3px; overflow: hidden; }
.sb-fill { height: 100%; background: var(--bar); border-radius: 99px; }

@media (max-width: 1000px) {
  .two-col { grid-template-columns: minmax(0, 1fr); }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-plan { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px; padding: max(10px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) 10px max(12px, env(safe-area-inset-left)); }
  .brand { padding: 0 6px 0 0; }
  .brand-sub { display: none; }
  .side-nav { display: flex; gap: 2px; order: 3; width: 100%; overflow-x: auto; }
  .side-link { padding: 8px 12px; font-size: 14px; white-space: nowrap; flex: none; }
  .side-groups { display: contents; }
  .side-link.sub { padding: 8px 12px; }
  .side-install { padding: 6px 10px; }
  .side-foot { margin: 0 0 0 auto; display: flex; align-items: center; gap: 8px; }
  .side-off, .su-role, .su-name { display: none; }
  .page { padding: 18px max(16px, env(safe-area-inset-right)) 40px max(16px, env(safe-area-inset-left)); }
  .invite { grid-template-columns: minmax(0, 1fr); }
  .grid3, .kpis.small { grid-template-columns: minmax(0, 1fr); }
  .search { width: 100%; }
}

/* ============ slides ============ */
.pg { position: relative; overflow: hidden; flex: none; color: #343434; }
.it { position: absolute; }
.it > img, .it > .vid, .it > .vid > video, .it > .car, .it > .ic, .it > .missing, .it > .vid-ph { position: absolute; inset: 0; width: 100%; height: 100%; }
.it, .it > img, .it > .vid, .it > .tx { border-radius: inherit; }
.it-image, .it-video, .it-box, .it-carousel, .it-icon { overflow: hidden; }
.it > img, .it > .vid > video { display: block; object-fit: cover; }
.vid { overflow: hidden; background: #000; }
.vid-play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 84px; height: 84px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .55); color: #fff; font-size: 34px; padding-left: 6px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.vid-snd { position: absolute; right: 14px; bottom: 14px; width: 46px; height: 46px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .5); color: #fff; font-size: 20px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.vid-ph { display: grid; place-items: center; background: #1a1f23; color: rgba(255, 255, 255, .7); font-size: 40px; }
/* Text is never clipped: like Ingage, a line taller than its box spills evenly above and below it. */
.tx { position: absolute; inset: 0; display: flex; flex-direction: column; overflow: visible; overflow-wrap: break-word; }
.tx-body { outline: none; }
.tx-body p { margin: 0 0 var(--pgap, 0); }
.tx-body p:last-child, .tx-body li:last-child { margin-bottom: 0; }
.tx-body ul, .tx-body ol { margin: 0 0 var(--pgap, 0); padding-left: 1.2em; }
.tx-body li { margin: 0 0 var(--pgap, 0); padding-left: .1em; }
.tx-body li::marker { font-size: .9em; }
.tx-body[contenteditable="true"] { cursor: text; caret-color: #e5372b; min-height: 1em; }
.ic { display: grid; place-items: center; }
.it.glass { border-radius: 50%; background: rgba(255, 255, 255, .26); backdrop-filter: blur(14px) saturate(1.3); -webkit-backdrop-filter: blur(14px) saturate(1.3); box-shadow: 0 2px 10px rgba(0, 0, 0, .18); }
.missing { display: grid; place-items: center; background: repeating-linear-gradient(45deg, #eef0f2 0 12px, #e4e7ea 12px 24px); color: #6b7680; font: 600 18px var(--ui); border: 2px dashed #b9c1c8; }
.car { overflow: hidden; }
.car-holder { position: absolute; inset: 0; }
.car-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .45); color: #fff; font-size: 30px; line-height: 1; z-index: 2; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.car-btn.prev { left: 14px; } .car-btn.next { right: 14px; }
.car-dots { position: absolute; left: 0; right: 0; bottom: 14px; display: flex; gap: 8px; justify-content: center; z-index: 2; }
.car-dots i { width: 9px; height: 9px; border-radius: 50%; background: rgba(0, 0, 0, .25); }
.car-dots i.on { background: rgba(0, 0, 0, .7); }
.thumb { position: relative; overflow: hidden; background: #fff; border-radius: 4px; flex: none; }
.thumb .pg { position: absolute; left: 0; top: 0; pointer-events: none; }
.pr-ph { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 8px; background: #f7f8f9; }
.pr-ph-title { font: 700 36px var(--brand); color: #343434; }
.pr-ph-sub { font: 500 20px var(--brand); color: #6b7680; }
.act { cursor: pointer; }
.pres .act:active { filter: brightness(.92); }
.pres .act.pulse::after { content: ''; position: absolute; inset: 0; border-radius: inherit; box-shadow: 0 0 0 0 rgba(255, 255, 255, .55); animation: pulse 2.4s ease-out infinite; pointer-events: none; }
.pres .it-text.act.pulse::after { box-shadow: 0 0 0 0 rgba(229, 55, 43, .45); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, .55); } 70%, 100% { box-shadow: 0 0 0 14px rgba(255, 255, 255, 0); } }
@media (prefers-reduced-motion: reduce) { .pres .act.pulse::after { animation: none; } }

/* ============ presenting ============ */
.pres { position: fixed; inset: 0; z-index: 500; background: #000; display: grid; place-items: center; outline: none; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.pres-frame { position: relative; overflow: hidden; background: #fff; --k: 1; }
.pres-slides { position: absolute; inset: 0; }
.pres-slides > .pg { position: absolute; left: 0; top: 0; transition: transform .36s cubic-bezier(.2, .7, .2, 1), opacity .36s; }
.pres-slides > .pg.enter.from-r { translate: 100% 0; }
.pres-slides > .pg.enter.from-l { translate: -100% 0; }
.pres-slides > .pg.enter { transition: translate .36s cubic-bezier(.2, .7, .2, 1); }
.pres-slides > .pg.leave { transition: translate .36s cubic-bezier(.2, .7, .2, 1), opacity .36s; opacity: .6; }
.pres-slides > .pg.leave.to-l { translate: -30% 0; }
.pres-slides > .pg.leave.to-r { translate: 30% 0; }
.pres-bar { position: absolute; left: 0; right: 0; bottom: 0; height: calc(63px * var(--k)); min-height: 44px; display: flex; align-items: center; gap: calc(8px * var(--k)); padding: 0 calc(10px * var(--k)); background: rgba(12, 12, 12, .62); backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4); color: #fff; z-index: 20; }
.pres-bar button { border: 0; background: transparent; color: #fff; }
.pres-x, .pres-more { width: calc(44px * var(--k)); min-width: 36px; height: calc(44px * var(--k)); min-height: 36px; border-radius: 50%; display: grid; place-items: center; font-size: max(15px, calc(19px * var(--k))); flex: none; }
.pres-x:hover, .pres-more:hover, .pres-arrow:hover:not(:disabled) { background: rgba(255, 255, 255, .14); }
.pres-more { display: flex; gap: 3px; align-items: center; justify-content: center; }
.pres-more i { width: 4px; height: 4px; border-radius: 50%; background: #fff; }
.pres-tabs { flex: 1; min-width: 0; display: flex; gap: calc(4px * var(--k)); overflow-x: auto; scrollbar-width: none; mask-image: linear-gradient(90deg, transparent 0, #000 12px, #000 calc(100% - 12px), transparent 100%); padding: 0 6px; }
.pres-tabs::-webkit-scrollbar { display: none; }
.pres-tab { flex: none; padding: calc(9px * var(--k)) calc(14px * var(--k)); border-radius: calc(8px * var(--k)); font: 600 max(11px, calc(13px * var(--k))) / 1 var(--brand); letter-spacing: .04em; text-transform: uppercase; opacity: .82; white-space: nowrap; }
.pres-tab.on { background: #343434; opacity: 1; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); }
.pres-arrows { display: flex; gap: 2px; flex: none; }
.pres-arrow { width: calc(46px * var(--k)); min-width: 38px; height: calc(44px * var(--k)); min-height: 36px; border-radius: calc(10px * var(--k)); font-size: max(26px, calc(34px * var(--k))); line-height: 1; padding-bottom: 4px; }
.pres-arrow:disabled { opacity: .3; }
.pres-layer { position: absolute; inset: 0; z-index: 30; pointer-events: none; }
.pres-layer.open { pointer-events: auto; }
.pres-scrim { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0, 0, 0, .5); animation: fade .2s; }
.pres-scrim.clear { background: transparent; }
.pres-popup { position: relative; overflow: hidden; background: #fff; box-shadow: 0 2px 20px rgba(0, 0, 0, .3), 0 20px 60px rgba(0, 0, 0, .25); animation: slideup .32s cubic-bezier(.2, .8, .2, 1); }
.pres-popup > .pg { position: absolute; left: 0; top: 0; }
@keyframes slideup { from { transform: translateY(40px); opacity: 0; } }
.pres-popx { position: absolute; top: 12px; right: 12px; z-index: 5; width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(30, 30, 30, .55); color: #fff; font-size: 16px; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.pres-popx.static { position: static; flex: none; }
.gal { position: relative; width: 94%; height: 90%; display: grid; grid-template-rows: auto minmax(0, 1fr) auto auto; gap: 10px; background: #0f1215; color: #fff; border-radius: 16px; padding: 16px; box-shadow: 0 20px 60px rgba(0, 0, 0, .4); animation: slideup .3s; }
.gal-title { font: 700 22px var(--brand); padding-right: 48px; }
.gal-stage { position: relative; min-height: 0; overflow: hidden; }
.gal-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.gal-btn { z-index: 1; }
.gal-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 54px; height: 54px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; font-size: 34px; }
.gal-btn.prev { left: 6px; } .gal-btn.next { right: 6px; }
.gal-cap { text-align: center; font-size: 15px; min-height: 1em; color: rgba(255, 255, 255, .85); }
.gal-dots { display: flex; justify-content: center; gap: 8px; }
.gal-dots i { width: 8px; height: 8px; border-radius: 50%; background: rgba(255, 255, 255, .3); }
.gal-dots i.on { background: #fff; }
.doc { width: 96%; height: 94%; display: grid; grid-template-rows: auto minmax(0, 1fr); background: #2a2f33; border-radius: 14px; overflow: hidden; box-shadow: 0 20px 60px rgba(0, 0, 0, .45); animation: slideup .3s; }
.doc-head { display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 18px; background: #1b1f22; color: #fff; }
.doc-name { flex: 1; min-width: 0; font: 600 15px var(--brand); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: capitalize; }
.doc-z, .doc-x { width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .12); color: #fff; font-size: 20px; }
.doc-x { font-size: 16px; }
.doc-scroll { overflow: auto; -webkit-overflow-scrolling: touch; padding: 16px; touch-action: pan-x pan-y; }
.doc-wait { height: 100%; display: grid; place-content: center; justify-items: center; gap: 14px; color: rgba(255, 255, 255, .85); text-align: center; }
.pdf-col { width: 100%; max-width: none; margin: 0 auto; display: grid; gap: 14px; }
.pdf-page { position: relative; width: 100%; background: #fff; box-shadow: 0 2px 10px rgba(0, 0, 0, .35); }
.pdf-page canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.pdf-num { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); color: #b5bcc2; font: 600 22px var(--ui); }
.pres-menu { position: absolute; right: calc(70px * var(--k)); bottom: calc(70px * var(--k)); min-width: 260px; background: rgba(28, 28, 30, .92); color: #fff; border-radius: 14px; padding: 6px; display: grid; backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); box-shadow: 0 12px 40px rgba(0, 0, 0, .4); animation: fade .15s; }
.pres-scrim.menu { background: rgba(0, 0, 0, .15); display: block; }
.pres-menu-head { font-size: 12px; color: rgba(255, 255, 255, .6); padding: 8px 12px 6px; }
.pres-menu button { text-align: left; border: 0; background: transparent; color: #fff; padding: 12px 12px; border-radius: 9px; font-size: 15px; }
.pres-menu button:hover { background: rgba(255, 255, 255, .1); }
.pres-scrim.grid { display: block; background: rgba(10, 12, 14, .96); }
.pres-grid { position: absolute; inset: 0; overflow: auto; padding: 18px 22px 40px; color: #fff; }
.pres-grid-head { display: flex; justify-content: space-between; align-items: center; font: 700 20px var(--brand); margin-bottom: 8px; position: sticky; top: -18px; padding: 10px 0; background: rgba(10, 12, 14, .96); z-index: 2; }
.pres-grid-name { font: 600 13px var(--brand); letter-spacing: .08em; color: rgba(255, 255, 255, .6); margin: 16px 0 10px; }
.pres-grid-row { display: flex; flex-wrap: wrap; gap: 14px; }
.pres-grid-item { position: relative; border: 0; padding: 0; background: transparent; border-radius: 6px; }
.pres-grid-item .thumb { border-radius: 6px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .12); }
.pres-grid-item.on .thumb { box-shadow: 0 0 0 3px var(--accent); }
.pres-grid-item > span { position: absolute; left: 6px; bottom: 6px; background: rgba(0, 0, 0, .65); color: #fff; font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 5px; }

/* ============ price slides (drawn on the 1024 x 768 slide; the bottom 63px is under the bar) ============ */
.prk { position: absolute; left: 0; top: 0; width: 100%; height: 705px; padding: 32px 44px 30px; display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 22px; background: #f4f5f7; font-family: var(--brand); color: #343434; }
.prk-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 54px; }
.prk-title { font-size: 34px; font-weight: 700; letter-spacing: -.01em; }
.prk-menu { width: 54px; height: 54px; border-radius: 14px; border: 0; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .12); display: grid; align-content: center; justify-items: center; gap: 6px; flex: none; }
.prk-menu span { width: 24px; height: 3px; border-radius: 2px; background: #343434; }
.prk-card { background: #fff; border-radius: 20px; box-shadow: 0 1px 3px rgba(0, 0, 0, .08), 0 12px 32px rgba(0, 0, 0, .06); padding: 30px 40px 34px; display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 22px; min-height: 0; }
.prk-name { border: 0; border-bottom: 2px solid #e6e8ea; font: 700 32px var(--brand); color: #e5372b; padding: 2px 0 12px; width: 100%; background: transparent; outline: none; border-radius: 0; text-overflow: ellipsis; }
.prk-name:focus { border-bottom-color: #e5372b; }
.prk-cols { display: grid; grid-template-columns: minmax(0, 1fr) 56px minmax(0, 1fr); align-items: start; align-self: center; min-height: 0; padding-bottom: 28px; }
.prk-cols > .prk-or { align-self: stretch; min-height: 210px; }
.prk-col { min-width: 0; display: flex; flex-direction: column; }
.prk-or { position: relative; display: grid; place-items: center; font: 700 15px var(--brand); color: #9aa3aa; text-transform: uppercase; letter-spacing: .1em; }
.prk-or::before { content: ''; position: absolute; top: 8px; bottom: 8px; left: 50%; width: 2px; margin-left: -1px; background: #eceef0; }
.prk-or { z-index: 0; }
.prk-or::after { content: ''; position: absolute; width: 40px; height: 30px; background: #fff; z-index: -1; }
.prk-lbl { font-size: 15px; font-weight: 700; color: #6b7680; text-transform: uppercase; letter-spacing: .08em; }
.prk-numwrap { margin-top: 12px; min-width: 0; }
.prk-price { border: 0; font: 700 64px/1.12 var(--brand); color: #343434; width: 100%; padding: 2px 0 6px; background: transparent; outline: none; letter-spacing: -.02em; border-radius: 0; border-bottom: 3px solid transparent; }
.prk-price::placeholder { color: #c3c8cd; }
.prk-price:focus { border-bottom-color: #e5372b; }
.prk.static .prk-price, .prk.static .prk-name { -webkit-text-fill-color: currentColor; opacity: 1; }
.prk.static .prk-name { color: #e5372b; }
.prk-mo { font: 700 64px/1.12 var(--brand); color: #343434; letter-spacing: -.02em; white-space: nowrap; padding: 2px 0 6px; font-variant-numeric: tabular-nums; }
.prk-mo small { font-size: .42em; font-weight: 600; color: #6b7680; margin-left: 4px; letter-spacing: 0; }
.prk-mo.is-empty { color: #c3c8cd; }
.prk-lines { margin-top: 14px; display: grid; gap: 8px; font-size: 17px; }
.prk-line { display: flex; justify-content: space-between; gap: 10px; color: #4a545b; }
.prk-line b { font-variant-numeric: tabular-nums; }
.prk-line.total { border-top: 2px solid #eceef0; padding-top: 10px; margin-top: 4px; color: #343434; font-size: 19px; }
.prk-save { margin-top: 6px; justify-self: start; display: inline-block; background: #e8f6ee; color: #1d7f45; font-weight: 700; padding: 6px 12px; border-radius: 99px; font-size: 15px; }
.prk-plan { margin-top: 16px; width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; background: #f6f7f8; border: 2px solid transparent; border-radius: 16px; padding: 12px 14px 12px 18px; text-align: left; font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; }
.prk-plan.many { cursor: pointer; }
.prk-plan-chev { width: 36px; height: 36px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .15); display: grid; place-items: center; }
.prk-plan-chev::before { content: ''; width: 9px; height: 9px; border: solid #343434; border-width: 0 2.5px 2.5px 0; transform: translateY(-2px) rotate(45deg); }
.prk-plan.open .prk-plan-chev::before { transform: translateY(2px) rotate(225deg); }
.prk-plan:not(.many) .prk-plan-chev { display: none; }
.prk.static:not(.customer) .prk-plan { pointer-events: none; }
.prk-plan-text { min-width: 0; }
.prk-plan-title { font: 700 18px/1.25 var(--brand); }
.prk-plan-sub { font-size: 14px; color: #6f7a83; margin-top: 4px; }
.prk .nowrap { white-space: nowrap; }
.prk-mo.tap { cursor: pointer; }
.prk-fin { position: absolute; z-index: 11; background: #fff; border-radius: 18px; box-shadow: 0 20px 60px rgba(0, 0, 0, .25), 0 0 0 1px rgba(0, 0, 0, .05); padding: 12px; display: grid; gap: 6px; align-content: start; overflow: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; animation: fade .15s; font-family: var(--brand); color: #343434; }
.prk-fin-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 6px 8px 4px; }
.prk-fin-title { font-size: 20px; font-weight: 700; }
.prk-fin-note { font-size: 14px; color: #6b7680; font-variant-numeric: tabular-nums; }
.prk-fin-lender { font-size: 12px; font-weight: 700; color: #6b7680; text-transform: uppercase; letter-spacing: .08em; padding: 8px 8px 0; }
.prk-fin-row { width: 100%; display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: 12px; text-align: left; border: 2px solid transparent; background: #f6f7f8; border-radius: 12px; padding: 10px 14px 10px 12px; font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; }
.prk-fin-row:hover { background: #eef0f2; }
.prk-fin-row.on { border-color: #e5372b; background: #fff6f5; }
.prk-fin-row .chk { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #c9ced3; display: grid; place-items: center; background: #fff; }
.prk-fin-row.on .chk { border-color: #e5372b; background: #e5372b; }
.prk-fin-row.on .chk::after { content: ''; width: 5px; height: 10px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg) translate(-1px, -1px); }
.prk-fin-txt { display: grid; gap: 3px; min-width: 0; }
.prk-fin-t { font-size: 16px; font-weight: 700; line-height: 1.25; }
.prk-fin-s { font-size: 13px; color: #6f7a83; }
.prk-fin-amt { font-size: 19px; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.prk-fin-amt small { font-size: 12px; font-weight: 600; color: #6b7680; margin-left: 2px; }
.prk-pop { position: absolute; right: 44px; top: 96px; width: 400px; background: #fff; border-radius: 18px; box-shadow: 0 20px 60px rgba(0, 0, 0, .25), 0 0 0 1px rgba(0, 0, 0, .05); padding: 18px; z-index: 10; display: grid; gap: 12px; animation: fade .15s; }
.prk-poptitle { font-size: 20px; font-weight: 700; }
.prk-pop-note { margin: 0; font-size: 13px; color: #7a848c; }
.prk-tog { display: flex; align-items: center; gap: 12px; border: 2px solid #eceef0; background: #fff; border-radius: 12px; padding: 12px 14px; font: 600 16px var(--brand); color: #343434; text-align: left; }
.prk-tog .chk { width: 24px; height: 24px; border-radius: 7px; border: 2px solid #c9ced3; flex: none; display: grid; place-items: center; }
.prk-tog.on { border-color: #e5372b; background: #fff6f5; }
.prk-tog.on .chk { background: #e5372b; border-color: #e5372b; }
.prk-tog.on .chk::after { content: ''; width: 7px; height: 12px; border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(45deg) translate(-1px, -1px); }
.prk-row { display: grid; gap: 8px; font: 600 15px var(--brand); }
.prk-seg { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.prk-seg button { border: 2px solid #eceef0; background: #fff; border-radius: 10px; padding: 10px 0; font: 700 15px var(--brand); color: #343434; }
.prk-seg button.on { border-color: #e5372b; background: #e5372b; color: #fff; }
.prk-dep { border: 2px solid #eceef0; border-radius: 10px; padding: 10px 12px; font: 700 18px var(--brand); color: #343434; outline: none; }
.prk-dep:focus { border-color: #e5372b; }
.prk-popfoot { display: flex; justify-content: space-between; gap: 10px; margin-top: 2px; }
.prk-clear { border: 0; background: transparent; color: #6b7680; font: 600 15px var(--brand); padding: 10px 4px; }
.prk-done { border: 0; background: #343434; color: #fff; font: 700 16px var(--brand); padding: 11px 26px; border-radius: 11px; }
.prk.static .prk-menu, .prk.static .prk-pop { display: none; }

/* ============ editor ============ */
.ed { position: fixed; inset: 0; z-index: 600; background: var(--bg); display: grid; grid-template-rows: auto minmax(0, 1fr); }
.ed-top { display: flex; align-items: center; gap: 12px; padding: max(8px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) 8px max(12px, env(safe-area-inset-left)); background: var(--surface); border-bottom: 1px solid var(--line); }
.ed-title { border: 0; background: transparent; font: 700 16px var(--brand); padding: 6px 10px; border-radius: 8px; max-width: 34vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ed-title:hover { background: var(--surface-2); }
.ed-status { font-size: 13px; color: var(--muted); }
.ed-top-r { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.ed-tb { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-size: 20px; }
.ed-tb:disabled { opacity: .35; }
.ed-tb.wide { width: auto; padding: 0 13px 0 10px; display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; }
.ed-tb.wide span { font-size: 19px; line-height: 1; }
.ed-body { display: grid; grid-template-columns: 172px minmax(0, 1fr) 300px; min-height: 0; }
.ed-list { position: relative; overflow: auto; padding: 10px 10px 40px 14px; border-right: 1px solid var(--line); background: var(--surface); }
.ed-hint { margin: 2px 0 -4px; font-size: 11px; color: var(--muted); }
.ed-list img { -webkit-user-drag: none; user-select: none; pointer-events: none; }
.ed-tile { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; touch-action: pan-y; cursor: grab; }
.ed-tile.dragging { opacity: .3; }
.ed-ghost { position: fixed; left: 0; top: 0; z-index: 2000; display: block; padding: 0; border: 0; border-radius: 6px; background: #fff; pointer-events: none; opacity: .96; box-shadow: 0 0 0 3px var(--accent), 0 14px 34px rgba(0, 0, 0, .3); }
.ed-drop-line { position: absolute; left: 10px; right: 10px; height: 4px; margin-top: -2px; border-radius: 4px; background: var(--accent); box-shadow: 0 0 0 2px var(--surface); pointer-events: none; z-index: 3; }
.ed-empty-sec { margin-bottom: 8px; padding: 16px 8px; border: 1.5px dashed var(--line-2); border-radius: 8px; text-align: center; font-size: 11px; color: var(--muted); }
.ed-sec { display: flex; justify-content: space-between; align-items: center; margin: 14px 0 6px; }
.ed-sec-name { font: 700 11px var(--brand); letter-spacing: .08em; color: var(--muted); text-transform: uppercase; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ed-tile { margin-bottom: 8px; }
.ed-tile-btn { display: block; padding: 0; border: 0; background: transparent; border-radius: 6px; box-shadow: 0 0 0 1px var(--line-2); }
.ed-tile.on .ed-tile-btn { box-shadow: 0 0 0 3px var(--accent); }
.ed-tile.hid .ed-tile-btn { opacity: .45; }
.ed-tile-meta { display: flex; justify-content: space-between; align-items: center; font-size: 11px; color: var(--muted); padding: 2px 0 0 2px; }
.ed-add { width: 100%; border: 1.5px dashed var(--line-2); background: transparent; border-radius: 8px; padding: 7px; font-size: 12px; font-weight: 600; color: var(--muted); }
.ed-add.sec { margin-top: 18px; }
.ed-canvas { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.ed-canvas > .ed-stage { flex: 1 1 0; }
.ed-crumbs { display: flex; align-items: center; gap: 6px; padding: 8px 14px; min-height: 46px; flex-wrap: wrap; }
.crumb { border: 0; background: transparent; padding: 5px 9px; border-radius: 8px; font-weight: 600; font-size: 13px; color: var(--muted); }
.crumb.on { color: var(--ink); background: var(--surface); box-shadow: var(--shadow); }
.crumb-sep { color: var(--muted); }
.crumb-back { margin-left: auto; }
.ed-textbar { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 6px 10px; margin: 0 14px 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.tb { min-width: 36px; height: 34px; border: 0; border-radius: 8px; background: transparent; font-weight: 600; font-size: 14px; padding: 0 8px; }
.tb:hover { background: var(--surface-2); }
.tb.b { font-weight: 800; } .tb.i { font-style: italic; font-family: Georgia, serif; }
.tb.sw { min-width: 26px; width: 26px; height: 26px; border-radius: 50%; padding: 0; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .2); }
.tb-sep { width: 1px; height: 22px; background: var(--line); margin: 0 4px; }
.ed-stage { position: relative; display: grid; place-items: center; min-height: 0; overflow: hidden; background: color-mix(in srgb, var(--bg) 80%, #8a959d 20%); touch-action: none; }
.ed-stage-inner { position: relative; box-shadow: 0 6px 30px rgba(0, 0, 0, .2); background: #fff; }
.ed-stage-inner > .pg { position: absolute; left: 0; top: 0; }
.ed-overlay { position: absolute; pointer-events: none; }
.sel { position: absolute; outline: 2px solid #2f80ed; outline-offset: 0; }
.sel.typing { outline: 2px dashed #2f80ed; }
.hdl { position: absolute; width: 14px; height: 14px; margin: -7px 0 0 -7px; background: #fff; border: 2px solid #2f80ed; border-radius: 4px; pointer-events: auto; touch-action: none; }
.hdl.nw { left: 0; top: 0; cursor: nwse-resize; } .hdl.n { left: 50%; top: 0; cursor: ns-resize; } .hdl.ne { left: 100%; top: 0; cursor: nesw-resize; }
.hdl.e { left: 100%; top: 50%; cursor: ew-resize; } .hdl.se { left: 100%; top: 100%; cursor: nwse-resize; } .hdl.s { left: 50%; top: 100%; cursor: ns-resize; }
.hdl.sw { left: 0; top: 100%; cursor: nesw-resize; } .hdl.w { left: 0; top: 50%; cursor: ew-resize; }
@media (pointer: coarse) { .hdl { width: 22px; height: 22px; margin: -11px 0 0 -11px; } }
.guide { position: absolute; background: #e5372b; }
.guide.v { top: 0; bottom: 0; width: 1px; } .guide.hz { left: 0; right: 0; height: 1px; }
.ed-insp { overflow: auto; padding: 14px 16px 60px; border-left: 1px solid var(--line); background: var(--surface); }
.insp-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.insp-head h3 { font-size: 17px; }
.insp-group { border-top: 1px solid var(--line); padding: 14px 0 12px; display: grid; gap: 10px; }
.insp-group h4 { font: 700 11px var(--ui); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.insp-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); align-items: center; gap: 8px; font-size: 13px; font-weight: 500; }
.insp-row.col { grid-template-columns: minmax(0, 1fr); gap: 6px; }
.insp-row.check { grid-template-columns: auto minmax(0, 1fr); }
.insp-row.check input { width: 18px; height: 18px; accent-color: var(--accent); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.grid2 .insp-row { grid-template-columns: 48px minmax(0, 1fr); }
.swatches { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.sw { width: 26px; height: 26px; border-radius: 50%; border: 0; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .2); padding: 0; }
.sw.on { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); }
.sw.none { background: linear-gradient(135deg, #fff 45%, #e5372b 45% 55%, #fff 55%); }
.swatches input[type="color"] { width: 30px; height: 30px; padding: 0; border: 0; background: transparent; }
.insp-media { display: block; border-radius: 8px; max-height: 120px; object-fit: cover; background: var(--surface-2); }
.insp-media.empty { display: grid; place-items: center; height: 60px; font-size: 12px; color: var(--muted); border: 1px dashed var(--line-2); }
.insp-thumbs { display: flex; flex-wrap: wrap; gap: 6px; }
.insp-thumb { padding: 0; border: 0; background: transparent; border-radius: 4px; box-shadow: 0 0 0 1px var(--line-2); }
.add-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.add-btn { display: grid; justify-items: center; gap: 2px; padding: 10px 4px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); font-size: 12px; font-weight: 600; }
.add-btn b { font-size: 18px; }
.add-btn:hover { border-color: var(--accent); }
.gal-edit { display: grid; gap: 6px; }
.gal-edit-row { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto auto; gap: 6px; align-items: center; }
@media (max-width: 1100px) { .ed-body { grid-template-columns: 150px minmax(0, 1fr) 270px; } }
@media (max-width: 860px) { .ed-body { grid-template-columns: 116px minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto; } .ed-list { grid-row: 1 / span 2; padding: 8px 6px 40px 8px; } .ed-canvas, .ed-insp { grid-column: 2; } .ed-insp { max-height: 38vh; border-left: 0; border-top: 1px solid var(--line); } .ed-status { display: none; } .ed-tb.wide { padding: 0 10px; } }
@media (max-width: 600px) { .ed-body { grid-template-columns: minmax(0, 1fr); } .ed-list { display: none; } .ed-canvas, .ed-insp { grid-column: 1; } .ed-tb.wide { font-size: 0; gap: 0; } .ed-tb.wide span { font-size: 19px; } }
.pdf-page > img { position: relative; z-index: 1; display: block; width: 100%; height: auto; }
.cust-cover { position: relative; display: block; width: 100%; padding: 0; border: 0; border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; background: #0d1114; }
.cust-cover .thumb { width: 100% !important; height: 100% !important; border-radius: 0; }
.cust-cover .card-play { opacity: 1; transform: none; }

/* ============ company library ============ */
.lib-intro { margin: 0 0 14px; max-width: 760px; }
.lib-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.lib-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.lib-chip { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); border-radius: 99px; padding: 7px 13px; font-size: 13px; font-weight: 600; }
.lib-chip span { font-size: 12px; color: var(--muted); font-weight: 600; }
.lib-chip.on { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.lib-chip.on span { color: inherit; opacity: .7; }
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 16px; }
.lib-grid.picker { max-height: min(58vh, 620px); overflow: auto; padding: 2px; grid-template-columns: repeat(auto-fill, minmax(138px, 1fr)); gap: 12px; }
.lib-tile { display: grid; gap: 4px; text-align: left; padding: 0; border: 0; background: transparent; color: var(--ink); min-width: 0; }
.lib-thumb { position: relative; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--surface-2); box-shadow: 0 0 0 1px var(--line); }
.lib-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lib-thumb.checker img, .lib-big.checker { object-fit: contain; }
.checker { background-color: #fff; background-image: linear-gradient(45deg, #eef0f2 25%, transparent 25%, transparent 75%, #eef0f2 75%), linear-gradient(45deg, #eef0f2 25%, transparent 25%, transparent 75%, #eef0f2 75%); background-size: 16px 16px; background-position: 0 0, 8px 8px; }
.lib-tile:hover .lib-thumb, .lib-tile:focus-visible .lib-thumb { box-shadow: 0 0 0 2px var(--accent); }
.lib-tile.sel .lib-thumb { box-shadow: 0 0 0 3px var(--accent); }
.lib-badge { position: absolute; left: 6px; bottom: 6px; background: rgba(0, 0, 0, .62); color: #fff; font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 99px; }
.lib-check { position: absolute; right: 6px; top: 6px; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 14px; }
.lib-noimg { position: absolute; inset: 0; display: grid; place-items: center; font: 700 18px var(--brand); color: var(--muted); }
.lib-name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lib-meta { font-size: 12px; color: var(--muted); margin-top: -3px; }
.lib-empty { grid-column: 1 / -1; padding: 28px 18px; border: 1px dashed var(--line-2); border-radius: 12px; color: var(--muted); text-align: center; }
.lib-page.drop { outline: 3px dashed var(--accent); outline-offset: 6px; border-radius: 12px; }
.lib-big { display: block; width: 100%; max-height: 52vh; object-fit: contain; border-radius: 10px; background: var(--surface-2); }
.dlg.xl { width: min(980px, 100%); }
.pick-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.up-list { display: grid; gap: 10px; max-height: 52vh; overflow: auto; }
.up-row { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; align-items: center; }
.up-prev { width: 64px; height: 48px; object-fit: cover; border-radius: 8px; background: var(--surface-2); }
.up-prev.icon { display: grid; place-items: center; font: 700 13px var(--brand); color: var(--muted); }
.up-fields { display: grid; grid-template-columns: minmax(0, 1fr) 130px; gap: 6px; }
.up-fields .progress { grid-column: 1 / -1; height: 5px; }
.up-row.ok .progress-fill { width: 100% !important; background: var(--ok); }
.up-row.bad .progress-fill { width: 100% !important; background: var(--danger); }
@media (max-width: 600px) { .lib-grid { grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 12px; } .up-fields { grid-template-columns: minmax(0, 1fr); } }
/* new presentation: start from scratch or a copy */
.nd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; max-height: 46vh; overflow: auto; padding: 3px; font-weight: 400; }
.nd-card { display: grid; gap: 3px; padding: 6px 6px 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); text-align: left; min-width: 0; }
.nd-card.on { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.nd-art { aspect-ratio: 4 / 3; border-radius: 8px; overflow: hidden; background: var(--surface-2); position: relative; }
.nd-art .thumb { width: 100% !important; height: 100% !important; border-radius: 0; }
.nd-blank { position: absolute; inset: 0; display: grid; place-items: center; font: 300 40px var(--ui); color: var(--muted); border: 1.5px dashed var(--line-2); border-radius: 8px; }
.nd-title { font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nd-sub { font-size: 12px; color: var(--muted); }

/* ---- Google Drive folder (Manage › Library) ---- */
.drv-panel { padding: 16px 18px; }
.drv-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 12px; }
.drv-text { min-width: 0; }
.drv-text h2 { margin: 0 0 4px; font-size: 16px; overflow-wrap: anywhere; }
.drv-text h2 a { color: inherit; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }
.drv-text p { margin: 0; max-width: 680px; }
.drv-ico { position: relative; display: inline-block; flex: none; width: 20px; height: 15px; margin-top: 3px; border-radius: 2px 3px 3px 3px; background: var(--muted); }
.drv-ico::before { content: ""; position: absolute; left: 0; top: -3px; width: 9px; height: 5px; border-radius: 2px 2px 0 0; background: inherit; }
.drv-ico.big { width: 30px; height: 23px; margin-top: 6px; background: var(--accent); }
.drv-ico.big::before { top: -4px; width: 13px; height: 6px; }
.drv-list { border: 1px solid var(--line); border-radius: 10px; max-height: min(52vh, 440px); overflow: auto; background: var(--surface); }
.drv-sec { padding: 10px 14px 6px; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.drv-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 14px; border: 0; border-top: 1px solid var(--line); background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; min-height: 46px; }
.drv-sec + .drv-row { border-top: 0; }
.drv-row:hover, .drv-row:focus-visible { background: var(--surface-2); }
.drv-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drv-go { color: var(--muted); font-size: 20px; line-height: 1; }
.drv-none { padding: 14px; margin: 0; }
.drv-list .loading { padding: 16px; }
.drv-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; font-size: 14px; }
.drv-crumb { border: 0; background: none; padding: 2px 0; font: inherit; color: var(--accent); cursor: pointer; }
.drv-crumb[aria-current] { color: inherit; font-weight: 600; cursor: default; }
.drv-sep { color: var(--muted); }
.drv-step { margin: 0; font-weight: 600; }
.drv-file { margin: 0; overflow-wrap: anywhere; }
.drv-bar { height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.drv-bar i { display: block; height: 100%; width: 0; background: var(--accent); border-radius: inherit; transition: width .2s; }
.drv-out:empty, .drv-note:empty, .drv-file:empty { display: none; }
.drv-note { margin: 0; }
.drv-more { margin-top: 6px; }
.drv-more summary { cursor: pointer; font-weight: 600; }
.drv-more ul { margin: 8px 0 0; padding-left: 18px; max-height: 200px; overflow: auto; font-size: 14px; }
.drv-more li { margin: 3px 0; overflow-wrap: anywhere; }
.drv-err p { margin: 0 0 8px; }
.drv-err .btn { display: inline-flex; }
.sent-tbl .linkish { white-space: nowrap; font-size: 13px; }
.sent-detail > td { background: var(--surface-2); padding: 16px 18px 20px; }
.sent-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: 28px; }
.sent-wrap h3 { margin: 0 0 10px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.sent-opens { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 14px; }
.sent-opens li { display: grid; gap: 2px; }
@media (max-width: 760px) { .sent-wrap { grid-template-columns: minmax(0, 1fr); gap: 18px; } }

/* ============ company app: Home ============ */
.side-count.hot { background: var(--accent); color: #fff; }
.side-count.dark { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); margin-left: 8px; }
.hero { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 18px 28px; padding: 26px 28px; border-radius: 18px; color: #fff; overflow: hidden;
  background: radial-gradient(120% 140% at 100% 0%, rgba(229, 55, 43, .38), transparent 55%), linear-gradient(135deg, #1a2228 0%, #232d34 60%, #2b363e 100%); box-shadow: var(--shadow); margin-bottom: 18px; }
.hero::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 5px; background: var(--accent); }
.hero-brand { display: flex; align-items: center; gap: 16px; min-width: 0; }
.hero-logo { width: 64px; height: 64px; border-radius: 14px; background: #fff; flex: none; object-fit: contain; }
.hero-name { font-family: var(--brand); font-weight: 800; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: #ffb3ad; }
.hero-hello { font-family: var(--brand); font-weight: 700; font-size: 26px; line-height: 1.2; margin-top: 4px; text-wrap: balance; }
.hero-clock { text-align: right; }
.hero-time { font-family: var(--brand); font-weight: 700; font-size: 44px; line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.hero-date { color: #c9d3d9; font-size: 15px; margin-top: 6px; }
.hero-btn { grid-column: 1 / -1; justify-self: start; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; margin-bottom: 18px; }
.tile { display: flex; gap: 12px; align-items: center; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); color: var(--ink); text-decoration: none; box-shadow: var(--shadow); transition: border-color .15s, transform .15s; }
.tile:hover { border-color: var(--accent); transform: translateY(-1px); }
.tile-ic { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-weight: 800; flex: none; }
.tile-label { display: block; font-weight: 700; }
.tile-sub { display: block; font-size: 13px; color: var(--muted); }
.home-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.home-main, .home-side { min-width: 0; }
.ann { border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 10px; padding: 14px 16px; background: var(--surface-2); }
.ann.off { border-left-color: var(--line-2); opacity: .8; }
.ann-head { display: flex; gap: 10px; align-items: center; justify-content: space-between; }
.ann-head h3 { font-size: 17px; }
.ann-meta { margin: 2px 0 8px; }
.ann-body p { margin: 0 0 8px; overflow-wrap: anywhere; }
.ann-admin { margin-top: 8px; gap: 4px; }
.ann-past { margin-top: 14px; }
.ann-past summary { cursor: pointer; color: var(--muted); font-weight: 600; margin-bottom: 10px; }
.ann-pop { max-width: 560px; }
.ann-pop-kicker { color: var(--accent); font-weight: 700; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; }
.ann-pop-title { font-size: 24px; }
.act-feed { list-style: none; margin: 0; padding: 0; display: grid; }
.act-feed li { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); }
.act-feed li:last-child { border-bottom: 0; }
.act-ic { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--muted); font-size: 13px; font-weight: 700; }
.act-text { color: var(--ink); text-decoration: none; overflow-wrap: anywhere; }
a.act-text:hover { color: var(--accent); }
.act-when { white-space: nowrap; }
.plain-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.mini-h { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-family: var(--ui); margin: 6px 0 6px; }
.pill.no { background: var(--accent-soft); color: var(--danger); }
@media (max-width: 900px) { .home-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 600px) {
  .hero { grid-template-columns: minmax(0, 1fr); padding: 20px; }
  .hero-clock { text-align: left; }
  .hero-time { font-size: 36px; }
  .hero-hello { font-size: 21px; }
  .hero-logo { width: 50px; height: 50px; }
}

/* ============ Documents ============ */
.doc-folder { padding: 0; overflow: hidden; }
.doc-folder > summary { cursor: pointer; padding: 16px 20px; font-family: var(--brand); font-weight: 700; font-size: 16px; list-style: none; display: flex; align-items: center; }
.doc-folder > summary::-webkit-details-marker { display: none; }
.doc-folder > summary::before { content: '▸'; color: var(--muted); margin-right: 10px; transition: transform .15s; }
.doc-folder[open] > summary::before { transform: rotate(90deg); }
.doc-list { list-style: none; margin: 0; padding: 0 8px 8px; }
.doc-row { display: flex; align-items: center; gap: 6px; border-top: 1px solid var(--line); }
.doc-open { flex: 1; min-width: 0; display: flex; gap: 14px; align-items: center; padding: 12px; color: var(--ink); text-decoration: none; border-radius: 10px; }
.doc-open:hover { background: var(--surface-2); }
.doc-ic { width: 42px; height: 42px; border-radius: 9px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-size: 11px; font-weight: 800; flex: none; }
.doc-text { display: grid; min-width: 0; }
.doc-row .doc-name { font: 600 15px var(--ui); overflow-wrap: anywhere; white-space: normal; text-transform: none; }
.doc-desc { color: var(--muted); }

/* ============ Suggestions ============ */
.sg-cols { align-items: start; }
.sg-cols > .panel, .sg-cols > div { min-width: 0; }
.sg { border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; background: var(--surface-2); }
.sg-head { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 6px; }
.sg-text p { margin: 0 0 6px; overflow-wrap: anywhere; }
.sg-reply { border-left: 3px solid var(--ok); padding: 4px 0 4px 12px; margin-top: 8px; }
.sg-reply p { margin: 4px 0; }
.sg-admin { display: grid; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line-2); }
.sg-admin select { max-width: 220px; }
.sg-top { justify-content: space-between; margin-bottom: 12px; }
.sg-top h2 { margin: 0; }

/* ============ @ Mentions ============ */
.note { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); }
.note.unread { background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 30%, var(--line)); }
.note-ic { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--accent); font-weight: 800; }
.note-main { text-align: left; border: 0; background: none; padding: 0; display: grid; gap: 3px; min-width: 0; }
.note-title { font-weight: 700; }
.note.unread .note-title::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); margin-right: 8px; vertical-align: middle; }
.note-body p { margin: 0; overflow-wrap: anywhere; }
.mention { color: var(--accent); font-weight: 600; }
.mention-wrap { position: relative; }
.mention-pop { position: absolute; left: 0; top: 100%; z-index: 30; margin-top: 4px; min-width: 260px; max-width: 100%; background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; box-shadow: var(--shadow); padding: 4px; display: grid; }
.mention-opt { display: flex; align-items: center; gap: 10px; border: 0; background: none; padding: 8px 10px; border-radius: 8px; text-align: left; }
.mention-opt.on, .mention-opt:hover { background: var(--surface-2); }
.av.sm { width: 32px; height: 32px; border-radius: 50%; display: inline-grid; place-items: center; background: var(--surface-2); color: var(--muted); font-weight: 700; font-size: 13px; flex: none; object-fit: cover; }
.feed-actions { margin-top: 10px; }
.post-card { padding: 16px 18px; display: grid; gap: 8px; }
.post { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 12px; }
.post-head { display: flex; gap: 10px; align-items: center; }
.post-head .icon-btn { margin-left: auto; }
.post-text p { margin: 2px 0 6px; overflow-wrap: anywhere; }
.replies { display: grid; gap: 10px; margin-left: 44px; padding-left: 14px; border-left: 2px solid var(--line); }
.post-card > .linkish { justify-self: start; margin-left: 44px; }
.reply-box { margin-left: 44px; display: grid; gap: 8px; }
.pick-list { display: grid; gap: 6px; max-height: 240px; overflow: auto; padding: 8px; border: 1px solid var(--line); border-radius: 10px; }
.panel .ann-head h3 { font: 700 17px/1.3 var(--brand); text-transform: none; letter-spacing: -.01em; color: var(--ink); margin: 0; }
.tiles { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
@media (max-width: 600px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .tile { padding: 12px; } .tile-sub { display: none; } .tile-ic { width: 34px; height: 34px; } }

/* ============ Training ============ */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tr-bar { height: 8px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; flex: 1; min-width: 60px; }
.tr-bar-fill { height: 100%; background: var(--ok); border-radius: 99px; }
.tr-summary { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.tr-summary-bar { flex: 1; min-width: 160px; display: flex; }
.tr-big { font-family: var(--brand); font-weight: 800; font-size: 28px; line-height: 1.1; }
.tr-search { width: 100%; max-width: none; min-height: 48px; font-size: 16px; margin: 4px 0 12px; }
.tr-hits { margin-bottom: 18px; }
.tr-hit { display: grid; gap: 2px; padding: 8px 10px; border-radius: 8px; color: var(--ink); text-decoration: none; }
.tr-hit:hover { background: var(--surface-2); }
.tr-hit mark { background: #ffe28a; color: inherit; border-radius: 3px; padding: 0 1px; }
.tr-section { margin-top: 22px; }
.tr-note { padding: 10px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); margin: 0 0 14px; }
.tr-archived { margin-top: 26px; }
.tr-archived summary { cursor: pointer; }
.lib-group-head h2 a { color: inherit; text-decoration: none; }
.lib-group-head h2 a:hover { text-decoration: underline; }
.tr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; margin-top: 12px; }
.tr-card { display: grid; gap: 8px; align-content: start; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); color: var(--ink); text-decoration: none; transition: border-color .15s, transform .15s; }
.tr-card:hover { border-color: var(--accent); transform: translateY(-1px); }
.tr-card-top { display: flex; justify-content: space-between; align-items: start; gap: 8px; }
.tr-card-tags { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.tr-emoji { font-size: 28px; line-height: 1; }
.tr-emoji.big { font-size: 48px; }
.tr-card-title { font-family: var(--brand); font-weight: 700; font-size: 16px; line-height: 1.3; }
.tr-card-desc { color: var(--muted); font-size: 13px; }
.tr-card-foot { display: flex; align-items: center; gap: 10px; margin-top: 4px; }
.tr-back { display: inline-block; margin-bottom: 10px; text-decoration: none; font-weight: 600; font-size: 14px; }
.tr-hero { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.tr-hero-text { flex: 1; min-width: 240px; }
.tr-hero-text h1 { font-size: 26px; }
.tr-hero-text p { margin: 4px 0 8px; }
.tr-hero-bar { display: flex; align-items: center; gap: 10px; max-width: 420px; }
.tr-items { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.tr-item { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); text-decoration: none; background: var(--surface); }
.tr-item:hover { border-color: var(--accent); }
.tr-check { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line-2); display: grid; place-items: center; font-weight: 800; color: #fff; flex: none; }
.tr-item.ok .tr-check { background: var(--ok); border-color: var(--ok); }
.tr-item-emoji { font-size: 20px; }
.tr-item-title { font-weight: 600; }
.tr-sign { border-left: 4px solid var(--warn); }
.tr-reader { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 22px; align-items: start; }
.tr-toc { position: sticky; top: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; }
.tr-toc-title { font-weight: 700; margin-bottom: 8px; }
.tr-toc ol { margin: 0; padding-left: 20px; display: grid; gap: 4px; font-size: 14px; }
.tr-toc a { color: var(--ink); text-decoration: none; }
.tr-toc a.on { color: var(--accent); font-weight: 700; }
.tr-page { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 26px 30px; box-shadow: var(--shadow); min-width: 0; }
.tr-step-title { font-size: 26px; margin: 6px 0 14px; }
.tr-body { font-size: 16px; line-height: 1.6; max-width: 760px; overflow-wrap: anywhere; }
.tr-body h2 { font-size: 21px; margin: 22px 0 8px; }
.tr-body h3 { font-size: 18px; margin: 18px 0 6px; }
.tr-body h4 { font-size: 16px; margin: 14px 0 6px; }
.tr-body p { margin: 0 0 10px; }
.tr-body p:empty { display: none; }
.tr-body ul, .tr-body ol { padding-left: 24px; margin: 0 0 12px; }
.tr-body li > p { margin: 0 0 4px; }
.tr-body img { max-width: 100%; height: auto; border-radius: 10px; margin: 8px 0; display: block; }
.tr-body table { border-collapse: collapse; width: 100%; margin: 10px 0; font-size: 14px; display: block; overflow-x: auto; }
.tr-body td, .tr-body th { border: 1px solid var(--line-2); padding: 8px 10px; vertical-align: top; }
.tr-body td p { margin: 0; }
.tr-body blockquote { border-left: 4px solid var(--accent); margin: 10px 0; padding: 4px 14px; color: var(--muted); }
.tr-body hr { border: 0; border-top: 1px solid var(--line); margin: 18px 0; }
.tr-video { position: relative; width: 100%; aspect-ratio: 16 / 9; margin: 10px 0; border-radius: 10px; overflow: hidden; background: #000; max-width: 100%; }
.tr-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.tr-nav { display: flex; justify-content: space-between; gap: 10px; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); }
.tr-q { border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; margin: 0; display: grid; gap: 6px; }
.tr-q legend { font-weight: 700; padding: 0 4px; }
.tr-q.right { border-color: var(--ok); background: var(--ok-soft); }
.tr-q.wrong { border-color: var(--danger); background: var(--accent-soft); }
.tr-qn { color: var(--accent); }
.tr-opt { display: flex; gap: 10px; align-items: flex-start; padding: 6px 8px; border-radius: 8px; cursor: pointer; }
.tr-opt:hover { background: var(--surface-2); }
.tr-opt input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); flex: none; }
.tr-result { margin-top: 18px; padding: 18px 20px; border-radius: var(--r); display: grid; gap: 8px; }
.tr-result.pass { background: var(--ok-soft); border: 1px solid var(--ok); }
.tr-result.fail { background: var(--accent-soft); border: 1px solid var(--danger); }
.tr-cell-bar { display: flex; align-items: center; gap: 8px; min-width: 140px; }
.grid-emoji { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 12px; }
.tr-edit-items { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; }
.tr-edit-items li { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; }
.grow { flex: 1; min-width: 0; }
.tr-editor { border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; }
.tr-toolbar { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; background: var(--surface-2); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 2; }
.tr-editable { min-height: 160px; padding: 14px 16px; outline: none; max-width: none; }
.tr-editable p:empty { display: block; min-height: 1em; }
.tr-step-edit { display: grid; gap: 10px; }
.tr-opt-edit { display: flex; gap: 8px; align-items: center; }
.tr-opt-edit input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--ok); flex: none; }
@media (max-width: 820px) {
  .tr-reader { grid-template-columns: minmax(0, 1fr); }
  .tr-toc { position: static; }
  .tr-page { padding: 18px; }
  .tr-step-title { font-size: 22px; }
}

/* ============ Time clock, pay, HR ============ */
.clock-card { display: grid; justify-items: center; gap: 10px; text-align: center; padding: 28px 20px; border-top: 5px solid var(--line-2); }
.clock-card.on { border-top-color: var(--ok); }
.clock-now { font-family: var(--brand); font-weight: 800; font-size: 44px; line-height: 1; font-variant-numeric: tabular-nums; }
.clock-status { font-weight: 600; font-size: 17px; }
.clock-live { font-variant-numeric: tabular-nums; color: var(--ok); font-weight: 700; min-height: 1.2em; }
.clock-card .field { max-width: 420px; }
.clock-btn { min-height: 64px; min-width: 240px; font-size: 20px; border-radius: 16px; color: #fff; border: 0; }
.clock-btn.in { background: var(--ok); }
.clock-btn.in:hover { background: #17693a; }
.clock-btn.out { background: var(--danger); }
.clock-btn.out:hover { background: #a3201a; }
.pay-card .stack { max-width: 520px; }
.pay-line { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.pay-line.total { font-weight: 800; font-size: 18px; border-bottom: 0; }
.tbl tr.clickable { cursor: pointer; }
.tbl tr.clickable:hover td { background: var(--surface-2); }
.tbl tr.flag td { background: var(--warn-soft); }
.tbl.ts td, .tbl.ts th { padding: 8px 6px; }
.edit-row { display: flex; gap: 8px; align-items: end; }
.dir-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-top: 12px; }
.dir-card { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 12px; align-items: start; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.dir-card > .btn { grid-column: 2; justify-self: start; }
.dir-av { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-weight: 800; object-fit: cover; }
.dir-text { display: grid; gap: 2px; min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 600px) { .clock-now { font-size: 36px; } .clock-btn { min-width: 100%; } }

/* ---------- Analytics for the whole app ---------- */
.an-tabs { overflow-x: auto; scrollbar-width: none; margin-top: 6px; }
.an-tabs::-webkit-scrollbar { display: none; }
.an-tabs .tab { white-space: nowrap; }
a.kpi { display: block; color: inherit; text-decoration: none; transition: border-color .15s, box-shadow .15s; }
a.kpi:hover, a.kpi:focus-visible { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.kpis + .kpis { margin-top: -4px; }
.kpi-sub .muted { margin-top: 2px; }
.attn { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.attn a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; margin: 0 -12px; border-radius: 10px; color: inherit; text-decoration: none; }
.attn a:hover, .attn a:focus-visible { background: var(--surface-2); }
.attn-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; background: var(--warn); }
.attn-dot.no { background: var(--danger); }
.attn-dot.info { background: color-mix(in srgb, var(--muted) 70%, transparent); }
.attn-text { flex: 1; min-width: 0; }
.attn-go { color: var(--muted); font-size: 13px; font-weight: 600; white-space: nowrap; }
.attn .tr-cell-bar { min-width: 120px; max-width: 200px; }
.an-h3 { font-size: 14px; margin: 20px 0 10px; color: var(--muted); }
@media (max-width: 600px) { .attn .tr-cell-bar { display: none; } .an .page-head .seg { width: 100%; } }
@media (max-width: 600px) { .an .seg-pre { display: none; } .an .page-head .seg { display: flex; } .an .page-head .seg button { flex: 1; } }
.two-col + .two-col { margin-top: 18px; }

/* ============ company app: Scorecards ============ */
.sc-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.sc-hero { margin-top: 4px; }
.sc-hero-text { min-width: 0; }
.sc-title { color: #fff; font-size: 28px; line-height: 1.15; margin-top: 4px; }
.sc-who { color: #c9d3d9; font-size: 15px; margin-top: 6px; }
.sc-hero-side { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.sc-kind { font-family: var(--brand); font-weight: 800; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: #ffb3ad; }
.sc-chip { background: rgba(255, 255, 255, .12); color: #fff; border: 1px solid rgba(255, 255, 255, .24); border-radius: 999px; padding: 4px 12px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.sc-intro p { font-size: 16px; line-height: 1.6; max-width: 75ch; margin: 0 0 10px; }
.sc-intro p:last-child { margin-bottom: 0; }
.sc-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin: 0 0 18px; }
.sc-stat { background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: var(--r); padding: 14px 16px; box-shadow: var(--shadow); display: grid; gap: 4px; align-content: start; }
.sc-stat-v { font-family: var(--brand); font-weight: 800; font-size: 30px; line-height: 1.1; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.sc-stat-l { font-weight: 600; }
.sc-stat-s { color: var(--muted); font-size: 13px; }
.sc-stat .sc-tone { justify-self: start; margin-top: 4px; }
.sc-tone { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.sc-tone.good { background: var(--ok-soft); color: var(--ok); }
.sc-tone.bad { background: var(--accent-soft); color: var(--danger); }
.sc-tone.warn { background: var(--warn-soft); color: var(--warn); }
.sc-tone.even { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.sc-table td:first-child { font-weight: 600; }
.sc-table td.num, .sc-table th.num { text-align: right; font-variant-numeric: tabular-nums; }
.sc-sec-intro { margin: 0 0 12px; line-height: 1.55; max-width: 75ch; }
.sc-note { margin: 10px 0 0; }
.sc-calls { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.sc-call { border: 1px solid var(--line); border-radius: var(--r); padding: 14px; background: var(--surface-2); display: grid; gap: 10px; align-content: start; }
.sc-call-top { display: flex; align-items: flex-start; gap: 12px; }
.sc-call-who { min-width: 0; flex: 1; }
.sc-call-n { width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: #fff; font: 800 14px/1 var(--brand); display: grid; place-items: center; flex: none; }
.sc-call-amt { font-family: var(--brand); font-weight: 800; font-size: 18px; white-space: nowrap; }
.sc-opener { margin: 0; padding: 8px 12px; border-left: 3px solid var(--accent); background: var(--surface); border-radius: 0 8px 8px 0; font-size: 14px; line-height: 1.45; }
.sc-call-acts { display: flex; flex-wrap: wrap; gap: 8px; }
.sc-bullets { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.sc-bullets li { display: flex; align-items: flex-start; gap: 10px; line-height: 1.55; }
.sc-b-ic { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; flex: none; font-size: 12px; font-weight: 800; margin-top: 1px; }
.sc-b-ic.good { background: var(--ok-soft); color: var(--ok); }
.sc-b-ic.bad { background: var(--warn-soft); color: var(--warn); }
.sc-b-ic.plain { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.sc-steps { list-style: none; counter-reset: st; margin: 0; padding: 0; display: grid; gap: 10px; }
.sc-steps li { counter-increment: st; display: flex; align-items: flex-start; gap: 12px; line-height: 1.55; }
.sc-steps li::before { content: counter(st); width: 26px; height: 26px; border-radius: 8px; background: var(--side); color: #fff; font: 800 13px/1 var(--brand); display: grid; place-items: center; flex: none; }
.sc-details { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.sc-detail { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.sc-detail h3 { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 6px; }
.sc-detail ul { margin: 0; padding-left: 18px; display: grid; gap: 4px; }
.sc-detail p { margin: 0; }
.sc-sign { font-family: var(--brand); font-weight: 700; font-size: 18px; margin: 8px 0 6px; }
.sc-foot { color: var(--muted); font-size: 13px; line-height: 1.5; max-width: 90ch; }
.sc-weeks { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 14px; scrollbar-width: none; }
.sc-weeks::-webkit-scrollbar { display: none; }
.sc-filters { display: flex; flex-wrap: wrap; gap: 8px; }
.sc-filters select { min-height: 40px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); padding: 0 12px; font: inherit; }
.sc-group { margin-bottom: 22px; }
.sc-group h2 { font-size: 18px; margin-bottom: 10px; }
.sc-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.sc-card { display: grid; gap: 12px; padding: 16px; border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: var(--r); background: var(--surface); color: inherit; text-decoration: none; box-shadow: var(--shadow); transition: border-color .15s; }
.sc-card:hover, .sc-card:focus-visible { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.sc-card-top { display: flex; align-items: center; gap: 10px; min-width: 0; }
.sc-card-who { min-width: 0; }
.sc-av { width: 36px; height: 36px; border-radius: 50%; background: var(--side); color: #fff; font: 800 15px/1 var(--brand); display: grid; place-items: center; flex: none; }
.sc-mini { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sc-mini b { display: block; font-family: var(--brand); font-size: 18px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.sc-mini span { color: var(--muted); font-size: 12px; line-height: 1.3; display: block; }
.sc-open { color: var(--accent); font-weight: 600; font-size: 14px; }
@media (max-width: 600px) {
  .sc-hero-side { align-items: flex-start; flex-direction: row; flex-wrap: wrap; }
  .sc-title { font-size: 22px; }
  .sc-stat-v { font-size: 24px; }
  .sc-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.sc-listhead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-bottom: 16px; }
.sc-listhead p { margin: 0; }
.sc-stat.t-good { border-top-color: var(--ok); }
.sc-stat.t-warn { border-top-color: #d99a00; }
.sc-stat.t-bad { border-top-color: var(--danger); }
.sc-stat.t-even { border-top-color: var(--line-2); }
.sc-pair { margin-bottom: 18px; }
.sc-pair .panel { margin-bottom: 0; }

/* ============ Team chat ============ */
/* Home: the chat is a column on the right on wide screens (iPad landscape and up), a card under the greeting on phones */
.page.home { max-width: 1680px; }
.home-wrap { display: flex; flex-direction: column; }
.home-left { display: contents; }
.home-left > .hero { order: 0; }
.home-chat { order: 1; min-width: 0; margin-bottom: 18px; }
.home-left > .tiles { order: 2; }
.home-left > .home-grid { order: 3; }
.home-chat .chat { height: min(520px, 72vh); height: min(520px, 72dvh); }
@media (min-width: 1180px) {
  .home-wrap { display: grid; grid-template-columns: minmax(0, 1fr) clamp(320px, 27vw, 420px); gap: 20px; align-items: start; }
  .home-left { display: block; min-width: 0; container-type: inline-size; }
  .home-chat { position: sticky; top: max(20px, env(safe-area-inset-top)); margin: 0; }
  .home-chat .chat { height: calc(100vh - 40px - var(--badge-h, 0px)); height: calc(100dvh - 40px - var(--badge-h, 0px)); min-height: 460px; }
}
@container (max-width: 720px) { .home-left .home-grid { grid-template-columns: minmax(0, 1fr); } }

.chat { display: flex; flex-direction: column; min-height: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; }
.chat-head { display: flex; align-items: center; gap: 4px; padding: 12px 10px 0 14px; }
.chat-title { font: 700 16px/1.2 var(--brand); margin: 0 auto 0 0; letter-spacing: -.01em; }
.chat-tools { display: flex; gap: 2px; }
.chat-tools a.icon-btn { text-decoration: none; }
.chat-tabs { display: flex; gap: 6px; overflow-x: auto; padding: 10px 14px 2px; scrollbar-width: none; }
.chat-tabs::-webkit-scrollbar { display: none; }
.chat-tab { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 30px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); border-radius: 99px; padding: 0 12px; font-size: 13px; font-weight: 600; }
.chat-tab:hover { border-color: var(--muted); }
.chat-tab.on { background: var(--side); border-color: var(--side); color: var(--side-ink); }
.chat-tab.add { border-style: dashed; color: var(--muted); font-weight: 500; }
.chat-n { background: var(--accent); color: #fff; border-radius: 99px; font-size: 11px; font-weight: 700; min-width: 18px; padding: 0 5px; line-height: 18px; text-align: center; }
.chat-sub { padding: 6px 14px 10px; font-size: 12px; color: var(--muted); border-bottom: 1px solid var(--line); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-sub button { border: 0; background: none; color: var(--muted); padding: 0; font: inherit; text-decoration: underline; text-underline-offset: 2px; }
.chat-sub button:hover { color: var(--ink); }
.chat-body { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; }
.chat-log { flex: 1; min-height: 0; overflow-y: auto; padding: 6px 12px 12px; display: flex; flex-direction: column; overscroll-behavior: contain; background: var(--surface-2); }
.chat-log:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.chat-day { align-self: center; margin: 12px 0 2px; }
.chat-day span { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); border-radius: 99px; padding: 2px 10px; }
.chat-more { align-self: center; margin: 6px 0 2px; border: 1px solid var(--line-2); background: var(--surface); color: var(--muted); border-radius: 99px; padding: 4px 12px; font-size: 12px; font-weight: 600; }
.chat-empty { margin: auto; text-align: center; color: var(--muted); padding: 24px 16px; max-width: 300px; font-size: 14px; }
.chat-empty p { margin: 0 0 6px; }
.chat-empty .strong { color: var(--ink); }
.chat-empty-ic { width: 46px; height: 46px; margin: 0 auto 10px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-size: 20px; }
.chat-jump { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); border: 0; border-radius: 99px; padding: 6px 14px; background: var(--side); color: var(--side-ink); font-size: 13px; font-weight: 600; box-shadow: var(--shadow); }
.msg { display: flex; gap: 8px; align-items: flex-end; margin-top: 10px; min-width: 0; }
.msg.cont { margin-top: 3px; }
.msg.mine { justify-content: flex-end; }
.msg-av { width: 30px; height: 30px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--side-2); color: var(--side-ink); font-weight: 700; font-size: 12px; object-fit: cover; }
.msg-av.gap { visibility: hidden; }
.msg-col { display: flex; flex-direction: column; align-items: flex-start; max-width: min(84%, 560px); min-width: 0; }
.msg.mine .msg-col { align-items: flex-end; }
.msg-meta { display: flex; gap: 8px; align-items: baseline; font-size: 12px; color: var(--muted); margin: 0 6px 3px; }
.msg-name { font-weight: 700; color: var(--ink); }
.msg-bubble { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 18px 18px 18px 6px; padding: 7px 12px; line-height: 1.4; overflow-wrap: anywhere; max-width: 100%; cursor: default; }
.msg.cont .msg-bubble { border-radius: 18px 18px 18px 6px; }
.msg.mine .msg-bubble { background: var(--accent); border-color: var(--accent); color: #fff; border-radius: 18px 18px 6px 18px; }
.msg-bubble p { margin: 0; }
.msg-bubble p + p { margin-top: 6px; }
.msg-bubble a { color: inherit; text-decoration: underline; }
.msg-bubble .mention { font-weight: 700; color: var(--accent); }
.msg.mine .msg-bubble .mention { color: #fff; text-decoration: underline; text-underline-offset: 2px; }
.msg.pending .msg-bubble { opacity: .65; }
.msg.open .msg-bubble { box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 35%, transparent); }
.msg-acts { display: flex; gap: 12px; align-items: center; margin: 4px 6px 0; font-size: 12px; color: var(--muted); }
.msg-acts .linkish { padding: 0; font-size: 12px; }
.msg-pending { font-size: 11px; color: var(--muted); margin: 2px 6px 0; }
.chat-compose { display: flex; gap: 8px; align-items: flex-end; padding: 10px; border-top: 1px solid var(--line); background: var(--surface); }
.chat-compose .mention-wrap { flex: 1; min-width: 0; }
.chat-compose textarea.field { display: block; resize: none; min-height: 42px; max-height: 150px; line-height: 1.4; padding: 10px 12px; border-radius: 21px; }
.chat-send { flex: none; border-radius: 21px; min-height: 42px; }
.mention-wrap.up .mention-pop { top: auto; bottom: 100%; margin: 0 0 6px; }
.chat-screen { max-width: 1000px; }
.chat-screen .chat { height: calc(100vh - 76px - var(--badge-h, 0px)); height: calc(100dvh - 76px - var(--badge-h, 0px)); min-height: 420px; }
.chat-people li { display: flex; gap: 10px; align-items: center; }
.chat-people .msg-av { width: 28px; height: 28px; }
.chat-roles { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 6px; }
.chat-people-pick { display: grid; gap: 2px; max-height: 280px; overflow-y: auto; border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; margin-top: 6px; }
.chat-person { padding: 6px 0; flex-wrap: wrap; gap: 4px 10px; }
.chat-person input:disabled { opacity: .6; }
@media (max-width: 820px) {
  /* the chat fills the screen under the menu bar, clear of Netlify's badge */
  .chat-screen { padding-top: 10px; padding-bottom: 10px; }
  .chat-screen .chat { height: calc(100vh - var(--side-h, 0px) - 20px - var(--badge-h, 0px)); height: calc(100dvh - var(--side-h, 0px) - 20px - var(--badge-h, 0px)); min-height: 360px; }
}
@media (max-width: 600px) {
  .home-chat .chat { height: min(480px, 70vh); height: min(480px, 70dvh); }
  .msg-col { max-width: 88%; }
}

/* ============ Announcement reactions and comments ============ */
.ann-social { margin-top: 10px; border-top: 1px solid var(--line); padding-top: 10px; }
.react-bar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.react-chip { display: inline-flex; align-items: center; gap: 5px; min-height: 30px; padding: 0 10px; border-radius: 99px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font-size: 14px; }
.react-chip.on { border-color: var(--accent); background: var(--accent-soft); }
.react-n { font-size: 13px; font-weight: 700; color: var(--muted); }
.react-chip.on .react-n { color: var(--accent); }
.react-btn { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 0 10px; border-radius: 99px; border: 1px solid transparent; background: transparent; color: var(--muted); font-size: 13px; font-weight: 600; }
.react-btn:hover, .react-btn[aria-expanded="true"] { background: var(--surface); border-color: var(--line); color: var(--ink); }
.react-ic { font-size: 15px; line-height: 1; }
.react-pick { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); width: max-content; max-width: 100%; }
.react-pick button { width: 40px; height: 40px; border: 0; border-radius: 10px; background: transparent; font-size: 22px; line-height: 1; }
.react-pick button:hover { background: var(--surface-2); }
.react-pick button.on { background: var(--accent-soft); }
.cmts { margin-top: 10px; display: grid; gap: 10px; }
.cmt-list { display: grid; gap: 10px; }
.cmt-list:empty { display: none; }
.cmt { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 10px; align-items: start; }
.cmt-meta { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; font-size: 13px; }
.cmt-meta .linkish { padding: 0; margin-left: auto; font-size: 12px; }
.cmt-text p { margin: 2px 0 0; overflow-wrap: anywhere; }
.cmt-form { display: flex; gap: 8px; align-items: flex-end; }
.cmt-form .mention-wrap { flex: 1; min-width: 0; }
.cmt-form textarea.field { resize: vertical; min-height: 44px; }

/* Dropdowns in the menu (Presentations, Training) */
.side-dd { display: contents; }
.side-dd-row { display: flex; align-items: center; gap: 2px; }
.side-dd-row .side-link { flex: 1; min-width: 0; }
.side-dd-tog { flex: none; width: 34px; height: 34px; border: 0; border-radius: 8px; background: transparent; color: var(--side-muted); font-size: 15px; transition: transform .15s; }
.side-dd-tog:hover { background: var(--side-2); color: var(--side-ink); }
.side-dd-tog.open { transform: rotate(180deg); }
@media (max-width: 820px) {
  .side-dd-row { display: contents; }
  .side-dd-row .side-link { flex: none; }
  .side-dd-tog { width: 30px; height: 34px; align-self: center; }
}

/* time off balances (inside Time clock) */
details.panel > summary { cursor: pointer; }
.kpi.neg .kpi-value { color: var(--danger); }
.to-balance .kpis { margin-top: 4px; }

/* suggestions: who can see it, comments, trash */
.sg-vis { border: 0; margin: 0; padding: 0; display: grid; gap: 8px; min-width: 0; }
.sg-vis legend { padding: 0; margin-bottom: 6px; }
.sg-vis .check { align-items: flex-start; }
.sg-vis .check input { margin-top: 1px; flex: none; }
.sg-sub { display: block; font-weight: 400; margin-top: 1px; }
.sg-concern { border-top: 1px dashed var(--line-2); padding-top: 10px; margin-top: 4px; }
.sg .pill.sg-vis-pill { background: var(--surface); color: var(--muted); border: 1px solid var(--line); }
.sg .pill.sg-vis-pill.private { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.sg-actions { gap: 6px; margin-top: 8px; align-items: center; }
.sg-actions .btn.small { min-height: 30px; }
.sg .cmts { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.sg.sg-focus { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent); }
.sg-trash { background: var(--surface); border-style: dashed; }
.sg-top .seg { max-width: 100%; }
@media (max-width: 600px) { .sg-top { flex-direction: column; align-items: flex-start; gap: 8px; } }
.to-when { min-width: 150px; }
@media (min-width: 1001px) { .sg-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); } }

/* Ask NTR: the AI search bar in the Home banner and its answer panel */
.ask-bar { grid-column: 1 / -1; position: relative; z-index: 1; min-width: 0; }
.ask-form { display: flex; align-items: center; gap: 6px; background: #fff; border-radius: 14px; padding: 5px 5px 5px 14px; box-shadow: 0 8px 26px rgba(0, 0, 0, .28); border: 2px solid transparent; transition: border-color .15s; }
.ask-form:focus-within { border-color: #ff8a80; }
.ask-spark { color: #e5372b; font-size: 18px; flex: none; line-height: 1; }
.ask-input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: inherit; font-size: 16px; color: #1c2226; padding: 11px 4px; -webkit-appearance: none; appearance: none; }
.ask-input::placeholder { color: #7a868e; }
.ask-input::-webkit-search-decoration { -webkit-appearance: none; }
.ask-mic { flex: none; width: 44px; height: 44px; border-radius: 11px; border: 0; background: #f1f3f5; color: #3d4a53; display: grid; place-items: center; cursor: pointer; transition: background .15s, color .15s; }
.ask-mic:hover { background: #e6e9ec; }
.ask-mic.on { background: #e5372b; color: #fff; animation: ask-pulse 1.3s ease-in-out infinite; }
.ask-mic-ic { display: grid; place-items: center; }
@keyframes ask-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(229, 55, 43, .55); } 50% { box-shadow: 0 0 0 8px rgba(229, 55, 43, 0); } }
.ask-go { flex: none; height: 44px; padding: 0 20px; border: 0; border-radius: 11px; background: #e5372b; color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.ask-go:hover { background: #c92c21; }
.ask-hint { color: #c9d3d9; font-size: 12.5px; margin-top: 8px; }
.ask-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); padding: 18px 20px 20px; margin: -6px 0 18px; scroll-margin-top: calc(var(--side-h, 0px) + 12px); }
.ask-head { display: flex; align-items: flex-start; gap: 12px; justify-content: space-between; padding-bottom: 12px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.ask-q .strong { font-size: 17px; margin-top: 2px; overflow-wrap: anywhere; }
.ask-x { flex: none; width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--muted); font-size: 20px; line-height: 1; cursor: pointer; }
.ask-body { display: grid; gap: 14px; min-width: 0; }
.ask-ai-label { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.ask-answer { font-size: 15.5px; line-height: 1.6; min-width: 0; }
.ask-answer p { margin: 0 0 8px; }
.ask-answer ul, .ask-answer ol { margin: 0 0 8px; padding-left: 22px; }
.ask-answer li { margin: 3px 0; }
.ask-cite { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; margin: 0 1px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); font-size: 11px; font-weight: 700; text-decoration: none; vertical-align: 2px; }
.ask-main { justify-self: start; max-width: 100%; white-space: normal; text-align: left; }
.ask-best { border-left: 3px solid var(--line-2); padding: 2px 0 2px 12px; }
.ask-best p { margin: 4px 0 0; line-height: 1.55; }
.ask-sources { display: grid; gap: 6px; }
.ask-src { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); text-decoration: none; background: var(--surface-2); min-width: 0; }
.ask-src:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.ask-n { flex: none; width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-size: 12px; font-weight: 700; }
.ask-src-t { display: grid; min-width: 0; flex: 1; }
.ask-src-t > * { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ask-go-ic { color: var(--muted); font-size: 18px; flex: none; }
.ask-note { margin: 0; }
.ask-thinking { display: flex; align-items: center; gap: 10px; color: var(--muted); }
.ask-dots { display: inline-flex; gap: 4px; }
.ask-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); opacity: .3; animation: ask-dot 1s infinite; }
.ask-dots i:nth-child(2) { animation-delay: .15s; } .ask-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes ask-dot { 0%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
@media (prefers-reduced-motion: reduce) { .ask-dots i, .ask-mic.on { animation: none; } }
@media (max-width: 600px) {
  .ask-form { padding-left: 10px; gap: 4px; }
  .ask-go { padding: 0 14px; }
  .ask-hint { display: none; }
  .ask-panel { padding: 14px; }
}

/* Manage → Permissions (like AccuLynx: a row per permission, a column per role) */
.perm-intro { max-width: 760px; margin: 0 0 14px; }
.perm-group { margin-bottom: 18px; }
.perm-group > h2 { margin-bottom: 4px; }
.perm-tbl { min-width: 720px; }
.perm-tbl th.perm-col, .perm-tbl td.perm-col { text-align: center; width: 96px; white-space: nowrap; }
.perm-tbl td.perm-name { min-width: 260px; }
.perm-tbl td.perm-name .small { margin-top: 2px; max-width: 460px; }
.perm-tbl input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--accent); cursor: pointer; }
.perm-always { font-size: 12px; font-weight: 600; color: var(--muted); }
.perm-admin-only { margin: 6px 0 0; padding-left: 20px; color: var(--muted); }
.perm-admin-only li { margin: 3px 0; }
.perm-bar { position: sticky; bottom: max(10px, env(safe-area-inset-bottom, 0px)); z-index: 5; display: flex; gap: 10px; justify-content: flex-end; align-items: center; flex-wrap: wrap; padding: 12px 16px; margin-top: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); }
.perm-bar .muted { margin-right: auto; }
@media (max-width: 820px) {
  .perm-tbl th.perm-name, .perm-tbl td.perm-name { position: sticky; left: 0; background: var(--surface); z-index: 1; min-width: 190px; box-shadow: 1px 0 0 var(--line); }
  .perm-tbl td.perm-name .small { display: none; }
}

/* Documents: sections, who can see it, text to copy */
.doc-folder .doc-sec-blurb { margin: -10px 0 6px; padding: 0 20px 0 44px; }
.doc-row .doc-roles { justify-self: start; margin-top: 4px; background: var(--warn-soft); color: var(--warn); }
button.doc-open { background: transparent; border: 0; font: inherit; text-align: left; cursor: pointer; width: 100%; }
.doc-copy { flex: none; }
.doc-textbody { white-space: normal; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; max-height: 60vh; overflow: auto; font-size: 15px; line-height: 1.55; }
.doc-textbody p { margin: 0 0 8px; overflow-wrap: anywhere; }
.doc-roles-field { border: 0; margin: 0; padding: 0; display: grid; gap: 8px; min-width: 0; }
.doc-roles-field legend { padding: 0; margin-bottom: 4px; }
.doc-role-boxes { display: flex; flex-wrap: wrap; gap: 8px 18px; padding-left: 30px; }
.doc-role-boxes .check.off { opacity: .45; }

/* ---------- SOPs (Training › SOPs) ---------- */
.sop-list { display: grid; gap: 8px; margin-top: 12px; }
.sop-row { display: flex; align-items: center; gap: 14px; padding: 12px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); color: var(--ink); text-decoration: none; min-width: 0; transition: border-color .15s; }
.sop-row:hover { border-color: var(--accent); }
.sop-row .tr-emoji { font-size: 24px; flex: none; }
.sop-row-text { display: grid; gap: 2px; flex: 1; min-width: 0; }
.sop-row-title { font-weight: 600; overflow-wrap: anywhere; }
.sop-row .pill { flex: none; }
.sop-who { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); font-weight: 500; }
.sop-who.wait { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.sop-go { font-size: 22px; color: var(--muted); flex: none; }
.tr-sop-link { margin: 0 0 16px; box-shadow: var(--shadow); }
.sop-count { font-family: var(--ui); font-weight: 400; }
.sop-meta { margin-top: 6px; }
.sop-meta .pill:first-child { background: var(--surface-2); border: 1px solid var(--line); color: var(--ink); }
.sop-toc { margin-bottom: 14px; }
.sop-toc ol { margin: 6px 0 0; padding-left: 22px; columns: 2 220px; column-gap: 28px; }
.sop-toc li { margin: 2px 0; break-inside: avoid; }
.linkish { background: none; border: 0; padding: 2px 0; color: var(--accent); text-align: left; cursor: pointer; }
.linkish:hover { text-decoration: underline; }
.sop-body h2, .sop-body h3, .sop-body h4 { scroll-margin-top: 76px; margin-top: 18px; }
.sop-body > :first-child { margin-top: 0; }
.sop-table { overflow-x: auto; margin: 12px 0; }
.sop-table table { border-collapse: collapse; min-width: 100%; font-size: 14px; }
.sop-table td, .sop-table th { border: 1px solid var(--line); padding: 6px 9px; vertical-align: top; text-align: left; }
.sop-table tr:first-child td { background: var(--surface-2); font-weight: 600; }
.sop-grid-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.sop-grid { min-width: 720px; }
.sop-grid th, .sop-grid td { padding: 7px 10px; border-bottom: 1px solid var(--line); text-align: center; vertical-align: middle; }
.sop-grid thead th { position: sticky; top: 0; z-index: 1; background: var(--surface); font-size: 13px; color: var(--muted); }
.sop-grid th[scope=row] { text-align: left; font-weight: 500; min-width: 240px; max-width: 360px; }
.sop-grid th[scope=row] a { color: var(--ink); text-decoration: none; }
.sop-grid th[scope=row] a:hover { color: var(--accent); }
.sop-grid-cat th { text-align: left; background: var(--surface-2); font-family: var(--brand); font-size: 14px; }
.sop-sug { display: block; font-weight: 400; margin-top: 2px; }
.sop-cell { display: inline-flex; padding: 6px; cursor: pointer; }
.sop-cell input { width: 18px; height: 18px; margin: 0; cursor: pointer; }
.sop-savebar { position: sticky; bottom: 0; display: flex; gap: 12px; align-items: center; justify-content: flex-end; flex-wrap: wrap; padding: 12px 0 calc(12px + env(safe-area-inset-bottom, 0px)); background: var(--bg); border-top: 1px solid var(--line); margin-top: 12px; }
@media (max-width: 820px) {
  .sop-row { padding: 11px 12px; gap: 10px; align-items: flex-start; flex-wrap: wrap; }
  .sop-row .pill { margin-left: 34px; }
  .sop-toc ol { columns: 1; }
}
.sop-grid.tbl th[scope=row], .sop-grid.tbl .sop-grid-cat th { text-transform: none; letter-spacing: 0; white-space: normal; font-size: 14px; color: var(--ink); }
.sop-grid.tbl .sop-grid-cat th { font-family: var(--brand); font-weight: 700; }
.sop-grid.tbl .sop-sug { font-size: 12px; color: var(--muted); }
.sop-grid.tbl tr:last-child td { border-bottom: 1px solid var(--line); }
.sop-grid.tbl tbody:last-child tr:last-child td, .sop-grid.tbl tbody:last-child tr:last-child th { border-bottom: 0; }

/* ============ recordings ============ */
.rec-page .page-head { margin-bottom: 4px; }
.rec-grid2 { gap: 12px; }
.rec-types { display: flex; flex-wrap: wrap; gap: 8px; }
.rec-types .btn { font-weight: 600; }
.rec-types .btn.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.rec-go { min-width: 220px; }
.rec-tips ul { margin: 0; padding-left: 20px; display: grid; gap: 8px; }
.rec-foot { margin-top: 18px; }
.rec-pending { display: flex; gap: 10px; align-items: center; padding: 10px 14px; border-radius: 10px; background: var(--warn-soft); color: var(--warn); font-weight: 600; font-size: 14px; margin-bottom: 14px; }
.rec-spin { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .8s linear infinite; vertical-align: -2px; margin-right: 8px; flex: none; }
.rec-list { display: grid; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.rec-list > p { margin: 0; padding: 18px; }
.rec-list > .empty { border: 0; border-radius: 0; }
.rec-row { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 13px 16px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; min-width: 0; }
.rec-row:last-child { border-bottom: 0; }
.rec-row:hover { background: var(--surface-2); }
.rec-row-main { min-width: 0; }
.rec-row-main > * { overflow: hidden; text-overflow: ellipsis; }
.rec-row-side { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; flex: none; max-width: 55%; }
.rec-chip { display: inline-grid; place-items: center; min-width: 38px; height: 26px; padding: 0 8px; border-radius: 99px; font-weight: 700; font-size: 13px; font-variant-numeric: tabular-nums; }
.rec-chip.good, .rec-big.good b, .rec-dots i.on.good { color: var(--ok); }
.rec-chip.mid, .rec-big.mid b, .rec-dots i.on.mid { color: var(--warn); }
.rec-chip.low, .rec-big.low b, .rec-dots i.on.low { color: var(--danger); }
.rec-chip.good { background: var(--ok-soft); }
.rec-chip.mid { background: var(--warn-soft); }
.rec-chip.low { background: var(--accent-soft); }
.rec-filters { margin-bottom: 12px; }
.rec-filters .field { width: auto; min-width: 180px; flex: 1 1 180px; max-width: 280px; }
.rec-lock { max-width: 640px; }
.rec-progress { height: 10px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; margin: 6px 0; }
.rec-progress > div { height: 100%; background: var(--accent); border-radius: 99px; }
.rec-people td:first-child { font-weight: 600; }

/* the screen while recording */
body.recording { overflow: hidden; }
.rec-screen { position: fixed; inset: 0; z-index: 950; background: #0e1316; color: #eef2f4; overflow-y: auto; animation: fade .15s;
  padding: max(20px, env(safe-area-inset-top)) max(18px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left)); }
.rec-in { max-width: 560px; min-height: 100%; margin: 0 auto; display: flex; flex-direction: column; gap: 16px; }
.rec-top { text-align: center; }
.rec-who { font: 700 22px/1.25 var(--brand); overflow-wrap: anywhere; }
.rec-sub { color: #93a1ab; font-size: 14px; margin-top: 4px; }
.rec-mid { display: grid; justify-items: center; gap: 12px; margin: 10px 0 4px; }
.rec-timer-row { display: flex; align-items: center; gap: 14px; }
.rec-timer { font: 700 64px/1 var(--ui); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.rec-dot { width: 18px; height: 18px; border-radius: 50%; background: #5b666e; flex: none; }
.rec-screen.on .rec-dot, .rec-dim .rec-dot { background: #ff3b30; animation: rec-blink 1.6s ease-in-out infinite; }
.rec-screen.held .rec-dot { background: #e0b54a; }
@keyframes rec-blink { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
.rec-level { width: min(320px, 80vw); height: 8px; border-radius: 99px; background: #232d34; overflow: hidden; }
.rec-level-fill { height: 100%; width: 100%; background: linear-gradient(90deg, #4cc27d, #4cc27d 70%, #e0b54a); transform-origin: left center; transform: scaleX(.02); transition: transform .08s linear; }
.rec-screen.held .rec-level-fill { background: #5b666e; }
.rec-status { font-weight: 700; font-size: 15px; letter-spacing: .02em; text-align: center; }
.rec-screen.held .rec-status { color: #e0b54a; }
.rec-warn { margin: 0; padding: 10px 14px; border-radius: 10px; background: #3a2f12; color: #ffd772; font-weight: 600; font-size: 14px; }
.rec-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: auto; }
.rec-actions .rec-btn { width: 100%; min-height: 58px; font-size: 17px; border-radius: 14px; }
.rec-actions .rec-btn:not(.primary):not(.danger) { background: #232d34; border-color: #3a454d; color: #eef2f4; }
.rec-actions .rec-btn.danger { grid-column: 1 / -1; }
.rec-saved { margin: 0; text-align: center; color: #93a1ab; font-size: 13px; }
.rec-dim { position: fixed; inset: 0; background: #000; display: grid; place-content: center; justify-items: center; gap: 12px; cursor: pointer; }
.rec-dim-time { font: 600 28px/1 var(--ui); font-variant-numeric: tabular-nums; color: #3d454b; }
.rec-dim-tip { color: #2e3439; font-size: 13px; }
.rec-dim .rec-dot { width: 12px; height: 12px; opacity: .6; }

/* after stopping, and on a recording's page */
.rec-outcomes { display: flex; flex-wrap: wrap; gap: 8px; }
.rec-outcomes .btn.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.rec-head { align-items: flex-start; }
.rec-head p { margin: 4px 0 0; }
.rec-listen { display: grid; gap: 14px; }
.rec-outcome { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 12px; }
.rec-player { display: grid; gap: 6px; }
.rec-player-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.rec-play { width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--accent); color: #fff; font-size: 16px; flex: none; display: grid; place-items: center; }
.rec-play:disabled { opacity: .4; }
.rec-t { font-variant-numeric: tabular-nums; font-size: 13px; color: var(--muted); flex: none; min-width: 40px; text-align: center; }
.rec-seek { flex: 1; min-width: 0; accent-color: var(--accent); }
.rec-player-btns { padding-left: 52px; }
.rec-coach-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 6px; }
.rec-coach-head h2 { margin: 0; }
.rec-big { font-size: 15px; color: var(--muted); }
.rec-big b { font: 800 30px/1 var(--brand); }
.rec-facts { margin: 4px 0 10px; }
.rec-summary { font-size: 16px; }
.rec-warn-box { padding: 10px 14px; border-radius: 10px; background: var(--warn-soft); color: var(--warn); font-weight: 600; }
.rec-steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 22px; }
.rec-step { border-bottom: 1px solid var(--line); padding-bottom: 8px; min-width: 0; }
.rec-step p { margin: 4px 0 0; color: var(--muted); }
.rec-step-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.rec-dots { display: inline-flex; gap: 4px; }
.rec-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }
.rec-dots i.on { background: currentColor; }
.rec-points, .rec-objs { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.rec-points li, .rec-objs li { padding: 10px 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); display: grid; gap: 6px; min-width: 0; }
.rec-points.good li { border-left: 3px solid var(--ok); }
.rec-points:not(.good) li { border-left: 3px solid var(--warn); }
.rec-points blockquote, .rec-objs blockquote { margin: 0; color: var(--muted); font-style: italic; overflow-wrap: anywhere; }
.rec-objs p { margin: 0; }
.rec-try { font-size: 14px; }
.rec-at { border: 0; background: transparent; color: var(--accent); font: 600 12px/1 var(--ui); font-style: normal; padding: 2px 4px; font-variant-numeric: tabular-nums; }
.rec-lines { display: grid; margin-top: 10px; max-height: 70vh; overflow-y: auto; border-top: 1px solid var(--line); }
.rec-line { display: grid; grid-template-columns: 48px 96px minmax(0, 1fr); gap: 8px; text-align: left; border: 0; border-bottom: 1px solid var(--line); background: transparent; padding: 9px 4px; font-size: 14px; color: var(--ink); }
.rec-line:hover { background: var(--surface-2); }
.rec-lt { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 12px; padding-top: 2px; }
.rec-lw { font-weight: 700; font-size: 13px; }
.rec-lw.rep { color: var(--bar); }
.rec-lw.ho { color: var(--ok); }
.rec-lw.oth { color: var(--muted); }
.rec-lw.c2 { color: var(--accent); }
.rec-lw.c3 { color: var(--warn); }
.rec-lw.c4 { color: #7b5cd6; }
.rec-actions-list { margin: 0; padding-left: 20px; display: grid; gap: 6px; }
.rec-lx { overflow-wrap: anywhere; }
.rec-manage { margin-top: 6px; }
@media (max-width: 820px) {
  .rec-timer { font-size: 54px; }
  .rec-steps { grid-template-columns: minmax(0, 1fr); }
  .rec-grid2 { grid-template-columns: minmax(0, 1fr); }
  .rec-line { grid-template-columns: 44px minmax(0, 1fr); }
  .rec-line .rec-lx { grid-column: 2; }
  .rec-row { align-items: flex-start; }
  .rec-player-btns { padding-left: 0; }
  .rec-go { width: 100%; }
}
.rec-page .pill:not(.ok):not(.wait):not(.no) { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
