:root {
  --ink: #1b1917;
  --muted: #746b63;
  --line: #e6ded6;
  --paper: #ffffff;
  --surface: #f5f2ee;
  --night: #1b1917;
  --navy: #2e241e;
  --blue: #ff833d;
  --gold: #ff833d;
  --green: #1f9d68;
  --radius: 18px;
}

@font-face { font-family:"Actay Wide"; src:url("ActayWide-Bold.otf") format("opentype"); font-weight:600; font-style:normal; font-display:swap; }

* { box-sizing: border-box; }
html { font-size: 16px; }
body { margin: 0; color: var(--ink); background: var(--surface); font-family: "Golos Text", system-ui, sans-serif; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 264px 1fr; }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 24px 18px 18px; color: #d8dfeb; background: var(--night); }
.brand { display: flex; align-items: center; gap: 12px; padding: 0 8px 26px; color: white; text-decoration: none; }
.brand-mark { width:38px; height:38px; display:grid; place-items:center; overflow:hidden; padding:5px; border:3px solid #fff; border-radius:50%; background:#000; box-shadow:0 5px 14px rgba(0,0,0,.24); }
.brand-mark img { width:100%; height:100%; display:block; object-fit:cover; }
.brand b, .brand small { display: block; }
.brand b { font-size: 1rem; }
.brand small { margin-top: 2px; color: #8e9bb0; font-size: .72rem; letter-spacing: .06em; }
.side-nav { display: grid; gap: 7px; }
.nav-item { position:relative; display: flex; align-items: center; gap: 12px; min-height: 46px; padding: 0 13px; border-radius: 12px; color: #aeb8c9; text-decoration: none; font-size: .9rem; font-weight: 600; transition: .2s ease; }
.nav-item:hover { color: white; background: #172337; }
.nav-item.active { color: white; background: #20304a; box-shadow: inset 3px 0 var(--gold); }
.nav-icon { width: 22px; text-align: center; color: #dbe2ec; font-size: 1.15rem; }
.nav-attention-badge { position:absolute; top:50%; right:10px; min-width:20px; height:20px; display:grid; place-items:center; padding:0 6px; border:2px solid var(--night); border-radius:999px; color:#fff; background:#ff7140; box-shadow:0 4px 12px rgba(255,113,64,.35); transform:translateY(-50%); font-size:.62rem; font-weight:900; line-height:1; }
.nav-attention-badge.is-hidden { display:none; }
.nav-item.active .nav-attention-badge { border-color:#302a25; background:#fff; color:#d95425; box-shadow:none; }
.sidebar-bottom { position: relative; margin-top: auto; display: grid; gap: 18px; }
.support-button { width: 100%; display: flex; align-items: center; gap: 10px; padding: 13px; border: 1px solid #2b3b56; border-radius: 14px; color: #dbe4ef; background: #172337; text-align: left; cursor: pointer; }
.support-button > span:first-child { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 9px; color: #172033; background: var(--gold); font-weight: 800; }
.support-button b, .support-button small { display: block; }
.support-button b { font-size: .77rem; }
.support-button small { margin-top: 2px; color: #8e9bb0; font-size: .68rem; }
.profile-mini { display: grid; grid-template-columns: 32px minmax(0, 1fr) 18px; align-items: center; gap: 7px; padding: 14px 2px 2px; border-top: 1px solid #26344b; }
.avatar { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; color: white; background: linear-gradient(135deg, #315c9b, #1f3354); font-size: .74rem; font-weight: 800; }
.profile-copy { min-width: 0; }
.profile-mini b, .profile-mini small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.profile-mini b { color: white; font-size: .72rem; }
.profile-mini small { margin-top: 3px; color: #8e9bb0; font-size: .6rem; letter-spacing: -.015em; }
.profile-mini .avatar { width: 32px; height: 32px; }
.profile-mini .icon-button { width: 18px; height: 28px; display: grid; place-items: center; overflow: hidden; padding: 0; border-radius: 7px; }
.profile-mini .icon-button svg { width: 14px; height: 4px; fill: currentColor; }
.profile-mini .icon-button:hover { color: #dce5f2; background: #243651; }
.profile-mini .icon-button:focus-visible { outline: 2px solid #6f8db7; outline-offset: 1px; }
.icon-button, .notification-button, .mobile-menu { border: 0; background: transparent; cursor: pointer; }
.icon-button { color: #758197; }
.profile-menu { position: absolute; left: 0; bottom: 62px; z-index: 30; width: 260px; overflow: hidden; padding: 7px; border: 1px solid #31415b; border-radius: 14px; background: #172337; box-shadow: 0 18px 45px rgba(0,0,0,.28); }
.profile-menu button { width: 100%; min-height: 52px; display: grid; grid-template-columns: 24px minmax(0, 1fr); align-items: center; gap: 10px; padding: 8px 11px; border: 0; border-radius: 9px; color: #dce5f2; background: transparent; text-align: left; cursor: pointer; }
.profile-menu button:hover, .profile-menu button:focus-visible { color: white; background: #243651; outline: none; }
.profile-menu span { width: 22px; color: #9fb0c7; text-align: center; }
.profile-menu button > div { min-width: 0; display: grid; gap: 2px; }
.profile-menu button b, .profile-menu button small { display: block; line-height: 1.3; }
.profile-menu button b { color: white; font-size: .76rem; }
.profile-menu button small { color: #9eabc0; font-size: .64rem; white-space: normal; }
.main-column { min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 20; min-height: 72px; display: flex; align-items: center; gap: 24px; padding: 0 32px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.94); backdrop-filter: blur(14px); }
.crumbs { color: #6c778b; font-size: .8rem; font-weight: 600; }
.crumbs span { margin: 0 8px; color: #c2c7d0; }
.global-search { width: min(410px, 38vw); margin-left: auto; display: flex; align-items: center; gap: 9px; padding: 0 12px; border: 1px solid #dfe4eb; border-radius: 11px; background: #f7f8fa; }
.global-search input { width: 100%; min-height: 40px; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: .82rem; }
.fx-topbar { min-height:40px; display:flex; align-items:center; gap:9px; flex:0 0 auto; padding:0 11px; border:1px solid #ead9cf; border-radius:11px; color:#9f421f; background:#fff8f3; }
.fx-topbar .fx-live-dot { width:8px; height:8px; flex:0 0 8px; }
.fx-topbar div { display:grid; gap:1px; line-height:1.05; }
.fx-topbar small { color:#8f8177; font-size:.48rem; font-weight:700; white-space:nowrap; }
.fx-topbar b { font-size:.63rem; white-space:nowrap; }
.global-search kbd { padding: 2px 6px; border: 1px solid #d7dbe2; border-radius: 5px; color: #8a94a6; background: white; font: 600 .67rem/1.4 "Golos Text"; }
.notification-button { position: relative; width: 38px; height: 38px; border: 1px solid #e0e4ea; border-radius: 11px; background: white; }
.notification-button span { position: absolute; top: 7px; right: 7px; width: 7px; height: 7px; border: 2px solid white; border-radius: 50%; background: #eb5b52; }
.mobile-menu { display: none; font-size: 1.3rem; }
.workspace { width: min(1240px, 100%); margin: 0 auto; padding: 42px 40px 56px; }
.welcome-row { display: flex; align-items: end; justify-content: space-between; gap: 28px; margin-bottom: 30px; }
.eyebrow, .card-kicker { margin: 0 0 7px; color: #7c8799; font-size: .7rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 8px; font-size: clamp(1.8rem, 3vw, 2.45rem); line-height: 1.15; letter-spacing: -.035em; }
.lead { margin-bottom: 0; color: var(--muted); font-size: .95rem; }
.primary-button { min-height: 46px; display: inline-flex; align-items: center; justify-content: center; gap: 16px; padding: 0 20px; border: 0; border-radius: 12px; color: white; background: var(--blue); box-shadow: 0 8px 20px rgba(41,103,232,.2); font-size: .84rem; font-weight: 800; cursor: pointer; }
.primary-button.compact { min-height: 42px; margin-top: 18px; padding: 0 16px; font-size: .78rem; box-shadow: none; }
.dashboard-grid { display: grid; grid-template-columns: 1.55fr .9fr; gap: 20px; }
.continue-card, .status-card { min-width: 0; padding: 25px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: 0 10px 30px rgba(23,32,51,.04); }
.card-kicker { display: flex; align-items: center; gap: 8px; }
.kicker-icon { color: var(--blue); font-size: 1rem; }
.continue-content { display: grid; grid-template-columns: 160px 1fr; gap: 26px; align-items: center; margin-top: 23px; }
.module-art { position: relative; height: 196px; overflow: hidden; display: grid; place-items: center; border-radius: 16px; color: white; background: linear-gradient(145deg, #16345f, #2c66a5); }
.module-art:before { content: ""; position: absolute; inset: 18px; border: 1px solid rgba(255,255,255,.2); border-radius: 50%; }
.module-art span { position: relative; z-index: 2; font-size: 3.2rem; font-weight: 800; letter-spacing: -.06em; }
.module-art i { position: absolute; width: 90px; height: 90px; border: 1px solid rgba(255,255,255,.12); border-radius: 50%; }
.module-art i:nth-of-type(1) { right: -25px; top: -15px; }
.module-art i:nth-of-type(2) { left: -30px; bottom: -25px; width: 120px; height: 120px; }
.module-art i:nth-of-type(3) { width: 22px; height: 22px; background: var(--gold); border: 0; right: 24px; bottom: 24px; }
.meta { margin-bottom: 8px; color: var(--blue); font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.continue-content h2, .status-card h2 { margin-bottom: 10px; font-size: 1.23rem; line-height: 1.3; letter-spacing: -.02em; }
.continue-content p:not(.meta) { margin-bottom: 18px; color: var(--muted); font-size: .82rem; line-height: 1.7; }
.progress-line { height: 7px; overflow: hidden; border-radius: 8px; background: #e9edf3; }
.progress-line span { display: block; height: 100%; border-radius: inherit; background: var(--gold); }
.progress-meta { display: flex; justify-content: space-between; margin-top: 8px; color: #7c8799; font-size: .68rem; font-weight: 700; }
.card-heading { display: flex; justify-content: space-between; gap: 16px; }
.score-ring { width: 60px; height: 60px; display: grid; place-items: center; flex: 0 0 auto; border: 6px solid #e6eefb; border-top-color: var(--blue); border-right-color: var(--blue); border-radius: 50%; color: var(--navy); font-size: 1rem; font-weight: 800; }
.score-ring small { font-size: .62rem; }
.steps-list { display: grid; gap: 4px; margin: 17px 0 0; padding: 0; list-style: none; }
.steps-list li { display: grid; grid-template-columns: 30px 1fr; align-items: center; gap: 11px; min-height: 53px; padding: 8px; border-radius: 11px; }
.steps-list li > span { width: 27px; height: 27px; display: grid; place-items: center; border: 1px solid #d9dee7; border-radius: 50%; color: #8b95a6; font-size: .7rem; font-weight: 800; }
.steps-list li b, .steps-list li small { display: block; }
.steps-list li b { font-size: .76rem; }
.steps-list li small { margin-top: 3px; color: #8892a2; font-size: .66rem; }
.steps-list li.done > span { border-color: #c9eddc; color: var(--green); background: #eaf8f1; }
.steps-list li.active { background: #f3f7fd; }
.steps-list li.active > span { border-color: var(--blue); color: white; background: var(--blue); }
.quick-section { margin-top: 34px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.section-heading h2 { margin-bottom: 0; font-size: 1.25rem; }
.text-button { border: 0; color: var(--blue); background: transparent; font-size: .78rem; font-weight: 800; cursor: pointer; }
.answer-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.answer-card { min-height: 120px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; padding: 18px; border: 1px solid var(--line); border-radius: 15px; background: white; text-align: left; cursor: pointer; transition: transform .2s ease, box-shadow .2s ease; }
.answer-card:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(23,32,51,.08); }
.answer-symbol { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; font-size: .9rem; font-weight: 800; }
.answer-symbol.blue { color: #245bc4; background: #eaf1ff; }
.answer-symbol.amber { color: #9f6507; background: #fff4d8; }
.answer-symbol.violet { color: #794fc2; background: #f2eaff; }
.answer-card small, .answer-card b, .answer-card em { display: block; }
.answer-card small { margin-bottom: 5px; color: #8a94a5; font-size: .63rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; }
.answer-card b { font-size: .78rem; line-height: 1.4; }
.answer-card em { margin-top: 7px; color: #929baa; font-size: .62rem; font-style: normal; }
.answer-card .arrow { color: #9ca5b4; }
.is-hidden { display: none !important; }
.page-view { animation: pageIn .35s ease both; }
@keyframes pageIn { from { opacity: 0; transform: translateY(7px); } to { opacity: 1; transform: none; } }
.suppress-page-animation .page-view { animation: none !important; }
.app-booting { min-height:100vh; overflow:hidden; background:var(--bg); }
.app-booting .auth-gate,.app-booting .app-shell { visibility:hidden !important; }
.app-booting::before { content:"Грандшеф"; position:fixed; z-index:9998; inset:0; display:grid; place-items:center; padding-bottom:62px; color:var(--text); font-size:.92rem; font-weight:800; letter-spacing:.04em; }
.app-booting::after { content:""; position:fixed; z-index:9999; top:calc(50% + 18px); left:50%; width:24px; height:24px; margin:-12px 0 0 -12px; border:3px solid rgba(217,95,47,.18); border-top-color:#d95f2f; border-radius:50%; animation:boot-spin .7s linear infinite; }
@keyframes boot-spin { to { transform:rotate(360deg); } }
.page-hero { position: relative; min-height: 190px; display: flex; align-items: center; justify-content: space-between; gap: 30px; overflow: hidden; margin-bottom: 24px; padding: 34px 38px; border-radius: 24px; color: white; background: linear-gradient(120deg, #11243f 0%, #173b6c 58%, #24538e 100%); box-shadow: 0 16px 40px rgba(15,37,68,.18); }
.page-hero:after { content: ""; position: absolute; width: 240px; height: 240px; right: -65px; bottom: -135px; border: 1px solid rgba(255,255,255,.15); border-radius: 50%; box-shadow: 0 0 0 38px rgba(255,255,255,.035), 0 0 0 76px rgba(255,255,255,.025); }
.page-hero > * { position: relative; z-index: 2; }
.page-hero .eyebrow { color: #a9c2e3; }
.page-hero h1 { margin-bottom: 10px; }
.page-hero .lead { max-width: 680px; color: #cedbeb; line-height: 1.65; }
.hero-stat { min-width: 150px; display: flex; align-items: center; gap: 12px; padding: 18px 20px; border: 1px solid rgba(255,255,255,.18); border-radius: 18px; background: rgba(255,255,255,.08); backdrop-filter: blur(8px); }
.hero-stat b { font-size: 2rem; letter-spacing: -.06em; }
.hero-stat span { color: #cdd9e9; font-size: .72rem; line-height: 1.45; }
.knowledge-toolbar { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.knowledge-search { flex: 1; min-height: 50px; display: flex; align-items: center; gap: 10px; padding: 0 16px; border: 1px solid var(--line); border-radius: 14px; background: white; box-shadow: 0 8px 25px rgba(23,32,51,.035); }
.knowledge-search input { width: 100%; border: 0; outline: 0; font-size: .86rem; }
.filter-chips { display: flex; gap: 7px; flex-wrap: wrap; }
.filter-chip { min-height: 38px; padding: 0 13px; border: 1px solid #dde2ea; border-radius: 999px; color: #637086; background: white; font-size: .72rem; font-weight: 800; cursor: pointer; }
.filter-chip:hover, .filter-chip.active { border-color: #244f87; color: white; background: #244f87; }
.knowledge-layout { display: grid; grid-template-columns: 210px 1fr; gap: 22px; }
.category-panel { align-self: start; padding: 20px 16px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.panel-label { margin: 0 8px 12px; color: #98a1b0; font-size: .64rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
#category-list { display: grid; gap: 3px; }
.category-link { width: 100%; display: flex; align-items: center; justify-content: space-between; min-height: 38px; padding: 0 9px; border: 0; border-radius: 9px; color: #59667a; background: transparent; text-align: left; font-size: .72rem; font-weight: 700; cursor: pointer; }
.category-link:hover, .category-link.active { color: #1f4e86; background: #edf4fd; }
.category-link span { color: #9da6b4; font-size: .64rem; }
.update-note { display: flex; gap: 9px; margin-top: 18px; padding: 13px 9px 2px; border-top: 1px solid var(--line); }
.update-note > span { width: 22px; height: 22px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; color: var(--green); background: #e7f7ef; font-size: .65rem; }
.update-note b, .update-note small { display: block; }
.update-note b { font-size: .66rem; }
.update-note small { margin-top: 3px; color: #929baa; font-size: .58rem; line-height: 1.4; }
.result-heading { min-height: 38px; display: flex; justify-content: space-between; align-items: center; color: #788395; font-size: .72rem; font-weight: 700; }
.sort-button { max-width:190px; min-height:36px; padding:0 28px 0 10px; border:1px solid transparent; border-radius:9px; outline:0; color:#647084; background:transparent; font:inherit; font-size:.68rem; font-weight:700; cursor:pointer; }
.sort-button:hover,.sort-button:focus { border-color:var(--line); background:var(--paper); }
.knowledge-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.knowledge-card { position: relative; min-height: 186px; display: flex; flex-direction: column; align-items: flex-start; padding: 19px; border: 1px solid var(--line); border-radius: 16px; background: white; text-align: left; box-shadow: 0 8px 25px rgba(23,32,51,.025); cursor: pointer; transition: .2s ease; }
.knowledge-card:hover { transform: translateY(-2px); border-color: #c9d6e8; box-shadow: 0 12px 26px rgba(23,49,84,.08); }
.knowledge-card-top { width:100%; display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:start; gap:10px; margin-bottom:15px; }
.topic-pill { padding: 5px 8px; border-radius: 7px; color: #2860a4; background: #edf4fd; font-size: .58rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.access-mark { color: #858fa0; font-size: .58rem; font-weight: 700; }
.knowledge-card-top .topic-pill { min-width:0; max-width:100%; justify-self:start; white-space:normal; overflow-wrap:anywhere; line-height:1.25; }
.knowledge-card-top .access-mark { justify-self:end; white-space:nowrap; text-align:right; }
.access-mark.public { color: #268460; }
.knowledge-card h2 { margin: 0 0 9px; font-size: .91rem; line-height: 1.45; letter-spacing: -.01em; }
.knowledge-card p { margin-bottom: 16px; color: #758094; font-size: .7rem; line-height: 1.55; }
.card-footer { width: 100%; display: flex; justify-content: space-between; align-items: center; margin-top: auto; color: #929baa; font-size: .61rem; }
.card-footer b { color: #55708f; font-weight: 800; }
.empty-state { padding: 70px 24px; border: 1px dashed #d8dee8; border-radius: 18px; background: white; text-align: center; }
.empty-state > span { font-size: 2rem; color: #a4adbb; }
.empty-state h2 { margin: 12px 0 6px; font-size: 1rem; }
.empty-state p { color: #818b9b; font-size: .75rem; }
.secondary-button { min-height: 40px; padding: 0 14px; border: 1px solid #cfd7e3; border-radius: 10px; background: white; font-size: .72rem; font-weight: 800; cursor: pointer; }
.course-overview { display: flex; align-items: center; gap: 14px; padding: 15px 19px; border: 1px solid rgba(255,255,255,.18); border-radius: 18px; background: rgba(255,255,255,.08); }
.course-ring { width: 58px; height: 58px; display: grid; place-items: center; border: 6px solid rgba(255,255,255,.18); border-top-color: var(--gold); border-right-color: var(--gold); border-radius: 50%; font-size: .78rem; }
.course-overview > div:last-child b, .course-overview > div:last-child span { display: block; }
.course-overview > div:last-child b { font-size: .78rem; }
.course-overview > div:last-child span { margin-top: 4px; color: #c7d5e6; font-size: .64rem; }
.branch-banner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; margin-bottom: 20px; padding: 15px 20px; border: 1px solid #d9e6f7; border-radius: 15px; background: #edf4fd; }
.branch-icon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: #8b5c05; background: #ffe9b6; }
.branch-banner b { font-size: .78rem; }
.branch-banner p { margin: 3px 0 0; color: #6e7b8f; font-size: .68rem; }
.course-layout { display: grid; grid-template-columns: 1fr 280px; gap: 20px; }
.module-list { display: grid; gap: 11px; }
.module-item { display: grid; grid-template-columns: 58px 1fr auto; align-items: center; gap: 16px; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.module-number { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 13px; color: #667286; background: #f0f2f6; font-weight: 800; }
.module-item.done .module-number { color: var(--green); background: #e7f7ef; }
.module-item.active { border-color: #b9cdec; box-shadow: 0 10px 25px rgba(35,81,137,.08); }
.module-item.active .module-number { color: #173b6c; background: #dceafd; }
.module-item h2 { margin: 0 0 5px; font-size: .88rem; }
.module-item p { margin: 0; color: #7e8999; font-size: .68rem; line-height: 1.5; }
.module-item button { min-width: 104px; min-height: 37px; border: 1px solid #d9dfe8; border-radius: 10px; color: #526178; background: white; font-size: .68rem; font-weight: 800; cursor: pointer; }
.module-item.active button { border-color: var(--blue); color: white; background: var(--blue); }
.module-item.locked { opacity: .65; }
.course-aside { display: grid; align-content: start; gap: 14px; }
.aside-card { padding: 22px; border: 1px solid var(--line); border-radius: 17px; background: white; }
.dark-card { color: white; background: linear-gradient(145deg, #17263f, #234b7c); }
.dark-card .eyebrow { color: #9fb8d7; }
.aside-card h2 { font-size: 1.12rem; line-height: 1.35; }
.aside-card p { color: #c3d0df; font-size: .7rem; line-height: 1.6; }
.gold-button { min-height: 39px; padding: 0 13px; border: 0; border-radius: 10px; color: #182235; background: var(--gold); font-size: .7rem; font-weight: 800; cursor: pointer; }
.aside-head { display: flex; align-items: center; gap: 10px; font-size: .77rem; }
.medal { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 9px; color: #9b650d; background: #fff0ca; }
.aside-card ul { display: grid; gap: 10px; margin: 16px 0 0; padding-left: 17px; color: #657185; font-size: .68rem; line-height: 1.45; }
.media-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 32px; }
.media-summary > div { display: grid; grid-template-columns: auto auto 1fr; align-items: center; gap: 10px; padding: 17px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.media-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; color: #25558e; background: #ebf3fd; font-weight: 800; }
.media-summary b { font-size: 1.3rem; }
.media-summary small { color: #7c8797; font-size: .66rem; }
.media-title { align-items: center; }
.media-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.media-card { overflow: hidden; border: 1px solid var(--line); border-radius: 17px; background: white; box-shadow: 0 8px 28px rgba(23,32,51,.04); }
.media-preview { position: relative; height: 170px; overflow: hidden; display: grid; place-items: center; color: white; }
.media-preview:before { content: ""; position: absolute; width: 170px; height: 170px; border: 1px solid rgba(255,255,255,.18); border-radius: 50%; box-shadow: 0 0 0 32px rgba(255,255,255,.05); }
.media-preview.cobalt { background: linear-gradient(135deg, #173b6c, #397cc2); }
.media-preview.gold { color: #2b2417; background: linear-gradient(135deg, #f3b335, #ffd886); }
.media-preview.plum { background: linear-gradient(135deg, #4a3469, #885fa3); }
.media-preview em { position: absolute; right: 12px; bottom: 11px; padding: 4px 7px; border-radius: 6px; color: white; background: rgba(16,24,40,.62); font-size: .58rem; font-style: normal; }
.play { position: relative; z-index: 2; width: 48px; height: 48px; display: grid; place-items: center; padding-left: 3px; border-radius: 50%; color: #16345f; background: white; }
.big-type { position: relative; z-index: 2; font-size: 4rem; font-weight: 800; letter-spacing: -.08em; }
.story-stack { position: relative; z-index: 2; font-size: 1.4rem; letter-spacing: .1em; transform: rotate(-6deg); }
.media-card > div:last-child { padding: 18px; }
.media-card small { color: #798597; font-size: .62rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.media-card h2 { margin: 8px 0 7px; font-size: .9rem; }
.media-card p { min-height: 38px; color: #7e899a; font-size: .68rem; line-height: 1.5; }
.download-button { width: 100%; min-height: 38px; display: flex; justify-content: space-between; align-items: center; padding: 0 12px; border: 1px solid #dfe4eb; border-radius: 9px; background: white; font-size: .68rem; font-weight: 800; cursor: pointer; }
.fresh-badge { padding: 8px 11px; border: 1px solid rgba(255,255,255,.2); border-radius: 999px; color: #fff4d7; background: rgba(245,182,66,.15); font-size: .7rem; font-weight: 800; }
.news-layout { display: grid; grid-template-columns: 1fr 1.15fr; gap: 20px; }
.featured-news { min-height: 340px; display: grid; grid-template-columns: auto 1fr; align-content: end; gap: 18px; padding: 28px; border-radius: 20px; color: white; background: linear-gradient(145deg, #172943 0%, #214d82 100%); box-shadow: 0 14px 34px rgba(22,52,95,.14); }
.news-date { width: 60px; height: 68px; display: grid; place-items: center; align-content: center; border-radius: 15px; color: #202a3a; background: var(--gold); }
.news-date b, .news-date span { display: block; }
.news-date b { font-size: 1.35rem; line-height: 1; }
.news-date span { font-size: .6rem; text-transform: uppercase; }
.news-tag { display: inline-flex; margin-bottom: 12px; padding: 5px 8px; border-radius: 7px; color: #d9e6f6; background: rgba(255,255,255,.1); font-size: .58rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.featured-news h2 { font-size: 1.45rem; line-height: 1.35; }
.featured-news p { color: #cad8e8; font-size: .72rem; line-height: 1.7; }
.featured-news .text-button { padding: 0; color: #ffd987; }
.news-list { display: grid; gap: 12px; }
.news-list article { display: grid; grid-template-columns: 78px 12px 1fr; gap: 12px; padding: 21px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.news-list time { color: #929baa; font-size: .62rem; }
.news-dot { width: 8px; height: 8px; margin-top: 3px; border-radius: 50%; }
.blue-dot { background: #3a75bf; box-shadow: 0 0 0 5px #eaf2fb; }
.gold-dot { background: var(--gold); box-shadow: 0 0 0 5px #fff6df; }
.gray-dot { background: #9aa4b3; box-shadow: 0 0 0 5px #eef0f4; }
.news-list small { color: #718096; font-size: .58rem; font-weight: 800; text-transform: uppercase; }
.news-list h2 { margin: 6px 0; font-size: .84rem; }
.news-list p { margin: 0; color: #7b8697; font-size: .67rem; line-height: 1.5; }
.modal-backdrop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(10,17,29,.64); backdrop-filter: blur(7px); }
.modal-card { position: relative; width: min(650px, 100%); max-height: 90vh; overflow-y: auto; padding: 32px; border-radius: 22px; background: white; box-shadow: 0 30px 80px rgba(0,0,0,.25); animation: modalIn .25s ease both; }
@keyframes modalIn { from { opacity: 0; transform: scale(.97) translateY(8px); } to { opacity: 1; transform: none; } }
.modal-close { position: absolute; top: 15px; right: 15px; width: 34px; height: 34px; border: 0; border-radius: 10px; color: #6d7788; background: #f1f3f6; font-size: 1.25rem; cursor: pointer; }
.modal-label { display: inline-flex; margin-bottom: 14px; padding: 6px 9px; border-radius: 7px; color: #2860a4; background: #edf4fd; font-size: .62rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; }
.modal-card h2 { padding-right: 30px; font-size: 1.55rem; line-height: 1.35; letter-spacing: -.025em; }
.modal-card p { color: #626f82; font-size: .84rem; line-height: 1.75; }
.modal-facts { display: grid; gap: 8px; margin: 20px 0; padding: 0; list-style: none; }
.modal-facts li { display: flex; gap: 9px; color: #3f4d60; font-size: .78rem; line-height: 1.55; }
.modal-facts li:before { content: "✓"; color: var(--green); font-weight: 800; }
.modal-actions { display: flex; gap: 10px; margin-top: 23px; padding-top: 19px; border-top: 1px solid var(--line); }
.modal-actions button { flex: 1; }
.share-button { min-height: 43px; border: 1px solid #cfd7e3; border-radius: 10px; background: white; font-size: .73rem; font-weight: 800; cursor: pointer; }
.ask-form { display: grid; gap: 13px; }
.ask-form label { color: #5a6678; font-size: .7rem; font-weight: 800; }
.ask-form input, .ask-form select { width: 100%; min-height: 46px; margin-top: 7px; padding: 0 13px; border: 1px solid #d9dfe7; border-radius: 11px; outline: 0; color: #334155; background: white; font: inherit; font-size: .76rem; }
.ask-form input:focus, .ask-form select:focus { border-color: #4f7db4; box-shadow: 0 0 0 3px #eaf2fb; }
.password-input-wrap { position:relative; display:block; }
.password-input-wrap input { padding-right:48px; }
.password-visibility-toggle { position:absolute; top:13px; right:7px; display:grid; width:34px; height:34px; place-items:center; padding:0; border:0; border-radius:9px; color:#788497; background:transparent; cursor:pointer; transition:color .16s ease,background .16s ease; }
.password-visibility-toggle:hover,.password-visibility-toggle:focus-visible,.password-visibility-toggle.is-visible { color:#c75129; background:#fff0e8; outline:none; }
.password-visibility-toggle svg { width:19px; height:19px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.password-visibility-toggle.is-visible svg { filter:drop-shadow(0 0 2px rgba(244,119,66,.28)); }
/* Единый ретро-файл-пикер: отсылка к интерфейсам 90-х без системной серой кнопки. */
.ask-form input[type="file"],.form-grid input[type="file"] { min-height:54px; padding:7px 9px; border:2px solid #27324a; border-radius:7px; color:#4c5668; background:repeating-linear-gradient(135deg,#fffaf0 0,#fffaf0 8px,#fff3df 8px,#fff3df 16px); font-family:"Courier New",monospace; font-size:.66rem; font-weight:700; box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d9c7ab,3px 3px 0 rgba(39,50,74,.14); cursor:pointer; }
.ask-form input[type="file"]::file-selector-button,.form-grid input[type="file"]::file-selector-button { min-height:34px; margin-right:12px; padding:0 13px; border:2px outset #ffe4a6; border-radius:3px; color:#fff; background:linear-gradient(180deg,#ff8b55 0 48%,#df572c 49% 100%); box-shadow:2px 2px 0 #27324a; font-family:"Courier New",monospace; font-size:.65rem; font-weight:900; letter-spacing:.025em; text-transform:uppercase; cursor:pointer; }
.ask-form input[type="file"]::-moz-file-upload-button,.form-grid input[type="file"]::-moz-file-upload-button { min-height:34px; margin-right:12px; padding:0 13px; border:2px outset #ffe4a6; border-radius:3px; color:#fff; background:linear-gradient(180deg,#ff8b55 0 48%,#df572c 49% 100%); box-shadow:2px 2px 0 #27324a; font-family:"Courier New",monospace; font-size:.65rem; font-weight:900; text-transform:uppercase; cursor:pointer; }
.ask-form input[type="file"]:hover::file-selector-button,.form-grid input[type="file"]:hover::file-selector-button { color:#251d18; background:linear-gradient(180deg,#ffe077 0 48%,#ffba3d 49% 100%); }
.ask-form input[type="file"]:active::file-selector-button,.form-grid input[type="file"]:active::file-selector-button { border-style:inset; box-shadow:1px 1px 0 #27324a; transform:translate(1px,1px); }
.ask-form input[type="file"]:focus-visible,.form-grid input[type="file"]:focus-visible { border-color:#ef6c37; box-shadow:0 0 0 3px rgba(244,119,66,.2),inset 2px 2px 0 #fff,inset -2px -2px 0 #d9c7ab,3px 3px 0 rgba(39,50,74,.14); outline:none; }
.generated-password-field { display:grid; grid-template-columns:minmax(0,1fr) auto 42px; gap:8px; align-items:end; }
.generated-password-field input { min-width:0; }
.generated-password-field button { min-height:46px; margin-top:7px; border-radius:11px; font:inherit; font-size:.66rem; font-weight:800; cursor:pointer; }
.generate-password-button { padding:0 14px; border:1px solid #f1b69b; color:#b84a24; background:#fff4ee; }
.generate-password-button:hover { border-color:#f47742; color:#983617; background:#ffebe1; }
.copy-password-button { width:42px; border:1px solid #d9dfe7; color:#5b687a; background:#fff; font-size:.9rem !important; }
.copy-password-button:hover { border-color:#f1b69b; color:#b84a24; background:#fff7f3; }
.generated-password-hint { display:block; margin-top:7px; color:#8993a2; font-size:.59rem; font-weight:500; line-height:1.45; }
.ask-form textarea { width: 100%; min-height: 120px; margin-top: 7px; padding: 13px; border: 1px solid #d9dfe7; border-radius: 11px; outline: 0; resize: vertical; font: inherit; font-size: .78rem; }
.ask-form textarea:focus { border-color: #4f7db4; box-shadow: 0 0 0 3px #eaf2fb; }
.quiz-options { display: grid; gap: 8px; margin: 20px 0; }
.quiz-option { padding: 13px 14px; border: 1px solid #dbe1e9; border-radius: 11px; background: white; text-align: left; font-size: .75rem; cursor: pointer; }
.quiz-option:hover, .quiz-option.selected { border-color: #3a6fae; background: #edf4fd; }
.toast { position: fixed; z-index: 120; right: 24px; bottom: 24px; padding: 13px 17px; border-radius: 12px; color: white; background: #17243a; box-shadow: 0 12px 35px rgba(0,0,0,.2); font-size: .72rem; font-weight: 700; animation: toastIn .25s ease both; }
@keyframes toastIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

@media (max-width: 1040px) {
  .app-shell { grid-template-columns: 84px 1fr; }
  .sidebar { padding-inline: 12px; }
  .brand { justify-content: center; padding-inline: 0; }
  .brand > span:last-child, .nav-item:not(.active)::after, .nav-item { font-size: 0; }
  .nav-item { justify-content: center; padding: 0; }
  .nav-attention-badge { top:7px; right:7px; transform:none; }
  .nav-icon { font-size: 1.2rem; }
  .support-button > span:last-child, .profile-mini > span:nth-child(2), .icon-button { display: none; }
  .support-button { justify-content: center; padding: 10px; }
  .profile-mini { display: flex; justify-content: center; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .course-layout { grid-template-columns: 1fr; }
  .course-aside { grid-template-columns: 1fr 1fr; }
  .media-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  .app-shell { display: block; }
  .sidebar { position: fixed; z-index: 50; width: 264px; transform: translateX(-105%); transition: transform .25s ease; }
  body.menu-open .sidebar { transform: translateX(0); }
  .brand { justify-content: flex-start; }
  .brand > span:last-child, .nav-item { font-size: initial; }
  .nav-item { justify-content: flex-start; padding: 0 13px; }
  .support-button > span:last-child, .profile-mini > span:nth-child(2), .icon-button { display: block; }
  .profile-mini { display: grid; }
  .mobile-menu { display: block; }
  .topbar { min-height: 64px; padding: 0 16px; gap: 12px; }
  .crumbs, .global-search kbd { display: none; }
  .global-search { width: auto; flex: 1; margin-left: 0; }
  .workspace { padding: 28px 18px 44px; }
  .welcome-row { align-items: flex-start; flex-direction: column; }
  .continue-content { grid-template-columns: 1fr; }
  .module-art { height: 150px; }
  .answer-grid { grid-template-columns: 1fr; }
  .page-hero { min-height: auto; align-items: flex-start; flex-direction: column; padding: 28px 23px; }
  .hero-stat, .course-overview { width: 100%; }
  .knowledge-toolbar { align-items: stretch; flex-direction: column; }
  .knowledge-layout { grid-template-columns: 1fr; }
  .category-panel { display: none; }
  .knowledge-grid { grid-template-columns: 1fr; }
  .course-aside { grid-template-columns: 1fr; }
  .module-item { grid-template-columns: 48px 1fr; }
  .module-item button { grid-column: 2; justify-self: start; }
  .media-summary { grid-template-columns: repeat(2, 1fr); }
  .media-grid { grid-template-columns: 1fr; }
  .news-layout { grid-template-columns: 1fr; }
  .featured-news { min-height: 300px; }
  .modal-card { padding: 27px 21px; }
}

/* Larger, app-like presentation */
html { font-size: 18px; }
body { min-width: 320px; overflow-x: hidden; }
.app-shell { grid-template-columns: 286px minmax(0, 1fr); }
.sidebar { padding: 28px 20px 20px; }
.brand b { font-size: 1.05rem; }
.brand small { font-size: .74rem; }
.nav-item { min-height: 52px; font-size: .92rem; }
.topbar { min-height: 80px; padding-inline: 38px; }
.crumbs { font-size: .82rem; }
.global-search { width: min(460px, 40vw); }
.global-search input { min-height: 46px; font-size: .86rem; }
.install-app-button { min-height: 42px; padding: 0 14px; border: 1px solid #d9e0e9; border-radius: 11px; color: #183a66; background: #eef4fb; font-size: .72rem; font-weight: 800; cursor: pointer; }
.ui-icon { width: 18px; height: 18px; display: block; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.notification-button { display: grid; place-items: center; color: #445269; }
.mode-switch, .install-app-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.mode-switch { min-height: 42px; padding: 0 14px; border: 1px solid #d9e0e9; border-radius: 11px; color: white; background: #173b6c; font-size: .7rem; cursor: pointer; }
.mode-switch b { white-space: nowrap; }
.mode-switch .ui-icon, .install-app-button .ui-icon { width: 16px; height: 16px; }
body.admin-mode .mode-switch { color: #173b6c; background: #eef4fb; }

/* Management center */
.admin-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 26px; }
.admin-heading h1 { margin-bottom: 7px; }
.admin-actions { display: flex; gap: 10px; }
.range-button { min-height: 44px; padding: 0 14px; border: 1px solid #dce2ea; border-radius: 11px; color: #566378; background: white; font-size: .72rem; font-weight: 700; cursor: pointer; }
.range-select { min-height:44px; padding:0 34px 0 13px; border:1px solid #dce2ea; border-radius:11px; color:#566378; background:#fff; font:700 .68rem "Golos Text",sans-serif; cursor:pointer; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi-grid article { min-height: 132px; display: flex; align-items: center; gap: 14px; padding: 20px; border: 1px solid var(--line); border-radius: 17px; background: white; box-shadow: 0 9px 26px rgba(23,32,51,.035); }
.kpi-icon { width: 46px; height: 46px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 13px; font-size: .9rem; font-weight: 800; }
.blue-kpi { color: #2864b0; background: #eaf2fd; }
.green-kpi { color: #27815f; background: #e7f7ef; }
.gold-kpi { color: #9a650b; background: #fff3d6; }
.violet-kpi { color: #7048a0; background: #f2eafa; }
.kpi-grid small, .kpi-grid b, .kpi-grid em { display: block; }
.kpi-grid small { color: #7f8a9c; font-size: .68rem; font-weight: 700; }
.kpi-grid b { margin-top: 4px; font-size: 1.35rem; letter-spacing: -.04em; }
.kpi-grid em { margin-top: 5px; color: #718096; font-size: .62rem; font-style: normal; }
.kpi-spark { width: 82px; height: 38px; margin-left: auto; overflow: visible; fill: none; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; opacity: .82; }
.kpi-spark polyline { stroke-dasharray: 140; stroke-dashoffset: 140; animation: draw-spark .9s ease-out .15s forwards; }
.blue-spark { stroke: #3477bd; }
.green-spark { stroke: #2b946d; }
.gold-spark { stroke: #d99a28; }
.violet-spark { stroke: #8055aa; }
.insight-grid { display: grid; grid-template-columns: 1.05fr 1fr .82fr; gap: 16px; margin-bottom: 16px; }
.insight-grid .admin-panel { min-height: 188px; }
.branch-bars, .region-bars { display: grid; gap: 15px; }
.branch-bars > div { display: grid; grid-template-columns: 112px minmax(80px, 1fr) 38px; align-items: center; gap: 12px; }
.branch-bars span b, .branch-bars span small { display: block; }
.branch-bars span b { font-size: .72rem; }
.branch-bars span small { margin-top: 3px; color: #8b95a4; font-size: .6rem; }
.branch-bars i, .region-bars i { height: 9px; overflow: hidden; border-radius: 999px; background: #edf1f5; }
.branch-bars i em, .region-bars i em { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #255f9f, #4388ce); transform-origin: left; animation: reveal-progress .7s ease-out both; }
.branch-bars > div:nth-child(2) i em { background: linear-gradient(90deg, #d99a28, #f4be58); }
.branch-bars strong { color: #315b8d; font-size: .73rem; text-align: right; }
.region-bars > div { display: grid; grid-template-columns: 78px 1fr 28px; align-items: center; gap: 10px; color: #5c687a; font-size: .68rem; }
.region-bars b { color: #24344c; text-align: right; }
.quality-score { display: flex; align-items: center; gap: 16px; margin: 3px 0 16px; }
.quality-score > span { width: 72px; height: 72px; display: grid; place-items: center; flex: 0 0 auto; border: 7px solid #dfe9f8; border-top-color: #2d6db5; border-right-color: #2d6db5; border-radius: 50%; color: #214f85; font-size: 1.25rem; font-weight: 800; }
.quality-score > span small { font-size: .64rem; }
.quality-score b { font-size: .72rem; }
.quality-score p { margin: 4px 0 0; color: #8993a2; font-size: .62rem; line-height: 1.45; }
.admin-grid-main { display: grid; grid-template-columns: 1.55fr .8fr; gap: 16px; margin-bottom: 16px; }
.admin-grid-bottom { display: grid; grid-template-columns: 1.25fr .9fr; gap: 16px; }
.admin-panel { padding: 22px; border: 1px solid var(--line); border-radius: 17px; background: white; box-shadow: 0 9px 26px rgba(23,32,51,.03); }
.leaderboard-panel { margin-bottom: 16px; overflow: hidden; }
.leaderboard-head { align-items: center; }
.leaderboard-head p:not(.eyebrow) { margin: 5px 0 0; color: #7d899b; font-size: .64rem; }
.leaderboard-scroll { overflow-x: auto; }
.leaderboard-table { width: 100%; border-collapse: collapse; font-size: .69rem; }
.leaderboard-table th { padding: 0 12px 9px; color: #8a95a6; font-size: .57rem; font-weight: 800; text-align: left; text-transform: uppercase; letter-spacing: .06em; }
.leaderboard-table td { padding: 10px 12px; border-top: 1px solid #edf0f4; color: #445166; vertical-align: middle; }
.leaderboard-table td:nth-last-child(-n+3), .leaderboard-table th:nth-last-child(-n+3) { text-align: center; }
.leaderboard-table td:last-child b { color: #1f568f; font-size: .82rem; }
.rank-badge { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 9px; color: #526176; background: #eef2f7; font-weight: 850; }
.rank-1 { color: #7a5108; background: #fff0c8; box-shadow: inset 0 0 0 1px #f2d58a; }
.rank-2 { color: #536173; background: #e9eef4; }
.rank-3 { color: #875b35; background: #f5e6d8; }
.leader-person { display: flex; align-items: center; gap: 9px; min-width: 165px; }
.leader-person .table-avatar { width: 30px; height: 30px; font-size: .6rem; }
.leader-person b, .leader-person small { display: block; }
.leader-person b { color: #1d2a3d; font-size: .7rem; }
.leader-person small { margin-top: 2px; color: #919aaa; font-size: .55rem; }
.leader-person .leader-email { max-width:190px; overflow:hidden; text-overflow:ellipsis; color:#6f7c90; white-space:nowrap; }
.leader-person-link { padding:0; border:0; color:inherit; background:transparent; text-align:left; text-decoration:none; cursor:pointer; }
.leader-person-link b { color:#b84921; text-decoration:underline; text-decoration-color:#efb59a; text-underline-offset:3px; }
.leader-person-link:hover b,.leader-person-link:focus-visible b { color:#e55f2c; text-decoration-color:#e55f2c; }
.leader-person-link:focus-visible { border-radius:8px; outline:2px solid #f2a482; outline-offset:4px; }
.promo-code { display: inline-flex; align-items: center; gap: 7px; padding: 6px 9px; border: 1px solid #dce5f0; border-radius: 8px; color: #295c96; background: #f6f9fd; font: inherit; font-weight: 800; cursor: pointer; }
.promo-code:hover { border-color: #9bb8d9; background: #edf5ff; }
.promo-code span { color: #8192a8; font-size: .72rem; }
.empty-ranking { padding: 22px !important; color: #8a95a6 !important; text-align: center !important; }
.admin-distribution-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.distribution-list, .source-list { display: grid; gap: 5px; }
.distribution-list button, .source-list > div { display: grid; grid-template-columns: 130px 1fr 45px; align-items: center; gap: 12px; min-height: 35px; padding: 0 7px; border: 0; border-radius: 9px; color: #38475c; background: transparent; font-size: .67rem; text-align: left; }
.distribution-list button { cursor: pointer; }
.distribution-list button:hover { background: #f5f8fc; }
.distribution-list i, .source-list i { height: 7px; overflow: hidden; border-radius: 999px; background: #eef2f6; }
.distribution-list i em, .source-list i em { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #2a66a9, #5a99d7); transform-origin: left; animation: reveal-progress .7s ease-out both; }
.source-list i em { background: linear-gradient(90deg, #e2a12d, #f2c367); }
.distribution-list b, .source-list b { color: #20314a; text-align: right; }
.distribution-list b small { margin-left: 5px; color: #6b88ab; font-size: .7rem; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.panel-head h2 { margin: 0; font-size: 1rem; }
.legend { display: flex; gap: 14px; color: #7c8798; font-size: .62rem; }
.legend span { display: flex; align-items: center; gap: 5px; }
.legend i { width: 8px; height: 8px; border-radius: 50%; }
.legend-blue { background: #326eb3; }
.legend-gold { background: var(--gold); }
.bar-chart { height: 228px; display: grid; grid-template-columns: repeat(8, 1fr); align-items: end; gap: 12px; padding: 22px 4px 0; border-bottom: 1px solid #e4e8ee; background: repeating-linear-gradient(to bottom, transparent 0, transparent 54px, #edf0f4 55px); }
.bar-chart > div { position: relative; height: var(--h); min-height: 18px; border-radius: 8px 8px 2px 2px; background: linear-gradient(180deg, #3978c0, #1f4d84); transform-origin: bottom; animation: rise-bar .65s cubic-bezier(.2,.8,.3,1) both; }
.bar-chart > div:nth-child(2) { animation-delay: .06s; }
.bar-chart > div:nth-child(3) { animation-delay: .12s; }
.bar-chart > div:nth-child(4) { animation-delay: .18s; }
.bar-chart > div:nth-child(5) { animation-delay: .24s; }
.bar-chart > div:nth-child(6) { animation-delay: .3s; }
.bar-chart > div:nth-child(7) { animation-delay: .36s; }
.bar-chart > div:nth-child(8) { animation-delay: .42s; }
.bar-chart > div:after { content: ""; position: absolute; inset: 45% 0 0; border-radius: 0 0 2px 2px; background: rgba(245,182,66,.35); }
.bar-chart > div.current { box-shadow: 0 0 0 4px rgba(50,110,179,.1); }
.bar-chart span { position: absolute; right: 50%; bottom: -24px; color: #929baa; font-size: .56rem; transform: translateX(50%); white-space: nowrap; }
.sales-chart { display: grid; gap: 12px; }
.chart-stats { display: grid; grid-template-columns: auto auto 1fr; align-items: center; gap: 22px; padding: 10px 13px; border: 1px solid #e7ecf3; border-radius: 12px; background: linear-gradient(90deg, #f7faff, #fffaf0); }
.chart-stats > div { display: grid; grid-template-columns: auto auto; align-items: baseline; gap: 2px 7px; }
.chart-stats span { grid-column: 1 / -1; color: #7e8a9d; font-size: .57rem; }
.chart-stats b { color: #18263a; font-size: 1rem; }
.chart-stats em { color: #21815c; font-size: .59rem; font-style: normal; font-weight: 800; }
.chart-stats p { justify-self: end; margin: 0; color: #738096; font-size: .62rem; }
.chart-stats p b { color: #315d91; font-size: inherit; }
.chart-plot { position: relative; height: 172px; margin-left: 38px; border-bottom: 1px solid #dfe5ed; background: repeating-linear-gradient(to bottom, #e9eef5 0 1px, transparent 1px 50px); }
.chart-scale { position: absolute; inset: -5px auto 32px -43px; display: flex; flex-direction: column; justify-content: space-between; color: #7f8b9d; font-size: .52rem; }
.order-columns { position: absolute; inset: 0 0 31px; display: grid; grid-template-columns: repeat(8, 1fr); align-items: end; gap: clamp(8px, 2.2vw, 25px); padding: 0 13px; }
.order-columns i { width: 100%; height: var(--h); max-width: 38px; justify-self: center; border-radius: 8px 8px 3px 3px; background: linear-gradient(180deg, rgba(55,123,199,.42), rgba(37,91,151,.16)); transform-origin: bottom; animation: rise-bar .7s cubic-bezier(.2,.8,.3,1) both; }
.order-columns i.current { background: linear-gradient(180deg, rgba(42,107,183,.65), rgba(37,91,151,.24)); box-shadow: 0 0 0 4px rgba(50,110,179,.08); }
.turnover-line { position: absolute; inset: 0 13px 31px; width: calc(100% - 26px); height: calc(100% - 31px); overflow: visible; pointer-events: none; }
.turnover-line .area { fill: url(#turnover-area); }
.turnover-line .line { fill: none; stroke: #eead32; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1200; stroke-dashoffset: 1200; animation: draw-spark 1.1s .15s ease forwards; }
.turnover-line circle { fill: #fff; stroke: #eead32; stroke-width: 3; }
.turnover-line circle.current { fill: #eead32; stroke: #fff; filter: drop-shadow(0 0 5px rgba(238,173,50,.65)); transform-box: fill-box; transform-origin: center; animation: chart-pulse 1.8s ease-in-out infinite; }
.chart-hover-layer { position:absolute; z-index:4; inset:0 13px 31px; display:grid; grid-template-columns:repeat(8,1fr); }
.chart-hit { position:relative; min-width:0; border:0; outline:0; background:transparent; cursor:crosshair; }
.chart-hit:after { content:""; position:absolute; top:0; bottom:0; left:50%; width:1px; background:transparent; transition:background .16s ease; }
.chart-hit:hover:after,.chart-hit:focus:after { background:rgba(244,119,66,.24); }
.chart-hit-tooltip { position:absolute; z-index:6; top:8px; left:50%; width:max-content; max-width:210px; display:grid; gap:5px; padding:10px 12px; border:1px solid rgba(255,255,255,.12); border-radius:11px; color:#fff; background:rgba(27,25,23,.96); box-shadow:0 12px 28px rgba(34,25,20,.24); text-align:left; opacity:0; pointer-events:none; transform:translate(-50%,-5px); transition:opacity .16s ease,transform .16s ease; }
.chart-hit:hover .chart-hit-tooltip,.chart-hit:focus .chart-hit-tooltip { opacity:1; transform:translate(-50%,0); }
.chart-hit.first .chart-hit-tooltip { left:0; transform:translate(0,-5px); }
.chart-hit.first:hover .chart-hit-tooltip,.chart-hit.first:focus .chart-hit-tooltip { transform:none; }
.chart-hit.last .chart-hit-tooltip { right:0; left:auto; transform:translate(0,-5px); }
.chart-hit.last:hover .chart-hit-tooltip,.chart-hit.last:focus .chart-hit-tooltip { transform:none; }
.chart-hit-tooltip strong { margin-bottom:2px; font-size:.68rem; }
.chart-hit-tooltip span { display:flex; align-items:center; gap:6px; font-size:.62rem; font-weight:700; }
.chart-hit-tooltip small { color:#cabfb6; font-size:.55rem; }
.chart-hit-tooltip i { width:7px; height:7px; border-radius:50%; }
.chart-hit-tooltip .orders-dot { background:#f47742; }
.chart-hit-tooltip .turnover-dot { background:#f5b642; }
.chart-axis { position: absolute; right: 0; bottom: 7px; left: 0; display: grid; grid-template-columns: repeat(8, 1fr); color: #5f6d82; font-size: .57rem; font-weight: 700; text-align: center; }
.chart-axis span { white-space: nowrap; }
.admin-country-bar { display: flex; align-items: center; gap: 10px; margin: -5px 0 13px; }
.admin-country-bar > span { color: #778497; font-size: .62rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.country-switcher { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border: 1px solid #dfe5ed; border-radius: 11px; background: #edf1f6; }
.country-switcher button { min-height: 31px; padding: 0 11px; border: 0; border-radius: 8px; color: #657286; background: transparent; font-size: .62rem; font-weight: 750; white-space: nowrap; cursor: pointer; }
.country-switcher button:hover { color: #214f84; }
.country-switcher button.active { color: white; background: #285f9e; box-shadow: 0 3px 9px rgba(34,83,139,.2); }
.accounting-country-switcher { margin:0 0 14px; }
.inline-status-select { min-height:34px; padding:0 28px 0 10px; border:1px solid #e2d7cf; border-radius:9px; color:#584c44; background:#fff; font:700 .62rem "Golos Text",sans-serif; cursor:pointer; }
.inline-status-select:disabled { opacity:.6; cursor:wait; }
.funnel-list { display: grid; gap: 8px; }
.funnel-list div { display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: 10px; padding: 12px; border-radius: 11px; background: #f6f8fb; }
.funnel-list div:nth-child(1) { width: 100%; }
.funnel-list div:nth-child(2) { width: 92%; }
.funnel-list div:nth-child(3) { width: 80%; }
.funnel-list div:nth-child(4) { width: 69%; }
.funnel-list span { color: #1f518c; font-weight: 800; }
.funnel-list b { font-size: .68rem; }
.funnel-list em { color: #7c8798; font-size: .62rem; font-style: normal; }
.attention-list { display: grid; gap: 7px; }
.attention-list button { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 11px; padding: 11px; border: 0; border-radius: 11px; background: #f7f8fa; text-align: left; cursor: pointer; }
.attention-list .task-row { display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:11px;padding:11px;border-radius:11px;background:#f7f8fa; }
.attention-list .task-row select { max-width:112px; }
.attention-list button:hover { background: #edf3fa; }
.status-orb { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; font-size: .68rem; font-weight: 800; }
.red-orb { color: #b44646; background: #fceaea; }
.gold-orb { color: #9b650d; background: #fff3d7; }
.blue-orb { color: #255b98; background: #e9f2fc; }
.attention-list b, .attention-list small { display: block; }
.attention-list b { font-size: .72rem; }
.attention-list small { margin-top: 3px; color: #8993a3; font-size: .62rem; }
.attention-list em { color: #2864ab; font-size: .62rem; font-style: normal; font-weight: 800; }
.team-feed ul { display: grid; gap: 13px; margin: 0; padding: 0; list-style: none; }
.team-feed li { display: grid; grid-template-columns: 34px 1fr; gap: 10px; }
.team-feed li > span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: #244c7e; background: #eaf2fc; font-size: .58rem; font-weight: 800; }
.team-feed p { margin: 0; color: #59667a; font-size: .67rem; line-height: 1.45; }
.team-feed small { display: block; margin-top: 3px; color: #9aa3b1; font-size: .58rem; }
.audit-toggle { min-height:32px; padding:0 11px; border:1px solid #eadfd7; border-radius:9px; color:#a94b28; background:#fff8f4; font:inherit; font-size:.61rem; font-weight:800; cursor:pointer; }
.team-feed.audit-collapsed ul { display:none; }
.team-feed.audit-collapsed { padding-bottom:18px; }
.admin-toolbar { display: flex; gap: 10px; margin-bottom: 15px; }
.admin-search { min-height: 46px; display: flex; align-items: center; gap: 9px; flex: 1; padding: 0 14px; border: 1px solid #dce2ea; border-radius: 11px; background: white; }
.admin-search input { width: 100%; border: 0; outline: 0; background: transparent; font-size: .78rem; }
.data-table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 16px; background: white; }
.data-table { width: 100%; min-width: 880px; border-collapse: collapse; }
.data-table th { padding: 14px 16px; border-bottom: 1px solid var(--line); color: #8a95a5; background: #f8f9fb; font-size: .62rem; text-align: left; text-transform: uppercase; letter-spacing: .07em; }
.data-table td { padding: 15px 16px; border-bottom: 1px solid #edf0f4; color: #4f5c70; font-size: .7rem; }
.data-table tr:last-child td { border-bottom: 0; }
.person-cell { display: flex; align-items: center; gap: 10px; }
.table-avatar { width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 10px; color: white; background: #2c5f98; font-size: .58rem; font-weight: 800; }
.person-cell b, .person-cell small { display: block; }
.person-cell b { color: #253146; font-size: .71rem; }
.person-cell small { margin-top: 2px; color: #97a0af; font-size: .58rem; }
.mini-progress { width: 92px; height: 6px; overflow: hidden; margin-top: 5px; border-radius: 5px; background: #e9edf2; }
.mini-progress span { display: block; height: 100%; border-radius: inherit; background: #3576be; }
.status-pill { display: inline-flex; align-items: center; min-height: 25px; padding: 0 8px; border-radius: 999px; font-size: .58rem; font-style: normal; font-weight: 800; }
.status-pill.success { color: #26775a; background: #e7f7ef; }
.status-pill.pending { color: #98640f; background: #fff3d8; }
.status-pill.inactive { color: #9b4c4c; background: #fbeaea; }
.row-action { border: 0; color: #376aab; background: transparent; font-size: .65rem; font-weight: 800; cursor: pointer; }
.order-summary { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-bottom: 12px; }
.order-summary div { padding: 17px; border: 1px solid var(--line); border-radius: 14px; background: white; }
.order-summary small, .order-summary b { display: block; }
.order-summary small { color: #7e899b; font-size: .65rem; }
.order-summary b { margin-top: 5px; font-size: 1.2rem; }
.message-layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: 15px; margin-bottom: 15px; }
.message-stats > div { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 18px; }
.message-stats span { padding: 14px 8px; border-radius: 11px; background: #f5f7fa; text-align: center; }
.message-stats b, .message-stats small { display: block; }
.message-stats b { font-size: 1.25rem; }
.message-stats small { margin-top: 4px; color: #8490a1; font-size: .58rem; }
.segments-panel { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.segments-panel .panel-head { grid-column: 1 / -1; }
.segments-panel button { display: flex; justify-content: space-between; align-items: center; min-height: 52px; padding: 0 13px; border: 1px solid #e3e7ed; border-radius: 11px; background: #fafbfc; font-size: .68rem; cursor: pointer; }
.segments-panel button:hover { border-color: #a9bfdb; background: #edf4fc; }
.segment-modal-summary { margin:8px 0 14px!important; color:var(--muted); }
.segment-partner-list { display:grid; gap:7px; max-height:min(52vh,480px); overflow:auto; padding-right:3px; scrollbar-width:thin; }
.segment-partner-row { display:grid; grid-template-columns:auto minmax(0,1fr) auto; gap:10px; align-items:center; padding:9px 10px; border:1px solid var(--line); border-radius:12px; background:#fafbfc; }
.segment-partner-identity { min-width:0; border:0; padding:0; color:var(--ink); background:transparent; font:inherit; text-align:left; cursor:pointer; }
.segment-partner-identity b,.segment-partner-identity small,.segment-partner-identity em { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.segment-partner-identity b { font-size:.7rem; }
.segment-partner-identity small { margin-top:2px; color:var(--muted); font-size:.56rem; }
.segment-partner-identity em { margin-top:3px; color:#b5572f; font-size:.54rem; font-style:normal; font-weight:700; }
.segment-partner-identity:hover b { color:#cf5527; text-decoration:underline; }
.segment-partner-empty { display:grid; gap:5px; padding:24px; border:1px dashed var(--line); border-radius:12px; color:var(--muted); text-align:center; }
.segment-partner-empty b { color:var(--ink); }
.campaigns-panel { padding-bottom: 8px; }
.curator-inbox-panel { margin-bottom: 15px; }
.curator-question { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 13px; padding: 14px 0; border-top: 1px solid #edf0f4; }
.curator-question .table-avatar { background: #315b8d; }
.curator-question b, .curator-question small { display: block; }
.curator-question b { font-size: .74rem; }
.curator-question p { margin: 4px 0 0; color: #586579; font-size: .68rem; line-height: 1.45; }
.curator-question small { margin-top: 4px; color: #929bab; font-size: .58rem; }
.curator-question > em { color: #315b8d; font-size: .63rem; font-style: normal; font-weight: 800; }
.curator-question.answered { opacity: .66; }
.support-chat { min-height: 390px; display: grid; grid-template-columns: 300px minmax(0, 1fr); overflow: hidden; border: 1px solid #e3e8ef; border-radius: 14px; background: #f8fafc; }
.chat-thread-list { overflow-y: auto; border-right: 1px solid #e3e8ef; background: white; }
.chat-thread { position: relative; width: 100%; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 13px; border: 0; border-bottom: 1px solid #edf0f4; color: #263349; background: transparent; text-align: left; cursor: pointer; }
.chat-thread:hover { background: #f5f8fc; }
.chat-thread.active { background: #eaf2fd; box-shadow: inset 3px 0 #2f70b8; }
.chat-thread > span:nth-child(2) { min-width: 0; }
.chat-thread b, .chat-thread small { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.chat-thread b { font-size: .72rem; }
.chat-thread small { margin-top: 4px; color: #788598; font-size: .61rem; }
.chat-thread time { align-self: start; color: #929cad; font-size: .55rem; }
.chat-thread i { position: absolute; right: 13px; bottom: 14px; width: 7px; height: 7px; border-radius: 50%; background: #2f70b8; }
.chat-conversation { min-width: 0; display: grid; grid-template-rows: auto 1fr auto; background: #f7f9fc; }
.chat-head { display: flex; align-items: center; gap: 10px; padding: 13px 16px; border-bottom: 1px solid #e3e8ef; background: white; }
.chat-head > div { min-width: 0; }
.chat-head b, .chat-head small { display: block; }
.chat-head b { font-size: .74rem; }
.chat-head small { margin-top: 2px; color: #8792a3; font-size: .58rem; }
.chat-head em { margin-left: auto; color: #6e7c90; font-size: .59rem; font-style: normal; }
.chat-messages { display: flex; flex-direction: column; gap: 10px; overflow-y: auto; padding: 18px; }
.chat-bubble { width: fit-content; max-width: 76%; padding: 10px 12px; border-radius: 13px 13px 13px 4px; background: white; box-shadow: 0 4px 14px rgba(24,48,78,.06); }
.chat-bubble.curator { align-self: flex-end; border-radius: 13px 13px 4px 13px; color: white; background: #285f9e; }
.chat-bubble p { margin: 0; font-size: .68rem; line-height: 1.5; }
.chat-bubble time { display: block; margin-top: 5px; color: #8c97a7; font-size: .54rem; text-align: right; }
.chat-bubble.curator time { color: #bfd1e7; }
.chat-meta { min-height:18px; display:flex; align-items:center; justify-content:flex-end; gap:4px; margin-top:5px; }
.chat-meta time { margin-top:0; }
.chat-bubble .chat-meta .chat-edited-status { display:inline; margin:0; color:#8c97a7; font-size:.44rem; font-weight:500; line-height:1; letter-spacing:0; text-transform:none; white-space:nowrap; opacity:.78; }
.chat-bubble.curator .chat-meta .chat-edited-status { color:rgba(255,255,255,.68); }
.chat-meta [data-edit-message] { width:18px; height:18px; display:grid; place-items:center; flex:0 0 18px; padding:0; border:0; border-radius:6px; color:#7f8b9a; background:transparent; cursor:pointer; transition:color .16s ease,background .16s ease; }
.chat-meta [data-edit-message] svg { width:11px; height:11px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.chat-meta [data-edit-message]:hover,.chat-meta [data-edit-message]:focus-visible { color:#d95524; background:rgba(255,255,255,.72); outline:none; }
.chat-bubble.curator .chat-meta [data-edit-message] { color:rgba(255,255,255,.78); }
.chat-bubble.curator .chat-meta [data-edit-message]:hover,.chat-bubble.curator .chat-meta [data-edit-message]:focus-visible { color:#fff; background:rgba(255,255,255,.18); }
.chat-translation { margin-top:9px; padding:9px 10px; border-left:3px solid #f47742; border-radius:0 9px 9px 0; background:#fff4ee; }
.chat-translation small { display:block; margin-bottom:4px; color:#b75229; font-size:.53rem; font-weight:800; letter-spacing:.04em; text-transform:uppercase; }
.chat-translation p { color:#302924; }
.translate-message-button { display:inline-flex; align-items:center; min-height:28px; margin-top:8px; padding:0 10px; border:1px solid #efc4b0; border-radius:8px; color:#b44f27; background:#fff8f4; font:700 .56rem "Golos Text",sans-serif; cursor:pointer; }
.translate-message-button:before { content:"文"; margin-right:6px; font-size:.64rem; }
.translate-message-button:hover,.translate-message-button:focus-visible { border-color:#f47742; color:#8f3515; background:#ffede4; outline:none; }
.translate-message-button:disabled { opacity:.6; cursor:wait; }
.chat-compose { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 9px; padding: 12px; border-top: 1px solid #e3e8ef; background: white; }
.chat-compose textarea { min-height: 42px; max-height: 90px; resize: vertical; padding: 11px 12px; border: 1px solid #d8e0eb; border-radius: 11px; font: inherit; font-size: .68rem; }
.chat-compose > .primary-button { grid-column: 1 / -1; }
.chat-file { min-width:156px; max-width:230px; height:42px; display:flex; align-items:center; gap:9px; padding:5px 9px; overflow:hidden; border:2px solid #27324a; border-radius:5px; color:#39445a; background:repeating-linear-gradient(135deg,#fffaf0 0,#fffaf0 7px,#fff2dd 7px,#fff2dd 14px); box-shadow:inset 1px 1px 0 #fff,inset -1px -1px 0 #cfbea4,2px 2px 0 rgba(39,50,74,.15); cursor:pointer; font-family:"Courier New",monospace; transition:border-color .18s ease,background .18s ease,transform .18s ease; }
.chat-file:hover { border-color:#d85d30; background:repeating-linear-gradient(135deg,#fff5df 0,#fff5df 7px,#ffe6bd 7px,#ffe6bd 14px); transform:translateY(-1px); }
.chat-file:focus-within { border-color:#ff833d; box-shadow:0 0 0 3px rgba(255,131,61,.16),2px 2px 0 rgba(39,50,74,.18); }
.chat-file input { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.chat-file-icon { width:27px; height:27px; display:grid; place-items:center; flex:0 0 auto; border:2px outset #ffe0a0; border-radius:2px; color:#fff; background:linear-gradient(180deg,#ff8b55 0 48%,#df572c 49% 100%); box-shadow:1px 1px 0 #27324a; }
.chat-file-icon svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.chat-file-label { min-width:0; max-width:174px; overflow:hidden; color:inherit; font-size:.6rem; font-weight:900; line-height:1.2; white-space:nowrap; text-overflow:ellipsis; text-transform:uppercase; }
.chat-file.has-file { border-color:#ce572c; background:#fff0d5; }
.currency-stack b, .currency-stack small, .country-label { display: block; }
.currency-stack small, .country-label { margin-top: 3px; color: #7f8b9d; font-size: .57rem; }
.orders-editor-table { min-width:1080px; }
.orders-editor-table td { vertical-align:middle; }
.inline-order-input,.inline-order-select { width:100%; min-height:34px; padding:6px 8px; border:1px solid transparent; border-radius:8px; color:#4f5c70; background:transparent; font:600 .64rem "Golos Text",sans-serif; transition:border-color .16s ease,background .16s ease,box-shadow .16s ease; }
.inline-order-input:hover,.inline-order-select:hover { border-color:#e4d8d0; background:#fffaf7; }
.inline-order-input:focus,.inline-order-select:focus { border-color:#ff9b69; background:#fff; box-shadow:0 0 0 3px rgba(255,131,61,.12); outline:none; }
.order-number-input { min-width:104px; font-weight:800; }
.partner-input { min-width:150px; }
.inline-order-select { min-width:128px; cursor:pointer; }
.inline-money { width:max-content; min-width:0; display:flex; align-items:center; justify-content:flex-start; gap:3px; padding:0 6px; border:1px solid transparent; border-radius:8px; }
.inline-money:focus-within { border-color:#ff9b69; box-shadow:0 0 0 3px rgba(255,131,61,.12); }
.inline-money .inline-order-input { width:72px; min-width:0; padding-inline:2px; border:0; box-shadow:none; text-align:right; }
.inline-money span { padding:0; color:#8a776b; font-size:.62rem; font-weight:800; }
.calculated-order-reward { display:flex; align-items:center; gap:6px; color:#3f4e61; font-weight:800; white-space:nowrap; }
.calculated-order-reward small { padding:3px 6px; border-radius:999px; color:#7c7169; background:#f1eeeb; font-size:.48rem; text-transform:uppercase; }
.order-status-select { min-width:142px; font-weight:800; }
.order-status-select.status-confirmed { color:#237659; background:#e8f7ef; }
.order-status-select.status-cancelled,.order-status-select.status-returned { color:#9a4943; background:#fbeaea; }
.order-status-select.status-review,.order-status-select.status-submitted { color:#93600f; background:#fff3d8; }
.order-status-select.status-draft { color:#667386; background:#edf1f5; }
.orders-editor-table tr.is-saving { opacity:.58; pointer-events:none; }
.order-workflow-tabs { display:flex; gap:6px; margin:0 0 10px; overflow-x:auto; padding:2px; scrollbar-width:thin; }
.order-workflow-tabs button { min-height:30px; flex:0 0 auto; padding:0 10px; border:1px solid #ddd6d0; border-radius:9px; color:#6d7684; background:#fff; font:700 .56rem "Golos Text",sans-serif; cursor:pointer; }
.order-workflow-tabs button.active { border-color:#f17742; color:#a54120; background:#fff1e9; }
.order-group-row td { padding:6px 12px!important; border-top:1px solid #e5ded8; border-bottom:1px solid #e8e1dc; color:#70665f; background:#f6f3f0; font-size:.56rem; font-weight:800; letter-spacing:.045em; text-transform:uppercase; }
.order-group-row td span { margin-right:7px; }
.order-group-row td b { display:inline-grid; min-width:19px; height:19px; place-items:center; border-radius:999px; color:#fff; background:#8b8179; font-size:.52rem; }
.orders-editor-table .order-workflow-row td { padding-block:6px; transition:background .15s ease; }
.orders-editor-table th,.orders-editor-table td { padding-inline:8px; }
.orders-editor-table .order-date-input { min-width:116px; }
.orders-editor-table .receipt-date-input { min-width:120px; }
.orders-editor-table .order-workflow-row.workflow-missing td { background:#fff8f2; }
.orders-editor-table .order-workflow-row.workflow-waiting td { background:#fffbee; }
.orders-editor-table .order-workflow-row.workflow-ready td { background:#f1f7ff; }
.orders-editor-table .order-workflow-row.workflow-review td { background:#f7f3ff; }
.orders-editor-table .order-workflow-row.workflow-confirmed td { background:#f1faf5; }
.orders-editor-table .order-workflow-row.workflow-payout td,.orders-editor-table .order-workflow-row.workflow-paid td { background:#eef9f8; }
.orders-editor-table .order-workflow-row.workflow-closed td { background:#fbf4f3; }
.workflow-status-label { display:block; margin-top:3px; color:#778292; font-size:.49rem; font-weight:700; white-space:nowrap; }
.receipt-date-heading { color:#a94b27!important; }
.receipt-date-cell { box-shadow:inset 2px 0 0 rgba(232,112,61,.22); }
.receipt-date-input { border-color:#efc4af; color:#a34421; background:#fff7f1; font-weight:900; }
.receipt-date-input:hover,.receipt-date-input:focus { border-color:#ed824f; background:#fff2e9; }
.receipt-countdown { display:block; margin-top:3px; color:#a35b39; font-size:.5rem; font-weight:800; white-space:nowrap; }
.compact-order-form { gap:8px; }
.modal-card:has(.compact-order-form) { width:min(880px,100%); max-height:calc(100vh - 28px); padding:24px 26px; }
.modal-card:has(.compact-order-form) .modal-label { margin-bottom:8px; }
.modal-card:has(.compact-order-form) h2 { margin:0 0 12px; font-size:1.28rem; }
.order-journey-panel { margin:0 0 14px; padding:14px; overflow:hidden; border:1px solid #eadfd6; border-radius:15px; background:linear-gradient(135deg,#fffaf6,#fff); }
.order-journey-head { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:12px; }
.order-journey-head div { display:grid; gap:3px; }
.order-journey-head small { color:#97877c; font-size:.53rem; font-weight:800; letter-spacing:.07em; text-transform:uppercase; }
.order-journey-head b { color:#312822; font-size:.76rem; }
.order-journey-head>span { padding:5px 9px; border-radius:999px; color:#a24a27; background:#fff0e7; font-size:.55rem; font-weight:900; white-space:nowrap; }
.order-journey-scroll { overflow-x:auto; padding:3px 2px 7px; scrollbar-width:thin; scrollbar-color:#e3b49d transparent; }
.order-journey { min-width:max-content; display:flex; gap:0; margin:0; padding:0; list-style:none; }
.order-journey li { position:relative; width:142px; display:grid; grid-template-columns:28px 1fr; align-items:start; gap:7px; padding-right:12px; }
.order-journey li:not(:first-child):before { content:""; position:absolute; top:13px; right:calc(100% - 1px); width:13px; height:2px; background:#dfe4e8; }
.order-journey li.done:not(:first-child):before { background:#39a778; }
.journey-marker { position:relative; z-index:1; width:27px; height:27px; display:grid; place-items:center; border:2px solid #dce2e7; border-radius:50%; color:#85909e; background:#fff; font-size:.56rem; font-weight:900; }
.order-journey li.done .journey-marker { border-color:#39a778; color:#fff; background:#39a778; box-shadow:0 0 0 4px rgba(57,167,120,.1); }
.order-journey li.current .journey-marker { border-color:#f47842; color:#c94f20; background:#fff3ec; box-shadow:0 0 0 4px rgba(244,120,66,.12); }
.order-journey li>div { display:grid; gap:3px; padding-top:1px; }
.order-journey li b { max-width:104px; color:#3d454f; font-size:.58rem; line-height:1.25; }
.order-journey li small { max-width:104px; color:#8a94a2; font-size:.48rem; line-height:1.3; }
.order-journey li.current b { color:#b54820; }
.order-journey li.future { opacity:.62; }
.order-journey.is-stopped li:not(.done) { opacity:.38; }
.order-journey.is-stopped li.current .journey-marker { border-color:#bd6258; color:#a6473e; background:#fbeceb; }
.compact-order-form .modal-form-grid { gap:8px; }
.compact-order-form input,.compact-order-form select { min-height:38px; margin-top:4px; padding-inline:10px; }
.compact-order-form textarea { min-height:68px; margin-top:4px; padding:9px 10px; }
.compact-order-form input[type="file"] { min-height:46px; padding:5px 7px; }
.compact-order-form .eligibility-note { margin:2px 0; padding:9px 11px; }
.received-date-field { padding:10px 12px; border:1px solid #eadfd6; border-radius:11px; background:#fffaf6; }
.received-date-field small { display:block; margin-top:6px; color:var(--muted); font-size:.58rem; font-weight:500; line-height:1.45; }
.campaign-row { display: grid; grid-template-columns: 1.4fr .7fr auto; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid #edf0f4; }
.campaign-row > div { display: flex; align-items: center; gap: 11px; }
.campaign-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; color: #275b98; background: #eaf2fc; }
.campaign-row p { margin: 0; }
.campaign-row b, .campaign-row small { display: block; }
.campaign-row b { font-size: .72rem; }
.campaign-row small, .campaign-row > span { margin-top: 3px; color: #8a95a5; font-size: .6rem; }
.access-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-bottom: 15px; }
.role-card { width:100%; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 11px; padding: 13px 8px; border:0; border-top: 1px solid #edf0f4; border-radius:10px; color:inherit; background:transparent; text-align:left; font:inherit; cursor:pointer; transition:background .16s ease,transform .16s ease; }
.role-card:hover,.role-card:focus-visible { background:#fff6f1; outline:none; transform:translateX(2px); }
.role-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; font-size: .65rem; font-weight: 800; }
.owner-role { color: #244e82; background: #e9f2fc; }
.manager-role { color: #8e6010; background: #fff3d8; }
.analyst-role { color: #684590; background: #f1eafb; }
.role-card b,.role-card > span:nth-child(2) small { display:block; margin:0; }
.role-card b { font-size: .72rem; }
.role-card > span:nth-child(2) small { margin-top:3px; color:#8993a3; font-size:.62rem; }
.role-card em { color: #788496; font-size: .6rem; font-style: normal; }
.role-card-side { display:grid; justify-items:end; gap:3px; }
.role-card-side small { color:#cf5a2c; font-size:.51rem; font-weight:800; opacity:0; transform:translateX(-3px); transition:opacity .16s ease,transform .16s ease; }
.role-card:hover .role-card-side small,.role-card:focus-visible .role-card-side small { opacity:1; transform:none; }
.role-member-list { display:grid; gap:7px; margin:18px 0 14px; }
.role-member-row { display:grid; grid-template-columns:auto minmax(0,1fr) auto auto; align-items:center; gap:10px; padding:10px; border:1px solid #e2e6ec; border-radius:11px; background:#f8fafc; }
.role-member-row > span:nth-child(2) { min-width:0; }
.role-member-row b,.role-member-row small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.role-member-row b { font-size:.68rem; }
.role-member-row small { margin-top:3px; color:#8792a2; font-size:.54rem; }
.role-member-empty,.role-member-note,.role-permission-note { margin:12px 0; padding:11px 12px; border-radius:10px; color:#697587; background:#f5f7fa; font-size:.62rem; line-height:1.5; }
.role-assignment-form { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:end; gap:10px; margin-top:14px; }
.role-assignment-form label { display:grid; gap:6px; color:#5e6878; font-size:.62rem; font-weight:800; }
.role-assignment-form select { min-height:42px; padding:0 11px; border:1px solid #d8e0e9; border-radius:10px; color:#3f4c5f; background:#fff; font:inherit; }
.role-assignment-form .primary-button { min-height:42px; }
.role-permission-note { border:1px solid #f0d9cd; color:#725b4f; background:#fff8f4; }
.permission-panel label { min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid #edf0f4; color: #586579; font-size: .68rem; }
.permission-panel input[type="checkbox"] { width: 38px; height: 21px; accent-color: #2868ae; cursor: pointer; }
.member-count { color: #7e899b; font-size: .65rem; }
.access-member { display: grid; grid-template-columns: auto minmax(180px, 1fr) auto auto auto; align-items: center; gap: 12px; padding: 13px 0; border-top: 1px solid #edf0f4; }
.access-member .table-avatar { width: 38px; height: 38px; }
.access-member b, .access-member small { display: block; }
.access-member b { font-size: .72rem; }
.access-member small { margin-top: 3px; color: #8d97a6; font-size: .6rem; }
.registration-email-cell > span,.registration-email-cell > small { display:block; }
.registration-email-cell > span { color:#536176; font-weight:600; }
.registration-email-cell > small { margin-top:5px; color:#8c97a7; font-size:.54rem; line-height:1.35; }
.access-member select { min-height: 36px; padding: 0 10px; border: 1px solid #dce2e9; border-radius: 9px; color: #556276; background: white; font-size: .64rem; }
.owner-role-lock { min-height:36px; display:inline-flex; align-items:center; padding:0 11px; border:1px solid #f0c8b5; border-radius:9px; color:#a14522; background:#fff6f0; font-size:.62rem; font-weight:800; white-space:nowrap; }
.curator-toggle { min-height: 36px; display: inline-flex; align-items: center; gap: 7px; padding: 0 10px; border: 1px solid #dce2e9; border-radius: 9px; color: #556276; background: #f8fafc; font-size: .64rem; font-weight: 700; cursor: pointer; }
.curator-toggle input { width: 17px; height: 17px; accent-color: #2967e8; cursor: pointer; }
.more-button { width: 36px; height: 36px; border: 0; border-radius: 9px; background: #f2f4f7; cursor: pointer; }
.partner-detail-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; margin: 20px 0; }
.partner-detail-grid div { padding: 13px; border-radius: 11px; background: #f4f6f9; }
.partner-detail-grid small, .partner-detail-grid b { display: block; }
.partner-detail-grid small { color: #8a95a5; font-size: .6rem; }
.partner-detail-grid b { margin-top: 5px; font-size: .75rem; }
.admin-note { display: block; color: #5a6678; font-size: .7rem; font-weight: 800; }
.admin-note textarea { width: 100%; min-height: 90px; margin-top: 7px; padding: 12px; border: 1px solid #d9dfe7; border-radius: 11px; resize: vertical; font: inherit; font-size: .74rem; }
.notification-list { display: grid; gap: 8px; margin-top: 18px; }
.notification-list button { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 11px; padding: 13px; border: 0; border-radius: 12px; background: #f6f8fb; text-align: left; cursor: pointer; }
.notification-list .notification-item { display:grid;grid-template-columns:auto minmax(0,1fr);align-items:start;gap:11px;padding:13px;border-radius:12px;background:#f6f8fb; }
.notification-list .notification-item p { margin:4px 0;color:#667085; }
.notification-list button:hover { background: #eaf2fb; }
.notification-list b, .notification-list small { display: block; }
.notification-list b { font-size: .75rem; }
.notification-list small { margin-top: 4px; color: #8993a3; font-size: .62rem; }
.smartphone-notification-card { display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:12px; margin:16px 0 6px; padding:13px 14px; border:1px solid #eadfd7; border-radius:15px; background:#fff9f5; }
.smartphone-notification-card>span { display:grid; width:36px; height:36px; place-items:center; border-radius:12px; color:#c65328; background:#ffe9dd; font-size:1rem; font-weight:900; }
.smartphone-notification-card b,.smartphone-notification-card small { display:block; }
.smartphone-notification-card b { color:#31394a; font-size:.7rem; }
.smartphone-notification-card small { margin-top:4px; color:#7c8798; font-size:.58rem; line-height:1.45; }
.smartphone-notification-card .secondary-button { min-height:36px; padding:0 12px; }
.smartphone-notification-card.enabled { border-color:#cae9db; background:#f1faf6; }
.smartphone-notification-card.enabled>span { color:#167553; background:#dff4e9; }
.schedule-row { display: flex; align-items: center; gap: 9px; font-weight: 600 !important; }
.schedule-row input { width: 18px; min-height: 18px; margin: 0; accent-color: #2868ae; }
.user-switch-list { display: grid; gap: 8px; margin-top: 18px; }
.user-switch-list button { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 12px; padding: 12px; border: 1px solid #e3e8ef; border-radius: 12px; background: #f8fafc; text-align: left; cursor: pointer; }
.user-switch-list button:hover { border-color: #aac1dd; background: #eef5fc; }
.user-switch-list b, .user-switch-list small { display: block; }
.user-switch-list b { font-size: .78rem; }
.user-switch-list small { margin-top: 3px; color: #8590a1; font-size: .65rem; }
.install-explainer { margin-bottom: 16px !important; }
.local-note { display: grid; gap: 4px; margin: 0 0 16px; padding: 13px 14px; border: 1px solid #f0d28c; border-radius: 12px; color: #76500e; background: #fff8e7; }
.local-note b { font-size: .73rem; }
.local-note span { font-size: .66rem; line-height: 1.5; }
.install-guides { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.install-guides section { position: relative; padding: 15px; border: 1px solid #e1e6ed; border-radius: 13px; background: #f8fafc; }
.install-guides section.recommended { border-color: #8fb4df; box-shadow: inset 0 0 0 1px #8fb4df; }
.install-guides section.recommended:after { content: "Ваш телефон"; position: absolute; top: 10px; right: 10px; color: #2b65a8; font-size: .56rem; font-weight: 800; text-transform: uppercase; }
.phone-label { color: #244f84; font-size: .72rem; font-weight: 800; }
.install-guides ol { margin: 12px 0 0; padding-left: 19px; color: #596679; font-size: .67rem; line-height: 1.55; }
.install-guides li + li { margin-top: 6px; }

@media (max-width: 1180px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-grid-main, .admin-grid-bottom, .admin-distribution-grid { grid-template-columns: 1fr; }
  .insight-grid { grid-template-columns: 1fr 1fr; }
  .quality-insight { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .mode-switch { width: 44px; min-height: 44px; padding: 0; flex: 0 0 auto; }
  .mode-switch b { display: none; }
  .install-app-button span { display: none; }
  .install-app-button:after { content: none; }
  .install-app-button { color: #183a66; }
  .admin-heading { align-items: stretch; flex-direction: column; margin-bottom: 19px; }
  .admin-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .admin-actions > * { width: 100%; }
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .kpi-grid article { min-height: 116px; align-items: flex-start; flex-direction: column; gap: 8px; padding: 15px; }
  .kpi-icon { width: 36px; height: 36px; border-radius: 10px; }
  .kpi-grid b { font-size: 1.12rem; }
  .kpi-spark { display: none; }
  .admin-panel { padding: 17px; }
  .bar-chart { height: 210px; gap: 7px; }
  .bar-chart span { font-size: .5rem; }
  .admin-toolbar { align-items: stretch; flex-wrap: wrap; }
  .admin-country-bar { align-items: flex-start; flex-direction: column; }
  .country-switcher { width: 100%; overflow-x: auto; }
  .country-switcher button { flex: 1 0 auto; }
  .admin-toolbar .country-switcher { flex-basis: 100%; }
  .admin-search { flex-basis: 100%; }
  .admin-toolbar .range-button { flex: 1; }
  .admin-toolbar .range-select { flex:1; min-width:145px; }
  .data-table-wrap { margin-right: -14px; border-radius: 15px 0 0 15px; }
  .order-summary { grid-template-columns: repeat(2, 1fr); }
  .message-layout, .access-grid { grid-template-columns: 1fr; }
  .insight-grid { grid-template-columns: 1fr; }
  .quality-insight { grid-column: auto; }
  .message-stats > div { gap: 7px; }
  .segments-panel { grid-template-columns: 1fr; }
  .segments-panel .panel-head { grid-column: 1; }
  .campaign-row { grid-template-columns: 1fr auto; }
  .campaign-row > span { display: none; }
  .access-member { grid-template-columns: auto 1fr auto; }
  .access-member select { grid-column: 2; justify-self: start; }
  .curator-toggle { grid-column: 2; justify-self: start; }
  .access-member .more-button { grid-column: 3; grid-row: 1; }
  .curator-question { grid-template-columns: auto 1fr; }
  .curator-question > em, .curator-question .row-action { grid-column: 2; justify-self: start; }
  .partner-detail-grid { grid-template-columns: repeat(2, 1fr); }
  .install-guides { grid-template-columns: 1fr; }
}
.workspace { width: min(1640px, 100%); padding: 42px 34px 64px; }
.page-hero { min-height: 218px; padding: 40px 44px; }
.page-hero .lead { font-size: .92rem; }
.knowledge-search { min-height: 56px; }
.knowledge-search input { font-size: .9rem; }
.filter-chip { min-height: 44px; padding-inline: 16px; font-size: .74rem; }
.knowledge-layout { grid-template-columns: 240px minmax(0, 1fr); gap: 24px; }
.category-link { min-height: 43px; font-size: .76rem; }
.result-heading { min-height: 44px; font-size: .76rem; }
.knowledge-card { min-height: 212px; padding: 23px; }
.topic-pill, .access-mark { font-size: .64rem; }
.knowledge-card h2 { font-size: 1rem; }
.knowledge-card p { font-size: .78rem; line-height: 1.65; }
.card-footer { font-size: .68rem; }
.module-item { min-height: 92px; padding: 20px; }
.module-item h2 { font-size: .94rem; }
.module-item p { font-size: .75rem; }
.media-card h2 { font-size: .96rem; }
.media-card p, .news-list p { font-size: .74rem; }

@media (max-width: 1180px) {
  html { font-size: 17px; }
  .app-shell { grid-template-columns: 92px minmax(0, 1fr); }
  .workspace { padding-inline: 32px; }
}

@media (max-width: 760px) {
  html { font-size: 17px; }
  body { padding-bottom: calc(78px + env(safe-area-inset-bottom)); background: #f4f6f9; }
  .app-shell { display: block; }
  .sidebar {
    position: fixed;
    inset: auto 0 0;
    z-index: 80;
    width: 100%;
    height: calc(72px + env(safe-area-inset-bottom));
    display: block;
    padding: 7px 8px calc(7px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(255,255,255,.12);
    background: rgba(16,24,40,.98);
    transform: none;
    transition: none;
    backdrop-filter: blur(18px);
  }
  .brand, .sidebar-bottom { display: none; }
  .side-nav { height: 100%; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 3px; }
  .nav-item, .nav-item.active {
    min-height: 58px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 3px 2px;
    border-radius: 12px;
    box-shadow: none;
    font-size: .6rem;
    line-height: 1.1;
    text-align: center;
  }
  .nav-item.active { color: #fff; background: #223550; }
  .nav-item.active:after { content: ""; position: absolute; top: 3px; width: 18px; height: 3px; border-radius: 4px; background: var(--gold); }
  .nav-icon { width: auto; font-size: 1.16rem; line-height: 1; }
  .topbar {
    min-height: calc(64px + env(safe-area-inset-top));
    padding: env(safe-area-inset-top) 14px 0;
    gap: 9px;
  }
  .mobile-menu, .crumbs, .global-search kbd { display: none; }
  .global-search { width: auto; flex: 1; margin: 0; border-radius: 13px; }
  .global-search input { min-height: 44px; font-size: .78rem; }
  .notification-button { width: 44px; height: 44px; flex: 0 0 auto; }
  .install-app-button { width: 44px; min-height: 44px; overflow: hidden; padding: 0; color: transparent; position: relative; flex: 0 0 auto; }
  .install-app-button:after { content: "↓"; position: absolute; inset: 0; display: grid; place-items: center; color: #183a66; font-size: 1rem; }
  .workspace { width: 100%; padding: 24px 14px 30px; }
  .welcome-row { margin-bottom: 20px; gap: 18px; }
  .welcome-row .primary-button { width: 100%; }
  h1 { font-size: clamp(1.48rem, 7vw, 1.8rem); }
  .lead { font-size: .88rem; line-height: 1.55; }
  .dashboard-grid { gap: 14px; }
  .continue-card, .status-card { padding: 19px; border-radius: 19px; }
  .continue-content { gap: 18px; margin-top: 17px; }
  .module-art { height: 132px; }
  .answer-card { min-height: 112px; padding: 16px; }
  .page-hero { min-height: 0; margin-bottom: 16px; padding: 25px 21px; border-radius: 20px; }
  .page-hero:after { width: 170px; height: 170px; }
  .page-hero .lead { font-size: .82rem; }
  .hero-stat { min-width: 0; padding: 13px 15px; }
  .knowledge-toolbar { position: sticky; top: calc(64px + env(safe-area-inset-top)); z-index: 15; margin: 0 -14px 14px; padding: 10px 14px; background: rgba(244,246,249,.94); backdrop-filter: blur(12px); }
  .knowledge-search { min-height: 50px; }
  .filter-chips { flex-wrap: nowrap; overflow-x: auto; margin-right: -14px; padding: 1px 14px 6px 0; scrollbar-width: none; }
  .filter-chips::-webkit-scrollbar { display: none; }
  .filter-chip { min-height: 42px; flex: 0 0 auto; }
  .result-heading { min-height: 38px; }
  .sort-button { font-size: .7rem; }
  .knowledge-card { min-height: 185px; padding: 19px; border-radius: 17px; }
  .knowledge-card h2 { font-size: .96rem; }
  .knowledge-card p { font-size: .76rem; }
  .branch-banner { grid-template-columns: auto 1fr; padding: 14px; }
  .branch-banner .text-button { grid-column: 2; justify-self: start; padding: 0; }
  .course-layout { gap: 14px; }
  .module-item { min-height: 0; padding: 17px 15px; gap: 12px; }
  .module-item h2 { font-size: .9rem; }
  .module-item p { font-size: .72rem; }
  .course-aside { gap: 12px; }
  .media-summary { gap: 9px; }
  .media-summary > div { grid-template-columns: auto 1fr; gap: 8px; padding: 13px; }
  .media-summary small { grid-column: 2; }
  .media-title { align-items: flex-start; flex-direction: column; }
  .news-list article { grid-template-columns: 64px 10px 1fr; padding: 17px 14px; gap: 10px; }
  .featured-news { grid-template-columns: 1fr; min-height: 320px; padding: 22px; }
  .support-chat { min-height: 520px; grid-template-columns: 1fr; }
  .chat-thread-list { max-height: 185px; border-right: 0; border-bottom: 1px solid #e3e8ef; }
  .chat-conversation { min-height: 330px; }
  .chat-compose { grid-template-columns: 1fr; }
  .chat-compose > .primary-button { grid-column: auto; }
  .chat-file { width: 100%; min-width: 0; }
  .chat-file-label { max-width:calc(100vw - 112px); }
  .chart-stats { grid-template-columns: 1fr 1fr; gap: 10px; }
  .chart-stats p { display: none; }
  .chart-axis { font-size: .5rem; }
  .modal-backdrop { align-items: end; padding: 0; }
  .modal-card { width: 100%; max-height: 88vh; padding: 28px 20px calc(24px + env(safe-area-inset-bottom)); border-radius: 24px 24px 0 0; }
  .modal-actions { position: sticky; bottom: 0; margin: 20px -20px -24px; padding: 14px 20px calc(14px + env(safe-area-inset-bottom)); background: white; }
  .modal-card:has(.modal-facts) { padding-top:22px; }
  .modal-card:has(.modal-facts) .modal-label { margin-bottom:10px; }
  .modal-card:has(.modal-facts) h2 { margin-bottom:12px; font-size:1.38rem; line-height:1.28; }
  .modal-card:has(.modal-facts) p { margin-bottom:12px; line-height:1.62; }
  .modal-card:has(.modal-facts) .modal-facts { margin:14px 0 28px; }
  .modal-card:has(.modal-facts) .modal-actions { margin-top:0; }
  .toast { right: 14px; bottom: calc(90px + env(safe-area-inset-bottom)); left: 14px; text-align: center; }
}

@media (max-width: 390px) {
  .workspace { padding-inline: 12px; }
  .topbar { padding-inline: 10px; }
  .global-search input::placeholder { color: transparent; }
  .global-search:after { content: "Поиск по базе"; position: absolute; left: 38px; color: #8a94a6; pointer-events: none; font-size: .72rem; }
  .global-search:focus-within:after { display: none; }
  .media-summary { grid-template-columns: 1fr; }
  .module-item { grid-template-columns: 44px minmax(0, 1fr); }
  .modal-actions { flex-direction: column-reverse; }
}

@media (min-width: 1181px) {
  html { font-size: 15px; }
  .app-shell { grid-template-columns: 210px minmax(0, 1fr); }
  .sidebar { padding: 18px 12px 12px; }
  .brand { gap: 9px; padding-bottom: 16px; }
  .brand-mark { width: 34px; height: 34px; font-size: .92rem; }
  .brand b { font-size: .88rem; }
  .brand small { font-size: .61rem; }
  .nav-item { min-height: 38px; gap: 9px; font-size: .74rem; }
  .nav-icon { width: 19px; font-size: 1rem; }
  .topbar { min-height: 62px; padding-inline: 22px; }
  .global-search { width: min(440px, 36vw); }
  .global-search input { min-height: 42px; }
  .workspace { width: min(1680px, 100%); padding: 20px 22px 42px; }
  .welcome-row { margin-bottom: 18px; }
  h1 { font-size: clamp(1.48rem, 1.75vw, 1.72rem); }
  .dashboard-grid { gap: 16px; }
  .continue-card, .status-card { padding: 18px; }
  .continue-content { grid-template-columns: 124px 1fr; gap: 19px; margin-top: 14px; }
  .module-art { height: 148px; }
  .module-art span { font-size: 2.55rem; }
  .quick-section { margin-top: 20px; }
  .answer-card { min-height: 88px; padding: 14px; }
  .admin-heading { margin-bottom: 17px; }
  .kpi-grid { gap: 11px; margin-bottom: 13px; }
  .kpi-grid article { min-height: 96px; padding: 14px; }
  .kpi-icon { width: 40px; height: 40px; }
  .kpi-spark { width: 68px; }
  .insight-grid { gap: 12px; margin-bottom: 12px; }
  .insight-grid .admin-panel { min-height: 148px; }
  .admin-grid-main, .admin-grid-bottom, .admin-distribution-grid { gap: 12px; margin-bottom: 12px; }
  .admin-panel { padding: 16px; }
  .panel-head { margin-bottom: 14px; }
  .bar-chart { height: 188px; }
  .page-hero { min-height: 126px; margin-bottom: 12px; padding: 18px 24px; border-radius: 18px; }
  .page-hero:after { width: 190px; height: 190px; right: -52px; bottom: -122px; }
  .page-hero h1 { margin-bottom: 5px; font-size: 1.48rem; }
  .page-hero .lead { max-width: 820px; font-size: .78rem; line-height: 1.5; }
  .hero-stat { min-width: 122px; gap: 9px; padding: 10px 13px; border-radius: 13px; }
  .hero-stat b { font-size: 1.45rem; }
  .hero-stat span { font-size: .62rem; }
  .knowledge-toolbar { gap: 10px; margin-bottom: 10px; }
  .knowledge-search { min-height: 42px; padding: 0 13px; border-radius: 11px; }
  .knowledge-search input { font-size: .78rem; }
  .filter-chips { gap: 5px; flex-wrap: nowrap; }
  .filter-chip { min-height: 34px; padding-inline: 11px; font-size: .66rem; }
  .knowledge-layout { grid-template-columns: 184px minmax(0, 1fr); gap: 14px; }
  .category-panel { padding: 13px 10px; border-radius: 13px; }
  .panel-label { margin: 0 7px 8px; }
  #category-list { gap: 1px; }
  .category-link { min-height: 30px; padding-inline: 8px; font-size: .66rem; }
  .update-note { margin-top: 10px; padding: 10px 8px 0; }
  .result-heading { min-height: 30px; font-size: .67rem; }
  .knowledge-grid { grid-template-columns: repeat(auto-fit, minmax(285px, 1fr)); grid-auto-rows: 146px; gap: 9px; }
  .knowledge-card { height: 100%; min-height: 0; padding: 14px; border-radius: 13px; animation: card-arrive .35s ease both; }
  .knowledge-card:nth-child(2) { animation-delay: .04s; }
  .knowledge-card:nth-child(3) { animation-delay: .08s; }
  .knowledge-card:nth-child(4) { animation-delay: .12s; }
  .knowledge-card:nth-child(5) { animation-delay: .16s; }
  .knowledge-card:nth-child(6) { animation-delay: .2s; }
  .knowledge-card-top { margin-bottom: 9px; }
  .topic-pill { padding: 4px 7px; }
  .knowledge-card h2 { min-height: 2.2em; margin-bottom: 5px; overflow: hidden; font-size: .82rem; line-height: 1.35; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
  .knowledge-card p { margin-bottom: 8px; overflow: hidden; font-size: .66rem; line-height: 1.42; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
  .card-footer { font-size: .58rem; }
  .course-hero { min-height: 112px; }
  .course-overview { gap: 10px; padding: 9px 13px; border-radius: 13px; }
  .course-ring { width: 44px; height: 44px; border-width: 5px; font-size: .68rem; }
  .branch-banner { gap: 11px; margin-bottom: 12px; padding: 10px 14px; border-radius: 12px; }
  .branch-icon { width: 30px; height: 30px; }
  .course-layout { grid-template-columns: minmax(0, 1fr) 252px; gap: 12px; }
  .module-list { gap: 7px; }
  .module-item { min-height: 66px; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 11px; padding: 10px 12px; border-radius: 13px; }
  .module-number { width: 38px; height: 38px; border-radius: 10px; font-size: .72rem; }
  .module-item h2 { margin-bottom: 3px; font-size: .8rem; }
  .module-item p { overflow: hidden; font-size: .64rem; line-height: 1.35; white-space: nowrap; text-overflow: ellipsis; }
  .module-item button { min-width: 92px; min-height: 32px; font-size: .62rem; }
  .course-aside { gap: 9px; }
  .aside-card { padding: 15px; border-radius: 13px; }
  .aside-card h2 { margin: 7px 0; font-size: .92rem; }
  .aside-card p { font-size: .64rem; line-height: 1.45; }
  .aside-card ul { gap: 7px; margin-top: 11px; font-size: .63rem; }
}

@keyframes draw-spark { to { stroke-dashoffset: 0; } }
@keyframes rise-bar { from { transform: scaleY(.08); opacity: .35; } to { transform: scaleY(1); opacity: 1; } }
@keyframes reveal-progress { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes card-arrive { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
@keyframes chart-pulse { 50% { transform: scale(1.25); transform-origin: center; } }

@media (prefers-reduced-motion: reduce) {
  .kpi-spark polyline, .bar-chart > div, .branch-bars i em, .region-bars i em, .knowledge-card, .order-columns i, .turnover-line .line, .turnover-line circle.current { animation: none; }
  .chart-hit-tooltip,.sales-month:after { transition:none; }
}

@media (display-mode: standalone) {
  .install-app-button { display: none; }
  .topbar { background: rgba(255,255,255,.97); }
}

/* Business cabinets added from the approved RK functional brief. */
.partner-announcement { display:grid; grid-template-columns:auto 1fr auto; gap:14px; align-items:center; margin-bottom:12px; padding:13px 16px; border:1px solid #f3d79a; border-radius:15px; background:linear-gradient(90deg,#fff8e8,#fffdf8); }
.announcement-mark { width:32px; height:32px; display:grid; place-items:center; border-radius:10px; color:#765000; background:#ffd774; font-weight:800; }
.partner-announcement small,.partner-announcement b,.partner-announcement p { display:block; }
.partner-announcement small { margin-bottom:2px; color:#8a6a22; font-size:.62rem; font-weight:800; text-transform:uppercase; letter-spacing:.08em; }
.partner-announcement b { font-size:.8rem; }
.partner-announcement p { margin:2px 0 0; color:var(--muted); font-size:.67rem; }
.business-kpis { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; margin-bottom:12px; }
.business-kpis article { min-height:90px; padding:14px 16px; border:1px solid var(--line); border-radius:15px; background:#fff; box-shadow:var(--shadow-soft); }
.business-kpis small,.business-kpis b,.business-kpis em { display:block; }
.business-kpis small { color:var(--muted); font-size:.65rem; font-weight:700; }
.business-kpis b { margin:7px 0 4px; color:var(--ink); font-size:1.18rem; font-style:normal; }
.business-kpis em { color:var(--muted); font-size:.62rem; font-style:normal; }
.business-kpis.compact { margin-bottom:14px; }
.partner-business-strip { display:grid; grid-template-columns:2fr 1fr 1.25fr; gap:1px; margin-bottom:16px; overflow:hidden; border:1px solid #dfe6ef; border-radius:15px; background:#dfe6ef; }
.partner-business-strip>div { min-height:82px; display:flex; flex-direction:column; justify-content:center; padding:12px 16px; background:#fff; }
.partner-business-strip span,.partner-business-strip small { color:var(--muted); font-size:.62rem; }
.partner-business-strip b { margin:4px 0; font-size:.82rem; }
.partner-business-strip i { height:5px; margin-top:7px; overflow:hidden; border-radius:5px; background:#e9eef5; }
.partner-business-strip i em { display:block; height:100%; border-radius:inherit; background:linear-gradient(90deg,#f5b642,#2d6cdf); }
.level-badge { color:#205da8!important; font-weight:800; }
.partner-performance { display:grid; gap:12px; margin-bottom:18px; }
.personal-ranking-card { min-height:110px; display:flex; align-items:center; justify-content:space-between; gap:24px; overflow:hidden; padding:18px 22px; border-radius:17px; color:#fff; background:linear-gradient(115deg,#142e52,#24578f 72%,#3072b5); box-shadow:0 12px 26px rgba(26,64,108,.16); }
.personal-ranking-card .eyebrow { margin-bottom:6px; color:#b9cce3; }
.personal-ranking-card h2 { margin:0 0 4px; font-size:1.6rem; letter-spacing:-.045em; }
.personal-ranking-card > div > span { color:#d6e2ef; font-size:.68rem; }
.ranking-summary { min-width:250px; display:grid; grid-template-columns:auto 1fr; align-items:center; gap:0 12px; padding-left:22px; border-left:1px solid rgba(255,255,255,.18); }
.ranking-summary b { grid-row:1 / 3; font-size:2.8rem; line-height:1; letter-spacing:-.08em; }
.ranking-summary span { color:#fff; font-size:.72rem; font-weight:800; }
.ranking-summary em { color:#f5c766; font-size:.66rem; font-style:normal; font-weight:700; }
.performance-main-grid { display:grid; grid-template-columns:1.32fr .88fr; gap:12px; }
.performance-detail-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.performance-card { min-width:0; padding:17px 18px; border:1px solid var(--line); border-radius:16px; background:#fff; box-shadow:var(--shadow-soft); }
.performance-card .eyebrow { margin-bottom:5px; }
.performance-card h2 { margin:0; font-size:.94rem; letter-spacing:-.02em; }
.performance-card-head { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; }
.level-target { display:flex; justify-content:space-between; gap:18px; margin:15px 0 8px; }
.level-target b { font-size:.72rem; }
.level-target span { color:var(--muted); font-size:.64rem; }
.segmented-progress { display:grid; grid-template-columns:repeat(5,1fr); gap:4px; }
.segmented-progress i { height:7px; border-radius:999px; background:#e8edf4; }
.segmented-progress i.done { background:linear-gradient(90deg,#e9a62d,#f5c05b); }
.level-roadmap { display:grid; grid-template-columns:repeat(4,1fr); gap:9px; margin-top:14px; }
.level-roadmap > span { position:relative; min-width:0; padding-top:26px; }
.level-roadmap i { position:absolute; top:0; left:0; width:20px; height:20px; display:grid; place-items:center; border:1px solid #d6deea; border-radius:50%; color:#8c97a8; font-size:.57rem; font-style:normal; font-weight:800; background:#fff; }
.level-roadmap span.done i { border-color:#b8e2ce; color:#237758; background:#e9f7f0; }
.level-roadmap span.current i { border-color:#f0c35f; color:#7b5607; background:#fff3d4; }
.level-roadmap b,.level-roadmap small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.level-roadmap b { font-size:.62rem; }
.level-roadmap small { margin-top:3px; color:var(--muted); font-size:.56rem; }
.volume-bonus-card { display:flex; flex-direction:column; justify-content:space-between; background:linear-gradient(145deg,#fff,#fbfcff); }
.volume-bonus-card h2 { margin-top:2px; color:#225d9f; font-size:1.38rem; }
.volume-bonus-card p { margin:5px 0 0; color:var(--muted); font-size:.65rem; }
.bonus-progress-head { display:grid; grid-template-columns:auto 1fr auto; align-items:baseline; gap:6px; margin-top:18px; }
.bonus-progress-head b { font-size:1rem; }
.bonus-progress-head span { color:var(--muted); font-size:.63rem; }
.bonus-progress-head em { color:#226aa3; font-size:.63rem; font-style:normal; font-weight:800; }
.bonus-progress { height:8px; margin:7px 0 11px; overflow:hidden; border-radius:999px; background:#e9eef5; }
.bonus-progress span { display:block; height:100%; border-radius:inherit; background:linear-gradient(90deg,#efab34,#ffd170); animation:reveal-progress .7s ease-out both; }
.volume-bonus-card > small { color:#7c8798; font-size:.59rem; line-height:1.45; }
.pending-card ul,.reward-rules-card ul { display:grid; gap:8px; margin:13px 0 0; padding:0; list-style:none; }
.pending-card li { display:grid; grid-template-columns:auto 1fr; gap:8px; align-items:center; }
.pending-card li > i { width:7px; height:7px; border-radius:50%; background:#edb13e; }
.pending-card li b,.pending-card li small { display:block; }
.pending-card li b { font-size:.64rem; }
.pending-card li small { margin-top:2px; color:var(--muted); font-size:.57rem; }
.pending-card li.pending-empty { grid-template-columns:32px 1fr; min-height:66px; padding:10px 12px; border:1px dashed #dce4ee; border-radius:12px; background:#f8fafc; }
.pending-card li.pending-empty > span { width:30px; height:30px; display:grid; place-items:center; border-radius:10px; color:#278064; background:#e8f7f0; font-size:.8rem; font-weight:900; }
.pending-card li.pending-empty b { font-size:.68rem; }
.pending-card li.pending-empty small { max-width:280px; line-height:1.45; }
.team-summary-card { display:flex; flex-direction:column; }
.team-summary-card dl { margin:11px 0 9px; }
.team-summary-card dl div { display:flex; align-items:center; justify-content:space-between; min-height:28px; border-bottom:1px solid #edf0f4; }
.team-summary-card dt { color:#596779; font-size:.64rem; }
.team-summary-card dd { margin:0; color:#1d4f87; font-size:.72rem; font-weight:800; }
.team-summary-card .text-button { align-self:flex-start; margin-top:auto; padding:0; }
.reward-rules-card ul { gap:7px; }
.reward-rules-card li { display:grid; grid-template-columns:22px 1fr; gap:8px; align-items:start; }
.reward-rules-card li > span { width:21px; height:21px; display:grid; place-items:center; border-radius:7px; color:#9b6104; background:#fff2d1; font-size:.56rem; font-weight:800; }
.reward-rules-card li p { margin:1px 0 0; color:#536175; font-size:.61rem; line-height:1.45; }
.reward-rules-card li p b { color:#1d2b3e; }
.compact-page-heading { display:flex; justify-content:space-between; gap:24px; align-items:flex-end; margin-bottom:16px; }
.compact-page-heading h1 { margin:2px 0 4px; }
.compact-page-heading .lead { max-width:780px; }
.promo-grid,.two-column-panels,.profile-form-grid,.application-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin-bottom:14px; }
.promo-grid article { position:relative; padding:16px 18px; border:1px solid #d7e1ee; border-radius:15px; background:linear-gradient(135deg,#fff,#f5f8fc); }
.promo-grid small,.promo-grid b,.promo-grid p { display:block; }
.promo-grid small { color:var(--muted); font-size:.62rem; }
.promo-grid b { margin:7px 0 3px; font-size:.93rem; }
.promo-grid p { margin:0; color:var(--muted); font-size:.65rem; }
.promo-grid article > button { position:absolute; top:16px; right:16px; border:0; color:#2465c3; background:none; font-size:.65rem; font-weight:800; cursor:pointer; }
.mini-chart-panel { margin-bottom:14px; }
.period-pills { display:flex; gap:5px; }
.period-pills button { min-height:30px; padding:0 10px; border:1px solid #dbe3ee; border-radius:9px; color:var(--muted); background:#fff; font-size:.62rem; font-weight:700; }
.period-pills button.active { color:#fff; border-color:#1e5ba7; background:#1e5ba7; }
.partner-bars { height:150px; display:flex; gap:8%; align-items:end; padding:14px 5% 0; border-bottom:1px solid #dce4ed; background:repeating-linear-gradient(to bottom,transparent 0,transparent 49px,#edf1f6 50px); }
.partner-bars i { position:relative; width:9%; height:var(--v); border-radius:8px 8px 2px 2px; background:linear-gradient(#64a0e0,#205da8); animation:rise-bar .7s ease both; transform-origin:bottom; }
.partner-bars i span { position:absolute; top:-20px; left:50%; transform:translateX(-50%); font-size:.61rem; font-style:normal; font-weight:800; }
.partner-axis { display:flex; justify-content:space-around; padding:7px 3% 0; color:var(--muted); font-size:.58rem; }
.data-table-wrap.embedded { margin:0; border:0; border-radius:0; box-shadow:none; }
.draft-note { display:flex; gap:8px; align-items:center; margin-bottom:14px; padding:11px 14px; border:1px solid #efcf8c; border-radius:12px; color:#6b5423; background:#fff8e8; font-size:.66rem; }
.leader-list { display:grid; gap:6px; margin:0; padding:0; list-style:none; }
.leader-list li { display:grid; grid-template-columns:28px 1fr auto; gap:10px; align-items:center; padding:9px 10px; border-radius:10px; background:#f5f7fa; }
.leader-list li>span { width:26px; height:26px; display:grid; place-items:center; border-radius:50%; color:#1f5b9c; background:#e4effc; font-size:.63rem; font-weight:800; }
.leader-list b,.leader-list small { display:block; }
.leader-list small { margin-top:2px; color:var(--muted); font-size:.57rem; }
.leader-list strong { font-size:.66rem; }
.leader-list li.leader-empty { grid-template-columns:42px minmax(0,1fr); min-height:112px; padding:18px; border:1px dashed #d8e0ea; background:linear-gradient(135deg,#f8fafc,#f3f6fa); }
.leader-list li.leader-empty > span { width:40px; height:40px; color:#b84a24; background:#fff0e9; font-size:1.2rem; }
.leader-list li.leader-empty b { font-size:.78rem; line-height:1.35; }
.leader-list li.leader-empty small { max-width:360px; margin-top:5px; font-size:.63rem; line-height:1.45; }
.team-donut { min-height:150px; display:flex; gap:20px; align-items:center; justify-content:center; }
.team-donut>span { width:96px; height:96px; display:grid; place-items:center; border:12px solid #dbe9f8; border-top-color:#2766ac; border-right-color:#2766ac; border-radius:50%; color:#1f5b9c; font-size:1.45rem; font-weight:800; transform:rotate(12deg); }
.team-donut>span small { font-size:.62rem; }
.team-donut div { max-width:220px; }
.team-donut p { color:var(--muted); font-size:.65rem; }
.payout-hero { display:grid; grid-template-columns:1.2fr 1fr 1fr; gap:1px; margin-bottom:14px; overflow:hidden; border-radius:16px; background:#2a4160; }
.payout-hero>div { min-height:112px; padding:18px; color:#fff; background:#17365e; }
.payout-hero>div:first-child { background:linear-gradient(135deg,#17365e,#2867ad); }
.payout-hero small,.payout-hero b,.payout-hero span { display:block; }
.payout-hero small { opacity:.7; font-size:.62rem; }
.payout-hero b { margin:9px 0 4px; font-size:1.25rem; }
.payout-hero span { opacity:.75; font-size:.62rem; }
.payout-split { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin-top:14px; }
.payout-split>div,.bonus-row { padding:12px; border-radius:11px; background:#f4f7fa; }
.payout-split span,.payout-split b,.payout-split small { display:block; }
.payout-split span,.payout-split small { color:var(--muted); font-size:.6rem; }
.payout-split b { margin:6px 0; font-size:.9rem; }
.check-list { display:grid; gap:7px; padding:0; list-style:none; font-size:.69rem; }
.check-list li { padding:9px 10px; border-radius:9px; background:#f5f7fa; }
.check-list .done { color:#187a53; background:#eaf8f2; }
.profile-form-grid { align-items:start; }
.form-grid { display:grid; grid-template-columns:1fr 1fr; gap:10px; margin:14px 0; }
.form-grid.one { grid-template-columns:1fr; }
.form-grid label { color:var(--muted); font-size:.61rem; font-weight:700; }
.form-grid input { width:100%; min-height:38px; margin-top:5px; padding:0 10px; border:1px solid #dce4ee; border-radius:9px; color:var(--ink); background:#fff; font:inherit; }
.document-status { display:flex; gap:10px; align-items:center; margin:14px 0; padding:12px; border-radius:11px; background:#ebf8f3; }
.document-status>span { width:28px; height:28px; display:grid; place-items:center; border-radius:50%; color:#178259; background:#d5f1e5; }
.document-status b,.document-status small { display:block; }
.document-status small { margin-top:2px; color:var(--muted); font-size:.58rem; }
.profile-top-grid,.profile-history-grid,.profile-finance-grid { display:grid; gap:12px; margin-bottom:12px; }
.profile-top-grid { grid-template-columns:1.42fr .78fr; }
.profile-history-grid,.profile-finance-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.profile-name-row { display:flex; align-items:center; gap:13px; }
.profile-avatar-large { width:48px; height:48px; display:grid; place-items:center; flex:0 0 auto; border-radius:15px; color:#fff; background:linear-gradient(145deg,#1e4e86,#357ac0); font-size:.82rem; font-weight:800; }
.profile-name-row .eyebrow { margin-bottom:3px; }
.profile-name-row h2 { margin:0 0 3px; font-size:1rem; }
.profile-name-row > div > span { color:var(--muted); font-size:.61rem; }
.profile-personal-card .currency-preview { grid-column:1 / -1; }
.contract-card { display:flex; flex-direction:column; }
.contract-card .secondary-button { align-self:flex-start; margin-top:auto; }
.contract-status-showcase { display:flex; align-items:flex-start; gap:16px; min-height:154px; padding:18px; border:1px solid #e5e7eb; border-radius:18px; background:linear-gradient(135deg,#fbfcfe,#f4f7fb); }
.contract-status-showcase .contract-status-icon { display:grid; place-items:center; flex:0 0 54px; width:54px; height:54px; border-radius:50%; color:#607087; background:#e8edf4; box-shadow:0 0 0 7px rgba(96,112,135,.08); font-size:1.55rem; font-weight:900; }
.contract-status-showcase .eyebrow { margin:1px 0 6px; }
.contract-status-showcase h2 { margin:0 0 8px; font-size:1.18rem; }
.contract-status-showcase p:not(.eyebrow) { max-width:560px; margin:0; color:#667287; font-size:.8rem; line-height:1.55; }
.contract-status-showcase small { display:block; margin-top:10px; color:#8993a3; font-size:.65rem; }
.contract-status-showcase.signed { border-color:#c8eadb; background:linear-gradient(135deg,#f1fbf6,#fbfffd); }
.contract-status-showcase.signed .contract-status-icon { color:#fff; background:#24a46d; box-shadow:0 0 0 7px rgba(36,164,109,.11); }
.contract-status-showcase.signed .eyebrow { color:#23845d; }
.contract-status-showcase.pending { border-color:#f0dfae; background:linear-gradient(135deg,#fffaf0,#fffdf8); }
.contract-status-showcase.pending .contract-status-icon { color:#9b6805; background:#ffe9ad; box-shadow:0 0 0 7px rgba(224,168,36,.1); }
.contract-status-showcase.pending .eyebrow { color:#9b6805; }
.contract-status-showcase.revision { border-color:#efceca; background:linear-gradient(135deg,#fff6f4,#fffafa); }
.contract-status-showcase.revision .contract-status-icon { color:#fff; background:#c95648; box-shadow:0 0 0 7px rgba(201,86,72,.1); }
.contract-status-showcase.revision .eyebrow { color:#a9473d; }
.profile-card-heading { display:flex; align-items:flex-start; gap:11px; }
.profile-card-heading > div { min-width:0; flex:1; }
.profile-card-heading h2 { margin:0; font-size:.94rem; }
.profile-card-heading .status-pill,.locked-badge { margin-left:auto; }
.profile-card-icon { width:34px; height:34px; display:grid; place-items:center; flex:0 0 auto; border-radius:10px; font-size:.78rem; font-weight:800; }
.profile-card-icon.blue { color:#2160a5; background:#e8f1fc; }
.profile-card-icon.gold { color:#95620b; background:#fff1d2; }
.profile-card-icon.green { color:#21775a; background:#e6f6ef; }
.profile-card-icon.violet { color:#72459d; background:#f2e9fb; }
.profile-card-icon.slate { color:#536378; background:#edf1f6; }
.locked-badge { padding:5px 8px; border-radius:999px; color:#64748b; background:#f0f3f7; font-size:.56rem; font-weight:800; white-space:nowrap; }
.profile-note { margin:11px 0 8px; color:#718096; font-size:.63rem; line-height:1.5; }
.profile-info-list { margin:8px 0 15px; }
.profile-info-list > div { display:flex; align-items:center; justify-content:space-between; gap:16px; min-height:34px; border-bottom:1px solid #edf0f4; }
.profile-info-list dt { color:#6f7c8f; font-size:.63rem; }
.profile-info-list dd { margin:0; color:#1f2c3e; font-size:.65rem; font-weight:800; text-align:right; }
.purchase-source-note { margin-bottom:12px; }
.purchase-edit-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.purchase-edit-grid label { min-width:0; color:var(--muted); font-size:.61rem; font-weight:700; }
.purchase-edit-grid label small { font-size:.53rem; font-weight:500; }
.purchase-edit-grid input { width:100%; min-height:38px; margin-top:5px; padding:0 10px; border:1px solid #dce4ee; border-radius:9px; color:var(--ink); background:#fff; font:inherit; }
.purchase-order-field { grid-column:1 / -1; }
.purchase-save-button { margin-top:12px; }
.purchase-verified-badge { color:#18754c; background:#e8f7ef; }
.purchase-manual-badge { color:#8b5b0b; background:#fff2d5; }
.purchase-required-badge { color:#a3472e; background:#fff0e9; }
.purchase-info-list dd { max-width:65%; overflow-wrap:anywhere; }
.profile-finance-grid .form-grid { margin-bottom:9px; }
.form-help { margin:0 0 12px; color:#788497; font-size:.6rem; line-height:1.45; }
.security-card { display:flex; align-items:center; justify-content:space-between; gap:20px; }
.security-card > div { display:flex; align-items:center; gap:12px; }
.security-card h2 { margin:0 0 3px; font-size:.94rem; }
.security-card p { margin:0; color:var(--muted); font-size:.62rem; }
.level-table-panel { margin-bottom:14px; }
.bonus-row { display:flex; justify-content:space-between; align-items:center; margin-top:7px; font-size:.68rem; }
.tax-bars { display:grid; gap:12px; margin-top:18px; }
.tax-bars>div { display:grid; grid-template-columns:95px 1fr 25px; gap:10px; align-items:center; color:var(--muted); font-size:.62rem; }
.tax-bars i { height:7px; overflow:hidden; border-radius:7px; background:#e7edf4; }
.tax-bars i em { display:block; height:100%; border-radius:inherit; background:#3e82c8; }
.application-grid .admin-panel>small { color:var(--muted); font-size:.62rem; }
.ok-mark { color:#178259; font-weight:800; }
.bad-mark { color:#c44b49; font-weight:800; }
.status-pill.danger { color:#a43734; background:#feeceb; }
.table-action.primary { color:#fff; background:#2466c5; }
.table-action { min-height:30px; padding:0 10px; border:1px solid #d8e1ec; border-radius:8px; color:#205b9f; background:#f7faff; font:700 .6rem "Golos Text",sans-serif; cursor:pointer; }
.registration-actions { display:flex; align-items:center; gap:7px; flex-wrap:wrap; }
.table-action.danger { border-color:#f0ceca; color:#b9473c; background:#fff7f6; }
.table-action.danger:hover,.table-action.danger:focus-visible { border-color:#dc8178; color:#8f2f28; background:#fdebea; outline:none; }
.danger-button { min-height:46px; padding:0 18px; border:0; border-radius:12px; color:#fff; background:#c94f43; box-shadow:0 9px 22px rgba(170,55,45,.22); font:700 .72rem "Golos Text",sans-serif; cursor:pointer; }
.danger-button:hover { background:#ad3e35; }
.danger-button.compact { min-height:40px; padding:0 14px; border:1px solid #efc5c0; color:#a54037; background:#fff8f7; box-shadow:none; }
.danger-button.compact:hover { color:#fff; background:#b8493f; }
.form-guidance { margin:0 0 14px; padding:12px 14px; border:1px solid #f1d1be; border-radius:12px; color:#8d563c; background:#fff8f3; font-size:.78rem; line-height:1.5; }
.contract-history-list { display:grid; gap:10px; margin-top:18px; }
.contract-history-list button { display:flex; align-items:center; justify-content:space-between; gap:18px; width:100%; padding:14px 16px; border:1px solid #eadfd7; border-radius:14px; color:#201d1b; background:#fff; text-align:left; cursor:pointer; }
.contract-history-list button:hover { border-color:#f4773f; background:#fff9f5; }
.contract-history-list span,.contract-history-list small,.contract-history-list em { display:block; }
.contract-history-list small { margin-top:3px; color:#788398; }
.contract-history-list em { margin-top:7px; color:#9b6045; font-style:normal; }
.contract-history-list strong { color:#e85f2e; white-space:nowrap; }
.danger-label { color:#ac3d33!important; background:#fdebea!important; }
.edit-record-action { display:inline-flex; align-items:center; justify-content:center; gap:6px; border-color:#f0cdbd; color:#b94b22; background:#fff8f4; white-space:nowrap; }
.edit-record-action span { font-size:.7rem; }
.edit-record-action:hover,.edit-record-action:focus-visible { border-color:#ff9d70; color:#953815; background:#ffebe1; outline:none; }
.payout-confirm>div { display:flex; justify-content:space-between; align-items:center; margin:14px 0; padding:14px; border-radius:12px; background:#f4f7fa; }

/* Entry and registration */
.auth-locked { overflow:hidden; }
.auth-locked .app-shell { display:none; }
.auth-gate { min-height:100vh; display:grid; grid-template-columns:minmax(340px,42%) minmax(0,1fr); color:#172033; background:#f4f7fb; }
.auth-gate.is-hidden { display:none; }
.auth-brand-panel { position:relative; min-height:100vh; display:flex; flex-direction:column; justify-content:flex-start; gap:30px; overflow:hidden; padding:clamp(138px,17vh,190px) clamp(34px,6vw,90px) clamp(30px,5vh,54px); color:#fff; background:linear-gradient(145deg,#1b1917 0%,#242220 58%,#4a352b 100%); }
.auth-brand-panel:after { content:""; position:absolute; right:-150px; bottom:-150px; width:430px; height:430px; border:1px solid rgba(255,255,255,.13); border-radius:50%; box-shadow:0 0 0 55px rgba(255,255,255,.035),0 0 0 110px rgba(255,255,255,.025); }
.auth-logo { position:absolute; top:30px; left:clamp(34px,6vw,90px); width:68px; height:68px; display:block; padding:3px; border:1px solid rgba(255,131,61,.62); border-radius:19px; background:rgba(255,255,255,.08); box-shadow:0 12px 30px rgba(0,0,0,.28),0 0 0 5px rgba(255,131,61,.07); }
.auth-logo .auth-device { width:100%; height:100%; display:block; object-fit:cover; border-radius:15px; }
.auth-logo b { position:absolute; right:-7px; bottom:-7px; width:29px; height:29px; display:grid; place-items:center; overflow:hidden; padding:3px; border:3px solid #fff; border-radius:50%; background:#000; box-shadow:0 0 0 3px #1b1917,0 4px 12px rgba(0,0,0,.24); }
.auth-logo b img { width:100%; height:100%; display:block; object-fit:cover; }
.auth-brand-panel>div:not(.auth-features) { position:relative; z-index:1; }
.auth-brand-panel p { margin:0 0 8px; color:#ff9a4f; font-size:.72rem; font-weight:700; letter-spacing:.12em; text-transform:uppercase; }
.auth-brand-panel h1 { margin:0; color:#fff; font-family:"Actay Wide","Golos Text",sans-serif; font-size:clamp(2.4rem,5vw,4.8rem); font-weight:600; letter-spacing:-.035em; }
.auth-brand-panel>div>span { max-width:560px; display:block; color:#d8e8f8; font-size:1rem; line-height:1.65; }
.auth-profession { max-width:560px; display:grid; gap:1px; margin-top:18px; font-size:clamp(1.25rem,2.15vw,1.72rem); font-weight:700; line-height:1.18; letter-spacing:-.035em; }
.auth-profession span { color:#fff; }
.auth-profession span:last-child { color:#d8e8f8; }
.auth-profession em { color:#ff874d; font-style:normal; }
.auth-features { position:relative; z-index:1; display:grid; gap:15px; }
.auth-brand-panel .auth-features span { display:grid; grid-template-columns:18px 1fr; align-items:center; gap:12px; color:#f4eee9; font-size:.82rem; line-height:1.45; }
.auth-brand-panel .auth-features span:before { content:""; width:18px; height:3px; align-self:center; border-radius:999px; background:linear-gradient(90deg,#ff833d,#ffc387); box-shadow:0 4px 12px rgba(255,131,61,.28); }

.page-heading h1,.compact-page-heading h1,.admin-heading h1,.page-hero h1 { font-family:"Actay Wide","Golos Text",sans-serif; font-weight:600; letter-spacing:-.02em; }
.auth-form-panel { display:grid; place-items:center; overflow-y:auto; padding:28px; }
.auth-card { width:min(450px,100%); padding:32px; border:1px solid #dce4ee; border-radius:24px; background:#fff; box-shadow:0 24px 70px rgba(21,42,72,.12); }
.auth-mobile-brand { display:none; align-items:center; gap:10px; margin-bottom:22px; }
.auth-mobile-brand span { width:38px; height:38px; display:block; padding:2px; overflow:hidden; border:1px solid #efc1ac; border-radius:11px; background:#fff3ed; }
.auth-mobile-brand span img { width:100%; height:100%; display:block; object-fit:cover; border-radius:8px; }
.auth-tabs { display:grid; grid-template-columns:1fr 1fr; gap:4px; margin-bottom:28px; padding:4px; border-radius:12px; background:#f0f3f7; }
.auth-tabs button { min-height:40px; border:0; border-radius:9px; color:#6f7d91; background:transparent; font:700 .76rem "Golos Text",sans-serif; cursor:pointer; }
.auth-tabs button.active { color:#173962; background:#fff; box-shadow:0 2px 10px rgba(24,55,94,.09); }
.auth-pane h2 { margin:3px 0 8px; font-size:1.45rem; }
.auth-pane>p:not(.eyebrow) { margin:0 0 22px; color:#738198; font-size:.76rem; line-height:1.55; }
.auth-form { display:grid; gap:15px; }
[data-auth-pane="register"] .auth-form { gap:10px; }
[data-auth-pane="register"] .auth-form input,[data-auth-pane="register"] .auth-form select { min-height:42px; }
.auth-form label { display:grid; gap:7px; color:#435066; font-size:.68rem; font-weight:700; }
.auth-form label>small { color:#909bae; font-size:.6rem; font-weight:500; }
.auth-form input,.auth-form select { width:100%; min-height:46px; padding:0 13px; border:1px solid #d6dfeb; border-radius:11px; color:#172033; background:#fff; font:500 .76rem "Golos Text",sans-serif; outline:none; }
.auth-form input:focus,.auth-form select:focus { border-color:#3977be; box-shadow:0 0 0 3px rgba(57,119,190,.12); }
.password-field { position:relative; display:block; }
.password-field input { padding-right:46px; }
.password-field button { position:absolute; top:5px; right:5px; width:36px; height:36px; border:0; border-radius:8px; color:#738198; background:transparent; cursor:pointer; }
.auth-submit { width:100%; min-height:46px; margin-top:4px; }
.auth-link { justify-self:center; padding:5px; border:0; color:#2766ac; background:none; font:700 .67rem "Golos Text",sans-serif; cursor:pointer; }
.auth-confirm { text-align:center; }
.confirm-mail { width:58px; height:58px; display:grid; place-items:center; margin:0 auto 18px; border-radius:17px; color:#1f64ad; background:#e7f1fd; font-size:1.35rem; }
.auth-demo-note { margin:18px 0; padding:11px 12px; border-radius:10px; color:#755b26; background:#fff7e6; font-size:.63rem; line-height:1.5; }

/* Sales chart and copy controls */
.promo-grid .copy-card { position:relative; min-height:90px; display:flex; justify-content:space-between; gap:18px; align-items:center; padding:15px 17px; border:1px solid #cfdded; border-radius:15px; color:inherit; background:linear-gradient(135deg,#fff,#f5f9fe); text-align:left; cursor:pointer; transition:border-color .18s,transform .18s,box-shadow .18s; }
.promo-grid .copy-card:hover { border-color:#77a5da; box-shadow:0 9px 24px rgba(37,86,143,.09); transform:translateY(-1px); }
.promo-grid .copy-card:active { transform:scale(.995); }
.promo-grid .copy-card.copied { border-color:#54ad82; background:#f0fbf6; }
.promo-grid .copy-card:disabled { opacity:.68; cursor:not-allowed; transform:none; box-shadow:none; }
.promo-grid .copy-card:disabled em { color:var(--muted); }
.primary-button:disabled { opacity:.62; cursor:not-allowed; box-shadow:none; }
.copy-card small,.copy-card b,.copy-card p { display:block; }
.copy-card small { color:var(--muted); font-size:.62rem; }
.copy-card b { margin:7px 0 3px; font-size:.9rem; }
.copy-card p { margin:0; color:var(--muted); font-size:.63rem; }
.copy-card em { display:flex; gap:7px; align-items:center; color:#2465c3; font-size:.65rem; font-style:normal; font-weight:800; white-space:nowrap; }
.copy-card em i { width:26px; height:26px; display:grid; place-items:center; border-radius:8px; background:#e4effc; font-style:normal; }
.mini-chart-panel { padding-bottom:12px; }
.sales-chart-compact { min-height:150px; display:grid; grid-template-columns:repeat(var(--count,6),minmax(62px,1fr)); gap:12px; align-items:end; overflow-x:auto; padding:10px 8px 0; background:linear-gradient(to bottom,transparent 32%,#edf2f7 32.5%,transparent 33%,transparent 65%,#edf2f7 65.5%,transparent 66%); scrollbar-width:thin; }
.sales-month { position:relative; min-width:62px; height:132px; display:grid; grid-template-rows:18px 1fr 22px; place-items:end center; outline:0; cursor:default; }
.sales-month:after { content:attr(data-tooltip); position:absolute; z-index:3; top:23px; left:50%; width:max-content; max-width:150px; padding:7px 9px; border-radius:8px; color:#fff; background:rgba(27,25,23,.95); box-shadow:0 8px 20px rgba(34,25,20,.2); font-size:.57rem; font-weight:700; white-space:nowrap; opacity:0; pointer-events:none; transform:translate(-50%,-4px); transition:opacity .15s ease,transform .15s ease; }
.sales-month:hover:after,.sales-month:focus:after { opacity:1; transform:translate(-50%,0); }
.sales-month:first-child:after { left:0; transform:translate(0,-4px); }
.sales-month:first-child:hover:after,.sales-month:first-child:focus:after { transform:none; }
.sales-month:last-child:after { right:0; left:auto; transform:translate(0,-4px); }
.sales-month:last-child:hover:after,.sales-month:last-child:focus:after { transform:none; }
.sales-month .sales-value { color:#26354b; font-size:.62rem; font-weight:800; }
.sales-month i { width:min(52px,68%); height:var(--v); min-height:10px; align-self:end; border-radius:9px 9px 4px 4px; background:linear-gradient(180deg,#75afe7,#2767ae); box-shadow:inset 0 1px rgba(255,255,255,.35); animation:rise-bar .45s ease both; transform-origin:bottom; }
.sales-month.current i { background:linear-gradient(180deg,#f7c861,#efa21a); box-shadow:0 5px 14px rgba(239,162,26,.2); }
.sales-month b { align-self:end; color:#718097; font-size:.6rem; font-weight:600; text-align:center; }
.period-pills button { cursor:pointer; }
.currency-preview { display:flex; flex-direction:column; justify-content:center; padding:7px 10px; border-radius:9px; background:#eef5fd; }
.currency-preview small { color:#70819a; font-size:.57rem; }
.currency-preview b { margin-top:3px; color:#1e5c9e; font-size:.66rem; }
.form-grid select { width:100%; min-height:38px; margin-top:5px; padding:0 10px; border:1px solid #dce4ee; border-radius:9px; color:var(--ink); background:#fff; font:inherit; }
.member-country { padding:5px 8px; border-radius:8px; color:#426183; background:#edf4fb; font-size:.58rem; font-weight:800; white-space:nowrap; }
.access-member { grid-template-columns:auto minmax(180px,1fr) auto auto auto auto auto auto; }
.staff-action-list { display:grid; gap:9px; margin-top:18px; }
.staff-action-list button { display:flex; flex-direction:column; gap:4px; width:100%; padding:14px 16px; border:1px solid var(--line); border-radius:13px; color:var(--ink); background:#fff; font:inherit; text-align:left; cursor:pointer; }
.staff-action-list button:hover { border-color:#efad8e; background:#fff8f4; }
.staff-action-list button b { font-size:.74rem; }
.staff-action-list button small { color:var(--muted); font-size:.61rem; }
.staff-action-list button.danger { border-color:#f0ceca; color:#a73d34; background:#fff8f7; }
.staff-action-list button:disabled { opacity:.55; cursor:not-allowed; }
.permission-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; margin:12px 0 4px; padding:12px; border:1px solid var(--line); border-radius:12px; }
.permission-grid legend { padding:0 5px; color:var(--muted); font-size:.62rem; font-weight:800; }
.permission-grid label { min-height:42px; display:flex; align-items:center; gap:8px; padding:8px 10px; border-radius:9px; background:#f8f6f3; }
.permission-grid input { width:16px; min-height:16px; margin:0; }
.registration-panel { margin-bottom:14px; }
.registration-panel .data-table td { vertical-align:middle; }
.registration-panel .error-cell { color:#b44732; }

.team-donut>span { position:relative; border:0; background:conic-gradient(#2766ac 0 73%,#dbe9f8 73% 100%); transform:none; }
.team-donut>span:before { content:""; position:absolute; inset:10px; border-radius:50%; background:#fff; }
.team-donut>span b,.team-donut>span small { position:relative; z-index:1; line-height:1; }
.team-donut>span b { display:flex; align-items:baseline; gap:2px; font-size:1.35rem; }
.team-donut>span small { font-size:.58rem; }

/* Source-grounded partner materials catalog */
.materials-page-heading { margin-bottom:16px; }
.materials-page-heading h1 { margin:3px 0 5px; font-size:1.55rem; }
.materials-page-heading p:last-child { margin:0; color:var(--muted); font-size:.72rem; }
.material-summary { display:grid; grid-template-columns:120px 120px 1fr; gap:10px; align-items:stretch; margin-bottom:14px; }
.material-summary>div,.material-summary>p { min-height:65px; margin:0; padding:13px 15px; border:1px solid var(--line); border-radius:14px; background:#fff; }
.material-summary>div { display:flex; flex-direction:column; justify-content:center; }
.material-summary span { color:#215c9e; font-size:1.08rem; font-weight:800; }
.material-summary small { margin-top:2px; color:var(--muted); font-size:.6rem; }
.material-summary>p { display:flex; align-items:center; color:#66758a; background:linear-gradient(110deg,#f9fbfe,#f2f7fd); font-size:.65rem; line-height:1.5; }
.material-category-tabs { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:9px; margin-bottom:22px; }
.material-category-tabs button { min-height:52px; display:grid; grid-template-columns:30px 1fr auto; gap:8px; align-items:center; padding:8px 11px; border:1px solid var(--line); border-radius:13px; color:#536277; background:#fff; font:inherit; text-align:left; cursor:pointer; transition:.18s ease; }
.material-category-tabs button:hover { border-color:#91b4da; transform:translateY(-1px); }
.material-category-tabs button.active { border-color:#2766ac; color:#174f8c; background:#eef5fd; box-shadow:0 6px 18px rgba(39,102,172,.08); }
.material-category-tabs button>span { width:30px; height:30px; display:grid; place-items:center; border-radius:9px; color:#2867aa; background:#e5f0fc; font-size:.68rem; font-weight:800; }
.material-category-tabs b { overflow:hidden; font-size:.66rem; text-overflow:ellipsis; white-space:nowrap; }
.material-category-tabs em { min-width:21px; height:21px; display:grid; place-items:center; border-radius:99px; color:#77869a; background:#f0f3f7; font-size:.55rem; font-style:normal; font-weight:800; }
.material-catalog-head { display:flex; align-items:flex-end; justify-content:space-between; margin-bottom:11px; }
.material-catalog-head h2 { margin:3px 0 0; font-size:1rem; }
.material-catalog-head>small { color:var(--muted); font-size:.59rem; }
.material-sort { max-width:170px; min-height:36px; padding:0 28px 0 10px; border:1px solid var(--line); border-radius:9px; outline:0; color:var(--muted); background:var(--paper); font:inherit; font-size:.64rem; font-weight:700; cursor:pointer; }
.material-sort:focus { border-color:#e68b63; box-shadow:0 0 0 3px rgba(230,139,99,.12); }
.material-catalog-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.promo-material-card { min-height:150px; display:grid; grid-template-columns:128px 1fr; overflow:hidden; border:1px solid var(--line); border-radius:16px; background:#fff; box-shadow:0 8px 24px rgba(25,44,70,.035); }
.promo-material-visual { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:10px; color:#fff; background:linear-gradient(145deg,#173c6b,#3476bd); }
.promo-material-visual.video { background:linear-gradient(145deg,#1d506b,#3a97ac); }
.promo-material-visual.text { background:linear-gradient(145deg,#674a29,#d39a35); }
.promo-material-visual.faq { background:linear-gradient(145deg,#563c73,#8a68ad); }
.promo-material-visual>span { width:45px; height:45px; display:grid; place-items:center; border:1px solid rgba(255,255,255,.35); border-radius:14px; background:rgba(255,255,255,.12); font-size:1rem; font-weight:800; }
.promo-material-visual small { color:rgba(255,255,255,.78); font-size:.54rem; font-weight:700; text-transform:uppercase; }
.promo-material-body { display:flex; flex-direction:column; padding:15px 16px; }
.promo-material-meta { min-height:20px; display:flex; align-items:center; gap:7px; color:#8490a1; font-size:.56rem; }
.promo-material-meta mark { padding:3px 7px; border-radius:99px; color:#18754c; background:#e7f7ef; font-size:.52rem; font-weight:800; }
.promo-material-body h3 { margin:7px 0 5px; font-size:.78rem; line-height:1.35; }
.promo-material-body p { margin:0 0 12px; color:var(--muted); font-size:.62rem; line-height:1.45; }
.promo-material-body a { display:flex; align-items:center; justify-content:space-between; margin-top:auto; color:#2464aa; font-size:.61rem; font-weight:800; text-decoration:none; }
.promo-material-body a:hover { color:#113f73; }

/* RETASTE / Grandchef product-site palette */
.sidebar { color:#e8e2dc; background:#1b1917; }
.support-button>span:first-child { color:#1b1917; background:#ff833d; }
.brand small,.support-button small,.profile-mini small { color:#a99e94; }
.nav-item { color:#c6bdb5; }
.nav-item:hover,.nav-item.active { color:#fff; background:#302a25; }
.nav-item.active { box-shadow:inset 3px 0 #ff874d; }
.nav-icon { color:#ded6cf; }
.support-button { border-color:#493d34; color:#f4eee9; background:#28231f; }
.profile-mini { border-color:#443a33; }
.avatar,.table-avatar,.curator-question .table-avatar,.profile-avatar-large { background:linear-gradient(145deg,#ff8b55,#c85229); }
.profile-menu { border-color:#50443b; background:#28231f; }
.profile-menu button:hover,.profile-menu button:focus-visible { background:#3a3029; }
.topbar { border-bottom-color:#e6ded6; background:rgba(255,252,248,.95); }
.global-search { border-color:#ded5cc; background:#faf7f3; }
.global-search kbd { border-color:#ded5cc; color:#8b7e73; background:#fff; }
.workspace { color:#1b1917; }
.primary-button,.mode-switch,.table-action.primary { color:#fff; background:#f47742; box-shadow:0 8px 20px rgba(244,119,66,.2); }
.primary-button:hover,.mode-switch:hover,.table-action.primary:hover { background:#df6433; }
.text-button,.row-action,.promo-grid button,.auth-link,.promo-material-body a { color:#d95f2f; }
.promo-material-body a:hover { color:#a83d19; }
.eyebrow,.card-kicker { color:#8a7d72; }
.page-hero,.dark-card,.featured-news,.personal-ranking-card,.auth-brand-panel { background:linear-gradient(135deg,#171513 0%,#2c241f 65%,#574033 100%); box-shadow:0 14px 34px rgba(42,31,24,.16); }
.module-art { background:linear-gradient(145deg,#241d18,#6e4938); }
.answer-symbol.blue,.media-icon,.modal-label,.topic-pill,.blue-orb,.campaign-icon,.owner-role,.profile-card-icon.blue,.currency-preview,.member-country,.confirm-mail,.copy-card em i { color:#c65328; background:#fff0e8; }
.steps-list li.active,.category-link:hover,.category-link.active,.branch-banner,.quiz-option:hover,.quiz-option.selected,.chat-thread.active,.notification-list button:hover,.segments-panel button:hover { background:#fff2eb; }
.category-link:hover,.category-link.active,.module-item.active .module-number,.modal-label,.topic-pill,.install-app-button,.phone-label,.currency-preview b,.member-country { color:#b94a22; }
.filter-chip:hover,.filter-chip.active,.country-switcher button.active,.period-pills button.active { border-color:#e76c3a; color:#fff; background:#e76c3a; box-shadow:0 3px 9px rgba(180,72,31,.18); }
.install-app-button,body.admin-mode .mode-switch { border-color:#ead9cf; color:#9f421f; background:#fff4ee; }
.score-ring,.quality-score>span { border-color:#f6dfd3; border-top-color:#f47742; border-right-color:#f47742; color:#9d411f; }
.branch-bars i em,.region-bars i em,.distribution-list i em,.source-list i em,.mini-progress span,.tax-bars i em { background:linear-gradient(90deg,#ff9b66,#d95f2f); }
.blue-spark { stroke:#f47742; }
.legend-blue,.blue-dot { background:#f47742; }
.blue-dot { box-shadow:0 0 0 5px #fff0e8; }
.bar-chart>div,.partner-bars i,.sales-month i { background:linear-gradient(180deg,#ff9a63,#d85a2c); }
.turnover-line .line { stroke:#ff874d; }
.turnover-line circle { stroke:#ff874d; }
.turnover-line circle.current { fill:#ff874d; }
.chart-stats { border-color:#eadfd7; background:linear-gradient(90deg,#fff8f3,#fffdf9); }
.chart-stats p b,.funnel-list span,.attention-list em,.team-summary-card dd,.level-badge,.volume-bonus-card h2,.bonus-progress-head em { color:#bb4d24!important; }
.distribution-list button:hover,.attention-list button:hover { background:#fff3ed; }
.promo-code { border-color:#efd8ca; color:#ad4822; background:#fff8f4; }
.promo-code:hover { border-color:#ec9d78; background:#fff0e8; }
.chat-thread.active { box-shadow:inset 3px 0 #f47742; }
.chat-thread i,.chat-bubble.curator { background:#e36a37; }
.permission-panel input[type="checkbox"],.curator-toggle input,.schedule-row input { accent-color:#f47742; }
.payout-hero { background:#49372d; }
.payout-hero>div { background:#2b231e; }
.payout-hero>div:first-child { background:linear-gradient(135deg,#211b17,#6e4433); }
.auth-gate { color:#1b1917; background:#f5f2ee; }
.auth-tabs button.active { color:#9f421f; }
.auth-form input:focus,.auth-form select:focus,.ask-form input:focus,.ask-form select:focus,.ask-form textarea:focus { border-color:#f08a5c; box-shadow:0 0 0 3px rgba(244,119,66,.14); }
.auth-inspiration { width:min(560px,100%); margin-top:auto; padding:17px 19px; border:1px solid rgba(255,131,61,.28); border-radius:18px; background:rgba(255,255,255,.045); backdrop-filter:blur(8px); }
.auth-inspiration small { display:block; margin-bottom:8px; color:#ff9a68; font-size:.68rem; font-weight:800; text-transform:uppercase; letter-spacing:.12em; }
.auth-inspiration blockquote { min-height:54px; margin:0; color:#fff; font-size:1rem; font-weight:600; line-height:1.55; transition:opacity .25s ease,transform .25s ease; }
.auth-inspiration blockquote.changing { opacity:0; transform:translateY(5px); }
.auth-inspiration-dots { display:flex; gap:6px; margin-top:13px; }
.auth-inspiration-dots i { width:6px; height:6px; border-radius:99px; background:rgba(255,255,255,.25); transition:width .25s ease,background .25s ease; }
.auth-inspiration-dots i.active { width:22px; background:#ff874d; }
.auth-error { margin:0; padding:9px 11px; border:1px solid #f1b9ae; border-radius:10px; color:#9e3426; background:#fff0ed; font-size:.66rem; line-height:1.4; }
.copy-card em { color:#d95f2f; }
.team-donut>span { background:conic-gradient(#f47742 0 73%,#f4ddd2 73% 100%); }
.material-summary span { color:#c65328; }
.material-category-tabs button.active { border-color:#f47742; color:#ad4822; background:#fff2eb; box-shadow:0 6px 18px rgba(244,119,66,.09); }
.material-category-tabs button>span { color:#c65328; background:#ffe9de; }
.promo-material-visual,.promo-material-visual.video,.promo-material-visual.text,.promo-material-visual.faq { background:linear-gradient(145deg,#221c18,#714837); }

.sales-register-head { gap:12px; }
.personal-sales-tools { display:flex; align-items:center; justify-content:flex-end; gap:10px; }
.compact-add-button { min-height:36px; padding:0 16px; border-radius:10px; white-space:nowrap; font-size:.65rem; }
.compact-filters { display:flex; align-items:center; gap:8px; }
.compact-filters select { min-height:36px; padding:0 30px 0 11px; border:1px solid var(--line); border-radius:10px; color:var(--ink); background:#fff; font:inherit; font-size:.65rem; }
.personal-sales-table td:last-child,.personal-sales-table th:last-child { width:1%; text-align:right; }
.personal-sales-table td:nth-child(2) small { display:block; margin-top:3px; color:var(--muted); font-size:.58rem; }
.sale-status-note { display:flex; align-items:center; gap:10px; margin:10px 0 18px; padding:11px 13px; border:1px solid var(--line); border-radius:12px; color:var(--muted); background:var(--soft); font-size:.72rem; line-height:1.45; }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.table-pagination { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:11px 2px 0; color:var(--muted); font-size:.62rem; }
.table-pagination>div { display:flex; align-items:center; gap:8px; }
.table-pagination button { width:31px; height:31px; border:1px solid var(--line); border-radius:9px; color:#a14522; background:#fff8f4; cursor:pointer; }
.table-pagination button:hover { border-color:#ef9a73; background:#fff0e8; }
.table-pagination b { min-width:42px; text-align:center; color:var(--ink); }
.table-empty { padding:22px; text-align:center; color:var(--muted); }
.modal-form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.form-error { margin:0; padding:10px 12px; border:1px solid #f2c5bd; border-radius:10px; color:#a53b2b; background:#fff2ef; font-size:.65rem; }
.page-view[data-view="team"]>.admin-panel { margin-top:14px; }
.account-type-badge { display:inline-flex; align-items:center; width:max-content; padding:5px 8px; border-radius:8px; font-size:.58rem; font-weight:800; white-space:nowrap; }
.account-type-badge.partner { color:#18754c; background:#e7f7ef; }
.account-type-badge.employee { color:#a14522; background:#fff0e8; }
.account-type-badge.owner { color:#fff; background:linear-gradient(135deg,#df5c2d,#fb7a45); box-shadow:0 5px 14px rgba(223,92,45,.18); }
.owner-access-summary { margin:12px 0 4px; padding:14px 16px; border:1px solid #f0c8b5; border-radius:12px; color:#78381f; background:#fff4ed; }
.owner-access-summary b { display:block; margin-bottom:5px; font-size:.75rem; }
.owner-access-summary p { margin:0; color:#916049; font-size:.65rem; line-height:1.5; }
.staff-preset-field { padding:11px 12px; border:1px solid #f0d3c5; border-radius:12px; background:#fff8f4; }
.staff-preset-field small { display:block; margin-top:6px; color:#96705e; font-size:.58rem; line-height:1.45; }
.profile-completion-notice { display:flex; flex-direction:column; gap:4px; margin:14px 0; padding:12px 14px; border:1px solid #f1c7a9; border-radius:12px; color:#8f431f; background:#fff5ea; }
.profile-completion-notice b { font-size:.72rem; }
.profile-completion-notice span { color:#946d5a; font-size:.62rem; line-height:1.45; }
.profile-completion-notice.is-complete { border-color:#c9eadb; color:#18754c; background:#eefaf4; }
.profile-source-field { grid-column:1 / -1; }
.profile-source-field small { display:block; margin-top:6px; color:var(--muted); font-size:.58rem; line-height:1.45; }
.account-separation-note { display:grid; grid-template-columns:auto 1fr auto 1fr; align-items:center; gap:9px 12px; margin:0 0 14px; padding:12px 14px; border:1px solid #eadfd7; border-radius:14px; color:var(--muted); background:#fffaf6; font-size:.64rem; }
.account-separation-note p { margin:0; line-height:1.45; }
.account-type-note { display:flex; align-items:flex-start; flex-direction:column; gap:3px; padding:10px 12px; border:1px solid #eadfd7; border-radius:10px; color:var(--muted); background:#fffaf6; font-size:.64rem; }
.account-type-note b { color:var(--ink); }
.personal-ranking-card>div:first-child>small { display:block; margin-top:6px; color:rgba(255,255,255,.62); font-size:.58rem; }

@media (min-width:761px) {
  .sidebar { display:flex; flex-direction:column; }
  .side-nav { min-height:0; overflow-y:auto; scrollbar-width:none; }
  .side-nav::-webkit-scrollbar { display:none; }
  .sidebar-bottom { margin-top:auto; }
}

@media (max-width:760px) {
  .auth-locked { overflow-x:hidden; overflow-y:auto; overscroll-behavior-y:contain; }
  .auth-gate { display:block; min-height:var(--visual-viewport-height,100dvh); background:#f4f7fb; }
  .auth-brand-panel { display:none; }
  .auth-form-panel { width:100%; min-width:0; min-height:var(--visual-viewport-height,100dvh); overflow:visible; padding:18px 14px calc(18px + var(--keyboard-height,0px)); }
  .auth-card { width:100%; min-width:0; max-width:450px; margin:auto 0; padding:23px 18px; border-radius:20px; }
  .auth-tabs,.auth-pane,.auth-form,.auth-form label,.auth-form input,.auth-form select { min-width:0; }
  .auth-tabs button { min-width:0; overflow:hidden; text-overflow:ellipsis; }
  .keyboard-open .auth-form-panel { align-content:start; place-items:start center; }
  .keyboard-open .auth-card { margin:0; }
  .keyboard-open .auth-form { scroll-margin-block:18px; }
  .keyboard-open .auth-form input,.keyboard-open .auth-form select { scroll-margin-block:26vh; }
  .auth-mobile-brand { display:flex; }
  .side-nav { display:flex; gap:4px; overflow-x:auto; overscroll-behavior-x:contain; scroll-snap-type:x proximity; scrollbar-width:none; }
  .side-nav::-webkit-scrollbar { display:none; }
  .nav-item,.nav-item.active { width:84px; min-width:84px; max-width:84px; flex:0 0 84px; overflow:hidden; padding-inline:4px; font-size:.56rem; line-height:1.08; white-space:normal; text-wrap:balance; overflow-wrap:normal; scroll-snap-align:start; }
  .nav-item .nav-icon { flex:0 0 auto; }
  .partner-announcement { grid-template-columns:auto 1fr; }
  .partner-announcement .text-button { grid-column:2; justify-self:start; }
  .business-kpis { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .business-kpis article { min-height:82px; padding:12px; }
  .business-kpis b { font-size:.94rem; }
  .partner-business-strip { grid-template-columns:1fr; }
  .personal-ranking-card { align-items:flex-start; flex-direction:column; gap:14px; }
  .ranking-summary { width:100%; min-width:0; padding:13px 0 0; border-top:1px solid rgba(255,255,255,.18); border-left:0; }
  .performance-main-grid,.performance-detail-grid { grid-template-columns:1fr; }
  .level-roadmap { grid-template-columns:repeat(2,1fr); row-gap:14px; }
  .compact-page-heading { align-items:flex-start; flex-direction:column; }
  .promo-grid,.two-column-panels,.profile-form-grid,.application-grid,.payout-hero { grid-template-columns:1fr; }
  .profile-top-grid,.profile-history-grid,.profile-finance-grid { grid-template-columns:1fr; }
  .purchase-edit-grid { grid-template-columns:1fr; }
  .purchase-order-field { grid-column:auto; }
  .security-card { align-items:flex-start; flex-direction:column; }
  .promo-grid article { padding-right:92px; }
  .promo-grid .copy-card { min-height:96px; padding:14px; }
  .copy-card em { font-size:0; }
  .copy-card em i { font-size:.78rem; }
  .draft-note { align-items:flex-start; flex-direction:column; }
  .period-pills { max-width:100%; overflow-x:auto; }
  .mini-chart-panel .panel-head { align-items:flex-start; flex-direction:column; gap:10px; }
  .mini-chart-panel .period-pills { width:100%; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); overflow:visible; }
  .mini-chart-panel .period-pills button { padding:0 4px; font-size:.56rem; }
  .partner-bars { gap:6%; padding-inline:3%; }
  .partner-bars i { width:11%; }
  .team-donut { justify-content:flex-start; }
  .material-summary { grid-template-columns:repeat(2,1fr); }
  .material-summary>p { grid-column:1 / -1; min-height:auto; }
  .material-category-tabs { display:flex; overflow-x:auto; padding-bottom:3px; scrollbar-width:none; }
  .material-category-tabs::-webkit-scrollbar { display:none; }
  .material-category-tabs button { min-width:150px; flex:0 0 150px; }
  .material-catalog-grid { grid-template-columns:1fr; }
  .promo-material-card { grid-template-columns:96px 1fr; }
  .form-grid,.payout-split { grid-template-columns:1fr; }
  .accountant-view .admin-heading,.admin-view .admin-heading { align-items:flex-start; }
  .access-member { grid-template-columns:auto 1fr auto; }
  .access-member .member-country { grid-column:2; justify-self:start; }
  .access-member .account-type-badge { grid-column:2; justify-self:start; }
  .access-member .status-pill { grid-column:2; justify-self:start; }
  .access-member .owner-role-lock { grid-column:2; justify-self:start; }
  .permission-grid { grid-template-columns:1fr; }
  .sales-register-head { align-items:stretch; flex-direction:column; }
  .personal-sales-tools { align-items:stretch; flex-direction:column; }
  .compact-add-button { width:100%; }
  .compact-filters { display:grid; grid-template-columns:1fr; }
  .compact-filters select { width:100%; }
  .personal-sale-edit { width:36px; min-width:36px; padding:0; }
  .personal-sale-edit span { font-size:.85rem; }
  .personal-sale-edit span + * { display:none; }
  .personal-sales-table .personal-sale-edit { font-size:0; }
  .sale-status-note { align-items:flex-start; flex-direction:column; }
  .generated-password-field { grid-template-columns:minmax(0,1fr) 42px; }
  .generated-password-field input { grid-column:1 / -1; }
  .generate-password-button { width:100%; }
  .modal-form-grid { grid-template-columns:1fr; }
  .account-separation-note { grid-template-columns:auto 1fr; }
}

/* v28: denser workspace, themes and richer partner controls */
.role-hidden { display:none!important; }
.theme-toggle,.language-toggle { min-height:40px; display:inline-flex; align-items:center; justify-content:center; gap:7px; padding:0 12px; border:1px solid #ead9cf; border-radius:11px; color:#9f421f; background:#fff8f4; font-size:.66rem; font-weight:800; white-space:nowrap; cursor:pointer; }
.theme-toggle span { font-size:.9rem; }
.language-toggle { gap:5px; padding-inline:10px; color:#7b6e64; }
.language-toggle span { opacity:.52; }
.language-toggle span.active { color:#c65328; opacity:1; }
.language-toggle i { color:#c8bdb5; font-style:normal; }
.workspace { width:min(1680px,100%); padding:26px 28px 40px; }
.app-shell { grid-template-columns:240px 1fr; }
.sidebar { padding:18px 14px 14px; }
.brand { padding-bottom:18px; }
.side-nav { gap:4px; }
.nav-item { min-height:41px; padding-inline:11px; }
.topbar { min-height:64px; gap:12px; padding:0 24px; }
.welcome-row,.admin-heading,.compact-page-heading { margin-bottom:18px; }
.welcome-row h1,.admin-heading h1,.compact-page-heading h1 { font-size:clamp(1.55rem,2.2vw,2rem); }
.lead { font-size:.82rem; }
.workspace .admin-panel { padding:16px 18px; border-radius:16px; }
.panel-head { margin-bottom:12px; }
.panel-head h2 { font-size:.96rem; }
.kpi-grid,.business-kpis { gap:10px; }
.kpi-grid article,.business-kpis article { min-height:92px; padding:14px 16px; }
.insight-grid,.admin-grid-main,.admin-grid-bottom,.admin-distribution-grid,.two-column-panels { gap:12px; }
.data-table th { padding:11px 13px; }
.data-table td { padding:12px 13px; }
.orders-editor-table th,.orders-editor-table td { padding-block:9px; }
.compact-referrals-table th { padding:7px 11px; line-height:1.2; }
.compact-referrals-table td { padding:6px 11px; line-height:1.2; }
.compact-referrals-table .table-action { min-height:26px; padding-inline:8px; border-radius:7px; }
.orders-editor-table .inline-order-input,.orders-editor-table .inline-order-select { min-height:34px; padding-block:6px; }
.order-partner-link { display:block; max-width:190px; overflow:hidden; border:0; padding:0; color:#a84723; background:none; font:inherit; font-weight:800; text-align:left; text-overflow:ellipsis; white-space:nowrap; cursor:pointer; }
.order-partner-link:hover { text-decoration:underline; }
.calculated-order-reward { min-width:105px; }
.calculated-order-reward small { display:block; margin-top:2px; color:var(--muted); font-size:.5rem; white-space:nowrap; }
.compact-referrals-table td:first-child small { display:block; max-width:220px; overflow:hidden; margin-top:2px; text-overflow:ellipsis; white-space:nowrap; }
.compact-referrals-table th:nth-child(4),.compact-referrals-table td:nth-child(4) { width:48px; text-align:center; }
.referral-assignee { width:100%; min-height:28px; overflow:hidden; border:1px solid var(--line); border-radius:8px; padding:4px 8px; color:#66758a; background:#fff; font:inherit; font-size:.6rem; font-weight:800; line-height:1.15; text-align:left; text-overflow:ellipsis; white-space:nowrap; cursor:pointer; }
.referral-assignee.assigned { border-color:#b9e5d1; color:#16734b; background:#effaf5; }
.assignment-check { display:inline-grid; place-items:center; }
.assignment-check input { position:absolute; opacity:0; }
.assignment-check span { width:18px; height:18px; display:grid; place-items:center; border:1px solid #d5dbe3; border-radius:6px; background:#f5f7fa; }
.assignment-check input:checked + span { border-color:#2aa06b; color:#fff; background:#2aa06b; }
.assignment-check input:checked + span:after { content:'✓'; font-size:.7rem; font-weight:900; }
.import-batch-list { display:grid; gap:7px; margin:0 0 10px; }
.import-batch-list>div { display:flex; align-items:center; gap:10px; padding:9px 12px; border:1px solid var(--line); border-radius:11px; background:#fff; }
.import-batch-list>div>span { width:28px; height:28px; display:grid; place-items:center; border-radius:8px; color:#b44e27; background:#fff0e8; }
.import-batch-list p { min-width:0; flex:1; margin:0; }
.import-batch-list b,.import-batch-list small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.import-batch-list b { font-size:.64rem; }.import-batch-list small { margin-top:2px; color:var(--muted); font-size:.54rem; }
.modal-card:has(.partner-import-preview) { width:min(880px,100%); }
.partner-import-summary { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; margin:18px 0; }
.partner-import-summary>div { display:flex; flex-direction:column; gap:3px; padding:14px 16px; border:1px solid #dbe2eb; border-radius:13px; background:#f7f9fc; }
.partner-import-summary b { color:#263247; font-size:1.25rem; }
.partner-import-summary small { color:#758197; font-size:.65rem; }
.partner-import-summary .success { border-color:#ccebdc; background:#effaf5; }
.partner-import-summary .success b { color:#167553; }
.partner-import-summary .warning { border-color:#f3dfae; background:#fff8e8; }
.partner-import-summary .warning b { color:#9b6812; }
.partner-import-preview { max-width:100%; margin:14px 0; overflow:auto; border:1px solid #e4ddd6; border-radius:13px; }
.partner-import-preview table { width:100%; min-width:650px; border-collapse:collapse; font-size:.7rem; }
.partner-import-preview th,.partner-import-preview td { padding:10px 12px; border-bottom:1px solid #eee7e1; text-align:left; }
.partner-import-preview th { color:#758197; background:#f7f8fa; font-size:.59rem; letter-spacing:.04em; text-transform:uppercase; }
.partner-import-errors { margin:14px 0; padding:13px 15px; border:1px solid #f0c7c2; border-radius:13px; color:#8c3f38; background:#fff4f2; font-size:.7rem; }
.partner-import-errors ul { display:grid; gap:5px; margin:9px 0 0; padding-left:18px; }
.partner-import-errors small { color:#9a736f; }
.import-warning { padding:10px 12px; border-radius:10px; color:#8c6111!important; background:#fff4dc; }
.referral-picker-description { max-width:590px; margin:8px 0 18px!important; line-height:1.55!important; }
.referral-search-box { position:relative; display:flex; align-items:center; width:100%; height:48px; box-sizing:border-box; border:1px solid #d8dfe8; border-radius:14px; color:#8290a3; background:#f8fafc; transition:border-color .18s ease,box-shadow .18s ease,background .18s ease; }
.referral-search-box:focus-within { border-color:#ef8354; background:#fff; box-shadow:0 0 0 4px rgba(239,112,59,.12); }
.referral-search-box .ui-icon { width:19px; height:19px; flex:0 0 19px; margin-left:15px; stroke-width:1.8; }
.referral-search-box input { width:100%; height:100%; min-width:0; padding:0 15px 0 11px; border:0; outline:0; color:#273246; background:transparent; font:600 .78rem/1.2 var(--font-body); }
.referral-search-box input::placeholder { color:#919cad; font-weight:500; opacity:1; }
.referral-search-box input::-webkit-search-cancel-button { cursor:pointer; }
.partner-picker-caption { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:17px 2px 8px; color:#737f91; font-size:.6rem; font-weight:800; letter-spacing:.055em; text-transform:uppercase; }
.partner-picker-caption small { display:grid; min-width:25px; height:25px; place-items:center; padding:0 7px; border-radius:999px; color:#b84d26; background:#fff0e8; font-size:.57rem; letter-spacing:0; }
.partner-picker-list { max-height:310px; display:grid; gap:7px; overflow:auto; margin:0 -3px 13px; padding:3px; scrollbar-width:thin; }
.partner-picker-list button { display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:12px; min-height:62px; padding:9px 11px; border:1px solid #e2e6ec; border-radius:14px; color:var(--ink); background:#fff; font:inherit; text-align:left; cursor:pointer; transition:border-color .18s ease,box-shadow .18s ease,transform .18s ease,background .18s ease; }
.partner-picker-list button:hover { border-color:#f09a73; background:#fffaf7; box-shadow:0 7px 18px rgba(63,42,31,.07); transform:translateY(-1px); }
.partner-picker-list button:focus-visible { outline:0; border-color:#ef8354; box-shadow:0 0 0 3px rgba(239,112,59,.14); }
.partner-picker-list .table-avatar { width:40px; height:40px; border-radius:12px; box-shadow:none; font-size:.68rem; }
.partner-picker-identity { min-width:0; }
.partner-picker-identity b,.partner-picker-identity small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.partner-picker-identity b { font-size:.74rem; }
.partner-picker-identity small { margin-top:4px; color:var(--muted); font-size:.58rem; }
.partner-picker-identity small i:after { content:'•'; margin:0 7px; color:#c2c9d2; font-style:normal; }
.partner-picker-action { display:flex; align-items:center; gap:7px; color:#c65328; font-size:.6rem; font-weight:800; }
.partner-picker-action>b { display:grid; width:24px; height:24px; place-items:center; border-radius:8px; color:#c65328; background:#fff0e8; font-size:.78rem; transition:transform .18s ease; }
.partner-picker-list button:hover .partner-picker-action>b { transform:translateX(2px); }
.partner-picker-empty { display:grid; justify-items:center; gap:5px; padding:27px 16px; border:1px dashed #d9dfe7; border-radius:14px; color:#758197; background:#fafbfc; text-align:center; }
.partner-picker-empty>span { display:grid; width:34px; height:34px; place-items:center; border-radius:11px; color:#c65328; background:#fff0e8; font-size:1rem; }
.partner-picker-empty b { color:#374154; font-size:.72rem; }
.partner-picker-empty small { font-size:.59rem; }
.referral-unassign-button { width:100%; margin-top:2px; }
.partner-insight-meta { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; margin:12px 0; }
.partner-insight-meta p { min-width:0; margin:0; padding:10px; border-radius:10px; background:var(--soft); }
.partner-insight-meta b,.partner-insight-meta small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.partner-insight-meta small { margin-top:3px; color:var(--muted); font-size:.54rem; }
.partner-order-chart { height:120px; display:flex; align-items:flex-end; gap:8px; padding:12px; border:1px solid var(--line); border-radius:12px; }
.partner-order-chart>div { height:100%; min-width:0; flex:1; display:flex; flex-direction:column; align-items:center; justify-content:flex-end; gap:3px; }
.partner-order-chart span { width:70%; min-height:4px; border-radius:5px 5px 2px 2px; background:linear-gradient(#ff9a63,#d85a2c); }.partner-order-chart b { font-size:.55rem; }.partner-order-chart small { color:var(--muted); font-size:.5rem; }
.compact-order-history { display:grid; gap:5px; margin-top:10px; }.compact-order-history button { display:grid; grid-template-columns:100px 1fr auto; gap:8px; border:0; border-radius:9px; padding:8px 10px; color:var(--ink); background:var(--soft); font:inherit; text-align:left; cursor:pointer; }.compact-order-history span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.compact-order-history em { font-style:normal; font-weight:800; }
.order-attachments { display:flex; flex-wrap:wrap; gap:6px; }.bonus-equipment-kpis { margin-top:14px; }
.order-summary div { padding:13px 15px; }
.support-chat { min-height:330px; }
.promo-grid { position:relative; z-index:1; gap:12px; margin-bottom:12px; }
.promo-grid .copy-card { position:relative; inset:auto; z-index:1; width:100%; min-width:0; min-height:78px; overflow:hidden; box-sizing:border-box; padding:12px 15px; border-color:#ead9cf; background:#fffaf7; transform:none!important; }
.promo-grid .copy-card:hover { z-index:2; border-color:#ef9c76; box-shadow:0 7px 18px rgba(90,54,35,.08); }
.promo-grid .copy-card.copied { border-color:#43a878; background:#effaf4; box-shadow:inset 0 0 0 1px #43a878; }
.copy-card b { margin:4px 0 2px; }
.mini-chart-panel { position:relative; overflow:hidden; padding-bottom:10px!important; background:linear-gradient(145deg,#fff 0%,#fff 62%,#fff8f3 100%); }
.mini-chart-panel:after { content:""; position:absolute; right:-90px; bottom:-110px; width:250px; height:250px; border-radius:50%; background:radial-gradient(circle,rgba(255,120,68,.09),transparent 68%); pointer-events:none; }
.sales-chart-compact { position:relative; isolation:isolate; min-height:150px; grid-template-columns:repeat(var(--count,6),minmax(0,1fr)); gap:clamp(4px,1vw,12px); overflow:visible; padding:13px 5px 0; border-radius:14px; background:linear-gradient(to bottom,transparent 25%,rgba(180,163,151,.18) 25.5%,transparent 26%,transparent 54%,rgba(180,163,151,.16) 54.5%,transparent 55%,transparent 82%,rgba(180,163,151,.14) 82.5%,transparent 83%); }
.chart-empty-state { grid-column:1 / -1; align-self:stretch; display:flex; align-items:center; justify-content:center; gap:12px; min-height:132px; padding:18px; border:1px dashed #ddd4cd; border-radius:14px; color:var(--ink); background:rgba(255,255,255,.72); text-align:left; }
.chart-empty-state > span { width:38px; height:38px; flex:0 0 auto; display:grid; place-items:center; border-radius:12px; color:#b84a24; background:#fff0e9; font-size:1.05rem; font-weight:900; }
.chart-empty-state b,.chart-empty-state small { display:block; }
.chart-empty-state b { font-size:.75rem; }
.chart-empty-state small { margin-top:4px; color:var(--muted); font-size:.62rem; }
.modern-sales-trend { position:absolute; z-index:-1; top:18px; bottom:25px; left:7px; width:max(calc(100% - 14px),calc(var(--count) * 48px - 14px)); height:calc(100% - 43px); overflow:visible; pointer-events:none; }
.modern-sales-area { filter:drop-shadow(0 9px 14px rgba(217,95,47,.08)); }
.modern-sales-line { fill:none; stroke:#ef6937; stroke-width:3; stroke-linecap:round; stroke-linejoin:round; vector-effect:non-scaling-stroke; filter:drop-shadow(0 4px 5px rgba(217,95,47,.22)); }
.sales-month { z-index:1; min-width:0; height:132px; grid-template-rows:23px 1fr 24px; }
.sales-month .sales-value { min-width:27px; padding:3px 7px; border:1px solid #f2dfd4; border-radius:99px; color:#7f4430; background:rgba(255,255,255,.92); box-shadow:0 5px 13px rgba(83,52,38,.08); text-align:center; }
.sales-month i { width:min(34px,42%); border:1px solid rgba(255,255,255,.72); border-radius:10px 10px 5px 5px; background:linear-gradient(180deg,rgba(255,144,91,.72),rgba(222,82,34,.48)); box-shadow:0 8px 18px rgba(217,95,47,.12),inset 0 1px rgba(255,255,255,.55); backdrop-filter:blur(2px); }
.sales-month.current i { background:linear-gradient(180deg,#ffc85f,#f2a20e); box-shadow:0 8px 20px rgba(239,162,26,.24),inset 0 1px rgba(255,255,255,.55); }
.sales-month.current .sales-value { border-color:#f3c76d; color:#9b5b00; background:#fff8e7; }
.sales-month b { width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.sales-month:after { top:19px; }
.table-pagination { padding-top:8px; }
.leaderboard-actions { display:flex; align-items:center; gap:12px; }
.ranking-country-switcher button { min-height:28px; padding-inline:9px; font-size:.58rem; }
.level-editor-table .level-col { width:23%; }.level-editor-table .threshold-col { width:13%; }.level-editor-table .rate-col { width:15%; }.level-editor-table .reward-col { width:25%; }.level-editor-table .count-col { width:9%; }
.level-editor-table td:nth-child(5) { white-space:nowrap; }
.level-name { display:flex; align-items:center; gap:13px; color:var(--ink); }
.level-rank { position:relative; z-index:0; width:34px; height:34px; display:grid; place-items:center; flex:0 0 auto; border:1px solid #ded7d1; border-radius:50%; color:#6f6259; background:linear-gradient(145deg,#fff,#ece7e3); box-shadow:0 4px 10px rgba(43,33,27,.08); font-size:.7rem; font-style:normal; font-weight:900; }
.level-rank span { position:relative; z-index:1; }
.level-rank:before { content:""; position:absolute; top:5px; left:7px; width:7px; height:4px; border-radius:50%; background:rgba(255,255,255,.72); transform:rotate(-28deg); }
.level-rank:after { content:""; position:absolute; right:4px; bottom:-5px; left:4px; height:10px; z-index:0; background:#9b8e85; clip-path:polygon(0 0,100% 0,82% 100%,50% 65%,18% 100%); }
.level-rank.rank-1 { border-color:#ffbd38; color:#5d3900; background:linear-gradient(145deg,#fff3a7 0%,#ffc33c 55%,#e79712 100%); box-shadow:0 5px 15px rgba(224,151,18,.28); }
.level-rank.rank-1:after { background:#df9512; }
.level-rank.rank-2 { border-color:#c6ccd4; color:#44505f; background:linear-gradient(145deg,#fff 0%,#dce2e9 58%,#aeb7c2 100%); box-shadow:0 5px 15px rgba(99,113,130,.2); }
.level-rank.rank-2:after { background:#9ca7b5; }
.level-rank.rank-3 { border-color:#d39464; color:#fff8f1; background:linear-gradient(145deg,#e8b083 0%,#bd6d38 58%,#8d4526 100%); box-shadow:0 5px 15px rgba(155,77,35,.22); }
.level-rank.rank-3:after { background:#9f542d; }
.level-editable { min-width:0; display:inline-flex; align-items:center; gap:7px; }
.level-editable b { min-width:0; color:inherit; font-size:inherit; font-weight:700; }
.cell-edit { width:26px; height:26px; display:grid; place-items:center; flex:0 0 auto; padding:0; border:1px solid #e5d8cf; border-radius:8px; color:#c95629; background:#fff8f4; cursor:pointer; font-size:.66rem; transition:background .16s ease,border-color .16s ease,transform .16s ease; }
.cell-edit:hover,.cell-edit:focus-visible { border-color:#ff9d70; color:#a83c17; background:#ffebe1; outline:none; transform:translateY(-1px); }
.calculated-value { display:inline-flex; align-items:center; gap:6px; font-weight:700; }
.calculated-value small { padding:3px 6px; border-radius:999px; color:#7c7169; background:#f1eeeb; font-size:.48rem; font-weight:700; text-transform:uppercase; }
.permission-checks { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; margin:0; padding:12px; border:1px solid var(--line); border-radius:11px; }
.permission-checks legend { padding:0 5px; color:var(--muted); font-size:.64rem; font-weight:800; }
.permission-checks label { display:flex; grid-template-columns:auto 1fr; align-items:center; gap:7px; min-height:34px; padding:7px 9px; border-radius:8px; background:#f7f4f1; }
.permission-checks input { width:16px; height:16px; accent-color:#f47742; }
.modal-card:has(.partner-card-header) { width:min(900px,100%); max-height:calc(100vh - 32px); overflow:auto; }
.partner-card-header { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; }
.partner-card-header h2 { margin:9px 0 8px; }
.partner-tags { display:flex; flex-wrap:wrap; align-items:center; gap:7px; color:var(--muted); font-size:.63rem; }
.partner-status { margin-top:5px; }
.partner-contact-grid { display:grid; grid-template-columns:1.35fr 1.25fr .8fr; gap:9px; margin:15px 0 10px; }
.partner-contact-grid>div,.partner-detail-grid>div { min-width:0; padding:11px 12px; border-radius:11px; background:#f6f4f2; }
.partner-contact-grid small,.partner-contact-grid b,.partner-detail-grid small,.partner-detail-grid b { display:block; }
.partner-contact-grid small,.partner-detail-grid small { color:var(--muted); font-size:.57rem; }
.partner-contact-grid b,.partner-detail-grid b { margin-top:4px; overflow-wrap:anywhere; font-size:.66rem; }
.partner-contact-grid a { display:block; margin-top:4px; color:#c95225; font-size:.66rem; font-weight:800; overflow-wrap:anywhere; text-decoration:none; }
.partner-contact-grid a:hover { text-decoration:underline; }
.partner-detail-grid { grid-template-columns:repeat(4,minmax(0,1fr)); gap:9px; margin:0 0 10px; }
.partner-trend-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:9px; margin:10px 0; }
.partner-trend-grid>div { min-width:0; padding:12px; border:1px solid #eee2da; border-radius:12px; background:#fffaf7; }
.partner-trend-grid small,.partner-trend-grid b,.partner-trend-grid em { display:block; }
.partner-trend-grid small { color:var(--muted); font-size:.55rem; }
.partner-trend-grid b { margin-top:5px; color:var(--ink); font-size:.86rem; }
.partner-trend-grid em { margin-top:3px; color:var(--muted); font-size:.51rem; font-style:normal; }
.partner-trend-grid .positive b { color:#188158; }
.partner-trend-grid .negative b { color:#c4493e; }
.partner-trend-grid .neutral b { color:#7d716a; }
.partner-modal-section { margin-top:10px; padding:12px; border:1px solid var(--line); border-radius:13px; }
.partner-section-head { display:flex; align-items:flex-end; justify-content:space-between; gap:12px; margin-bottom:10px; }
.partner-section-head small,.partner-section-head b { display:block; }
.partner-section-head small { color:var(--muted); font-size:.56rem; text-transform:uppercase; letter-spacing:.08em; }
.partner-section-head b { margin-top:3px; font-size:.75rem; }
.partner-section-head>span { color:var(--muted); font-size:.58rem; }
.partner-mini-chart { height:92px; display:grid; grid-template-columns:repeat(6,1fr); gap:8px; align-items:end; padding-top:3px; background:linear-gradient(to bottom,transparent 49%,var(--line) 50%,transparent 51%); }
.partner-mini-chart>div { position:relative; height:86px; display:grid; grid-template-rows:14px 1fr 17px; align-items:end; justify-items:center; outline:0; }
.partner-mini-chart span,.partner-mini-chart b { font-size:.54rem; }
.partner-mini-chart b { color:var(--muted); }
.partner-mini-chart i { width:min(28px,65%); height:var(--v); min-height:8px; border-radius:6px 6px 2px 2px; background:linear-gradient(180deg,#ff9d6c,#d95f2f); }
.partner-mini-chart>div:after { content:attr(data-tooltip); position:absolute; z-index:5; top:15px; left:50%; width:max-content; padding:5px 7px; border-radius:7px; color:#fff; background:#1b1917; font-size:.54rem; opacity:0; transform:translate(-50%,-3px); pointer-events:none; }
.partner-mini-chart>div:hover:after,.partner-mini-chart>div:focus:after { opacity:1; transform:translate(-50%,0); }
.partner-line-chart { min-height:180px; padding:4px 2px 0; }
.partner-line-chart svg { width:100%; height:auto; overflow:visible; }
.partner-line-chart .chart-grid-line { fill:none; stroke:#eadfd8; stroke-width:1; }
.partner-line-chart .chart-area { fill:url(#partner-chart-area); }
.partner-line-chart .chart-line { fill:none; stroke:#f47742; stroke-width:4; stroke-linecap:round; stroke-linejoin:round; }
.partner-line-chart circle { fill:#fff; stroke:#f47742; stroke-width:4; }
.partner-line-chart text { fill:var(--muted); font-size:10px; font-weight:700; text-anchor:middle; }
.partner-line-chart .chart-value { fill:var(--ink); font-size:11px; }
.partner-chart-empty { min-height:155px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:5px; border:1px dashed #ead8ce; border-radius:12px; background:#fffcfa; text-align:center; }
.partner-chart-empty>span { width:36px; height:36px; display:grid; place-items:center; border-radius:11px; color:#cf5628; background:#fff0e8; font-size:1rem; }
.partner-chart-empty b { font-size:.68rem; }
.partner-chart-empty small { color:var(--muted); font-size:.55rem; }
.partner-management-row { display:grid; grid-template-columns:minmax(220px,.8fr) minmax(0,1.2fr); gap:10px; align-items:end; }
.partner-curator-control { display:grid; gap:6px; color:var(--muted); font-size:.58rem; font-weight:800; }
.partner-curator-control select { min-height:42px; padding:0 11px; border:1px solid #e1d6cf; border-radius:10px; color:var(--ink); background:#fff; font-family:inherit; font-size:.63rem; font-weight:700; }
.partner-curator-empty,.partner-links-empty { padding:10px; border-radius:10px; color:var(--muted); background:#f6f4f2; font-size:.58rem; }
.partner-curator-empty small,.partner-curator-empty b { display:block; }
.partner-curator-empty b { margin-top:4px; color:var(--ink); font-size:.61rem; }
.partner-bulk-bar { display:flex; align-items:center; gap:10px; margin:0 0 10px; padding:10px 12px; border:1px solid #efd5c7; border-radius:12px; background:#fff7f2; }
.partner-bulk-bar b { margin-right:auto; font-size:.66rem; }
.partner-bulk-bar select { min-height:38px; padding:0 10px; border:1px solid #e4d8d0; border-radius:9px; background:#fff; font-size:.62rem; }
.partner-bulk-bar .secondary-button { min-height:38px; padding:0 13px; }
.partners-register-table .partner-row-check,.partners-register-table thead input { width:16px; height:16px; accent-color:#f47742; cursor:pointer; }
.partners-register-table tr.is-selected td { background:#fff8f3; }
.partners-register-table tr.is-highlighted td { animation:partner-row-highlight 1.8s ease; }
@keyframes partner-row-highlight { 0%,100% { background:transparent; } 20%,70% { background:#fff0e7; } }
.partner-name-link { display:flex; align-items:center; gap:9px; padding:0; border:0; color:inherit; background:transparent; text-align:left; cursor:pointer; }
.partner-name-link span:last-child,.partner-name-link b,.partner-name-link small { display:block; }
.partner-name-link b { color:#b84921; }
.partner-name-link small { margin-top:2px; color:var(--muted); font-size:.55rem; white-space:nowrap; }
.partner-name-link:hover b,.partner-name-link:focus-visible b { text-decoration:underline; }
.partner-contact-link { display:block; max-width:175px; color:#b84921; text-decoration:none; }
.partner-contact-link b,.partner-contact-link small { display:block; }
.partner-contact-link b { font-size:.62rem; }
.partner-contact-link small { margin-top:2px; overflow:hidden; color:var(--muted); font-size:.53rem; text-overflow:ellipsis; white-space:nowrap; }
.contact-missing { color:var(--muted); font-size:.58rem; }
.partner-link-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
.partner-link-grid button { min-width:0; display:flex; align-items:center; justify-content:space-between; gap:8px; padding:10px; border:1px solid #ead9cf; border-radius:10px; color:var(--ink); background:#fffaf7; text-align:left; cursor:pointer; }
.partner-link-grid span,.partner-link-grid small,.partner-link-grid b { min-width:0; display:block; }
.partner-link-grid small { color:var(--muted); font-size:.53rem; }
.partner-link-grid b { margin-top:3px; overflow:hidden; font-size:.59rem; text-overflow:ellipsis; white-space:nowrap; }
.partner-link-grid em { color:#d95f2f; font-style:normal; }

html[data-theme="dark"] { --ink:#f6eee8; --muted:#b8aaa0; --line:#4b3c33; --paper:#29231f; --surface:#171513; --night:#11100f; }
html[data-theme="dark"] body,html[data-theme="dark"] .workspace { color:var(--ink); background:#171513; }
html[data-theme="dark"] .topbar { border-color:#43362e; background:rgba(30,26,23,.96); }
html[data-theme="dark"] .global-search,html[data-theme="dark"] .theme-toggle,html[data-theme="dark"] .language-toggle,html[data-theme="dark"] .install-app-button,html[data-theme="dark"] body.admin-mode .mode-switch { border-color:#57463b; color:#f3c0aa; background:#29231f; }
html[data-theme="dark"] .fx-topbar { border-color:#654737; color:#ffc0a2; background:#382820; }
html[data-theme="dark"] .fx-topbar small { color:#baa99e; }
html[data-theme="dark"] .global-search input { color:#f7f0ea; }
html[data-theme="dark"] .global-search input::placeholder { color:#8f8177; }
html[data-theme="dark"] .admin-panel,html[data-theme="dark"] .business-kpis article,html[data-theme="dark"] .kpi-grid article,html[data-theme="dark"] .data-table-wrap,html[data-theme="dark"] .order-summary div,html[data-theme="dark"] .answer-card,html[data-theme="dark"] .promo-material-card,html[data-theme="dark"] .material-summary>div,html[data-theme="dark"] .material-summary>p { border-color:#493c33; background:#29231f; box-shadow:none; }
html[data-theme="dark"] .partner-announcement,html[data-theme="dark"] .performance-card,html[data-theme="dark"] .continue-card,html[data-theme="dark"] .status-card,html[data-theme="dark"] .category-panel,html[data-theme="dark"] .knowledge-card,html[data-theme="dark"] .module-item,html[data-theme="dark"] .aside-card,html[data-theme="dark"] .media-summary>div,html[data-theme="dark"] .media-card,html[data-theme="dark"] .news-list article,html[data-theme="dark"] .partner-business-strip>div { border-color:#493c33; color:#f6eee8; background:#29231f; box-shadow:none; }
html[data-theme="dark"] .partner-announcement { background:linear-gradient(90deg,#35291f,#2a231e); }
html[data-theme="dark"] .performance-card p,html[data-theme="dark"] .performance-card span,html[data-theme="dark"] .performance-card small,html[data-theme="dark"] .partner-announcement p { color:#b8aaa0; }
html[data-theme="dark"] .level-roadmap i { border-color:#5b4b40; color:#c7b9af; background:#211d1a; }
html[data-theme="dark"] .team-donut>span:before { background:#29231f; }
html[data-theme="dark"] .data-table th { border-color:#4b3c33; color:#b4a69c; background:#211d1a; }
html[data-theme="dark"] .data-table td { border-color:#43372f; color:#d6cac1; }
html[data-theme="dark"] .role-card { border-color:#43372f; }
html[data-theme="dark"] .role-card:hover,html[data-theme="dark"] .role-card:focus-visible { background:#352820; }
html[data-theme="dark"] .role-member-row,html[data-theme="dark"] .role-member-empty,html[data-theme="dark"] .role-member-note { border-color:#4b3c33; color:#d8ccc3; background:#211d1a; }
html[data-theme="dark"] .role-assignment-form select { border-color:#514138; color:#f6eee8; background:#211d1a; }
html[data-theme="dark"] .role-permission-note { border-color:#654737; color:#e5c9ba; background:#382820; }
html[data-theme="dark"] .registration-email-cell > span { color:#eee4dd; }
html[data-theme="dark"] .registration-email-cell > small { color:#a99d94; }
html[data-theme="dark"] .range-select,html[data-theme="dark"] .inline-order-input,html[data-theme="dark"] .inline-order-select { border-color:#514138; color:#f1e7df; background:#29231f; }
html[data-theme="dark"] .inline-order-input:hover,html[data-theme="dark"] .inline-order-select:hover,html[data-theme="dark"] .inline-order-input:focus,html[data-theme="dark"] .inline-order-select:focus { border-color:#936047; background:#352b25; }
html[data-theme="dark"] .inline-money { border-color:#514138; background:#29231f; }
html[data-theme="dark"] .calculated-order-reward { color:#eadfd7; }
html[data-theme="dark"] .calculated-order-reward small { color:#c9bbb1; background:#40352e; }
html[data-theme="dark"] .order-status-select.status-confirmed { border-color:#315e4d; color:#9ee0c2; background:#213a31; }
html[data-theme="dark"] .order-status-select.status-cancelled,html[data-theme="dark"] .order-status-select.status-returned { border-color:#754742; color:#f0aaa3; background:#3e2927; }
html[data-theme="dark"] .order-status-select.status-review,html[data-theme="dark"] .order-status-select.status-submitted { border-color:#715c31; color:#f0ca78; background:#3d3421; }
html[data-theme="dark"] .order-workflow-tabs button { border-color:#59483d; color:#c2b5ac; background:#29231f; }
html[data-theme="dark"] .order-workflow-tabs button.active { border-color:#a55c3b; color:#ffc3aa; background:#432b21; }
html[data-theme="dark"] .order-group-row td { border-color:#4b3c33; color:#c6b8ae; background:#211d1a; }
html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-missing td { background:#332722; }
html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-waiting td { background:#312d20; }
html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-ready td { background:#222c37; }
html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-review td { background:#2d2738; }
html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-confirmed td { background:#203029; }
html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-payout td,html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-paid td { background:#203131; }
html[data-theme="dark"] .orders-editor-table .order-workflow-row.workflow-closed td { background:#362626; }
html[data-theme="dark"] .receipt-date-heading { color:#ffab82!important; }
html[data-theme="dark"] .receipt-date-cell { box-shadow:inset 2px 0 0 rgba(255,143,92,.34); }
html[data-theme="dark"] .receipt-date-input { border-color:#8a563e; color:#ffc0a2; background:#3a2922; }
html[data-theme="dark"] .receipt-date-input:hover,html[data-theme="dark"] .receipt-date-input:focus { border-color:#c9764f; background:#442e25; }
html[data-theme="dark"] .receipt-countdown { color:#e7a281; }
html[data-theme="dark"] .received-date-field { border-color:#59483d; background:#302720; }
html[data-theme="dark"] .order-journey-panel { border-color:#59483d; background:linear-gradient(135deg,#302720,#29231f); }
html[data-theme="dark"] .order-journey-head small,html[data-theme="dark"] .order-journey li small { color:#ae9e94; }
html[data-theme="dark"] .order-journey-head b,html[data-theme="dark"] .order-journey li b { color:#f4eae3; }
html[data-theme="dark"] .order-journey-head>span { color:#ffc0a2; background:#432b21; }
html[data-theme="dark"] .journey-marker { border-color:#5b4a40; color:#b8aaa0; background:#211d1a; }
html[data-theme="dark"] .order-journey li:not(:first-child):before { background:#4b3d35; }
html[data-theme="dark"] .order-journey li.done:not(:first-child):before { background:#3c9a70; }
html[data-theme="dark"] .order-journey li.current b { color:#ffb18c; }
html[data-theme="dark"] .person-cell b,html[data-theme="dark"] .profile-info-list dd,html[data-theme="dark"] .level-name { color:#f6eee8; }
html[data-theme="dark"] .promo-grid .copy-card,html[data-theme="dark"] .partner-link-grid button { border-color:#59473b; color:#f6eee8; background:#2d251f; }
html[data-theme="dark"] .promo-grid .copy-card.copied { border-color:#43a878; background:#20352b; }
html[data-theme="dark"] .mini-chart-panel { background:linear-gradient(145deg,#29231f 0%,#29231f 62%,#34251e 100%); }
html[data-theme="dark"] .sales-chart-compact { background:linear-gradient(to bottom,transparent 25%,#493b32 25.5%,transparent 26%,transparent 54%,#493b32 54.5%,transparent 55%,transparent 82%,#493b32 82.5%,transparent 83%); }
html[data-theme="dark"] .sales-month .sales-value { border-color:#5a4438; color:#f4d8cb; background:rgba(35,29,26,.92); }
html[data-theme="dark"] .sales-month.current .sales-value { border-color:#8a6427; color:#ffd98d; background:#352a1d; }
html[data-theme="dark"] .sales-month b { color:#b8aaa0; }
html[data-theme="dark"] .knowledge-search,html[data-theme="dark"] .filter-chip { border-color:#57463b; color:#e9ddd4; background:#29231f; box-shadow:none; }
html[data-theme="dark"] .material-sort { border-color:#57463b; color:#e9ddd4; background:#29231f; }
html[data-theme="dark"] .knowledge-search input { color:#f6eee8; background:transparent; }
html[data-theme="dark"] .knowledge-search input::placeholder { color:#97887d; }
html[data-theme="dark"] .filter-chip:hover,html[data-theme="dark"] .filter-chip.active { border-color:#f06c39; color:#fff; background:#d95f2f; }
html[data-theme="dark"] .sort-button { color:#b8aaa0; }
html[data-theme="dark"] .country-switcher,html[data-theme="dark"] .compact-filters select,html[data-theme="dark"] .form-grid select,html[data-theme="dark"] .ask-form input,html[data-theme="dark"] .ask-form select,html[data-theme="dark"] .ask-form textarea,html[data-theme="dark"] .form-grid input { border-color:#514138; color:#f6eee8; background:#211d1a; }
html[data-theme="dark"] .partner-contact-grid>div,html[data-theme="dark"] .partner-detail-grid>div,html[data-theme="dark"] .permission-checks label { background:#211d1a; }
html[data-theme="dark"] .partner-modal-section,html[data-theme="dark"] .permission-checks { border-color:#4b3c33; }
html[data-theme="dark"] .partner-trend-grid>div,html[data-theme="dark"] .partner-chart-empty,html[data-theme="dark"] .partner-bulk-bar { border-color:#594337; background:#352820; }
html[data-theme="dark"] .partner-curator-control select,html[data-theme="dark"] .partner-bulk-bar select { border-color:#59483e; color:var(--ink); background:#211d1a; }
html[data-theme="dark"] .partner-line-chart .chart-grid-line { stroke:#524238; }
html[data-theme="dark"] .partner-line-chart circle { fill:#29231f; }
html[data-theme="dark"] .modal-card { color:#f6eee8; background:#29231f; }
html[data-theme="dark"] .modal-close { color:#dacdc4; background:#211d1a; }
html[data-theme="dark"] .funnel-list div,html[data-theme="dark"] .attention-list button,html[data-theme="dark"] .attention-list .task-row,html[data-theme="dark"] .notification-list .notification-item,html[data-theme="dark"] .segments-panel button,html[data-theme="dark"] .message-stats span { background:#211d1a; }
html[data-theme="dark"] .segment-partner-row { background:#211d1a; }
html[data-theme="dark"] .chat-thread-list,html[data-theme="dark"] .chat-head { background:#29231f; }
html[data-theme="dark"] .chat-conversation,html[data-theme="dark"] .support-chat { border-color:#4b3c33; background:#211d1a; }
html[data-theme="dark"] .chat-compose { border-color:#4b3c33; background:#29231f; }
html[data-theme="dark"] .chat-compose textarea { border-color:#514138; color:#f6eee8; background:#211d1a; }
html[data-theme="dark"] .chat-translation { border-left-color:#ff8c58; background:#382820; }
html[data-theme="dark"] .chat-translation small { color:#ffad87; }
html[data-theme="dark"] .chat-translation p { color:#f6eee8; }
html[data-theme="dark"] .translate-message-button { border-color:#714b39; color:#ffad87; background:#382820; }
html[data-theme="dark"] .chat-file { border-color:#5a463b; color:#f6eee8; background:#352b25; }
html[data-theme="dark"] .chat-file:hover,html[data-theme="dark"] .chat-file.has-file { border-color:#b86743; background:#3d2e27; }
html[data-theme="dark"] .ask-form input[type="file"],html[data-theme="dark"] .form-grid input[type="file"] { border-color:#d18a65; color:#f6e4cf; background:repeating-linear-gradient(135deg,#2d2824 0,#2d2824 8px,#352d27 8px,#352d27 16px); box-shadow:inset 2px 2px 0 #54463c,inset -2px -2px 0 #151311,3px 3px 0 rgba(0,0,0,.28); }
html[data-theme="dark"] .referral-search-box { border-color:#514138; color:#ad9d92; background:#211d1a; }
html[data-theme="dark"] .referral-search-box:focus-within { border-color:#e07b50; background:#26211e; }
html[data-theme="dark"] .referral-search-box input { color:#f6eee8; }
html[data-theme="dark"] .partner-picker-list button { border-color:#514138; color:#f6eee8; background:#211d1a; }
html[data-theme="dark"] .partner-picker-list button:hover { border-color:#b96845; background:#312720; }
html[data-theme="dark"] .partner-picker-empty { border-color:#514138; color:#ad9d92; background:#211d1a; }
html[data-theme="dark"] .partner-picker-empty b { color:#f6eee8; }
html[data-theme="dark"] .smartphone-notification-card { border-color:#59443a; background:#30261f; }
html[data-theme="dark"] .smartphone-notification-card b { color:#f6eee8; }
html[data-theme="dark"] .smartphone-notification-card.enabled { border-color:#315847; background:#21352c; }
html[data-theme="dark"] .profile-info-list>div { border-color:#43372f; }
html[data-theme="dark"] .purchase-edit-grid input { border-color:#504239; color:#f6eee8; background:#2a231f; }
html[data-theme="dark"] .contract-status-showcase { border-color:#4a4039; background:#2a2522; }
html[data-theme="dark"] .contract-status-showcase p:not(.eyebrow),html[data-theme="dark"] .contract-status-showcase small { color:#c7bbb2; }
html[data-theme="dark"] .contract-status-showcase.signed { border-color:#285f48; background:#1f3028; }
html[data-theme="dark"] .contract-status-showcase.pending { border-color:#6b5830; background:#312b20; }
html[data-theme="dark"] .contract-status-showcase.revision { border-color:#75443e; background:#342521; }
html[data-theme="dark"] .purchase-verified-badge { color:#92dfb8; background:#193d2d; }
html[data-theme="dark"] .purchase-manual-badge { color:#f2c86d; background:#47391d; }
html[data-theme="dark"] .purchase-required-badge { color:#ffb59d; background:#4b2d25; }
html[data-theme="dark"] .cell-edit { border-color:#5b473c; color:#ff9a6b; background:#352a24; }
html[data-theme="dark"] .cell-edit:hover,html[data-theme="dark"] .cell-edit:focus-visible { border-color:#b96844; color:#ffc0a2; background:#463128; }
html[data-theme="dark"] .calculated-value small { color:#c9bbb1; background:#40352e; }
html[data-theme="dark"] .level-rank.rank-other { border-color:#5b4b42; color:#ddd1c8; background:linear-gradient(145deg,#42372f,#29231f); }
html[data-theme="dark"] .edit-record-action { border-color:#5b473c; color:#ff9a6b; background:#352a24; }
html[data-theme="dark"] .edit-record-action:hover,html[data-theme="dark"] .edit-record-action:focus-visible { border-color:#b96844; color:#ffc0a2; background:#463128; }
html[data-theme="dark"] .table-action.danger { border-color:#70443f; color:#f2a39b; background:#3b2926; }
html[data-theme="dark"] .table-action.danger:hover,html[data-theme="dark"] .table-action.danger:focus-visible { border-color:#a85c53; color:#ffd0cb; background:#4b2e2a; }

@media (max-width:980px) {
  .theme-toggle b { display:none; }
  .theme-toggle { width:40px; padding:0; }
  .ranking-country-switcher { max-width:100%; overflow-x:auto; }
  .leaderboard-head,.leaderboard-actions { align-items:flex-start; flex-direction:column; }
}

@media (max-width:760px) {
  .workspace { padding:18px 14px 30px; }
  .topbar { padding-inline:12px; }
  .language-toggle { padding-inline:8px; }
  .knowledge-layout { width:100%; grid-template-columns:minmax(0,1fr); }
  .knowledge-layout>div,.knowledge-grid { width:100%; min-width:0; }
  .knowledge-grid { grid-template-columns:minmax(0,1fr); }
  .knowledge-card { width:100%; min-width:0; box-sizing:border-box; }
  html[data-theme="dark"] .knowledge-toolbar { background:rgba(23,21,19,.94); }
  .partner-contact-grid,.partner-detail-grid,.partner-link-grid,.partner-trend-grid { grid-template-columns:1fr 1fr; }
  .partner-link-grid button:last-child { grid-column:1 / -1; }
  .partner-management-row { grid-template-columns:1fr; }
  .partner-bulk-bar { align-items:stretch; flex-direction:column; }
  .partner-bulk-bar b { margin-right:0; }
  .permission-checks { grid-template-columns:1fr; }
  .sales-chart-compact { overflow-x:auto; grid-template-columns:repeat(var(--count,6),minmax(48px,1fr)); }
}

/* Mobile header and bottom navigation: keep labels clear of icons and browser chrome. */
@media (max-width:760px) {
  body { padding-bottom:calc(90px + env(safe-area-inset-bottom)); }
  .global-search { position:relative; min-width:0; padding-inline:14px; }
  .global-search > span { width:20px; height:20px; display:grid; place-items:center; flex:0 0 20px; }
  .global-search > span .ui-icon { width:20px; height:20px; }
  .global-search input { min-width:0; padding:0; }
  .sidebar {
    height:calc(84px + env(safe-area-inset-bottom));
    padding:6px 8px calc(10px + env(safe-area-inset-bottom));
  }
  .side-nav { align-items:start; }
  .nav-item,.nav-item.active {
    position:relative;
    height:66px;
    min-height:66px;
    justify-content:flex-start;
    gap:6px;
    padding:10px 4px 7px;
    overflow:visible;
  }
  .nav-attention-badge { top:5px; right:5px; min-width:18px; height:18px; padding-inline:5px; border-width:1px; font-size:.55rem; transform:none; }
  .nav-item.active:after { top:2px; left:50%; transform:translateX(-50%); }
}

@media (max-width:390px) {
  .global-search:after { left:52px; }
}

@media (max-width:760px) {
  .role-member-row { grid-template-columns:auto minmax(0,1fr) auto; }
  .role-member-row .table-action { grid-column:2 / -1; justify-self:start; }
  .role-assignment-form { grid-template-columns:1fr; }
  .role-assignment-form .primary-button { width:100%; }
  .referral-search-box { height:46px; }
  .partner-picker-list button { gap:9px; min-height:58px; padding:8px; }
  .partner-picker-list .table-avatar { width:36px; height:36px; }
  .partner-picker-action { font-size:0; gap:0; }
  .partner-picker-action>b { font-size:.78rem; }
  .segment-partner-row { grid-template-columns:auto minmax(0,1fr); }
  .segment-partner-row>.table-action { grid-column:2; justify-self:start; }
  .smartphone-notification-card { grid-template-columns:auto minmax(0,1fr); }
  .smartphone-notification-card .secondary-button { grid-column:1 / -1; width:100%; }
}

.staff-sections {
  max-height:420px;
  overflow:auto;
  align-content:start;
  scrollbar-width:thin;
}
.permission-select-all {
  grid-column:1 / -1;
  justify-self:end;
  min-height:32px;
  padding:0 12px;
  border:0;
  border-radius:9px;
  background:#fff0e8;
  color:#d95727;
  font:800 .68rem/1 var(--font-body);
  cursor:pointer;
}
.permission-select-all:hover { background:#ffe3d4; }
body.dark-mode .permission-select-all { background:#4c3026; color:#ff9a70; }
@media (max-width:760px) {
  .staff-sections { max-height:330px; }
}
.reward-board{display:grid;grid-template-columns:1fr 1fr;gap:18px}.workflow-list{display:grid;gap:12px}.workflow-card{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:16px;border:1px solid var(--line,#e7ddd4);border-radius:16px;background:#faf8f6}.workflow-card h3{margin:8px 0 4px}.workflow-card p,.workflow-card small{margin:0;color:var(--muted,#788398)}.contract-partner-meta{display:flex;gap:6px 14px;flex-wrap:wrap;margin-bottom:5px!important;font-size:13px}.contract-partner-meta span+span:before{content:'•';margin-right:14px;color:#c9bdb2}.workflow-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}.workflow-empty{color:var(--muted,#788398);padding:20px 0}.contract-template-summary{margin-bottom:18px}.contract-card-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:18px}.eligibility-note{padding:12px 14px;border-radius:12px;background:#fff4dc;color:#8c6111}.eligibility-note.ready{background:#e7f7ef;color:#167553}.fx-rate-strip{display:flex;align-items:center;gap:14px;margin:16px 0;padding:14px 18px;border:1px solid #f2c5ad;border-radius:16px;background:linear-gradient(110deg,#fff8f3,#fff);box-shadow:0 8px 24px rgba(238,111,57,.08)}.fx-rate-strip b,.fx-rate-strip small{display:block}.fx-rate-strip small{color:var(--muted,#788398)}.fx-live-dot{width:11px;height:11px;border-radius:50%;background:#2db37d;box-shadow:0 0 0 0 rgba(45,179,125,.45);animation:fx-pulse 2s infinite}.fx-secondary{margin-left:auto;display:flex;gap:16px;font-size:13px;color:var(--muted,#788398)}@keyframes fx-pulse{70%{box-shadow:0 0 0 9px rgba(45,179,125,0)}100%{box-shadow:0 0 0 0 rgba(45,179,125,0)}}.referral-partner-select{min-width:210px}
@media(max-width:760px){.reward-board{grid-template-columns:1fr}.workflow-card{align-items:flex-start;flex-direction:column}.workflow-actions{justify-content:flex-start}.fx-rate-strip{align-items:flex-start;flex-wrap:wrap}.fx-secondary{width:100%;margin-left:25px;flex-direction:column;gap:4px}.contract-card-actions>*{width:100%}.partner-insight-meta{grid-template-columns:repeat(2,minmax(0,1fr))}.compact-order-history button{grid-template-columns:74px minmax(0,1fr)}.compact-order-history em{grid-column:2}}
@media(max-width:760px){.fx-topbar{min-width:42px;min-height:42px;justify-content:center;padding:0 7px}.fx-topbar .fx-live-dot,.fx-topbar small{display:none}.fx-topbar b{font-size:.55rem}}

/* v67 — mobile-first density and true single-column layout */
@media (max-width:760px) {
  html { width:100%; max-width:100%; overflow-x:hidden; font-size:15px; }
  body { width:100%; max-width:100%; overflow-x:hidden; padding-bottom:calc(78px + env(safe-area-inset-bottom)); }
  .app-shell,.main-column,.workspace,[data-view] { width:100%; max-width:100%; min-width:0; }
  .main-column,.workspace,[data-view] { overflow-x:clip; }
  .topbar { width:100%; min-width:0; min-height:calc(54px + env(safe-area-inset-top)); display:flex; gap:5px; padding:env(safe-area-inset-top) 8px 0; overflow:visible; }
  .topbar > * { min-width:0; }
  .global-search { position:relative; width:36px; min-width:36px; height:36px; flex:0 0 36px; padding:0; border-radius:11px; }
  .global-search > span { width:36px; height:36px; flex:0 0 36px; }
  .global-search > span .ui-icon { width:17px; height:17px; }
  .global-search input { position:absolute; width:1px; min-width:0; height:36px; padding:0; opacity:0; pointer-events:none; }
  .global-search:focus-within { position:absolute; z-index:30; inset:calc(env(safe-area-inset-top) + 7px) 8px auto; width:auto; padding:0 12px; background:#fff; box-shadow:0 8px 28px rgba(42,32,25,.18); }
  .global-search:focus-within > span { width:25px; flex-basis:25px; }
  .global-search:focus-within input { position:static; width:100%; padding:0 4px; opacity:1; pointer-events:auto; }
  .global-search:after { content:none!important; }
  html[data-theme="dark"] .global-search:focus-within { background:#29231f; }
  .fx-topbar { width:72px; min-width:72px; min-height:36px; height:36px; padding:0 6px; border-radius:10px; }
  .fx-topbar b { overflow:hidden; font-size:.5rem; line-height:1.12; text-align:center; white-space:normal; }
  .fx-topbar .fx-live-dot,.fx-topbar small { display:none; }
  .language-toggle,.theme-toggle,.notification-button,.mode-switch,.install-app-button { width:36px; min-width:36px; height:36px; min-height:36px; flex:0 0 36px; padding:0; border-radius:10px; }
  .language-toggle { font-size:.56rem; }
  .language-toggle i,.language-toggle span:last-child { display:none; }
  .theme-toggle span { font-size:.78rem; }
  .notification-button .ui-icon,.mode-switch .ui-icon,.install-app-button .ui-icon { width:16px; height:16px; }
  .install-app-button:after { font-size:.8rem; }
  .workspace { padding:16px 11px 24px; }
  .welcome-row,.admin-heading,.compact-page-heading { gap:12px; margin-bottom:14px; }
  .welcome-row h1,.admin-heading h1,.compact-page-heading h1,h1 { margin-bottom:5px; font-size:1.52rem; line-height:1.12; }
  .lead { font-size:.76rem; line-height:1.45; }
  .eyebrow { font-size:.6rem; letter-spacing:.1em; }
  .primary-button,.secondary-button { min-height:42px; font-size:.7rem; }
  .welcome-row .primary-button { min-height:46px; }
  .admin-actions { gap:7px; }
  .admin-actions .primary-button:last-child:nth-child(odd) { grid-column:1 / -1; }
  .sidebar { height:calc(74px + env(safe-area-inset-bottom)); padding:5px 6px calc(7px + env(safe-area-inset-bottom)); }
  .side-nav { gap:2px; }
  .nav-item,.nav-item.active { width:72px; min-width:72px; max-width:72px; height:60px; min-height:60px; flex-basis:72px; gap:4px; padding:8px 3px 5px; border-radius:11px; font-size:.52rem; line-height:1.06; }
  .nav-icon { font-size:1rem; }
  .nav-icon .ui-icon { width:16px; height:16px; }
  .nav-attention-badge { top:3px; right:3px; min-width:16px; height:16px; font-size:.49rem; }
  .partner-announcement { gap:10px; margin-bottom:10px; padding:11px 12px; border-radius:14px; }
  .announcement-mark { width:34px; height:34px; }
  .partner-announcement small { font-size:.54rem; }
  .partner-announcement b { font-size:.7rem; line-height:1.3; }
  .partner-announcement p { font-size:.62rem; line-height:1.35; }
  .business-kpis { gap:7px; margin-bottom:10px; }
  .business-kpis article,.kpi-grid article { min-height:82px; padding:11px; border-radius:14px; }
  .business-kpis small,.kpi-grid small { font-size:.57rem; }
  .business-kpis b,.kpi-grid b { font-size:1rem; }
  .business-kpis em,.kpi-grid em { font-size:.58rem; line-height:1.28; }
  .workspace .admin-panel,.performance-card { padding:13px; border-radius:15px; }
  .panel-head { gap:9px; margin-bottom:9px; }
  .panel-head h2,.performance-card h2 { font-size:.88rem; line-height:1.25; }
  .team-donut { min-height:96px; gap:14px; justify-content:flex-start; }
  .team-donut>span { width:70px; height:70px; flex:0 0 70px; }
  .team-donut>span:before { inset:8px; }
  .team-donut>span b { font-size:1rem; }
  .team-donut div { max-width:none; }
  .team-donut div>b { font-size:.78rem; }
  .team-donut p { margin-top:4px; font-size:.58rem; line-height:1.35; }
  .mini-chart-panel .period-pills button { min-height:34px; font-size:.52rem; }
  .sales-chart-compact { min-height:112px; max-height:132px; gap:7px; padding:7px 3px 0; grid-template-columns:repeat(var(--count,6),minmax(42px,1fr)); }
  .sales-month { min-height:102px; }
  .sales-month i { width:min(34px,62%); }
  .sales-month b,.sales-month .sales-value { font-size:.49rem; }
  .bar-chart { height:150px; gap:5px; }
  .chart-plot { height:132px; margin-left:28px; }
  .chart-scale { left:-33px; }
  .partner-line-chart { min-height:125px; overflow:hidden; }
  .partner-mini-chart { height:80px; gap:4px; }
  .country-switcher { width:100%; max-width:100%; gap:1px; overflow-x:auto; padding:3px; }
  .country-switcher button { min-height:34px; padding:0 9px; font-size:.57rem; }
  .admin-toolbar { display:grid; grid-template-columns:1fr 1fr; gap:7px; margin-bottom:11px; }
  .admin-toolbar .country-switcher,.admin-toolbar .admin-search { grid-column:1 / -1; width:100%; flex-basis:auto; }
  .admin-search,.compact-filters select,.admin-toolbar select,.range-select { min-height:42px; font-size:.68rem; }
  select,.compact-filters select,.admin-toolbar select,.range-select { appearance:none; -webkit-appearance:none; padding-right:34px!important; background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23756861' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E")!important; background-repeat:no-repeat!important; background-position:right 10px center!important; background-size:14px!important; }
  .data-table-wrap,.data-table-wrap.embedded { width:100%; max-width:100%; margin:0; overflow:visible; border:0; border-radius:0; background:transparent; }
  .data-table,.orders-editor-table { width:100%; min-width:0; display:block; }
  .data-table thead { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
  .data-table tbody { width:100%; display:grid; gap:8px; }
  .data-table tbody tr { position:relative; width:100%; min-width:0; display:grid; overflow:hidden; padding:7px 10px; border:1px solid var(--line); border-radius:13px; background:#fff; box-shadow:0 4px 14px rgba(34,28,24,.035); }
  .data-table td,.orders-editor-table td { min-width:0; display:grid; grid-template-columns:minmax(82px,.42fr) minmax(0,1fr); align-items:center; gap:9px; padding:7px 0!important; border:0; border-bottom:1px solid #eee9e5; background:transparent!important; box-shadow:none!important; text-align:left!important; font-size:.64rem; overflow-wrap:anywhere; }
  .data-table td:last-child { border-bottom:0; }
  .data-table td:before { content:attr(data-label); color:#8b817a; font-size:.52rem; font-weight:800; letter-spacing:.045em; text-transform:uppercase; }
  .data-table td[data-label=""] { grid-template-columns:1fr; }
  .data-table td[data-label=""]:before,.data-table td[colspan]:before { content:none; }
  .data-table td[colspan] { display:block; padding:13px!important; }
  .data-table input,.data-table select { max-width:100%; }
  .data-table .row-action,.data-table .table-action { min-height:34px; justify-self:start; }
  html[data-theme="dark"] .data-table tbody tr { border-color:#493c33; background:#29231f; }
  html[data-theme="dark"] .data-table td { border-color:#43372f; }
  .partners-register-table td:nth-child(n+4):nth-child(-n+9) { display:none; }
  .partners-register-table tbody tr { cursor:pointer; padding-left:38px; }
  .partners-register-table td:first-child { position:absolute; top:12px; left:11px; width:18px; padding:0!important; }
  .partners-register-table td:nth-child(2),.partners-register-table td:nth-child(3) { grid-template-columns:1fr; }
  .partners-register-table td:nth-child(2):before,.partners-register-table td:nth-child(3):before { display:none; }
  .partner-name-link { width:100%; }
  .partner-name-link small { white-space:normal; }
  .partner-contact-link { max-width:100%; padding-left:43px; }
  .partners-register-table td:last-child .row-action { width:100%; }
  .partner-contact-grid,.partner-detail-grid,.partner-trend-grid { grid-template-columns:1fr 1fr; gap:7px; }
  .partner-contact-grid>div,.partner-detail-grid>div,.partner-trend-grid>div { padding:9px; }
  .partner-modal-section { padding:10px; }
  .modal-card { padding:22px 15px calc(18px + env(safe-area-inset-bottom)); }
  .modal-card h2 { font-size:1.25rem; }
  .modal-card p { font-size:.72rem; line-height:1.55; }
}

@media (max-width:370px) {
  .topbar { gap:4px; padding-inline:6px; }
  .fx-topbar { width:66px; min-width:66px; }
  .language-toggle,.theme-toggle,.notification-button,.mode-switch,.install-app-button,.global-search { width:34px; min-width:34px; flex-basis:34px; }
  .global-search > span { width:34px; height:34px; flex-basis:34px; }
}
