:root { --pa-primary: #0b5ed7; --pa-dark: #212b36; --pa-sidebar-w: 250px; }
body { background: #f4f6f9; font-size: .95rem; }
.btn-primary { --bs-btn-bg: var(--pa-primary); --bs-btn-border-color: var(--pa-primary); --bs-btn-hover-bg: color-mix(in srgb, var(--pa-primary) 85%, #000); --bs-btn-hover-border-color: color-mix(in srgb, var(--pa-primary) 85%, #000); --bs-btn-active-bg: color-mix(in srgb, var(--pa-primary) 78%, #000); --bs-btn-disabled-bg: var(--pa-primary); }
a { color: var(--pa-primary); }
.text-bg-primary { background-color: var(--pa-primary) !important; }

.pa-shell { display: flex; min-height: 100vh; }
.pa-sidebar { width: var(--pa-sidebar-w); background: var(--pa-dark); color: #cfd6de; flex: 0 0 var(--pa-sidebar-w); transition: margin .2s; position: sticky; top: 0; height: 100vh; overflow-y: auto; z-index: 1030; }
.pa-brand { display: flex; align-items: center; gap: .6rem; padding: 1rem 1.1rem; color: #fff; font-weight: 600; border-bottom: 1px solid rgba(255,255,255,.08); }
.pa-logo { max-height: 34px; max-width: 44px; object-fit: contain; }
.pa-brand-text { line-height: 1.15; font-size: .95rem; }
.pa-nav { padding: .6rem 0 2rem; }
.pa-nav a { display: flex; align-items: center; gap: .7rem; color: #cfd6de; padding: .6rem 1.1rem; text-decoration: none; border-left: 3px solid transparent; }
.pa-nav a:hover { background: rgba(255,255,255,.06); color: #fff; }
.pa-nav a.active { background: rgba(255,255,255,.1); color: #fff; border-left-color: var(--pa-primary); }
.pa-nav i { font-size: 1.1rem; width: 1.2rem; text-align: center; }
.pa-nav-title { text-transform: uppercase; font-size: .7rem; letter-spacing: .08em; color: #8a96a3; padding: 1rem 1.1rem .3rem; }
.pa-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.pa-topbar { background: #fff; border-bottom: 1px solid #e3e7ec; padding: .5rem 1rem; display: flex; align-items: center; position: sticky; top: 0; z-index: 1020; }
.pa-content { padding: 1.25rem; flex: 1 1 auto; }
.pa-footer { padding: .75rem 1.25rem; border-top: 1px solid #e3e7ec; background: #fff; }
.pa-backdrop { display: none; }
.pa-notif-menu { width: 340px; max-width: 92vw; max-height: 70vh; overflow-y: auto; }
body.pa-collapsed .pa-sidebar { margin-left: calc(-1 * var(--pa-sidebar-w)); }
@media (max-width: 991.98px) {
  .pa-sidebar { position: fixed; left: 0; top: 0; margin-left: calc(-1 * var(--pa-sidebar-w)); }
  body.pa-open .pa-sidebar { margin-left: 0; box-shadow: 0 0 30px rgba(0,0,0,.4); }
  body.pa-open .pa-backdrop { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 1025; }
  body.pa-collapsed .pa-sidebar { margin-left: calc(-1 * var(--pa-sidebar-w)); }
  .pa-content { padding: .9rem; }
}
.pa-loading { position: fixed; inset: 0; background: rgba(20,28,38,.45); z-index: 2000; display: flex; align-items: center; justify-content: center; }
.pa-auth-body { background: linear-gradient(135deg, var(--pa-dark), var(--pa-primary)); min-height: 100vh; }

.card { border: 1px solid #e3e7ec; box-shadow: 0 1px 2px rgba(16,24,40,.04); }
.card-header { background: #fff; font-weight: 600; }
.kpi { border-left: 4px solid var(--pa-primary); text-decoration: none; color: inherit; display: block; height: 100%; }
.kpi:hover { box-shadow: 0 4px 14px rgba(16,24,40,.1); color: inherit; }
.kpi .kpi-value { font-size: 1.7rem; font-weight: 700; line-height: 1.1; }
.kpi .kpi-label { font-size: .78rem; color: #667085; text-transform: uppercase; letter-spacing: .03em; }
.kpi.kpi-danger { border-left-color: #dc3545; } .kpi.kpi-warning { border-left-color: #f59f00; } .kpi.kpi-success { border-left-color: #198754; } .kpi.kpi-info { border-left-color: #0dcaf0; } .kpi.kpi-muted { border-left-color: #98a2b3; }
.table > :not(caption) > * > * { padding: .55rem .65rem; }
.table-sticky thead th { position: sticky; top: 0; background: #f8f9fb; z-index: 1; }
.chart-box { position: relative; height: 280px; }
.form-section { border-left: 3px solid var(--pa-primary); padding-left: .9rem; margin: 1.5rem 0 .9rem; font-weight: 600; }
.req::after { content: " *"; color: #dc3545; }
.prog { height: 8px; } .prog-lg { height: 14px; }
.timeline { list-style: none; padding-left: 0; margin: 0; border-left: 2px solid #dfe3e8; }
.timeline > li { position: relative; padding: 0 0 1rem 1.1rem; }
.timeline > li::before { content: ""; position: absolute; left: -6px; top: .35rem; width: 10px; height: 10px; border-radius: 50%; background: var(--pa-primary); }
.tab-content > .tab-pane { padding-top: 1rem; }
.nav-tabs .nav-link { color: #475467; } .nav-tabs .nav-link.active { font-weight: 600; }
.sla-ok { color: #198754; } .sla-warn { color: #b57600; } .sla-late { color: #dc3545; font-weight: 600; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0,1fr)); gap: 1px; background: #dfe3e8; border: 1px solid #dfe3e8; }
.cal-head { background: #f1f3f6; text-align: center; font-size: .75rem; font-weight: 600; padding: .35rem 0; text-transform: uppercase; }
.cal-cell { background: #fff; min-height: 104px; padding: .25rem; font-size: .75rem; overflow: hidden; }
.cal-cell.other { background: #fafbfc; color: #98a2b3; } .cal-cell.today { outline: 2px solid var(--pa-primary); outline-offset: -2px; }
.cal-ev { display: block; border-radius: 3px; padding: 1px 4px; margin-top: 2px; color: #fff; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-ev.s-ok { background: #0d6efd; } .cal-ev.s-warn { background: #f59f00; color: #3a2a00; } .cal-ev.s-late { background: #dc3545; } .cal-ev.s-done { background: #198754; } .cal-ev.s-blocked { background: #6c757d; } .cal-ev.s-mark { background: #7048e8; }
.legend-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; }
.pre-wrap { white-space: pre-wrap; }
.w5 { border-left: 4px solid var(--pa-primary); background: #fff; padding: .6rem .8rem; border-radius: 4px; }
@media (max-width: 767.98px) {
  .cal-cell { min-height: 70px; } .cal-ev { font-size: .65rem; }
  .table-stack thead { display: none; }
  .table-stack tr { display: block; border-bottom: 2px solid #e3e7ec; margin-bottom: .4rem; }
  .table-stack td { display: flex; justify-content: space-between; gap: 1rem; border: 0; padding: .3rem .65rem; text-align: right; }
  .table-stack td::before { content: attr(data-label); font-weight: 600; text-align: left; color: #667085; }
}
@media print {
  .pa-sidebar, .pa-topbar, .pa-footer, .no-print, .pa-backdrop { display: none !important; }
  .pa-content { padding: 0; } body { background: #fff; } .card { box-shadow: none; border-color: #ccc; }
  a { color: inherit; text-decoration: none; } .tab-content > .tab-pane { display: block !important; opacity: 1 !important; }
}
