/* ============================================================
   Suprimentos — Patrimônio e Almoxarifado Geral (out/2026)

   Identidade dos modais de prescrição (prescricao-modal.css) levada para a página
   inteira: Inter, tinta azul-marinho, acento azul, cartões de 14px, rótulos em
   caixa-alta miúda, botões .prmd-btn. Os tokens --p-* do modal são redeclarados
   aqui no container da página — então .prmd-btn, .prmd-field, .prmd-flabel e as
   peças .pmod-* (grade, check, seg, tabela, aviso) funcionam DENTRO da página com
   o mesmo desenho que têm dentro do modal. Os modais em si usam o ModalPadrao
   (.prmd.pmod), sem nada novo.

   Layout: container `container-fluid mc-page mc-scaled gsx` (zoom do mc-scale.js,
   desenho de referência 1600px — sem media queries de largura aqui). Modais,
   painel lateral e toast são IRMÃOS do container (zoom em ancestral desloca
   position:fixed) e levam .gs-layer para herdar os tokens.

   Nada aqui usa .table/.card/.btn/.badge: o mc-page.css e o custom-tables.css
   pintam essas classes com !important.

   Camadas: painel lateral 1045, modais 1050 (ModalPadrao), confirmação 1052,
   SweetAlert 1060, toast 1065.
   ============================================================ */

.gsx, .gs-layer {
    /* ---- Tokens do modal de prescrição (tema claro) ---- */
    --p-surface:      #ffffff;
    --p-soft:         #f8fafc;
    --p-soft2:        #f1f5f9;
    --p-border:       #e2e8f0;
    --p-border-soft:  #f1f5f9;
    --p-ink:          #0b1f3a;
    --p-text:         #475569;
    --p-muted:        #64748b;
    --p-faint:        #94a3b8;
    --p-blue:         #1a4a9e;
    --p-blue-light:   #2563eb;
    --p-blue-soft:    #eff6ff;
    --p-blue-line:    #bfdbfe;
    --p-blue-line-soft: #dbeafe;
    --p-red:          #dc2626;
    --p-red-soft:     #fef2f2;
    --p-orange:       #ea580c;
    --p-orange-soft:  #fff7ed;
    --p-orange-line:  #f3cfa6;
    --p-green:        #059669;
    --p-green-soft:   #ecfdf5;
    --p-yellow:       #d97706;
    --p-yellow-soft:  #fffbeb;
    --p-grad-primary: linear-gradient(135deg, var(--p-blue), var(--p-blue-light));
    --p-focus-ring:   0 0 0 3px rgba(37, 99, 235, .18);
    --p-shadow-sm:    0 1px 2px rgba(16,33,64,.06);
    --p-shadow:       0 1px 2px rgba(16,33,64,.04), 0 12px 32px -12px rgba(16,33,64,.12);
    --p-shadow-lg:    0 24px 70px -24px rgba(16,33,64,.28);
    --p-font:         'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --p-mono:         ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    --p-ease:         cubic-bezier(.16,1,.3,1);

    /* ---- Extras de página ---- */
    --gs-bg:          #eef2f7;
    --gs-hover:       #f8fbff;
    --gs-purple:      #7c3aed;
    --gs-purple-soft: #f5f3ff;
    --gs-teal:        #0891b2;
    --gs-teal-soft:   #ecfeff;
    --gs-pink:        #db2777;
    --gs-pink-soft:   #fdf2f8;
    --gs-scrim:       linear-gradient(135deg, rgba(11,31,58,.55), rgba(30,58,95,.42));

    font-family: var(--p-font);
    color: var(--p-text);
    -webkit-font-smoothing: antialiased;
}

/* Tema escuro do sistema — mesmos valores do bloco escuro de prescricao-modal.css. */
[data-theme-mode="dark"] :is(.gsx, .gs-layer) {
    --p-surface:      #0f1a1f;
    --p-soft:         #15242a;
    --p-soft2:        #1c2e35;
    --p-border:       #213339;
    --p-border-soft:  #1c2e35;
    --p-ink:          #e8f0f2;
    --p-text:         #c3d3d8;
    --p-muted:        #a5b9c0;
    --p-faint:        #6d838b;
    --p-blue:         #4a8fe7;
    --p-blue-light:   #6ba5f0;
    --p-blue-soft:    #112238;
    --p-blue-line:    #1d4066;
    --p-blue-line-soft: #16304d;
    --p-red:          #ee6a5f;
    --p-red-soft:     #2d1917;
    --p-orange:       #dda23f;
    --p-orange-soft:  #2c2412;
    --p-orange-line:  #4a3c1c;
    --p-green:        #33bd77;
    --p-green-soft:   #0f2a1f;
    --p-yellow:       #dda23f;
    --p-yellow-soft:  #2c2412;
    --p-grad-primary: linear-gradient(135deg, #1d4066, #2b6bb5);
    --p-focus-ring:   0 0 0 3px rgba(74,143,231,.25);
    --p-shadow-sm:    0 1px 2px rgba(0,0,0,.4);
    --p-shadow:       0 1px 2px rgba(0,0,0,.3), 0 12px 32px -12px rgba(0,0,0,.6);
    --p-shadow-lg:    0 24px 70px -24px rgba(0,0,0,.8);
    --gs-bg:          #070e11;
    --gs-hover:       #16252c;
    --gs-purple:      #a58bea;
    --gs-purple-soft: #201a33;
    --gs-teal:        #22d3ee;
    --gs-teal-soft:   #0e2a30;
    --gs-pink:        #f472b6;
    --gs-pink-soft:   #2d1424;
    --gs-scrim:       linear-gradient(135deg, rgba(0,0,0,.72), rgba(4,14,20,.66));
    color-scheme: dark;
}

:is(.gsx, .gs-layer) *, :is(.gsx, .gs-layer) *::before, :is(.gsx, .gs-layer) *::after { box-sizing: border-box; }
:is(.gsx, .gs-layer) :is(button, input, select, textarea) { font-family: var(--p-font); }
:is(.gsx, .gs-layer) button { cursor: pointer; }
:is(.gsx, .gs-layer) button:disabled { cursor: not-allowed; }
:is(.gsx, .gs-layer) a { color: var(--p-blue); text-decoration: none; }
:is(.gsx, .gs-layer) a:hover { color: var(--p-blue-light); }
:is(.gsx, .gs-layer) ::placeholder { color: var(--p-faint); }
:is(.gsx, .gs-layer) ::selection { background: var(--p-blue-line-soft); color: var(--p-ink); }
@keyframes gsFadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes gsSpin { to { transform: rotate(360deg); } }
@keyframes gsPulse { 0%, 100% { opacity: 1; } 50% { opacity: .45; } }
@keyframes gsSlideIn { from { transform: translateX(28px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ============================================================
   Página
   ============================================================ */
.gsx.mc-page {
    padding: 0 0 48px;
    background: var(--gs-bg);
    font-family: var(--p-font);
    color: var(--p-text);
}
/* Página curta encosta no topo (mesmo ajuste do agendamentos.css: o .page do YNEX
   centraliza na vertical) e o fundo vai até o fim da janela. */
.page:has(> .main-content > .gsx) { justify-content: flex-start; }
.main-content:has(> .gsx) { flex: 1 0 auto; display: flex; flex-direction: column; }
.main-content > .gsx { flex: 1 0 auto; }

.gs-body { padding: 20px 22px 0; display: flex; flex-direction: column; gap: 16px; }
.gs-body > * { animation: gsFadeUp .35s var(--p-ease) both; }

/* ---- Sub-navegação do módulo ---- */
.gs-subnav {
    display: flex; align-items: stretch; gap: 10px;
    background: var(--p-surface); border-bottom: 1px solid var(--p-border);
    padding: 0 16px; min-height: 52px;
}
.gs-subnav-mod {
    display: flex; align-items: center; gap: 9px; flex: none;
    padding-right: 10px; border-right: 1px solid var(--p-border);
}
.gs-subnav-mod-ico {
    width: 30px; height: 30px; border-radius: 9px; flex: none;
    display: flex; align-items: center; justify-content: center; font-size: 16px;
    background: var(--p-grad-primary); color: #fff;
}
.gs-subnav-mod-txt { font-size: .8rem; font-weight: 800; color: var(--p-ink); letter-spacing: -.2px; white-space: nowrap; }
.gs-subnav-mod-txt small { display: block; font-size: .6rem; font-weight: 700; color: var(--p-faint); letter-spacing: .8px; text-transform: uppercase; }
/* 12 abas + selo + leitor/seletor cabem em 1600 (referência do zoom); se faltar espaço a faixa
   rola na horizontal — barra fina visível de propósito, para a rolagem ser descoberta. */
.gs-subnav-tabs { display: flex; align-items: stretch; gap: 0; overflow-x: auto; scrollbar-width: thin; flex: 1; min-width: 0; }
.gs-subnav-tabs::-webkit-scrollbar { height: 4px; }
.gs-subnav a.gs-tab {
    display: flex; align-items: center; gap: 5px; padding: 0 8px;
    border-bottom: 2px solid transparent; margin-bottom: -1px;
    color: var(--p-muted); font-size: .74rem; font-weight: 600; white-space: nowrap; text-decoration: none;
    transition: color .15s, border-color .15s;
}
.gs-subnav a.gs-tab i { font-size: 14px; }
.gs-subnav a.gs-tab:hover { color: var(--p-blue); }
.gs-subnav a.gs-tab.on { color: var(--p-blue); border-bottom-color: var(--p-blue); font-weight: 800; }
.gs-subnav a.gs-tab .gs-tab-n {
    padding: 0 .4rem; border-radius: 50px; font-size: .6rem; font-weight: 800;
    background: var(--p-red); color: #fff; line-height: 1.5;
}
.gs-subnav-dir { display: flex; align-items: center; gap: 8px; flex: none; }
.gs-subnav-dir .gs-seg button { max-width: 150px; }
.gs-subnav-dir .gs-seg button > .gs-ell { max-width: 118px; }

/* ---- Cabeçalho da página ---- */
.gs-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.gs-head-ico {
    width: 46px; height: 46px; border-radius: 13px; flex: none;
    display: flex; align-items: center; justify-content: center; font-size: 22px;
    background: var(--p-blue-soft); color: var(--p-blue); border: 1px solid var(--p-blue-line-soft);
}
.gs-head-txt { min-width: 0; flex: 1; }
.gs-head-eyebrow { font-size: .62rem; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase; color: var(--p-faint); }
.gs-head-title { font-size: 1.32rem; font-weight: 800; color: var(--p-ink); letter-spacing: -.5px; line-height: 1.2; margin: 0; }
.gs-head-sub { font-size: .78rem; font-weight: 500; color: var(--p-muted); margin-top: 3px; }
.gs-head-acoes { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ---- Botões (complementos do .prmd-btn) ---- */
.gsx .prmd-btn, .gs-layer .prmd-btn { text-decoration: none; white-space: nowrap; line-height: 1.2; }
.prmd-btn.gs-ghost { border: 1px solid transparent; background: transparent; color: var(--p-muted); }
.prmd-btn.gs-ghost:hover:not(:disabled) { background: var(--p-blue-soft); color: var(--p-blue); }
.prmd-btn.gs-ok { border: none; color: #fff; background: linear-gradient(135deg, #047857, #059669); box-shadow: 0 10px 22px -10px rgba(5,150,105,.6); }
.prmd-btn.gs-ok:hover:not(:disabled) { filter: brightness(1.06); color: #fff; }
.prmd-btn.gs-danger { border: none; color: #fff; background: linear-gradient(135deg, #b91c1c, #dc2626); box-shadow: 0 10px 22px -10px rgba(220,38,38,.55); }
.prmd-btn.gs-danger:hover:not(:disabled) { filter: brightness(1.06); color: #fff; }
.prmd-btn.gs-warn { border: 1px solid var(--p-orange-line); background: var(--p-orange-soft); color: var(--p-orange); }
.prmd-btn.gs-warn:hover:not(:disabled) { border-color: var(--p-orange); }
.prmd-btn.gs-soft { border: 1px solid var(--p-blue-line-soft); background: var(--p-blue-soft); color: var(--p-blue); }
.prmd-btn.gs-soft:hover:not(:disabled) { border-color: var(--p-blue-line); }
.prmd-btn.primary:hover:not(:disabled) { filter: brightness(1.06); color: #fff; }
.gs-ibtn {
    width: 32px; height: 32px; border-radius: 9px; flex: none;
    border: 1px solid var(--p-border); background: var(--p-surface); color: var(--p-muted);
    display: inline-flex; align-items: center; justify-content: center; font-size: 15px;
    transition: all .15s;
}
.gs-ibtn:hover:not(:disabled) { border-color: var(--p-blue-line); color: var(--p-blue); background: var(--p-blue-soft); }
.gs-ibtn.danger:hover:not(:disabled) { border-color: rgba(220,38,38,.4); color: var(--p-red); background: var(--p-red-soft); }
.gs-ibtn.ok:hover:not(:disabled) { border-color: rgba(5,150,105,.4); color: var(--p-green); background: var(--p-green-soft); }
.gs-ibtn.sm { width: 28px; height: 28px; border-radius: 8px; font-size: 14px; }
.gs-ibtn:disabled { opacity: .45; }
.gs-link { border: 0; background: none; padding: 0; color: var(--p-blue); font-weight: 700; font-size: inherit; }
.gs-link:hover { text-decoration: underline; }

/* ---- Cartões ---- */
.gs-card {
    background: var(--p-surface); border: 1px solid var(--p-border); border-radius: 14px;
    box-shadow: var(--p-shadow-sm); min-width: 0;
}
.gs-card.clip { overflow: hidden; }
.gs-card.pad { padding: 14px 16px; }
.gs-card.destaque { border-color: var(--p-blue-line); }
.gs-card-h {
    display: flex; align-items: center; gap: 9px; flex-wrap: wrap;
    padding: 12px 16px; border-bottom: 1px solid var(--p-border);
}
.gs-card-h.semlinha { border-bottom: 0; padding-bottom: 4px; }
.gs-card-t { display: flex; align-items: center; gap: 8px; font-size: .84rem; font-weight: 800; color: var(--p-ink); letter-spacing: -.1px; }
.gs-card-t > i { font-size: 17px; color: var(--p-blue); }
.gs-card-sub { font-size: .7rem; font-weight: 600; color: var(--p-faint); }
.gs-card-b { padding: 14px 16px; }
.gs-card-b.flush { padding: 0; }
.gs-card-f { padding: 10px 16px; border-top: 1px solid var(--p-border); background: var(--p-soft); border-radius: 0 0 14px 14px; display: flex; align-items: center; gap: 8px; }
.gs-count {
    padding: .1rem .55rem; border-radius: 50px; font-size: .64rem; font-weight: 800;
    background: var(--p-blue-soft); color: var(--p-blue); border: 1px solid var(--p-blue-line-soft); white-space: nowrap;
}
.gs-flex1 { flex: 1; min-width: 0; }

/* ---- Grades de layout ---- */
.gs-grid { display: grid; gap: 16px; min-width: 0; }
.gs-g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gs-g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.gs-g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.gs-g-main { grid-template-columns: minmax(0, 1fr) 380px; }
.gs-g-main-l { grid-template-columns: 340px minmax(0, 1fr); }
.gs-g-2-1 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.gs-span2 { grid-column: span 2; }
.gs-col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.gs-col.g10 { gap: 10px; }
.gs-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.gs-row.wrap { flex-wrap: wrap; }
.gs-row.g4 { gap: 4px; }
.gs-row.g12 { gap: 12px; }
.gs-row.top { align-items: flex-start; }
.gs-right { margin-left: auto; }

/* ---- KPIs ---- */
.gs-kpis { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); gap: 14px; }
.gs-kpi {
    position: relative; overflow: hidden;
    background: var(--p-surface); border: 1px solid var(--p-border); border-radius: 14px;
    box-shadow: var(--p-shadow-sm); padding: 14px 16px; display: flex; align-items: center; gap: 13px; min-width: 0;
    text-align: left; color: inherit; font: inherit; width: 100%;
    transition: border-color .15s, box-shadow .15s, transform .15s;
}
button.gs-kpi, a.gs-kpi, .gs-kpi.click { cursor: pointer; }
button.gs-kpi:hover, a.gs-kpi:hover, .gs-kpi.click:hover { border-color: var(--p-blue-line); box-shadow: var(--p-shadow); transform: translateY(-1px); }
.gs-kpi.on { border-color: var(--p-blue); box-shadow: inset 0 0 0 1px var(--p-blue); }
.gs-kpi-ico {
    width: 42px; height: 42px; border-radius: 12px; flex: none;
    display: flex; align-items: center; justify-content: center; font-size: 19px;
    background: var(--tone-bg, var(--p-blue-soft)); color: var(--tone-fg, var(--p-blue));
}
.gs-kpi-txt { min-width: 0; flex: 1; }
.gs-kpi-l { font-size: .64rem; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; color: var(--p-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-kpi-v { font-size: 1.42rem; font-weight: 800; color: var(--p-ink); letter-spacing: -.6px; line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-kpi-v small { font-size: .7rem; font-weight: 700; color: var(--p-faint); letter-spacing: 0; }
.gs-kpi-s { font-size: .68rem; font-weight: 600; color: var(--p-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-kpi-s.ok { color: var(--p-green); }
.gs-kpi-s.warn { color: var(--p-yellow); }
.gs-kpi-s.err { color: var(--p-red); }
.gs-kpi::after {
    content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
    background: var(--tone-fg, transparent); opacity: 0; transition: opacity .15s;
}
.gs-kpi.on::after, button.gs-kpi:hover::after { opacity: 1; }

/* Tons (KPI, ícones, pílulas, avatares) */
.t-blue   { --tone-bg: var(--p-blue-soft);   --tone-fg: var(--p-blue);   --tone-bd: var(--p-blue-line); }
.t-green  { --tone-bg: var(--p-green-soft);  --tone-fg: var(--p-green);  --tone-bd: rgba(5,150,105,.3); }
.t-orange { --tone-bg: var(--p-orange-soft); --tone-fg: var(--p-orange); --tone-bd: var(--p-orange-line); }
.t-yellow { --tone-bg: var(--p-yellow-soft); --tone-fg: var(--p-yellow); --tone-bd: rgba(217,119,6,.3); }
.t-red    { --tone-bg: var(--p-red-soft);    --tone-fg: var(--p-red);    --tone-bd: rgba(220,38,38,.3); }
.t-purple { --tone-bg: var(--gs-purple-soft); --tone-fg: var(--gs-purple); --tone-bd: rgba(124,58,237,.28); }
.t-teal   { --tone-bg: var(--gs-teal-soft);  --tone-fg: var(--gs-teal);  --tone-bd: rgba(8,145,178,.3); }
.t-pink   { --tone-bg: var(--gs-pink-soft);  --tone-fg: var(--gs-pink);  --tone-bd: rgba(219,39,119,.28); }
.t-slate  { --tone-bg: var(--p-soft2);       --tone-fg: var(--p-muted);  --tone-bd: var(--p-border); }

/* ---- Pílulas de status / selos ---- */
.gs-pill {
    display: inline-flex; align-items: center; gap: 5px; max-width: 100%;
    padding: .16rem .6rem; border-radius: 50px; white-space: nowrap;
    font-size: .64rem; font-weight: 800; letter-spacing: .1px;
    background: var(--tone-bg, var(--p-soft2)); color: var(--tone-fg, var(--p-muted));
    border: 1px solid var(--tone-bd, var(--p-border));
}
.gs-pill > span { overflow: hidden; text-overflow: ellipsis; }
.gs-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.gs-pill.nodot::before { display: none; }
.gs-pill i { font-size: 12px; }
.gs-pill.lg { font-size: .7rem; padding: .25rem .75rem; }
.gs-pill.pulse::before { animation: gsPulse 1.4s ease-in-out infinite; }
.gs-tag {
    display: inline-flex; align-items: center; gap: 4px; padding: .08rem .45rem; border-radius: 6px;
    font-size: .62rem; font-weight: 700; white-space: nowrap;
    background: var(--tone-bg, var(--p-soft2)); color: var(--tone-fg, var(--p-muted));
}
.gs-tag i { font-size: 12px; }
.gs-code {
    display: inline-block; padding: .08rem .42rem; border-radius: 6px; white-space: nowrap;
    font-family: var(--p-mono); font-size: .7rem; font-weight: 700;
    color: var(--p-blue); background: var(--p-blue-soft); border: 1px solid var(--p-blue-line-soft);
}
.gs-mono { font-family: var(--p-mono); }
.gs-num { font-variant-numeric: tabular-nums; }

/* ---- Barra de ferramentas e filtros ---- */
.gs-toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 12px 16px; }
.gs-toolbar + .gs-toolbar { padding-top: 0; }
.gs-busca { position: relative; flex: 1 1 280px; min-width: 220px; max-width: 460px; }
.gs-busca > i { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--p-faint); font-size: 16px; pointer-events: none; }
.gs-busca > .prmd-field { padding-left: 35px; padding-right: 32px; height: 38px; }
.gs-busca-x {
    position: absolute; right: 5px; top: 50%; transform: translateY(-50%);
    width: 26px; height: 26px; border: 0; border-radius: 7px; background: transparent; color: var(--p-faint);
    display: flex; align-items: center; justify-content: center; font-size: 15px;
}
.gs-busca-x:hover { background: var(--p-soft2); color: var(--p-ink); }
.gs-sel { width: auto; min-width: 150px; max-width: 230px; height: 38px; }
.gsx .prmd-field, .gs-layer .prmd-field { min-height: 36px; }
.gsx input[type="date"].prmd-field, .gsx input[type="month"].prmd-field { min-width: 140px; }
.gs-chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.gs-chip {
    display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 11px;
    border: 1px solid var(--p-border); border-radius: 50px; background: var(--p-surface);
    font-size: .72rem; font-weight: 700; color: var(--p-muted); white-space: nowrap; transition: all .15s;
}
.gs-chip i { font-size: 14px; }
.gs-chip:hover { border-color: var(--p-blue-line); color: var(--p-blue); }
.gs-chip.on { background: var(--p-blue-soft); border-color: var(--p-blue); color: var(--p-blue); }
.gs-chip-n {
    padding: 0 .42rem; border-radius: 50px; font-size: .6rem; font-weight: 800; line-height: 1.6;
    background: var(--p-soft2); color: var(--p-muted);
}
.gs-chip.on .gs-chip-n { background: var(--p-blue); color: #fff; }
.gs-chip.t-red .gs-chip-n, .gs-chip.t-orange .gs-chip-n { background: var(--tone-bg); color: var(--tone-fg); }
.gs-ativos { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding: 0 16px 10px; }
.gs-ativo {
    display: inline-flex; align-items: center; gap: 5px; padding: .18rem .3rem .18rem .6rem; border-radius: 8px;
    background: var(--p-blue-soft); border: 1px solid var(--p-blue-line-soft); color: var(--p-blue); font-size: .68rem; font-weight: 700;
}
.gs-ativo button { border: 0; background: none; color: inherit; display: inline-flex; font-size: 13px; padding: 0; opacity: .7; }
.gs-ativo button:hover { opacity: 1; }

/* Segmentado (Tabela | Cards | Kanban) */
.gs-seg { display: inline-flex; padding: 3px; gap: 2px; border-radius: 10px; background: var(--p-soft2); border: 1px solid var(--p-border); }
.gs-seg button {
    display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; border: 0; border-radius: 8px;
    background: transparent; color: var(--p-muted); font-size: .72rem; font-weight: 700; white-space: nowrap;
}
.gs-seg button i { font-size: 15px; }
.gs-seg button.on { background: var(--p-surface); color: var(--p-blue); box-shadow: var(--p-shadow-sm); }

/* Abas dentro da página (mesmo desenho das categorias do modal de prescrição) */
.gs-tabs { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.gs-tabs.linha { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
.gs-tabs .prmd-cat { flex: none; white-space: nowrap; }
.gs-tabs-n { margin-left: 2px; padding: 0 .42rem; border-radius: 50px; background: var(--p-soft2); color: var(--p-muted); font-size: .62rem; font-weight: 800; }
.prmd-cat.act .gs-tabs-n { background: var(--p-blue); color: #fff; }

/* ============================================================
   Tabela própria (não usa .table)
   ============================================================ */
.gs-tablewrap { overflow-x: auto; }
.gs-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .78rem; color: var(--p-text); }
.gs-table th {
    position: sticky; top: 0; z-index: 1;
    padding: 9px 12px; text-align: left; white-space: nowrap;
    background: var(--p-soft); border-bottom: 1px solid var(--p-border);
    font-size: .6rem; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; color: var(--p-muted);
}
.gs-table th.sort { cursor: pointer; user-select: none; }
.gs-table th.sort:hover { color: var(--p-blue); }
.gs-table th.sort i { font-size: 12px; vertical-align: -1px; opacity: .5; }
.gs-table th.sort.on { color: var(--p-blue); }
.gs-table th.sort.on i { opacity: 1; }
.gs-table td { padding: 10px 12px; border-bottom: 1px solid var(--p-border-soft); vertical-align: middle; }
.gs-table tbody tr:last-child td { border-bottom: 0; }
.gs-table tbody tr { transition: background .12s; }
.gs-table tbody tr:hover td { background: var(--gs-hover); }
.gs-table tbody tr.click { cursor: pointer; }
.gs-table tbody tr.sel td { background: var(--p-blue-soft); }
.gs-table tbody tr.dim td { opacity: .55; }
.gs-table tbody tr.alerta td:first-child { box-shadow: inset 3px 0 0 var(--p-red); }
.gs-table tbody tr.aviso td:first-child { box-shadow: inset 3px 0 0 var(--p-yellow); }
.gs-table tfoot td { padding: 10px 12px; background: var(--p-soft); border-top: 1px solid var(--p-border); font-weight: 800; color: var(--p-ink); }
.gs-table .r { text-align: right; }
.gs-table .c { text-align: center; }
.gs-table .nw { white-space: nowrap; }
.gs-table .chk { width: 36px; padding-right: 0; }
.gs-table .acts { width: 1%; white-space: nowrap; text-align: right; }
.gs-table .acts .gs-row { justify-content: flex-end; gap: 4px; }
.gs-table input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--p-blue); cursor: pointer; vertical-align: middle; }
.gs-t-main { font-weight: 700; color: var(--p-ink); line-height: 1.3; }
.gs-t-sub { font-size: .68rem; font-weight: 500; color: var(--p-muted); margin-top: 1px; }
.gs-t-main, .gs-t-sub { max-width: 420px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gs-ell { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gs-pos { color: var(--p-green); font-weight: 800; }
.gs-neg { color: var(--p-red); font-weight: 800; }
.gs-mutetx { color: var(--p-faint); }
.gs-ink { color: var(--p-ink); font-weight: 700; }

/* Paginação */
.gs-pager { display: flex; align-items: center; gap: 8px; padding: 10px 16px; border-top: 1px solid var(--p-border); background: var(--p-soft); border-radius: 0 0 14px 14px; }
.gs-pager-info { font-size: .7rem; font-weight: 600; color: var(--p-muted); }
.gs-pager-nav { margin-left: auto; display: flex; gap: 4px; align-items: center; }
.gs-pager-nav button {
    min-width: 30px; height: 30px; padding: 0 8px; border-radius: 8px; border: 1px solid var(--p-border);
    background: var(--p-surface); color: var(--p-text); font-size: .72rem; font-weight: 700;
    display: inline-flex; align-items: center; justify-content: center;
}
.gs-pager-nav button:hover:not(:disabled) { border-color: var(--p-blue-line); color: var(--p-blue); }
.gs-pager-nav button.on { background: var(--p-blue); border-color: var(--p-blue); color: #fff; }
.gs-pager-nav button:disabled { opacity: .45; }
.gs-pager-nav span { font-size: .72rem; color: var(--p-faint); padding: 0 2px; }

/* Barra de seleção em lote (aparece sobre a tabela) */
.gs-bulk {
    display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
    margin: 0 16px 10px; padding: 8px 10px 8px 14px; border-radius: 12px;
    background: var(--p-grad-primary); color: #fff; box-shadow: 0 12px 26px -14px rgba(26,74,158,.7);
    animation: gsFadeUp .25s var(--p-ease);
}
.gs-bulk-n { font-size: .78rem; font-weight: 800; }
.gs-bulk .prmd-btn { padding: .4rem .75rem; font-size: .72rem; border: 1px solid rgba(255,255,255,.3); background: rgba(255,255,255,.14); color: #fff; }
.gs-bulk .prmd-btn:hover:not(:disabled) { background: rgba(255,255,255,.26); color: #fff; }
.gs-bulk .gs-link { color: #fff; opacity: .85; font-size: .72rem; }

/* ---- Estados ---- */
.gs-vazio { text-align: center; padding: 38px 20px; color: var(--p-muted); }
.gs-vazio > i { display: block; font-size: 36px; color: var(--p-faint); margin-bottom: 6px; }
.gs-vazio-t { font-size: .86rem; font-weight: 800; color: var(--p-ink); }
.gs-vazio-s { font-size: .74rem; margin-top: 3px; line-height: 1.5; }
.gs-vazio .prmd-btn { margin-top: 12px; }
.gs-vazio.sm { padding: 20px 12px; }
.gs-vazio.sm > i { font-size: 26px; }
.gs-vazio.ok > i { color: var(--p-green); }
.gs-loading { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 48px 20px; font-size: .78rem; font-weight: 600; color: var(--p-muted); }
.gs-spin { width: 30px; height: 30px; border: 3px solid var(--p-blue-line-soft); border-top-color: var(--p-blue); border-radius: 50%; animation: gsSpin .8s linear infinite; }
.gs-spin.sm { width: 16px; height: 16px; border-width: 2px; }
.gs-skel { border-radius: 8px; background: linear-gradient(90deg, var(--p-soft2) 0%, var(--p-soft) 50%, var(--p-soft2) 100%); background-size: 200% 100%; animation: gsPulse 1.2s ease-in-out infinite; }

/* Aviso de página (sem acesso, depósito etc.) — mesmas cores do .pmod-aviso */
.gs-aviso {
    display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: 12px;
    background: var(--p-blue-soft); border: 1px solid var(--p-blue-line-soft); color: var(--p-ink); font-size: .78rem; line-height: 1.5;
}
.gs-aviso > i { font-size: 18px; color: var(--p-blue); flex: none; margin-top: 1px; }
.gs-aviso.warn { background: var(--p-yellow-soft); border-color: rgba(217,119,6,.35); }
.gs-aviso.warn > i { color: var(--p-yellow); }
.gs-aviso.erro { background: var(--p-red-soft); border-color: rgba(220,38,38,.35); }
.gs-aviso.erro > i { color: var(--p-red); }
.gs-aviso.ok { background: var(--p-green-soft); border-color: rgba(5,150,105,.3); }
.gs-aviso.ok > i { color: var(--p-green); }
.gs-aviso b { color: var(--p-ink); }

/* ============================================================
   Peças de visualização
   ============================================================ */
/* Avatar com iniciais */
.gs-av {
    width: 30px; height: 30px; border-radius: 50%; flex: none;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--tone-bg, var(--p-blue-soft)); color: var(--tone-fg, var(--p-blue));
    font-size: .64rem; font-weight: 800;
}
.gs-av.lg { width: 40px; height: 40px; font-size: .78rem; }
.gs-av.sq { border-radius: 10px; }
.gs-quem { display: flex; align-items: center; gap: 9px; min-width: 0; }
.gs-quem > div { min-width: 0; }

/* Ícone em caixa (lista de itens, alertas) */
.gs-ibox {
    width: 34px; height: 34px; border-radius: 10px; flex: none;
    display: inline-flex; align-items: center; justify-content: center; font-size: 16px;
    background: var(--tone-bg, var(--p-blue-soft)); color: var(--tone-fg, var(--p-blue));
}
.gs-ibox.lg { width: 44px; height: 44px; border-radius: 12px; font-size: 20px; }
.gs-ibox.sm { width: 28px; height: 28px; border-radius: 8px; font-size: 14px; }

/* Lista de itens (alertas, atividades, lotes) */
.gs-lista { display: flex; flex-direction: column; }
.gs-li { display: flex; align-items: center; gap: 11px; padding: 10px 16px; border-bottom: 1px solid var(--p-border-soft); min-width: 0; }
.gs-li:last-child { border-bottom: 0; }
.gs-li.click { cursor: pointer; transition: background .12s; }
.gs-li.click:hover { background: var(--gs-hover); }
.gs-li-txt { flex: 1; min-width: 0; }
.gs-li-t { font-size: .78rem; font-weight: 700; color: var(--p-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-li-s { font-size: .68rem; font-weight: 500; color: var(--p-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-li-v { flex: none; text-align: right; font-size: .76rem; font-weight: 800; color: var(--p-ink); }
.gs-li-v small { display: block; font-size: .62rem; font-weight: 600; color: var(--p-faint); }

/* Barras horizontais (distribuição) */
.gs-bars { display: flex; flex-direction: column; gap: 10px; }
.gs-bar-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; align-items: center; }
.gs-bar-row.click { cursor: pointer; }
.gs-bar-row.click:hover .gs-bar-l { color: var(--p-blue); }
.gs-bar-l { font-size: .74rem; font-weight: 700; color: var(--p-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-bar-v { font-size: .72rem; font-weight: 800; color: var(--p-ink); text-align: right; font-variant-numeric: tabular-nums; }
.gs-bar-v small { font-weight: 600; color: var(--p-faint); margin-left: 4px; }
.gs-bar { grid-column: 1 / -1; height: 8px; border-radius: 50px; background: var(--p-soft2); overflow: hidden; }
.gs-bar > span { display: block; height: 100%; border-radius: 50px; background: var(--tone-fg, var(--p-grad-primary)); background: var(--bar, var(--p-grad-primary)); transition: width .5s var(--p-ease); }

/* Progresso */
.gs-prog { height: 7px; border-radius: 50px; background: var(--p-soft2); overflow: hidden; min-width: 60px; }
.gs-prog > span { display: block; height: 100%; border-radius: 50px; background: var(--tone-fg, var(--p-blue)); transition: width .5s var(--p-ease); }
.gs-prog.lg { height: 10px; }
.gs-prog-txt { font-size: .66rem; font-weight: 700; color: var(--p-muted); }

/* Rosca (conic-gradient montado no C#) */
.gs-donut-wrap { display: flex; align-items: center; gap: 18px; }
.gs-donut {
    width: 132px; height: 132px; border-radius: 50%; flex: none; position: relative;
    background: var(--donut, var(--p-soft2));
}
.gs-donut::after { content: ""; position: absolute; inset: 20px; border-radius: 50%; background: var(--p-surface); }
.gs-donut-c { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.gs-donut-c b { font-size: 1.2rem; font-weight: 800; color: var(--p-ink); line-height: 1.1; }
.gs-donut-c span { font-size: .6rem; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; color: var(--p-faint); }
.gs-legenda { display: flex; flex-direction: column; gap: 7px; min-width: 0; flex: 1; }
.gs-leg { display: flex; align-items: center; gap: 8px; font-size: .72rem; min-width: 0; }
.gs-leg i { width: 9px; height: 9px; border-radius: 3px; flex: none; background: var(--c); }
.gs-leg span { flex: 1; min-width: 0; color: var(--p-text); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-leg b { color: var(--p-ink); font-weight: 800; font-variant-numeric: tabular-nums; }

/* Colunas verticais (série mensal) */
.gs-colchart { display: flex; align-items: flex-end; gap: 8px; height: 150px; padding-top: 18px; }
.gs-colchart-i { flex: 1; min-width: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 5px; }
.gs-colchart-b { width: 100%; max-width: 34px; border-radius: 7px 7px 3px 3px; background: var(--p-grad-primary); position: relative; min-height: 2px; transition: height .5s var(--p-ease); }
.gs-colchart-b.alt { background: var(--p-blue-line); }
.gs-colchart-b span { position: absolute; top: -17px; left: 50%; transform: translateX(-50%); font-size: .58rem; font-weight: 800; color: var(--p-muted); white-space: nowrap; }
.gs-colchart-l { font-size: .6rem; font-weight: 700; color: var(--p-faint); white-space: nowrap; text-transform: uppercase; }

/* Lista de definição (ficha) */
.gs-dl { display: grid; grid-template-columns: repeat(var(--dl, 3), minmax(0, 1fr)); gap: 12px 16px; }
.gs-dl > div { min-width: 0; }
.gs-dl dt, .gs-dt { font-size: .6rem; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; color: var(--p-faint); margin: 0 0 2px; }
.gs-dl dd, .gs-dd { font-size: .8rem; font-weight: 700; color: var(--p-ink); margin: 0; word-break: break-word; }
.gs-dl dd.vazio, .gs-dd.vazio { color: var(--p-faint); font-weight: 500; }
.gs-dl .full { grid-column: 1 / -1; }
.gs-secao-t {
    display: flex; align-items: center; gap: 7px; margin: 2px 0 10px;
    font-size: .64rem; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; color: var(--p-muted);
}
.gs-secao-t i { font-size: 15px; color: var(--p-blue); }

/* Linha do tempo */
.gs-tl { position: relative; padding-left: 26px; display: flex; flex-direction: column; gap: 14px; }
.gs-tl::before { content: ""; position: absolute; left: 10px; top: 6px; bottom: 6px; width: 2px; background: var(--p-border); border-radius: 2px; }
.gs-tl-i { position: relative; }
.gs-tl-dot {
    position: absolute; left: -26px; top: 1px; width: 22px; height: 22px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-size: 12px;
    background: var(--tone-bg, var(--p-blue-soft)); color: var(--tone-fg, var(--p-blue)); border: 2px solid var(--p-surface);
    box-shadow: 0 0 0 1px var(--tone-bd, var(--p-blue-line));
}
.gs-tl-t { font-size: .78rem; font-weight: 800; color: var(--p-ink); }
.gs-tl-s { font-size: .7rem; color: var(--p-muted); margin-top: 1px; line-height: 1.45; }
.gs-tl-d { font-size: .64rem; font-weight: 700; color: var(--p-faint); }
.gs-tl-i.futuro .gs-tl-dot { background: var(--p-surface); color: var(--p-faint); box-shadow: 0 0 0 1px var(--p-border); }
.gs-tl-i.futuro .gs-tl-t { color: var(--p-faint); }

/* Etapas (fluxo de status — requisição, OS, OC) */
.gs-steps { display: flex; align-items: flex-start; gap: 0; }
.gs-step { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 5px; position: relative; text-align: center; }
.gs-step::before { content: ""; position: absolute; top: 13px; right: 50%; width: 100%; height: 2px; background: var(--p-border); z-index: 0; }
.gs-step:first-child::before { display: none; }
.gs-step.ok::before, .gs-step.atual::before { background: var(--p-blue); }
.gs-step-n {
    position: relative; z-index: 1; width: 28px; height: 28px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-size: .72rem; font-weight: 800;
    background: var(--p-surface); color: var(--p-faint); border: 2px solid var(--p-border);
}
.gs-step.ok .gs-step-n { background: var(--p-blue); border-color: var(--p-blue); color: #fff; }
.gs-step.atual .gs-step-n { border-color: var(--p-blue); color: var(--p-blue); box-shadow: 0 0 0 4px var(--p-blue-soft); }
.gs-step.erro .gs-step-n { background: var(--p-red); border-color: var(--p-red); color: #fff; }
.gs-step-l { font-size: .64rem; font-weight: 700; color: var(--p-faint); line-height: 1.25; padding: 0 4px; }
.gs-step.ok .gs-step-l, .gs-step.atual .gs-step-l { color: var(--p-ink); }
.gs-step-d { font-size: .58rem; color: var(--p-faint); }
button.gs-step { border: 0; background: transparent; padding: 0; }
button.gs-step:hover .gs-step-l { color: var(--p-blue); }

/* Kanban */
.gs-kanban { display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(230px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 4px; align-items: start; }
.gs-kcol { background: var(--p-soft); border: 1px solid var(--p-border); border-radius: 14px; display: flex; flex-direction: column; min-height: 140px; max-height: 70vh; min-width: 0; }
.gs-kcol-h { display: flex; align-items: center; gap: 7px; padding: 10px 12px; border-bottom: 1px solid var(--p-border); }
.gs-kcol-h::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--tone-fg, var(--p-blue)); flex: none; }
.gs-kcol-t { font-size: .74rem; font-weight: 800; color: var(--p-ink); flex: 1; min-width: 0; }
.gs-kcol-b { padding: 10px; display: flex; flex-direction: column; gap: 8px; overflow-y: auto; }
.gs-kcard {
    background: var(--p-surface); border: 1px solid var(--p-border); border-radius: 11px; padding: 10px 11px;
    box-shadow: var(--p-shadow-sm); cursor: pointer; transition: border-color .15s, box-shadow .15s, transform .15s; text-align: left;
    display: block; width: 100%; color: inherit; font: inherit;
}
.gs-kcard:hover { border-color: var(--p-blue-line); box-shadow: var(--p-shadow); transform: translateY(-1px); }
.gs-kcard.urg { box-shadow: inset 3px 0 0 var(--p-red), var(--p-shadow-sm); }
.gs-kcard-t { font-size: .76rem; font-weight: 800; color: var(--p-ink); line-height: 1.35; margin: 4px 0 2px; }
.gs-kcard-s { font-size: .66rem; color: var(--p-muted); line-height: 1.4; }
.gs-kcard-f { display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: .64rem; font-weight: 700; color: var(--p-faint); }
.gs-kcol-vazio { text-align: center; font-size: .68rem; color: var(--p-faint); padding: 16px 6px; }

/* Cartões em grade (bens com foto, categorias, relatórios) */
.gs-cards { display: grid; grid-template-columns: repeat(var(--cc, 4), minmax(0, 1fr)); gap: 12px; }
.gs-tile {
    background: var(--p-surface); border: 1px solid var(--p-border); border-radius: 14px; box-shadow: var(--p-shadow-sm);
    padding: 14px; display: flex; flex-direction: column; gap: 8px; min-width: 0; text-align: left; color: inherit; font: inherit;
    transition: border-color .15s, box-shadow .15s, transform .15s;
}
button.gs-tile, .gs-tile.click { cursor: pointer; }
button.gs-tile:hover, .gs-tile.click:hover { border-color: var(--p-blue-line); box-shadow: var(--p-shadow); transform: translateY(-1px); }
.gs-tile.on { border-color: var(--p-blue); box-shadow: inset 0 0 0 1px var(--p-blue); }
.gs-tile-foto {
    height: 120px; margin: -14px -14px 2px; border-radius: 14px 14px 0 0; overflow: hidden;
    background: var(--p-soft2); display: flex; align-items: center; justify-content: center; color: var(--p-faint); font-size: 34px;
}
.gs-tile-foto img { width: 100%; height: 100%; object-fit: cover; }
.gs-tile-t { font-size: .8rem; font-weight: 800; color: var(--p-ink); line-height: 1.3; }
.gs-tile-s { font-size: .7rem; color: var(--p-muted); line-height: 1.45; }

/* Calendário mensal (agenda técnica, validade) */
.gs-cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--p-border); border-left: 1px solid var(--p-border); }
.gs-cal-h { padding: 7px 8px; font-size: .6rem; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; color: var(--p-faint); background: var(--p-soft); border-right: 1px solid var(--p-border); border-bottom: 1px solid var(--p-border); }
.gs-cal-d { min-height: 104px; padding: 6px; border-right: 1px solid var(--p-border); border-bottom: 1px solid var(--p-border); display: flex; flex-direction: column; gap: 3px; min-width: 0; background: var(--p-surface); }
.gs-cal-d.fora { background: var(--p-soft); }
.gs-cal-d.fora .gs-cal-n { color: var(--p-faint); opacity: .6; }
.gs-cal-d.hoje .gs-cal-n { background: var(--p-blue); color: #fff; }
.gs-cal-n { align-self: flex-start; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 50px; display: flex; align-items: center; justify-content: center; font-size: .68rem; font-weight: 800; color: var(--p-ink); }
.gs-cal-ev {
    display: flex; align-items: center; gap: 4px; padding: 2px 6px; border-radius: 6px; border: 0; width: 100%; text-align: left;
    background: var(--tone-bg, var(--p-blue-soft)); color: var(--tone-fg, var(--p-blue));
    font-size: .6rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gs-cal-ev i { font-size: 11px; flex: none; }
.gs-cal-ev:hover { filter: brightness(.97); box-shadow: inset 0 0 0 1px var(--tone-bd, var(--p-blue-line)); }
.gs-cal-mais { font-size: .6rem; font-weight: 800; color: var(--p-muted); border: 0; background: none; padding: 0 4px; text-align: left; }

/* Leitor de código (tombamento, código de barras) */
.gs-scan { position: relative; }
.gs-scan > i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-size: 22px; color: var(--p-blue); pointer-events: none; }
.gs-scan > .prmd-field { height: 52px; padding-left: 48px; font-size: 1rem; font-weight: 700; border-radius: 12px; border: 1.5px solid var(--p-blue-line); }
.gs-scan > .prmd-field:focus { border-color: var(--p-blue-light); }
.gs-scan-dica { font-size: .66rem; color: var(--p-faint); margin-top: 5px; }
/* Leitor compacto (sub-navegação) */
.gs-scan.mini > i { left: 10px; font-size: 16px; }
.gs-scan.mini > .prmd-field { height: 34px; padding-left: 32px; font-size: .76rem; width: 196px; border-width: 1px; border-color: var(--p-border); border-radius: 9px; }

/* ============================================================
   Painel lateral (ficha rápida, kardex) — fora do container com zoom
   ============================================================ */
.gs-drawer-ov {
    position: fixed; inset: 0; z-index: 1045; background: var(--gs-scrim);
    display: flex; justify-content: flex-end; animation: gsFadeUp .2s ease;
}
.gs-drawer {
    width: min(var(--gs-dw, 560px), 100vw); height: 100%; background: var(--p-surface);
    box-shadow: var(--p-shadow-lg); display: flex; flex-direction: column; animation: gsSlideIn .3s var(--p-ease);
    font-family: var(--p-font); color: var(--p-text);
}
.gs-drawer-h { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--p-border); flex: none; }
.gs-drawer-h .prmd-head-ico { width: 40px; height: 40px; border-radius: 11px; background: var(--p-blue-soft); color: var(--p-blue); display: flex; align-items: center; justify-content: center; font-size: 19px; flex: none; }
.gs-drawer-t { font-size: .95rem; font-weight: 800; color: var(--p-ink); letter-spacing: -.2px; line-height: 1.3; }
.gs-drawer-s { font-size: .7rem; font-weight: 600; color: var(--p-muted); }
.gs-drawer-b { flex: 1; overflow-y: auto; padding: 16px 18px; display: flex; flex-direction: column; gap: 14px; background: var(--p-soft); }
.gs-drawer-f { flex: none; display: flex; align-items: center; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--p-border); background: var(--p-surface); flex-wrap: wrap; }
.gs-drawer-x {
    width: 32px; height: 32px; border: none; border-radius: 8px; background: transparent; color: var(--p-muted);
    display: flex; align-items: center; justify-content: center; font-size: 18px; margin-left: auto; flex: none;
}
.gs-drawer-x:hover { background: var(--p-red-soft); color: var(--p-red); }

/* ---- Toast ---- */
.gs-toast {
    position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 1065;
    display: flex; align-items: center; gap: 9px; max-width: min(560px, calc(100vw - 32px));
    padding: 11px 16px; border-radius: 12px; background: #0b1f3a; color: #fff;
    box-shadow: 0 18px 40px -16px rgba(11,31,58,.6); font-size: .8rem; font-weight: 600; line-height: 1.4;
    animation: gsFadeUp .3s var(--p-ease);
}
.gs-toast > i { font-size: 18px; color: #34d399; flex: none; }
.gs-toast.err { background: #7f1d1d; }
.gs-toast.err > i { color: #fca5a5; }
.gs-toast.warn { background: #78350f; }
.gs-toast.warn > i { color: #fcd34d; }
[data-theme-mode="dark"] .gs-toast { background: #1c2e35; border: 1px solid #31474f; }

/* ============================================================
   Complementos para os modais (ModalPadrao .pmod) dos dois módulos
   ============================================================ */
/* Etapas do assistente no topo do corpo do modal */
.gs-wiz { display: flex; gap: 6px; padding: 0 0 2px; overflow-x: auto; scrollbar-width: none; }
.gs-wiz button {
    flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 11px;
    border: 1px solid var(--p-border); background: var(--p-surface); text-align: left; color: var(--p-muted);
}
.gs-wiz button:hover:not(:disabled) { border-color: var(--p-blue-line); }
.gs-wiz-n {
    width: 24px; height: 24px; border-radius: 50%; flex: none; display: flex; align-items: center; justify-content: center;
    font-size: .68rem; font-weight: 800; background: var(--p-soft2); color: var(--p-muted);
}
.gs-wiz-l { font-size: .7rem; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-wiz button.on { border-color: var(--p-blue); background: var(--p-blue-soft); color: var(--p-blue); }
.gs-wiz button.on .gs-wiz-n { background: var(--p-blue); color: #fff; }
.gs-wiz button.ok .gs-wiz-n { background: var(--p-green); color: #fff; }
.gs-wiz button.erro { border-color: rgba(220,38,38,.4); }
.gs-wiz button.erro .gs-wiz-n { background: var(--p-red); color: #fff; }

/* Resumo lateral do modal (pré-visualização do que vai ser gravado) */
.gs-resumo { background: var(--p-soft); border: 1px dashed var(--p-border); border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.gs-resumo-l { display: flex; justify-content: space-between; gap: 10px; font-size: .74rem; }
.gs-resumo-l span { color: var(--p-muted); }
.gs-resumo-l b { color: var(--p-ink); text-align: right; }
.gs-resumo-l.total { border-top: 1px solid var(--p-border); padding-top: 6px; margin-top: 2px; font-size: .82rem; }

/* Opções em cartão (tipo de movimentação, motivo) */
.gs-opcoes { display: grid; grid-template-columns: repeat(var(--oc, 3), minmax(0, 1fr)); gap: 8px; }
.gs-opcao {
    display: flex; align-items: flex-start; gap: 9px; padding: 10px 11px; border-radius: 12px; text-align: left;
    border: 1px solid var(--p-border); background: var(--p-surface); color: var(--p-text); transition: all .15s; min-width: 0;
}
.gs-opcao > i { font-size: 18px; color: var(--p-faint); flex: none; margin-top: 1px; }
.gs-opcao b { display: block; font-size: .76rem; font-weight: 800; color: var(--p-ink); }
.gs-opcao small { display: block; font-size: .64rem; color: var(--p-muted); line-height: 1.4; margin-top: 1px; }
.gs-opcao:hover:not(:disabled) { border-color: var(--p-blue-line); }
.gs-opcao.on { border-color: var(--p-blue); background: var(--p-blue-soft); box-shadow: inset 0 0 0 1px var(--p-blue); }
.gs-opcao.on > i { color: var(--p-blue); }
.gs-opcao:disabled { opacity: .5; }

/* Dropzone de arquivo (InputFile por cima, invisível) */
.gs-drop {
    position: relative; display: flex; align-items: center; gap: 10px; padding: 14px; border-radius: 12px;
    border: 1.5px dashed var(--p-blue-line); background: var(--p-blue-soft); color: var(--p-blue); font-size: .76rem; font-weight: 700;
}
.gs-drop > i { font-size: 22px; }
.gs-drop small { display: block; font-weight: 500; color: var(--p-muted); font-size: .66rem; }
.gs-drop input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

/* Linha "item escolhido" com remover (bens/produtos selecionados no modal) */
.gs-itens { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; }
.gs-item {
    display: flex; align-items: center; gap: 9px; padding: 7px 8px 7px 10px; border-radius: 10px;
    background: var(--p-surface); border: 1px solid var(--p-border);
}
.gs-item-txt { flex: 1; min-width: 0; }

/* Impressão: nada do módulo vai para o papel (as impressões usam iframe próprio). */
@media print {
    .gs-subnav, .gs-head-acoes, .gs-toolbar, .gs-pager, .gs-bulk, .gs-noprint { display: none !important; }
    .gsx.mc-page { background: #fff; }
}
