:root{--teal:#008c9a;--teal2:#00626b;--navy:#061923;--bg:#eef6f8;--tab:#c7c1b5;--border:#222;--head:#eaf6f7;--text:#001a3a}*{box-sizing:border-box}body{margin:0;background:var(--bg);font-family:Arial,Helvetica,sans-serif;color:#00152e;font-size:14px}.login-page{background:#0c2122;min-height:100vh;display:flex;align-items:stretch;justify-content:center}.login-wrap{width:100%;min-height:100vh;background:#0c2122 url('/static/branding/rockfile-login-lion-watermark.png') right center/48% no-repeat;display:flex;align-items:center;padding-left:90px}.login-panel{width:390px;color:#e9ffff}.login-panel img{width:270px;margin-bottom:28px}.login-panel h1{font-size:30px;margin:0 0 12px}.login-panel p{color:#8ec7cb;margin:0 0 28px}.login-panel label{font-weight:700;display:block;margin:12px 0 7px}.login-panel input{width:100%;background:#113c3d;border:1px solid #2a5b5d;color:white;padding:12px}.login-panel button{width:100%;margin-top:16px;background:#008c9a;color:white;border:0;padding:14px;font-weight:bold}.login-chips span{display:inline-block;background:#103c41;color:#3ee1e7;padding:8px 12px;margin:20px 5px 0 0;font-size:12px}.topbar{display:flex;gap:18px;align-items:center;background:#061923;color:white;padding:14px 22px}.topbar img{height:58px;background:white;padding:7px}.topbar h1{font-size:24px;margin:0}.topbar p{font-size:12px;margin:8px 0 0;color:#b7f7ff}.tabs{display:flex;background:#c7c1b5;border-bottom:1px solid #999}.tab{display:block;color:#000;text-decoration:none;font-weight:bold;padding:14px 22px;border-right:1px solid #8f8a80;border-left:1px solid #ddd7cb}.tab:hover,.tab.active{background:#eef6f8}.page{padding:18px}h2{font-size:24px;margin:4px 0 8px}.headerline{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.toolbar,.filterbar,.actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:10px 0}.toolbar input,.filterbar input{height:28px}.btn,button{background:#e0ddd6;border:1px solid #999;color:#000;padding:9px 15px;text-decoration:none;cursor:pointer}button.primary,.primary{background:#008c9a;color:white;border-color:#00626b;font-weight:bold}.danger{background:#b91c1c;color:white}.sub{color:#556987;font-size:13px}.counter{margin-left:auto;color:#556987}.grid,.formgrid{border-collapse:collapse;width:100%;background:white}.grid th,.grid td,.formgrid th,.formgrid td{border:1px solid #a7a7a7;padding:5px 7px;white-space:nowrap}.grid th,.formgrid th{background:#eef9fa;position:sticky;top:0;z-index:2}.grid tr:hover td{background:#eaf4ff}.grid-wrap{overflow:auto;max-height:70vh;border:1px solid #9b9b9b;background:white}.wide{min-width:1800px}.formgrid input,.formgrid select{width:100%;height:26px;border:1px solid #777}.msg{padding:10px;margin:8px 0;border:1px solid}.msg.success{background:#dcfce7;color:#166534}.msg.danger{background:#fee2e2;color:#991b1b}.msg.warning{background:#fef3c7;color:#92400e}.card{background:white;border:1px solid #999;padding:12px;margin:10px 0}.twocol{display:grid;grid-template-columns:repeat(2,1fr);gap:6px 25px}.item-form section{border:1px solid #ccc;margin:10px 0;padding:8px;background:white}.item-form section h3{margin:-8px -8px 8px;padding:5px 8px;background:#edf2ff;font-size:14px}.item-grid{display:grid;grid-template-columns:190px 1fr 190px 1fr;gap:8px 12px}.item-grid label{font-weight:bold;font-size:12px}.item-grid input{width:100%;height:25px}.kpis{display:grid;grid-template-columns:repeat(6,1fr);gap:10px}.kpis div{background:white;border:1px solid #222;border-top:4px solid var(--teal);padding:14px}.kpis b{font-size:28px;display:block}.dashgrid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.barrow{display:grid;grid-template-columns:150px 1fr 140px;align-items:center;gap:8px;margin:10px 0}.bar{height:18px;background:#e2e8f0}.bar span{display:block;height:100%;background:#008c9a}.inline{display:inline}.status-select{width:180px}.desktop-box{border:1px solid #222;padding:14px;background:#f9fbfc}.tabs-mini{display:flex;gap:4px;margin:12px 0}.tabs-mini a{padding:10px 16px;background:#c7c1b5;color:#000;text-decoration:none;border:1px solid #999;font-weight:bold}.tabs-mini a.active{background:#eef6f8}@media(max-width:900px){.kpis,.dashgrid,.twocol{grid-template-columns:1fr}.login-wrap{padding:30px;background-size:80%}.login-panel{width:100%}.topbar h1{font-size:18px}.tabs{overflow-x:auto}.tab{white-space:nowrap}}

/* Ajustes de grid estilo Excel */
.grid-wrap{max-height:calc(100vh - 260px); overflow:auto; border:1px solid #9a9a9a; background:#fff;}
.grid.excel-grid{border-collapse:collapse; width:max-content; min-width:100%; font-size:13px;}
.grid.excel-grid thead th{position:sticky; top:0; z-index:2; background:#eaf5f7; border:1px solid #999; white-space:nowrap;}
.grid.excel-grid thead tr.column-filters th{top:28px; background:#f8ffff;}
.grid.excel-grid thead tr.column-filters input{width:95%; box-sizing:border-box; font-size:12px; border:1px solid #999;}
.grid.excel-grid td{border:1px solid #ddd; white-space:nowrap; padding:4px 7px;}
.grid.excel-grid tbody tr:hover{background:#d7ebf4;}
.grid.excel-grid tbody tr:has(input[type=checkbox]:checked){background:#4f7088; color:white;}
.excelbar select{min-width:160px;}
.inline{display:inline; margin:0;}
.inline select{width:100%; min-width:150px;}

/* Usuário logado no canto superior direito */
.topbar{position:relative;}
.topbar-title{flex:1; min-width:0;}
.user-box{margin-left:auto; min-width:260px; max-width:340px; align-self:stretch; border:2px solid #0aa4ad; background:#071f2a; color:#eaffff; padding:8px 12px; display:flex; flex-direction:column; justify-content:center; font-size:12px; line-height:1.35;}
.user-box .user-name{font-size:14px; font-weight:700; color:#fff; white-space:nowrap; overflow:hidden; text-overflow:ellipsis;}
.user-box .user-meta{color:#b7f7ff; white-space:nowrap; overflow:hidden; text-overflow:ellipsis;}
.user-box .user-actions{margin-top:3px; color:#8ee8ef;}
.user-box a{color:#8ee8ef; text-decoration:none; font-weight:700;}
.user-box a:hover{text-decoration:underline;}
.password-card{max-width:760px;}
.password-grid{grid-template-columns:1fr; max-width:520px;}
.password-grid input{height:32px;}
@media(max-width:900px){.topbar{flex-wrap:wrap}.user-box{width:100%;max-width:none;margin-left:0}.topbar-title{width:100%}}
.login-links{margin-top:12px;font-size:13px}.login-links a{color:#2fd7e5;text-decoration:none}.login-links a:hover{text-decoration:underline}
.user-box{margin-left:auto;text-align:right;color:#fff;border:1px solid rgba(47,215,229,.35);padding:8px 12px;min-width:230px;background:rgba(0,0,0,.18)}.user-name{font-weight:700}.user-meta{font-size:12px;color:#bce7eb}.user-actions a{color:#2fd7e5;text-decoration:none;font-size:12px}

.row-alert{background:#fff7ed!important}.inline-form{display:flex;gap:6px;align-items:center}.inline-form input{height:28px}.excel thead th{position:sticky;top:0;z-index:2}
