:root {
  --ink: #0d352a;
  --deep: #041b14;
  --green: #124a39;
  --green-2: #23644e;
  --lime: #c8ed4b;
  --lime-strong: #afd636;
  --lime-soft: #eff8cc;
  --paper: #fbfdf9;
  --surface: #eef4ef;
  --line: #cbd7d0;
  --muted: #667970;
  --coral: #a75543;
  --yellow: #ffe03b;
  --shadow: 0 22px 70px rgba(13, 53, 42, .12);
  color-scheme: light;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: #e7eee9; }
body { margin: 0; min-height: 100vh; color: var(--ink); background: radial-gradient(circle at 75% -10%, rgba(200, 237, 75, .18), transparent 28rem), #e9f0eb; }
button, input { font: inherit; }
button { color: inherit; }
.skip-link { position: fixed; left: 14px; top: -60px; z-index: 999; padding: 12px 16px; color: white; background: var(--deep); border-radius: 8px; }
.skip-link:focus { top: 14px; }

.training-header { min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px 24px; border-bottom: 1px solid rgba(203, 215, 208, .95); background: rgba(250, 252, 249, .92); backdrop-filter: blur(18px); position: sticky; top: 0; z-index: 80; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; font-size: .84rem; font-weight: 900; letter-spacing: .1em; }
.brand small { display: block; margin-top: 3px; color: var(--muted); font-size: .5rem; letter-spacing: .14em; }
.brand-mark { width: 38px; height: 38px; display: grid; place-items: center; padding: 6px 10px; border-radius: 10px; background: var(--deep); }
.brand-mark img { width: 100%; height: 100%; object-fit: contain; }
.header-status { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.demo-chip, .sample-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 7px 11px; border-radius: 999px; font-size: .74rem; font-weight: 800; white-space: nowrap; }
.demo-chip { color: #14382c; background: var(--lime-soft); }
.demo-chip i { width: 7px; height: 7px; border-radius: 50%; background: #1c9960; box-shadow: 0 0 0 4px rgba(28, 153, 96, .12); }
.sample-chip { color: #714d14; background: #fff1cc; }
.quiet-button, .primary-button, .return-button { min-height: 40px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 9px; background: white; cursor: pointer; font-weight: 800; transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease; }
.quiet-button:hover, .primary-button:hover, .return-button:hover { transform: translateY(-1px); }
.quiet-button:focus-visible, .primary-button:focus-visible, .return-button:focus-visible, button:focus-visible { outline: 3px solid rgba(86, 150, 73, .28); outline-offset: 2px; }
.primary-button { color: var(--deep); border-color: var(--lime); background: var(--lime); box-shadow: 0 8px 20px rgba(126, 162, 33, .16); }
.share-button { white-space: nowrap; }
.return-button { color: white; border-color: var(--green); background: var(--green); }
button:disabled { opacity: .42; cursor: not-allowed; transform: none !important; }

.training-layout { width: min(1880px, 100%); min-height: calc(100vh - 70px); margin: 0 auto; padding: 18px; display: grid; grid-template-columns: 250px minmax(670px, 1fr) 320px; gap: 16px; align-items: start; }
.lesson-rail, .coach-panel, .demo-frame { border: 1px solid rgba(185, 202, 193, .9); border-radius: 20px; box-shadow: var(--shadow); }
.lesson-rail { min-height: calc(100vh - 106px); position: sticky; top: 88px; display: flex; flex-direction: column; padding: 22px; color: white; background: var(--deep); overflow: hidden; }
.lesson-rail::after { content: ""; width: 180px; height: 180px; position: absolute; right: -95px; bottom: 80px; border: 38px solid rgba(200, 237, 75, .08); border-radius: 50%; pointer-events: none; }
.rail-heading > span { color: var(--lime); font-size: .66rem; font-weight: 900; letter-spacing: .15em; }
.rail-heading strong { display: block; margin-top: 8px; font-size: 1.28rem; }
.rail-heading p { margin: 9px 0 0; color: #a9c0b5; font-size: .82rem; line-height: 1.5; }
.lesson-rail ol { list-style: none; display: grid; gap: 5px; margin: 22px 0; padding: 0; }
.lesson-rail li button { width: 100%; min-height: 56px; display: grid; grid-template-columns: 32px 1fr; align-items: center; gap: 9px; padding: 8px; color: #b6c8bf; border: 0; border-radius: 11px; background: transparent; cursor: pointer; text-align: left; }
.lesson-rail li button b { width: 31px; height: 31px; display: grid; place-items: center; color: #8ea69a; border: 1px solid rgba(255, 255, 255, .13); border-radius: 50%; font-size: .68rem; }
.lesson-rail li button span { font-size: .82rem; font-weight: 800; }
.lesson-rail li button small { display: block; margin-top: 3px; color: #789187; font-size: .64rem; font-weight: 600; }
.lesson-rail li.is-current button { color: var(--deep); background: var(--lime); }
.lesson-rail li.is-current button b { color: var(--deep); border-color: rgba(13, 53, 42, .3); }
.lesson-rail li.is-current button small { color: #476339; }
.lesson-rail li.is-complete button { color: white; }
.lesson-rail li.is-complete button b { color: var(--deep); border-color: var(--lime); background: var(--lime); }
.rail-progress { margin-top: auto; position: relative; z-index: 1; }
.rail-progress div { display: flex; justify-content: space-between; color: #acc0b6; font-size: .7rem; }
.rail-progress strong { color: var(--lime); }
.rail-progress i { height: 6px; display: block; margin-top: 8px; overflow: hidden; border-radius: 999px; background: #284a3e; }
.rail-progress i span { width: 14%; height: 100%; display: block; border-radius: inherit; background: linear-gradient(90deg, #6bd18f, var(--lime)); transition: width .35s ease; }

.demo-frame { min-height: calc(100vh - 106px); position: relative; overflow: hidden; background: var(--paper); }
.pwa-header { min-height: 68px; display: grid; grid-template-columns: minmax(220px, 1fr) auto minmax(155px, 1fr); align-items: center; gap: 16px; padding: 11px 19px; border-bottom: 1px solid var(--line); background: rgba(250, 251, 248, .96); }
.pwa-brand { display: flex; align-items: center; gap: 10px; }
.pwa-brand > span { width: 34px; height: 34px; display: grid; place-items: center; padding: 6px 10px; border-radius: 9px; background: var(--ink); }
.pwa-brand img { width: 100%; height: 100%; object-fit: contain; }
.pwa-brand strong { font-size: .72rem; letter-spacing: .08em; }
.pwa-brand small { display: block; margin-top: 3px; color: var(--muted); font-size: .42rem; letter-spacing: .12em; }
.pwa-header nav { display: flex; gap: 4px; padding: 4px; border-radius: 10px; background: #e1e9e4; }
.pwa-header nav button { padding: 8px 11px; color: var(--muted); border: 0; border-radius: 7px; background: transparent; cursor: pointer; font-size: .68rem; font-weight: 800; }
.pwa-header nav button.is-active { color: var(--ink); background: white; box-shadow: 0 2px 8px rgba(20, 53, 46, .08); }
.pwa-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
.notification-button { width: 39px; height: 39px; position: relative; display: grid; place-items: center; color: var(--ink); border: 1px solid var(--line); border-radius: 50%; background: white; cursor: pointer; }
.notification-button > span { width: 13px; height: 15px; position: relative; color: transparent; border: 2px solid var(--ink); border-radius: 8px 8px 5px 5px; }
.notification-button > span::after { content: ""; width: 5px; height: 2px; position: absolute; left: 2px; bottom: -5px; border-radius: 4px; background: var(--ink); }
.notification-button b { min-width: 17px; height: 17px; position: absolute; right: -3px; top: -3px; display: grid; place-items: center; padding: 0 4px; color: white; border-radius: 999px; background: #dd4e43; font-size: .59rem; }
.viewer { color: var(--ink); font-size: .62rem; font-weight: 900; text-align: right; }
.viewer small { display: block; color: var(--muted); font-size: .46rem; letter-spacing: .12em; }

.workspace-content { padding: 25px 28px 42px; }
.workspace-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.eyebrow { margin: 0 0 8px; color: var(--coral); font-size: .61rem; font-weight: 900; letter-spacing: .15em; }
.workspace-hero h1 { margin: 0; font-size: clamp(2.4rem, 4.2vw, 4.5rem); line-height: .94; letter-spacing: -.055em; font-weight: 680; }
.workspace-hero h1 em { color: var(--green-2); font-style: normal; }
.workspace-hero div > p:last-child { max-width: 650px; margin: 15px 0 0; color: var(--muted); font-size: .84rem; line-height: 1.6; }
.live-sync { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: .68rem; font-weight: 800; white-space: nowrap; }
.live-sync i { width: 8px; height: 8px; border-radius: 50%; background: #37a66a; box-shadow: 0 0 0 5px rgba(55, 166, 106, .12); }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 24px; border: 1px solid var(--line); border-radius: 13px; overflow: hidden; }
.metrics article { min-height: 102px; position: relative; padding: 18px; border-right: 1px solid var(--line); background: #f9faf7; }
.metrics article:last-child { border-right: 0; }
.metrics article > span { position: absolute; right: 13px; top: 11px; color: #a5b0ab; font-size: .52rem; font-weight: 800; }
.metrics strong { font-size: 1.75rem; }
.metrics p { margin: 5px 0 0; color: var(--muted); font-size: .68rem; }
.training-banner { min-height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 16px; padding: 15px 16px; color: #edf8f1; border-radius: 13px; background: var(--ink); }
.training-banner > div { display: flex; align-items: center; gap: 15px; }
.training-banner > div > span { width: 40px; height: 40px; display: grid; place-items: center; flex: 0 0 auto; color: var(--ink); border-radius: 50%; background: var(--lime); font-size: .72rem; font-weight: 900; }
.training-banner p { margin: 0; }
.training-banner strong { display: block; font-size: .9rem; }
.training-banner small { display: block; margin-top: 5px; color: #b7cbc1; font-size: .69rem; line-height: 1.35; }
.training-banner .primary-button { white-space: nowrap; }
.lead-toolbar { display: grid; grid-template-columns: minmax(260px, 1fr) auto; gap: 14px; align-items: end; margin-top: 16px; padding: 14px; border: 1px solid var(--line); border-radius: 13px; background: rgba(250, 252, 249, .85); }
.lead-toolbar label { display: grid; gap: 6px; }
.lead-toolbar label > span, .lead-toolbar > div > span { color: var(--muted); font-size: .54rem; font-weight: 900; letter-spacing: .1em; }
.lead-toolbar input { width: 100%; height: 42px; padding: 0 13px; border: 1px solid #bac9c0; border-radius: 9px; background: white; }
.lead-toolbar > div { display: flex; align-items: center; gap: 5px; }
.lead-toolbar > div > span { margin-right: 5px; }
.lead-toolbar > div button { padding: 9px 11px; color: var(--muted); border: 0; border-radius: 7px; background: #e1e9e4; font-size: .65rem; font-weight: 800; }
.lead-toolbar > div button.is-active { color: var(--ink); background: white; box-shadow: 0 2px 7px rgba(20, 53, 46, .08); }
.empty-state { min-height: 260px; display: grid; place-items: center; align-content: center; gap: 8px; margin-top: 16px; border: 1px dashed #b7c8bf; border-radius: 14px; color: var(--muted); background: #f6f9f6; text-align: center; }
.empty-state .empty-orb { width: 44px; height: 44px; display: grid; place-items: center; color: var(--green); border-radius: 50%; background: var(--lime-soft); font-size: 1.5rem; }
.empty-state strong { color: var(--ink); font-size: 1rem; }
.empty-state p { margin: 0; font-size: .72rem; }

.lead-card { position: relative; margin-top: 16px; padding: 22px; border: 1px solid var(--line); border-left: 5px solid var(--coral); background: #fbfcf9; box-shadow: 0 12px 38px rgba(24, 55, 47, .08); animation: enter-card .42s ease both; }
@keyframes enter-card { from { opacity: 0; transform: translateY(12px); } }
.lead-card > header { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.source { color: var(--green); font-size: .64rem; font-weight: 900; letter-spacing: .085em; }
.reference-row { display: flex; align-items: center; gap: 7px; margin-top: 8px; }
.reference-row code, .reference-row span { padding: 5px 8px; border: 1px solid #c7d6ce; border-radius: 6px; color: #49675b; background: #f0f5f1; font-size: .6rem; font-weight: 800; }
.reference-row span { color: #6f5b1f; border-color: #e5d498; background: #fff8dc; }
.lead-card h2 { margin: 9px 0 0; font-size: 1.55rem; letter-spacing: -.03em; }
.lead-badges { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 6px; }
.badge { padding: 6px 9px; border-radius: 999px; font-size: .61rem; font-weight: 900; white-space: nowrap; }
.badge.high { color: #6b5011; background: #fff0a8; }
.badge.attention { color: #7b342b; background: #fae1dc; }
.badge.ai { color: #245640; background: #e3f1e8; }
.badge.staff { color: white; background: var(--coral); }
.lead-facts { display: grid; grid-template-columns: 1.5fr .8fr .8fr 1fr; margin-top: 20px; border: 1px solid var(--line); }
.lead-facts > div { min-height: 78px; padding: 12px; border-right: 1px solid var(--line); }
.lead-facts > div:last-child { border-right: 0; }
.lead-facts small { display: block; color: var(--muted); font-size: .59rem; font-weight: 800; }
.lead-facts strong { display: block; margin-top: 8px; font-size: .79rem; line-height: 1.4; }
.attention-note { display: flex; gap: 10px; margin-top: 12px; padding: 11px 13px; border-left: 3px solid var(--yellow); background: #f8f1df; }
.attention-note > span { width: 21px; height: 21px; display: grid; place-items: center; flex: 0 0 auto; border: 1px solid var(--ink); border-radius: 50%; font: 600 .7rem Georgia, serif; }
.attention-note p { margin: 0; color: var(--muted); font-size: .68rem; line-height: 1.45; }
.attention-note strong { display: block; color: var(--ink); }
.conversation-preview { margin-top: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 9px; background: #f4f8f5; }
.conversation-preview span { color: var(--muted); font-size: .58rem; font-weight: 800; }
.conversation-preview p { margin: 6px 0 0; font-size: .73rem; line-height: 1.5; }
.lead-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 13px; padding-top: 13px; border-top: 1px solid var(--line); }
.lead-actions button { min-height: 38px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 7px; background: white; cursor: pointer; font-size: .69rem; font-weight: 800; }
.lead-actions .primary-action { color: white; border-color: #1f9d62; background: #1f9d62; box-shadow: 0 7px 18px rgba(31, 157, 98, .18); }

/* Latest SSPVE PWA customer workspace */
.pwa-header { grid-template-columns: minmax(175px, 1fr) auto minmax(160px, 1fr); gap: 9px; }
.pwa-header nav button { display: inline-flex; align-items: center; gap: 5px; }
.pwa-header nav button b { min-width: 16px; height: 16px; display: grid; place-items: center; padding: 0 4px; color: white; border-radius: 999px; background: #d94e43; font-size: .54rem; }
.language-switch { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 8px; background: #edf2ee; }
.language-switch b, .language-switch i { padding: 5px 6px; border-radius: 6px; font-size: .55rem; font-style: normal; font-weight: 850; }
.language-switch b { color: var(--ink); background: white; box-shadow: 0 2px 6px rgba(20, 53, 46, .08); }
.language-switch i { color: var(--muted); }
.theme-button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 50%; background: white; cursor: pointer; font-size: .84rem; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.page-heading h1 { margin: 0; font-size: 1.7rem; letter-spacing: -.035em; }
.page-heading p { margin: 5px 0 0; color: var(--muted); font-size: .76rem; }
.refresh-button { min-height: 38px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; background: white; cursor: pointer; font-size: .7rem; font-weight: 850; }
.latest-toolbar { grid-template-columns: 1fr; align-items: stretch; }
.customer-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.lead-toolbar .customer-filters > button { display: inline-flex; align-items: center; gap: 7px; padding: 9px 12px; }
.customer-filters button b { min-width: 20px; height: 20px; display: grid; place-items: center; padding: 0 5px; border-radius: 999px; color: var(--muted); background: rgba(255, 255, 255, .82); font-size: .6rem; }
.customer-filters button.is-active b { color: white; background: var(--green); }
.customer-card { margin-top: 16px; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: white; box-shadow: 0 10px 30px rgba(24, 55, 47, .07); animation: enter-card .42s ease both; }
.customer-card-summary { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 15px 17px 10px; }
.customer-identity { display: flex; align-items: center; gap: 11px; }
.customer-avatar { width: 40px; height: 40px; display: grid; place-items: center; flex: 0 0 auto; color: white; border-radius: 50%; background: var(--green); font-size: .7rem; font-weight: 900; }
.customer-identity strong, .customer-identity small { display: block; }
.customer-identity strong { font-size: .88rem; }
.customer-identity small { margin-top: 5px; color: var(--muted); font-size: .6rem; }
.customer-stage { display: grid; justify-items: end; gap: 7px; }
.customer-stage > span { padding: 5px 8px; color: #6a541b; border-radius: 999px; background: #fff2bd; font-size: .59rem; font-weight: 900; }
.customer-stage button { padding: 0; color: var(--green); border: 0; background: transparent; cursor: pointer; font-size: .65rem; font-weight: 900; }
.customer-alert { display: flex; align-items: center; gap: 8px; margin: 0; padding: 0 17px 14px 68px; color: #914236; font-size: .68rem; font-weight: 800; }
.customer-alert i { width: 7px; height: 7px; border-radius: 50%; background: #d95647; box-shadow: 0 0 0 4px rgba(217, 86, 71, .1); }
.customer-details { padding: 16px 17px 18px; border-top: 1px solid var(--line); background: #fbfcfa; }
.reception-panel { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px; border: 1px solid #c6d6ce; border-radius: 11px; background: #f0f6f2; }
.reception-panel small, .reception-panel strong { display: block; }
.reception-panel small { color: var(--muted); font-size: .57rem; font-weight: 850; letter-spacing: .06em; }
.reception-panel strong { margin-top: 5px; font-size: .85rem; }
.reception-panel p { margin: 5px 0 0; color: var(--muted); font-size: .64rem; line-height: 1.4; }
.primary-action { min-height: 38px; flex: 0 0 auto; padding: 9px 12px; color: white; border: 0; border-radius: 8px; background: #1f9d62; cursor: pointer; font-size: .68rem; font-weight: 900; box-shadow: 0 7px 18px rgba(31, 157, 98, .16); }
.customer-number { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 13px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; background: white; }
.customer-number span { color: var(--muted); font-size: .62rem; }
.customer-number strong { font-size: .69rem; }
.latest-facts { grid-template-columns: 1.25fr .75fr; margin-top: 9px; border-radius: 9px; overflow: hidden; background: white; }
.latest-facts > div { min-height: 68px; }
.latest-facts > div:nth-child(2) { border-right: 0; }
.latest-facts > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
.issue-panel { margin-top: 12px; overflow: hidden; border: 1px solid #e9c3bc; border-radius: 11px; background: #fffafa; }
.issue-panel > header { display: flex; align-items: center; justify-content: space-between; padding: 11px 13px; border-bottom: 1px solid #efd6d1; }
.issue-panel > header strong { font-size: .75rem; }
.issue-panel > header b { min-width: 22px; height: 22px; display: grid; place-items: center; color: white; border-radius: 999px; background: #d65346; font-size: .62rem; }
.issue-guidance { margin: 0; padding: 10px 13px; color: #7a625d; background: #fff3ef; font-size: .62rem; line-height: 1.48; }
.issue-item { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; padding: 12px 13px; }
.issue-item p { margin: 0; font-size: .68rem; }
.issue-item p strong, .issue-item p span { display: block; }
.issue-item p span { margin-top: 5px; color: var(--muted); line-height: 1.45; }
.issue-item > div { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.issue-item button { min-height: 34px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 7px; background: white; cursor: pointer; font-size: .62rem; font-weight: 850; }
.latest-actions { margin-top: 12px; padding-top: 12px; }
.latest-actions button:first-child { color: white; border-color: var(--green); background: var(--green); }
.status-row { margin-top: 13px; padding-top: 13px; border-top: 1px solid var(--line); }
.status-row > span { color: var(--muted); font-size: .57rem; font-weight: 900; letter-spacing: .07em; }
.status-row > div { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.status-row button { padding: 6px 8px; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; background: white; font-size: .58rem; font-weight: 800; }
.status-row button.is-active { color: white; border-color: var(--green); background: var(--green); }
.latest-activity > strong { font-size: .8rem; }
.latest-activity p { margin: 8px 0 0; color: var(--muted); font-size: .67rem; line-height: 1.45; }
.chat-label { width: fit-content; margin: 0 auto 12px; padding: 6px 9px; color: #48675a; border-radius: 999px; background: #dce7e0; font-size: .58rem; font-weight: 850; }

.notification-panel, .conversation-drawer { width: min(390px, 94%); height: calc(100% - 68px); position: absolute; right: 0; top: 68px; z-index: 40; transform: translateX(105%); border-left: 1px solid var(--line); background: rgba(250, 252, 249, .98); box-shadow: -22px 24px 50px rgba(13, 53, 42, .18); transition: transform .28s ease; }
.notification-panel.is-open, .conversation-drawer.is-open { transform: translateX(0); }
.notification-panel > header, .conversation-drawer > header { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 16px 18px; color: white; background: var(--ink); }
.notification-panel > header > div, .conversation-drawer > header > div { display: grid; gap: 3px; }
.notification-panel > header strong { font-size: 1rem; }
.notification-panel > header span { display: inline-flex; align-items: center; gap: 6px; color: #a9c1b6; font-size: .62rem; }
.notification-panel > header i { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); }
.notification-panel > header button, .conversation-drawer > header button { width: 32px; height: 32px; color: white; border: 1px solid rgba(255, 255, 255, .2); border-radius: 50%; background: transparent; cursor: pointer; font-size: 1.2rem; }
.notification-panel > section { padding: 18px; border-bottom: 1px solid var(--line); }
.panel-title { display: flex; justify-content: space-between; }
.panel-title b { min-width: 24px; height: 24px; display: grid; place-items: center; color: var(--deep); border-radius: 999px; background: var(--lime); font-size: .68rem; }
.panel-empty { color: var(--muted); font-size: .72rem; }
.notification-item { width: 100%; display: grid; grid-template-columns: 10px 1fr auto; align-items: center; gap: 10px; margin-top: 13px; padding: 13px; border: 1px solid #e7b8b0; border-radius: 10px; color: inherit; background: #fff5f3; cursor: pointer; text-align: left; }
.notification-item > i { width: 8px; height: 8px; border-radius: 50%; background: #d64f43; box-shadow: 0 0 0 5px rgba(214, 79, 67, .1); }
.notification-item strong, .notification-item small { display: block; }
.notification-item strong { font-size: .75rem; }
.notification-item small { margin-top: 4px; color: var(--muted); font-size: .61rem; }
.notification-item em { font-style: normal; }
.push-settings > strong { font-size: .8rem; }
.push-settings p { color: var(--muted); font-size: .68rem; line-height: 1.45; }
.push-settings button { min-height: 38px; padding: 8px 11px; color: var(--deep); border: 0; border-radius: 7px; background: var(--lime); cursor: pointer; font-size: .67rem; font-weight: 900; }

.conversation-drawer { width: min(430px, 96%); display: flex; flex-direction: column; z-index: 45; }
.conversation-drawer > header span { color: var(--lime); font-size: .55rem; font-weight: 900; letter-spacing: .11em; }
.conversation-drawer > header strong { font-size: 1rem; }
.chat-thread { flex: 1; overflow: auto; padding: 18px; background: #e8f0eb; }
.bubble { width: fit-content; max-width: 84%; margin: 0 0 11px; padding: 11px 13px; border-radius: 13px 13px 13px 3px; background: white; box-shadow: 0 4px 12px rgba(13, 53, 42, .06); font-size: .72rem; line-height: 1.48; }
.bubble.outgoing { margin-left: auto; border-radius: 13px 13px 3px 13px; background: #dff1cc; }
.bubble b { display: block; margin-bottom: 4px; color: var(--green); font-size: .58rem; }
.staff-message { background: var(--lime-soft) !important; }
.system-message { margin: 16px auto; padding: 7px 10px; color: #74443b; border-radius: 999px; background: #f5dcd6; font-size: .58rem; font-weight: 800; text-align: center; }
.system-message.success { color: #245f44; background: #dff1e6; }
.conversation-drawer > footer { display: grid; gap: 8px; padding: 15px; border-top: 1px solid var(--line); background: white; }
.toast { max-width: calc(100% - 40px); position: absolute; left: 50%; bottom: 22px; z-index: 70; transform: translateX(-50%); padding: 11px 16px; color: white; border-radius: 999px; background: var(--deep); box-shadow: 0 15px 40px rgba(0, 0, 0, .2); font-size: .72rem; font-weight: 800; }

.coach-panel { min-height: calc(100vh - 106px); position: sticky; top: 88px; display: flex; flex-direction: column; padding: 19px; background: #f9fbf8; }
.coach-panel > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.coach-panel > header span { color: var(--green); font-size: .59rem; font-weight: 900; letter-spacing: .11em; }
.coach-panel > header b { padding: 5px 7px; color: var(--deep); border-radius: 6px; background: var(--lime); font-size: .58rem; }
.coach-body { flex: 1; padding: 22px 1px; }
.coach-kicker { color: var(--coral); font-size: .62rem; font-weight: 900; letter-spacing: .14em; }
.coach-body h2 { margin: 10px 0 12px; font-size: 1.75rem; line-height: 1.04; letter-spacing: -.035em; }
.coach-body > p { margin: 0; color: var(--muted); font-size: .88rem; line-height: 1.65; }
.coach-action, .coach-check { margin-top: 24px; padding: 14px; border-radius: 11px; }
.coach-action { color: white; background: var(--ink); }
.coach-check { border-left: 3px solid var(--lime-strong); background: var(--surface); }
.coach-action strong, .coach-check span { color: var(--lime); font-size: .59rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.coach-check span { color: var(--green); }
.coach-action p, .coach-check p { margin: 8px 0 0; font-size: .77rem; line-height: 1.5; }
.coach-panel > footer { display: grid; grid-template-columns: 1fr 1.25fr; gap: 8px; }
.coach-note { margin: 10px 0 0; color: var(--muted); font-size: .6rem; text-align: center; }

.install-dialog { width: min(850px, calc(100% - 30px)); padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 22px; color: var(--ink); background: var(--paper); box-shadow: 0 40px 120px rgba(4, 27, 20, .35); }
.install-dialog::backdrop { background: rgba(4, 27, 20, .72); backdrop-filter: blur(8px); }
.dialog-close { width: 36px; height: 36px; position: absolute; right: 17px; top: 17px; color: white; border: 1px solid rgba(255, 255, 255, .23); border-radius: 50%; background: transparent; cursor: pointer; font-size: 1.25rem; z-index: 2; }
.install-intro { display: flex; align-items: center; gap: 17px; padding: 25px 68px 25px 27px; color: white; background: var(--deep); }
.app-icon { width: 72px; height: 72px; flex: 0 0 auto; overflow: hidden; border-radius: 17px; background: white; }
.app-icon img { width: 100%; height: 100%; object-fit: cover; }
.install-intro div > span { color: var(--lime); font-size: .6rem; font-weight: 900; letter-spacing: .14em; }
.install-intro h2 { margin: 7px 0 4px; font-size: 1.6rem; }
.install-intro p { margin: 0; color: #acc2b7; font-size: .78rem; }
.device-tabs { display: flex; gap: 5px; padding: 16px 24px 0; }
.device-tabs button { min-width: 130px; padding: 10px 15px; color: var(--muted); border: 1px solid var(--line); border-radius: 9px; background: white; cursor: pointer; font-size: .76rem; font-weight: 850; }
.device-tabs button.is-active { color: var(--deep); border-color: var(--lime); background: var(--lime); }
.install-content { display: grid; grid-template-columns: 1fr 260px; gap: 24px; padding: 20px 24px; }
.install-content ol { list-style: none; display: grid; gap: 11px; margin: 0; padding: 0; counter-reset: install; }
.install-content li { min-height: 58px; display: grid; grid-template-columns: 34px 1fr; gap: 11px; align-items: center; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; background: white; }
.install-content li::before { counter-increment: install; content: counter(install); width: 31px; height: 31px; display: grid; place-items: center; color: var(--deep); border-radius: 50%; background: var(--lime); font-size: .68rem; font-weight: 900; }
.install-content li strong, .install-content li small { display: block; }
.install-content li strong { font-size: .78rem; }
.install-content li small { margin-top: 3px; color: var(--muted); font-size: .64rem; line-height: 1.35; }
.install-content aside { display: grid; place-items: center; align-content: center; padding: 17px; border-radius: 14px; background: var(--surface); text-align: center; }
.install-content aside img { width: 170px; height: 170px; background: white; }
.install-content aside strong { margin-top: 12px; font-size: .83rem; }
.install-content aside small { max-width: 210px; margin-top: 6px; color: var(--muted); font-size: .61rem; overflow-wrap: anywhere; }
.install-dialog > footer { display: flex; justify-content: flex-end; padding: 0 24px 24px; }

.reference-dialog { width: min(980px, calc(100% - 30px)); max-height: min(900px, calc(100vh - 30px)); padding: 0; overflow: auto; border: 1px solid var(--line); border-radius: 22px; color: var(--ink); background: var(--paper); box-shadow: 0 40px 120px rgba(4, 27, 20, .35); }
.reference-dialog::backdrop { background: rgba(4, 27, 20, .72); backdrop-filter: blur(8px); }
.reference-intro { display: flex; align-items: center; gap: 17px; padding: 25px 68px 25px 27px; color: white; background: linear-gradient(135deg, var(--deep), var(--green)); }
.reference-intro div > span { color: var(--lime); font-size: .6rem; font-weight: 900; letter-spacing: .14em; }
.reference-intro h2 { margin: 7px 0 4px; font-size: 1.6rem; }
.reference-intro p { margin: 0; color: #c5d6ce; font-size: .78rem; }
.reference-content { display: grid; grid-template-columns: 1.1fr .9fr; gap: 14px; padding: 20px 24px; }
.reference-content > section { padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: white; }
.reference-flow, .reference-status { grid-column: span 1; }
.reference-rules, .reference-launch { grid-column: 1 / -1; }
.section-heading { display: flex; align-items: center; gap: 11px; margin-bottom: 14px; }
.section-heading > span { width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; color: var(--deep); border-radius: 50%; background: var(--lime); font-size: .68rem; font-weight: 900; }
.section-heading small { color: var(--green); font-size: .58rem; font-weight: 900; letter-spacing: .12em; }
.section-heading h3 { margin: 3px 0 0; font-size: 1rem; }
.reference-flow ol { list-style: none; display: grid; gap: 9px; margin: 0; padding: 0; }
.reference-flow li { display: grid; grid-template-columns: 74px 1fr; gap: 9px; padding: 10px; border-radius: 9px; background: var(--surface); font-size: .72rem; line-height: 1.45; }
.reference-flow li b { color: var(--green); }
.status-reference-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.status-reference-grid article { padding: 11px; border-radius: 10px; background: var(--surface); }
.status-reference-grid strong { font-size: .72rem; }
.status-reference-grid p { margin: 5px 0 0; color: var(--muted); font-size: .65rem; line-height: 1.4; }
.reference-note { margin: 10px 0 0; padding: 10px; color: #684720; border-radius: 9px; background: #fff3d2; font-size: .67rem; line-height: 1.45; }
.reference-rules ul { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 28px; margin: 0; padding-left: 18px; color: var(--muted); font-size: .72rem; line-height: 1.5; }
.reference-rules li::marker { color: var(--green); }
.reference-launch { color: white; background: var(--ink) !important; }
.reference-launch .section-heading > span { color: var(--deep); }
.reference-launch .section-heading small { color: var(--lime); }
.reference-launch p { margin: 0; color: #c5d6ce; font-size: .76rem; line-height: 1.6; }
.reference-dialog > footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 24px 24px; }
.reference-dialog > footer small { color: var(--muted); font-size: .62rem; }
.reference-dialog > footer div { display: flex; gap: 8px; }

[hidden] { display: none !important; }

@media (max-width: 1400px) {
  .training-layout { grid-template-columns: 220px minmax(620px, 1fr) 285px; padding: 12px; gap: 12px; }
  .lesson-rail, .coach-panel { padding: 16px; }
  .pwa-header nav button { padding: 8px 7px; }
  .language-switch i { display: none; }
  .workspace-content { padding: 22px; }
}

@media (max-width: 1120px) {
  .training-layout { grid-template-columns: 210px minmax(0, 1fr); }
  .coach-panel { min-height: auto; position: static; grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1.6fr auto; gap: 18px; align-items: center; }
  .coach-panel > header { display: grid; justify-content: start; border: 0; padding: 0; }
  .coach-body { padding: 0; display: grid; grid-template-columns: 130px 1fr; gap: 5px 20px; align-items: center; }
  .coach-body h2 { margin: 0; font-size: 1.35rem; }
  .coach-body > p { grid-column: 2; }
  .coach-action, .coach-check { display: none; }
  .coach-panel > footer { width: 230px; }
  .coach-note { display: none; }
  .pwa-header { grid-template-columns: 1fr auto; }
  .pwa-header nav { display: none; }
}

@media (max-width: 780px) {
  .training-header { padding: 10px 13px; }
  .brand { font-size: .68rem; }
  .brand small, .sample-chip, #resetDemo, #referenceGuide { display: none; }
  .share-button { min-height: 36px; padding: 7px 10px; font-size: .7rem; }
  .training-layout { display: block; padding: 9px; }
  .lesson-rail { min-height: auto; position: static; padding: 14px; border-radius: 15px; }
  .rail-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
  .rail-heading strong { margin: 0; font-size: 1rem; }
  .rail-heading > span, .rail-heading p { display: none; }
  .lesson-rail ol { display: flex; overflow-x: auto; margin: 12px 0; padding-bottom: 2px; scrollbar-width: none; }
  .lesson-rail li { flex: 0 0 auto; }
  .lesson-rail li button { min-height: 42px; grid-template-columns: 28px 1fr; padding: 6px 9px; }
  .lesson-rail li button b { width: 27px; height: 27px; }
  .lesson-rail li button small { display: none; }
  .rail-progress { margin: 0; }
  .demo-frame { min-height: 760px; margin-top: 9px; border-radius: 15px; }
  .pwa-header { min-height: 60px; padding: 9px 12px; }
  .pwa-brand strong { display: none; }
  .language-switch { display: none; }
  .workspace-content { padding: 18px 14px 90px; }
  .workspace-hero { align-items: flex-start; }
  .workspace-hero h1 { font-size: 2.7rem; }
  .workspace-hero div > p:last-child { font-size: .78rem; }
  .live-sync { display: none; }
  .metrics { grid-template-columns: 1fr 1fr; }
  .metrics article:nth-child(2) { border-right: 0; }
  .metrics article { min-height: 86px; border-bottom: 1px solid var(--line); }
  .metrics article:nth-child(3), .metrics article:nth-child(4) { border-bottom: 0; }
  .training-banner { align-items: flex-start; flex-direction: column; }
  .training-banner .primary-button { width: 100%; }
  .lead-toolbar { grid-template-columns: 1fr; }
  .lead-toolbar > div { overflow-x: auto; }
  .customer-filters { flex-wrap: nowrap; padding-bottom: 3px; }
  .customer-filters button { flex: 0 0 auto; }
  .customer-card-summary { align-items: flex-start; padding: 14px; }
  .customer-alert { padding: 0 14px 13px 64px; }
  .customer-details { padding: 13px; }
  .reception-panel { align-items: stretch; flex-direction: column; }
  .primary-action { width: 100%; }
  .latest-facts { grid-template-columns: 1fr; }
  .latest-facts > div { border-right: 0; border-bottom: 1px solid var(--line); }
  .latest-facts > div:last-child { border-bottom: 0; }
  .issue-item { grid-template-columns: 1fr; }
  .issue-item > div { justify-content: flex-start; }
  .lead-card > header { display: grid; }
  .lead-badges { justify-content: flex-start; }
  .lead-facts { grid-template-columns: 1fr 1fr; }
  .lead-facts > div:nth-child(2) { border-right: 0; }
  .lead-facts > div:nth-child(1), .lead-facts > div:nth-child(2) { border-bottom: 1px solid var(--line); }
  .coach-panel { margin-top: 9px; display: block; padding: 16px; border-radius: 15px; }
  .coach-panel > header { display: flex; justify-content: space-between; padding-bottom: 12px; }
  .coach-body { display: block; padding: 16px 0; }
  .coach-body h2 { margin: 8px 0; }
  .coach-body > p { font-size: .82rem; }
  .coach-panel > footer { width: 100%; }
  .notification-panel, .conversation-drawer { height: calc(100% - 60px); top: 60px; }
  .install-content { grid-template-columns: 1fr; }
  .install-content aside { grid-template-columns: 120px 1fr; justify-items: start; gap: 4px 14px; text-align: left; }
  .install-content aside img { width: 120px; height: 120px; grid-row: 1 / 3; }
  .install-content aside strong { margin: 0; }
  .reference-content { grid-template-columns: 1fr; padding: 14px; }
  .reference-flow, .reference-status, .reference-rules, .reference-launch { grid-column: 1; }
  .reference-rules ul { grid-template-columns: 1fr; }
  .reference-intro { padding: 20px 54px 20px 18px; }
  .reference-intro h2 { font-size: 1.25rem; }
  .reference-dialog > footer { align-items: stretch; flex-direction: column; padding: 0 14px 16px; }
  .reference-dialog > footer div { display: grid; grid-template-columns: 1fr 1fr; }
}

@media print {
  body { background: white; }
  body > *:not(.reference-dialog) { display: none !important; }
  .reference-dialog[open] { width: 100%; max-height: none; display: block; position: static; border: 0; box-shadow: none; }
  .reference-dialog .dialog-close, .reference-dialog > footer div { display: none; }
  .reference-content { padding: 14px 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
