:root{color-scheme:dark;--bg:#080e16;--panel:#101a27;--card:#152232;--card2:#1b2b3e;--gold:#e4bb75;--gold2:#b78a43;--line:#344253;--text:#f1eadd;--muted:#96a6b6;--green:#65d2a0;--red:#f19d99;--blue:#8bbdf1;font-family:Georgia,'Times New Roman',serif}
*{box-sizing:border-box}html,body,#app{margin:0;width:100%;min-height:100%;background:var(--bg);color:var(--text)}button,input,textarea,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.48;cursor:not-allowed}a{color:var(--gold)}.boot{padding:25vh 2rem;text-align:center;color:var(--gold);font-size:24px}.app-shell{display:grid;grid-template-columns:228px minmax(0,1fr);min-height:100dvh}.sidebar{background:linear-gradient(180deg,#152030 0,#0b131d 90%);border-right:1px solid #3b3327;padding:25px 16px;display:flex;flex-direction:column;gap:18px}.brand{display:flex;align-items:center;gap:12px}.crest{display:grid;place-items:center;min-width:47px;height:47px;background:#1b2735;border:1px solid #c99b51;border-radius:14px;font-size:24px;color:var(--gold)}.brand-title{font-size:15px;font-weight:800;letter-spacing:.07em;color:#f4d395}.brand-sub{font-size:10px;letter-spacing:.13em;color:#9ba9b9;margin-top:5px}.nav-note{color:var(--muted);font-size:11px;letter-spacing:.16em;margin-top:20px}.nav-button{width:100%;text-align:left;border:1px solid transparent;background:transparent;border-radius:11px;color:#c4cdd7;padding:13px 12px}.nav-button.active{color:#f5d392;border-color:#9e7843;background:linear-gradient(90deg,#352b20,#192737)}.side-bottom{margin-top:auto;display:grid;gap:12px}.side-small{font-size:12px;color:#91a4b7;line-height:1.7}.work{min-width:0}.header{height:84px;border-bottom:1px solid #2f3d49;background:#0e1723;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:0 28px}.header h1{margin:0;font-size:24px;color:#f2d297;letter-spacing:.01em}.header small{display:block;color:var(--muted);font-size:11px;margin-bottom:5px}.top-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.pill{display:inline-flex;align-items:center;gap:7px;border:1px solid #4b5661;border-radius:999px;background:#1b2a3b;padding:8px 13px;font-size:12px;color:#e6dcd0}.dot{width:7px;height:7px;background:var(--green);border-radius:50%;display:inline-block}.dot.off{background:#e8b064}.btn{border:1px solid #5a5144;color:#f7dba3;background:#192636;padding:10px 14px;border-radius:10px;transition:background .15s}.btn:hover{background:#2a3848}.btn.primary{background:linear-gradient(100deg,#b98640,#f0ce8b);color:#24190e;border:0;font-weight:700}.btn.danger{border-color:#78413f;color:#efb6ac}.main{padding:22px 28px}.kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:16px}.kpi{background:linear-gradient(160deg,#162334,#111b29);border:1px solid #324357;border-radius:15px;padding:15px}.kpi small{display:block;color:#a7b3c0;font-size:12px}.kpi strong{display:block;font-size:26px;color:#e9bd72;margin-top:6px}.dashboard{display:grid;grid-template-columns:300px minmax(280px,1fr) 248px;gap:14px;align-items:stretch;min-height:calc(100dvh - 265px)}.panel{border:1px solid #34475d;background:#111b2a;border-radius:15px;min-width:0;overflow:hidden;display:flex;flex-direction:column}.panel-head{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:17px;border-bottom:1px solid #2c3c4d}.panel-head h2{margin:0;color:#efcea0;font-size:16px}.muted{color:var(--muted)}.input,select,textarea{width:100%;border:1px solid #44536a;border-radius:10px;background:#0b1522;color:#f4ede2;padding:11px 12px;outline:0;min-width:0}.input:focus,select:focus,textarea:focus{border-color:var(--gold)}.search-wrap{display:grid;gap:10px;padding:14px}.thread-list{overflow:auto;flex:1;max-height:calc(100dvh - 400px)}.thread{display:flex;width:100%;text-align:left;gap:12px;border:0;border-bottom:1px solid #27394b;background:transparent;padding:15px 14px;color:var(--text)}.thread:hover,.thread.selected{background:#233348}.thread.selected{border-left:3px solid var(--gold);padding-left:11px}.avatar{background:#364052;border:1px solid #a38a65;border-radius:13px;width:40px;min-width:40px;height:40px;display:grid;place-items:center;color:#f2d6a2;font-weight:700;font-size:18px}.thread-info{min-width:0;flex:1}.thread-info strong{font-size:14px}.thread-info small{display:block;font-size:11px;color:#9aa9b9;margin-top:6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.unread{border-radius:99px;background:#d7a95a;color:#22180d;padding:3px 7px;font-size:11px;font-weight:bold}.badge{border:1px solid #426351;color:#77d2a2;background:#1b322c;border-radius:999px;padding:4px 8px;font-size:10px}.badge.closed{border-color:#565f6c;color:#a4b0bf;background:#1c2835}.conv-head{display:flex;align-items:center;justify-content:space-between;gap:9px;padding:17px;border-bottom:1px solid #344357}.conv-title{font-weight:700;color:#f2d199;font-size:18px}.conv-head small{display:block;margin-top:7px;font-size:11px;color:var(--muted)}.messages{flex:1;overflow:auto;min-height:320px;max-height:calc(100dvh - 480px);padding:20px 18px;display:flex;flex-direction:column;gap:16px;background:radial-gradient(ellipse at 80% 0,#1a2b41 0,transparent 56%),#111b28}.bubble{max-width:85%;border-radius:15px 15px 15px 3px;background:#24354b;padding:12px 14px;align-self:flex-start;white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.55;font-size:13px}.bubble.staff{align-self:flex-end;background:#463a28;border:1px solid #866a3d;border-radius:15px 15px 3px 15px}.bubble-head{display:flex;justify-content:space-between;gap:12px;margin-bottom:7px;color:#ddc7a3;font-size:11px}.bubble time{color:#acb6c4;font-size:10px}.bubble p{margin:0}.bubble .manage{display:flex;gap:10px;margin-top:9px}.bubble .manage button{background:transparent;border:0;color:#deb774;font-size:11px;padding:2px}.composer{padding:14px 18px;border-top:1px solid #3a4450;background:#132031}.composer textarea{height:73px;resize:vertical;min-height:70px}.composer-actions{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:10px}.shortcuts{display:flex;gap:7px;flex-wrap:wrap;padding:10px 0}.shortcut{font-size:11px;border:1px solid #344353;background:#1e3042;color:#d3c5b2;border-radius:999px;padding:7px 10px}.customer{padding:20px;display:grid;gap:13px;align-content:start}.customer-avatar{width:64px;height:64px;background:#423927;color:#ffdf97;border:1px solid #b18a4b;font-size:27px;border-radius:17px;display:grid;place-items:center}.info-row{border-bottom:1px solid #2b3b4b;padding-bottom:13px}.info-row small{color:#95a6b9;display:block;margin-bottom:7px}.info-row div{font-size:13px;overflow-wrap:anywhere}.empty{margin:auto;max-width:390px;padding:30px;color:#a4b4c5;text-align:center;line-height:1.7}.error,.feedback{color:#f3b8a8;font-size:12px;line-height:1.5;min-height:1.4em}.feedback.ok{color:#8ae5ad}.login-page{min-height:100dvh;display:grid;place-items:center;padding:20px;background:radial-gradient(circle at 50% 0,#263344 0,transparent 48%),#0a111c}.login-card{max-width:435px;width:100%;padding:32px;border-radius:20px;background:#131e2d;border:1px solid #8b6b40;box-shadow:0 25px 80px #0007}.login-card h1{color:#f0c982;font-size:28px;margin:20px 0 8px}.login-card p{color:#a7b5c5;font-size:13px;line-height:1.7}.field{display:block;color:#e6cfad;font-size:13px;margin-top:15px}.field input{margin-top:7px}.login-card button{margin-top:19px;width:100%;height:43px}.demo-banner{background:#2d2419;color:#ead5aa;border:1px solid #947042;padding:10px 16px;font-size:12px;text-align:center;line-height:1.5}.toast{position:fixed;right:18px;bottom:18px;background:#243244;border:1px solid #b58b4d;border-radius:12px;padding:12px 18px;box-shadow:0 10px 45px #0008;z-index:50;max-width:350px;font-size:13px}.toolbar{display:flex;gap:6px;flex-wrap:wrap}.mobile-back{display:none}.footer-note{margin-top:15px;color:#798c9f;font-size:11px}.access-error{padding:13px;color:#ecc1a8;border:1px solid #8c5143;border-radius:12px;background:#42262042}.language{width:auto;max-width:140px;min-width:92px;padding:8px;font-size:12px}.small-link{background:none;color:#f0c788;border:none;padding:5px;text-decoration:underline}.no-scroll{overflow:hidden}
@media(max-width:1250px){.dashboard{grid-template-columns:280px minmax(240px,1fr)}.customer-panel{display:none}}
@media(max-width:880px){.app-shell{grid-template-columns:1fr}.sidebar{display:none}.main{padding:14px}.header{height:auto;min-height:82px;padding:16px;align-items:flex-start;flex-direction:column}.header h1{font-size:21px}.kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard{grid-template-columns:1fr;min-height:calc(100dvh - 255px)}.list-panel{min-height:400px}.dashboard.show-detail .list-panel{display:none}.dashboard:not(.show-detail) .chat-panel{display:none}.dashboard.show-detail .chat-panel{min-height:68dvh}.thread-list{max-height:none}.messages{max-height:none;min-height:42dvh}.mobile-back{display:inline-flex}.top-actions{width:100%}.header .pill{font-size:11px}.login-card{padding:24px}}
