@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');
:root{--ink:#192d3d;--muted:#73818d;--bg:#f4f6f8;--line:#e4e9ed;--teal:#137e70;--nav:#142c3d;--red:#bd5541;--gold:#bc852e;font-family:Manrope,'Noto Sans Thai',system-ui,sans-serif;color:var(--ink);background:var(--bg);font-size:14px}*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,a,input,select,textarea{outline-offset:4px}button,a{touch-action:manipulation}button{cursor:pointer;border:1px solid var(--line);background:white;color:var(--ink);padding:10px 16px;border-radius:9px;font-weight:600}button:hover{filter:brightness(.97)}button:disabled{opacity:.55;cursor:wait}a{color:var(--teal);text-decoration:none}button.primary,.primary{background:var(--teal);border-color:var(--teal);color:white}.danger{background:#b54738;color:#fff;border-color:#b54738}.quiet{background:transparent}.shell{display:grid;grid-template-columns:238px 1fr;min-height:100vh}.sidebar{background:var(--nav);color:#c4d1da;padding:32px 21px;display:flex;flex-direction:column;position:sticky;top:0;height:100vh}.brand{display:flex;align-items:center;gap:11px;font-weight:800;color:inherit;font-size:16px;letter-spacing:-.4px}.brand-icon{display:grid;place-items:center;width:38px;height:42px;background:#229083;color:white;border-radius:10px;font-size:21px}.brand small{display:block;letter-spacing:2px;font-size:9px;font-weight:500;opacity:.55;margin-top:4px}.nav-label{font-size:10px;letter-spacing:1.8px;color:#7f97a6;margin:42px 12px 14px}.nav{display:grid;gap:7px}.nav a{color:#b1c3cf;padding:12px 14px;border-radius:9px;display:flex;justify-content:space-between;align-items:center}.nav a.active{background:#274553;color:#fff;box-shadow:inset 3px 0 #56b8a2}.nav .count{background:#355365;border-radius:5px;padding:1px 7px;font-size:11px}.sidebar-footer{margin-top:auto;padding-top:35px}.secure{font-size:11px;color:#89a697;padding:15px 8px;border-bottom:1px solid #314657;line-height:1.8}.user{display:flex;gap:11px;align-items:center;padding:20px 5px 8px}.avatar{display:grid;place-items:center;border-radius:50%;width:34px;height:34px;background:#dceee7;color:#285949;font-weight:800}.user small{display:block;color:#8ca2b2;font-size:10px}.logout{color:#98adbc;font-size:11px;margin-left:50px}.content{min-width:0}.topbar{height:77px;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 42px;background:#fff}.breadcrumb{font-size:12px;color:var(--muted)}.breadcrumb strong{color:var(--ink);font-weight:500}.lang{display:flex;border:1px solid var(--line);padding:3px;border-radius:8px;gap:3px}.lang button{border:0;background:none;padding:5px 10px;font-size:11px}.lang button.active{background:#e6f2ed;color:var(--teal)}main{max-width:1440px;margin:auto;padding:35px 42px 60px}.heading{display:flex;justify-content:space-between;gap:20px;align-items:center;margin-bottom:29px}.eyebrow{font-size:10px;letter-spacing:1.7px;color:var(--teal);font-weight:800;text-transform:uppercase;margin-bottom:8px}h1{font-size:29px;line-height:1.4;letter-spacing:-.8px;margin:0 0 8px}h2{font-size:17px;margin:0}h3{font-size:14px;margin:0 0 12px}p{line-height:1.8}.subtext{color:var(--muted);margin:0;font-size:12px}.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:18px;margin-bottom:27px}.stat{background:#fff;border:1px solid var(--line);padding:21px 23px;border-radius:12px;position:relative}.stat .label{font-size:12px;color:var(--muted)}.stat strong{font-size:33px;font-weight:800;display:block;margin:10px 0 4px;letter-spacing:-1px}.stat small{color:var(--muted);font-size:10px}.stat.warn{background:#fff9f2;border-color:#efe0cd}.stat.warn strong{color:var(--gold)}.stat-icon{position:absolute;right:20px;top:20px;width:30px;height:30px;border-radius:8px;background:#f0f5f7;text-align:center;line-height:30px;color:#8195a3}.notice{border:1px solid #ecdcc5;background:#fffbf4;border-radius:10px;padding:15px 20px;display:flex;gap:13px;align-items:center;margin-bottom:24px;color:#7f5b26;font-size:12px}.notice a{margin-left:auto;color:#996c25;font-weight:700;white-space:nowrap}.notice.error{border-color:#efc6be;background:#fff3f0;color:#9a3020}.panel{background:white;border:1px solid var(--line);border-radius:13px;overflow:hidden}.panel-title{padding:23px;display:flex;justify-content:space-between;align-items:center;gap:16px;border-bottom:1px solid var(--line)}.panel-title p{margin:5px 0 0;color:var(--muted);font-size:11px}.toolbar{display:flex;gap:12px;padding:20px 23px}.search{flex:1;min-width:130px}.toolbar input,.toolbar select{background:#f9fafb}.table-wrap{overflow-x:auto}table{width:100%;border-collapse:collapse;text-align:left;white-space:nowrap}th{background:#fafbfc;font-size:10px;letter-spacing:.35px;color:var(--muted);font-weight:600;padding:13px 20px;border-block:1px solid var(--line)}td{padding:18px 20px;border-bottom:1px solid #eef1f4;font-size:12px}tr:last-child td{border-bottom:0}tbody tr:hover{background:#f9fbfc}.case-name{font-weight:700;display:block;color:var(--ink);margin:5px 0;max-width:300px;overflow:hidden;text-overflow:ellipsis}.reference{font-size:10px;color:var(--teal);font-weight:800}.company{font-size:10px;color:var(--muted)}.badge{display:inline-flex;align-items:center;gap:6px;border-radius:5px;padding:5px 9px;font-size:10px;font-weight:600;background:#eef3f6;color:#607788}.badge:before{content:'';width:5px;height:5px;border-radius:50%;background:currentColor}.badge.in_progress{background:#eaf0fa;color:#456ca5}.badge.waiting{background:#fff3df;color:#a67b2c}.badge.submitted{background:#f0ebfa;color:#8162a3}.badge.closed{background:#e9f3ed;color:#548365}.priority{font-size:10px}.priority.urgent{color:#ba5749}.priority.high{color:#ad8339}.muted{color:var(--muted)}.stale-text{color:#b18037;font-size:10px;display:block;margin-top:5px}.table-footer{padding:17px 23px;color:var(--muted);font-size:11px;border-top:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;gap:10px}.table-footer button{padding:5px 12px}.empty{text-align:center;padding:58px 20px;color:var(--muted);line-height:1.9}.empty strong{display:block;color:var(--ink);font-size:17px;margin-bottom:7px}.back{display:inline-block;color:var(--muted);font-size:12px;margin-bottom:20px}.detail-grid{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:22px}.pad{padding:24px}.detail-grid .panel{margin-bottom:20px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}.full{grid-column:1/-1}label{font-size:12px;font-weight:600;display:grid;gap:8px}input,select,textarea{width:100%;border:1px solid #dce3e7;background:#fff;border-radius:7px;padding:10px 12px;color:var(--ink);min-height:42px}textarea{resize:vertical;min-height:110px}small.hint,label small{font-size:10px;color:var(--muted);font-weight:400;line-height:1.7}.actions{display:flex;gap:10px;justify-content:flex-end;margin-top:20px;align-items:center}.event{position:relative;padding:0 0 22px 25px;margin-left:5px;border-left:1px solid var(--line)}.event:last-child{border:0;padding-bottom:0}.event:before{content:'';position:absolute;left:-5px;top:3px;width:9px;height:9px;border-radius:50%;background:#90b9ad;border:2px solid #fff}.event-header{display:flex;justify-content:space-between;gap:12px;font-size:11px}.event p{white-space:pre-wrap;margin:9px 0;color:#4f6371;font-size:12px;overflow-wrap:anywhere}.event time{color:var(--muted);font-size:10px}.event details{font-size:11px;color:var(--muted)}.event pre{white-space:pre-wrap;overflow-wrap:anywhere;font-family:inherit;font-size:10px}.file{display:flex;align-items:center;gap:10px;padding:12px 0;border-bottom:1px solid var(--line)}.file a{min-width:0;overflow-wrap:anywhere;font-size:12px}.file small{display:block;font-size:10px;color:var(--muted);margin-top:3px}.drop-area{padding:18px;border:1px dashed #b5c9c6;background:#f6faf8;border-radius:9px;margin-top:16px}.drop-area input{font-size:11px;border:0;padding:10px 0;background:transparent}.meta{display:grid;gap:17px;font-size:12px}.meta span{display:block;color:var(--muted);font-size:10px;margin-bottom:6px}.close-note{background:#f6f8f9;border-radius:8px;padding:16px;margin-top:20px;font-size:11px;line-height:1.8;color:var(--muted)}.dialog{max-width:580px;width:calc(100% - 32px);border:0;border-radius:15px;padding:27px;box-shadow:0 15px 80px #142c3d30}.dialog::backdrop{background:#152b3e66}.dialog .check{display:flex;align-items:flex-start;gap:10px;margin:20px 0;font-weight:400;line-height:1.7}.check input{width:18px;min-height:18px;margin:3px 0}.toast{position:fixed;bottom:25px;right:25px;max-width:450px;background:#193d35;color:white;box-shadow:0 10px 30px #0002;border-radius:10px;padding:16px 22px;z-index:20;line-height:1.7}.toast.error{background:#963e32}.auth{min-height:100vh;display:grid;grid-template-columns:1fr 1fr}.auth-art{background:var(--nav);color:#fff;padding:60px;display:flex;flex-direction:column;justify-content:space-between}.auth-art h1{font-size:48px;line-height:1.4;max-width:570px}.auth-art p{color:#a3b7c1;max-width:420px}.auth-art footer{color:#7e99a8;font-size:11px}.auth-main{padding:35px;display:flex;flex-direction:column;align-items:center;justify-content:center}.auth-box{max-width:470px;width:100%}.auth-box .lang{width:max-content;margin-left:auto;margin-bottom:42px}.auth-box h2{font-size:25px}.auth-box .login-button{display:block;text-align:center;padding:13px;border-radius:8px;margin:22px 0 15px}.auth-box details{margin-top:28px;border-top:1px solid var(--line);padding-top:24px}.auth-box summary{cursor:pointer;font-weight:600;margin-bottom:20px}.trap{position:absolute;left:-10000px}.loading{text-align:center;padding:100px;color:var(--muted)}.demo-banner{background:#fff1d6;color:#6c5027;text-align:center;padding:8px;font-size:11px}.admin-row{padding:20px 24px;display:flex;justify-content:space-between;align-items:center;gap:16px;border-bottom:1px solid var(--line)}.admin-row small{display:block;color:var(--muted);margin-top:5px}.admin-row .actions{margin:0}.health{display:flex;gap:20px;flex-wrap:wrap;font-size:12px}.health div{flex:1;min-width:180px;line-height:1.8}.health strong{display:block}.status-row{display:flex;gap:10px;align-items:center}.mobile-brand{display:none}
.toolbar select{width:180px;flex:0 0 180px}
.mobile-signout{display:none}
@media(max-width:760px){.mobile-signout{display:block;text-align:center;padding:18px;border-top:1px solid var(--line);font-size:12px}.nav{scrollbar-width:thin;scrollbar-color:#547482 transparent}}
@media(min-width:1500px){main{padding-top:45px}.stats{gap:24px}.stat{padding:26px}.heading{margin-bottom:35px}}
@media(max-width:1100px){.shell{grid-template-columns:195px 1fr}.sidebar{padding:25px 14px}.brand{font-size:13px}.topbar{padding:0 25px}main{padding:28px 25px}.detail-grid{grid-template-columns:1fr}.stats{gap:10px}.stat{padding:16px}.stat-icon{display:none}.stat strong{font-size:28px}.auth-art{padding:40px}.auth-art h1{font-size:36px}}
@media(max-width:760px){.shell{display:block}.sidebar{height:auto;position:static;padding:17px 20px}.sidebar .brand,.nav-label,.sidebar-footer{display:none}.nav{display:flex;overflow:auto;gap:6px}.nav a{padding:9px 12px;font-size:11px;white-space:nowrap;gap:8px}.topbar{height:62px;padding:0 20px}.breadcrumb{display:none}.mobile-brand{display:block;font-size:13px;font-weight:800}main{padding:25px 17px}.heading{align-items:flex-start;gap:12px}.heading h1{font-size:23px}.heading button{font-size:11px;padding:11px;white-space:nowrap}.stats{grid-template-columns:1fr 1fr;gap:10px}.stat{padding:16px}.notice{font-size:11px;padding:14px;flex-wrap:wrap}.notice a{margin-left:25px}.toolbar{padding:15px;flex-wrap:wrap}.toolbar .search{flex-basis:100%}.toolbar select{flex:1;width:auto;max-width:48%}.panel-title{padding:18px}th,td{padding:14px}.form-grid{grid-template-columns:1fr}.full{grid-column:auto}.pad{padding:18px}.auth{display:block}.auth-art{padding:25px}.auth-art>div:nth-child(2),.auth-art footer{display:none}.auth-main{padding:25px}.auth-box .lang{margin-bottom:28px}.admin-row{align-items:flex-start;flex-direction:column}.toast{left:17px;right:17px;bottom:17px}.event-header{flex-direction:column;gap:4px}}
