/* New Era Lending LLC — Loan Officer Technology Skills Test. Brand: red #C80400, tangerine #FF6442, grey #EDEDED. */
@font-face { font-family: "Work Sans"; src: url("assets/work-sans-variable.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
/* Licensed Basic Sans Alt Black served by the official New Era Lending Webflow site. Falls back to Work Sans / system sans offline. */
@font-face { font-family: "Basic Sans"; src: url("https://cdn.prod.website-files.com/6908d561c9fee5ea45e73e39/691f280519729057de181377_basicsansalt-black-webfont.woff2") format("woff2"); font-weight: 900; font-style: normal; font-display: swap; }

:root {
  --red: #c80400; --red-dark: #a30300; --tangerine: #ff6442; --tangerine-dark: #c5482a;
  --grey: #ededed; --line: #d9d9d9; --card-ink: #3a3a3a; --ink: #535353; --muted: #626262; --soft: #8a8a8a;
  --body: "Work Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --display: "Basic Sans", "Work Sans", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--grey); color: var(--ink); font-family: var(--body); font-size: 15px; line-height: 1.5; }
h1, h2, h3 { font-family: var(--display); font-weight: 900; letter-spacing: -.02em; margin: 0; }
h1 { color: var(--red); text-transform: uppercase; font-size: 44px; line-height: 1.1; margin: 4px 0 14px; }
h2 { color: var(--red); font-size: 26px; line-height: 1.2; }
h3 { color: var(--card-ink); font-size: 17px; line-height: 1.25; }
p { margin: 0 0 10px; }
a { color: var(--tangerine-dark); }
button, input, select, textarea { font: inherit; color: var(--card-ink); }
input, select, textarea { border: 1px solid #c9c9c9; border-radius: 6px; padding: 7px 9px; background: #fff; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--tangerine); outline-offset: 0; border-color: var(--tangerine); }
button:focus-visible { outline: 3px solid var(--tangerine); outline-offset: 2px; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: 12px; font-weight: 600; color: var(--soft); margin: 0; }
.lead-text { font-size: 16px; color: var(--muted); max-width: 760px; }
.fine { font-size: 12px; color: var(--soft); margin-top: 14px; }
.empty { color: var(--soft); font-size: 13px; padding: 10px; margin: 0; }

.btn { border: 0; border-radius: 999px; padding: 10px 22px; font-weight: 600; cursor: pointer; transition: background .15s, transform .05s; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); }
.btn-primary:disabled { background: #d7a3a2; cursor: not-allowed; }
.btn-ghost { background: #fff; color: var(--card-ink); border: 1px solid #c9c9c9; }
.btn-ghost:hover { border-color: var(--tangerine); color: var(--tangerine-dark); }
.btn-accent { background: var(--tangerine); color: #fff; }
.btn-accent:hover { background: var(--tangerine-dark); }
.btn-sm { padding: 6px 14px; font-size: 13px; }

/* Top bar */
.topbar { height: 56px; background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 16px; padding: 0 20px; position: sticky; top: 0; z-index: 20; }
.logo { height: 34px; width: auto; }
.topbar-title { font-family: var(--display); font-weight: 900; color: var(--card-ink); font-size: 16px; border-left: 1px solid var(--line); padding-left: 16px; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 14px; font-size: 13px; }
.clock { font-family: var(--display); font-weight: 900; font-size: 20px; color: var(--card-ink); min-width: 64px; text-align: right; }
.mode-pill { background: var(--grey); color: var(--card-ink); border-radius: 999px; padding: 3px 10px; font-size: 12px; font-weight: 600; }
.mode-pill.demo { background: var(--tangerine); color: #fff; }

.screen { display: none; }
.screen.active { display: block; }

/* Start / generic cards */
.start-card, .card-wide { background: #fff; max-width: 980px; margin: 28px auto; padding: 36px 44px; border-radius: 14px; border-top: 5px solid var(--red); }
.parts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 20px 0 24px; }
.part { display: flex; gap: 12px; background: var(--grey); border-radius: 10px; padding: 14px; }
.part p { font-size: 13px; color: var(--muted); margin: 4px 0 0; }
.part-num { flex: 0 0 30px; height: 30px; border-radius: 50%; background: var(--tangerine); color: #fff; display: grid; place-items: center; font-family: var(--display); font-weight: 900; }
.h2-small { font-size: 20px; margin-bottom: 6px; }
.howto { margin: 6px 0 22px; padding-left: 20px; color: var(--muted); }
.howto li { margin: 4px 0; }
.howto b { color: var(--card-ink); }
.start-form { display: grid; gap: 8px; max-width: 520px; }
.start-form label { font-weight: 600; color: var(--card-ink); font-size: 14px; }
.start-form .check { font-weight: 500; display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.start-actions { display: flex; gap: 10px; margin-top: 10px; }

/* Simulation layout */
.sim-grid { display: grid; grid-template-columns: 220px minmax(0, 1fr) 370px; gap: 10px; padding: 10px; height: calc(100vh - 56px); min-height: 700px; }
.pane { background: #fff; border-radius: 10px; display: flex; flex-direction: column; min-height: 0; border: 1px solid var(--line); }
.pane-head { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-bottom: 1px solid var(--line); }
.pane-head h3 { font-size: 15px; white-space: nowrap; }
.pane-head small { font-family: var(--body); font-weight: 500; color: var(--soft); font-size: 11px; letter-spacing: 0; }
.ico { color: var(--tangerine); font-size: 16px; width: 18px; text-align: center; }
.right-col { display: flex; flex-direction: column; gap: 10px; min-height: 0; }

/* Tasks */
.tasks { overflow: auto; padding: 8px; display: flex; flex-direction: column; gap: 8px; }
.task { border: 1px solid var(--line); border-left: 4px solid var(--tangerine); border-radius: 8px; padding: 8px 10px; font-size: 13px; background: #fff; animation: slidein .3s ease-out; }
.task.new { box-shadow: 0 0 0 2px var(--tangerine); }
.task.done { opacity: .55; border-left-color: var(--soft); }
.task .t-meta { display: flex; justify-content: space-between; font-size: 11px; color: var(--soft); margin-bottom: 3px; }
.task .t-title { color: var(--card-ink); font-weight: 600; margin-bottom: 2px; }
.task p { margin: 0 0 6px; color: var(--muted); }
.task label { font-size: 12px; display: flex; align-items: center; gap: 6px; color: var(--muted); cursor: pointer; }
.task.info { border-left-color: var(--red); }
@keyframes slidein { from { transform: translateY(-6px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ===== Simulated apps. These looks apply ONLY inside .app panes. ===== */
.app { --sys: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; font-family: var(--sys); font-size: 13px; color: #181818; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.app input, .app select, .app textarea, .app button { font-family: var(--sys); }
.app .empty { color: #706e6b; }

/* --- CRM --- */
.sf { background: #f3f3f3; border: 1px solid #dddbda; border-radius: 4px; }
.sf-global { display: flex; align-items: center; gap: 10px; background: #032d60; color: #fff; height: 42px; padding: 0 10px; flex: 0 0 auto; }
.sf-waffle { background: transparent; border: 0; color: #fff; width: 30px; height: 30px; border-radius: 4px; display: grid; place-items: center; cursor: pointer; padding: 0; }
.sf-waffle:hover { background: #0b4a8f; }
.sf-appname { font-size: 16px; font-weight: 600; padding-right: 6px; }
.sf-gsearch { flex: 1; max-width: 360px; margin: 0 auto; display: flex; align-items: center; gap: 6px; background: #fff; border-radius: 4px; padding: 0 8px; color: #706e6b; height: 28px; }
.sf-gsearch input { border: 0; outline: 0; flex: 1; font-size: 13px; padding: 0; background: transparent; color: #181818; }
.sf-gsearch:focus-within { box-shadow: 0 0 0 2px #1b96ff; }
.sf-gicons { display: flex; gap: 12px; align-items: center; color: #c9d7ea; }
.sf-avatar { width: 26px; height: 26px; border-radius: 50%; background: #0176d3; color: #fff; display: grid; place-items: center; font-size: 11px; font-weight: 700; }
.sf-tabs { display: flex; align-items: stretch; background: #fff; border-bottom: 3px solid #0176d3; height: 38px; padding: 0 8px; flex: 0 0 auto; }
.sf-tab { background: transparent; border: 0; padding: 0 12px; font-size: 13px; color: #181818; cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -3px; }
.sf-tab:hover { background: #f3f3f3; }
.sf-tab.on { border-bottom-color: #014486; font-weight: 600; background: #f3f9ff; }
.sf-tag { margin-left: auto; align-self: center; font-size: 11px; color: #706e6b; }
.sf-page { flex: 1; overflow: auto; padding: 10px; }
.sf-card { background: #fff; border: 1px solid #dddbda; border-radius: 4px; box-shadow: 0 2px 2px rgba(0,0,0,.05); }
.sf-link { color: #0176d3; cursor: pointer; text-decoration: none; }
.sf-link:hover { text-decoration: underline; color: #014486; }
.sf-btn { background: #fff; border: 1px solid #c9c9c9; color: #0176d3; border-radius: 4px; padding: 0 12px; height: 28px; font-size: 13px; cursor: pointer; }
.sf-btn:hover { background: #f3f3f3; }
.sf-btn-brand { background: #0176d3; border-color: #0176d3; color: #fff; }
.sf-btn-brand:hover { background: #014486; }
.sf-btn:disabled { color: #c9c9c9; background: #fff; border-color: #e5e5e5; cursor: default; }
.sf-obj-icon { width: 32px; height: 32px; border-radius: 4px; background: #f88962; display: grid; place-items: center; flex: 0 0 32px; }
.sf-lv-head, .sf-hl-top { display: flex; align-items: center; gap: 10px; padding: 10px 12px 6px; }
.sf-lv-obj { font-size: 12px; color: #444; }
.sf-lv-title { font-size: 17px; font-weight: 700; color: #181818; display: flex; align-items: center; gap: 4px; }
.sf-lv-btns { margin-left: auto; display: flex; gap: 0; }
.sf-lv-btns .sf-btn { border-radius: 0; margin-left: -1px; }
.sf-lv-btns .sf-btn:first-child { border-radius: 4px 0 0 4px; }
.sf-lv-btns .sf-btn:last-child { border-radius: 0 4px 4px 0; }
.sf-lv-meta { font-size: 12px; color: #706e6b; padding: 0 12px 8px; }
.sf-table-wrap { overflow: auto; border-top: 1px solid #dddbda; }
.sf-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.sf-table th { background: #f3f3f3; color: #444; font-weight: 600; text-align: left; padding: 6px 8px; border-bottom: 1px solid #dddbda; border-right: 1px solid #e5e5e5; white-space: nowrap; cursor: pointer; font-size: 12px; position: sticky; top: 0; }
.sf-table th:hover { background: #fff; }
.sf-sort { margin-left: 4px; font-size: 9px; color: #c9c9c9; }
.sf-table th.sorted .sf-sort { color: #0176d3; }
.sf-table td { padding: 6px 8px; border-bottom: 1px solid #e5e5e5; white-space: nowrap; max-width: 170px; overflow: hidden; text-overflow: ellipsis; }
.sf-table tr[data-id] { cursor: pointer; }
.sf-table tbody tr:hover td { background: #f3f9ff; }
.sf-table tr.sel td { background: #eef4ff; }
.sf-num { color: #706e6b; width: 28px; text-align: right; }
.sf-menu-wrap { position: relative; width: 34px; overflow: visible !important; }
.sf-rowmenu { border: 1px solid #c9c9c9; background: #fff; border-radius: 4px; width: 22px; height: 20px; display: grid; place-items: center; color: #706e6b; cursor: pointer; padding: 0; }
.sf-menu { position: absolute; right: 6px; top: 26px; background: #fff; border: 1px solid #dddbda; border-radius: 4px; box-shadow: 0 2px 8px rgba(0,0,0,.16); z-index: 30; min-width: 120px; padding: 4px 0; }
.sf-menu button { display: block; width: 100%; text-align: left; background: none; border: 0; padding: 6px 12px; font-size: 13px; cursor: pointer; }
.sf-menu button:hover { background: #f3f3f3; }
.sf-crumbs { font-size: 12px; color: #706e6b; margin: 0 0 6px 2px; }
.sf-highlights { margin-bottom: 8px; }
.sf-hl-name { font-size: 18px; font-weight: 700; color: #181818; }
.sf-hl-fields { display: flex; gap: 22px; padding: 4px 12px 12px 54px; flex-wrap: wrap; font-size: 13px; }
.sf-hl-fields span { display: block; font-size: 11px; color: #444; }
.sf-pathcard { padding: 8px 10px; margin-bottom: 8px; }
.sf-path { display: flex; gap: 4px; }
.sf-chev { flex: 1; height: 28px; border: 0; background: #ecebea; color: #181818; font-size: 12.5px; cursor: pointer; clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 50%, calc(100% - 10px) 100%, 0 100%, 10px 50%); display: flex; align-items: center; justify-content: center; gap: 4px; }
.sf-chev:first-child { clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 50%, calc(100% - 10px) 100%, 0 100%); border-radius: 14px 0 0 14px; }
.sf-chev:last-child { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 10px 50%); border-radius: 0 14px 14px 0; }
.sf-chev.done { background: #3ba755; color: #fff; }
.sf-chev.cur { background: #014486; color: #fff; font-weight: 600; }
.sf-chev.pick { box-shadow: inset 0 0 0 2px #1b96ff; background: #d8e6fe; color: #014486; }
.sf-chev:hover:not(.cur) { background: #dddbda; }
.sf-chev.done:hover { background: #2e844a; }
.sf-path-note { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #444; margin-top: 6px; }
.sf-path-note .sf-btn { margin-left: auto; height: 26px; }
.sf-rec-body { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 8px; align-items: start; }
.sf-subtabs { display: flex; border-bottom: 1px solid #dddbda; padding: 0 10px; }
.sf-subtabs button { background: none; border: 0; padding: 9px 10px 7px; font-size: 13px; color: #444; border-bottom: 2px solid transparent; cursor: pointer; }
.sf-subtabs button.on { border-bottom-color: #0176d3; color: #181818; font-weight: 600; }
.sf-section { background: #f3f3f3; margin: 10px 10px 4px; padding: 4px 8px; font-size: 13px; font-weight: 600; color: #181818; border-radius: 4px; }
.sf-fields { display: grid; grid-template-columns: 1fr 1fr; column-gap: 14px; padding: 0 12px; }
.sf-field { border-bottom: 1px solid #e5e5e5; padding: 4px 0 5px; min-height: 42px; }
.sf-flabel { font-size: 12px; color: #444; }
.sf-fval { display: flex; align-items: center; gap: 4px; min-height: 22px; font-size: 13px; }
.sf-fval > span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sf-fval input, .sf-fval select { width: 100%; border: 1px solid #c9c9c9; border-radius: 4px; padding: 3px 6px; font-size: 13px; height: 28px; }
.sf-fval input:focus, .sf-fval select:focus { outline: 0; border-color: #1b96ff; box-shadow: 0 0 0 1px #1b96ff; }
.sf-pencil { border: 0; background: none; color: #aeaeae; cursor: pointer; padding: 2px 4px; border-radius: 3px; }
.sf-field:hover .sf-pencil { color: #0176d3; }
.sf-pencil:hover { background: #f3f3f3; }
.sf-optout { color: #ba0517; }
.sf-editbar { position: sticky; bottom: 0; display: flex; justify-content: center; align-items: center; gap: 8px; background: #f3f3f3; border-top: 1px solid #dddbda; padding: 8px; margin-top: 10px; }
.sf-editbar .unsaved { color: #ba0517; margin-right: auto; font-family: var(--sys); }
.sf-details { padding-bottom: 10px; }
.sf-act-pub { padding: 10px; display: grid; gap: 6px; }
.sf-act-pub textarea, .sf-act-pub input { border: 1px solid #c9c9c9; border-radius: 4px; padding: 6px 8px; font-size: 13px; width: 100%; resize: vertical; }
.sf-act-pub textarea:focus, .sf-act-pub input:focus { outline: 0; border-color: #1b96ff; box-shadow: 0 0 0 1px #1b96ff; }
.sf-act-btns { display: flex; justify-content: flex-end; }
.sf-mini { font-size: 12px; color: #444; }
.sf-hint { font-size: 12px; color: #706e6b; margin: 0; }
.sf-timeline { list-style: none; margin: 4px 0 10px; padding: 0 10px; }
.sf-timeline li { display: flex; gap: 8px; padding: 6px 0; border-bottom: 1px solid #f3f3f3; }
.sf-timeline li i { width: 22px; height: 22px; border-radius: 4px; display: grid; place-items: center; flex: 0 0 22px; color: #fff; background: #939393; }
.sf-timeline li i svg { width: 13px; height: 13px; }
.sf-timeline li.k-call i { background: #48c3cc; }
.sf-timeline li.k-task i { background: #3ba755; }
.sf-timeline li.k-upd i { background: #7f8de1; }
.sf-timeline li b { display: block; font-size: 12.5px; color: #0176d3; font-weight: 600; }
.sf-timeline li span { display: block; font-size: 12px; color: #181818; word-break: break-word; }
.sf-timeline li small { color: #706e6b; font-size: 11px; }
.sf-timeline .sf-empty { color: #706e6b; font-size: 12px; display: block; text-align: center; padding: 12px 0; border: 0; }

/* Home, related, misc */
.sf-gbtn { background: none; border: 0; color: #c9d7ea; cursor: pointer; padding: 2px; display: grid; }
.sf-gbtn:hover { color: #fff; }
.sf-avatar { border: 0; cursor: pointer; }
.sf-home { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sf-tile { padding: 10px 12px; }
.sf-tile-h { font-size: 14px; font-weight: 700; color: #181818; margin-bottom: 6px; }
.sf-big { font-size: 28px; font-weight: 300; color: #0176d3; line-height: 1; margin-bottom: 6px; }
.sf-tile ul { list-style: none; margin: 0; padding: 0; }
.sf-tile li { display: flex; justify-content: space-between; gap: 6px; padding: 5px 0; border-bottom: 1px solid #f3f3f3; font-size: 12.5px; }
.sf-tile li span { color: #706e6b; font-size: 11.5px; text-align: right; }
.sf-viewall { display: block; text-align: center; font-size: 12px; margin-top: 6px; }
.sf-ic-contacts { background: #a094ed; } .sf-ic-opportunities { background: #fcb95b; } .sf-ic-tasks { background: #3ba755; }
.sf-related { list-style: none; margin: 0; padding: 0 12px; }
.sf-related li { padding: 8px 0; border-bottom: 1px solid #e5e5e5; }
.sf-related b { display: block; color: #0176d3; font-size: 13px; }
.sf-related span { font-size: 12px; color: #706e6b; }
.dp-link { background: none; border: 0; color: #7c52ff; font-size: 11.5px; cursor: pointer; text-decoration: underline; padding: 2px 0; margin-top: 4px; display: block; margin-left: auto; margin-right: auto; }

/* --- Phone (softphone) --- */
.dp { background: #fff; border: 1px solid #e3e1ea; border-radius: 10px; flex: 0 0 auto; }
.dp.is-ringing { box-shadow: 0 0 0 3px #7c52ff; border-color: #7c52ff; }
.dp-head { display: flex; align-items: center; gap: 6px; padding: 8px 12px; border-bottom: 1px solid #efedf5; }
.dp-head b { font-size: 14px; color: #1d1c2b; }
.dp-head small { color: #8a87a0; font-size: 11px; }
.dp-logo { width: 18px; height: 18px; border-radius: 5px; background: #7c52ff; display: grid; place-items: center; }
.dp-logo i { width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.dp-status { margin-left: auto; font-size: 11.5px; font-weight: 600; display: flex; align-items: center; gap: 5px; color: #5d5a73; }
.dp-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #23a55a; }
.dp-status.busy::before { background: #e5484d; }
.dp-body { padding: 10px 12px; }
.dp-display { display: flex; gap: 8px; margin-bottom: 8px; }
.dp-display input { flex: 1; border: 1px solid #e3e1ea; border-radius: 8px; padding: 6px 10px; font-size: 13px; }
.dp-display input:focus { outline: 0; border-color: #7c52ff; }
.dp-call { width: 34px; height: 34px; border-radius: 50%; border: 0; background: #23a55a; color: #fff; display: grid; place-items: center; cursor: pointer; }
.dp-keypad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.dp-key { height: 30px; border: 0; border-radius: 8px; background: #f4f2fb; color: #1d1c2b; font-size: 15px; font-weight: 600; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; }
.dp-key small { font-size: 9px; color: #8a87a0; font-weight: 600; letter-spacing: .08em; }
.dp-key:hover { background: #e9e3ff; }
.dp-incoming { text-align: center; padding: 2px 0 4px; }
.dp-label { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: #7c52ff; font-weight: 700; }
.dp-av { width: 52px; height: 52px; margin: 8px auto 6px; border-radius: 50%; background: #7c52ff; color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 18px; }
.dp-av.ring { animation: dpPulse 1s infinite; }
.dp-av.sm { width: 36px; height: 36px; margin: 0; font-size: 13px; flex: 0 0 36px; }
@keyframes dpPulse { 0% { box-shadow: 0 0 0 0 rgba(124,82,255,.6); } 70% { box-shadow: 0 0 0 16px rgba(124,82,255,0); } 100% { box-shadow: 0 0 0 0 rgba(124,82,255,0); } }
.dp-name { font-size: 15px; font-weight: 700; color: #1d1c2b; }
.dp-num { font-size: 12.5px; color: #5d5a73; }
.dp-countdown { font-size: 12px; color: #e5484d; font-weight: 600; margin-top: 2px; }
.dp-inc-btns { display: flex; justify-content: center; gap: 46px; margin-top: 10px; }
.dp-inc-lbl { display: flex; justify-content: center; gap: 52px; font-size: 11px; color: #5d5a73; margin-top: 3px; }
.dp-round { width: 46px; height: 46px; border-radius: 50%; border: 0; color: #fff; display: grid; place-items: center; cursor: pointer; }
.dp-green { background: #23a55a; }
.dp-green:hover { background: #1b8a4a; }
.dp-red { background: #e5484d; }
.dp-red:hover { background: #c8373c; }
.dp-oncall { display: flex; align-items: center; gap: 10px; }
.dp-hold { color: #7c52ff; }
.dp-transcript { background: #f7f6fc; border-radius: 8px; padding: 7px 9px; margin-top: 8px; max-height: 84px; overflow: auto; font-size: 12.5px; }
.dp-transcript p { margin: 0 0 4px; color: #1d1c2b; }
.dp-transcript p.sys { color: #8a87a0; font-style: italic; }
.dp-controls { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 8px; }
.dp-ctl { border: 0; background: #f4f2fb; color: #3b3953; border-radius: 8px; padding: 5px 0 4px; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 10.5px; }
.dp-ctl:hover { background: #e9e3ff; }
.dp-ctl.on { background: #7c52ff; color: #fff; }
.dp-hang-row { display: flex; justify-content: center; margin-top: 8px; }
.dp-hang-row .dp-round { width: 40px; height: 40px; }
.dp-wrap-title { font-size: 12.5px; font-weight: 600; color: #1d1c2b; margin: 10px 0 6px; }
.dispo { display: flex; flex-wrap: wrap; gap: 6px; }
.dispo button { background: #fff; border: 1px solid #cfc3ff; color: #5b37e0; border-radius: 999px; padding: 5px 11px; font-size: 12.5px; cursor: pointer; }
.dispo button:hover { background: #7c52ff; color: #fff; border-color: #7c52ff; }
.missed { border-top: 1px solid #efedf5; padding: 6px 12px 8px; font-size: 12.5px; max-height: 92px; overflow: auto; }
.missed:empty { display: none; }
.missed .m-title { font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; color: #8a87a0; font-weight: 700; margin-bottom: 3px; }
.missed-item { display: flex; align-items: center; gap: 6px; padding: 3px 0; }
.missed-item span { flex: 1; color: #1d1c2b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.missed-item.done span { color: #8a87a0; text-decoration: line-through; }
.missed-item small { color: #8a87a0; }
.dp-missed-ico { color: #e5484d; display: grid; }
.dp-cb { border: 0; background: #7c52ff; color: #fff; border-radius: 999px; padding: 3px 10px 3px 6px; font-size: 12px; cursor: pointer; display: flex; align-items: center; gap: 3px; }
.dp-cb svg { width: 13px; height: 13px; }
.dp-cb:hover { background: #6439f5; }

/* --- Texts (inbox) --- */
.hm { background: #fff; border: 1px solid #dfe3ea; border-radius: 8px; flex: 1; }
.hm-head { display: flex; align-items: center; gap: 6px; padding: 7px 12px; border-bottom: 1px solid #e8ebf0; background: #f7f9fc; }
.hm-head b { font-size: 14px; color: #1b2733; }
.hm-head small { font-size: 11px; color: #7b8794; }
.hm-logo { width: 18px; height: 18px; border-radius: 5px; background: #2d6cdf; color: #fff; font-size: 11px; display: grid; place-items: center; }
.hm-count { margin-left: auto; background: #e5484d; color: #fff; border-radius: 999px; font-size: 11px; font-weight: 700; padding: 0 7px; }
.hm-count:empty { display: none; }
.hm-body { display: grid; grid-template-columns: 136px minmax(0, 1fr); flex: 1; min-height: 0; }
.convos { border-right: 1px solid #e8ebf0; overflow: auto; background: #fbfcfd; }
.convo { display: flex; gap: 6px; padding: 7px 7px; border-bottom: 1px solid #eef1f4; cursor: pointer; position: relative; align-items: flex-start; }
.convo:hover { background: #f0f4fa; }
.convo.sel { background: #e8f0fe; box-shadow: inset 3px 0 0 #2d6cdf; }
.hm-av { width: 26px; height: 26px; border-radius: 50%; color: #fff; font-size: 10.5px; font-weight: 700; display: grid; place-items: center; flex: 0 0 26px; }
.hm-av.sm { width: 28px; height: 28px; flex-basis: 28px; }
.hm-cv { min-width: 0; flex: 1; }
.hm-cv-top { display: flex; gap: 4px; align-items: baseline; }
.hm-cv-top b { font-size: 12px; color: #1b2733; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; font-weight: 600; }
.convo.unread .hm-cv-top b { font-weight: 800; }
.hm-cv-top time { font-size: 10px; color: #7b8794; }
.hm-prev { font-size: 11px; color: #5b6774; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hm-prev .opt { color: #c8373c; font-style: normal; font-weight: 700; }
.convo .badge { position: absolute; right: 6px; bottom: 6px; background: #e5484d; color: #fff; border-radius: 999px; font-size: 10px; min-width: 16px; text-align: center; padding: 0 4px; font-weight: 700; }
.thread-wrap { display: flex; flex-direction: column; min-height: 0; }
.hm-thead { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-bottom: 1px solid #e8ebf0; min-height: 40px; }
.hm-th-name { display: block; font-weight: 700; color: #1b2733; font-size: 13px; }
.hm-th-num { display: block; font-size: 11px; color: #7b8794; }
.hm-chip-in, .hm-chip-out { margin-left: auto; font-size: 10.5px; font-weight: 700; border-radius: 999px; padding: 1px 8px; }
.hm-chip-in { background: #e6f4ea; color: #1b7f3b; }
.hm-chip-out { background: #fde7e7; color: #c8373c; }
.hm-optout { background: #fff4e5; border-bottom: 1px solid #f5c37a; color: #7a4b00; font-size: 12px; padding: 7px 10px; }
.hm-optout b { color: #a33a00; }
.thread { flex: 1; overflow: auto; padding: 8px 10px; display: flex; flex-direction: column; gap: 6px; background: #fff; }
.bubble { max-width: 86%; padding: 6px 10px; border-radius: 14px; font-size: 12.5px; line-height: 1.4; }
.bubble.in { background: #eef1f5; color: #1b2733; align-self: flex-start; border-bottom-left-radius: 4px; }
.bubble.out { background: #2d6cdf; color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.bubble.sys { align-self: center; background: transparent; color: #c8373c; font-size: 11px; font-weight: 600; }
.bubble time { display: block; font-size: 9.5px; opacity: .7; margin-top: 2px; }
.composer { display: flex; gap: 6px; padding: 7px 8px; border-top: 1px solid #e8ebf0; align-items: flex-end; background: #fbfcfd; }
.composer textarea { flex: 1; resize: none; font-size: 12.5px; border: 1px solid #d3d9e1; border-radius: 8px; padding: 6px 8px; }
.composer textarea:focus { outline: 0; border-color: #2d6cdf; box-shadow: 0 0 0 1px #2d6cdf; }
.hm-tpl-wrap { position: relative; }
.hm-tpl { width: 32px; height: 32px; border: 1px solid #d3d9e1; background: #fff; border-radius: 8px; color: #4a5866; cursor: pointer; display: grid; place-items: center; }
.hm-tpl:hover { color: #2d6cdf; border-color: #2d6cdf; }
.hm-tpl-menu { position: absolute; bottom: 38px; left: 0; width: 250px; background: #fff; border: 1px solid #dfe3ea; border-radius: 8px; box-shadow: 0 6px 18px rgba(0,0,0,.14); z-index: 40; padding: 4px 0; }
.hm-tpl-h { font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; color: #7b8794; font-weight: 700; padding: 4px 10px; }
.hm-tpl-menu button { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 6px 10px; cursor: pointer; }
.hm-tpl-menu button:hover { background: #f0f4fa; }
.hm-tpl-menu b { display: block; font-size: 12px; color: #1b2733; }
.hm-tpl-menu span { display: block; font-size: 11px; color: #5b6774; }
.hm-send { height: 32px; border: 0; border-radius: 8px; background: #2d6cdf; color: #fff; padding: 0 10px; font-size: 12.5px; font-weight: 600; display: flex; align-items: center; gap: 4px; cursor: pointer; }
.hm-send:hover { background: #2358bd; }
.hm-send:disabled { background: #a9c0ea; cursor: not-allowed; }

/* Toasts */
.toasts { position: fixed; bottom: 14px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 6px; z-index: 50; pointer-events: none; }
.toast { background: var(--card-ink); color: #fff; padding: 8px 16px; border-radius: 999px; font-size: 13px; animation: slidein .25s ease-out; box-shadow: 0 4px 14px rgba(0,0,0,.18); }
.toast.warn { background: var(--red); }

/* First-task guide (never blocks clicks) */
.guide { position: fixed; z-index: 60; pointer-events: none; display: flex; flex-direction: column; align-items: flex-start; animation: guideBob 1s ease-in-out infinite; }
.guide[hidden] { display: none !important; }
.guide-tip { background: var(--tangerine); color: #fff; font: 600 12.5px/1.3 var(--body); padding: 6px 10px; border-radius: 8px; max-width: 240px; box-shadow: 0 3px 10px rgba(0,0,0,.18); }
.guide-arrow { position: relative; margin-top: -1px; }
.guide.below { flex-direction: column-reverse; animation-name: guideBobUp; }
.guide.below .guide-arrow { transform: rotate(180deg); margin: 0 0 -1px; }
@keyframes guideBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes guideBobUp { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }

/* Quiz */
.q { border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; margin: 12px 0; }
.q.missing { border-color: var(--red); }
.q h3 { margin-bottom: 8px; font-size: 16px; }
.q h3 span { color: var(--tangerine); margin-right: 6px; }
.q label { display: flex; gap: 10px; align-items: flex-start; padding: 5px 8px; border-radius: 6px; cursor: pointer; color: var(--muted); }
.q label:hover { background: #f7f7f7; }
.q input { margin-top: 4px; accent-color: var(--red); }
.actions { display: flex; justify-content: flex-end; align-items: center; gap: 12px; margin-top: 18px; }
.form-msg { color: var(--red); font-weight: 600; font-size: 14px; }

/* Typing */
.type-stats { display: flex; gap: 14px; margin: 16px 0; }
.type-stats div { background: var(--grey); border-radius: 10px; padding: 10px 18px; min-width: 150px; }
.type-stats span { display: block; font-family: var(--display); font-weight: 900; font-size: 30px; color: var(--card-ink); }
.type-stats small { color: var(--soft); font-size: 12px; }
.passage { font-size: 18px; line-height: 1.75; background: #fafafa; border: 1px solid var(--line); border-radius: 10px; padding: 14px 18px; color: var(--soft); user-select: none; max-height: 220px; overflow: auto; }
.passage .ok { color: var(--card-ink); }
.passage .bad { color: var(--red); background: #fde6e5; border-radius: 2px; }
.passage .cur { border-bottom: 2px solid var(--tangerine); color: var(--card-ink); }
#typeInput { width: 100%; margin-top: 12px; font-size: 16px; }

/* Results */
.res-top { display: flex; gap: 28px; align-items: center; margin: 10px 0 22px; flex-wrap: wrap; }
.score-ring { width: 150px; height: 150px; border-radius: 50%; border: 10px solid var(--grey); display: grid; place-items: center; text-align: center; position: relative; }
.score-ring b { font-family: var(--display); font-weight: 900; font-size: 50px; color: var(--red); line-height: 1; display: block; }
.score-ring small { color: var(--soft); }
.verdict { font-family: var(--display); font-weight: 900; font-size: 20px; color: var(--card-ink); }
.verdict.pass { color: var(--card-ink); }
.verdict.review { color: var(--red); }
.meta-line { color: var(--muted); font-size: 14px; }
.cats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.cat { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.cat-head { display: flex; justify-content: space-between; align-items: baseline; }
.cat-head b { font-family: var(--display); font-weight: 900; color: var(--card-ink); font-size: 22px; }
.bar { height: 8px; background: var(--grey); border-radius: 999px; margin: 8px 0; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--tangerine); border-radius: 999px; }
.cat ul { margin: 6px 0 0; padding-left: 0; list-style: none; font-size: 12.5px; color: var(--muted); }
.cat li { display: flex; justify-content: space-between; gap: 10px; padding: 2px 0; border-bottom: 1px dotted #e3e3e3; }
.cat li em { font-style: normal; color: var(--card-ink); white-space: nowrap; }
.cat li.miss em { color: var(--red); }
.results h2 { margin: 26px 0 8px; }
.timeline { width: 100%; border-collapse: collapse; font-size: 13px; }
.timeline th { text-align: left; background: var(--grey); color: var(--card-ink); padding: 6px 10px; font-weight: 600; }
.timeline td { padding: 6px 10px; border-bottom: 1px solid #eee; vertical-align: top; }
.timeline td.slow { color: var(--red); font-weight: 600; }
.res-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 0 4px; }

/* Done / submitting */
.done-card { max-width: 760px; margin-top: 60px; }
.spinner { width: 42px; height: 42px; border-radius: 50%; border: 4px solid var(--grey); border-top-color: var(--tangerine); animation: spin 0.9s linear infinite; margin: 10px 0 16px; }
@keyframes spin { to { transform: rotate(360deg); } }
.fallback { background: var(--grey); border-radius: 10px; padding: 16px 18px; margin-top: 16px; }
.fallback .btn { display: inline-block; text-decoration: none; margin-top: 6px; }
[hidden] { display: none !important; }

@media (max-width: 1400px) {
  .sim-grid { grid-template-columns: 200px minmax(0, 1fr) 350px; }
}
@media print {
  body { background: #fff; }
  .topbar-right, .res-actions, .no-print { display: none !important; }
  .topbar { position: static; }
  .card-wide { margin: 0; padding: 0; border: 0; max-width: none; }
  .cat { break-inside: avoid; }
}
.dp-oncall .dp-link { margin-left: 0; }
