
:root{--nav:#0d1733;--nav-soft:#243457;--bg:#f6f8fb;--white:#fff;--ink:#1c2942;--muted:#78869e;--border:#e6ebf3;--accent:#5368ee;--a-soft:#eef1ff;--teal:#15b7a0;--orange:#b5822c}
*{box-sizing:border-box}html,body{margin:0;min-height:100%;background:var(--bg);color:var(--ink);font-family:Inter,"Segoe UI",Arial,sans-serif;font-size:13px}
button,input,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.48;cursor:not-allowed}input,select,button{outline-offset:2px}
.layout{min-height:100vh;display:flex}.sidebar{width:258px;min-width:258px;background:var(--nav);color:#cbd5e7;height:100vh;position:sticky;top:0;display:flex;flex-direction:column;padding:27px 16px;z-index:4}
.brand{display:flex;align-items:center;gap:12px;margin:0 7px 30px}.logo{width:41px;height:41px;background:linear-gradient(145deg,#6c77fc,#34bebe);border-radius:12px;display:grid;place-items:center;color:white;font-size:24px;font-weight:800}.brand-name b{display:block;font-size:19px;letter-spacing:1.1px;color:white}.brand-name small{display:block;font-size:9px;letter-spacing:1.3px;color:#8c9dbb;margin-top:4px}
.side-search{display:flex;gap:8px;align-items:center;background:#202f50;border:1px solid #283a5f;border-radius:9px;color:#8da1c8;padding:0 11px}.side-search input{background:none;color:white;border:0;width:100%;min-width:0;padding:12px 2px;font-size:12px}.side-search input::placeholder{color:#8599bc}
.side-title{color:#647a9e;font-size:10px;font-weight:800;letter-spacing:1.5px;display:flex;justify-content:space-between;padding:29px 11px 12px}.side-title span{color:#b1c1e2}
.datasets{flex:1;overflow:auto;min-height:110px}.side-empty{padding:12px 11px;color:#8b9fbe;font-size:11px;line-height:1.6}.dataset-item{background:none;display:block;color:#bfcee4;border:0;text-align:left;width:100%;border-radius:9px;padding:12px 11px;margin:3px 0}.dataset-item:hover,.dataset-item.active{background:#283957;color:white}.dataset-item b{display:block;font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:195px}.dataset-item small{display:block;color:#93a8c8;font-size:10px;margin-top:6px}.dataset-item.active{box-shadow:inset 3px 0 #647af4}.side-create{background:#35477e;border:1px solid #475a93;color:white;border-radius:9px;padding:12px;margin:12px 0;font-weight:750}.side-bottom{padding:14px 9px 0;border-top:1px solid #2c3b5b;color:#b2c2e1;font-size:10.5px;line-height:1.9}.side-bottom div{color:#8195bb}.status-dot{display:inline-block;width:7px;height:7px;background:#3ec7aa;border-radius:50%;margin-right:6px}
.main{flex:1;min-width:0}.topbar{display:flex;justify-content:space-between;align-items:center;background:var(--white);border-bottom:1px solid var(--border);height:76px;padding:0 34px;gap:12px}.breadcrumb{font-size:12px;color:#8491a7}.breadcrumb i{color:#b6bed0;margin:0 10px;font-style:normal}.breadcrumb strong{color:#3b4b68}
.top-actions{display:flex;gap:11px;align-items:center}.top-actions select{border:1px solid var(--border);border-radius:8px;padding:9px 10px;color:#52617e;background:white}.status{font-weight:700;color:#64728b;border:1px solid var(--border);border-radius:99px;padding:8px 12px;font-size:10px;letter-spacing:.3px}
.content{padding:30px 34px 50px;max-width:1720px;margin:auto}.heading{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin-bottom:26px}.eyebrow{font-size:10px;letter-spacing:1.7px;font-weight:850;color:#8998af}.heading h1{font-size:28px;letter-spacing:-.8px;margin:8px 0 7px}.heading p{margin:0;color:var(--muted);line-height:1.5}.heading-actions{display:flex;gap:10px;align-items:center}
.btn{border:1px solid #dde4ee;border-radius:9px;padding:11px 15px;white-space:nowrap;display:inline-flex;align-items:center;justify-content:center;gap:8px;background:white;color:#32425e;font-size:12px;font-weight:770;text-decoration:none}.btn:hover:not(:disabled){filter:brightness(.965)}.btn.primary{background:var(--accent);border-color:var(--accent);color:white}.btn.light{background:#f5f7fc}.btn.auth{background:#eef1ff;color:#5166dc;border-color:#eef1ff}
.stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;margin-bottom:21px}.stat{background:white;border:1px solid var(--border);border-radius:15px;padding:19px 22px;min-height:125px;box-shadow:0 5px 22px #18295006}.stat>span{color:#7e8aa1;font-size:11px;font-weight:720}.stat strong{display:block;font-size:27px;margin:12px 0 5px;letter-spacing:-.9px}.stat small{color:#929fb3;font-size:10px}
.panel{background:white;border:1px solid var(--border);border-radius:15px;box-shadow:0 5px 22px #18295006}.table-panel{padding:19px 19px 15px}.tablebar{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.global-search{flex:1;max-width:590px;min-width:250px;display:flex;align-items:center;gap:8px;padding:0 13px;border:1px solid #dee6f0;border-radius:9px;color:#9babbe}.global-search input{border:0;background:none;padding:12px 0;outline:none;width:100%;color:#30415e}.table-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.table-actions select{padding:10px;border:1px solid #e2e8f1;border-radius:9px;color:#536581;background:white}
.results{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:17px 0 11px;font-size:12px;color:#64738e}.results b{color:#23344e;font-size:16px}.results #searchNote{margin-left:auto;color:#9baaaf;font-size:10px}
.table-wrap{min-height:270px;max-height:calc(100vh - 375px);overflow:auto;border:1px solid #e8ecf4;border-radius:11px}.empty{text-align:center;min-height:265px;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:30px;color:#7c89a2}.empty-icon{width:66px;height:66px;background:#f0f3fc;display:grid;place-items:center;border-radius:19px;font-size:29px;color:#7587e8}.empty h3{font-size:15px;color:#314364;margin:12px 0 7px}.empty p{margin:0;line-height:1.6}
table{width:100%;border-collapse:separate;border-spacing:0;min-width:950px;text-align:left;white-space:nowrap}th,td{border-bottom:1px solid #edf1f5;padding:12px 12px;font-size:12px;vertical-align:middle}thead th{position:sticky;top:0;z-index:2;background:#f7f9fd;color:#687b99;font-size:10px;text-transform:uppercase;letter-spacing:.4px;font-weight:800;cursor:pointer;user-select:none}thead th:hover{color:var(--accent)}thead tr.filters th{top:40px;background:#fcfdff;cursor:auto;padding:7px 8px}thead input{border:1px solid #e2e8f2;padding:8px;border-radius:7px;font-size:11px;width:100%;min-width:90px;max-width:230px;background:white;font-weight:400;letter-spacing:0;text-transform:none;color:#30415e;outline:0}thead input:focus{border-color:#6b7deb}td{color:#3e4d65}tbody tr:hover{background:#fafbff}tbody tr:last-child td{border-bottom:0}.row-num{font-variant-numeric:tabular-nums;color:#a1aec1}.email-cell{font-weight:750;color:#233a6a}.file-ref{font-weight:650;color:#5c70b6}.sortmark{font-size:11px;color:#b0bcdb}.warn{font-size:11px;color:#a16e29}
.table-footer{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:15px 2px 2px}.pagination-label{font-size:11px;color:#8390a6}.pager{display:flex;align-items:center;gap:9px}.pager span{color:#586984;font-weight:750}
.footnote{color:#9aa5b6;font-size:11px;margin:18px 3px}
.overlay{display:none;position:fixed;inset:0;background:#0b1635ab;z-index:50;align-items:center;justify-content:center;padding:12px}.overlay.open{display:flex}.import-drawer,.auth-modal{background:white;border-radius:17px;box-shadow:0 25px 80px #0c1a4066}.import-drawer{max-width:720px;width:100%;padding:26px;max-height:94vh;overflow:auto}.drawer-head{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}.drawer-head h2{margin:6px 0;font-size:22px}.drawer-head p{margin:0 0 20px;color:#7c8ca5}.icon-btn{width:34px;height:34px;border:1px solid #e4e9f2;background:#fff;border-radius:9px;cursor:pointer;color:#687b94}
.dropzone{text-align:center;padding:26px;border:2px dashed #bbc8e9;border-radius:13px;background:#f8faff;cursor:pointer}.dropzone.drag{background:#eef2ff;border-color:#5b6fff}.upload-icon{font-size:31px;color:#6a7ee4}.dropzone h3{margin:3px 0 6px}.dropzone p{font-size:11px;color:#8b99b0;margin:0 0 12px}.file-details{margin-top:13px;border:1px solid #e4e9f1;background:#fbfcff;padding:12px;border-radius:9px;font-size:11px;line-height:1.7;word-break:break-word}.file-details strong{color:#3d5376}
.fieldrow{margin:15px 0}.fieldrow label{display:block;font-size:11px;color:#657792;margin-bottom:6px;font-weight:750}.fieldrow input{width:100%;border:1px solid #dae2f0;padding:12px;border-radius:9px;color:#31415b}.mapping{display:flex;gap:12px;flex-wrap:wrap;margin-bottom:16px}.mapping label{font-size:11px;color:#6c7d98}.mapping select{margin:5px 0;border:1px solid #dfe6f0;background:white;padding:9px;border-radius:8px;min-width:150px}.notice{font-size:11px;color:#907029;background:#fffaf0;border:1px solid #f6e8cf;padding:11px 13px;border-radius:9px;line-height:1.6}.import-controls{display:flex;gap:9px;margin:18px 0;flex-wrap:wrap}
.import-progress{border-top:1px solid #edf0f5;padding-top:17px}.progress-top{display:flex;justify-content:space-between;gap:10px;color:#5a6984}.progress-track{height:9px;border-radius:20px;overflow:hidden;background:#e9eef6;margin:12px 0}.progress-track>div{height:100%;width:0%;background:linear-gradient(90deg,#5b73ef,#18bea2);transition:width .2s}.progress-metrics{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.progress-metrics>div{border:1px solid #e7ebf4;padding:10px;border-radius:9px}.progress-metrics span{color:#95a1b3;font-size:10px;display:block;margin-bottom:8px}.progress-metrics b{font-size:17px}.import-progress>p{font-size:11px;line-height:1.6;color:#957128}
.auth-modal{max-width:420px;width:100%;padding:27px}.auth-heading{text-align:center}.auth-heading .logo{margin:0 auto 10px}.auth-heading h2{margin:0;font-size:20px}.auth-heading p{margin:9px 0 19px;color:#798ba5;line-height:1.55}.auth-modal label{display:block;font-size:11px;color:#566c8b;font-weight:750;margin:11px 0 6px}.auth-modal input{width:100%;border:1px solid #dce4f1;border-radius:9px;padding:11px}.auth-hint{font-size:10px;color:#9aabc0;line-height:1.6}.auth-error{min-height:15px;color:#c44e55;font-size:12px;margin:11px 0}.auth-actions{display:flex;gap:7px;flex-wrap:wrap}
.toast{position:fixed;bottom:22px;right:22px;background:#17284a;color:white;border-radius:10px;padding:13px 16px;z-index:100;display:none;box-shadow:0 12px 36px #121e404d;max-width:360px;font-size:12px;line-height:1.5}.toast.show{display:block}
[dir=rtl] .sidebar .dataset-item{text-align:right}[dir=rtl] table{text-align:right}[dir=rtl] .results #searchNote{margin-right:auto;margin-left:0}
@media(max-width:1120px){.sidebar{width:210px;min-width:210px}.content{padding:25px 22px}.topbar{padding:0 22px}.status{display:none}}
@media(max-width:760px){.layout{display:block}.sidebar{width:100%;min-width:0;height:auto;position:sticky;top:0;padding:10px;flex-direction:row;gap:7px;align-items:center;overflow:auto}.brand{margin:0 7px 0 0;flex:none}.brand .logo{width:31px;height:31px;font-size:15px}.brand-name b{font-size:13px}.brand-name small,.side-title,.side-bottom,.side-search{display:none}.datasets{display:flex;min-height:0;overflow:auto;gap:3px}.dataset-item{width:auto;min-width:110px;padding:8px 10px;margin:0}.dataset-item b{font-size:11px;max-width:125px}.dataset-item small{display:none}.side-create{white-space:nowrap;padding:8px;margin:0;font-size:11px}.topbar{height:63px;padding:0 14px}.breadcrumb{font-size:10px}.top-actions select{font-size:11px;padding:8px}.top-actions .btn{padding:8px;font-size:10px}.content{padding:18px 13px}.heading{align-items:flex-start;flex-wrap:wrap}.heading h1{font-size:24px}.stats{grid-template-columns:1fr 1fr}.stats .stat:last-child{grid-column:span 2}.table-panel{padding:12px}.table-wrap{max-height:65vh}.global-search{max-width:none;width:100%}.table-actions{width:100%}.tablebar{gap:7px}.import-drawer{padding:18px}.progress-metrics b{font-size:14px}}
@media(max-width:450px){.heading-actions{width:100%}.heading-actions .btn{flex:1}.stats{grid-template-columns:1fr}.stats .stat:last-child{grid-column:auto}.import-controls .btn{flex:1}.progress-metrics{grid-template-columns:1fr 1fr}.pagination-label{display:none}}
@media print{.sidebar,.topbar,.heading-actions,.tablebar,.table-footer,.footnote,.overlay,.toast{display:none!important}.content{padding:0}.table-wrap{max-height:none;overflow:visible}.panel,.stat{box-shadow:none}}
