/* ProtectTickets - Estilos customizados */

/* Metric-matched fallbacks — cut layout shift while webfonts swap in */
@font-face {
    font-family: "Inter Fallback";
    src: local("Arial");
    size-adjust: 107.64%;
    ascent-override: 90.49%;
    descent-override: 22.56%;
    line-gap-override: 0%;
}
@font-face {
    font-family: "Montserrat Fallback";
    src: local("Arial");
    size-adjust: 112.84%;
    ascent-override: 90%;
    descent-override: 22%;
    line-gap-override: 0%;
}

:root {
    --prioridade-baixa: #6C757D;
    --prioridade-media: #2563EB;
    --prioridade-alta: #EA580C;
    --prioridade-urgente: #DC2626;
    /* Protect brand — DESIGN.md §2 */
    --pt-ink: #093A87;
    --pt-ink-2: #07306E;
    --pt-ink-3: #05224E;
    --pt-signal: #10CAF0;
    --pt-paper: #EEF2F4;
    --pt-panel: #F7F9FA;
    --pt-text: #1C2833;
    /* ~7:1 on white — secondary copy stays AA without looking faint */
    --pt-muted: #475569;
    --pt-danger: #DC2626;
    --pt-success: #15803D;
    --bs-body-color: var(--pt-text);
    --bs-secondary-color: var(--pt-muted);
    --bs-body-font-size: var(--pt-text-body);
    --bs-body-line-height: 1.55;
    /* Branding (sobrescrito via header com valores do banco) */
    --pt-primary: #093A87;
    --pt-primary-2: #07306E;
    --pt-primary-3: #05224E;
    --pt-primary-rgb: 9, 58, 135;
    --pt-info-glow: #10CAF0;
    --pt-info-glow-rgb: 16, 202, 240;
    --pt-surface: #FFFFFF;
    --pt-surface-soft: #F4F7F8;
    --pt-border-soft: rgba(9, 58, 135, 0.14);
    --pt-radius-lg: 12px;
    --pt-radius-xl: 16px;
    --pt-radius-md: 8px;
    --pt-radius-btn: 8px;
    --pt-space-xs: 4px;
    --pt-space-sm: 8px;
    --pt-space-md: 16px;
    --pt-space-lg: 24px;
    --pt-space-xl: 32px;
    --pt-font-display: "Montserrat", "Montserrat Fallback", system-ui, sans-serif;
    --pt-font-sans: "Inter", "Inter Fallback", system-ui, sans-serif;
    --pt-font-mono: "IBM Plex Mono", ui-monospace, monospace;
    /* Type ramp — DESIGN.md §3 (use tokens only; no literal sizes outside this scale) */
    --pt-text-display-lg: clamp(1.75rem, 5vw, 2.5rem);
    --pt-text-display: clamp(1.75rem, 3vw, 2.25rem);
    --pt-text-headline: 1.35rem;
    --pt-text-title: 1.1rem;
    --pt-text-body: 1rem;
    --pt-text-label: 0.875rem;
    --pt-text-sm: var(--pt-text-label);
    --pt-text-xs: 0.75rem;
    --pt-leading-body: 1.55;
    --pt-leading-prose: 1.65;
    --pt-shadow-soft: 0 8px 24px rgba(15, 42, 58, 0.08);
    --pt-shadow-strong: 0 14px 36px rgba(15, 42, 58, 0.12);
    --pt-shadow-premium: 0 1px 2px rgba(15, 42, 58, 0.04), 0 8px 28px rgba(15, 42, 58, 0.06);
    --pt-glass: rgba(247, 249, 250, 0.92);
    --pt-gradient-primary: linear-gradient(135deg, var(--pt-ink) 0%, var(--pt-ink-2) 55%, var(--pt-ink-3) 100%);
    --pt-focus-ring: #093A87;
}

body {
    min-height: 100vh;
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-body);
    line-height: var(--pt-leading-body);
    font-optical-sizing: auto;
    font-feature-settings: "kern";
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background:
        radial-gradient(circle at 0% 0%, rgba(9, 58, 135, 0.05), transparent 34%),
        radial-gradient(circle at 100% 8%, rgba(16, 202, 240, 0.03), transparent 28%),
        var(--bs-body-bg, var(--pt-paper));
    color: var(--bs-body-color, var(--pt-text));
    transition: background-color 0.2s ease, color 0.15s ease;
    overflow-x: hidden;
}

:focus-visible {
    outline: 3px solid var(--pt-focus-ring);
    outline-offset: 2px;
}

[data-bs-theme="dark"] {
    --pt-focus-ring: #10CAF0;
}

/* Tipografia — DESIGN.md §3 */
.pt-display {
    font-family: var(--pt-font-display);
    font-size: var(--pt-text-display);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
    text-wrap: balance;
}
.pt-headline {
    font-family: var(--pt-font-display);
    font-size: var(--pt-text-headline);
    font-weight: 700;
    line-height: 1.25;
    text-wrap: balance;
}
.pt-title {
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-title);
    font-weight: 600;
    line-height: 1.3;
}
.pt-label {
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-label);
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.01em;
}
.pt-mono {
    font-family: var(--pt-font-mono);
    font-size: var(--pt-text-sm);
    font-weight: 500;
    line-height: 1.4;
    font-variant-numeric: tabular-nums;
}

/* Long-form reading: descrição, comentários, histórico */
.pt-prose {
    max-width: 68ch;
    font-size: var(--pt-text-body);
    line-height: var(--pt-leading-prose);
    color: var(--pt-text);
    overflow-wrap: anywhere;
    text-wrap: pretty;
}

.pt-prose p:last-child {
    margin-bottom: 0;
}

/* Avoid compounded .small { em } shrinking nested copy below label floor */
.small,
small {
    font-size: var(--pt-text-label);
}

.text-muted {
    color: var(--pt-muted) !important;
}

.form-control,
.form-select {
    font-size: var(--pt-text-body);
    line-height: var(--pt-leading-body);
}

.form-control-sm,
.form-select-sm {
    font-size: var(--pt-text-label);
    line-height: 1.45;
    min-height: 2.25rem;
}

.form-label {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-text);
    margin-bottom: 0.35rem;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}

.pt-skip-link {
    position: absolute;
    left: 0.75rem;
    top: 0.75rem;
    z-index: 2000;
    padding: 0.55rem 0.9rem;
    border-radius: var(--pt-radius-md, 8px);
    background: var(--pt-ink, #093A87);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    transform: translateY(-200%);
    transition: transform 0.15s ease;
}

.pt-skip-link:focus,
.pt-skip-link:focus-visible {
    transform: translateY(0);
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
    color: #fff;
}

a,
button,
.card,
.btn,
.table-hover tbody tr {
    transition: color 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, opacity 0.18s ease, filter 0.18s ease;
}

button,
a.btn,
.pt-side-link,
.pt-auth-submit,
.pt-auth-forgot,
.pt-auth-password-toggle,
.pt-sidebar-toggle,
.dashboard-kpi-rail-item,
.atrasado-item,
.dashboard-dist-chip,
.setor-ranking-item--link {
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(15, 42, 58, 0.12);
}

.pt-main {
    min-height: calc(100vh - 4rem);
}

#main-content,
#dashboard-hero-title,
[id^="dashboard-sec-"] {
    scroll-margin-top: 5.5rem;
}

/* Só oculta h1 duplicado quando é filho direto de main (topbar já mostra o título) */
#main-content > h1.pt-sr-topbar-title {
    display: none;
}

.pt-page-shell {
    padding-top: clamp(1rem, 2.2vw, 1.5rem) !important;
    padding-left: clamp(1rem, 2.2vw, 1.75rem) !important;
    padding-right: clamp(1rem, 2.2vw, 1.75rem) !important;
    padding-bottom: 1.75rem !important;
}

/* Conteúdo centralizado em telas muito largas (apenas área logada) */
.pt-app-shell .pt-content-shell > main.pt-page-shell {
    max-width: 1680px;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
}

/* Auth — Protect Navy + Arc Cyan */
.pt-auth-page {
    --pt-auth-ink: #093A87;
    --pt-auth-ink-2: #07306E;
    --pt-auth-paper: #eef1f6;
    --pt-auth-panel: #f5f7fb;
    --pt-auth-signal: #10CAF0;
    --pt-auth-text: #1c2833;
    /* ≥4.5:1 on panel (#f5f7fb) for body-size secondary copy */
    --pt-auth-muted: #445566;
    --pt-auth-placeholder: #64748b;
    --pt-auth-line: rgba(9, 58, 135, 0.18);
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--pt-auth-paper);
    font-family: var(--pt-font-sans);
    padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}

.pt-auth-split {
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
}

.pt-auth-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1.75rem, 4vw, 3.5rem);
    /* Mesmo radial da splash Protect: claro no topo-esquerdo → navy no inferior-direito */
    background: radial-gradient(
        ellipse 130% 110% at 18% 12%,
        #365d98 0%,
        #0a377b 38%,
        #062b62 68%,
        #04214d 100%
    );
    color: #f4f7f8;
}

.pt-auth-logo {
    display: block;
    width: min(300px, 82%);
    height: auto;
    max-height: 118px;
    object-fit: contain;
    object-position: center;
    margin: 0 auto 1.5rem;
    /* logo.png = Protect + tagline “O seu jeito de rastrear”; invert → branco no hero */
    filter: brightness(0) invert(1);
}

.pt-auth-hero-signal {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        repeating-linear-gradient(
            -18deg,
            transparent 0,
            transparent 22px,
            rgba(255, 255, 255, 0.025) 22px,
            rgba(255, 255, 255, 0.025) 23px
        );
}

.pt-auth-hero-signal::after {
    content: "";
    position: absolute;
    left: -20%;
    top: 0;
    width: 38%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(0, 144, 200, 0.2),
        transparent
    );
    animation: pt-auth-sweep 7.5s ease-in-out infinite;
}

@keyframes pt-auth-sweep {
    0%,
    100% {
        transform: translateX(0);
        opacity: 0.35;
    }
    50% {
        transform: translateX(220%);
        opacity: 0.85;
    }
}

.pt-auth-hero-content {
    position: relative;
    z-index: 1;
    width: min(560px, 100%);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pt-auth-kicker {
    margin: 0 0 0.75rem;
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-label);
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    /* ~4.5:1+ on navy hero (was ~0.62 white — weak) */
    color: rgba(244, 247, 248, 0.82);
}

.pt-auth-brand {
    margin: 0 0 0.35rem;
    font-family: var(--pt-font-display);
    font-size: var(--pt-text-display-lg);
    font-weight: 800;
    line-height: 0.95;
    letter-spacing: -0.02em;
    color: #fff;
    text-wrap: balance;
}

.pt-auth-brand-tag {
    margin: 0 0 1.15rem;
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-title);
    font-weight: 500;
    line-height: 1.35;
    letter-spacing: 0.01em;
    color: rgba(244, 247, 248, 0.72);
}

.pt-auth-input.is-invalid {
    border-color: var(--pt-danger, #DC2626);
    /* Bootstrap pinta ícone de feedback — colide com toggle e polui o campo */
    background-image: none;
    padding-right: 2.5rem;
}

.pt-auth-input.is-invalid:focus {
    border-color: var(--pt-danger, #DC2626);
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.18);
}

.pt-auth-field-error {
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    margin-top: 0.45rem;
    font-size: var(--pt-text-label);
    line-height: 1.4;
    color: var(--pt-danger, #DC2626);
}

.pt-auth-field-error i {
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.pt-auth-form-error {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    margin: 0;
    padding: 0.75rem 0.85rem;
    border: 1px solid color-mix(in srgb, var(--pt-danger, #DC2626) 28%, transparent);
    border-radius: 8px;
    background: color-mix(in srgb, var(--pt-danger, #DC2626) 6%, transparent);
    font-size: var(--pt-text-label);
    line-height: 1.45;
    color: #b42318; /* texto em fundo tintado — ≥4.5:1 */
}

.pt-auth-form-error:focus {
    outline: 2px solid #b42318;
    outline-offset: 2px;
}

.pt-auth-form-error i {
    margin-top: 0.12rem;
    flex-shrink: 0;
    color: #b42318;
}

/* Ícones decorativos do grupo não herdam vermelho do invalid */
.pt-auth-input-group:has(.is-invalid) > i,
.pt-auth-input-group:has(.is-invalid) .pt-auth-password-toggle {
    color: var(--pt-auth-muted);
}

.pt-auth-form-error-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
    min-width: 0;
}

.pt-auth-form-error-link {
    color: var(--pt-auth-ink);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 0.15em;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}

.pt-auth-form-error-link:hover {
    color: var(--pt-auth-ink-2, #07306E);
}

.pt-auth-form-error-link:focus-visible {
    outline: 2px solid var(--pt-auth-ink);
    outline-offset: 2px;
    border-radius: 4px;
}

.pt-auth-hero-text {
    margin: 0;
    max-width: 38ch;
    font-size: var(--pt-text-title);
    line-height: 1.55;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.92);
    text-wrap: pretty;
    text-align: center;
}

.pt-auth-queue {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 0.65rem;
    padding-top: 1.1rem;
    border-top: 1px solid rgba(244, 247, 248, 0.16);
}

.pt-auth-queue span {
    font-size: var(--pt-text-label);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: rgba(244, 247, 248, 0.55);
}

.pt-auth-queue span + span::before {
    content: "·";
    margin-right: 0.65rem;
    color: var(--pt-auth-signal);
}

.pt-auth-form-side {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1.5rem, 4vw, 2.75rem);
    background: var(--pt-auth-panel);
}

.pt-auth-form-wrap {
    width: min(380px, 100%);
    animation: pt-auth-rise 0.55s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.pt-auth-form-wrap > .alert {
    margin-bottom: 1.25rem;
}

@keyframes pt-auth-rise {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pt-auth-form-title {
    margin: 0 0 0.4rem;
    font-family: var(--pt-font-display);
    font-size: var(--pt-text-display);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--pt-auth-text);
    text-wrap: balance;
}

.pt-auth-form-subtitle {
    margin: 0 0 1.75rem;
    color: var(--pt-auth-muted);
    font-size: var(--pt-text-body);
    line-height: 1.5;
    max-width: 42ch;
}

.pt-auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.05rem;
}

.pt-auth-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.pt-auth-form-meta {
    display: flex;
    justify-content: flex-end;
    margin-top: -0.25rem;
    margin-bottom: 0.15rem;
}

.pt-auth-label {
    display: block;
    margin: 0;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-auth-text);
}

.pt-auth-input-group {
    position: relative;
}

.pt-auth-input-group > i {
    position: absolute;
    left: 0.85rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--pt-auth-muted);
    font-size: var(--pt-text-body);
    pointer-events: none;
}

.pt-auth-input {
    height: 48px;
    min-height: 48px;
    border-radius: 8px;
    border: 1px solid var(--pt-auth-line);
    padding-left: 2.45rem;
    padding-right: 2.5rem;
    /* 16px: evita zoom forçado no iOS */
    font-size: var(--pt-text-body);
    line-height: 1.4;
    background: var(--pt-surface, #fff);
    color: var(--pt-auth-text);
}

.pt-auth-input::placeholder {
    color: var(--pt-auth-placeholder);
    opacity: 1;
}

.pt-auth-input:focus {
    border-color: var(--pt-auth-ink);
    box-shadow: 0 0 0 3px rgba(9, 58, 135, 0.16);
}

.pt-auth-input:focus-visible {
    outline: 2px solid var(--pt-auth-ink);
    outline-offset: 2px;
}

.pt-auth-submit {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--pt-auth-ink);
    --bs-btn-border-color: var(--pt-auth-ink);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: #07306E;
    --bs-btn-hover-border-color: #07306E;
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: #05224E;
    --bs-btn-active-border-color: #05224E;
    height: 48px;
    min-height: 48px;
    border-radius: 8px;
    font-weight: 600;
    letter-spacing: 0.01em;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.pt-auth-submit:disabled {
    cursor: wait;
    opacity: 0.85;
}

.pt-auth-submit-busy {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.pt-auth-submit:focus-visible {
    outline: 2px solid var(--pt-auth-ink);
    outline-offset: 2px;
    box-shadow: 0 0 0 3px rgba(16, 202, 240, 0.35);
}

.pt-auth-forgot {
    color: var(--pt-auth-ink);
    font-size: var(--pt-text-label);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 0.18em;
    text-decoration-thickness: 1px;
    cursor: pointer;
    min-height: 44px;
    padding: 0.25rem 0;
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    transition: color 0.2s ease;
}

.pt-auth-password-toggle {
    position: absolute;
    right: 0.25rem;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    color: var(--pt-auth-muted);
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.pt-auth-password-toggle:hover {
    background: rgba(15, 42, 58, 0.06);
    color: var(--pt-auth-ink);
}

.pt-auth-password-toggle:focus-visible {
    outline: 2px solid var(--pt-auth-ink);
    outline-offset: 2px;
}

.pt-auth-forgot:hover {
    color: var(--pt-auth-ink-2);
    text-decoration-thickness: 2px;
}

.pt-auth-forgot:focus-visible {
    outline: 2px solid var(--pt-auth-ink);
    outline-offset: 3px;
    border-radius: 4px;
}

.pt-auth-footnote {
    margin-top: 1.25rem;
    font-size: var(--pt-text-label);
    line-height: 1.45;
    color: var(--pt-auth-muted);
    text-align: left;
}

@media (max-width: 991.98px) {
    .pt-auth-split {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    /* Portrait: hero só logo — form sobe na viewport (job Operate primeiro) */
    .pt-auth-hero {
        min-height: auto;
        align-items: center;
        justify-content: center;
        padding: 1rem 1.25rem 0.85rem;
        padding-top: max(1rem, env(safe-area-inset-top));
    }
    .pt-auth-logo {
        width: min(200px, 62%);
        max-height: 64px;
        margin-bottom: 0;
    }
    .pt-auth-kicker {
        margin-bottom: 0.55rem;
        letter-spacing: 0.12em;
    }
    .pt-auth-brand {
        font-size: var(--pt-text-display-lg);
    }
    .pt-auth-brand-tag {
        font-size: var(--pt-text-body);
        margin-bottom: 1rem;
    }
    .pt-auth-hero-text {
        display: none;
    }
    .pt-auth-form-side {
        padding: 1.25rem 1.25rem max(2rem, env(safe-area-inset-bottom));
        align-items: flex-start;
    }
    .pt-auth-form-wrap {
        width: 100%;
        max-width: 420px;
        margin-inline: auto;
    }
    .pt-auth-form-subtitle {
        margin-bottom: 1.35rem;
    }
}

@media (max-width: 575.98px) {
    .pt-auth-hero {
        padding: 0.85rem 1rem 0.7rem;
    }
    .pt-auth-logo {
        width: min(180px, 58%);
        max-height: 56px;
    }
    .pt-auth-form-side {
        padding: 1.1rem 1rem max(1.75rem, env(safe-area-inset-bottom));
    }
    .pt-auth-form-title {
        font-size: var(--pt-text-headline);
    }
}

/* Landscape phone: hero compacto, form no restante */
@media (max-width: 991.98px) and (max-height: 520px) {
    .pt-auth-hero {
        padding: 0.85rem 1rem;
    }
    .pt-auth-logo {
        max-height: 56px;
        margin-bottom: 0;
    }
    .pt-auth-kicker {
        display: none;
    }
    .pt-auth-hero-text {
        display: none;
    }
    .pt-auth-form-side {
        padding-top: 1rem;
        padding-bottom: max(1rem, env(safe-area-inset-bottom));
    }
    .pt-auth-form-subtitle {
        margin-bottom: 1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .pt-auth-hero-signal::after,
    .pt-auth-form-wrap {
        animation: none;
    }
}

[data-bs-theme="dark"] .pt-auth-page {
    --pt-auth-paper: #0c141a;
    --pt-auth-panel: #111b22;
    --pt-auth-text: #e8eef2;
    --pt-auth-muted: #a8b8c6;
    --pt-auth-placeholder: #8fa0b0;
    --pt-auth-line: rgba(232, 238, 242, 0.14);
    background: var(--pt-auth-paper);
}

[data-bs-theme="dark"] .pt-auth-input {
    background: #0c141a;
    color: var(--pt-auth-text);
}

[data-bs-theme="dark"] .pt-auth-input:focus {
    border-color: var(--pt-auth-signal);
    box-shadow: 0 0 0 3px rgba(16, 202, 240, 0.22);
}

[data-bs-theme="dark"] .pt-auth-forgot {
    color: #7dd3fc;
}

[data-bs-theme="dark"] .pt-auth-field-error {
    color: #f97066;
}

[data-bs-theme="dark"] .pt-auth-form-error {
    color: #f97066;
    border-color: rgba(249, 112, 102, 0.35);
    background: rgba(220, 38, 38, 0.12);
}

[data-bs-theme="dark"] .pt-auth-form-error-link {
    color: #7dd3fc;
}

.pt-auth-card {
    border: 1px solid var(--bs-border-color-translucent);
}

.pt-navbar.navbar {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(120deg, var(--pt-ink) 0%, var(--pt-ink-2) 55%, var(--pt-ink-3) 100%);
    backdrop-filter: saturate(1.1);
}

.pt-app-shell {
    display: flex;
    min-height: 100vh;
    background: var(--pt-paper);
}

.pt-sidebar {
    width: 220px;
    flex-shrink: 0;
    padding: 1rem 0.9rem;
    padding-top: calc(1rem + env(safe-area-inset-top));
    padding-bottom: calc(1rem + env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    /* Preto do logo.png + arco azul Protect */
    background:
        radial-gradient(120% 70% at 0% 0%, rgba(16, 202, 240, 0.2) 0%, transparent 48%),
        radial-gradient(90% 50% at 100% 100%, rgba(9, 58, 135, 0.55) 0%, transparent 55%),
        linear-gradient(185deg, #070b12 0%, #0a1322 52%, #08101c 100%);
    color: #fff;
    position: sticky;
    top: 0;
    max-height: 100vh;
    max-height: 100dvh;
    overflow-y: auto;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.04), 8px 0 24px rgba(10, 16, 32, 0.28);
    scrollbar-width: none; /* Firefox */
    transition: padding 0.2s ease, box-shadow 0.2s ease;
}

.pt-sidebar-top {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.pt-sidebar::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none; /* Chromium/Safari */
}

.pt-content-shell {
    flex: 1;
    min-width: 0;
    overflow-x: hidden;
}

.pt-topbar {
    height: 56px;
    padding: 0 1.15rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--pt-border-soft);
    background: var(--pt-panel);
    backdrop-filter: none;
    position: sticky;
    top: 0;
    z-index: 1010;
    box-shadow: none;
}

/* Topbar: micro-interações mais “premium” */
.pt-topbar .btn {
    backdrop-filter: blur(10px);
}

.pt-topbar-title {
    font-weight: 700;
    letter-spacing: 0.01em;
}

.pt-topbar-left {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.pt-topbar-title-wrap {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.pt-topbar-subtitle {
    font-size: var(--pt-text-label);
    text-transform: none;
    letter-spacing: 0.01em;
    color: #64748b;
    font-weight: 600;
    line-height: 1.25;
}

.pt-topbar-title-icon {
    width: 1.95rem;
    height: 1.95rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    color: var(--pt-primary);
}

.pt-topbar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pt-topbar .btn-outline-secondary {
    border-color: rgba(100, 116, 139, 0.35);
    background: rgba(255, 255, 255, 0.72);
    color: #334155;
}

.pt-topbar .btn-outline-secondary:hover {
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.32);
    color: color-mix(in srgb, var(--pt-primary) 92%, #000);
}

.pt-topbar [data-pt-theme].is-active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.35);
    color: var(--pt-primary-2);
}

.pt-topbar-badge {
    font-size: var(--pt-text-label);
    min-width: 1.05rem;
}

.pt-notif-menu {
    width: min(380px, 92vw);
    max-height: 72vh;
    overflow-y: auto;
}

.pt-notif-item {
    white-space: normal;
    padding: 0.65rem 0.85rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.pt-notif-item:last-child {
    border-bottom: 0;
}

.pt-notif-item.is-unread {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
}

.pt-notif-title {
    font-weight: 700;
    font-size: var(--pt-text-label);
    color: #0f172a;
}

.pt-notif-msg {
    font-size: var(--pt-text-label);
    color: #475569;
    margin-top: 0.12rem;
}

.pt-notif-time {
    font-size: var(--pt-text-label);
    color: #94a3b8;
    margin-top: 0.2rem;
}

.pt-notif-list-unread {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
}

.pt-toast-container {
    z-index: 1095;
}

.pt-toast {
    min-width: 300px;
    max-width: 380px;
    border-radius: 12px;
    color: #fff;
}

.pt-toast .toast-body {
    font-weight: 600;
    letter-spacing: 0.01em;
    line-height: 1.35;
}

.pt-toast-icon {
    font-size: var(--pt-text-body);
    opacity: 0.98;
    line-height: 1.2;
}

.pt-toast-progress {
    height: 3px;
    width: 100%;
    background: rgba(255, 255, 255, 0.35);
    transform-origin: left center;
    transform: scaleX(1);
    animation: ptToastProgress var(--pt-toast-delay, 4500ms) linear forwards;
    animation-play-state: paused;
}

.pt-toast.pt-toast-running .pt-toast-progress {
    animation-play-state: running;
}

.pt-toast:hover .pt-toast-progress {
    animation-play-state: paused;
}

@keyframes ptToastProgress {
    from {
        transform: scaleX(1);
    }
    to {
        transform: scaleX(0);
    }
}

.pt-toast-success {
    background: linear-gradient(135deg, #15803d 0%, #166534 100%);
}

.pt-toast-danger {
    background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
}

.pt-toast-warning {
    background: linear-gradient(135deg, #b45309 0%, #92400e 100%);
}

.pt-toast-info {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
}

@media (max-width: 575.98px) {
    .pt-toast-container {
        left: 0.75rem;
        right: 0.75rem;
        top: 0.75rem;
        padding: 0 !important;
    }

    .pt-toast {
        min-width: 0;
        width: 100%;
        max-width: none;
    }
}

.pt-sidebar-toggle {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    cursor: pointer;
}

.pt-sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-top: 0.85rem;
    flex: 1 1 auto;
    min-height: 0;
}

.pt-side-link {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    position: relative;
    width: 100%;
    box-sizing: border-box;
    color: rgba(255, 255, 255, 0.92);
    text-decoration: none;
    border-radius: 8px;
    padding: 0.5rem 0.72rem;
    font-size: var(--pt-text-body);
    line-height: 1.25;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pt-side-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    transform: none;
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

.pt-side-link.active {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-weight: 600;
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: none;
}

.pt-side-link.active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 3px;
    height: 58%;
    min-height: 16px;
    max-height: 24px;
    transform: translateY(-50%);
    border-radius: 0 2px 2px 0;
    background: var(--pt-signal);
    opacity: 1;
}

.pt-side-link i {
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.pt-side-link:hover i,
.pt-side-link.active i {
    opacity: 1;
    transform: none;
}

.pt-side-link:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.82);
    outline-offset: 2px;
}

.pt-side-link-logout {
    display: flex;
    align-items: center;
    width: 100%;
    box-sizing: border-box;
    color: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.04);
    border-radius: 8px;
}

.pt-side-link-logout:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.18);
}

.pt-side-group-title {
    font-size: var(--pt-text-label);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 1rem 0 0.3rem;
    color: rgba(255, 255, 255, 0.62);
    font-weight: 700;
    padding: 0 0.6rem;
}

.pt-sidebar-bottom {
    margin-top: auto;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    min-width: 0;
}

.pt-sidebar-prefooter {
    margin-top: auto;
    padding-top: 0.55rem;
}

.pt-side-link-sub {
    padding-left: 1.95rem;
    font-size: var(--pt-text-label);
    color: rgba(255, 255, 255, 0.88);
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar {
    width: 68px;
    padding-left: 0.65rem;
    padding-right: 0.65rem;
}

.pt-app-shell.is-sidebar-collapsed .pt-brand-text,
.pt-app-shell.is-sidebar-collapsed .pt-side-group-title,
.pt-app-shell.is-sidebar-collapsed .pt-side-link-sub {
    display: none;
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-logo-img {
    width: 40px;
    max-height: 40px;
    object-fit: cover;
    object-position: left center;
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-brand {
    padding: 0.35rem;
    align-items: center;
    width: 100%;
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-top > .d-flex {
    flex-direction: column;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.45rem;
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-top {
    width: 100%;
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-nav {
    gap: 0.45rem;
}

.pt-app-shell.is-sidebar-collapsed .pt-side-link {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0;
    min-height: 38px;
    padding-left: 0.45rem;
    padding-right: 0.45rem;
}

.pt-app-shell.is-sidebar-collapsed .pt-side-link i {
    margin: 0 !important;
    font-size: var(--pt-text-body);
}

.pt-app-shell.is-sidebar-collapsed .pt-side-link.active::before {
    display: none;
}

.pt-app-shell.is-sidebar-collapsed .pt-side-link.active {
    background: rgba(255, 255, 255, 0.14);
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-bottom {
    display: block;
    padding-top: 0.55rem;
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-prefooter {
    padding-top: 0.45rem;
}

.pt-app-shell.is-sidebar-collapsed .pt-side-link-logout {
    justify-content: center;
}

.pt-app-shell.is-sidebar-collapsed .pt-sidebar-toggle i {
    transform: rotate(180deg);
}

.pt-theme-option {
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.pt-theme-option:has(.form-check-input:checked) {
    border-color: var(--bs-primary) !important;
    box-shadow: 0 0 0 0.15rem rgba(var(--bs-primary-rgb), 0.25);
}

[data-bs-theme="dark"] .pt-theme-option:has(.form-check-input:checked) {
    box-shadow: 0 0 0 0.15rem rgba(var(--pt-primary-rgb, 13, 110, 253), 0.35);
}

/* Config SLA — lista de feriados */
.pt-sla-feriados-list {
    max-width: 420px;
}

.pt-sla-feriado-row .input-group-text {
    min-width: 6.5rem;
    justify-content: center;
}

/* Preferencias (mobile): alvos maiores para toque e melhor legibilidade */
.pt-pref-scope-option {
    border: 1px solid var(--bs-border-color);
    border-radius: 10px;
    padding: 0.6rem 0.75rem 0.6rem 2rem;
    position: relative;
}

.pt-pref-scope-option .form-check-input {
    margin-left: -1.45rem;
}

@media (max-width: 767.98px) {
    .pt-preferencias-form .card-body {
        padding: 0.9rem;
    }

    .pt-pref-scope-option {
        margin-bottom: 0.55rem !important;
    }

    .pt-pref-kanban-options .form-check-inline {
        width: 100%;
        margin-right: 0;
    }

    .pt-pref-kanban-options .form-check-label {
        font-size: var(--pt-text-body);
    }
}

.card {
    border-radius: var(--pt-radius-md);
}

.btn {
    font-weight: 600;
    letter-spacing: 0.01em;
    border-radius: var(--pt-radius-btn);
    min-height: 40px;
    padding: 0.5rem 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    line-height: 1.15;
}

.pt-btn-lg {
    height: 48px;
    padding: 0.6rem 1.15rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.pt-btn-pill {
    border-radius: var(--pt-radius-btn) !important;
}

/* Command palette */
.pt-cmd-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 36px;
}

.pt-cmd-trigger-kbd {
    margin-left: 0.15rem;
    padding: 0.05rem 0.35rem;
    border: 1px solid rgba(15, 23, 42, 0.14);
    border-radius: 4px;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: var(--pt-text-xs);
    font-weight: 500;
    color: var(--pt-muted, #5b6b7a);
    background: var(--pt-surface-soft, #f4f7f8);
}

html.pt-cmd-open {
    overflow: hidden;
}

.pt-cmd {
    position: fixed;
    inset: 0;
    z-index: 1100;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 12vh 1rem 2rem;
}

.pt-cmd[hidden] {
    display: none !important;
}

.pt-cmd-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 42, 58, 0.45);
}

.pt-cmd-dialog {
    position: relative;
    z-index: 1;
    width: min(36rem, 100%);
    max-height: min(70vh, 32rem);
    display: flex;
    flex-direction: column;
    background: var(--pt-surface, #fff);
    border: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
    border-radius: var(--pt-radius-lg, 12px);
    box-shadow: var(--pt-shadow-strong, 0 14px 36px rgba(15, 42, 58, 0.12));
    overflow: hidden;
    overscroll-behavior: contain;
}

.pt-cmd-header {
    padding: 0.75rem 0.85rem 0.5rem;
    border-bottom: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
}

.pt-cmd-input-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: var(--pt-radius-md, 8px);
    padding: 0.15rem 0.25rem;
}

.pt-cmd-input-wrap:focus-within {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

.pt-cmd-search-icon {
    color: var(--pt-muted, #5b6b7a);
    font-size: var(--pt-text-title);
}

.pt-cmd-input {
    flex: 1;
    min-width: 0;
    border: 0;
    background: transparent;
    font-size: var(--pt-text-body);
    font-family: var(--pt-font-sans);
    color: var(--pt-text, #1c2833);
    outline: none;
    padding: 0.35rem 0;
}

.pt-cmd-input:focus,
.pt-cmd-input:focus-visible {
    outline: none;
    box-shadow: none;
}

.pt-cmd-hint {
    margin: 0.45rem 0 0;
    font-size: var(--pt-text-xs);
    color: var(--pt-muted, #5b6b7a);
}

.pt-cmd-body {
    flex: 1;
    overflow: auto;
    overscroll-behavior: contain;
    padding: 0.35rem 0.4rem 0.5rem;
}

.pt-cmd-group {
    padding: 0.55rem 0.65rem 0.2rem;
    font-size: var(--pt-text-xs);
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--pt-muted, #5b6b7a);
}

.pt-cmd-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    width: 100%;
    min-height: 44px;
    padding: 0.45rem 0.65rem;
    border: 0;
    border-radius: var(--pt-radius-md, 8px);
    background: transparent;
    color: var(--pt-text, #1c2833);
    text-align: left;
    cursor: pointer;
}

.pt-cmd-item:hover,
.pt-cmd-item.is-active {
    background: rgba(9, 58, 135, 0.08);
}

.pt-cmd-item:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 1px;
}

.pt-cmd-item-icon {
    width: 1.5rem;
    flex-shrink: 0;
    color: var(--pt-ink, #093A87);
    text-align: center;
}

.pt-cmd-item-text {
    display: flex;
    flex-direction: column;
    gap: 0.05rem;
    min-width: 0;
}

.pt-cmd-item-label {
    font-size: var(--pt-text-body);
    font-weight: 600;
}

.pt-cmd-item-hint {
    font-size: var(--pt-text-xs);
    color: var(--pt-muted, #5b6b7a);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pt-cmd-empty {
    padding: 1.25rem 0.75rem;
    text-align: center;
    color: var(--pt-muted, #5b6b7a);
    font-size: var(--pt-text-label);
}

.pt-cmd-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
    padding: 0.5rem 0.85rem;
    border-top: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
    font-size: var(--pt-text-xs);
    color: var(--pt-muted, #5b6b7a);
    background: var(--pt-surface-soft, #f4f7f8);
}

.pt-cmd-kbd {
    display: inline-block;
    padding: 0.05rem 0.35rem;
    border: 1px solid rgba(15, 23, 42, 0.14);
    border-radius: 4px;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: var(--pt-text-xs);
    background: var(--pt-surface, #fff);
    color: inherit;
}

button.pt-cmd-kbd {
    appearance: none;
    line-height: 1.2;
    margin: 0;
}

.pt-cmd-esc {
    cursor: pointer;
    flex-shrink: 0;
}

.pt-cmd-esc:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

[data-bs-theme="dark"] .pt-cmd-dialog {
    background: #0f172a;
    border-color: rgba(148, 163, 184, 0.22);
}

[data-bs-theme="dark"] .pt-cmd-input {
    color: #e2e8f0;
}

[data-bs-theme="dark"] .pt-cmd-item:hover,
[data-bs-theme="dark"] .pt-cmd-item.is-active {
    background: rgba(96, 165, 250, 0.14);
}

[data-bs-theme="dark"] .pt-cmd-item-icon {
    color: #93c5fd;
}

[data-bs-theme="dark"] .pt-cmd-footer {
    background: rgba(2, 6, 23, 0.55);
    border-color: rgba(148, 163, 184, 0.18);
}

[data-bs-theme="dark"] .pt-cmd-kbd,
[data-bs-theme="dark"] .pt-cmd-trigger-kbd {
    background: rgba(15, 23, 42, 0.9);
    border-color: rgba(148, 163, 184, 0.28);
    color: #cbd5e1;
}

[data-bs-theme="dark"] .pt-cmd-backdrop {
    background: rgba(2, 6, 23, 0.72);
}

@media (prefers-reduced-motion: reduce) {
    .pt-cmd-dialog {
        transition: none;
    }
}

.btn:focus-visible {
    box-shadow: 0 0 0 0.22rem rgba(var(--pt-primary-rgb, 13, 110, 253), 0.18);
}

.btn i,
.btn .bi {
    line-height: 1;
}

.pt-icon-btn {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px !important;
    line-height: 1;
}

.pt-icon-btn.btn-outline-secondary {
    border-color: rgba(15, 23, 42, 0.14);
}

.pt-icon-btn:hover,
.pt-icon-btn:focus-visible {
    transform: none;
}

.pt-icon-btn.btn-outline-secondary:hover,
.pt-icon-btn.btn-outline-secondary:focus {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.30);
}

.pt-icon-btn.btn-outline-danger:hover,
.pt-icon-btn.btn-outline-danger:focus {
    background: rgba(220, 53, 69, 0.08);
}

.pt-icon-link {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px !important;
    color: var(--bs-body-color);
    text-decoration: none;
}

.pt-icon-link:hover,
.pt-icon-link:focus-visible {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
    color: color-mix(in srgb, var(--pt-primary) 92%, #000);
    text-decoration: none;
}

.btn-primary {
    border-color: var(--pt-primary-2);
    background: linear-gradient(135deg, var(--pt-primary), var(--pt-primary-2));
    box-shadow: 0 10px 20px color-mix(in srgb, var(--pt-primary) 24%, transparent);
}

.btn-primary:hover,
.btn-primary:focus {
    border-color: var(--pt-primary-3);
    background: linear-gradient(135deg, color-mix(in srgb, var(--pt-primary) 92%, #000), var(--pt-primary-3));
    box-shadow: 0 14px 30px color-mix(in srgb, var(--pt-primary) 32%, transparent);
    transform: translateY(-1px);
}

.btn-sm {
    border-radius: var(--pt-radius-btn);
    min-height: 34px;
    padding: 0.35rem 0.75rem;
}

/* Touch / mobile: alvos ≥44px (WCAG 2.2 / PRODUCT.md); desktop fino mantém densidade. */
@media (pointer: coarse), (max-width: 767.98px) {
    .pt-icon-btn,
    .pt-icon-link {
        width: 44px;
        height: 44px;
        min-width: 44px;
        min-height: 44px;
    }

    .btn-sm {
        min-height: 44px;
        min-width: 44px;
        padding: 0.5rem 0.9rem;
    }

    .pt-topbar .btn-sm,
    .pt-topbar [data-pt-theme],
    .pt-mobile-pagebar-actions .btn-sm,
    .pt-mobile-pagebar-actions [data-pt-theme] {
        min-height: 44px;
        min-width: 44px;
    }

    .pt-cmd-trigger {
        min-height: 44px;
    }

    .tickets-toolbar .pt-toolbar-toggle,
    .tickets-toolbar .pt-toolbar-action,
    .filtros-card .pt-toolbar-toggle,
    .filtros-card .pt-toolbar-action {
        height: auto;
        min-height: 44px;
    }

    .tickets-toolbar .pt-btn-icon-only,
    .tickets-kanban-chrome .pt-btn-icon-only {
        width: 44px;
        height: 44px;
        min-width: 44px;
        min-height: 44px;
    }

    .pt-section-actions .btn,
    .tickets-bulk-bar-actions .btn {
        min-height: 44px;
    }

    .pt-section-filters .pt-toolbar-toggle {
        height: auto;
        min-height: 44px;
    }

    .pagination .page-link {
        min-width: 44px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .form-check-input {
        width: 1.2rem;
        height: 1.2rem;
    }

    .pt-combobox-trigger,
    .ticket-prioridade-field,
    .filtro-input,
    .filtros-card .form-select.filtro-input {
        min-height: 44px;
    }
}

.btn-outline-secondary {
    border-color: rgba(15, 23, 42, 0.16);
}

.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.28);
}

.btn-outline-danger:hover,
.btn-outline-danger:focus {
    background: rgba(220, 53, 69, 0.08);
}

.btn-outline-success:hover,
.btn-outline-success:focus {
    background: rgba(25, 135, 84, 0.08);
}

.btn-link {
    font-weight: 600;
    text-decoration: none;
}

.btn-link:hover,
.btn-link:focus {
    text-decoration: none;
}

/* Padronização de botões dentro de modais e ações em containers */
.modal .modal-header {
    gap: 0.5rem;
}

.modal .modal-footer {
    gap: 0.5rem;
    flex-wrap: wrap;
}

.pt-confirm-dialog .modal-content {
    overscroll-behavior: contain;
    border: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
    border-radius: var(--pt-radius-lg, 12px);
    box-shadow: var(--pt-shadow-premium);
}

.pt-confirm-modal.is-danger .modal-header {
    color: var(--pt-danger, #dc2626);
}

.pt-confirm-modal #ptModalConfirmOk.btn-danger:focus-visible {
    outline: 3px solid var(--pt-danger, #dc2626);
    outline-offset: 2px;
}

.form-control,
.form-select {
    border-radius: 10px;
    border-color: #d8e2f0;
    color: var(--pt-text);
}

.form-control:focus-visible,
.form-select:focus-visible {
    border-color: var(--pt-ink, #093A87);
    box-shadow: 0 0 0 0.2rem rgba(9, 58, 135, 0.28);
    outline: 2px solid var(--pt-focus-ring, #093A87);
    outline-offset: 1px;
}

.table-danger {
    background-color: rgba(220, 53, 69, 0.1);
}

.table {
    --bs-table-bg: transparent;
}

.table > :not(caption) > * > * {
    padding-top: 0.8rem;
    padding-bottom: 0.8rem;
    border-bottom-color: rgba(100, 116, 139, 0.18);
}

.table thead th {
    font-size: var(--pt-text-label);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--pt-muted);
    font-weight: 700;
}

.table-hover tbody tr:hover {
    background-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.05);
    transform: translateY(-1px);
}

.alert {
    border: none;
    border-radius: var(--pt-radius-md);
}

.badge {
    border-radius: 999px;
    padding: 0.42em 0.68em;
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1.2;
    border: 1px solid transparent;
}

.pt-ui-premium .badge[class*="-subtle"] {
    border-color: rgba(15, 23, 42, 0.08);
}

[data-bs-theme="dark"] .pt-ui-premium .badge[class*="-subtle"] {
    border-color: rgba(255, 255, 255, 0.1);
}

.badge-urgente { background-color: var(--prioridade-urgente); }
.badge-alta { background-color: var(--prioridade-alta); }
.badge-media { background-color: var(--prioridade-media); }
.badge-baixa { background-color: var(--prioridade-baixa); }

/* Badges padronizados (lista, ticket, Kanban) */
.pt-badge,
.tickets-kanban-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: var(--pt-text-label);
    font-weight: 700;
    letter-spacing: 0.03em;
    line-height: 1.2;
    padding: 0.28em 0.55em;
    border-radius: 6px;
    border: 1px solid transparent;
    white-space: nowrap;
    max-width: 100%;
    vertical-align: middle;
}

.pt-badge-pri {
    color: #fff;
    background: var(--pt-badge-color, var(--pt-primary));
    border-color: color-mix(in srgb, var(--pt-badge-color, var(--pt-primary)) 78%, #000);
    box-shadow: 0 1px 3px color-mix(in srgb, var(--pt-badge-color, var(--pt-primary)) 28%, transparent);
}

.pt-badge-status {
    background: rgba(100, 116, 139, 0.12);
    color: #334155;
    border-color: rgba(100, 116, 139, 0.22);
}

.pt-badge-status--aberto {
    background: rgba(59, 130, 246, 0.14);
    color: #1d4ed8;
    border-color: rgba(59, 130, 246, 0.28);
}

.pt-badge-status--em-tratamento {
    background: rgba(14, 165, 233, 0.14);
    color: #0369a1;
    border-color: rgba(14, 165, 233, 0.28);
}

.pt-badge-status--encaminhado {
    background: rgba(99, 102, 241, 0.14);
    color: #4338ca;
    border-color: rgba(99, 102, 241, 0.28);
}

.pt-badge-status--aguardando-cliente {
    background: rgba(245, 158, 11, 0.16);
    color: #b45309;
    border-color: rgba(245, 158, 11, 0.32);
}

.pt-badge-status--agendado {
    background: rgba(168, 85, 247, 0.14);
    color: #7e22ce;
    border-color: rgba(168, 85, 247, 0.28);
}

.pt-badge-status--finalizado {
    background: rgba(34, 197, 94, 0.14);
    color: #15803d;
    border-color: rgba(34, 197, 94, 0.28);
}

.pt-badge-status--cancelado {
    background: rgba(100, 116, 139, 0.16);
    color: #475569;
    border-color: rgba(100, 116, 139, 0.28);
}

.pt-badge-sla--late,
.tickets-kanban-badge--danger {
    color: #b91c1c;
    background: rgba(248, 113, 113, 0.16);
    border-color: rgba(248, 113, 113, 0.35);
}

.pt-badge--fila-warn,
.tickets-kanban-badge--warn {
    color: #92400e;
    background: rgba(251, 191, 36, 0.18);
    border-color: rgba(251, 191, 36, 0.4);
}

.pt-badge--fila-ok {
    color: #166534;
    background: rgba(34, 197, 94, 0.14);
    border-color: rgba(34, 197, 94, 0.3);
}

.pt-badge--fila-muted {
    color: #475569;
    background: rgba(100, 116, 139, 0.12);
    border-color: rgba(100, 116, 139, 0.22);
}

.pt-badge-email--pending {
    color: #b45309;
    background: rgba(245, 158, 11, 0.16);
    border-color: rgba(245, 158, 11, 0.32);
}

.pt-badge-email--sent {
    color: #15803d;
    background: rgba(34, 197, 94, 0.14);
    border-color: rgba(34, 197, 94, 0.3);
}

.pt-badge-email--error {
    color: #b91c1c;
    background: rgba(248, 113, 113, 0.16);
    border-color: rgba(248, 113, 113, 0.35);
}

.pt-badge-email--unknown {
    color: #475569;
    background: rgba(100, 116, 139, 0.12);
    border-color: rgba(100, 116, 139, 0.22);
}

.pt-badge-audit--default {
    color: #334155;
    background: rgba(100, 116, 139, 0.12);
    border-color: rgba(100, 116, 139, 0.22);
}

.pt-badge-audit--login {
    color: #1d4ed8;
    background: rgba(59, 130, 246, 0.14);
    border-color: rgba(59, 130, 246, 0.28);
}

.pt-badge-audit--create {
    color: #15803d;
    background: rgba(34, 197, 94, 0.14);
    border-color: rgba(34, 197, 94, 0.28);
}

.pt-badge-audit--update {
    color: #0369a1;
    background: rgba(14, 165, 233, 0.14);
    border-color: rgba(14, 165, 233, 0.28);
}

.pt-badge-audit--delete {
    color: #b91c1c;
    background: rgba(248, 113, 113, 0.16);
    border-color: rgba(248, 113, 113, 0.35);
}

.pt-badge-audit--profile,
.pt-badge-audit--prefs {
    color: #7e22ce;
    background: rgba(168, 85, 247, 0.14);
    border-color: rgba(168, 85, 247, 0.28);
}

.pt-badge-audit--security {
    color: #9a3412;
    background: rgba(249, 115, 22, 0.16);
    border-color: rgba(249, 115, 22, 0.32);
}

.pt-badge-audit--config {
    color: #4338ca;
    background: rgba(99, 102, 241, 0.14);
    border-color: rgba(99, 102, 241, 0.28);
}

.tickets-kanban-badge--pri {
    color: #fff;
    background: var(--kanban-pri, var(--pt-badge-color, var(--pt-primary)));
    border-color: color-mix(in srgb, var(--kanban-pri, var(--pt-primary)) 80%, #000);
    box-shadow: 0 1px 4px color-mix(in srgb, var(--kanban-pri, var(--pt-primary)) 35%, transparent);
}

[data-bs-theme="dark"] .pt-badge-status {
    background: rgba(148, 163, 184, 0.14);
    color: #e2e8f0;
    border-color: rgba(148, 163, 184, 0.22);
}

[data-bs-theme="dark"] .pt-badge-status--aberto {
    background: rgba(59, 130, 246, 0.22);
    color: #bfdbfe;
    border-color: rgba(96, 165, 250, 0.35);
}

[data-bs-theme="dark"] .pt-badge-status--em-tratamento {
    background: rgba(14, 165, 233, 0.2);
    color: #bae6fd;
    border-color: rgba(56, 189, 248, 0.35);
}

[data-bs-theme="dark"] .pt-badge-status--encaminhado {
    background: rgba(99, 102, 241, 0.22);
    color: #c7d2fe;
    border-color: rgba(129, 140, 248, 0.35);
}

[data-bs-theme="dark"] .pt-badge-status--aguardando-cliente {
    background: rgba(245, 158, 11, 0.2);
    color: #fde68a;
    border-color: rgba(251, 191, 36, 0.35);
}

[data-bs-theme="dark"] .pt-badge-status--agendado {
    background: rgba(168, 85, 247, 0.22);
    color: #e9d5ff;
    border-color: rgba(192, 132, 252, 0.35);
}

[data-bs-theme="dark"] .pt-badge-status--finalizado {
    background: rgba(34, 197, 94, 0.2);
    color: #bbf7d0;
    border-color: rgba(74, 222, 128, 0.35);
}

[data-bs-theme="dark"] .pt-badge-status--cancelado {
    background: rgba(100, 116, 139, 0.2);
    color: #cbd5e1;
    border-color: rgba(148, 163, 184, 0.28);
}

[data-bs-theme="dark"] .pt-badge-sla--late,
[data-bs-theme="dark"] .tickets-kanban-badge--danger {
    color: #fecaca;
    background: rgba(248, 113, 113, 0.2);
    border-color: rgba(248, 113, 113, 0.38);
}

[data-bs-theme="dark"] .pt-badge--fila-warn,
[data-bs-theme="dark"] .tickets-kanban-badge--warn {
    color: #fde68a;
    background: rgba(251, 191, 36, 0.18);
    border-color: rgba(251, 191, 36, 0.38);
}

[data-bs-theme="dark"] .pt-badge--fila-ok {
    color: #bbf7d0;
    background: rgba(34, 197, 94, 0.18);
    border-color: rgba(74, 222, 128, 0.32);
}

[data-bs-theme="dark"] .pt-badge--fila-muted {
    color: #cbd5e1;
    background: rgba(100, 116, 139, 0.18);
    border-color: rgba(148, 163, 184, 0.28);
}

[data-bs-theme="dark"] .pt-badge-email--pending {
    color: #fde68a;
    background: rgba(245, 158, 11, 0.2);
    border-color: rgba(251, 191, 36, 0.35);
}

[data-bs-theme="dark"] .pt-badge-email--sent {
    color: #bbf7d0;
    background: rgba(34, 197, 94, 0.18);
    border-color: rgba(74, 222, 128, 0.32);
}

[data-bs-theme="dark"] .pt-badge-email--error {
    color: #fecaca;
    background: rgba(248, 113, 113, 0.2);
    border-color: rgba(248, 113, 113, 0.38);
}

[data-bs-theme="dark"] .pt-badge-audit--default {
    color: #cbd5e1;
    background: rgba(100, 116, 139, 0.18);
    border-color: rgba(148, 163, 184, 0.28);
}

[data-bs-theme="dark"] .pt-badge-audit--login {
    color: #bfdbfe;
    background: rgba(59, 130, 246, 0.22);
    border-color: rgba(96, 165, 250, 0.35);
}

[data-bs-theme="dark"] .pt-badge-audit--create {
    color: #bbf7d0;
    background: rgba(34, 197, 94, 0.18);
    border-color: rgba(74, 222, 128, 0.32);
}

[data-bs-theme="dark"] .pt-badge-audit--update {
    color: #bae6fd;
    background: rgba(14, 165, 233, 0.2);
    border-color: rgba(56, 189, 248, 0.35);
}

[data-bs-theme="dark"] .pt-badge-audit--delete {
    color: #fecaca;
    background: rgba(248, 113, 113, 0.2);
    border-color: rgba(248, 113, 113, 0.38);
}

[data-bs-theme="dark"] .pt-badge-audit--profile,
[data-bs-theme="dark"] .pt-badge-audit--prefs {
    color: #e9d5ff;
    background: rgba(168, 85, 247, 0.22);
    border-color: rgba(192, 132, 252, 0.35);
}

[data-bs-theme="dark"] .pt-badge-audit--security {
    color: #fed7aa;
    background: rgba(249, 115, 22, 0.2);
    border-color: rgba(251, 146, 60, 0.35);
}

[data-bs-theme="dark"] .pt-badge-audit--config {
    color: #c7d2fe;
    background: rgba(99, 102, 241, 0.22);
    border-color: rgba(129, 140, 248, 0.35);
}

/* Prioridade: botão do dropdown custom (cor vinda do cadastro) */
.ticket-prioridade-field {
    font-weight: 600;
    border-width: 2px;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.ticket-prioridade-field:focus-visible {
    box-shadow: 0 0 0 0.2rem color-mix(in srgb, var(--pt-prioridade-cor, var(--pt-primary)) 35%, transparent);
}

.pt-prioridade-widget {
    position: relative;
}

.pt-prioridade-chevron {
    flex-shrink: 0;
    margin-left: 0.5rem;
    transition: transform 0.2s ease;
    opacity: 0.85;
}

.pt-prioridade-widget.is-open .pt-prioridade-chevron {
    transform: rotate(180deg);
}

.pt-prioridade-list {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 1080;
    border-radius: 0.375rem;
    border: 1px solid var(--bs-border-color);
    overflow: hidden;
    overflow-y: auto;
    max-height: min(280px, 55vh);
}

.pt-prioridade-option {
    padding: 0.65rem 0.85rem;
    font-weight: 600;
    cursor: pointer;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    transition: filter 0.15s ease, box-shadow 0.15s ease;
}

[data-bs-theme="dark"] .pt-prioridade-option {
    border-bottom-color: rgba(255, 255, 255, 0.08);
}

.pt-prioridade-option:last-child {
    border-bottom: none;
}

.pt-prioridade-option:hover,
.pt-prioridade-option:focus-visible {
    filter: brightness(1.05);
    outline: 2px solid rgba(255, 255, 255, 0.55);
    outline-offset: -2px;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35);
}

[data-bs-theme="dark"] .pt-prioridade-option:hover,
[data-bs-theme="dark"] .pt-prioridade-option:focus-visible {
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.2);
}

.pt-prioridade-option.is-selected {
    box-shadow: inset 3px 0 0 currentColor;
}

/* Combobox com busca dentro do painel (pt-select-search.js) */
.pt-combobox {
    position: relative;
    width: 100%;
}

.pt-combobox-native {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
    opacity: 0;
    pointer-events: none;
}

.pt-combobox-trigger {
    text-align: left;
    cursor: pointer;
    background-color: var(--bs-body-bg);
    color: var(--bs-body-color);
}

.pt-combobox-trigger.form-select {
    background-image: none;
    padding-right: 0.75rem;
}

.pt-combobox-trigger:focus-visible {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.25);
}

.pt-combobox-chevron {
    font-size: var(--pt-text-label);
    transition: transform 0.2s ease;
}

.pt-combobox.is-open .pt-combobox-chevron {
    transform: rotate(180deg);
}

.pt-combobox-panel {
    position: absolute;
    top: calc(100% + 2px);
    left: 0;
    right: 0;
    z-index: 1060;
    display: flex;
    flex-direction: column;
    max-height: min(320px, 70vh);
    background: var(--bs-body-bg);
    color: var(--bs-body-color);
    border: 1px solid var(--bs-border-color);
    border-radius: var(--bs-border-radius, 0.375rem);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.12);
}

[data-bs-theme="dark"] .pt-combobox-panel {
    box-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.45);
}

.pt-combobox-panel[hidden] {
    display: none !important;
}

.pt-combobox-panel:not([hidden]) {
    display: flex !important;
}

.pt-combobox-search-bar {
    flex-shrink: 0;
    padding: 0.4rem 0.5rem;
    border-bottom: 2px solid var(--bs-primary);
    background: var(--bs-body-bg);
}

.pt-combobox-search-input {
    width: 100%;
}

.pt-combobox-list {
    flex: 1 1 auto;
    overflow-y: auto;
    min-height: 0;
    padding: 0.25rem 0;
}

.pt-combobox-option {
    padding: 0.45rem 0.75rem;
    cursor: pointer;
    font-size: var(--pt-text-body);
    line-height: 1.35;
}

.pt-combobox-option:hover:not(.disabled),
.pt-combobox-option:focus-visible {
    outline: 2px solid rgba(var(--bs-primary-rgb), 0.45);
    outline-offset: -2px;
    background-color: var(--bs-secondary-bg);
}

.pt-combobox-option.is-selected {
    box-shadow: inset 3px 0 0 var(--bs-primary);
    background-color: rgba(var(--bs-primary-rgb), 0.08);
}

.pt-combobox-option.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@media (max-width: 767.98px) {
    .pt-table-mobile-cards thead {
        display: none;
    }

    .pt-table-mobile-cards,
    .pt-table-mobile-cards tbody,
    .pt-table-mobile-cards tr,
    .pt-table-mobile-cards td {
        display: block;
        width: 100%;
    }

    .pt-table-mobile-cards tr {
        display: flex;
        flex-direction: column;
        background: var(--bs-body-bg);
        border: 1px solid var(--pt-border-soft);
        border-radius: 12px;
        margin-bottom: 0.75rem;
        padding: 0.15rem 0;
        box-shadow: 0 6px 20px rgba(2, 6, 23, 0.05);
    }

    .pt-table-mobile-cards td[data-label="Título"],
    .pt-table-mobile-cards td[data-label="Nome"],
    .pt-table-mobile-cards td[data-label="Assunto"],
    .pt-table-mobile-cards td[data-label="Ação"] {
        order: -20;
        border-bottom: 0;
        padding-top: 0.7rem;
        padding-bottom: 0.15rem;
        font-weight: 800;
        font-size: var(--pt-text-body);
        line-height: 1.3;
        color: var(--bs-body-color);
    }

    .pt-table-mobile-cards td[data-label="Título"]::before,
    .pt-table-mobile-cards td[data-label="Nome"]::before,
    .pt-table-mobile-cards td[data-label="Assunto"]::before,
    .pt-table-mobile-cards td[data-label="Ação"]::before {
        display: none;
    }

    .pt-table-mobile-cards td[data-label="#"],
    .pt-table-mobile-cards td[data-label="ID"] {
        order: -19;
        padding-top: 0;
        padding-bottom: 0.35rem;
        border-bottom: 1px dashed rgba(148, 163, 184, 0.22);
        font-size: var(--pt-text-label);
        font-weight: 600;
        color: var(--bs-secondary-color);
    }

    .pt-table-mobile-cards td[data-label="#"]::before,
    .pt-table-mobile-cards td[data-label="ID"]::before {
        display: none;
    }

    .pt-table-mobile-cards--tickets td[data-label="Ações"] {
        order: 100;
        margin-top: 0.15rem;
        padding-top: 0.75rem;
        border-top: 1px dashed rgba(148, 163, 184, 0.28);
    }

    .pt-table-mobile-cards td {
        border: 0;
        border-bottom: 1px dashed rgba(148, 163, 184, 0.28);
        padding: 0.52rem 0.8rem;
        text-align: left !important;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .pt-table-mobile-cards td::before {
        content: attr(data-label);
        display: block;
        font-size: var(--pt-text-label);
        text-transform: uppercase;
        letter-spacing: 0.05em;
        color: rgba(100, 116, 139, 0.95);
        margin-bottom: 0.2rem;
        font-weight: 700;
    }

    .pt-table-mobile-cards td:last-child {
        border-bottom: 0;
    }

    .pt-table-mobile-cards td[colspan]::before {
        display: none;
    }

    .pt-table-mobile-cards td[colspan] {
        text-align: center !important;
    }

    .pt-table-mobile-cards td[data-label="Ações"] {
        padding-top: 0.65rem;
    }

    .pt-table-mobile-cards td[data-label="Ações"] .pt-table-actions {
        display: flex;
        flex-wrap: wrap;
        gap: 0.45rem;
        justify-content: flex-start;
        align-items: center;
    }

    .pt-table-mobile-cards td[data-label="Ações"] .pt-table-actions.justify-content-end {
        justify-content: flex-start !important;
    }

    .pt-table-mobile-cards td[data-label="Ações"] .pt-table-actions > a,
    .pt-table-mobile-cards td[data-label="Ações"] .pt-table-actions > button,
    .pt-table-mobile-cards td[data-label="Ações"] .pt-table-actions > form {
        flex: 0 0 auto;
    }

    .pt-table-mobile-cards td[data-label="Ações"] .pt-table-actions .btn {
        min-height: 44px;
        padding-left: 0.7rem;
        padding-right: 0.7rem;
    }

    .pt-table-mobile-cards td[data-label="Ações"] .pt-table-actions form {
        margin: 0;
    }
}

.filtro-grupo .pt-combobox,
.filtro-grupo .pt-combobox-trigger {
    width: 100%;
    max-width: 100%;
}

.navbar-brand {
    font-weight: 600;
}

.pt-mobile-navbar-wrap {
    padding-left: 0.35rem;
    padding-right: 0.35rem;
}

.pt-mobile-brand {
    margin-right: 0.35rem;
    padding-top: 0;
    padding-bottom: 0;
    line-height: 1;
    max-width: none;
    overflow: visible;
    height: 24px;
}

.pt-mobile-brand-logo {
    width: auto !important;
    height: 28px !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: contain;
    object-position: left center;
    filter: brightness(0) invert(1);
    flex-shrink: 0;
    display: block;
}

.pt-navbar.d-lg-none .navbar-brand img.pt-mobile-brand-logo {
    width: auto !important;
    height: 24px !important;
}

@media (max-width: 380px) {
    .pt-mobile-brand {
        height: 20px;
    }
    .pt-mobile-brand-logo {
        height: 20px !important;
    }
    .pt-navbar.d-lg-none .navbar-brand img.pt-mobile-brand-logo {
        height: 20px !important;
    }
}

.pt-navbar.d-lg-none {
    min-height: 56px;
}

.pt-navbar.d-lg-none .container-fluid {
    min-height: 56px;
    align-items: center;
}

.pt-navbar.d-lg-none .navbar-toggler {
    padding: 0.3rem 0.55rem;
}

.pt-mobile-menu {
    margin-top: 0.55rem;
    border-top: 1px solid rgba(255, 255, 255, 0.14);
    padding-top: 0.6rem;
}

.pt-mobile-menu-links .nav-link {
    border-radius: 10px;
    padding: 0.55rem 0.7rem;
    font-weight: 600;
}

.pt-mobile-menu-links .nav-link.active {
    background: rgba(255, 255, 255, 0.2);
}

.pt-mobile-menu-account {
    margin-top: 0.45rem;
    padding-top: 0.45rem;
    border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.pt-mobile-pagebar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.65rem 0.85rem;
    border-bottom: 1px solid var(--pt-border-soft);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1005;
}

.pt-mobile-pagebar-main {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
}

.pt-mobile-pagebar-icon {
    width: 1.85rem;
    height: 1.85rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    color: var(--pt-primary);
    flex-shrink: 0;
}

.pt-mobile-pagebar-titles {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.15;
}

.pt-mobile-pagebar-title {
    font-weight: 700;
    font-size: var(--pt-text-body);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pt-mobile-pagebar-subtitle {
    font-size: var(--pt-text-label);
    color: #64748b;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pt-mobile-pagebar-actions {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-shrink: 0;
}

.pt-mobile-pagebar-actions .btn-group .btn {
    padding-inline: 0.45rem;
}

@media (max-width: 767.98px) {
    .pt-mobile-pagebar {
        flex-wrap: wrap;
        align-items: flex-start;
        gap: 0.5rem 0.75rem;
        padding-left: max(0.85rem, env(safe-area-inset-left));
        padding-right: max(0.85rem, env(safe-area-inset-right));
    }

    .pt-mobile-pagebar-main {
        flex: 1 1 12rem;
        min-width: 0;
    }

    .pt-mobile-pagebar-actions {
        flex: 1 1 auto;
        flex-wrap: wrap;
        justify-content: flex-end;
        max-width: 100%;
        row-gap: 0.35rem;
    }
}

.pt-filter-active-dot {
    display: inline-block;
    width: 0.42rem;
    height: 0.42rem;
    margin-left: 0.25rem;
    border-radius: 999px;
    background: var(--pt-primary);
    vertical-align: middle;
}

.pt-btn-loading {
    pointer-events: none;
}

.pt-btn-loading .pt-btn-spinner {
    vertical-align: -0.125em;
}

.pt-sidebar-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    padding: 0.15rem 0.2rem;
    border-radius: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
}

.pt-sidebar-logo-img {
    width: 148px;
    height: auto;
    max-width: 100%;
    max-height: 58px;
    object-fit: contain;
    /* Logo branca sobre sidebar escura */
    filter: brightness(0) invert(1);
}

.pt-sidebar .navbar-brand {
    font-size: var(--pt-text-body);
    font-weight: 700;
    letter-spacing: 0.02em;
}

/* Wordmark já vem no logo — evita duplicar "Protect" */
.pt-sidebar .pt-brand-text {
    display: none;
}

.pt-page-hero {
    background: linear-gradient(135deg, rgba(var(--pt-primary-rgb, 13, 110, 253), 0.11), rgba(var(--pt-info-glow-rgb, 13, 202, 240), 0.10));
    border: 1px solid rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    border-radius: var(--pt-radius-lg);
    padding: 1rem 1.15rem;
    backdrop-filter: blur(4px);
}

.pt-modern-card {
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-lg);
    background: linear-gradient(180deg, var(--pt-surface), var(--pt-surface-soft));
    box-shadow: var(--pt-shadow-soft);
}

.pt-modern-card:hover {
    box-shadow: var(--pt-shadow-strong);
    transform: translateY(-1px);
}

.pt-modern-card .card-body {
    padding: 1.25rem;
}

.pt-subpanel {
    background: var(--bs-tertiary-bg);
    border-color: var(--bs-border-color) !important;
}

@media (max-width: 768px) {
    .table-responsive {
        font-size: var(--pt-text-label);
    }
    .btn-sm {
        padding: 0.25rem 0.5rem;
        font-size: var(--pt-text-label);
    }
    .stat-card { flex-direction: column; text-align: center; }
    .navbar-collapse { max-height: 70vh; overflow-y: auto; }
}

@media (max-width: 991.98px) {
    .pt-page-shell {
        padding-top: 0.85rem !important;
    }
}
@media (max-width: 576px) {
    .card-body { padding: 0.75rem; }
    .table { font-size: var(--pt-text-label); }
    .atrasado-item { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
}

/* Cabeçalho de página (contexto + CTA) */
.pt-page-header {
    gap: 1rem;
}

.pt-page-header .pt-page-header-lead {
    font-size: var(--pt-text-body);
    color: var(--bs-secondary-color);
    line-height: 1.45;
    max-width: 52ch;
    margin-bottom: 0;
}

/* Dashboard — sem entrada decorativa (produto carrega na tarefa) */
.dashboard-modern {
    animation: none;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--pt-text-headline);
    color: #fff;
}
.stat-card-primary .stat-card-icon { background: var(--pt-primary, var(--pt-ink)); }
.stat-card-danger .stat-card-icon { background: #dc2626; }
.stat-card-success .stat-card-icon { background: #15803d; }
.stat-card-info .stat-card-icon { background: var(--pt-primary-2, var(--pt-ink-2)); }
.stat-card-warning .stat-card-icon { background: var(--pt-signal); color: #1c2833; }

.stat-card-content {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}
.stat-card-label {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    text-transform: none;
    letter-spacing: 0.02em;
}
.stat-card-value {
    font-size: var(--pt-text-display);
    font-weight: 700;
    color: var(--pt-text, #1c2833);
    font-variant-numeric: tabular-nums;
}
.stat-card-danger .stat-card-value { color: #dc2626; }
.stat-card-success .stat-card-value { color: #15803d; }

.chart-container {
    position: relative;
}

.empty-state {
    text-align: center;
    padding: 1.6rem 1.25rem;
    color: #64748b;
    border: 1px dashed rgba(148, 163, 184, 0.42);
    border-radius: var(--pt-radius-md);
    background: rgba(255, 255, 255, 0.6);
}
.empty-state i {
    font-size: var(--pt-text-display);
    display: block;
    margin-bottom: 0.5rem;
    opacity: 0.55;
    color: var(--pt-primary);
}

/* Bloco padrão para telas/listas sem resultados */
.pt-empty-block {
    text-align: center;
    padding: 1.75rem 1.25rem;
    border: 1px dashed rgba(148, 163, 184, 0.42);
    border-radius: var(--pt-radius-md);
    background: rgba(255, 255, 255, 0.6);
    color: var(--bs-secondary-color);
}

.pt-empty-block i {
    font-size: var(--pt-text-display);
    display: block;
    margin-bottom: 0.45rem;
    opacity: 0.6;
    color: var(--pt-primary);
}

.pt-empty-block-title {
    font-weight: 700;
    color: var(--bs-body-color);
    margin-bottom: 0.15rem;
}

.pt-empty-block-text {
    margin: 0;
}

[data-bs-theme="dark"] .pt-empty-block {
    background: rgba(0, 0, 0, 0.18);
    border-color: rgba(148, 163, 184, 0.22);
}

.pt-empty-block--compact {
    padding: 1.1rem 0.85rem;
}

.pt-empty-block--compact i {
    font-size: var(--pt-text-display);
    margin-bottom: 0.35rem;
}

.pt-empty-block--compact .pt-empty-block-title {
    font-size: var(--pt-text-body);
}

.pt-empty-block--compact .pt-empty-block-text {
    font-size: var(--pt-text-label);
}

.pt-empty-block--inline {
    padding: 0.85rem 0.65rem;
    border-style: dashed;
}

.pt-empty-block--inline i {
    font-size: var(--pt-text-headline);
    margin-bottom: 0.25rem;
}

.atrasados-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.atrasado-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid #f0f0f0;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s, border-color 0.2s;
}
.atrasado-item:hover {
    background: rgba(220, 53, 69, 0.06);
    border-color: rgba(220, 53, 69, 0.3);
}
.atrasado-item-main {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}
.atrasado-id {
    font-weight: 600;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-variant-numeric: tabular-nums;
    color: var(--pt-ink);
    flex-shrink: 0;
}
.atrasado-titulo {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.atrasado-prazo {
    font-size: var(--pt-text-label);
    color: #dc2626;
    font-weight: 500;
    flex-shrink: 0;
}

/* Dashboard premium — SaaS ops panel */
.dashboard-premium {
    --dash-elevate: 0 1px 2px rgba(15, 42, 58, 0.04), 0 10px 32px rgba(15, 42, 58, 0.07);
    --dash-elevate-hover: 0 2px 4px rgba(15, 42, 58, 0.05), 0 14px 36px rgba(15, 42, 58, 0.1);
}

.dashboard-premium .dashboard-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1.1rem 1.75rem;
    margin-bottom: 1.35rem;
    padding: 1.4rem 1.5rem;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    background:
        radial-gradient(90% 120% at 100% -10%, rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.12) 0%, transparent 52%),
        linear-gradient(165deg, var(--pt-surface, #ffffff) 0%, var(--pt-surface-soft, #f4f7f8) 140%);
    border: 1px solid rgba(15, 42, 58, 0.08);
    border-radius: var(--pt-radius-xl, 16px);
    box-shadow: var(--dash-elevate);
}

.dashboard-premium .dashboard-hero::before {
    display: none;
}

.dashboard-hero-notify {
    margin-left: 0.5rem;
    font-weight: 600;
    color: var(--pt-ink, #093A87);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.dashboard-hero-notify:hover {
    color: var(--pt-ink-2, #07306E);
}

.dashboard-mine-meta,
.dashboard-setor-meta {
    font-size: var(--pt-text-label);
    font-weight: 500;
    color: var(--pt-muted, #5b6b7a);
    letter-spacing: 0;
    text-transform: none;
}

.dashboard-mine-meta {
    margin-left: auto;
}

.dashboard-mine-meta a,
.dashboard-setor-meta a {
    color: var(--pt-ink, #093A87);
    font-weight: 600;
    text-decoration: none;
}

.dashboard-mine-meta a:hover,
.dashboard-setor-meta a:hover {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.dashboard-mine-meta a:focus-visible,
.dashboard-setor-meta a:focus-visible,
.dashboard-hero-notify:focus-visible {
    outline: 3px solid rgba(15, 42, 58, 0.28);
    outline-offset: 2px;
    border-radius: 4px;
}

.dashboard-setor-meta {
    margin: -0.25rem 0 1rem;
}

[data-bs-theme="dark"] .dashboard-hero-notify,
[data-bs-theme="dark"] .dashboard-mine-meta a,
[data-bs-theme="dark"] .dashboard-setor-meta a {
    color: var(--bs-emphasis-color, #f8fafc);
}

@media (max-width: 575.98px) {
    .dashboard-mine-meta {
        margin-left: 0;
        width: 100%;
    }
}

.dashboard-premium .dashboard-hero::after {
    display: none;
}

.dashboard-hero-main {
    position: relative;
    z-index: 1;
    min-width: 0;
}

.dashboard-hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.dashboard-hero-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.dashboard-hero-quick-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    min-height: 36px;
    padding: 0.35rem 0.7rem;
    border-radius: 8px;
    border: 1px solid var(--pt-border-soft);
    background: var(--pt-panel, #f7f9fa);
    color: var(--pt-text, #1c2833);
    text-decoration: none;
    font-size: var(--pt-text-label);
    font-weight: 600;
    cursor: pointer;
    touch-action: manipulation;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.dashboard-hero-quick-link i {
    opacity: 0.85;
}

.dashboard-hero-quick-link:hover {
    border-color: rgba(15, 42, 58, 0.22);
    background: rgba(15, 42, 58, 0.05);
    color: var(--pt-ink);
}

.dashboard-hero-quick-link:focus-visible {
    outline: 2px solid var(--pt-ink);
    outline-offset: 2px;
}

.dashboard-hero-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: var(--pt-text-label);
    font-weight: 600;
    padding: 0.35rem 0.65rem;
    border-radius: 8px;
    background: rgba(15, 42, 58, 0.06);
    color: var(--pt-ink);
    border: 1px solid rgba(15, 42, 58, 0.1);
}

.dashboard-hero-chip--muted {
    background: var(--pt-panel, #f7f9fa);
    color: var(--pt-muted, #5b6b7a);
    border-color: var(--pt-border-soft);
}

.dashboard-hero-chip--link {
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.dashboard-hero-chip--link:hover {
    border-color: rgba(15, 42, 58, 0.22);
    background: rgba(15, 42, 58, 0.08);
    color: var(--pt-ink);
}

.dashboard-hero-chip--link:focus-visible {
    outline: 2px solid var(--pt-ink);
    outline-offset: 2px;
}

.dashboard-hero-chip .bi {
    font-size: var(--pt-text-label);
    opacity: 0.85;
}

.dashboard-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: var(--pt-text-label);
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--pt-muted, #5b6b7a);
    margin: 0;
}

.dashboard-hero-eyebrow-mark {
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 2px;
    background: var(--pt-signal, #10CAF0);
    box-shadow: 0 0 0 3px rgba(16, 202, 240, 0.22);
    flex-shrink: 0;
}

.dashboard-hero-title {
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-headline);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.25;
    color: var(--pt-ink, #093A87);
    margin: 0.35rem 0 0.5rem;
    text-wrap: balance;
}

.dashboard-hero-btn {
    min-height: 40px;
    padding: 0.5rem 1rem;
    border-radius: var(--pt-radius-md, 8px);
    font-weight: 600;
    font-size: var(--pt-text-label);
}

.dashboard-premium .dashboard-hero-btn.btn-primary {
    background: var(--pt-primary, #093A87);
    border-color: var(--pt-primary, #093A87);
    color: #fff;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12) inset, 0 6px 16px rgba(15, 42, 58, 0.18);
}

.dashboard-premium .dashboard-hero-btn.btn-primary:hover {
    background: var(--pt-primary-2, #07306E);
    border-color: var(--pt-primary-2, #07306E);
    color: #fff;
}

.dashboard-premium .dashboard-hero-btn.btn-outline-secondary {
    border-color: rgba(15, 42, 58, 0.16);
    color: var(--pt-ink, #093A87);
    background: rgba(255, 255, 255, 0.72);
}

.dashboard-premium .dashboard-hero-btn.btn-outline-secondary:hover {
    background: var(--pt-surface, #fff);
    border-color: rgba(15, 42, 58, 0.28);
    color: var(--pt-ink, #093A87);
}

.dashboard-hero-lead {
    font-size: var(--pt-text-body);
    color: var(--pt-text, #1c2833);
    opacity: 0.78;
    line-height: 1.5;
    max-width: 52ch;
}

.dashboard-hero-greeting {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    margin-bottom: 0.35rem !important;
}

.dashboard-hero-load {
    font-variant-numeric: tabular-nums;
    color: inherit;
    text-decoration: none;
}

.dashboard-hero-load:hover {
    text-decoration: underline;
    text-underline-offset: 0.12em;
}

.dashboard-hero-load:focus-visible {
    outline: 3px solid rgba(15, 42, 58, 0.28);
    outline-offset: 3px;
    border-radius: 4px;
}

.dashboard-hero-load.is-critical {
    color: #dc2626;
}

.dashboard-hero-load--signal {
    color: #9a6418;
}

.dashboard-hero-meta {
    margin-top: 0.35rem;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-text, #1c2833);
    opacity: 0.72;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.45rem;
}

.dashboard-hero-meta-link {
    color: var(--pt-ink-2, #07306E);
    text-decoration: none;
    font-weight: 700;
}

.dashboard-hero-meta-link:hover {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.dashboard-hero-meta-link:focus-visible {
    outline: 3px solid rgba(15, 42, 58, 0.28);
    outline-offset: 2px;
    border-radius: 4px;
}

.dashboard-hero-scope {
    color: var(--pt-ink-2, #07306E);
}

.dashboard-hero-meta-sep {
    opacity: 0.55;
}

.dashboard-hero-updated {
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: var(--pt-text-label);
    font-weight: 500;
    color: var(--pt-muted, #5B6B7A);
    font-variant-numeric: tabular-nums;
}

.dashboard-stats-alert {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 0 0 1rem;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(220, 38, 38, 0.28);
    border-radius: var(--pt-radius-lg, 12px);
    background: #fef2f2;
    color: var(--pt-text, #1C2833);
}

.dashboard-stats-alert-body {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
}

.dashboard-stats-alert-body i {
    color: #dc2626;
    margin-top: 0.15rem;
}

.dashboard-stats-alert-body strong {
    display: block;
}

.dashboard-stats-alert-body span {
    color: var(--pt-muted, #5B6B7A);
    font-size: var(--pt-text-body);
}

.stat-card--error .stat-card-value {
    color: var(--pt-muted, #5B6B7A);
}

[data-bs-theme="dark"] .dashboard-stats-alert {
    background: rgba(220, 38, 38, 0.12);
    border-color: rgba(220, 38, 38, 0.35);
}

.dashboard-hero-refresh {
    color: var(--pt-ink-2, #07306E);
    text-decoration: none;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.dashboard-hero-refresh:hover {
    text-decoration: underline;
}

.dashboard-hero-refresh.is-loading {
    opacity: 0.65;
    pointer-events: none;
}

.dashboard-kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.25rem;
    height: 1.25rem;
    padding: 0 0.3rem;
    border: 1px solid var(--pt-border-soft);
    border-radius: 4px;
    background: var(--pt-surface-soft, #f4f7f8);
    color: var(--pt-ink-2, #07306E);
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: var(--pt-text-label);
    font-weight: 700;
    line-height: 1;
}

.dashboard-hotkeys-hint {
    margin-top: 0.45rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.65rem;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
}

.dashboard-hotkeys-hint-label {
    color: var(--pt-ink-2, #07306E);
    font-weight: 700;
}

.dashboard-hotkeys-hint-item {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
}

.dashboard-scope-toggle {
    display: inline-flex;
    position: relative;
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-md, 8px);
    overflow: hidden;
    background: var(--pt-surface-soft, #f4f7f8);
}

.dashboard-scope-toggle-btn {
    padding: 0.28rem 0.65rem;
    font-size: var(--pt-text-label);
    font-weight: 700;
    color: var(--pt-muted, #5b6b7a);
    text-decoration: none;
    min-height: 32px;
    display: inline-flex;
    align-items: center;
}

.dashboard-scope-toggle-btn:hover {
    color: var(--pt-ink, #093A87);
    background: rgba(15, 42, 58, 0.04);
}

.dashboard-scope-toggle-btn.is-active {
    background: var(--pt-primary, #093A87);
    color: #fff;
}

.dashboard-scope-toggle-btn:focus-visible {
    outline: 3px solid rgba(15, 42, 58, 0.28);
    outline-offset: 2px;
    z-index: 1;
}

.dashboard-scope-toggle.is-loading {
    pointer-events: none;
    opacity: 0.72;
}

.dashboard-scope-toggle.is-loading::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.45) 50%,
        transparent 100%
    );
    background-size: 200% 100%;
    animation: dashboard-scope-shimmer 0.9s ease-in-out infinite;
}

@keyframes dashboard-scope-shimmer {
    from { background-position: 100% 0; }
    to { background-position: -100% 0; }
}

@media (prefers-reduced-motion: reduce) {
    .dashboard-scope-toggle.is-loading::after {
        animation: none;
        background: rgba(255, 255, 255, 0.35);
    }
}

.dashboard-modern.is-navigating {
    cursor: progress;
}

[data-bs-theme="dark"] .dashboard-hero-scope {
    color: var(--bs-emphasis-color, #e2e8f0);
}

[data-bs-theme="dark"] .dashboard-scope-toggle {
    background: rgba(15, 23, 42, 0.72);
    border-color: rgba(148, 163, 184, 0.22);
}

[data-bs-theme="dark"] .dashboard-scope-toggle-btn {
    color: #94a3b8;
}

[data-bs-theme="dark"] .dashboard-scope-toggle-btn:hover {
    color: #e2e8f0;
    background: rgba(148, 163, 184, 0.1);
}

[data-bs-theme="dark"] .dashboard-scope-toggle-btn.is-active {
    background: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.55);
    color: #f8fafc;
    border-color: rgba(147, 197, 253, 0.28);
    box-shadow: inset 0 0 0 1px rgba(147, 197, 253, 0.12);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-hero-btn.btn-primary {
    background: var(--pt-primary, #093A87);
    border-color: var(--pt-primary, #093A87);
    color: #fff;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset, 0 8px 20px rgba(0, 0, 0, 0.35);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-hero-btn.btn-primary:hover {
    background: var(--pt-primary-2, #07306E);
    border-color: var(--pt-primary-2, #07306E);
    color: #fff;
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-hero-btn.btn-outline-secondary {
    background: rgba(15, 23, 42, 0.72);
    border-color: rgba(148, 163, 184, 0.35);
    color: #d7e2f1;
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-hero-btn.btn-outline-secondary:hover {
    background: rgba(30, 41, 59, 0.9);
    border-color: rgba(147, 197, 253, 0.4);
    color: #f1f5f9;
}

[data-bs-theme="dark"] .pt-ui-premium .btn-primary,
[data-bs-theme="dark"] .btn-primary {
    background: var(--pt-primary, #093A87);
    border-color: var(--pt-primary, #093A87);
    color: #fff;
}

[data-bs-theme="dark"] .pt-ui-premium .btn-primary:hover,
[data-bs-theme="dark"] .btn-primary:hover {
    background: var(--pt-primary-2, #07306E);
    border-color: var(--pt-primary-2, #07306E);
    color: #fff;
}

[data-bs-theme="dark"] .dashboard-kbd {
    background: rgba(0, 0, 0, 0.25);
    border-color: rgba(148, 163, 184, 0.28);
    color: #e2e8f0;
}

[data-bs-theme="dark"] .dashboard-hotkeys-hint-label {
    color: #e2e8f0;
}

[data-bs-theme="dark"] .dashboard-scope-toggle.is-loading::after {
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.12) 50%,
        transparent 100%
    );
    background-size: 200% 100%;
}

[data-bs-theme="dark"] .dashboard-hero-load.is-critical {
    color: #f87171;
}

.dashboard-hero-stat {
    font-weight: 700;
    color: var(--bs-body-color);
}

.dashboard-hero-stat--danger {
    color: #dc3545;
}

.dashboard-hero-stat--success {
    color: #198754;
}

.dashboard-hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.dashboard-section {
    margin-bottom: 2rem;
}

/* Zona de triagem: ritmo mais apertado até Atenção / SLA */
.dashboard-hero + .dashboard-section,
.dashboard-section--priority {
    margin-bottom: 1.5rem;
}

.dashboard-section--priority + .dashboard-section {
    margin-bottom: 1.5rem;
}

/* Bloco analítico: mais ar antes de Distribuição / Análise */
.dashboard-section--secondary {
    margin-top: 0.5rem;
    margin-bottom: 2.5rem;
}

.dashboard-section--last {
    margin-bottom: 0.5rem;
}

.dashboard-section--priority .dashboard-section-label {
    font-size: var(--pt-text-title);
    color: var(--pt-ink, #093A87);
}

.dashboard-section--priority .dashboard-section-head::after {
    display: none;
}

.dashboard-section-head {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.dashboard-section-head::after {
    content: "";
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, var(--pt-border-soft) 0%, transparent 100%);
}

.dashboard-section-label {
    font-size: var(--pt-text-title);
    font-weight: 700;
    letter-spacing: -0.015em;
    text-transform: none;
    color: var(--pt-ink, #093A87);
    margin: 0;
    flex-shrink: 0;
    text-wrap: balance;
}

.dashboard-premium .dashboard-section-head {
    margin-bottom: 1.1rem;
}

.dashboard-premium .dashboard-scope-toggle {
    border-radius: 999px;
    padding: 2px;
    background: rgba(15, 42, 58, 0.05);
    border-color: transparent;
}

.dashboard-premium .dashboard-scope-toggle-btn {
    border-radius: 999px;
    min-height: 30px;
    padding: 0.28rem 0.8rem;
}

.dashboard-premium .dashboard-dist-chip {
    border-radius: var(--pt-radius-lg, 12px);
    border: 1px solid rgba(15, 42, 58, 0.08);
    background: linear-gradient(180deg, var(--pt-surface, #fff) 0%, var(--pt-surface-soft, #f4f7f8) 160%);
    box-shadow: 0 1px 2px rgba(15, 42, 58, 0.03);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.dashboard-premium .dashboard-dist-chip:hover {
    border-color: rgba(15, 42, 58, 0.16);
    box-shadow: var(--dash-elevate);
    background: var(--pt-surface, #fff);
}

.dashboard-section-head--stack {
    align-items: stretch;
}

.dashboard-section-head-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1.25rem;
    width: 100%;
}

.dashboard-kpi-rail {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0.35rem;
    margin-left: auto;
}

.dashboard-kpi-rail-item {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    min-width: 4.25rem;
    min-height: 40px;
    padding: 0.28rem 0.55rem;
    border: 1px solid transparent;
    border-radius: var(--pt-radius-md, 8px);
    background: transparent;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.18s ease, background-color 0.18s ease;
}

.dashboard-kpi-rail-item:hover {
    border-color: var(--pt-border-soft);
    background: var(--pt-surface-soft, #f4f7f8);
}

.dashboard-kpi-rail-item:focus-visible {
    outline: 3px solid rgba(15, 42, 58, 0.28);
    outline-offset: 2px;
}

.dashboard-kpi-rail-item.is-critical {
    border-color: rgba(220, 38, 38, 0.28);
    background: rgba(220, 38, 38, 0.05);
}

.dashboard-kpi-rail-item.is-critical .dashboard-kpi-rail-value {
    color: #dc2626;
}

.dashboard-kpi-rail-item--soft {
    opacity: 0.85;
}

.dashboard-kpi-rail-value {
    font-size: var(--pt-text-body);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    line-height: 1.15;
    color: var(--pt-muted, #5b6b7a);
}

.dashboard-kpi-rail-label {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    line-height: 1.2;
}

.dashboard-card--lead {
    box-shadow: var(--pt-shadow-soft);
    border-color: rgba(220, 38, 38, 0.28);
    background: linear-gradient(180deg, rgba(220, 38, 38, 0.04) 0%, var(--pt-surface, #fff) 2.5rem);
}

/* Filas da mesa: painel de lista, sem card teatral */
.dashboard-queue {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    padding: 0.85rem 1rem 1rem;
    background: var(--pt-surface, #fff);
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-lg, 12px);
    min-height: 100%;
}

.dashboard-queue--danger {
    border-color: rgba(220, 38, 38, 0.22);
    background: linear-gradient(180deg, rgba(220, 38, 38, 0.04) 0%, var(--pt-surface, #fff) 3.5rem);
}

.dashboard-queue--warning {
    border-color: rgba(201, 133, 42, 0.28);
    background: linear-gradient(180deg, rgba(201, 133, 42, 0.05) 0%, var(--pt-surface, #fff) 3.5rem);
}

.dashboard-queue--lead {
    box-shadow: 0 0 0 1px rgba(220, 38, 38, 0.12);
}

.dashboard-queue-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
}

.dashboard-queue-title {
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-body);
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--pt-text, #1c2833);
    display: inline-flex;
    align-items: baseline;
    gap: 0.45rem;
}

.dashboard-queue-count {
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    font-variant-numeric: tabular-nums;
}

.dashboard-queue--danger .dashboard-queue-count {
    color: #dc2626;
}

.dashboard-queue--warning .dashboard-queue-count {
    color: #9a6418;
}

.dashboard-queue-more {
    font-size: var(--pt-text-label);
    font-weight: 700;
    color: var(--pt-ink-2, #07306E);
    text-decoration: none;
    white-space: nowrap;
}

.dashboard-queue-more:hover {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.dashboard-queue-more:focus-visible {
    outline: 3px solid rgba(15, 42, 58, 0.28);
    outline-offset: 2px;
    border-radius: 4px;
}

.dashboard-queue .atrasados-list--premium {
    margin: 0;
}

.dashboard-queue .atrasado-item {
    border-radius: var(--pt-radius-md, 8px);
}

[data-bs-theme="dark"] .dashboard-queue {
    background: var(--pt-surface, #1e293b);
}

[data-bs-theme="dark"] .dashboard-queue--danger {
    border-color: rgba(248, 113, 113, 0.35);
    background: linear-gradient(180deg, rgba(248, 113, 113, 0.08) 0%, var(--pt-surface, #1e293b) 3.5rem);
}

[data-bs-theme="dark"] .dashboard-queue--warning {
    border-color: rgba(224, 168, 74, 0.35);
    background: linear-gradient(180deg, rgba(224, 168, 74, 0.08) 0%, var(--pt-surface, #1e293b) 3.5rem);
}

[data-bs-theme="dark"] .dashboard-queue--lead {
    box-shadow: 0 0 0 1px rgba(248, 113, 113, 0.2);
}

[data-bs-theme="dark"] .dashboard-hero-load--signal {
    color: #e0a84a;
}

[data-bs-theme="dark"] .dashboard-hero-meta-link {
    color: #e2e8f0;
}

[data-bs-theme="dark"] .dashboard-hero-lead,
[data-bs-theme="dark"] .dashboard-hero-meta {
    color: #e2e8f0;
    opacity: 0.82;
}

[data-bs-theme="dark"] .dashboard-card-stat--context {
    color: #94a3b8;
}

[data-bs-theme="dark"] .dashboard-hotkeys-hint {
    color: #94a3b8;
}

.dashboard-atencao-grid--risk-first > [class*="col-"] + [class*="col-"] {
    margin-top: 0;
}

@media (max-width: 575.98px) {
    .dashboard-kpi-rail {
        margin-left: 0;
        width: 100%;
    }

    .dashboard-kpi-rail-item {
        flex: 1 1 calc(33.333% - 0.35rem);
        min-width: 5rem;
    }
}

[data-bs-theme="dark"] .dashboard-section-label {
    color: var(--bs-emphasis-color, #f8fafc);
}

[data-bs-theme="dark"] .dashboard-kpi-rail-value {
    color: var(--bs-emphasis-color, #e2e8f0);
}

[data-bs-theme="dark"] .dashboard-card--lead {
    border-color: rgba(248, 113, 113, 0.35);
    background: linear-gradient(180deg, rgba(248, 113, 113, 0.08) 0%, transparent 2.5rem);
}

[data-bs-theme="dark"] .dashboard-kpi-rail-item:hover {
    background: rgba(0, 0, 0, 0.2);
}

.dashboard-section-hint {
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
    opacity: 0.75;
}

.stat-card-value--sm {
    font-size: var(--pt-text-headline);
}

.setor-ranking--grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
    gap: 0.55rem;
}

.dashboard-section--metrics {
    margin-bottom: 1.5rem;
}

.dashboard-metrics-aside {
    margin-top: 0.65rem;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.55rem;
}

.dashboard-metrics-aside a {
    color: var(--pt-ink-2, #07306E);
    text-decoration: none;
    font-weight: 700;
}

.dashboard-metrics-aside a:hover {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.dashboard-card-header-link {
    font-size: var(--pt-text-label);
    font-weight: 700;
    color: var(--pt-ink-2, #07306E);
    text-decoration: none;
    white-space: nowrap;
}

.dashboard-card-header-link:hover {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.dashboard-card-title .dashboard-card-stat {
    margin-left: 0.4rem;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    vertical-align: baseline;
}

.dashboard-premium .stat-card {
    position: relative;
    border: 1px solid rgba(15, 42, 58, 0.08);
    border-radius: var(--pt-radius-xl, 16px);
    background: linear-gradient(180deg, #ffffff 0%, var(--pt-surface-soft, #f4f7f8) 160%);
    box-shadow: var(--dash-elevate);
    padding: 1.1rem 1.15rem;
    min-height: 100%;
    transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

/* Side-stripe removido (DESIGN ban) — status via ícone/valor */
.dashboard-premium .stat-card-accent {
    display: none;
}

.stat-card-primary .stat-card-accent { background: var(--pt-primary, var(--pt-ink)); }
.stat-card-danger .stat-card-accent { background: #dc2626; }
.stat-card-success .stat-card-accent { background: #15803d; }
.stat-card-info .stat-card-accent { background: var(--pt-primary-2, var(--pt-ink-2)); }
.stat-card-warning .stat-card-accent { background: var(--pt-signal); }

.dashboard-premium .stat-card-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    font-size: var(--pt-text-title);
    box-shadow: none;
}

.dashboard-premium .stat-card-primary .stat-card-icon {
    background: rgba(15, 42, 58, 0.08);
    color: var(--pt-ink, #093A87);
}

.dashboard-premium .stat-card-danger .stat-card-icon {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
}

.dashboard-premium .stat-card-success .stat-card-icon {
    background: rgba(21, 128, 61, 0.1);
    color: #15803d;
}

.dashboard-premium .stat-card-info .stat-card-icon {
    background: rgba(22, 56, 73, 0.1);
    color: var(--pt-ink-2, #07306E);
}

.dashboard-premium .stat-card-warning .stat-card-icon {
    background: rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.14);
    color: #0e7490;
}

.dashboard-premium .stat-card-label {
    font-size: var(--pt-text-label);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--pt-muted, #5b6b7a);
}

.dashboard-premium .stat-card-value {
    font-size: var(--pt-text-display);
    font-weight: 700;
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
    color: var(--pt-ink, #093A87);
    line-height: 1.1;
}

.stat-card--link {
    text-decoration: none;
    color: inherit;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.dashboard-premium .stat-card--link:hover {
    border-color: rgba(15, 42, 58, 0.16);
    background: var(--pt-surface, #fff);
    transform: none;
    box-shadow: var(--dash-elevate-hover);
}

.stat-card--link:focus-visible {
    outline: 3px solid rgba(15, 42, 58, 0.28);
    outline-offset: 2px;
}

.stat-card-arrow {
    margin-left: auto;
    font-size: var(--pt-text-body);
    opacity: 0;
    color: var(--pt-ink-2, #07306E);
    transition: opacity 0.18s ease, transform 0.18s ease;
    flex-shrink: 0;
}

.stat-card--link:hover .stat-card-arrow {
    opacity: 1;
    transform: translate(2px, -2px);
}

.dashboard-premium .dashboard-card {
    border: 1px solid rgba(15, 42, 58, 0.08);
    border-radius: var(--pt-radius-xl, 16px);
    box-shadow: var(--dash-elevate);
    background: var(--pt-surface, #fff);
    overflow: hidden;
}

.dashboard-premium .dashboard-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
    padding: 1.05rem 1.35rem;
    background: linear-gradient(180deg, var(--pt-surface-soft, #f4f7f8) 0%, rgba(255, 255, 255, 0) 100%);
    border-bottom: 1px solid rgba(15, 42, 58, 0.06);
}

.dashboard-card-header-text {
    min-width: 0;
}

.dashboard-card-stat {
    flex-shrink: 0;
    font-size: var(--pt-text-title);
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
    color: var(--pt-primary-2);
    line-height: 1.2;
}

.dashboard-card-stat--context {
    font-size: var(--pt-text-label);
    font-weight: 600;
    font-family: var(--pt-font-mono, "IBM Plex Mono", ui-monospace, monospace);
    letter-spacing: 0;
    color: var(--pt-muted, #5b6b7a);
}

.dashboard-queue-panel .dashboard-card-title .dashboard-card-stat--context {
    margin-left: 0.35rem;
    vertical-align: baseline;
}

.dashboard-card-stat-unit {
    display: block;
    font-size: var(--pt-text-label);
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--bs-secondary-color);
    margin-top: 0.1rem;
}

.dashboard-card-eyebrow {
    display: block;
    font-size: var(--pt-text-label);
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--bs-secondary-color);
    margin-bottom: 0.15rem;
}

.dashboard-premium .dashboard-card-header h5,
.dashboard-card-title {
    font-weight: 600;
    font-size: var(--pt-text-title);
    line-height: 1.3;
    text-wrap: balance;
}

.dashboard-inline-link {
    font-size: inherit;
    font-weight: 600;
    text-decoration: none;
    color: var(--pt-primary-2);
}

.dashboard-inline-link:hover {
    text-decoration: underline;
}

.dashboard-list-footer-link {
    font-size: var(--pt-text-label);
    font-weight: 600;
    text-decoration: none;
    color: var(--pt-primary-2);
}

.dashboard-list-footer-link:hover {
    text-decoration: underline;
}

.dashboard-premium .pt-empty-block {
    border-radius: 12px;
    border: 1px dashed var(--pt-border-soft);
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.03);
}

.atrasados-list--premium > li {
    list-style: none;
}

.atrasados-list--premium > li > .atrasado-item {
    display: flex;
    width: 100%;
}

.dashboard-dist-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.dashboard-dist-grid > li {
    list-style: none;
    display: contents;
}

.dashboard-dist-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.65rem 0.45rem 0.75rem;
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-md, 8px);
    background: var(--pt-surface, #fff);
    text-decoration: none;
    color: inherit;
    transition: background-color 0.18s ease, border-color 0.18s ease;
}

.dashboard-dist-chip:hover {
    background: var(--pt-surface-soft, #f4f7f8);
    border-color: rgba(15, 42, 58, 0.28);
}

.dashboard-dist-chip-count {
    font-size: var(--pt-text-body);
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    color: var(--pt-primary-2);
    min-width: 1.25rem;
    text-align: center;
}

.dashboard-dist-chip-arrow {
    font-size: var(--pt-text-label);
    opacity: 0;
    color: var(--pt-primary-2);
    transition: opacity 0.15s ease;
}

.dashboard-dist-chip:hover .dashboard-dist-chip-arrow,
.dashboard-dist-chip:focus-visible .dashboard-dist-chip-arrow {
    opacity: 1;
}

.dashboard-dist-chip-label .pt-badge {
    margin: 0;
}

.setor-ranking--premium > li {
    list-style: none;
}

.setor-ranking-item--link {
    display: block;
    text-decoration: none;
    color: inherit;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.setor-ranking-item--link:hover {
    background: var(--pt-surface-soft, #f4f7f8);
    border-color: rgba(15, 42, 58, 0.22);
}

.setor-ranking--premium .setor-ranking-item {
    flex-direction: column;
    align-items: stretch;
}

.dashboard-badge,
.dashboard-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.75rem;
    min-height: 1.75rem;
    padding: 0.2rem 0.55rem;
    border-radius: var(--pt-radius-md, 8px);
    font-size: var(--pt-text-label);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    line-height: 1.2;
    border: 1px solid transparent;
}

.dashboard-badge--warning,
.dashboard-count--warning {
    background: rgba(201, 133, 42, 0.14);
    color: #9a6418;
    border-color: rgba(201, 133, 42, 0.32);
}

.dashboard-badge--danger,
.dashboard-count--danger {
    background: rgba(220, 38, 38, 0.1);
    color: #b91c1c;
    border-color: rgba(220, 38, 38, 0.28);
}

.dashboard-delta {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    min-height: 1.75rem;
    padding: 0.25rem 0.55rem;
    border-radius: var(--pt-radius-md, 8px);
    font-size: var(--pt-text-label);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    border: 1px solid transparent;
}

.dashboard-delta--up,
.dashboard-delta--down,
.dashboard-delta--volume {
    background: rgba(15, 42, 58, 0.06);
    color: var(--pt-ink-2, #07306E);
    border-color: rgba(15, 42, 58, 0.14);
}

[data-bs-theme="dark"] .dashboard-delta--up,
[data-bs-theme="dark"] .dashboard-delta--down,
[data-bs-theme="dark"] .dashboard-delta--volume {
    background: rgba(226, 232, 240, 0.08);
    color: #e2e8f0;
    border-color: rgba(226, 232, 240, 0.18);
}

.dashboard-delta-pct {
    font-weight: 600;
    opacity: 0.9;
}

.chart-container--premium {
    position: relative;
    width: 100%;
    min-height: 200px;
    padding: 0.5rem 0.25rem;
    border-radius: 12px;
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.03);
}

.chart-container--bar {
    height: min(320px, 42vh);
    min-height: 240px;
}

.dashboard-card-body--list {
    padding: 0.85rem 1rem 1rem;
}

.dashboard-atencao-grid {
    align-items: stretch;
}

.dashboard-queue-panel {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 22rem;
}

.dashboard-queue-panel .dashboard-card-header {
    flex-shrink: 0;
}

.dashboard-queue-scroll {
    flex: 1 1 auto;
    min-height: 0;
    max-height: 28rem;
    overflow: auto;
    overscroll-behavior: contain;
}

.atrasados-list--premium {
    gap: 0.45rem;
}

.dashboard-premium .atrasado-item {
    border-radius: 10px;
    border: 1px solid rgba(15, 42, 58, 0.08);
    background: var(--pt-surface, #fff);
    padding: 0.7rem 0.85rem;
}

.dashboard-premium .atrasado-item--stack {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.4rem;
}

.dashboard-premium .atrasado-item-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.5rem 0.65rem;
    min-width: 0;
}

.dashboard-premium .atrasado-item-row--meta {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.5rem;
}

.dashboard-premium .atrasado-item--stack .atrasado-titulo {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-ink, #093A87);
    line-height: 1.3;
}

.dashboard-premium .atrasado-item--stack .atrasado-id {
    font-size: var(--pt-text-label);
}

.dashboard-premium .atrasado-item--stack .atrasado-prazo {
    font-size: var(--pt-text-label);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    justify-self: end;
}

.dashboard-premium .atrasado-meta {
    min-width: 0;
    flex-wrap: nowrap;
    overflow: hidden;
    gap: 0.5rem;
}

.dashboard-premium .atrasado-meta-item {
    max-width: 11rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-premium .atrasado-meta-status {
    flex-shrink: 0;
    justify-self: end;
}

.dashboard-premium .atrasado-meta-status .pt-badge {
    font-size: var(--pt-text-label);
}

.dashboard-premium .atrasado-item--warning:hover {
    background: rgba(251, 191, 36, 0.1);
    border-color: rgba(251, 191, 36, 0.35);
}

.dashboard-premium .atrasado-item--danger:hover,
.dashboard-premium .atrasado-item:hover {
    background: rgba(248, 113, 113, 0.08);
    border-color: rgba(248, 113, 113, 0.3);
}

.atrasado-prazo--warning {
    color: #d97706 !important;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.dashboard-premium .atrasado-prazo {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.empty-state--premium i {
    font-size: var(--pt-text-display-lg);
    opacity: 0.45;
    color: var(--pt-primary);
}

.dashboard-premium .dashboard-card-danger {
    border: 1px solid rgba(220, 38, 38, 0.22);
    box-shadow: var(--pt-shadow-soft);
    background: color-mix(in srgb, #dc2626 3%, var(--pt-surface, #fff));
}

.dashboard-premium .dashboard-card-warning {
    border: 1px solid rgba(201, 133, 42, 0.28);
    box-shadow: var(--pt-shadow-soft);
    background: color-mix(in srgb, #c9852a 4%, var(--pt-surface, #fff));
}

.dashboard-premium .dashboard-card-danger .dashboard-card-header {
    background: rgba(220, 38, 38, 0.06);
}

.dashboard-premium .dashboard-card-warning .dashboard-card-header {
    background: rgba(201, 133, 42, 0.08);
}

@media (max-width: 575.98px) {
    .dashboard-premium .dashboard-hero-actions {
        width: 100%;
    }
    .dashboard-premium .dashboard-hero-actions .btn {
        flex: 1 1 auto;
    }
    .stat-card-arrow {
        opacity: 0.5;
    }
}

[data-bs-theme="dark"] .dashboard-hero-stat--danger {
    color: #fca5a5;
}

[data-bs-theme="dark"] .dashboard-hero-stat--success {
    color: #86efac;
}

[data-bs-theme="dark"] .dashboard-premium .stat-card {
    background: linear-gradient(145deg, var(--pt-surface) 0%, var(--pt-surface-soft) 100%);
}

[data-bs-theme="dark"] .dashboard-premium {
    --dash-elevate: 0 1px 2px rgba(0, 0, 0, 0.2), 0 12px 32px rgba(0, 0, 0, 0.28);
    --dash-elevate-hover: 0 2px 6px rgba(0, 0, 0, 0.24), 0 16px 40px rgba(0, 0, 0, 0.34);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-hero {
    background:
        radial-gradient(90% 120% at 100% -10%, rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.14) 0%, transparent 52%),
        linear-gradient(165deg, #1e293b 0%, #152033 140%);
    border-color: rgba(148, 163, 184, 0.16);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-hero-title {
    color: #f1f5f9;
}

[data-bs-theme="dark"] .dashboard-premium .stat-card {
    background: linear-gradient(180deg, #1e293b 0%, #162033 160%);
    border-color: rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .dashboard-premium .stat-card-value {
    color: #f8fafc;
}

[data-bs-theme="dark"] .dashboard-premium .stat-card-primary .stat-card-icon {
    background: rgba(148, 163, 184, 0.14);
    color: #e2e8f0;
}

[data-bs-theme="dark"] .dashboard-sla-strip {
    background:
        radial-gradient(80% 120% at 0% 0%, rgba(16, 202, 240, 0.06) 0%, transparent 55%),
        linear-gradient(180deg, #1e293b 0%, #162033 180%);
    border-color: rgba(148, 163, 184, 0.16);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
}

[data-bs-theme="dark"] .dashboard-sla-strip-pct {
    border-color: rgba(148, 163, 184, 0.16);
}

[data-bs-theme="dark"] .dashboard-sla-strip-value {
    color: #f8fafc;
}

[data-bs-theme="dark"] .dashboard-sla-strip-status {
    color: #e2e8f0;
}

[data-bs-theme="dark"] .dashboard-sla-strip-hint {
    color: #94a3b8;
}

[data-bs-theme="dark"] .dashboard-sla-strip-metrics dt {
    color: #94a3b8;
}

[data-bs-theme="dark"] .dashboard-sla-strip-metrics dd {
    color: #f1f5f9;
}

[data-bs-theme="dark"] .dashboard-analise-details {
    background: #1e293b;
    border-color: rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-hero::after {
    background: radial-gradient(ellipse at center, rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22) 0%, transparent 68%);
}

[data-bs-theme="dark"] .dashboard-premium .stat-card {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
}

[data-bs-theme="dark"] .dashboard-hero-chip {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.16);
    border-color: rgba(148, 163, 184, 0.2);
}

[data-bs-theme="dark"] .dashboard-hero-quick-link {
    background: rgba(0, 0, 0, 0.18);
    border-color: rgba(148, 163, 184, 0.18);
}

[data-bs-theme="dark"] .dashboard-hero-quick-link:hover {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    border-color: rgba(96, 165, 250, 0.28);
}

[data-bs-theme="dark"] .dashboard-hero-chip--muted {
    background: rgba(0, 0, 0, 0.2);
}

[data-bs-theme="dark"] .dashboard-sla-metric--tile {
    background: rgba(0, 0, 0, 0.18);
}

[data-bs-theme="dark"] .setor-ranking-bar {
    background: rgba(255, 255, 255, 0.08);
}

[data-bs-theme="dark"] .dashboard-premium .atrasado-item {
    background: rgba(0, 0, 0, 0.15);
}

[data-bs-theme="dark"] .chart-container--premium {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
}

[data-bs-theme="dark"] .dashboard-badge--warning,
[data-bs-theme="dark"] .dashboard-count--warning {
    color: #e0a84a;
    background: rgba(201, 133, 42, 0.18);
    border-color: rgba(201, 133, 42, 0.35);
}

[data-bs-theme="dark"] .dashboard-badge--danger,
[data-bs-theme="dark"] .dashboard-count--danger {
    color: #fecaca;
    background: rgba(248, 113, 113, 0.18);
    border-color: rgba(248, 113, 113, 0.32);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-card-danger {
    background: color-mix(in srgb, #dc2626 12%, var(--pt-surface, #121a28));
    border-color: rgba(248, 113, 113, 0.28);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-card-warning {
    background: color-mix(in srgb, #c9852a 12%, var(--pt-surface, #121a28));
    border-color: rgba(224, 168, 74, 0.3);
}

.dashboard-hero-stat--warn {
    color: #d97706;
    font-weight: 700;
}

.dashboard-kpi-row > [class*="col-xl"] {
    flex: 1 1 0;
    min-width: 10rem;
}

.dashboard-kpi-row--triage > [class*="col-"] {
    flex: 1 1 0;
    min-width: 0;
}

.dashboard-throughput-meta {
    flex-shrink: 0;
    margin-left: auto;
    font-size: var(--pt-text-label);
    font-weight: 500;
    color: var(--pt-muted, #5b6b7a);
    letter-spacing: 0;
    text-transform: none;
}

.dashboard-throughput-meta strong {
    color: var(--pt-text, #1c2833);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

[data-bs-theme="dark"] .dashboard-throughput-meta strong {
    color: var(--bs-emphasis-color, #f8fafc);
}

@media (max-width: 575.98px) {
    .dashboard-section-head:has(.dashboard-throughput-meta) {
        flex-wrap: wrap;
        gap: 0.5rem 1rem;
    }

    .dashboard-throughput-meta {
        margin-left: 0;
        width: 100%;
    }
}

.dashboard-sla-legend {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    margin-left: auto;
}

.dashboard-sla-strip {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: var(--pt-space-md, 16px) var(--pt-space-lg, 24px);
    align-items: center;
    padding: var(--pt-space-md, 16px) var(--pt-space-lg, 24px);
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-xl, 16px);
    background: linear-gradient(180deg, var(--pt-surface, #ffffff) 0%, var(--pt-surface-soft, #f4f7f8) 180%);
    box-shadow: var(--dash-elevate, var(--pt-shadow-premium));
}

.dashboard-sla-strip--ok {
    border-color: rgba(21, 128, 61, 0.22);
    background:
        radial-gradient(80% 120% at 0% 0%, rgba(21, 128, 61, 0.08) 0%, transparent 55%),
        linear-gradient(180deg, var(--pt-surface, #ffffff) 0%, rgba(21, 128, 61, 0.04) 180%);
}

.dashboard-sla-strip--risk {
    border-color: rgba(234, 88, 12, 0.28);
    background:
        radial-gradient(80% 120% at 0% 0%, rgba(234, 88, 12, 0.1) 0%, transparent 55%),
        linear-gradient(180deg, var(--pt-surface, #ffffff) 0%, rgba(234, 88, 12, 0.05) 180%);
}

.dashboard-sla-strip--critical {
    border-color: rgba(220, 38, 38, 0.24);
    background:
        radial-gradient(80% 120% at 0% 0%, rgba(220, 38, 38, 0.08) 0%, transparent 55%),
        linear-gradient(180deg, var(--pt-surface, #ffffff) 0%, rgba(220, 38, 38, 0.04) 180%);
}

.dashboard-sla-strip-pct {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 6.5rem;
    padding-right: var(--pt-space-md, 16px);
    border-right: 1px solid var(--pt-border-soft);
}

.dashboard-sla-strip-value {
    font-family: var(--pt-font-mono);
    font-size: var(--pt-text-display);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
    line-height: 1.05;
    color: var(--pt-ink, #093A87);
}

.dashboard-sla-strip--ok .dashboard-sla-strip-value { color: var(--pt-success, #15803d); }
.dashboard-sla-strip--risk .dashboard-sla-strip-value { color: #9a6418; }
.dashboard-sla-strip--critical .dashboard-sla-strip-value { color: var(--pt-danger, #dc2626); }

.dashboard-sla-strip-status {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: var(--pt-text-label);
    font-weight: 700;
    color: var(--pt-text, #1c2833);
}

.dashboard-sla-strip-status .bi {
    font-size: var(--pt-text-body);
    opacity: 0.9;
}

.dashboard-sla-strip--ok .dashboard-sla-strip-status .bi { color: var(--pt-success, #15803d); }
.dashboard-sla-strip--risk .dashboard-sla-strip-status .bi { color: #c2410c; }
.dashboard-sla-strip--critical .dashboard-sla-strip-status .bi { color: var(--pt-danger, #dc2626); }

.dashboard-sla-strip-body {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    min-width: 0;
}

.dashboard-sla-strip-hint {
    font-size: var(--pt-text-label);
    color: var(--pt-muted, #5b6b7a);
    line-height: 1.35;
    text-wrap: pretty;
    margin: 0;
}

.dashboard-sla-strip-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 0;
    padding: 0;
}

.dashboard-sla-strip-metrics dt {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    margin: 0 0 0.15rem;
    text-transform: none;
    letter-spacing: 0;
}

.dashboard-sla-strip-metrics dd {
    margin: 0;
    font-size: var(--pt-text-body);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: var(--pt-text, #1c2833);
}

.dashboard-sla-strip-late {
    color: var(--pt-danger, #dc2626);
}

.dashboard-sla-strip-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: var(--pt-space-sm, 8px);
    min-width: 11.5rem;
}

.dashboard-sla-strip-cta,
.dashboard-sla-strip-secondary {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

.dashboard-analise-details {
    border: 1px solid rgba(15, 42, 58, 0.08);
    border-radius: var(--pt-radius-xl, 16px);
    background: var(--pt-surface, #fff);
    box-shadow: var(--dash-elevate, var(--pt-shadow-premium));
    padding: 0.35rem 0.35rem 0.85rem;
}

.dashboard-analise-summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.5rem 1rem;
    padding: 0.85rem 1.1rem;
    border-radius: var(--pt-radius-lg, 12px);
    transition: background-color 0.18s ease;
}

.dashboard-analise-summary:hover {
    background: var(--pt-surface-soft, #f4f7f8);
}

.dashboard-analise-summary::-webkit-details-marker {
    display: none;
}

.dashboard-analise-summary::before {
    content: "";
    width: 0.45rem;
    height: 0.45rem;
    border-right: 2px solid var(--pt-muted, #5b6b7a);
    border-bottom: 2px solid var(--pt-muted, #5b6b7a);
    transform: rotate(-45deg);
    margin-right: 0.15rem;
    transition: transform 0.15s ease;
}

.dashboard-analise-details[open] .dashboard-analise-summary::before {
    transform: rotate(45deg);
}

.dashboard-analise-details[open] .dashboard-analise-summary {
    margin-bottom: 0.35rem;
}

.dashboard-analise-summary-hint {
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
    font-size: var(--pt-text-label);
}

.dashboard-analise-details .dashboard-analise-row {
    padding: 0 0.75rem;
}

@media (max-width: 991.98px) {
    .dashboard-sla-strip {
        grid-template-columns: 1fr;
        gap: var(--pt-space-md, 16px);
    }

    .dashboard-sla-strip-pct {
        flex-direction: row;
        align-items: baseline;
        gap: 0.75rem;
        min-width: 0;
        padding-right: 0;
        border-right: 0;
        padding-bottom: 0.65rem;
        border-bottom: 1px solid var(--pt-border-soft);
        margin-bottom: 0;
    }

    .dashboard-sla-strip-actions {
        flex-direction: row;
        flex-wrap: wrap;
        min-width: 0;
    }

    .dashboard-sla-strip-cta,
    .dashboard-sla-strip-secondary {
        flex: 1 1 auto;
    }
}

@media (max-width: 575.98px) {
    .dashboard-sla-strip-metrics {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
}

.dashboard-sla-panel .dashboard-card-body {
    padding: 1.1rem 1.35rem;
}

.dashboard-chart-error {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1.25rem;
    background: var(--pt-surface-soft, #f4f7f8);
    border-radius: var(--pt-radius-md, 8px);
    z-index: 2;
}

.dashboard-chart-error[hidden] {
    display: none !important;
}

.dashboard-chart-error-title {
    font-size: var(--pt-text-body);
    font-weight: 700;
    color: var(--pt-text, #1c2833);
}

.dashboard-chart-error-text {
    font-size: var(--pt-text-label);
    color: var(--pt-muted, #5b6b7a);
    max-width: 22rem;
}

.dashboard-async-chart.is-error .pt-skeleton-chart-bars {
    display: none !important;
}

.dashboard-async-chart.is-error .dashboard-chart-canvas {
    opacity: 0 !important;
}

.dashboard-sla-metrics-grid {
    height: 100%;
    align-content: center;
}

.dashboard-sla-metric--tile {
    height: 100%;
    padding: 0.85rem 1rem;
    border-radius: var(--pt-radius-md);
    border: 1px solid var(--pt-border-soft);
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.03);
}

.dashboard-sla-metric-icon {
    display: block;
    font-size: var(--pt-text-title);
    margin-bottom: 0.35rem;
    opacity: 0.9;
}

.dashboard-sla-metric-label {
    display: block;
    font-size: var(--pt-text-label);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--bs-secondary-color);
    margin-bottom: 0.2rem;
}

.dashboard-sla-metric-value {
    display: block;
    font-size: var(--pt-text-headline);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.dashboard-sla-metric-sub {
    display: block;
    font-size: var(--pt-text-label);
    color: var(--bs-secondary-color);
    margin-top: 0.25rem;
}

.dashboard-card-body--chart {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.dashboard-analise-row {
    align-items: stretch;
}

.dashboard-analise-row > [class*="col-"] {
    min-width: 0;
}

.dashboard-analise-chart-card {
    min-height: 0;
}

@media (min-width: 1200px) {
    .dashboard-analise-chart-card .chart-container--bar {
        min-height: 280px;
    }
}

@media (max-width: 991.98px) {
    .chart-container--bar {
        height: 260px;
    }
}

.setor-ranking--premium .setor-ranking-item {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
    border-radius: 12px;
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.03);
    border: 1px solid var(--pt-border-soft);
    padding: 0.65rem 0.85rem;
}

.setor-ranking-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    min-width: 0;
}

.setor-ranking-bar {
    height: 4px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.06);
    overflow: hidden;
}

.setor-ranking-bar span {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--pt-primary), var(--pt-primary-2));
    transform: scaleX(var(--pt-bar, 0));
    transform-origin: left center;
    transition: transform 0.4s ease;
}

.setor-ranking-pos--top {
    /* legado: ranking sem medalha/gamificação */
    background: transparent;
    color: inherit;
}

.empty-state--compact {
    padding: 1.5rem 1rem;
}

.empty-state--compact i {
    font-size: var(--pt-text-display);
    margin-bottom: 0.35rem;
}

.setor-ranking-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    justify-content: flex-end;
}

.dashboard-premium .atrasado-item {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.65rem;
}

.dashboard-premium .atrasado-item-main {
    align-items: flex-start;
    flex: 1 1 12rem;
}

.atrasado-item-text {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.atrasado-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.65rem;
    font-size: var(--pt-text-label);
    color: var(--pt-muted, #5b6b7a);
    font-weight: 500;
}

.atrasado-meta span,
.atrasado-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.atrasado-meta-status {
    display: inline-flex;
    align-items: center;
}

@media (max-width: 575.98px) {
    .dashboard-premium .atrasado-item-row {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .dashboard-premium .atrasado-item--stack .atrasado-prazo {
        grid-column: 1 / -1;
        justify-self: start;
    }

    .dashboard-premium .atrasado-item-row--meta {
        grid-template-columns: 1fr;
    }

    .dashboard-premium .atrasado-meta {
        flex-wrap: wrap;
    }

    .dashboard-premium .atrasado-meta-status {
        justify-self: start;
    }

    .dashboard-queue-panel {
        min-height: 0;
    }

    .dashboard-queue-scroll {
        max-height: none;
    }
}

.dashboard-list-footer {
    padding-top: 0.75rem;
    margin-top: 0.35rem;
    border-top: 1px solid var(--pt-border-soft);
    text-align: center;
}

[data-bs-theme="dark"] .dashboard-hero-stat--warn {
    color: #fde68a;
}

[data-bs-theme="dark"] .setor-ranking--premium .setor-ranking-item {
    background: rgba(0, 0, 0, 0.15);
    border-color: rgba(148, 163, 184, 0.14);
}

.setor-ranking {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.setor-ranking-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    border: 1px solid #e5eaf2;
    border-radius: 8px;
    padding: 0.55rem 0.7rem;
}

.setor-ranking-main {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.setor-ranking-pos {
    font-weight: 800;
    color: #64748b;
}

.setor-ranking-name {
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Barra de tickets: ordenação + Filtro + ações */
.tickets-toolbar {
    background: var(--pt-surface);
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-md);
    padding: 0.75rem 1rem;
    box-shadow: var(--pt-shadow-soft);
    margin-bottom: 1rem !important;
    align-items: center;
}

.tickets-toolbar-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.55rem 0.85rem;
    padding: 0.25rem 0.65rem 0.25rem 0.5rem;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.035);
    border: 1px solid rgba(15, 23, 42, 0.07);
}

.tickets-toolbar-count {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--bs-secondary-color);
    white-space: nowrap;
}

.tickets-toolbar-count-num {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    color: var(--bs-body-color);
}

.tickets-toolbar-count-label {
    font-weight: 500;
}

.tickets-toolbar-ordenar .form-select {
    max-width: 12rem;
    min-width: 9.5rem;
    border-radius: 999px;
    background: var(--pt-surface);
    border-color: rgba(15, 23, 42, 0.1);
    font-size: var(--pt-text-label);
    padding-top: 0.32rem;
    padding-bottom: 0.32rem;
}

.tickets-toolbar .pt-toolbar-toggle,
.filtros-card .pt-toolbar-toggle {
    border-radius: var(--pt-radius-md) !important;
    height: 38px;
    padding: 0.4rem 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: transparent;
    color: var(--bs-body-color);
    box-shadow: none;
    transform: none;
}

.tickets-toolbar .pt-toolbar-toggle i,
.filtros-card .pt-toolbar-toggle i {
    font-size: var(--pt-text-body);
    line-height: 1;
}

.tickets-toolbar .pt-toolbar-toggle:hover,
.filtros-card .pt-toolbar-toggle:hover {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.28);
}

.tickets-toolbar .pt-toolbar-toggle:focus-visible,
.filtros-card .pt-toolbar-toggle:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

.tickets-toolbar .pt-toolbar-toggle.is-active,
.tickets-toolbar .pt-toolbar-toggle.is-active:hover,
.filtros-card .pt-toolbar-toggle.is-active,
.filtros-card .pt-toolbar-toggle.is-active:hover {
    border-color: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.35);
    background: var(--pt-ink, #093A87);
    color: #fff;
    box-shadow: none;
    transform: none;
}

.tickets-toolbar .pt-toolbar-toggle.is-active:focus-visible,
.filtros-card .pt-toolbar-toggle.is-active:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

.tickets-toolbar .btn-filtro-toggle[aria-expanded="true"],
.tickets-toolbar .btn-filtro-toggle[aria-expanded="true"]:hover {
    border-color: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.35);
    background: var(--pt-ink, #093A87);
    color: #fff;
    box-shadow: none;
    transform: none;
}

.tickets-toolbar .pt-toolbar-toggle.is-active i,
.filtros-card .pt-toolbar-toggle.is-active i {
    color: inherit;
}

.tickets-toolbar .pt-toolbar-action,
.filtros-card .pt-toolbar-action {
    border-radius: var(--pt-radius-md) !important;
    height: 38px;
    padding: 0.4rem 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.tickets-toolbar .pt-toolbar-action.btn-outline-success,
.filtros-card .pt-toolbar-action.btn-outline-success {
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
    color: var(--pt-primary);
}

.tickets-toolbar .pt-toolbar-action.btn-primary,
.filtros-card .pt-toolbar-action.btn-primary {
    box-shadow: 0 12px 26px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
}

.tickets-toolbar .pt-toolbar-action.btn-primary:hover,
.tickets-toolbar .pt-toolbar-action.btn-primary:focus,
.filtros-card .pt-toolbar-action.btn-primary:hover,
.filtros-card .pt-toolbar-action.btn-primary:focus {
    box-shadow: 0 14px 30px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.28);
}

.tickets-toolbar .pt-toolbar-action.btn-outline-success:hover,
.tickets-toolbar .pt-toolbar-action.btn-outline-success:focus,
.filtros-card .pt-toolbar-action.btn-outline-success:hover,
.filtros-card .pt-toolbar-action.btn-outline-success:focus {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.08);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.32);
    color: var(--pt-primary);
}

.tickets-toolbar .pt-toolbar-action.btn-outline-danger:hover,
.tickets-toolbar .pt-toolbar-action.btn-outline-danger:focus,
.filtros-card .pt-toolbar-action.btn-outline-danger:hover,
.filtros-card .pt-toolbar-action.btn-outline-danger:focus {
    background: rgba(220, 53, 69, 0.08);
}

.tickets-toolbar .btn-filtro-toggle .filtros-toggle-chevron {
    display: inline-block;
    transition: transform 0.25s ease;
    vertical-align: middle;
}

/* Kanban: usa largura do content-shell e altura da janela (dvh) */
.tickets-kanban-viewport {
    --pt-kanban-chrome: 200px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0 0 0.35rem;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: clamp(280px, calc(100vh - var(--pt-kanban-chrome)), 1100px);
    max-height: calc(100vh - var(--pt-kanban-chrome));
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(100, 116, 139, 0.35) transparent;
}

@supports (height: 100dvh) {
    .tickets-kanban-viewport {
        min-height: clamp(280px, calc(100dvh - var(--pt-kanban-chrome)), 1100px);
        max-height: calc(100dvh - var(--pt-kanban-chrome));
    }
}

@media (max-width: 991.98px) {
    .tickets-kanban-viewport {
        --pt-kanban-chrome: 230px;
    }
}

@media (max-width: 575.98px) {
    .tickets-kanban-viewport {
        --pt-kanban-chrome: 250px;
        min-height: 0;
        max-height: none;
        overflow: visible;
    }
}

.tickets-kanban-viewport::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.tickets-kanban-viewport::-webkit-scrollbar-thumb {
    background: rgba(100, 116, 139, 0.35);
    border-radius: 999px;
}

.tickets-kanban-wrap {
    --kanban-cols: 5;
    display: grid;
    grid-template-columns: repeat(var(--kanban-cols), minmax(0, 1fr));
    gap: clamp(0.55rem, 1.2vw, 1rem);
    width: 100%;
    flex: 1 1 auto;
    min-height: 0;
    min-width: 0;
    align-items: stretch;
    align-content: stretch;
    padding: 0.08rem 0;
}

/* Ecrãs médios: evita colunas demasiado estreitas; permite várias linhas */
@media (max-width: 1199.98px) {
    .tickets-kanban-wrap {
        grid-template-columns: repeat(auto-fill, minmax(min(100%, 228px), 1fr));
        overflow-y: auto;
        overflow-x: hidden;
        scrollbar-width: thin;
        scrollbar-color: rgba(100, 116, 139, 0.35) transparent;
        align-content: start;
    }
}

/* Telemóvel: colunas empilhadas, altura confortável por bloco */
@media (max-width: 575.98px) {
    .tickets-kanban-wrap {
        grid-template-columns: 1fr;
        overflow: visible;
        flex: none;
    }
}

.tickets-kanban-board-empty {
    width: 100%;
    flex-shrink: 0;
    border: 1px dashed rgba(15, 42, 58, 0.18);
    border-radius: 8px;
    padding: 1.35rem 1rem;
    color: var(--pt-muted, #5b6b7a);
    text-align: center;
    background: var(--pt-panel, #f7f9fa);
}

.tickets-kanban-board-empty::before {
    content: "\f47f";
    font-family: "bootstrap-icons";
    display: block;
    font-size: var(--pt-text-display);
    opacity: 0.55;
    margin-bottom: 0.35rem;
    color: var(--pt-ink);
}

.tickets-kanban-col {
    min-width: 0;
    background: var(--pt-panel, #f7f9fa);
    border: 1px solid var(--pt-border-soft);
    border-radius: 8px;
    min-height: 160px;
    height: 100%;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: none;
    position: relative;
}

@media (max-width: 575.98px) {
    .tickets-kanban-col {
        height: auto;
        max-height: none;
    }

    .tickets-kanban-list {
        max-height: min(320px, 42vh);
        flex: 0 1 auto;
    }
}

@supports (height: 100dvh) {
    @media (max-width: 575.98px) {
        .tickets-kanban-list {
            max-height: min(320px, 42dvh);
        }
    }
}

.tickets-kanban-col::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 3px;
    border-radius: 7px 7px 0 0;
    background: #6b7c8a;
    opacity: 1;
    z-index: 4;
    pointer-events: none;
}

.tickets-kanban-col[data-status-slug="aberto"]::before { background: #2563eb; }
.tickets-kanban-col[data-status-slug="encaminhado"]::before { background: #c9852a; }
.tickets-kanban-col[data-status-slug="aguardando cliente"]::before { background: #64748b; }
.tickets-kanban-col[data-status-slug="agendado"]::before { background: #0f766e; }
.tickets-kanban-col[data-status-slug="finalizado"]::before { background: #15803d; }
.tickets-kanban-col[data-status-slug="cancelado"]::before { background: #b42318; }

.tickets-kanban-col[data-status-slug="em análise"]::before,
.tickets-kanban-col[data-status-slug="em analise"]::before { background: #475569; }

.tickets-kanban-col[data-status-slug="em tratamento"]::before { background: #07306E; }

.tickets-kanban-col[data-status-slug="sem status"]::before { background: #6b7c8a; }

.tickets-kanban-col.is-drop-target {
    border-color: var(--pt-ink);
    box-shadow: inset 0 0 0 2px rgba(15, 42, 58, 0.12);
    background: rgba(15, 42, 58, 0.04);
}

.tickets-kanban-col-header {
    flex-shrink: 0;
    padding: 0.75rem 0.75rem 0.65rem;
    border-bottom: 1px solid var(--pt-border-soft);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    position: sticky;
    top: 0;
    z-index: 3;
    background: var(--pt-surface, #fff);
    backdrop-filter: none;
    border-radius: 0;
}

.tickets-kanban-col-title {
    font-size: var(--pt-text-label);
    font-weight: 700;
    text-transform: none;
    letter-spacing: 0.01em;
    color: var(--pt-text, #1c2833);
    line-height: 1.25;
    min-width: 0;
}

.tickets-kanban-col-count {
    font-size: var(--pt-text-label);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    padding: 0.22em 0.5em;
    border-radius: 6px;
    background: rgba(15, 42, 58, 0.06) !important;
    color: var(--pt-ink) !important;
    border: 1px solid rgba(15, 42, 58, 0.1);
}

.tickets-kanban-list {
    padding: 0.72rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(100, 116, 139, 0.35) transparent;
}

.tickets-kanban-viewport.is-compact .tickets-kanban-wrap {
    gap: clamp(0.45rem, 0.9vw, 0.75rem);
}

.tickets-kanban-viewport.is-compact .tickets-kanban-col-header {
    padding: 0.6rem 0.75rem;
}

.tickets-kanban-viewport.is-compact .tickets-kanban-list {
    padding: 0.6rem;
    gap: 0.5rem;
}

.tickets-kanban-viewport.is-compact .tickets-kanban-card {
    padding: 0.55rem 0.6rem 0.5rem;
    border-radius: 8px;
}

.tickets-kanban-viewport.is-compact .tickets-kanban-title {
    font-size: var(--pt-text-label);
    -webkit-line-clamp: 2;
    line-clamp: 2;
    margin-bottom: 0.45rem;
}

.tickets-kanban-viewport.is-compact .tickets-kanban-meta {
    padding-top: 0.4rem;
    gap: 0.25rem;
}

.tickets-kanban-viewport.is-compact .tickets-kanban-meta-item {
    font-size: var(--pt-text-label);
}

.tickets-kanban-viewport.is-compact .tickets-kanban-meta-icon {
    width: 1.25rem;
    height: 1.25rem;
    border-radius: 6px;
}

.tickets-kanban-viewport.is-compact .tickets-kanban-meta-text {
    -webkit-line-clamp: 1;
    line-clamp: 1;
}

.tickets-kanban-card {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    position: relative;
    text-decoration: none;
    color: inherit;
    border: 1px solid var(--pt-border-soft);
    border-radius: 8px;
    background: var(--pt-surface, #fff);
    padding: 0.7rem 0.75rem 0.55rem 0.85rem;
    width: 100%;
    transition: border-color 0.2s ease, background-color 0.2s ease;
    cursor: default;
    touch-action: manipulation;
    box-shadow: none;
}

.tickets-kanban-card-main {
    display: block;
    min-width: 0;
    color: inherit;
    text-decoration: none;
    border-radius: 4px;
}

.tickets-kanban-card-main:focus-visible {
    outline: 2px solid var(--pt-ink);
    outline-offset: 2px;
}

.tickets-kanban-status-btn {
    align-self: stretch;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    min-height: 32px;
    margin: 0;
    padding: 0.25rem 0.5rem;
    border: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
    border-radius: 6px;
    background: var(--pt-surface-soft, #f4f7f8);
    color: var(--pt-ink, #093A87);
    font-size: var(--pt-text-xs);
    font-weight: 600;
    font-family: inherit;
    line-height: 1.2;
    cursor: pointer;
    opacity: 0.72;
}

.tickets-kanban-status-btn:hover,
.tickets-kanban-card:focus-within .tickets-kanban-status-btn {
    opacity: 1;
    border-color: rgba(9, 58, 135, 0.28);
    background: var(--pt-surface, #fff);
}

.tickets-kanban-status-btn:focus-visible {
    outline: 2px solid var(--pt-ink);
    outline-offset: 2px;
    opacity: 1;
}

.tickets-kanban-status-btn-label {
    letter-spacing: 0.01em;
}

.tickets-kanban-status-menu {
    position: fixed;
    z-index: 1200;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    max-height: min(50vh, 16rem);
    overflow: auto;
    overscroll-behavior: contain;
    padding: 0.35rem;
    border: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
    border-radius: 8px;
    background: var(--pt-surface, #fff);
    box-shadow: var(--pt-shadow-strong, 0 14px 36px rgba(15, 42, 58, 0.12));
}

.tickets-kanban-status-menu[hidden] {
    display: none !important;
}

.tickets-kanban-status-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    width: 100%;
    min-height: 36px;
    margin: 0;
    padding: 0.4rem 0.55rem;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--pt-text, #1c2833);
    font: inherit;
    font-size: var(--pt-text-label);
    font-weight: 500;
    text-align: left;
    cursor: pointer;
}

.tickets-kanban-status-option:hover,
.tickets-kanban-status-option.is-active {
    background: var(--pt-surface-soft, #f4f7f8);
    color: var(--pt-ink, #093A87);
}

.tickets-kanban-status-option:focus-visible {
    background: var(--pt-surface-soft, #f4f7f8);
    color: var(--pt-ink, #093A87);
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

.tickets-kanban-status-option.is-current {
    opacity: 0.55;
    cursor: default;
}

.tickets-kanban-status-current {
    font-size: var(--pt-text-xs);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
}

.tickets-kanban-status-empty {
    padding: 0.5rem;
    font-size: var(--pt-text-label);
    color: var(--pt-muted, #5b6b7a);
}

[data-bs-theme="dark"] .tickets-kanban-status-btn {
    background: rgba(15, 23, 42, 0.55);
    border-color: rgba(148, 163, 184, 0.28);
    color: #93c5fd;
}

[data-bs-theme="dark"] .tickets-kanban-status-menu {
    background: #0f172a;
    border-color: rgba(148, 163, 184, 0.22);
}

[data-bs-theme="dark"] .tickets-kanban-status-option:hover,
[data-bs-theme="dark"] .tickets-kanban-status-option.is-active,
[data-bs-theme="dark"] .tickets-kanban-status-option:focus-visible {
    background: rgba(30, 41, 59, 0.95);
    color: #e2e8f0;
}

.tickets-kanban-card-pri {
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 3px;
    border-radius: 0 2px 2px 0;
    background: var(--kanban-pri, #64748b);
}

.tickets-kanban-pri-label {
    font-size: var(--pt-text-xs);
    font-weight: 600;
    color: var(--pt-muted, #5B6B7A);
    max-width: 7rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tickets-kanban-late-label {
    font-weight: 700;
    color: #b42318;
}

.tickets-kanban-meta-item--warn .tickets-kanban-meta-text {
    color: #b45309;
    font-weight: 600;
}

.tickets-kanban-card.is-atrasado {
    border-color: rgba(180, 35, 24, 0.55);
    background: #fff5f4;
    box-shadow: none;
}

.tickets-kanban-card.is-atrasado .tickets-kanban-title {
    font-weight: 700;
}

.tickets-kanban-card.is-meu:not(.is-atrasado) {
    border-color: rgba(9, 58, 135, 0.32);
    background: #f5f8fc;
}

.tickets-kanban-card.is-meu .tickets-kanban-id {
    color: var(--pt-ink, #093A87);
}

.tickets-kanban-meu-chip {
    flex-shrink: 0;
    font-size: var(--pt-text-xs);
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1;
    padding: 0.28em 0.45em;
    border-radius: 6px;
    border: 1px solid rgba(9, 58, 135, 0.22);
    background: rgba(9, 58, 135, 0.08);
    color: var(--pt-ink, #093A87);
}

.tickets-kanban-card.is-atrasado .tickets-kanban-meu-chip {
    border-color: rgba(180, 35, 24, 0.28);
    background: rgba(180, 35, 24, 0.08);
    color: #b42318;
}

.tickets-kanban-card-head {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.4rem;
}

.tickets-kanban-card-head .tickets-kanban-id {
    margin-right: auto;
}

.tickets-kanban-card-top {
    display: flex;
    align-items: flex-start;
    gap: 0.15rem;
    min-width: 0;
}

.tickets-kanban-card-grip {
    flex-shrink: 0;
    opacity: 0.65;
    pointer-events: auto;
    cursor: grab;
    touch-action: none;
    appearance: none;
    background: transparent;
    border: 0;
    margin: -0.35rem 0 0 -0.35rem;
    padding: 0.55rem 0.45rem;
    min-width: 44px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    color: #94a3b8;
    font-size: var(--pt-text-body);
    line-height: 1;
}

.tickets-kanban-card-grip:hover,
.tickets-kanban-card:hover .tickets-kanban-card-grip {
    opacity: 1;
    background: rgba(15, 42, 58, 0.06);
    color: var(--pt-ink, #093A87);
}

.tickets-kanban-card-grip:focus-visible {
    outline: 2px solid var(--pt-ink);
    outline-offset: 2px;
    opacity: 1;
}

.tickets-kanban-card-grip:active {
    cursor: grabbing;
}

.tickets-kanban-id {
    font-weight: 700;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    color: var(--pt-ink);
    font-size: var(--pt-text-label);
    letter-spacing: 0.02em;
    font-variant-numeric: tabular-nums;
}

.tickets-kanban-title {
    font-weight: 600;
    font-size: var(--pt-text-label);
    line-height: 1.4;
    letter-spacing: -0.01em;
    margin: 0 0 0.55rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
    color: var(--bs-body-color);
}

.tickets-kanban-card-badges {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.55rem;
}

.tickets-kanban-meta {
    list-style: none;
    margin: 0;
    padding: 0.5rem 0 0;
    border-top: 1px solid var(--pt-border-soft, rgba(15, 23, 42, 0.08));
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.tickets-kanban-meta-item {
    display: flex;
    align-items: flex-start;
    gap: 0.45rem;
    min-width: 0;
    font-size: var(--pt-text-label);
    line-height: 1.35;
    color: var(--bs-secondary-color);
}

.tickets-kanban-meta-icon {
    flex-shrink: 0;
    width: 1.35rem;
    height: 1.35rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: rgba(15, 23, 42, 0.05);
    color: #64748b;
    font-size: var(--pt-text-label);
}

.tickets-kanban-meta-text {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.tickets-kanban-meta-item--prazo .tickets-kanban-meta-icon {
    background: rgba(15, 42, 58, 0.08);
    color: var(--pt-primary-2, var(--pt-primary));
}

.tickets-kanban-meta-prazo--late {
    color: #dc2626;
    font-weight: 600;
}

.tickets-kanban-meta-prazo--late .tickets-kanban-meta-icon {
    background: rgba(239, 68, 68, 0.12);
    color: #dc2626;
}

.tickets-kanban-card.is-dragging {
    opacity: 0.85;
    border-color: var(--pt-ink);
    box-shadow: none;
    cursor: grabbing;
}

.tickets-kanban-card.is-saving {
    pointer-events: none;
    opacity: 0.7;
}

.tickets-kanban-card:hover {
    border-color: rgba(15, 42, 58, 0.22);
    background: var(--pt-surface, #fff);
    transform: none;
    box-shadow: none;
}

.tickets-kanban-card:focus-within {
    border-color: rgba(9, 58, 135, 0.35);
}

.tickets-kanban-empty {
    font-size: var(--pt-text-label);
    color: #64748b;
    padding: 0.85rem 0.65rem;
    text-align: center;
    border: 1px dashed rgba(148, 163, 184, 0.45);
    border-radius: 12px;
    margin-top: 0.15rem;
    background: rgba(255, 255, 255, 0.6);
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.tickets-kanban-empty::before {
    content: "\f2f2";
    font-family: "bootstrap-icons";
    display: block;
    font-size: var(--pt-text-headline);
    opacity: 0.55;
    color: var(--pt-primary);
}

/* Kanban: skeleton/loading durante sync */
.tickets-kanban-viewport {
    position: relative;
}

.tickets-kanban-viewport.is-loading::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0.35) 100%);
    backdrop-filter: blur(2px);
    pointer-events: none;
    opacity: 1;
}

.tickets-kanban-viewport.is-loading .tickets-kanban-card {
    opacity: 0.35;
    filter: grayscale(0.1);
}

.tickets-kanban-viewport.is-loading .tickets-kanban-list {
    position: relative;
}

.tickets-kanban-viewport.is-loading .tickets-kanban-list::before {
    content: "";
    display: block;
    height: 104px;
    border-radius: 12px;
    background:
        linear-gradient(90deg,
            rgba(148, 163, 184, 0.18) 0%,
            rgba(148, 163, 184, 0.08) 35%,
            rgba(148, 163, 184, 0.18) 70%,
            rgba(148, 163, 184, 0.18) 100%);
    background-size: 220% 100%;
    animation: pt-skeleton 1.1s ease-in-out infinite;
    margin-bottom: 0.55rem;
}

.tickets-kanban-viewport.is-loading .tickets-kanban-list::after {
    content: "";
    display: block;
    height: 86px;
    border-radius: 12px;
    background:
        linear-gradient(90deg,
            rgba(148, 163, 184, 0.18) 0%,
            rgba(148, 163, 184, 0.08) 35%,
            rgba(148, 163, 184, 0.18) 70%,
            rgba(148, 163, 184, 0.18) 100%);
    background-size: 220% 100%;
    animation: pt-skeleton 1.1s ease-in-out infinite;
}

@keyframes pt-skeleton {
    0% { background-position: 120% 0; }
    100% { background-position: -120% 0; }
}

.pt-skeleton-shimmer {
    display: block;
    border-radius: 8px;
    background:
        linear-gradient(90deg,
            rgba(148, 163, 184, 0.2) 0%,
            rgba(148, 163, 184, 0.08) 40%,
            rgba(148, 163, 184, 0.2) 80%,
            rgba(148, 163, 184, 0.2) 100%);
    background-size: 220% 100%;
    animation: pt-skeleton 1.1s ease-in-out infinite;
}

[data-bs-theme="dark"] .pt-skeleton-shimmer {
    background:
        linear-gradient(90deg,
            rgba(148, 163, 184, 0.14) 0%,
            rgba(148, 163, 184, 0.05) 40%,
            rgba(148, 163, 184, 0.14) 80%,
            rgba(148, 163, 184, 0.14) 100%);
    background-size: 220% 100%;
}

/* Dashboard: listas e gráfico com skeleton */
.dashboard-async-list {
    display: grid;
    min-height: 6.5rem;
}

.dashboard-async-list-skeleton,
.dashboard-async-list-content {
    grid-area: 1 / 1;
    min-width: 0;
}

.dashboard-async-list-content {
    opacity: 0;
    transition: opacity 0.22s ease;
}

.dashboard-async-list.is-ready .dashboard-async-list-skeleton {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.15s ease, visibility 0s linear 0.15s;
}

.dashboard-async-list.is-ready .dashboard-async-list-content {
    opacity: 1;
}

.pt-skeleton-ticket-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.pt-skeleton-ticket-row {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--pt-border-soft);
    border-radius: 12px;
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.02);
}

.pt-skeleton-ticket-id {
    width: 2.25rem;
    height: 0.875rem;
    flex-shrink: 0;
    border-radius: 6px;
}

.pt-skeleton-ticket-body {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    min-width: 0;
}

.pt-skeleton-line--title {
    height: 0.875rem;
    width: 72%;
    max-width: 14rem;
}

.pt-skeleton-line--meta {
    height: 0.625rem;
    width: 48%;
    max-width: 9rem;
}

.pt-skeleton-ticket-prazo {
    width: 3.5rem;
    height: 0.75rem;
    flex-shrink: 0;
    border-radius: 6px;
}

.dashboard-async-chart {
    position: relative;
    display: grid;
}

.dashboard-async-chart .pt-skeleton-chart-bars,
.dashboard-async-chart .dashboard-chart-canvas {
    grid-area: 1 / 1;
}

.dashboard-async-chart .dashboard-chart-canvas {
    opacity: 0;
    transition: opacity 0.28s ease;
}

.dashboard-async-chart .pt-skeleton-chart-bars {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.35rem;
    height: 100%;
    min-height: inherit;
    padding: 0.5rem 0.25rem 0.35rem;
    pointer-events: none;
}

.dashboard-async-chart .pt-skeleton-chart-bars span {
    flex: 1 1 0;
    max-width: 44px;
    border-radius: 10px 10px 4px 4px;
    background:
        linear-gradient(90deg,
            rgba(148, 163, 184, 0.2) 0%,
            rgba(148, 163, 184, 0.08) 40%,
            rgba(148, 163, 184, 0.2) 80%,
            rgba(148, 163, 184, 0.2) 100%);
    background-size: 220% 100%;
    animation: pt-skeleton 1.1s ease-in-out infinite;
}

.dashboard-async-chart .pt-skeleton-chart-bars span:nth-child(1) { height: 42%; }
.dashboard-async-chart .pt-skeleton-chart-bars span:nth-child(2) { height: 68%; animation-delay: 0.05s; }
.dashboard-async-chart .pt-skeleton-chart-bars span:nth-child(3) { height: 55%; animation-delay: 0.1s; }
.dashboard-async-chart .pt-skeleton-chart-bars span:nth-child(4) { height: 82%; animation-delay: 0.04s; }
.dashboard-async-chart .pt-skeleton-chart-bars span:nth-child(5) { height: 48%; animation-delay: 0.12s; }
.dashboard-async-chart .pt-skeleton-chart-bars span:nth-child(6) { height: 74%; animation-delay: 0.08s; }
.dashboard-async-chart .pt-skeleton-chart-bars span:nth-child(7) { height: 58%; animation-delay: 0.14s; }

.dashboard-async-chart.is-ready .pt-skeleton-chart-bars {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease, visibility 0s linear 0.15s;
}

.dashboard-async-chart.is-ready .dashboard-chart-canvas {
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    .tickets-kanban-viewport.is-loading .tickets-kanban-list::before,
    .tickets-kanban-viewport.is-loading .tickets-kanban-list::after {
        animation: none;
    }

    .pt-skeleton-shimmer,
    .dashboard-async-chart .pt-skeleton-chart-bars span {
        animation: none;
    }

    .dashboard-async-list-content,
    .dashboard-async-list.is-ready .dashboard-async-list-skeleton,
    .dashboard-async-chart .dashboard-chart-canvas,
    .dashboard-async-chart.is-ready .pt-skeleton-chart-bars {
        transition: none;
    }

    .dashboard-async-list:not(.is-ready) .dashboard-async-list-content {
        opacity: 1;
    }

    .dashboard-async-list:not(.is-ready) .dashboard-async-list-skeleton {
        display: none;
    }

    .dashboard-async-chart:not(.is-ready) .dashboard-chart-canvas {
        opacity: 1;
    }

    .dashboard-async-chart:not(.is-ready) .pt-skeleton-chart-bars {
        display: none;
    }
}

.tickets-kanban-toast {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1060;
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    max-width: min(22rem, calc(100vw - 32px));
    padding: 0.55rem 0.75rem;
    border-radius: 8px;
    font-size: var(--pt-text-label);
    color: #fff;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.16s ease, transform 0.16s ease;
    box-shadow: 0 8px 24px rgba(15, 42, 58, 0.18);
}

.tickets-kanban-toast.success { background: #15803d; }
.tickets-kanban-toast.error { background: #dc2626; }
.tickets-kanban-toast.show { opacity: 1; transform: translateY(0); }

.tickets-kanban-toast-msg {
    min-width: 0;
    line-height: 1.35;
}

.tickets-kanban-toast-undo {
    flex-shrink: 0;
    appearance: none;
    border: 1px solid rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    font: inherit;
    font-weight: 600;
    font-size: var(--pt-text-label);
    line-height: 1;
    padding: 0.4rem 0.55rem;
    min-height: 32px;
    border-radius: 6px;
    cursor: pointer;
}

.tickets-kanban-toast-undo:hover {
    background: rgba(255, 255, 255, 0.24);
}

.tickets-kanban-toast-undo:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.tickets-kanban-toast-dismiss {
    flex-shrink: 0;
    appearance: none;
    border: 0;
    background: transparent;
    color: rgba(255, 255, 255, 0.85);
    width: 32px;
    height: 32px;
    padding: 0;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    cursor: pointer;
    font-size: var(--pt-text-label);
}

.tickets-kanban-toast-dismiss:hover {
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
}

.tickets-kanban-toast-dismiss:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.tickets-kanban-toast.has-undo {
    padding-right: 0.45rem;
}

.tickets-kanban-chrome {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.75rem;
    flex-shrink: 0;
    padding: 0.35rem 0.15rem 0.55rem;
    margin: 0 0 0.15rem;
    border-bottom: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
}

.tickets-kanban-chrome-tools {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.55rem;
    min-width: 0;
}

.tickets-kanban-chrome .pt-btn-icon-only {
    width: 34px;
    height: 34px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.tickets-kanban-chrome .pt-btn-icon-only.is-active,
.tickets-kanban-chrome .pt-btn-icon-only.is-active:hover,
.tickets-kanban-chrome .pt-btn-icon-only.is-active:focus {
    background: rgba(9, 58, 135, 0.1);
    border-color: rgba(9, 58, 135, 0.35);
    color: var(--pt-ink, #093A87);
}

.tickets-kanban-chrome-hint {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.45rem;
    margin: 0 0 0 auto;
    padding: 0;
    font-size: var(--pt-text-label);
    line-height: 1.3;
    color: var(--pt-muted, #5B6B7A);
}

.tickets-kanban-chrome-hint-item {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.tickets-kanban-chrome-hint-item i {
    font-size: var(--pt-text-body);
    opacity: 0.85;
}

.tickets-kanban-chrome-hint-sep {
    opacity: 0.45;
}

@media (max-width: 575.98px) {
    .tickets-kanban-chrome-hint {
        flex-basis: 100%;
        margin-left: 0;
    }
}

.pt-kanban-sync-hint {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    justify-content: flex-start;
    font-size: var(--pt-text-label);
    line-height: 1.2;
    min-width: 0;
    margin-left: 0.15rem;
    color: var(--pt-muted, #5B6B7A);
    font-variant-numeric: tabular-nums;
}

.pt-kanban-sync-text {
    font-family: var(--pt-font-sans);
    font-weight: 500;
}

.tickets-list-id {
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

/* Bulk actions — lista */
.tickets-bulk-bar {
    position: sticky;
    top: 3.25rem;
    z-index: 101;
    margin-bottom: 0.75rem;
    padding: 0.75rem 1rem;
    background: var(--pt-surface, #fff);
    border: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
    border-radius: var(--pt-radius-lg, 12px);
    box-shadow: var(--pt-shadow-soft, 0 8px 24px rgba(15, 42, 58, 0.08));
}

.tickets-bulk-bar-main {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem 1rem;
}

.tickets-bulk-bar-count {
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-text, #1c2833);
    font-variant-numeric: tabular-nums;
}

.tickets-bulk-bar-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem;
}

.tickets-bulk-bar-actions .btn {
    border-radius: var(--pt-radius-md, 8px);
    min-height: 36px;
}

.tickets-bulk-bar-clear {
    text-decoration: none;
    color: var(--pt-muted, #5b6b7a);
}

.tickets-bulk-panel {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
}

.tickets-bulk-panel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
    gap: 0.65rem 1rem;
    align-items: end;
}

.tickets-bulk-panel-grid--prio {
    max-width: 28rem;
}

.tickets-bulk-panel-submit {
    display: flex;
    align-items: flex-end;
}

.tickets-bulk-panel-hint {
    margin-top: 0.5rem;
}

.tickets-list-check-col,
.tickets-list-check {
    width: 2.25rem;
    vertical-align: middle;
}

.tickets-list-check .form-check-input,
.tickets-list-check-col .form-check-input {
    margin: 0;
    width: 1.1rem;
    height: 1.1rem;
    cursor: pointer;
}

[data-bs-theme="dark"] .tickets-bulk-bar {
    background: rgba(15, 23, 42, 0.92);
    border-color: rgba(148, 163, 184, 0.22);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
}

@media (max-width: 767.98px) {
    .tickets-bulk-bar {
        top: 0.5rem;
    }

    .pt-table-mobile-cards--tickets td[data-label="Selecionar"] {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        order: -22;
        border-bottom: 0;
        padding-top: 0.55rem;
        padding-bottom: 0;
    }

    .pt-table-mobile-cards--tickets td[data-label="Selecionar"]::before {
        display: none;
    }

    .pt-table-mobile-cards--tickets td[data-label="Selecionar"] .form-check-input {
        width: 1.35rem;
        height: 1.35rem;
    }
}

.tickets-list-row.is-atrasado {
    background: rgba(220, 38, 38, 0.04);
}

.tickets-list-prazo {
    font-variant-numeric: tabular-nums;
}

.tickets-list-prazo.is-atrasado,
.tickets-list-late {
    color: #b42318;
    font-weight: 600;
}

.tickets-list-late {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    margin-right: 0.35rem;
    font-size: var(--pt-text-label);
}

.tickets-list-prazo-val {
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: var(--pt-text-label);
}

.pt-detail-opened-by {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: var(--pt-text-body);
    color: var(--pt-muted, #5B6B7A);
}

.pt-detail-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.55rem;
    border: 1px solid var(--pt-border-soft);
    border-radius: 8px;
    background: var(--pt-surface-soft, #f4f7f8);
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-text, #1C2833);
}

/* Macros / templates no detalhe */
.pt-macros-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    max-height: 9.5rem;
    overflow: auto;
}

.pt-macro-chip {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    min-height: 36px;
    padding: 0.35rem 0.7rem;
    border: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
    border-radius: var(--pt-radius-md, 8px);
    background: var(--pt-surface, #fff);
    color: var(--pt-ink, #093A87);
    font-size: var(--pt-text-label);
    font-weight: 600;
    line-height: 1.2;
    text-align: left;
    cursor: pointer;
}

.pt-macro-chip:hover {
    background: var(--pt-surface-soft, #f4f7f8);
    border-color: rgba(9, 58, 135, 0.28);
}

.pt-macro-chip:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

.pt-macros--modal {
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--pt-border-soft, rgba(9, 58, 135, 0.14));
}

.pt-macros--modal .pt-macros-list {
    max-height: 7.5rem;
}

.pt-macros-filter {
    border-radius: var(--pt-radius-md, 8px);
}

[data-bs-theme="dark"] .pt-macro-chip {
    background: rgba(15, 23, 42, 0.65);
    border-color: rgba(148, 163, 184, 0.28);
    color: #dbeafe;
}

[data-bs-theme="dark"] .pt-macro-chip:hover {
    background: rgba(30, 41, 59, 0.9);
}

.pt-detail-actions .btn,
.pt-detail-action-form .btn,
.pt-ticket-sidebar .btn {
    border-radius: 8px;
}

.tickets-toolbar .pt-btn-icon-only {
    width: 38px;
    min-width: 38px;
    padding-left: 0;
    padding-right: 0;
    justify-content: center;
}

.tickets-toolbar .pt-btn-icon-only.is-active,
.tickets-toolbar .pt-btn-icon-only.is-active:hover,
.tickets-toolbar .pt-btn-icon-only.is-active:focus {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.32);
    color: var(--pt-primary);
}

/* Dashboard: mobile mais compacto */
@media (max-width: 575.98px) {
    .dashboard-premium .dashboard-hero {
        padding: 1.1rem 1.05rem;
    }
    .dashboard-section {
        margin-bottom: 1.25rem;
    }
    .dashboard-section-head {
        margin-bottom: 0.75rem;
    }
    .dashboard-premium .dashboard-card-header {
        padding: 0.85rem 1rem;
    }
    .dashboard-premium .stat-card {
        padding: 0.95rem 1rem;
    }
    .dashboard-premium .stat-card-value {
        font-size: var(--pt-text-display);
    }
    .dashboard-premium .stat-card-icon {
        width: 46px;
        height: 46px;
        border-radius: 13px;
        font-size: var(--pt-text-headline);
    }
}

.pt-kanban-refresh.is-loading i {
    display: inline-block;
    animation: pt-kanban-spin 0.75s linear infinite;
}

@keyframes pt-kanban-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (prefers-reduced-motion: reduce) {
    .pt-kanban-refresh.is-loading i {
        animation: none;
    }
}

[data-bs-theme="dark"] .tickets-kanban-col {
    background: rgba(15, 23, 42, 0.68);
    border-color: var(--bs-border-color);
    box-shadow: none;
}

[data-bs-theme="dark"] .tickets-kanban-board-empty {
    border-color: rgba(148, 163, 184, 0.35);
    background: rgba(15, 23, 42, 0.45);
    color: #9db1ce;
}

[data-bs-theme="dark"] .tickets-kanban-col-header {
    border-bottom-color: var(--bs-border-color);
    background: rgba(15, 23, 42, 0.94);
}

[data-bs-theme="dark"] .tickets-kanban-col-title {
    color: #e8f0ff;
}

[data-bs-theme="dark"] .tickets-kanban-col-count {
    background: rgba(148, 163, 184, 0.12) !important;
    color: #cbd5e1 !important;
    border-color: rgba(148, 163, 184, 0.25);
}

[data-bs-theme="dark"] .tickets-kanban-viewport {
    scrollbar-color: rgba(148, 163, 184, 0.35) transparent;
}

[data-bs-theme="dark"] .tickets-kanban-viewport::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.35);
}

[data-bs-theme="dark"] .tickets-kanban-card {
    background: linear-gradient(165deg, rgba(2, 6, 23, 0.78) 0%, rgba(8, 13, 28, 0.9) 100%);
    border-color: rgba(148, 163, 184, 0.3);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
}

[data-bs-theme="dark"] .tickets-kanban-card.is-atrasado {
    background: linear-gradient(165deg, rgba(60, 20, 25, 0.55) 0%, rgba(40, 12, 16, 0.72) 100%);
    border-color: rgba(248, 113, 113, 0.55);
}

[data-bs-theme="dark"] .tickets-kanban-card.is-meu:not(.is-atrasado) {
    background: rgba(9, 58, 135, 0.22);
    border-color: rgba(147, 197, 253, 0.4);
}

[data-bs-theme="dark"] .tickets-kanban-meu-chip {
    border-color: rgba(147, 197, 253, 0.35);
    background: rgba(147, 197, 253, 0.12);
    color: #bfdbfe;
}

[data-bs-theme="dark"] .tickets-kanban-card.is-atrasado .tickets-kanban-meu-chip {
    border-color: rgba(252, 165, 165, 0.4);
    background: rgba(248, 113, 113, 0.14);
    color: #fecaca;
}

[data-bs-theme="dark"] .tickets-kanban-chrome-hint {
    color: #94a3b8;
}

[data-bs-theme="dark"] .tickets-kanban-card-grip {
    color: #64748b;
}

[data-bs-theme="dark"] .tickets-kanban-meta {
    border-top-color: rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .tickets-kanban-meta-icon {
    background: rgba(255, 255, 255, 0.06);
    color: #94a3b8;
}

[data-bs-theme="dark"] .tickets-kanban-card:hover {
    border-color: rgba(232, 238, 242, 0.28);
    background: #152029;
}

[data-bs-theme="dark"] .tickets-kanban-empty {
    border-color: rgba(148, 163, 184, 0.28);
    color: #94a3b8;
    background: rgba(0, 0, 0, 0.18);
}

[data-bs-theme="dark"] .tickets-kanban-viewport.is-loading::after {
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.4) 0%, rgba(2, 6, 23, 0.25) 100%);
}

[data-bs-theme="dark"] .tickets-kanban-board-empty {
    background: rgba(0, 0, 0, 0.18);
    border-color: rgba(148, 163, 184, 0.22);
    color: #94a3b8;
}

[data-bs-theme="dark"] .tickets-kanban-board-empty::before,
[data-bs-theme="dark"] .tickets-kanban-empty::before {
    color: #93c5fd;
}

/* Acessibilidade: foco consistente em links “card” e navegação */
.pt-config-nav-link:focus-visible,
.pt-side-link:focus-visible,
.stat-card--link:focus-visible,
.dashboard-hero-quick-link:focus-visible,
.dashboard-hero-chip--link:focus-visible,
.dashboard-list-footer-link:focus-visible,
.dashboard-premium .atrasado-item:focus-visible,
.dashboard-dist-chip:focus-visible,
.setor-ranking-item--link:focus-visible,
.dashboard-inline-link:focus-visible,
.pt-toolbar-toggle:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

[data-bs-theme="dark"] .tickets-kanban-col.is-drop-target {
    background: rgba(232, 238, 242, 0.06);
    border-color: rgba(232, 238, 242, 0.35);
    box-shadow: inset 0 0 0 2px rgba(232, 238, 242, 0.1);
}

.tickets-toolbar .btn-filtro-toggle[aria-expanded="true"] .filtros-toggle-chevron {
    transform: rotate(180deg);
}

.filtros-collapse-wrap:not(.show) {
    margin-bottom: 0 !important;
}

/* Filtros de tickets — painel em seções */
.filtros-card {
    border: 1px solid var(--pt-border-soft, rgba(0, 0, 0, 0.06));
    border-radius: 14px;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
    overflow: visible;
}

.filtros-section--top {
    padding: 1rem 1.25rem;
    border-radius: 12px;
    background: linear-gradient(
        145deg,
        rgba(var(--pt-primary-rgb, 13, 110, 253), 0.07) 0%,
        rgba(var(--pt-primary-rgb, 13, 110, 253), 0.02) 55%,
        transparent 100%
    );
    border: 1px solid rgba(var(--pt-primary-rgb, 13, 110, 253), 0.14);
}

.filtros-section--criterios {
    padding: 1rem 1.15rem 1.1rem;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.025);
    border: 1px solid rgba(15, 23, 42, 0.06);
}

.filtros-section-head {
    margin-bottom: 0.85rem;
}

.filtros-section-title {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: var(--pt-text-label);
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #64748b;
    margin: 0;
    padding-bottom: 0.35rem;
    border-bottom: 1px solid rgba(15, 23, 42, 0.07);
    width: 100%;
}

.filtros-section-title-icon {
    font-size: var(--pt-text-body);
    opacity: 0.85;
    color: var(--pt-primary);
}

/* Busca rápida — largura total */
.pt-filtro-busca-section {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.pt-filtro-busca-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.35rem 1rem;
}

.pt-filtro-busca-hint {
    font-size: var(--pt-text-label);
    color: var(--bs-secondary-color);
}

.pt-filtro-busca-row {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0.65rem;
}

.pt-filtro-busca-field {
    flex: 1 1 16rem;
    min-width: 0;
}

.pt-filtro-busca-input {
    width: 100%;
    min-height: 46px;
    padding-right: 2.5rem;
    font-size: var(--pt-text-body);
    border-radius: 12px;
    background: var(--pt-surface, #fff);
}

.pt-filtro-busca-input:focus {
    border-color: var(--pt-primary);
    box-shadow: 0 0 0 4px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.18);
}

.pt-filtro-busca-clear {
    position: absolute;
    right: 0.55rem;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    padding: 0;
    border: none;
    border-radius: 999px;
    background: transparent;
    color: var(--bs-secondary-color);
    transition: background 0.15s ease, color 0.15s ease;
}

.pt-filtro-busca-clear:hover {
    background: rgba(15, 23, 42, 0.08);
    color: var(--bs-body-color);
}

.pt-filtro-busca-submit {
    flex: 0 0 auto;
    min-height: 46px;
    padding-inline: 1.25rem;
    border-radius: 12px;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: 0 4px 14px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.28);
}

.pt-filtro-busca-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.pt-filtro-chip {
    display: inline-flex;
    align-items: center;
    margin: 0;
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: var(--pt-surface, #fff);
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--bs-body-color);
    cursor: pointer;
    user-select: none;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.pt-filtro-chip .form-check-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

.pt-filtro-chip span {
    display: inline-flex;
    align-items: center;
}

.pt-filtro-chip:hover {
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.35);
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.06);
}

.pt-filtro-chip.is-active {
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.45);
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    color: var(--pt-primary-2);
}

/* Primeira linha legada (outros formulários) */
.filtros-linha-top {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    align-items: end;
}

.filtro-escopo .pt-toolbar-toggle {
    height: 36px;
    padding: 0.35rem 0.8rem;
}

/* Grid de critérios: fluxo responsivo sem “tudo numa coluna” em tablets */
.filtros-linha-criterios {
    display: grid;
    gap: 0.85rem 1rem;
    align-items: start;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
}

.filtro-grupo--periodo,
.filtro-grupo--resumo {
    min-width: 0;
}

/* Período e Resumo operação lado a lado */
.filtro-grupo--periodo {
    grid-column: span 2;
}

.filtro-grupo--resumo {
    grid-column: span 2;
}

.filtro-grupo--periodo .filtro-periodo-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.65rem 1rem;
    align-items: stretch;
}

@media (max-width: 991.98px) {
    .filtro-grupo--periodo,
    .filtro-grupo--resumo {
        grid-column: 1 / -1;
    }
}

.filtro-periodo-campo {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 0;
}

.filtro-periodo-micro {
    font-size: var(--pt-text-label);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #64748b;
}

/* Datas: sem ícone à esquerda (evita duplicar com o picker nativo) */
.filtro-input--date {
    padding-left: 0.65rem;
    min-height: 42px;
}

.filtros-checks-card {
    padding: 0.65rem 0.75rem;
    border-radius: 10px;
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.04);
    border: 1px solid rgba(var(--pt-primary-rgb, 13, 110, 253), 0.1);
}

@media (min-width: 576px) {
    .filtros-checks-stack.filtros-checks-card {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: flex-start;
        gap: 0.65rem 1.5rem;
    }
}

@media (max-width: 575.98px) {
    .pt-filtro-busca-submit span {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .pt-filtro-busca-submit {
        padding-inline: 0.85rem;
    }
}

.filtros-checks-stack {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.filtros-checks-stack .form-check-label {
    line-height: 1.35;
}

/* Barra de ações: hint + botões */
.filtros-acoes-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.85rem 1rem;
    padding-top: 1.15rem;
    margin-top: 0.25rem;
    border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.filtros-acoes-hint {
    flex: 1 1 12rem;
    max-width: 26rem;
    line-height: 1.4;
}

.filtros-acoes-btns {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.65rem 0.85rem;
}

.filtros-acoes-bar .filtro-btn,
.filtros-acoes-bar .filtro-btn-export {
    min-height: 42px;
    padding-left: 1.2rem;
    padding-right: 1.2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.filtros-acoes-bar .filtro-btn-export,
.filtros-card .filtros-acoes-bar a.btn.filtro-btn-export {
    border-radius: 10px;
    font-weight: 700;
    font-size: var(--pt-text-body);
    letter-spacing: 0.02em;
    border: none !important;
    color: #fff !important;
    background: linear-gradient(
        145deg,
        var(--pt-signal) 0%,
        var(--pt-primary) 48%,
        var(--pt-primary-2) 100%
    ) !important;
    box-shadow:
        0 4px 18px rgba(var(--pt-primary-rgb, 9, 58, 135), 0.35),
        0 1px 0 rgba(255, 255, 255, 0.2) inset;
    transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.filtros-acoes-bar .filtro-btn-export:hover,
.filtros-card .filtros-acoes-bar a.btn.filtro-btn-export:hover {
    color: #fff !important;
    filter: brightness(1.06);
    transform: translateY(-1px);
    box-shadow:
        0 8px 26px rgba(var(--pt-primary-rgb, 9, 58, 135), 0.42),
        0 1px 0 rgba(255, 255, 255, 0.25) inset;
}

.filtros-acoes-bar .filtro-btn-export:focus-visible,
.filtros-card .filtros-acoes-bar a.btn.filtro-btn-export:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
    box-shadow: 0 4px 18px rgba(var(--pt-primary-rgb, 9, 58, 135), 0.35);
}

@media (max-width: 575.98px) {
    .filtros-acoes-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .filtros-acoes-btns {
        justify-content: stretch;
    }

    .filtros-acoes-btns .filtro-btn,
    .filtros-acoes-btns .filtro-btn-export {
        flex: 1 1 auto;
    }
}

.filtros-header {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    padding: 0.875rem 1.25rem;
    font-weight: 600;
    font-size: var(--pt-text-body);
    color: #334155;
}

.filtros-header-toggle {
    cursor: pointer;
    display: flex;
    align-items: center;
    user-select: none;
    transition: background-color 0.2s;
}

.filtros-header-toggle:hover {
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%) !important;
}

.filtros-chevron {
    font-size: var(--pt-text-body);
    color: #64748b;
    transition: transform 0.25s ease;
}

.filtros-header-toggle[aria-expanded="true"] .filtros-chevron {
    transform: rotate(180deg);
}

.filtros-body {
    padding: 1.25rem 1.5rem;
    background: var(--pt-surface, #fff);
}

.filtros-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.filtros-linha {
    display: grid;
    gap: 1rem 1.25rem;
    align-items: end;
}

.filtros-linha-1 {
    grid-template-columns: minmax(0, 1fr);
}

.filtro-grupo {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.form-label,
.filtro-label {
    font-size: var(--pt-text-label);
    font-weight: 600;
}

.filtro-label {
    color: #64748b;
    text-transform: none;
    letter-spacing: 0.02em;
}

.filtro-input {
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    padding: 0.55rem 0.75rem;
    min-height: 42px;
    font-size: var(--pt-text-label);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filtros-card .form-select.filtro-input {
    min-height: 42px;
}

.filtro-input:focus-visible {
    border-color: var(--pt-primary);
    box-shadow: 0 0 0 3px rgba(var(--pt-primary-rgb, 15, 42, 58), 0.15);
    outline: 2px solid var(--pt-ink, #093A87);
    outline-offset: 1px;
}

.input-icon-wrapper {
    position: relative;
}

.input-icon-wrapper .input-icon {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: var(--pt-text-body);
    pointer-events: none;
}

.input-icon-wrapper .filtro-input {
    padding-left: 2.25rem;
}

.filtro-checkbox {
    padding-top: 0.5rem;
}

.filtro-checkbox .form-check-label {
    font-size: var(--pt-text-label);
    color: #475569;
    cursor: pointer;
}

.filtro-checkbox .form-check-input:checked {
    background-color: var(--pt-primary);
}

.filtro-btn {
    padding: 0.5rem 1.25rem;
    font-weight: 600;
    font-size: var(--pt-text-label);
    border-radius: 8px;
    background: linear-gradient(135deg, var(--pt-primary) 0%, var(--pt-primary-2) 100%);
    border: none;
    box-shadow: 0 2px 8px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.30);
    transition: transform 0.15s, box-shadow 0.15s;
}

.filtro-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.35);
}

@media (max-width: 576px) {
    .filtros-body {
        padding: 1rem;
    }
}

/* ——— Modo escuro (Bootstrap data-bs-theme=dark + componentes custom) ——— */
[data-bs-theme="dark"] {
    color-scheme: dark;
    /* Tokens de produto (faltavam — ficavam nos valores claros) */
    --pt-paper: #080d16;
    --pt-panel: #121a28;
    --pt-text: #e8eef7;
    --pt-muted: #94a3b8;
    --pt-surface: #121a28;
    --pt-surface-soft: #1a2436;
    --pt-border-soft: rgba(148, 163, 184, 0.16);
    --pt-shadow-soft: 0 12px 32px rgba(0, 0, 0, 0.42);
    --pt-shadow-strong: 0 20px 50px rgba(0, 0, 0, 0.55);
    --pt-shadow-premium: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 12px 40px rgba(0, 0, 0, 0.45);
    --pt-glass: rgba(10, 15, 28, 0.82);
    --bs-body-bg: #080d16;
    --bs-body-color: #e8eef7;
    --bs-emphasis-color: #f8fafc;
    --bs-secondary-color: #94a3b8;
    --bs-secondary-bg: #121a28;
    --bs-tertiary-bg: #1a2436;
    --bs-border-color: rgba(148, 163, 184, 0.18);
    --bs-border-color-translucent: rgba(148, 163, 184, 0.12);
    --bs-link-color: #93c5fd;
    --bs-link-hover-color: #bfdbfe;
    --bs-heading-color: #f1f5f9;
}

[data-bs-theme="dark"] .stat-card-value,
[data-bs-theme="dark"] .dashboard-card-header h5 {
    color: var(--bs-emphasis-color);
}

[data-bs-theme="dark"] .stat-card {
    background: var(--bs-secondary-bg);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

[data-bs-theme="dark"] .stat-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}

[data-bs-theme="dark"] .stat-card-label {
    color: var(--bs-secondary-color);
}

[data-bs-theme="dark"] .atrasado-item {
    border-color: var(--bs-border-color);
    background: var(--bs-body-bg);
}

[data-bs-theme="dark"] .atrasado-item:hover {
    background: rgba(220, 53, 69, 0.1);
}

[data-bs-theme="dark"] .setor-ranking-item {
    border-color: var(--bs-border-color);
    background: rgba(255, 255, 255, 0.02);
}

[data-bs-theme="dark"] .setor-ranking-pos {
    color: #9fb0c6;
}

[data-bs-theme="dark"] .filtros-card {
    border-color: var(--bs-border-color);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.3);
}

[data-bs-theme="dark"] .pt-page-hero {
    background: linear-gradient(135deg, rgba(var(--pt-primary-rgb, 13, 110, 253), 0.20), rgba(var(--pt-info-glow-rgb, 13, 202, 240), 0.14));
    border-color: rgba(var(--pt-info-glow-rgb, 13, 202, 240), 0.25);
}

[data-bs-theme="dark"] .pt-modern-card {
    border-color: var(--bs-border-color);
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.75), rgba(15, 23, 42, 0.75));
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.42);
}

[data-bs-theme="dark"] .pt-modern-card:hover {
    box-shadow: 0 20px 46px rgba(0, 0, 0, 0.5);
}

[data-bs-theme="dark"] .pt-navbar.navbar {
    background: linear-gradient(120deg, color-mix(in srgb, var(--pt-primary) 55%, #000) 0%, color-mix(in srgb, var(--pt-primary-2) 55%, #000) 52%, color-mix(in srgb, var(--pt-primary-3) 55%, #000) 100%);
}

[data-bs-theme="dark"] .pt-sidebar,
[data-bs-theme="dark"] .pt-ui-premium .pt-sidebar {
    background:
        radial-gradient(120% 70% at 0% 0%, rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.12) 0%, transparent 48%),
        radial-gradient(90% 50% at 100% 100%, rgba(var(--pt-primary-rgb, 9, 58, 135), 0.35) 0%, transparent 55%),
        linear-gradient(185deg, #070b12 0%, #0a1322 52%, #08101c 100%);
    color: #e8eef7;
    border-right: 1px solid rgba(148, 163, 184, 0.14);
    box-shadow:
        inset -1px 0 0 rgba(255, 255, 255, 0.04),
        8px 0 24px rgba(0, 0, 0, 0.45);
}

[data-bs-theme="dark"] .pt-side-link,
[data-bs-theme="dark"] .pt-side-link-logout {
    color: rgba(232, 238, 247, 0.88);
}

[data-bs-theme="dark"] .pt-side-link:hover,
[data-bs-theme="dark"] .pt-side-link-logout:hover {
    background: rgba(148, 163, 184, 0.12);
    color: #fff;
    border-color: rgba(148, 163, 184, 0.16);
}

[data-bs-theme="dark"] .pt-side-link.active,
[data-bs-theme="dark"] .pt-ui-premium .pt-side-link.active {
    background: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.38);
    color: #f8fafc;
    border-color: rgba(147, 197, 253, 0.18);
}

[data-bs-theme="dark"] .pt-side-link.active::before {
    background: var(--pt-signal, #10CAF0);
}

[data-bs-theme="dark"] .pt-side-group-title {
    color: rgba(148, 163, 184, 0.85);
}

[data-bs-theme="dark"] .pt-topbar {
    background: rgba(2, 6, 23, 0.62);
    border-bottom-color: rgba(148, 163, 184, 0.2);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

[data-bs-theme="dark"] .pt-topbar .btn-outline-secondary {
    background: rgba(15, 23, 42, 0.62);
    border-color: rgba(148, 163, 184, 0.35);
    color: #d7e2f1;
}

[data-bs-theme="dark"] .pt-topbar .btn-outline-secondary:hover {
    background: rgba(30, 41, 59, 0.78);
    border-color: rgba(96, 165, 250, 0.45);
    color: #e8f0ff;
}

[data-bs-theme="dark"] .pt-topbar-subtitle {
    color: #94a3b8;
}

[data-bs-theme="dark"] .pt-mobile-pagebar {
    background: rgba(2, 6, 23, 0.72);
    border-bottom-color: rgba(148, 163, 184, 0.2);
}

[data-bs-theme="dark"] .pt-mobile-pagebar-subtitle {
    color: #94a3b8;
}

[data-bs-theme="dark"] .pt-mobile-pagebar .btn-outline-secondary {
    background: rgba(15, 23, 42, 0.62);
    border-color: rgba(148, 163, 184, 0.35);
    color: #d7e2f1;
}

[data-bs-theme="dark"] .tickets-toolbar {
    background: rgba(15, 23, 42, 0.72);
    border-color: rgba(148, 163, 184, 0.2);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
}

[data-bs-theme="dark"] .tickets-toolbar-meta {
    background: rgba(2, 6, 23, 0.45);
    border-color: rgba(148, 163, 184, 0.18);
}

[data-bs-theme="dark"] .tickets-toolbar-ordenar .form-select {
    background: rgba(15, 23, 42, 0.85);
    border-color: rgba(148, 163, 184, 0.35);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .pt-topbar-title-icon {
    background: rgba(96, 165, 250, 0.18);
    color: #cbe0ff;
}

[data-bs-theme="dark"] .pt-side-link:hover {
    background: rgba(148, 163, 184, 0.12);
}

[data-bs-theme="dark"] .table thead th {
    color: #94a3b8;
}

[data-bs-theme="dark"] body,
[data-bs-theme="dark"] body.pt-ui-premium {
    background:
        radial-gradient(ellipse 90% 55% at 0% -8%, rgba(var(--pt-primary-rgb, 13, 110, 253), 0.16), transparent 52%),
        radial-gradient(ellipse 70% 45% at 100% 0%, rgba(var(--pt-info-glow-rgb, 13, 202, 240), 0.09), transparent 48%),
        radial-gradient(ellipse 50% 35% at 50% 100%, rgba(var(--pt-primary-rgb, 13, 110, 253), 0.05), transparent 42%),
        var(--bs-body-bg);
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select {
    border-color: rgba(148, 163, 184, 0.35);
    background-color: rgba(15, 23, 42, 0.78);
}

[data-bs-theme="dark"] .btn-outline-secondary {
    border-color: rgba(148, 163, 184, 0.45);
    color: #cbd5e1;
}

[data-bs-theme="dark"] .filtros-header {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-bottom-color: var(--bs-border-color);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .filtros-header-toggle:hover {
    background: linear-gradient(135deg, #334155 0%, #1e293b 100%) !important;
}

[data-bs-theme="dark"] .filtros-body {
    background: var(--bs-secondary-bg);
}

[data-bs-theme="dark"] .filtros-section--top {
    background: linear-gradient(
        145deg,
        rgba(var(--pt-primary-rgb, 13, 110, 253), 0.16) 0%,
        rgba(15, 23, 42, 0.35) 100%
    );
    border-color: rgba(148, 163, 184, 0.22);
}

[data-bs-theme="dark"] .pt-filtro-busca-input {
    background: rgba(2, 6, 23, 0.55);
    border-color: rgba(148, 163, 184, 0.22);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .pt-filtro-busca-input:focus {
    box-shadow: 0 0 0 4px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.28);
}

[data-bs-theme="dark"] .pt-filtro-busca-clear:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #f1f5f9;
}

[data-bs-theme="dark"] .pt-filtro-chip {
    background: rgba(2, 6, 23, 0.45);
    border-color: rgba(148, 163, 184, 0.2);
}

[data-bs-theme="dark"] .pt-filtro-chip.is-active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.45);
}

[data-bs-theme="dark"] .filtros-section--criterios {
    background: rgba(2, 6, 23, 0.35);
    border-color: rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .filtros-section-title {
    color: #94a3b8;
    border-bottom-color: rgba(148, 163, 184, 0.16);
}

[data-bs-theme="dark"] .filtros-checks-card {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.1);
    border-color: rgba(148, 163, 184, 0.2);
}

[data-bs-theme="dark"] .filtro-periodo-micro {
    color: #94a3b8;
}

[data-bs-theme="dark"] .filtros-acoes-bar {
    border-top-color: rgba(148, 163, 184, 0.18);
}

[data-bs-theme="dark"] .filtros-acoes-hint {
    color: var(--bs-secondary-color) !important;
}

[data-bs-theme="dark"] .filtros-acoes-bar .filtro-btn-export,
[data-bs-theme="dark"] .filtros-card .filtros-acoes-bar a.btn.filtro-btn-export {
    background: linear-gradient(
        145deg,
        color-mix(in srgb, var(--pt-signal) 85%, #fff) 0%,
        var(--pt-primary) 45%,
        var(--pt-primary-3) 100%
    ) !important;
    box-shadow:
        0 4px 22px rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.3),
        0 1px 0 rgba(255, 255, 255, 0.12) inset;
}

[data-bs-theme="dark"] .filtros-acoes-bar .filtro-btn-export:hover,
[data-bs-theme="dark"] .filtros-card .filtros-acoes-bar a.btn.filtro-btn-export:hover {
    box-shadow:
        0 8px 28px rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.38),
        0 1px 0 rgba(255, 255, 255, 0.15) inset;
}

[data-bs-theme="dark"] .filtro-label {
    color: var(--bs-secondary-color);
}

[data-bs-theme="dark"] .filtro-input {
    background-color: var(--bs-body-bg);
    border-color: var(--bs-border-color);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .filtro-checkbox .form-check-label {
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .table {
    --bs-table-bg: transparent;
}

[data-bs-theme="dark"] .card {
    background-color: var(--bs-secondary-bg);
    border-color: var(--bs-border-color);
}

[data-bs-theme="dark"] .card-header.bg-transparent {
    border-bottom-color: var(--bs-border-color);
}

[data-bs-theme="dark"] .text-muted {
    color: var(--bs-secondary-color) !important;
}

[data-bs-theme="dark"] .empty-state {
    color: var(--bs-secondary-color);
    background: rgba(0, 0, 0, 0.18);
    border-color: rgba(148, 163, 184, 0.22);
}

[data-bs-theme="dark"] .ticket-prioridade-field:focus-visible {
    box-shadow: 0 0 0 0.2rem color-mix(in srgb, var(--pt-prioridade-cor, var(--pt-primary)) 45%, transparent);
}

/* Modal de comentário responsivo
 * O <form> envolve body+footer e quebra o flex do Bootstrap scrollable —
 * tratamos form como coluna flex para o body rolar sem estourar a viewport.
 */
.pt-modal-comentario-dialog {
    margin: 0.75rem auto;
    max-width: min(1140px, calc(100vw - 1.5rem));
    max-height: calc(100dvh - 1.5rem);
}

.pt-modal-comentario-dialog .modal-content {
    display: flex;
    flex-direction: column;
    max-height: calc(100dvh - 1.5rem);
    min-height: 0;
    overflow: hidden;
}

.pt-modal-comentario-dialog .modal-header,
.pt-modal-comentario-dialog .modal-footer {
    flex-shrink: 0;
}

.pt-modal-comentario-dialog form {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}

.pt-modal-comentario-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.pt-comentario-textarea {
    min-height: 8rem;
    max-height: min(28vh, 16rem);
    resize: vertical;
}

.pt-macros--modal .pt-macros-list {
    max-height: 6.5rem;
}

@media (min-width: 992px) {
    .pt-modal-comentario-dialog {
        height: auto;
        max-height: min(88vh, calc(100dvh - 2rem));
    }

    .pt-modal-comentario-dialog .modal-content {
        max-height: min(88vh, calc(100dvh - 2rem));
    }

    .pt-comentario-textarea {
        min-height: 10rem;
        max-height: min(36vh, 20rem);
    }
}

@media (max-width: 991.98px) {
    .pt-modal-comentario-dialog {
        margin: 0.5rem;
        max-width: calc(100vw - 1rem);
        max-height: calc(100dvh - 1rem);
    }

    .pt-modal-comentario-dialog .modal-content {
        max-height: calc(100dvh - 1rem);
    }

    .pt-comentario-textarea {
        min-height: 7rem;
        max-height: min(32vh, 12rem);
    }
}

/* Comentários longos no histórico não estouram o card */
.pt-ticket-historico .list-group-item p,
.card .list-group-item p.small {
    overflow-wrap: anywhere;
    word-break: break-word;
}

/*
 * Modal de pré-visualização (PDF / texto / imagem).
 * O fundo claro (bg-body-secondary + body-bg no iframe) aparecia como faixa cinza sobre o PDF
 * porque o viewer do Chrome nem sempre preenche todo o iframe — usamos flex + altura do diálogo
 * e cor próxima ao viewer (#323639) na área do iframe.
 */
.pt-modal-preview-dialog {
    margin: 1.75rem auto;
}

/* Altura definida: o iframe PDF precisa de ancestral com altura real (flex 1 1 auto). */
@media (min-width: 992px) {
    .pt-modal-preview-dialog {
        height: 92vh;
        max-height: 92vh;
    }
}

@media (max-width: 991.98px) {
    .modal-fullscreen-lg-down.pt-modal-preview-dialog {
        height: 100%;
        max-height: none;
        margin: 0;
    }
}

.pt-modal-preview-dialog .modal-content {
    min-height: 0;
}

@media (min-width: 992px) {
    .pt-modal-preview-dialog .modal-content {
        max-height: 92vh;
        height: 100%;
    }
}

@media (max-width: 991.98px) {
    .modal-fullscreen-lg-down.pt-modal-preview-dialog .modal-content {
        max-height: none;
        height: 100%;
    }
}

.pt-modal-preview-body {
    min-height: 0;
    flex: 1 1 auto;
    background-color: #323639;
    overscroll-behavior: contain;
}

#modalPreviewAnexoImgWrap,
#modalPreviewAnexoLocalImgWrap,
#modalPreviewAnexoFallback,
#modalPreviewAnexoLocalFallback {
    overscroll-behavior: contain;
}

#modalPreviewAnexo .ticket-preview-frame,
#modalPreviewAnexoLocal .ticket-preview-frame {
    min-height: 12rem;
    height: auto;
    flex: 1 1 auto;
    width: 100%;
    align-self: stretch;
    /* Mesma família de cinza do visualizador PDF do Chrome (evita “mancha” clara) */
    background-color: #323639;
}

/*
 * Chrome: o visualizador de PDF dentro de iframe pode ficar em branco se um ancestral
 * usar transform, filter ou backdrop-filter (comum em modais Bootstrap).
 */
#modalPreviewAnexo .modal-dialog.pt-modal-preview-dialog,
#modalPreviewAnexo .modal-dialog.pt-modal-preview-dialog .modal-content,
#modalPreviewAnexoLocal .modal-dialog.pt-modal-preview-dialog,
#modalPreviewAnexoLocal .modal-dialog.pt-modal-preview-dialog .modal-content {
    transform: none !important;
    filter: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

#modalPreviewAnexo.fade .modal-dialog.pt-modal-preview-dialog {
    transform: none !important;
}

#modalPreviewAnexo .pt-modal-preview-body,
#modalPreviewAnexoLocal .pt-modal-preview-body {
    isolation: isolate;
}

/* Modal de agendamento (data/hora) */
.pt-modal-agendamento-dialog {
    max-width: 560px;
}

@media (min-width: 576px) {
    .pt-modal-agendamento-dialog {
        max-width: 620px;
    }
}

.pt-modal-agendamento .modal-body {
    padding-top: 0.25rem;
}

.pt-agendamento-layout {
    align-items: stretch;
}

/* Calendário */
.pt-ag-cal-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.pt-ag-cal-title {
    font-weight: 700;
    font-size: var(--pt-text-body);
    text-align: center;
    flex: 1;
    text-transform: capitalize;
}

.pt-ag-cal-hoje {
    font-size: var(--pt-text-label);
    margin-bottom: 0.35rem;
}

.pt-ag-cal-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    text-align: center;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--bs-secondary-color);
    margin-bottom: 4px;
}

.pt-ag-cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.pt-ag-cal-day {
    aspect-ratio: 1;
    min-height: 2.25rem;
    border: none;
    border-radius: 0.45rem;
    background: transparent;
    color: var(--bs-body-color);
    font-size: var(--pt-text-label);
    font-weight: 500;
    font-variant-numeric: tabular-nums;
    padding: 0;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

.pt-ag-cal-day:hover:not(:disabled):not(.is-outside) {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
}

.pt-ag-cal-day.is-today:not(.is-selected) {
    box-shadow: inset 0 0 0 2px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.45);
    font-weight: 700;
}

.pt-ag-cal-day.is-selected {
    background: var(--pt-primary, #0d6efd);
    color: #fff;
    font-weight: 700;
}

.pt-ag-cal-day.is-selected:hover {
    background: var(--pt-primary-2, #0a58ca);
    color: #fff;
}

.pt-ag-cal-day.is-outside,
.pt-ag-cal-day.is-disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

/* Horários */
.pt-ag-time-panel {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
}

.pt-ag-time-slots {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    max-height: 11.5rem;
    overflow-y: auto;
    padding: 2px;
    margin-bottom: 0.5rem;
}

.pt-ag-time-slot {
    border: 1px solid var(--bs-border-color);
    border-radius: 0.4rem;
    background: var(--bs-body-bg);
    color: var(--bs-body-color);
    font-size: var(--pt-text-label);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    padding: 0.4rem 0.25rem;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.pt-ag-time-slot:hover {
    border-color: var(--pt-primary, #0d6efd);
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.08);
}

.pt-ag-time-slot.is-selected {
    border-color: var(--pt-primary, #0d6efd);
    background: var(--pt-primary, #0d6efd);
    color: #fff;
}

.pt-agendamento-time {
    font-variant-numeric: tabular-nums;
}

/* Trigger no ticket */
.pt-agendamento-trigger .btn {
    text-align: left;
    justify-content: flex-start;
    min-height: 2.75rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.pt-agendamento-trigger-inner {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.1rem;
}

.pt-agendamento-trigger-label {
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
    font-size: var(--pt-text-label);
    line-height: 1.25;
}

.pt-agendamento-trigger-sub {
    font-size: var(--pt-text-label);
    line-height: 1.2;
    color: var(--bs-secondary-color);
}

/* Preview */
.pt-agendamento-preview {
    padding: 0.85rem 1rem;
    border-radius: 0.55rem;
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.08);
    border: 1px solid rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
}

.pt-agendamento-preview-main {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.pt-agendamento-preview-main > .bi {
    color: var(--pt-primary, #0d6efd);
    font-size: var(--pt-text-headline);
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.pt-agendamento-preview-date {
    font-weight: 600;
    font-size: var(--pt-text-body);
    line-height: 1.35;
    text-transform: capitalize;
}

.pt-agendamento-preview-date.text-muted {
    font-weight: 500;
    text-transform: none;
}

.pt-agendamento-presets .btn {
    white-space: nowrap;
}

[data-bs-theme="dark"] .pt-agendamento-preview {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.14);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.38);
}

[data-bs-theme="dark"] .pt-ag-time-slot {
    background: rgba(255, 255, 255, 0.04);
}

#ptModalAgendamento .form-control[type="time"] {
    color-scheme: light dark;
}

@media (max-width: 767.98px) {
    .pt-ag-time-slots {
        grid-template-columns: repeat(4, 1fr);
        max-height: 8rem;
    }
}

/* --- Layout v2: navegação, detalhe, config, sticky toolbar --- */

.pt-breadcrumb-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.5rem;
    padding: 0;
    list-style: none;
    font-size: var(--pt-text-label);
}

.pt-breadcrumb-item {
    display: inline-flex;
    align-items: center;
    color: var(--bs-secondary-color);
}

.pt-breadcrumb-item:not(:last-child)::after {
    content: "/";
    margin-left: 0.5rem;
    opacity: 0.45;
    font-weight: 500;
}

.pt-breadcrumb-item a {
    color: var(--pt-primary-2);
    text-decoration: none;
    font-weight: 600;
}

.pt-breadcrumb-item a:hover {
    text-decoration: underline;
}

.pt-breadcrumb-item.is-current span {
    color: var(--bs-body-color);
    font-weight: 600;
}

.pt-detail-header {
    padding: 1rem 1.15rem 1.1rem;
    border-radius: var(--pt-radius-md);
    border: 1px solid var(--pt-border-soft);
    background: var(--pt-surface);
    box-shadow: none;
    position: relative;
    overflow: hidden;
}

.pt-detail-header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--pt-signal);
}

.pt-detail-header-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
    margin-bottom: 0.65rem;
    padding-bottom: 0.65rem;
    border-bottom: 1px solid var(--pt-border-soft);
}

.pt-detail-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.5rem;
    min-width: 0;
}

.pt-detail-id {
    font-size: var(--pt-text-label);
    font-weight: 700;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    letter-spacing: 0.02em;
    color: var(--pt-ink);
    font-variant-numeric: tabular-nums;
    padding: 0.2rem 0.45rem;
    border-radius: 6px;
    background: rgba(15, 42, 58, 0.06);
    border: 1px solid rgba(15, 42, 58, 0.1);
}

.pt-detail-title {
    font-size: var(--pt-text-headline);
    font-weight: 700;
    line-height: 1.4;
    color: var(--pt-text, #1c2833);
    text-wrap: balance;
}

.pt-detail-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
    margin-left: auto;
    flex-shrink: 0;
}

.pt-detail-actions .btn,
.pt-detail-action-form {
    flex-shrink: 0;
    margin: 0;
    border-radius: 8px;
}

.pt-detail-action-form {
    display: inline-flex;
}

@media (max-width: 767.98px) {
    .pt-detail-header-top {
        flex-direction: column;
        align-items: stretch;
    }

    .pt-detail-actions {
        margin-left: 0;
        justify-content: flex-start;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.15rem;
        -webkit-overflow-scrolling: touch;
    }

    .pt-detail-actions .btn,
    .pt-detail-action-form .btn {
        white-space: nowrap;
    }
}

.pt-sticky-toolbar-wrap {
    position: sticky;
    top: 0;
    z-index: 102;
    padding-top: 0.15rem;
    padding-bottom: 0.35rem;
    margin-bottom: 0 !important;
    background: color-mix(in srgb, var(--bs-body-bg) 88%, transparent);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: box-shadow 0.2s ease;
}

.pt-sticky-toolbar-wrap.is-scrolled {
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.tickets-toolbar-escopo .btn {
    border-radius: 999px !important;
    padding-inline: 0.65rem;
}

.tickets-toolbar-escopo .btn.is-active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.14);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.35);
    color: var(--pt-primary-2);
}

.pt-config-layout {
    align-items: flex-start;
}

.pt-config-nav {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    position: sticky;
    top: 1rem;
    padding: 0.75rem;
    border-radius: var(--pt-radius-lg, 12px);
    border: 1px solid var(--pt-border-soft);
    background: var(--pt-surface);
    box-shadow: var(--pt-shadow-premium, var(--pt-shadow-soft));
}

.pt-config-nav-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-height: 44px;
    padding: 0.55rem 0.75rem;
    border-radius: var(--pt-radius-md, 8px);
    text-decoration: none;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--bs-body-color);
    border: 1px solid transparent;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.pt-config-nav-link i {
    font-size: var(--pt-text-title);
    opacity: 0.85;
    flex-shrink: 0;
}

.pt-config-nav-link:hover {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.07);
    color: var(--pt-primary-2);
}

.pt-config-nav-link.active {
    background: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.1);
    border-color: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.18);
    color: var(--pt-ink, #093A87);
    position: relative;
}

.pt-config-nav-link.active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 3px;
    height: 58%;
    min-height: 14px;
    max-height: 22px;
    transform: translateY(-50%);
    border-radius: 0 2px 2px 0;
    background: var(--pt-signal, #10CAF0);
    opacity: 0.95;
}

.pt-config-panel > .card,
.pt-config-panel > form > .card,
.pt-config-panel .card.pt-card-elevated {
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-lg, 12px);
    box-shadow: var(--pt-shadow-premium, var(--pt-shadow-soft));
}

.pt-config-panel > .card.shadow-sm,
.pt-config-panel > form > .card.shadow-sm {
    box-shadow: var(--pt-shadow-premium, var(--pt-shadow-soft)) !important;
}

/* Títulos de seção em Config (topbar + h1 no conteúdo) */
.pt-config-panel > .d-flex h1,
.pt-config-panel > h1,
.pt-section-title {
    font-family: var(--pt-font-sans);
    font-size: var(--pt-text-headline);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.25;
    margin: 0;
    color: var(--pt-text, #1c2833);
}

.pt-config-panel > .d-flex.justify-content-between {
    align-items: flex-start !important;
    gap: 1rem;
}

.pt-config-panel > p.text-muted.mb-4 {
    max-width: 52ch;
    margin-top: -0.5rem;
    font-size: var(--pt-text-body);
    line-height: 1.45;
}

.pt-section-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.85rem 1.25rem;
}

.pt-section-header-main {
    min-width: 0;
}

.pt-section-meta {
    margin-top: 0.25rem;
    font-size: var(--pt-text-label);
    font-weight: 600;
    color: var(--pt-muted, #5b6b7a);
}

.pt-section-lead {
    margin-top: 0.35rem;
    font-size: var(--pt-text-body);
    line-height: 1.45;
    color: var(--pt-muted, #5b6b7a);
    max-width: 52ch;
}

.pt-section-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.pt-section-actions .btn {
    border-radius: var(--pt-radius-md, 8px);
    min-height: 38px;
}

.pt-section-badge {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0.35rem 0.75rem;
    border-radius: var(--pt-radius-md, 8px);
    border: 1px solid var(--pt-border-soft);
    background: var(--pt-surface-soft, #f4f7f8);
    color: var(--pt-muted, #5b6b7a);
    font-size: var(--pt-text-label);
    font-weight: 600;
}

.pt-section-filters {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    padding: 0.35rem;
    border-radius: var(--pt-radius-lg, 12px);
    border: 1px solid var(--pt-border-soft);
    background: var(--pt-surface);
    box-shadow: var(--pt-shadow-soft);
}

.pt-section-filters .pt-toolbar-toggle {
    border-radius: var(--pt-radius-md, 8px) !important;
    height: 36px;
    padding: 0.35rem 0.85rem;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: transparent;
    color: var(--bs-body-color);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.pt-section-filters .pt-toolbar-toggle:hover {
    background: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.06);
    border-color: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.28);
}

.pt-section-filters .pt-toolbar-toggle.is-active {
    background: var(--pt-ink, #093A87);
    border-color: var(--pt-ink, #093A87);
    color: #fff;
}

.pt-section-filters .pt-toolbar-toggle:focus-visible {
    outline: 3px solid var(--pt-focus-ring, #093A87);
    outline-offset: 2px;
}

.pt-notif-list-item.is-unread {
    background: rgba(9, 58, 135, 0.05);
}

.pt-notif-list-item.is-unread .pt-notif-list-title::before {
    content: "";
    display: inline-block;
    width: 0.45rem;
    height: 0.45rem;
    margin-right: 0.4rem;
    border-radius: 50%;
    background: var(--pt-signal, #10CAF0);
    vertical-align: 0.1em;
}

.pt-notif-list-title {
    font-weight: 600;
    font-size: var(--pt-text-body);
}

.pt-notif-list-msg {
    font-size: var(--pt-text-label);
    color: var(--pt-muted, #5b6b7a);
    margin-top: 0.15rem;
}

.pt-table-wrap {
    border-radius: var(--pt-radius-md);
    border: 1px solid var(--pt-border-soft);
    overflow: auto;
    background: var(--pt-surface);
    box-shadow: var(--pt-shadow-soft);
}

.pt-table-wrap .table {
    margin-bottom: 0;
}

.pt-table-wrap .table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: var(--pt-surface-soft);
    border-bottom-width: 1px;
    font-size: var(--pt-text-label);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--bs-secondary-color);
    white-space: nowrap;
}

/* Tabelas: zebra suave + hover mais moderno */
.pt-table-wrap .table tbody tr {
    transition: background 0.16s ease;
}

.pt-table-wrap .table tbody tr:nth-child(even) {
    background: rgba(15, 23, 42, 0.018);
}

.pt-table-wrap .table-hover tbody tr:hover {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.045);
}

[data-bs-theme="dark"] .pt-table-wrap .table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.03);
}

[data-bs-theme="dark"] .pt-table-wrap .table-hover tbody tr:hover {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.08);
}

.card.pt-card {
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-md);
    box-shadow: var(--pt-shadow-soft);
}

.card.pt-card > .card-header {
    background: var(--pt-surface-soft);
    border-bottom: 1px solid var(--pt-border-soft);
    font-weight: 600;
}

[data-bs-theme="dark"] .pt-sticky-toolbar-wrap {
    background: color-mix(in srgb, var(--bs-body-bg) 92%, transparent);
}

[data-bs-theme="dark"] .pt-sticky-toolbar-wrap.is-scrolled {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

[data-bs-theme="dark"] .pt-detail-header,
[data-bs-theme="dark"] .pt-config-nav {
    background: var(--bs-body-bg);
    border-color: rgba(255, 255, 255, 0.08);
}

[data-bs-theme="dark"] .pt-config-nav-link.active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.14);
}

[data-bs-theme="dark"] .pt-config-nav-link.active::before {
    background: rgba(147, 197, 253, 0.75);
    opacity: 0.5;
}

@media (max-width: 991.98px) {
    .pt-config-nav {
        position: static;
        flex-direction: row;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x proximity;
        scrollbar-width: none;
        margin-bottom: 0.75rem;
        padding: 0.6rem;
        gap: 0.4rem;
    }

    .pt-config-nav::-webkit-scrollbar {
        display: none;
    }

    .pt-config-nav-link {
        flex: 0 0 auto;
        scroll-snap-align: start;
        padding: 0.5rem 0.75rem;
    }

    .pt-config-nav-link span {
        font-size: var(--pt-text-label);
    }

    .pt-config-nav-link.active::before {
        top: auto;
        bottom: 0;
        left: 50%;
        width: 58%;
        height: 3px;
        min-height: 3px;
        max-height: 3px;
        transform: translateX(-50%);
        border-radius: 2px 2px 0 0;
    }

    .pt-sticky-toolbar-wrap {
        top: 0;
    }
}

/* --- Mobile polish: lista, formulário, detalhe --- */
@media (max-width: 767.98px) {
    .pt-page-shell {
        padding-bottom: max(1.75rem, env(safe-area-inset-bottom)) !important;
    }

    .pt-breadcrumb-list {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 0.15rem;
        scrollbar-width: none;
    }

    .pt-breadcrumb-list::-webkit-scrollbar {
        display: none;
    }

    .tickets-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }

    .tickets-toolbar-meta,
    .tickets-toolbar > .d-flex:last-child {
        width: 100%;
    }

    .tickets-toolbar > .d-flex:last-child {
        justify-content: flex-start;
    }

    .tickets-toolbar-ordenar {
        width: 100%;
    }

    .tickets-toolbar-ordenar .form-select {
        width: 100%;
        max-width: none;
        min-width: 0;
    }

    .tickets-bulk-bar-main {
        flex-direction: column;
        align-items: stretch;
    }

    .tickets-bulk-bar-actions {
        width: 100%;
    }

    .tickets-bulk-panel-grid {
        grid-template-columns: 1fr;
    }

    .pt-section-header {
        flex-direction: column;
        align-items: stretch;
    }

    .pt-section-actions {
        width: 100%;
    }

    .pt-section-lead {
        max-width: none;
    }

    .pt-historico-item-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.2rem;
    }

    .pt-historico-item-head small {
        font-size: var(--pt-text-xs);
        line-height: 1.35;
        overflow-wrap: anywhere;
    }

    .pt-detail-title {
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .pt-card-header.pt-card-header-text {
        flex-wrap: wrap;
    }

    .pt-modal-comentario-dialog .modal-footer,
    .pt-modal-comentario-dialog .modal-footer .d-flex {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
    }

    .pt-modal-comentario-dialog .modal-footer .btn {
        width: 100%;
    }

    .pt-section-filters {
        display: flex;
        width: 100%;
    }

    .pt-section-filters .pt-toolbar-toggle {
        flex: 1 1 0;
        justify-content: center;
        text-align: center;
    }

    .pt-notif-list-item-body {
        flex-direction: column;
        gap: 0.65rem;
    }

    .pt-notif-list-item-meta {
        width: 100%;
        text-align: left !important;
        display: flex;
        flex-direction: column;
        gap: 0.55rem;
        padding-top: 0.45rem;
        border-top: 1px dashed var(--pt-border-soft);
    }

    .pt-notif-list-item-meta .d-flex {
        justify-content: stretch !important;
        width: 100%;
        gap: 0.5rem;
    }

    .pt-notif-list-item-meta .d-flex .btn {
        flex: 1 1 0;
        min-width: 0;
    }

    .pt-notif-list-item-meta small {
        white-space: normal;
    }

    .pt-notif-list-item-main .btn-link {
        width: 100%;
        text-align: left;
        padding: 0.15rem 0;
    }

    .pt-notif-list-title,
    .pt-notif-list-msg {
        overflow-wrap: anywhere;
    }

    .pt-config-panel > .d-flex.justify-content-between {
        flex-direction: column;
        align-items: stretch;
    }

    .pt-table-wrap:has(.pt-table-mobile-cards) {
        border: 0;
        box-shadow: none;
        background: transparent;
        overflow: visible;
    }

    .pt-table-mobile-cards td[data-label="Ações"]:has(> .text-muted.small:only-child) {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .dashboard-hero-quick-link {
        min-height: 44px;
    }

    .pt-filtro-busca-row {
        flex-direction: column;
        align-items: stretch;
    }

    .pt-filtro-busca-submit {
        width: 100%;
    }

    .pt-page-shell form > .btn,
    .pt-page-shell form > a.btn {
        width: 100%;
    }

    .pt-page-shell form > .btn + .btn,
    .pt-page-shell form > .btn + a.btn,
    .pt-page-shell form > a.btn + .btn,
    .pt-page-shell form > a.btn + a.btn {
        margin-left: 0 !important;
        margin-top: 0.5rem;
    }

    .pt-pref-kanban-options .form-check-inline {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    .pt-pref-kanban-options .form-check-input {
        width: 1.2rem;
        height: 1.2rem;
    }
}

/* =============================================================================
   UI Premium — camada visual refinada (body.pt-ui-premium)
   ============================================================================= */

.pt-ui-premium {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.pt-ui-premium {
    background:
        radial-gradient(ellipse 70% 45% at 0% -8%, rgba(var(--pt-primary-rgb, 9, 58, 135), 0.06), transparent 55%),
        radial-gradient(ellipse 50% 35% at 100% 0%, rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.05), transparent 48%),
        var(--pt-paper);
    font-family: var(--pt-font-sans);
}

/* Botões primários */
.pt-ui-premium .btn-primary,
.pt-ui-premium .btn-primary:focus {
    background: var(--pt-primary, var(--pt-ink));
    border: 1px solid var(--pt-primary, var(--pt-ink));
    border-radius: var(--pt-radius-md);
    box-shadow: none;
}

.pt-ui-premium .btn-primary:hover {
    filter: none;
    transform: none;
    background: var(--pt-primary-2, var(--pt-ink-2));
    border-color: var(--pt-primary-2, var(--pt-ink-2));
    box-shadow: none;
}

.pt-ui-premium .btn-outline-primary {
    border-color: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.35);
    color: var(--pt-ink);
}

.pt-ui-premium .btn-outline-primary:hover {
    background: rgba(15, 42, 58, 0.06);
    border-color: rgba(15, 42, 58, 0.5);
    color: var(--pt-ink-3);
}

/* Cards elevados */
.pt-ui-premium .pt-card-elevated,
.pt-ui-premium .card.pt-card-elevated {
    border: 1px solid var(--pt-border-soft);
    border-radius: var(--pt-radius-md);
    box-shadow: none;
    background: var(--pt-surface);
    overflow: visible;
}

.pt-ui-premium .pt-card-elevated .pt-card-header,
.pt-ui-premium .pt-card-elevated > .card-header {
    background: linear-gradient(180deg, var(--pt-surface-soft) 0%, var(--pt-surface) 100%);
    border-bottom: 1px solid var(--pt-border-soft);
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}

.pt-card-header-text {
    min-width: 0;
}

.pt-card-header-text .fw-semibold {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

.letter-spacing-tight {
    letter-spacing: 0.06em;
}

/* Topbar & sidebar */
.pt-ui-premium .pt-topbar {
    height: 56px;
    background: var(--pt-panel);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-bottom: 1px solid var(--pt-border-soft);
    box-shadow: none;
}

.pt-ui-premium .pt-topbar-title-icon {
    background: rgba(15, 42, 58, 0.08);
    color: var(--pt-ink);
    box-shadow: none;
    border-radius: 8px;
}

.pt-ui-premium .pt-topbar-title {
    font-family: var(--pt-font-sans);
    font-weight: 650;
    color: var(--pt-text);
}

.pt-ui-premium .pt-sidebar {
    background:
        radial-gradient(120% 70% at 0% 0%, rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.18) 0%, transparent 48%),
        linear-gradient(185deg, var(--pt-primary, #093A87) 0%, var(--pt-primary-2, #07306E) 55%, var(--pt-primary-3, #05224E) 100%);
    box-shadow:
        inset -1px 0 0 rgba(255, 255, 255, 0.06),
        10px 0 28px rgba(15, 42, 58, 0.16);
}

.pt-ui-premium .pt-side-link.active {
    background: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

.pt-ui-premium .pt-brand-text {
    font-family: var(--pt-font-display);
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Cabeçalho do ticket */
.pt-ui-premium .pt-detail-header {
    position: relative;
    padding: 1rem 1.15rem 1.1rem;
    border-radius: var(--pt-radius-md);
    border: 1px solid var(--pt-border-soft);
    background: var(--pt-surface);
    box-shadow: none;
    overflow: visible;
}

.pt-ui-premium .pt-detail-header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--pt-signal);
    opacity: 1;
}

.pt-ui-premium .pt-detail-header-top {
    border-bottom-color: var(--pt-border-soft);
}

.pt-ui-premium .pt-detail-id {
    font-size: var(--pt-text-label);
    padding: 0.2rem 0.45rem;
    border-radius: 6px;
    background: rgba(15, 42, 58, 0.06);
    border: 1px solid rgba(15, 42, 58, 0.1);
    color: var(--pt-ink);
}

.pt-ui-premium .pt-detail-meta .badge,
.pt-ui-premium .pt-detail-meta .pt-badge {
    font-weight: 600;
    font-size: var(--pt-text-label);
    letter-spacing: 0.03em;
    padding: 0.35em 0.6em;
    border-radius: 6px;
    border: 1px solid rgba(15, 42, 58, 0.1);
    box-shadow: none;
}

.pt-ui-premium .pt-detail-title {
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.35;
}

/* Cluster de ações */
.pt-action-cluster {
    display: inline-flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 0.35rem;
    padding: 0.25rem;
    border-radius: 8px;
    background: var(--pt-panel, #f7f9fa);
    border: 1px solid var(--pt-border-soft);
    box-shadow: none;
}

.pt-ui-premium .pt-action-cluster .pt-action-primary {
    box-shadow: none;
    border-radius: 8px;
}

.pt-ui-premium .pt-action-ghost {
    border-color: transparent;
    background: transparent;
    color: var(--pt-muted, #5b6b7a);
    border-radius: 8px;
}

.pt-ui-premium .pt-action-ghost:hover {
    background: rgba(15, 42, 58, 0.06);
    color: var(--pt-ink);
}

.pt-ui-premium .pt-action-danger {
    opacity: 0.92;
}

.pt-ui-premium .pt-action-danger:hover {
    opacity: 1;
}

/* Dashboard & listagens */
.pt-ui-premium .stat-card {
    border-radius: var(--pt-radius-md);
    border: 1px solid var(--pt-border-soft);
    box-shadow: none;
    background: var(--pt-surface);
}

.pt-ui-premium .stat-card:hover {
    box-shadow: none;
    transform: none;
    border-color: rgba(15, 42, 58, 0.2);
}

.pt-ui-premium .dashboard-card {
    border-radius: var(--pt-radius-lg);
    border: 1px solid var(--pt-border-soft);
    box-shadow: var(--pt-shadow-premium);
}

.pt-ui-premium .tickets-toolbar,
.pt-ui-premium .filtros-card {
    border-radius: var(--pt-radius-lg);
    box-shadow: var(--pt-shadow-premium);
}

.pt-ui-premium .pt-breadcrumb-item a {
    font-weight: 600;
}

.pt-ui-premium .pt-filtro-busca-section {
    border-radius: 14px;
}

/* Toasts */
.pt-ui-premium .pt-toast {
    border-radius: var(--pt-radius-md);
    backdrop-filter: blur(8px);
}

/* (premium dark: ver bloco "Modo escuro v2" no final do arquivo) */

@media (prefers-reduced-motion: reduce) {
    .pt-ui-premium .btn-primary:hover,
    .pt-ui-premium .stat-card:hover {
        transform: none;
    }
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-dist-chip {
    border-color: rgba(148, 163, 184, 0.16);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}

[data-bs-theme="dark"] .dashboard-premium .dashboard-dist-chip:hover {
    border-color: rgba(148, 163, 184, 0.28);
}

[data-bs-theme="dark"] .pt-ui-premium .btn-outline-primary {
    border-color: rgba(147, 197, 253, 0.45);
    color: #93c5fd;
}

[data-bs-theme="dark"] .pt-ui-premium .btn-outline-primary:hover {
    background: rgba(var(--pt-primary-rgb, 9, 58, 135), 0.28);
    border-color: rgba(147, 197, 253, 0.55);
    color: #dbeafe;
}

[data-bs-theme="dark"] .dashboard-premium .stat-card-warning .stat-card-icon {
    background: rgba(var(--pt-info-glow-rgb, 16, 202, 240), 0.18);
    color: #7dd3fc;
}

/* ——— Modo escuro v2 (refino premium + componentes) ——— */

[data-bs-theme="dark"] .pt-topbar [data-pt-theme].is-active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.45);
    color: #dbeafe;
    box-shadow: 0 0 0 1px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.2);
}

[data-bs-theme="dark"] .pt-breadcrumb-item a {
    color: #93c5fd;
}

[data-bs-theme="dark"] .pt-breadcrumb-item.is-current span {
    color: #f1f5f9;
}

[data-bs-theme="dark"] body.pt-ui-premium .pt-detail-header {
    background: linear-gradient(165deg, rgba(26, 36, 54, 0.98) 0%, rgba(12, 18, 30, 0.99) 100%);
    border-color: rgba(148, 163, 184, 0.16);
}

[data-bs-theme="dark"] .pt-detail-meta .badge.bg-secondary {
    background: rgba(148, 163, 184, 0.22) !important;
    color: #e2e8f0 !important;
    border: 1px solid rgba(148, 163, 184, 0.28);
}

[data-bs-theme="dark"] .pt-detail-meta .badge.bg-info,
[data-bs-theme="dark"] .pt-detail-meta .badge.bg-info.text-dark {
    background: rgba(56, 189, 248, 0.2) !important;
    color: #7dd3fc !important;
    border: 1px solid rgba(56, 189, 248, 0.35);
}

[data-bs-theme="dark"] .pt-detail-meta .badge.bg-warning,
[data-bs-theme="dark"] .pt-detail-meta .badge.bg-warning.text-dark {
    background: rgba(251, 191, 36, 0.22) !important;
    color: #fde68a !important;
    border: 1px solid rgba(251, 191, 36, 0.35);
}

[data-bs-theme="dark"] .pt-ui-premium .pt-card-elevated,
[data-bs-theme="dark"] .pt-ui-premium .card.pt-card-elevated {
    background: linear-gradient(180deg, var(--pt-surface) 0%, color-mix(in srgb, var(--pt-surface-soft) 88%, #000) 100%);
    border-color: rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .pt-ui-premium .pt-card-elevated > .card-header,
[data-bs-theme="dark"] .pt-ui-premium .pt-card-elevated .pt-card-header {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, transparent 100%);
    border-bottom-color: rgba(148, 163, 184, 0.12);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .pt-ui-premium .stat-card {
    background: linear-gradient(145deg, var(--pt-surface) 0%, var(--pt-surface-soft) 100%);
    border-color: rgba(148, 163, 184, 0.12);
}

[data-bs-theme="dark"] .pt-ui-premium .stat-card-value {
    color: #f8fafc;
}

[data-bs-theme="dark"] .pt-ui-premium .stat-card-danger .stat-card-value {
    color: #fca5a5;
}

[data-bs-theme="dark"] .pt-ui-premium .stat-card-success .stat-card-value {
    color: #86efac;
}

[data-bs-theme="dark"] .pt-config-nav {
    background: var(--pt-surface);
    border-color: rgba(148, 163, 184, 0.14);
    box-shadow: var(--pt-shadow-premium);
}

[data-bs-theme="dark"] .pt-config-nav-link {
    color: #cbd5e1;
}

[data-bs-theme="dark"] .pt-config-nav-link:hover {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
    color: #e0edff;
}

[data-bs-theme="dark"] .pt-config-nav-link.active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.14);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
    color: #dbeafe;
}

[data-bs-theme="dark"] .pt-config-panel > .d-flex h1,
[data-bs-theme="dark"] .pt-config-panel > h1 {
    color: #f8fafc;
}

[data-bs-theme="dark"] .pt-section-title {
    color: #f8fafc;
}

[data-bs-theme="dark"] .pt-section-filters {
    background: rgba(15, 23, 42, 0.72);
    border-color: rgba(148, 163, 184, 0.22);
}

[data-bs-theme="dark"] .pt-section-filters .pt-toolbar-toggle {
    border-color: rgba(148, 163, 184, 0.22);
    color: #cbd5e1;
}

[data-bs-theme="dark"] .pt-section-filters .pt-toolbar-toggle.is-active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.4);
    color: #dbeafe;
}

[data-bs-theme="dark"] .pt-notif-list-item.is-unread {
    background: rgba(96, 165, 250, 0.08);
}

[data-bs-theme="dark"] .pt-section-badge {
    background: rgba(2, 6, 23, 0.45);
    border-color: rgba(148, 163, 184, 0.22);
    color: #cbd5e1;
}

[data-bs-theme="dark"] .pt-table-wrap {
    background: var(--pt-surface);
    border-color: rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .pt-table-wrap .table thead th {
    background: var(--pt-surface-soft);
    color: #94a3b8;
}

[data-bs-theme="dark"] .table-hover > tbody > tr:hover > * {
    --bs-table-hover-bg: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.1);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .list-group-item {
    background-color: var(--pt-surface);
    border-color: rgba(148, 163, 184, 0.12);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .list-group-item-action:hover,
[data-bs-theme="dark"] .list-group-item-action:focus {
    background-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.1);
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .dropdown-menu {
    background: var(--pt-surface);
    border-color: rgba(148, 163, 184, 0.16);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
}

[data-bs-theme="dark"] .dropdown-item {
    color: #e2e8f0;
}

[data-bs-theme="dark"] .dropdown-item:hover,
[data-bs-theme="dark"] .dropdown-item:focus {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.14);
    color: #f8fafc;
}

[data-bs-theme="dark"] .pt-notif-menu {
    background: var(--pt-surface);
    border: 1px solid rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .pt-notif-item.is-unread {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.12);
}

[data-bs-theme="dark"] .pt-notif-title {
    color: #f1f5f9;
}

[data-bs-theme="dark"] .pt-notif-msg {
    color: #94a3b8;
}

[data-bs-theme="dark"] .modal-content {
    background: var(--pt-surface);
    border-color: rgba(148, 163, 184, 0.16);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.65);
}

[data-bs-theme="dark"] .modal-header,
[data-bs-theme="dark"] .modal-footer {
    border-color: rgba(148, 163, 184, 0.14);
}

[data-bs-theme="dark"] .btn-close {
    filter: invert(1) grayscale(100%) brightness(1.8);
    opacity: 0.72;
}

[data-bs-theme="dark"] .alert {
    border-width: 1px;
}

[data-bs-theme="dark"] .alert-info {
    background: rgba(56, 189, 248, 0.12);
    border-color: rgba(56, 189, 248, 0.28);
    color: #bae6fd;
}

[data-bs-theme="dark"] .alert-warning {
    background: rgba(251, 191, 36, 0.12);
    border-color: rgba(251, 191, 36, 0.28);
    color: #fde68a;
}

[data-bs-theme="dark"] .alert-success {
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.28);
    color: #bbf7d0;
}

[data-bs-theme="dark"] .alert-danger {
    background: rgba(248, 113, 113, 0.12);
    border-color: rgba(248, 113, 113, 0.28);
    color: #fecaca;
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select {
    background-color: rgba(8, 13, 24, 0.85);
    border-color: rgba(148, 163, 184, 0.22);
    color: #f1f5f9;
}

[data-bs-theme="dark"] .form-control::placeholder {
    color: #64748b;
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: rgba(8, 13, 24, 0.95);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.55);
    box-shadow: 0 0 0 3px rgba(var(--pt-primary-rgb, 13, 110, 253), 0.22);
    color: #f8fafc;
}

[data-bs-theme="dark"] .form-control:disabled,
[data-bs-theme="dark"] .form-select:disabled {
    background-color: rgba(15, 23, 42, 0.5);
    color: #64748b;
}

[data-bs-theme="dark"] .input-group-text {
    background: var(--pt-surface-soft);
    border-color: rgba(148, 163, 184, 0.22);
    color: #94a3b8;
}

[data-bs-theme="dark"] .btn-outline-primary {
    color: #93c5fd;
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.45);
}

[data-bs-theme="dark"] .btn-outline-primary:hover {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.18);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.6);
    color: #dbeafe;
}

[data-bs-theme="dark"] .btn-outline-secondary {
    background: rgba(15, 23, 42, 0.45);
    border-color: rgba(148, 163, 184, 0.28);
    color: #cbd5e1;
}

[data-bs-theme="dark"] .btn-outline-secondary:hover {
    background: rgba(30, 41, 59, 0.75);
    border-color: rgba(148, 163, 184, 0.4);
    color: #f1f5f9;
}

[data-bs-theme="dark"] .btn-outline-danger {
    color: #fca5a5;
    border-color: rgba(248, 113, 113, 0.45);
}

[data-bs-theme="dark"] .btn-outline-danger:hover {
    background: rgba(248, 113, 113, 0.14);
    color: #fecaca;
}

[data-bs-theme="dark"] .pt-ui-premium .pt-action-ghost {
    color: #94a3b8;
}

[data-bs-theme="dark"] .pt-ui-premium .pt-action-ghost:hover {
    background: rgba(148, 163, 184, 0.1);
    color: #f1f5f9;
}

[data-bs-theme="dark"] .pt-sticky-toolbar-wrap {
    background: color-mix(in srgb, var(--bs-body-bg) 90%, transparent);
}

[data-bs-theme="dark"] .pt-sticky-toolbar-wrap.is-scrolled {
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.45);
}

[data-bs-theme="dark"] .tickets-toolbar .pt-toolbar-toggle {
    border-color: rgba(148, 163, 184, 0.22);
    color: #cbd5e1;
}

[data-bs-theme="dark"] .tickets-toolbar .pt-toolbar-toggle.is-active {
    background: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.2);
    border-color: rgba(var(--pt-primary-rgb, 13, 110, 253), 0.4);
    color: #dbeafe;
}

[data-bs-theme="dark"] hr {
    border-color: rgba(148, 163, 184, 0.14);
    opacity: 1;
}

[data-bs-theme="dark"] ::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.28);
    border-radius: 999px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: rgba(148, 163, 184, 0.42);
    background-clip: padding-box;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-track {
    background: transparent;
}

[data-bs-theme="dark"] {
    scrollbar-color: rgba(148, 163, 184, 0.28) transparent;
}
