:root{font-family:Arial,sans-serif;color:#dce6f4;background:#0b0e14;font-size:13px}*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button{cursor:pointer;background:#23364b;color:#fff;border:1px solid #40556c;border-radius:5px;padding:8px}button:hover{filter:brightness(1.2)}button:disabled{opacity:.3;cursor:not-allowed}input,select{background:#111c2b;color:#fff;border:1px solid #34485d;border-radius:5px;padding:8px;min-width:0}input[type=color]{width:58px;height:34px;padding:2px}h1{font-size:19px;margin:0;color:#8193ac}h2{font-size:16px;margin:0 0 12px}h3{margin:8px 0}.shell{max-width:1300px;margin:auto;padding:14px}.top,.bar,.flex{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.top{justify-content:space-between;margin-bottom:12px}.bar,.panel{background:#10151d;border:1px solid #1f2a3a;border-radius:7px;padding:10px;margin-bottom:10px}.spacer{flex:1}.muted{color:#8493a8}.cyan{color:#00e5ff}.green{color:#2ecc71}.red{color:#e74c3c}.pill{background:#18283b;border:1px solid #26384e;border-radius:5px;padding:7px}.gridhead,.charrow{display:grid;grid-template-columns:60px 60px minmax(150px,1.8fr) 55px 48px 90px 80px 60px 75px 85px;gap:5px;align-items:center;min-width:820px;padding:5px;text-align:center}.gridhead{background:#0f1a2a;font-weight:bold}.charrow{border-radius:4px;margin:2px 0;min-height:36px}.charrow button{padding:5px 2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.charrow select{padding:5px 1px;width:100%}.scroll{overflow:auto;max-height:calc(100vh - 230px);min-height:240px;background:#0d0d0d}.copied{background:#ffa000!important;color:#000!important}.copiedName{background:#fff176!important;color:#000!important;border:2px solid #fff9c4}.on{background:#2e7d32;padding:6px;border-radius:4px}.off{background:#b71c1c;padding:6px;border-radius:4px}.filter{font-weight:bold}.filter.inactive{background:#1a1f28!important;color:#69778a!important}.danger{background:#800e15}.primary{background:#235781}.auth{max-width:420px;margin:12vh auto;padding:25px;background:#101722;border:1px solid #26364c;border-radius:12px}.auth input{width:100%;margin:7px 0 14px}.auth button{width:100%}.error{color:#ff8888;margin:10px 0}.success{color:#78e7a2}.tabs{display:flex;gap:6px;margin-bottom:12px}.tabs button.active{background:#235781}.adminGrid{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:12px}.card{padding:12px;border:1px solid #29394d;border-radius:8px;background:#111c29}.card input{max-width:100%}.stack{display:flex;flex-direction:column;gap:8px}.check{display:inline-flex;align-items:center;gap:5px;margin:3px 8px 3px 0}.check input{width:auto}.logwrap{overflow:auto;max-height:350px}table{width:100%;border-collapse:collapse}td,th{padding:8px;border-bottom:1px solid #293444;text-align:left}dialog{background:#121b29;color:white;border:1px solid #3a526b;border-radius:8px;max-width:min(95vw,560px);width:100%}dialog::backdrop{background:#000a}.formgrid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.formgrid label{display:flex;flex-direction:column;gap:4px}.formgrid input{width:100%}@media(max-width:600px){.formgrid{grid-template-columns:1fr}.shell{padding:7px}.scroll{max-height:65vh}}

/* V24 compact: 10 columns fit into approximately 880px, with more rows visible. */
.shell{max-width:940px;padding:8px}.top{margin-bottom:7px}.bar,.panel{padding:6px 8px;margin-bottom:6px}.bar button{padding:5px 8px}.pill{padding:4px 6px}.tabs{margin-bottom:7px}
.gridhead,.charrow{grid-template-columns:60px 60px minmax(165px,1fr) 50px 45px 90px 75px 55px 70px 85px;gap:3px;min-width:810px;padding:3px 4px}
.gridhead{height:34px}.charrow{min-height:31px;margin:1px 0;height:31px}.charrow button{padding:3px 2px;height:25px;border-radius:4px}.charrow select{padding:2px 1px;height:25px}.charrow .on,.charrow .off{padding:4px 2px}.scroll{max-height:calc(100vh - 175px)}
/* Accessible color editor with named swatches, real color pickers and hex previews. */
.color-editor{display:grid;gap:9px}.color-group{border:1px solid #33465b;border-radius:8px;padding:10px;background:#172334}.color-group-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:8px}.color-preview{min-width:85px;padding:6px 9px;border-radius:5px;text-align:center;border:1px solid #62758a;color:#fff}.color-controls{display:flex;flex-wrap:wrap;gap:8px}.color-field{display:flex;align-items:center;gap:7px;background:#101927;border:1px solid #2e4157;border-radius:6px;padding:5px 7px}.color-field span{min-width:62px;color:#c9d7e7}.color-field input[type=color]{width:43px;min-width:43px;height:32px;padding:2px;cursor:pointer}.color-field code{color:#b8c9df;font-size:11px}

/* V28 — scrollbars compactas, integradas ao tema GilxzTokens. */
:root{color-scheme:dark;--scroll-track:#0c1420;--scroll-thumb:#2c4965;--scroll-hover:#39739c;--scroll-border:#17283b}
html{scrollbar-color:var(--scroll-thumb) var(--scroll-track);scrollbar-width:thin}
/* Todos os contêineres roláveis usam a mesma linguagem visual. */
.scroll,.logwrap,.color-editor,.panel,.card,dialog{scrollbar-color:var(--scroll-thumb) var(--scroll-track);scrollbar-width:thin}
::-webkit-scrollbar{width:9px;height:9px}
::-webkit-scrollbar-track{background:var(--scroll-track);border-radius:8px}
::-webkit-scrollbar-thumb{background:var(--scroll-thumb);border:2px solid var(--scroll-track);border-radius:8px}
::-webkit-scrollbar-thumb:hover{background:var(--scroll-hover)}
::-webkit-scrollbar-corner{background:var(--scroll-track)}
.scroll{overflow:auto;overscroll-behavior:contain;border:1px solid #1d3045;border-radius:6px;scrollbar-gutter:stable}
.logwrap{scrollbar-gutter:stable}
/* Barra horizontal aparece apenas quando a janela for mais estreita que a tabela. */
@media(max-width:850px){.scroll{overflow-x:auto}}

/* V29 - indicador de conexão */
.connection-banner{padding:11px 14px;margin:8px 0;border-radius:7px;border:1px solid #ff5c64;background:#491d27;color:#fff0f0;font-weight:700;text-align:center;position:sticky;top:0;z-index:99;box-shadow:0 2px 12px #0008}
.connection-banner.checking{border-color:#e4b44c;background:#45371c;color:#ffe6a3}
.connection-banner[hidden]{display:none}
button:disabled,select:disabled{opacity:.48;cursor:not-allowed}
