/* Preferências visuais do painel; cores de erro, alerta e sucesso permanecem semânticas. */
:root,html[data-gd-theme="azul-executivo"]{--gd-primary:#0B1F5E;--gd-secondary:#22B8FF;--gd-accent:#22B8FF;--gd-background:#F8FAFC;--gd-card:#FFFFFF;--gd-text:#171717;--gd-border:#E2E8F0;--gd-muted:#526276;--gd-hover:#EAF6FF;--gd-focus:#0878B6}
html[data-gd-theme="azul-logotipo"]{--gd-primary:#168FE8;--gd-secondary:#35B8F5;--gd-accent:#35B8F5;--gd-background:#F3F8FD;--gd-card:#FFFFFF;--gd-text:#151515;--gd-border:#DCE7F1;--gd-muted:#526276;--gd-hover:#E7F3FC;--gd-focus:#0965A7}
html[data-gd-theme="rosa-suave"]{--gd-primary:#BE2773;--gd-secondary:#EC4899;--gd-accent:#EC4899;--gd-background:#FFF5FA;--gd-card:#FFFFFF;--gd-text:#171717;--gd-border:#F4D8E8;--gd-muted:#694A5D;--gd-hover:#FCEAF4;--gd-focus:#BE2773}
html[data-gd-theme="apple-soft"]{--gd-primary:#77777D;--gd-secondary:#86868B;--gd-accent:#77777D;--gd-background:#F5F5F7;--gd-card:#FFFFFF;--gd-text:#1D1D1F;--gd-border:#D2D2D7;--gd-muted:#6E6E73;--gd-hover:#E8E8ED;--gd-focus:#55555B}
html[data-gd-theme]{--bg:var(--gd-background);--card:var(--gd-card);--ink:var(--gd-text);--muted:var(--gd-muted);--line:var(--gd-border);--nav:var(--gd-primary);--blue:var(--gd-primary);--cyan:var(--gd-secondary);--violet:var(--gd-secondary)}
html[data-gd-theme] body,html[data-gd-theme] .app,html[data-gd-theme] .main{background:var(--gd-background);color:var(--gd-text)}
html[data-gd-theme] body:before{background:none}
html[data-gd-theme] .top{background:var(--gd-primary)!important;color:#fff;border-bottom:3px solid var(--gd-secondary)}
html[data-gd-theme] .side{background:var(--gd-primary)!important;color:#fff}
html[data-gd-theme] .who{background:rgba(255,255,255,.1);border-color:rgba(255,255,255,.25);color:#fff}
html[data-gd-theme] .who small,html[data-gd-theme] .nav button{color:#fff}
html[data-gd-theme] .nav button:is(.active,:hover){background:rgba(255,255,255,.19);color:#fff;border-left:3px solid var(--gd-accent)}
html[data-gd-theme] :is(.card,.section.card,.category,.service,.sum,.finance-order .sum){background:var(--gd-card)!important;color:var(--gd-text);border-color:var(--gd-border)}
html[data-gd-theme] :is(.metric:after,.category:before){background:none}
html[data-gd-theme] .metric .val,html[data-gd-theme] .finance-order .sum:nth-child(4) b{background:none;color:var(--gd-primary);-webkit-text-fill-color:currentColor}
html[data-gd-theme] .btn:not(.green):not(.red),html[data-gd-theme] .pdf-btn,html[data-gd-theme] .category .tag{background:var(--gd-primary)!important;color:#fff!important;border-color:var(--gd-primary)}
html[data-gd-theme] .btn.secondary:not(.green):not(.red){background:var(--gd-card)!important;color:var(--gd-text)!important;border:1px solid var(--gd-border);box-shadow:none}
html[data-gd-theme] .top .btn.secondary:not(.green):not(.red){background:rgba(255,255,255,.13)!important;color:#fff!important;border-color:rgba(255,255,255,.5)}
html[data-gd-theme] :is(.service.active,.login-profile.active){background:var(--gd-hover)!important;border-color:var(--gd-focus);color:var(--gd-text);box-shadow:0 0 0 2px var(--gd-border)}
html[data-gd-theme] :is(.pagehead h2,.category b,.sum b){color:var(--gd-text)}
html[data-gd-theme] :is(.pagehead p,.muted,.footer,.metric .lab,.metric .sub,.service small,.sum small,.category .n){color:var(--gd-muted)}
html[data-gd-theme] :is(.table-wrap,.table th,.table td){border-color:var(--gd-border);color:var(--gd-text)}
html[data-gd-theme] .table th{background:var(--gd-hover)!important;color:var(--gd-text)}
html[data-gd-theme] .table tbody tr:hover{background:var(--gd-hover)}
html[data-gd-theme] .field label{color:var(--gd-text)}
html[data-gd-theme] :is(.field input,.field select,.field textarea,.login-profile,input:not([type="checkbox"]):not([type="radio"]),select,textarea){background:var(--gd-card)!important;color:var(--gd-text)!important;border-color:var(--gd-border)}
html[data-gd-theme] input::placeholder,html[data-gd-theme] textarea::placeholder{color:var(--gd-muted)}
html[data-gd-theme] :is(button,input,select,textarea,a):focus-visible{outline:3px solid var(--gd-focus)!important;outline-offset:2px}
html[data-gd-theme] :is(.field input,.field select,.field textarea):focus{border-color:var(--gd-focus);box-shadow:0 0 0 3px var(--gd-border)}
html[data-gd-theme] .badge.blue{background:var(--gd-hover);color:var(--gd-text)}
/* Apple Soft: superfícies cinza discretas e texto branco legível nos botões primários. */
html[data-gd-theme="apple-soft"] :is(.top,.side){background:#707076!important}
html[data-gd-theme="apple-soft"] :is(.btn:not(.green):not(.red),.pdf-btn,.category .tag){background:#707076!important;border-color:#707076;color:#FFFFFF!important}
html[data-gd-theme="apple-soft"] .gd-theme-trigger{color:#FFFFFF;border-color:rgba(255,255,255,.65)}
html[data-gd-theme="azul-logotipo"] :is(.btn:not(.green):not(.red),.pdf-btn,.category .tag){background:#0965A7!important;border-color:#0965A7;color:#FFFFFF!important}
html[data-gd-theme="azul-logotipo"] :is(.top,.side){background:#0965A7!important}
.gd-theme-control{position:relative;display:inline-flex;align-items:center;flex:0 0 auto;z-index:60}
.gd-theme-trigger{display:inline-flex;align-items:center;justify-content:center;width:42px;height:42px;border:1px solid rgba(255,255,255,.65);border-radius:12px;background:rgba(255,255,255,.13);color:#fff;font-size:22px;line-height:1;cursor:pointer}
.gd-theme-trigger:hover{background:rgba(255,255,255,.25)}
.gd-theme-menu{position:absolute;top:calc(100% + 8px);right:0;width:min(296px,calc(100vw - 24px));padding:8px;border:1px solid var(--gd-border);border-radius:15px;background:var(--gd-card);box-shadow:0 18px 45px rgba(0,0,0,.24);color:var(--gd-text)}
.gd-theme-menu[hidden]{display:none}
.gd-theme-menu-title{padding:7px 9px 9px;font-weight:800;color:var(--gd-text)}
.gd-theme-option{display:flex;align-items:center;gap:10px;width:100%;padding:10px;border:0;border-radius:10px;background:transparent;color:var(--gd-text);text-align:left;cursor:pointer;font:inherit}
.gd-theme-option:hover,.gd-theme-option:focus-visible,.gd-theme-option[aria-checked="true"]{background:var(--gd-hover)}
.gd-theme-option[aria-checked="true"]{font-weight:800;border-left:3px solid var(--gd-accent)}
.gd-theme-option-label{flex:1;min-width:0}.gd-theme-swatches{display:flex;gap:3px;flex:0 0 auto}
.gd-theme-swatch{width:12px;height:18px;border:1px solid rgba(0,0,0,.18);border-radius:3px}.gd-theme-check{width:16px;text-align:center;font-weight:900}
@media(max-width:760px){.gd-theme-trigger{width:40px;height:40px}.gd-theme-menu{position:fixed;top:70px;right:12px}}
@media(max-width:430px){html[data-gd-theme] .status b{display:none}.gd-theme-trigger{width:36px;height:36px;font-size:19px}html[data-gd-theme] .status .btn{padding:6px 7px;font-size:10px}}
@media print{html[data-gd-theme] body,html[data-gd-theme] .card,html[data-gd-theme] .table th,html[data-gd-theme] .table td{background:#fff!important;color:#000!important}.gd-theme-control{display:none!important}}
