/* Mira · beauty studio — LeoAnalyst demo. Palette: misted sage paper, deep fern ink-green, honey + rose accents */
:root{
  --paper:#f6f1f4;--paper-2:#efe7ec;--surface:#ffffff;--surface-2:#f8f3f6;--line:#ece3e8;--line-2:#e0d4db;
  --ink:#2a1f2d;--ink-2:#4d3f50;--muted:#8a7b88;--faint:#b9adb6;
  --fern:#6e3f8f;--fern-2:#9a6cc4;--fern-soft:#efe5f7;--fern-glow:#e0cdef;
  --peach:#f0a07e;--peach-soft:#fde9df;
  --good:#2f8a64;--good-soft:#e1f2ea;
  --honey:#f0a07e;--honey-soft:#fde9df;--rose:#d9667f;--rose-soft:#fbe4ea;--sky:#7b8fe0;--sky-soft:#e8ebfb;--plum:#9a6cc4;
  --shadow:0 1px 2px rgba(42,31,45,.04),0 8px 24px -12px rgba(110,63,143,.16);
  --shadow-pop:0 18px 50px -18px rgba(60,30,70,.35);
  --r-xl:26px;--r-lg:20px;--r-md:14px;--r-sm:10px;
  --font:"Onest",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  color-scheme:light;
}
body.dark{
  --paper:#151117;--paper-2:#1a151d;--surface:#1f1923;--surface-2:#271f2c;--line:#32293a;--line-2:#3e3346;
  --ink:#f3ecf5;--ink-2:#d2c5d6;--muted:#9d8fa2;--faint:#6c5f72;
  --fern:#c39be6;--fern-2:#d4b3f0;--fern-soft:#352743;--fern-glow:#45325a;
  --peach-soft:#3d2a24;--good:#6fd3a6;--good-soft:#1d352c;
  --honey-soft:#3d2a24;--rose-soft:#3d2430;--sky-soft:#242a40;
  --shadow:0 1px 2px rgba(0,0,0,.3),0 10px 30px -14px rgba(0,0,0,.6);--shadow-pop:0 18px 50px -18px rgba(0,0,0,.8);
  color-scheme:dark;
}
*{box-sizing:border-box}
html,body{margin:0;min-height:100%}
body{font-family:var(--font);background:var(--paper);color:var(--ink);font-size:14px;line-height:1.45;-webkit-font-smoothing:antialiased;font-feature-settings:"tnum" 1,"lnum" 1}
button,input,select{font:inherit;color:inherit}
button{cursor:pointer}
:focus-visible{outline:2px solid var(--fern-2);outline-offset:2px;border-radius:8px}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}

/* Shell */
.shell{display:grid;grid-template-columns:76px minmax(0,1fr);min-height:100vh}
.rail{position:sticky;top:0;height:100vh;display:flex;flex-direction:column;align-items:center;gap:6px;padding:18px 0;background:var(--surface);border-right:1px solid var(--line)}
.logo{width:44px;height:44px;border-radius:50%;display:grid;place-items:center;background:var(--fern);color:#fff;margin-bottom:14px;box-shadow:0 6px 16px -6px rgba(110,63,143,.55)}
.logo svg{width:22px;height:22px}
.theme-switch{display:flex;flex-direction:column;gap:4px;padding:4px;border-radius:999px;background:var(--surface-2);border:1px solid var(--line);margin-bottom:16px}
.theme-switch button{width:34px;height:34px;border-radius:50%;border:0;background:transparent;color:var(--muted);display:grid;place-items:center}
.theme-switch button[aria-pressed="true"]{background:var(--ink);color:var(--surface)}
.theme-switch svg{width:16px;height:16px}
.rail-nav{display:flex;flex-direction:column;gap:6px}
.rail-btn{position:relative;width:46px;height:46px;border-radius:15px;border:0;background:transparent;color:var(--muted);display:grid;place-items:center;transition:background .15s,color .15s}
.rail-btn:hover{background:var(--surface-2);color:var(--ink)}
.rail-btn[aria-current="page"]{background:var(--fern);color:#fff;box-shadow:0 8px 18px -8px rgba(110,63,143,.6)}
.rail-btn svg{width:20px;height:20px}
.rail-btn .dot{position:absolute;top:6px;right:6px;min-width:16px;height:16px;padding:0 4px;border-radius:999px;background:var(--rose);color:#fff;font-size:10px;font-weight:700;display:grid;place-items:center;border:2px solid var(--surface)}
.rail-btn .tip{position:absolute;left:56px;top:50%;transform:translateY(-50%);white-space:nowrap;background:var(--ink);color:var(--surface);font-size:12px;padding:5px 9px;border-radius:8px;opacity:0;pointer-events:none;transition:opacity .12s;z-index:30}
.rail-btn:hover .tip,.rail-btn:focus-visible .tip{opacity:1}
.rail-foot{margin-top:auto}

.main{min-width:0;display:flex;flex-direction:column}
.topbar{position:sticky;top:0;z-index:20;display:flex;align-items:center;gap:16px;padding:14px 28px;background:color-mix(in srgb,var(--paper) 86%,transparent);backdrop-filter:blur(12px);border-bottom:1px solid transparent}
.brand{display:flex;flex-direction:column;line-height:1.1;min-width:120px}
.brand b{font-size:19px;font-weight:700;letter-spacing:-.02em}
.brand span{font-size:12px;color:var(--muted)}
.pills{display:flex;gap:3px;padding:4px;border-radius:999px;background:var(--surface);border:1px solid var(--line);overflow-x:auto;scrollbar-width:none;min-width:0}
.pills::-webkit-scrollbar{display:none}
.pill{border:0;background:transparent;padding:8px 15px;border-radius:999px;font-size:13px;font-weight:550;color:var(--muted);white-space:nowrap}
.pill:hover{color:var(--ink)}
.pill[aria-pressed="true"],.pill[aria-current="page"]{background:var(--ink);color:var(--surface)}
.top-actions{margin-left:auto;display:flex;align-items:center;gap:8px}
.search{display:flex;align-items:center;gap:8px;height:40px;padding:0 10px 0 12px;border-radius:999px;background:var(--surface);border:1px solid var(--line);color:var(--muted);width:200px}
.search input{border:0;background:transparent;outline:0;width:100%;font-size:13px;color:var(--ink)}
.search kbd{font-family:inherit;font-size:11px;color:var(--faint);border:1px solid var(--line);border-radius:6px;padding:1px 5px}
.search svg{width:16px;height:16px;flex:none}
.icon-btn{position:relative;width:40px;height:40px;border-radius:50%;border:1px solid var(--line);background:var(--surface);display:grid;place-items:center;color:var(--ink-2);font-size:12px;font-weight:700}
.icon-btn svg{width:18px;height:18px}
.icon-btn .dot{position:absolute;top:-2px;right:-2px;width:17px;height:17px;border-radius:50%;background:var(--rose);color:#fff;font-size:10px;display:grid;place-items:center;border:2px solid var(--paper)}
.btn{display:inline-flex;align-items:center;gap:8px;height:40px;padding:0 16px;border-radius:999px;border:1px solid var(--line);background:var(--surface);font-size:13px;font-weight:600;color:var(--ink);white-space:nowrap}
.btn:hover{border-color:var(--line-2)}
.btn svg{width:16px;height:16px}
.btn-primary{background:var(--fern);border-color:var(--fern);color:#fff;box-shadow:0 8px 18px -10px rgba(110,63,143,.7)}
.btn-primary:hover{background:var(--fern-2);border-color:var(--fern-2)}
body.dark .btn-primary{color:#1b1220}
.btn-ghost{background:transparent}
.user{display:flex;align-items:center;gap:9px;padding:4px 12px 4px 4px;border-radius:999px;background:var(--surface);border:1px solid var(--line)}
.avatar{width:32px;height:32px;border-radius:50%;display:grid;place-items:center;font-size:12px;font-weight:700;color:#fff;flex:none}
.user small{display:block;font-size:11px;color:var(--muted);line-height:1.1}
.user b{font-size:13px;font-weight:600;line-height:1.2}

.content{padding:8px 28px 48px;max-width:1520px;width:100%}
.page-head{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin:14px 0 18px;flex-wrap:wrap}
.page-head p{margin:0 0 4px;color:var(--muted);font-size:13px}
.page-head h1{margin:0;font-size:34px;line-height:1.05;font-weight:700;letter-spacing:-.035em}
.head-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.seg{display:inline-flex;gap:2px;padding:3px;border-radius:999px;background:var(--surface);border:1px solid var(--line)}
.seg button{border:0;background:transparent;border-radius:999px;padding:7px 12px;font-size:12.5px;font-weight:600;color:var(--muted);white-space:nowrap}
.seg button[aria-pressed="true"]{background:var(--fern-soft);color:var(--fern)}

/* Grid & cards */
.grid{display:grid;gap:16px}
.g-hero{grid-template-columns:minmax(300px,1.15fr) repeat(3,minmax(0,1fr))}
.g-2-1{grid-template-columns:minmax(0,2fr) minmax(300px,1fr)}
.g-1-1{grid-template-columns:repeat(2,minmax(0,1fr))}
.g-4{grid-template-columns:repeat(4,minmax(0,1fr))}
.g-6{grid-template-columns:repeat(6,minmax(0,1fr))}
.stack{display:flex;flex-direction:column;gap:16px}
.mt{margin-top:16px}
.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-xl);padding:20px 22px;box-shadow:var(--shadow);min-width:0;position:relative}
.card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:12px}
.card-title{margin:0;font-size:16px;font-weight:650;letter-spacing:-.01em}
.card-sub{margin:3px 0 0;color:var(--muted);font-size:12.5px}
.legend{display:flex;gap:14px;flex-wrap:wrap;font-size:12px;color:var(--muted);align-items:center}
.legend i{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:6px;vertical-align:0}
.legend button{border:0;background:transparent;padding:4px 2px;font-size:12px;color:var(--muted)}
.legend button[aria-pressed="false"]{opacity:.4;text-decoration:line-through}

/* Welcome */
.welcome{background:transparent;border:0;box-shadow:none;padding:6px 6px 6px 2px;display:flex;flex-direction:column}
.welcome .when{display:inline-flex;align-items:center;gap:8px;font-size:12.5px;color:var(--muted);padding:5px 10px;border-radius:999px;background:var(--surface);border:1px solid var(--line);align-self:flex-start}
.welcome .when i{width:7px;height:7px;border-radius:50%;background:var(--fern-2)}
.welcome h1{margin:16px 0 10px;font-size:40px;line-height:1.02;font-weight:700;letter-spacing:-.04em}
.welcome p{margin:0 0 18px;color:var(--ink-2);font-size:14px;max-width:34ch}
.welcome p b{font-weight:650;color:var(--ink)}
.welcome .row{display:flex;gap:8px;flex-wrap:wrap;margin-top:auto}

/* KPI */
.kpi{display:flex;flex-direction:column;gap:6px;cursor:default}
.kpi-top{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}
.kpi-label{font-size:13px;color:var(--muted);font-weight:500}
.kpi-ico{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;flex:none}
.kpi-ico svg{width:18px;height:18px}
.kpi-value{font-size:30px;font-weight:700;letter-spacing:-.035em;line-height:1.1;display:flex;align-items:baseline;gap:10px;flex-wrap:wrap}
.delta{white-space:nowrap;font-size:12px;font-weight:650;letter-spacing:0;padding:2px 7px;border-radius:999px;background:var(--good-soft);color:var(--good)}
.delta.down{background:var(--rose-soft);color:var(--rose)}
.kpi-foot{display:flex;justify-content:space-between;align-items:flex-end;gap:10px;margin-top:auto;font-size:12px;color:var(--muted)}
.spark{width:110px;height:36px;flex:none}
.thumbs{display:flex}
.thumbs span{width:34px;height:34px;border-radius:10px;overflow:hidden;border:2px solid var(--surface);margin-left:-8px;box-shadow:0 2px 6px rgba(0,0,0,.08)}
.thumbs span:first-child{margin-left:0}
.thumbs svg{width:100%;height:100%;display:block}
button.kpi{text-align:left;font:inherit;color:inherit;border:1px solid var(--line);cursor:pointer;transition:border-color .15s,box-shadow .15s}
button.kpi:hover{border-color:var(--line-2)}
button.kpi[aria-pressed="true"]{border-color:var(--fern-2);box-shadow:0 0 0 3px var(--fern-soft),var(--shadow)}
.g-6 .kpi-value{font-size:24px}
.g-6 .card{padding:16px 16px}

/* Charts */
.chart{position:relative;width:100%;min-height:200px}
.chart svg{display:block;width:100%;height:auto;overflow:visible}
.chart text{font-family:var(--font);fill:var(--muted)}
.tip-box{position:absolute;z-index:15;pointer-events:none;min-width:150px;padding:10px 12px;border-radius:12px;background:var(--surface);border:1px solid var(--line);box-shadow:var(--shadow-pop);font-size:12px;opacity:0;transform:translateY(4px);transition:opacity .1s,transform .1s}
.tip-box.on{opacity:1;transform:none}
.tip-box b{display:block;font-size:12.5px;margin-bottom:4px}
.tip-box .tr{display:flex;justify-content:space-between;gap:14px;color:var(--ink-2)}
.tip-box .tr i{display:inline-block;width:8px;height:8px;border-radius:50%;margin-right:6px}
.tip-box .tr span:last-child{font-weight:650;color:var(--ink)}
.toggle{display:inline-flex;align-items:center;gap:8px;font-size:12.5px;color:var(--muted);border:0;background:transparent;padding:4px}
.toggle .sw{width:34px;height:20px;border-radius:999px;background:var(--line-2);position:relative;transition:background .15s}
.toggle .sw::after{content:"";position:absolute;top:2px;left:2px;width:16px;height:16px;border-radius:50%;background:#fff;transition:transform .15s;box-shadow:0 1px 3px rgba(0,0,0,.2)}
.toggle[aria-pressed="true"] .sw{background:var(--fern-2)}
.toggle[aria-pressed="true"] .sw::after{transform:translateX(14px)}

/* Gauge */
.gauge-wrap{display:flex;flex-direction:column;align-items:center}
.gauge-wrap svg{width:100%;max-width:300px;height:auto}
.gauge-num{font-size:34px;font-weight:700;letter-spacing:-.04em}
.gauge-cap{font-size:12.5px;color:var(--muted)}
.gauge-stats{display:flex;justify-content:space-between;width:100%;margin-top:14px;padding-top:14px;border-top:1px dashed var(--line-2);gap:10px}
.gauge-stats div{display:flex;flex-direction:column}
.gauge-stats small{color:var(--muted);font-size:12px}
.gauge-stats b{font-size:20px;letter-spacing:-.02em}
.gauge-note{margin-top:10px;font-size:12px;color:var(--muted);text-align:center}

/* Lists */
.list{display:flex;flex-direction:column}
.li{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:12px;align-items:center;padding:10px 0;border-top:1px solid var(--line)}
.li:first-child{border-top:0}
.li-time{font-weight:650;font-size:13px;min-width:46px}
.li-main b{display:block;font-size:13.5px;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.li-main small{display:block;color:var(--muted);font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.status{display:inline-flex;align-items:center;gap:6px;font-size:11.5px;font-weight:600;padding:3px 9px;border-radius:999px;white-space:nowrap}
.st-done{background:var(--fern-soft);color:var(--fern)}
.st-confirmed{background:var(--sky-soft);color:var(--sky)}
.st-pending{background:var(--peach-soft);color:#b8603d}
body.dark .st-pending{color:var(--peach)}
.st-cancelled{background:var(--surface-2);color:var(--muted)}
.st-noshow{background:var(--rose-soft);color:var(--rose)}
.bar-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 12px;padding:9px 0;border-top:1px solid var(--line)}
.bar-row:first-child{border-top:0}
.bar-row .nm{font-size:13px;font-weight:550;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.bar-row .vl{font-size:13px;font-weight:650;text-align:right}
.bar-row .track{grid-column:1/-1;height:7px;border-radius:999px;background:var(--surface-2);overflow:hidden}
.bar-row .fill{height:100%;border-radius:999px;background:var(--fern-2)}
.rank{display:grid;grid-template-columns:30px minmax(0,1fr) auto;gap:4px 12px;align-items:center;padding:10px 0;border-top:1px solid var(--line)}
.rank:first-child{border-top:0}
.rank .n{width:28px;height:28px;border-radius:50%;display:grid;place-items:center;font-size:12px;font-weight:700;background:var(--surface-2);color:var(--ink-2);grid-row:span 2}
.rank:first-child .n{background:var(--fern);color:#fff}
.rank b{font-size:13.5px;font-weight:600}
.rank small{display:block;font-size:12px;color:var(--muted)}
.rank .vl{font-weight:650;font-size:13.5px;text-align:right;grid-row:span 1}
.rank .track{grid-column:2/-1;height:6px;border-radius:999px;background:var(--surface-2);overflow:hidden}
.rank .fill{height:100%;background:linear-gradient(90deg,var(--fern-2),var(--peach));border-radius:999px}

/* Catalog */
.toolbar{display:flex;flex-wrap:wrap;gap:10px;align-items:center;justify-content:space-between;margin:4px 0 16px}
.chips{display:flex;gap:6px;flex-wrap:wrap}
.chip{border:1px solid var(--line);background:var(--surface);border-radius:999px;padding:7px 13px;font-size:12.5px;font-weight:600;color:var(--ink-2);display:inline-flex;align-items:center;gap:7px;white-space:nowrap}
.chip i{width:7px;height:7px;border-radius:50%}
.chip small{color:var(--faint);font-weight:600}
.chip[aria-pressed="true"]{background:var(--ink);border-color:var(--ink);color:var(--surface)}
.chip[aria-pressed="true"] small{color:var(--faint)}
.tools-r{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.field{display:flex;align-items:center;gap:8px;height:38px;padding:0 12px;border-radius:999px;background:var(--surface);border:1px solid var(--line);color:var(--muted)}
.field input,.field select{border:0;background:transparent;outline:0;font-size:13px;color:var(--ink);min-width:0}
.field svg{width:15px;height:15px;flex:none}
.field select{padding-right:4px;cursor:pointer}
.catalog{display:grid;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:16px}
.svc{display:flex;flex-direction:column;background:var(--surface);border:1px solid var(--line);border-radius:var(--r-xl);overflow:hidden;box-shadow:var(--shadow);text-align:left;padding:0;transition:transform .2s cubic-bezier(.2,.8,.2,1),box-shadow .2s}
.svc:hover{transform:translateY(-3px);box-shadow:var(--shadow-pop)}
.svc-art{position:relative;aspect-ratio:4/3;margin:8px 8px 0;border-radius:20px;overflow:hidden}
.svc-art svg{position:absolute;inset:0;width:100%;height:100%}
.badge{position:absolute;top:10px;left:10px;font-size:11.5px;font-weight:650;padding:4px 9px;border-radius:999px;background:rgba(255,255,255,.88);color:var(--ink);backdrop-filter:blur(6px)}
.badge.low{background:var(--rose);color:#fff}
.badge.new{background:var(--sky);color:#fff}
.badge.hit{background:var(--fern);color:#fff}
.badge.premium{background:var(--ink);color:#fff}
.svc-body{padding:12px 16px 16px;display:flex;flex-direction:column;gap:6px;flex:1}
.svc-top{display:flex;justify-content:space-between;gap:10px;align-items:flex-start}
.svc-name{font-size:14.5px;font-weight:650;letter-spacing:-.01em}
.svc-cat{font-size:11.5px;font-weight:600;padding:3px 8px;border-radius:999px;white-space:nowrap}
.svc-meta{font-size:12.5px;color:var(--muted)}
.svc-load{margin-top:auto;padding-top:8px}
.svc-load .lbl{display:flex;justify-content:space-between;font-size:12px;color:var(--muted);margin-bottom:6px}
.svc-load .lbl b{color:var(--ink);font-weight:650}
.svc-load .track{height:6px;border-radius:999px;background:var(--surface-2);overflow:hidden}
.svc-load .fill{height:100%;border-radius:999px}
.empty{padding:40px 20px;text-align:center;color:var(--muted);border:1px dashed var(--line-2);border-radius:var(--r-xl)}
.empty button{margin-top:10px}

/* Table */
.tbl-wrap{width:100%;overflow-x:auto}
.tbl{width:100%;border-collapse:collapse;font-size:13px}
.tbl th{text-align:left;font-weight:600;color:var(--muted);font-size:12px;padding:10px 10px;border-bottom:1px solid var(--line);white-space:normal;line-height:1.25;vertical-align:bottom}
.tbl td{padding:11px 10px;border-bottom:1px solid var(--line);vertical-align:middle}
.tbl tr:last-child td{border-bottom:0}
.tbl .num{text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums}
.tbl th:first-child,.tbl td:first-child{padding-left:4px}
.tbl th:last-child,.tbl td:last-child{padding-right:4px}
.tbl small{display:block;color:var(--muted);font-size:12px}
.tbl .nowrap{white-space:nowrap}
.tbl tbody tr:hover td{background:var(--surface-2)}
.more{display:flex;justify-content:center;margin-top:12px}

/* Heatmap */
.heat{display:grid;grid-template-columns:34px repeat(12,minmax(0,1fr));gap:4px;font-size:11px;color:var(--muted)}
.heat .c{aspect-ratio:1.5/1;border-radius:6px;min-height:18px}
.heat .h{text-align:center}
.heat .d{display:flex;align-items:center}
.heat-key{display:flex;align-items:center;gap:6px;font-size:11.5px;color:var(--muted);margin-top:10px}
.heat-key span{width:22px;height:10px;border-radius:4px}

/* Funnel */
.funnel{display:flex;flex-direction:column;gap:10px}
.fn{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px 12px}
.fn b{font-size:13px;font-weight:600}
.fn .vl{font-size:13px;font-weight:650;text-align:right}
.fn .vl small{color:var(--muted);font-weight:500;margin-left:6px}
.fn .track{grid-column:1/-1;height:26px;border-radius:9px;background:var(--surface-2);overflow:hidden}
.fn .fill{height:100%;border-radius:9px;background:linear-gradient(90deg,var(--fern),var(--fern-2) 60%,var(--peach))}
.fn .drop{grid-column:1/-1;font-size:11.5px;color:var(--rose)}

/* Masters */
.masters{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:16px}
.mst{text-align:left;font:inherit;color:inherit;cursor:pointer;display:flex;flex-direction:column;gap:14px}
.mst[aria-pressed="true"]{border-color:var(--fern-2);box-shadow:0 0 0 3px var(--fern-soft),var(--shadow)}
.mst-top{display:flex;gap:12px;align-items:center}
.mst-top .avatar{width:46px;height:46px;font-size:15px}
.mst-top b{display:block;font-size:15px;font-weight:650}
.mst-top small{color:var(--muted);font-size:12.5px}
.mst-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.mst-stats div{display:flex;flex-direction:column}
.mst-stats small{font-size:11.5px;color:var(--muted)}
.mst-stats b{font-size:15px;font-weight:650;letter-spacing:-.01em}
.ring{margin-left:auto;flex:none}
.stars{color:#e0a43a;font-size:12.5px;font-weight:650}

/* Popover & modal */
.pop{position:absolute;right:0;top:48px;width:320px;max-width:calc(100vw - 24px);background:var(--surface);border:1px solid var(--line);border-radius:18px;box-shadow:var(--shadow-pop);padding:8px;z-index:40}
.pop h4{margin:6px 10px 8px;font-size:13px}
.pop-item{display:flex;gap:10px;padding:10px;border-radius:12px;align-items:flex-start;font-size:12.5px;color:var(--ink-2)}
.pop-item:hover{background:var(--surface-2)}
.pop-item i{width:8px;height:8px;border-radius:50%;margin-top:5px;flex:none}
.overlay{position:fixed;inset:0;z-index:60;background:rgba(15,22,19,.45);backdrop-filter:blur(4px);display:flex;align-items:center;justify-content:center;padding:20px}
.modal{width:min(760px,100%);max-height:calc(100vh - 40px);overflow:auto;background:var(--surface);border-radius:28px;box-shadow:var(--shadow-pop);border:1px solid var(--line)}
.modal-head{display:flex;justify-content:space-between;align-items:center;padding:18px 22px 0}
.modal-head h3{margin:0;font-size:20px;letter-spacing:-.02em}
.modal-body{padding:16px 22px 22px}
.svc-detail{display:grid;grid-template-columns:260px minmax(0,1fr);gap:20px}
.svc-detail .svc-art{margin:0;aspect-ratio:1/1}
.facts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:12px 0}
.fact{padding:12px 14px;border-radius:16px;background:var(--surface-2)}
.fact small{display:block;color:var(--muted);font-size:12px}
.fact b{font-size:18px;letter-spacing:-.02em}
.form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.form label{display:flex;flex-direction:column;gap:6px;font-size:12.5px;color:var(--muted);font-weight:550}
.form .full{grid-column:1/-1}
.form input,.form select{height:42px;border-radius:12px;border:1px solid var(--line-2);background:var(--surface-2);padding:0 12px;font-size:14px;color:var(--ink)}
.form-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:16px}
.toast{position:fixed;left:50%;bottom:24px;transform:translateX(-50%);background:var(--ink);color:var(--surface);padding:11px 16px;border-radius:999px;font-size:13px;font-weight:600;z-index:80;box-shadow:var(--shadow-pop)}
.foot{margin-top:28px;font-size:12px;color:var(--faint);text-align:center}

/* Responsive */
@media(max-width:1280px){.g-hero{grid-template-columns:repeat(3,minmax(0,1fr))}.g-hero .welcome{grid-column:1/-1}.g-6{grid-template-columns:repeat(3,minmax(0,1fr))}.search{width:160px}}
@media(max-width:1080px){.g-2-1,.g-1-1{grid-template-columns:1fr}.user .u-text{display:none}.user{padding:4px}}
@media(max-width:900px){
  .shell{grid-template-columns:1fr}.rail{display:none}
  .topbar{flex-wrap:wrap;padding:12px 16px;gap:10px}
  .pills{order:3;width:100%}
  .search{display:none}
  .content{padding:4px 16px 40px}
  .g-4{grid-template-columns:repeat(2,minmax(0,1fr))}
  .svc-detail{grid-template-columns:1fr}.svc-detail .svc-art{aspect-ratio:16/10}
}
@media(max-width:640px){
  .g-hero,.g-6{grid-template-columns:repeat(2,minmax(0,1fr))}
  .g-hero .card{padding:14px}
  .kpi-value{font-size:24px}.g-6 .kpi-value{font-size:20px}
  .spark{width:80px}
  .welcome h1{font-size:32px}
  .page-head h1{font-size:28px}
  .card{padding:16px;border-radius:22px}
  .catalog{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .svc-body{padding:10px 12px 12px}.svc-name{font-size:13.5px}.svc-cat{display:none}
  .tbl{font-size:12px}.tbl th,.tbl td{padding:9px 5px}
  .tbl .hide-sm{display:none}
  .heat{grid-template-columns:24px repeat(12,minmax(0,1fr));gap:2px}.heat .c{min-height:14px;border-radius:4px}
  .form{grid-template-columns:1fr}
  .brand b{font-size:17px}
  .top-actions .btn-primary span{display:none}.top-actions .btn-primary{padding:0 12px}
  .facts{grid-template-columns:1fr 1fr}
}
@media(max-width:380px){.g-hero,.g-6,.g-4{grid-template-columns:1fr}.catalog{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}

.track,.fill{display:block}
.svc-top{flex-direction:column;align-items:flex-start;gap:6px}
.svc-cat{order:-1}
.kpi-foot .spark{width:46%;max-width:150px;height:44px}
.g-6 .kpi-foot{align-items:center}
.g-6 .kpi-foot .spark{width:56%;height:34px}
@media(max-width:640px){.g-hero>.card:last-child{grid-column:1/-1}.svc-load .lbl span{font-size:11px}}
.kpi-chart{flex:1;display:flex;align-items:flex-end;min-height:56px;margin:4px -4px 0}
.kpi-chart .spark{width:100%!important;max-width:none!important;height:64px!important}
.low-list{flex:1;display:flex;flex-direction:column;gap:8px;margin-top:6px}
.low-item{display:flex;align-items:center;gap:10px;font-size:13px;font-weight:600;line-height:1.2}
.low-item small{display:block;font-weight:500;color:var(--rose);font-size:12px;margin-top:2px}
.low-thumb{width:40px;height:40px;border-radius:12px;overflow:hidden;flex:none}
.low-thumb svg{width:100%;height:100%;display:block}
/* layering: rail tooltips above content */
.rail{z-index:35}
.rail-btn .tip{z-index:50}
/* topbar fit on mid-size screens */
.user b,.user small{white-space:nowrap}
.pills{flex:0 1 auto}
@media(max-width:1480px){.user .u-text{display:none}.user{padding:4px}}
@media(max-width:1360px){
 .search{width:40px;padding:0;justify-content:center;transition:width .2s}
 .search input,.search kbd{display:none}
 .search:focus-within{width:180px;padding:0 10px 0 12px;justify-content:flex-start}
 .search:focus-within input{display:block}
 .topbar{gap:12px}
}
@media(max-width:1160px){.top-actions .btn-primary span{display:none}.top-actions .btn-primary{padding:0 12px}}
.mst-stats b{white-space:nowrap;font-size:14px}
.mst-top>span:nth-child(2){min-width:0}
.mst-top b{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
@media(max-width:1060px){.topbar{flex-wrap:wrap;row-gap:10px}.pills{order:3;width:100%;flex:1 1 100%}}

.mst-top b{white-space:normal;overflow:visible;line-height:1.2}.mst-top small{display:block;line-height:1.3;margin-top:2px}.mst-top .stars{display:block;margin-top:2px}.mst-top .ring{width:48px;height:48px}
.logo{background:linear-gradient(140deg,var(--fern) 10%,var(--fern-2) 55%,var(--peach))}
