:root{
  --blue:#0957b8; --blue-2:#0a83d9; --green:#28a745; --green-2:#62c933; --ink:#172033; --muted:#6b7280; --line:#e7ebf2; --bg:#f4f7fb; --card:#ffffff; --sidebar:#101828; --sidebar-2:#16233a;
}
*{box-sizing:border-box} body{margin:0;background:radial-gradient(circle at top left,#e9f4ff 0,#f6f8fb 34%,#f4f7fb 100%);color:var(--ink);font-family:Inter,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif} a{color:inherit}.app-shell{display:flex;min-height:100vh}.sidebar{width:292px;background:linear-gradient(180deg,var(--sidebar),var(--sidebar-2));color:#e7eefb;position:fixed;top:0;left:0;bottom:0;padding:22px 18px;z-index:1040;box-shadow:18px 0 48px rgba(12,25,47,.18);overflow-y:auto}.brand-box{display:flex;align-items:center;gap:13px;padding:10px 10px 20px;border-bottom:1px solid rgba(255,255,255,.1)}.brand-mark{width:58px;height:50px;object-fit:cover;object-position:top center;border-radius:16px;background:#fff;box-shadow:0 10px 24px rgba(0,0,0,.22)}.brand-box strong{display:block;font-size:1.05rem;letter-spacing:.2px}.brand-box span{display:block;color:#9fb0cc;font-size:.78rem;margin-top:2px}.sidebar-nav{padding:18px 0}.sidebar-nav a{height:42px;display:flex;align-items:center;gap:12px;text-decoration:none;color:#b9c7dc;border-radius:14px;padding:0 13px;margin:4px 0;font-size:.93rem;transition:.18s}.sidebar-nav a i{font-size:1.05rem;width:21px;text-align:center}.sidebar-nav a:hover{background:rgba(255,255,255,.08);color:#fff;transform:translateX(2px)}.sidebar-nav a.active{background:linear-gradient(135deg,var(--blue),var(--green));color:#fff;box-shadow:0 12px 28px rgba(9,87,184,.3)}.nav-section{font-size:.68rem;text-transform:uppercase;letter-spacing:.12em;color:#7f8da8;margin:18px 10px 8px}.sidebar-footer{padding:13px;margin-top:15px;border-radius:16px;background:rgba(255,255,255,.07);font-size:.8rem;color:#c4d1e4}.content-wrap{margin-left:292px;min-height:100vh;width:calc(100% - 292px)}.topbar{height:76px;display:flex;align-items:center;justify-content:space-between;padding:0 28px;background:rgba(255,255,255,.78);backdrop-filter:blur(16px);border-bottom:1px solid rgba(231,235,242,.85);position:sticky;top:0;z-index:1030}.topbar-actions{display:flex;align-items:center;gap:10px}.user-pill{height:38px;padding:0 12px;border:1px solid var(--line);background:#fff;border-radius:999px;display:flex;align-items:center;gap:8px;box-shadow:0 8px 22px rgba(15,23,42,.04)}.user-pill em{font-style:normal;font-size:.72rem;color:var(--green);background:#eaf8ed;border-radius:999px;padding:2px 7px}.icon-btn{border:0;background:#fff;border-radius:12px;width:40px;height:40px;box-shadow:0 8px 20px rgba(0,0,0,.06)}.page-container{padding:28px;max-width:1600px}.page-title{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:22px}.page-title h1{font-size:1.7rem;margin:0;font-weight:800;letter-spacing:-.03em}.page-title p{color:var(--muted);margin:.25rem 0 0}.card{border:0;border-radius:24px;background:rgba(255,255,255,.94);box-shadow:0 18px 45px rgba(16,24,40,.08);overflow:hidden}.card-header-modern{padding:20px 22px;border-bottom:1px solid var(--line);background:linear-gradient(180deg,#fff,#fbfcff)}.kpi-card{padding:20px;position:relative;overflow:hidden}.kpi-card::after{content:"";position:absolute;right:-25px;top:-35px;width:105px;height:105px;border-radius:50%;background:linear-gradient(135deg,rgba(9,87,184,.12),rgba(40,167,69,.14))}.kpi-label{color:var(--muted);font-size:.86rem}.kpi-value{font-size:2rem;font-weight:800;letter-spacing:-.04em;margin:2px 0}.kpi-icon{width:48px;height:48px;border-radius:16px;display:flex;align-items:center;justify-content:center;background:#eef6ff;color:var(--blue);font-size:1.45rem}.kpi-icon.green{background:#ecf9ee;color:var(--green)}.kpi-icon.orange{background:#fff5e6;color:#b76b00}.kpi-icon.red{background:#fff0f0;color:#be2b2b}.table{vertical-align:middle}.table thead th{font-size:.75rem;text-transform:uppercase;letter-spacing:.05em;color:#667085;background:#f8fafc;border-bottom:1px solid var(--line);white-space:nowrap}.table td{border-color:#edf1f7}.form-control,.form-select{border-radius:14px;border-color:#dce3ee;padding:.7rem .85rem}.form-control:focus,.form-select:focus{box-shadow:0 0 0 .22rem rgba(9,87,184,.1);border-color:#89b7ed}.btn{border-radius:13px;font-weight:700}.btn-primary{background:linear-gradient(135deg,var(--blue),var(--blue-2));border:0}.btn-success{background:linear-gradient(135deg,var(--green),var(--green-2));border:0}.btn-outline-secondary{border-color:#d6dce7;color:#344054}.badge-soft-danger{background:#ffe7e7;color:#aa1f1f}.badge-soft-warning{background:#fff4d6;color:#9c6a00}.badge-soft-success{background:#def8e4;color:#146b22}.badge-soft-info{background:#e7f3ff;color:#0758a8}.signature-pad{border:2px dashed #a9c1dd;border-radius:18px;background:#fff;width:100%;height:190px;touch-action:none}.soft-alert{border:0;border-radius:18px;box-shadow:0 12px 28px rgba(16,24,40,.08)}.login-main{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:24px;background:radial-gradient(circle at top left,#dff0ff,transparent 35%),linear-gradient(135deg,#0f233f,#0a4d8f 52%,#0e8f53)}.login-card{width:min(1040px,100%);display:grid;grid-template-columns:1.05fr .95fr;background:rgba(255,255,255,.96);border-radius:32px;overflow:hidden;box-shadow:0 30px 90px rgba(0,0,0,.28)}.login-hero{background:linear-gradient(160deg,#0a3e7c,#0a85d9 48%,#27a844);color:#fff;padding:46px;display:flex;flex-direction:column;justify-content:space-between;min-height:560px}.login-hero img{width:260px;max-width:100%;background:#fff;border-radius:24px;box-shadow:0 20px 50px rgba(0,0,0,.2)}.login-hero h1{font-size:2.4rem;font-weight:900;letter-spacing:-.05em;margin-top:34px}.login-form{padding:54px}.mini-stat{display:flex;align-items:center;gap:12px;padding:13px;border-radius:16px;background:#f8fafc;border:1px solid var(--line)}.mini-stat i{font-size:1.3rem;color:var(--blue)}.chart-box{height:300px}.small-chart{height:235px}.status-dot{width:10px;height:10px;border-radius:50%;display:inline-block;margin-right:7px}.dot-green{background:#22c55e}.dot-red{background:#ef4444}.dot-yellow{background:#f59e0b}.quick-list a,.quick-list .list-row{display:flex;justify-content:space-between;gap:12px;padding:13px 0;border-bottom:1px solid var(--line);text-decoration:none}.quick-list a:last-child,.quick-list .list-row:last-child{border-bottom:0}.print-logo{max-width:220px}.avatar-circle{width:42px;height:42px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;background:linear-gradient(135deg,#e8f2ff,#e9f8ef);color:var(--blue);font-weight:800}.sidebar-backdrop{display:none}.text-bg-light-blue{background:#eef6ff;color:#0957b8}.empty-state{padding:34px;text-align:center;color:var(--muted)}.empty-state i{font-size:2.2rem;color:#b9c7dc}.subtle{color:var(--muted)}
@media(max-width:991px){.sidebar{transform:translateX(-105%);transition:.2s}.sidebar.open{transform:translateX(0)}.content-wrap{margin-left:0;width:100%}.sidebar-backdrop.show{display:block;position:fixed;inset:0;background:rgba(15,23,42,.42);z-index:1035}.topbar{padding:0 16px}.page-container{padding:18px}.topbar-actions .user-pill{display:none}.login-card{grid-template-columns:1fr}.login-hero{min-height:auto}.login-form{padding:34px}.chart-box,.small-chart{height:260px}}
@media print{.sidebar,.topbar,.no-print,.alert,.sidebar-backdrop{display:none!important}.content-wrap{margin:0;width:100%}.page-container{padding:0}.card{box-shadow:none;border:1px solid #ddd;border-radius:8px}body{background:#fff}.table thead th{background:#fff}}

.report-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:22px;padding:30px;border-radius:30px;background:radial-gradient(circle at top left,rgba(255,255,255,.25),transparent 30%),linear-gradient(135deg,#073b79,#0a83d9 48%,#28a745);color:#fff;box-shadow:0 26px 60px rgba(9,87,184,.22);position:relative;overflow:hidden}.report-hero::after{content:"";position:absolute;right:-90px;top:-120px;width:300px;height:300px;border-radius:50%;background:rgba(255,255,255,.14)}.report-hero>div{position:relative;z-index:1}.report-hero h1{font-size:2rem;font-weight:900;letter-spacing:-.045em;margin:.35rem 0}.report-hero p{max-width:780px;margin:0;color:rgba(255,255,255,.86)}.eyebrow{display:inline-flex;align-items:center;gap:8px;font-size:.75rem;text-transform:uppercase;letter-spacing:.13em;font-weight:800;background:rgba(255,255,255,.16);border:1px solid rgba(255,255,255,.22);border-radius:999px;padding:8px 12px}.report-period{display:inline-flex;align-items:center;gap:8px;margin-top:16px;background:rgba(255,255,255,.14);border:1px solid rgba(255,255,255,.2);padding:9px 12px;border-radius:14px}.report-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end}.report-filter-card{border:1px solid rgba(255,255,255,.75)}.report-stat-card{display:flex;flex-direction:row;align-items:center;gap:16px;padding:20px;min-height:128px;transition:.18s}.report-stat-card:hover{transform:translateY(-3px);box-shadow:0 24px 55px rgba(16,24,40,.12)}.report-stat-card span{display:block;color:var(--muted);font-size:.84rem}.report-stat-card strong{display:block;font-size:1.72rem;font-weight:900;letter-spacing:-.045em;margin:2px 0;color:var(--ink)}.report-stat-card small{color:var(--muted)}.report-stat-icon{width:58px;height:58px;border-radius:19px;display:flex;align-items:center;justify-content:center;font-size:1.6rem;flex:0 0 58px}.report-stat-icon.blue{background:#eaf4ff;color:#0957b8}.report-stat-icon.green{background:#e9f8ef;color:#229b3c}.report-stat-icon.purple{background:#f1ecff;color:#6941c6}.report-stat-icon.orange{background:#fff4e5;color:#b76b00}.chart-card .card-header-modern{min-height:86px}.report-alert-list .list-row{align-items:center}.table-hover tbody tr:hover{background:#f8fbff}@media(max-width:991px){.report-hero{align-items:flex-start;flex-direction:column;padding:24px}.report-actions{justify-content:flex-start}.report-hero h1{font-size:1.55rem}.report-stat-card{min-height:auto}}

.topbar-left{display:flex;align-items:center;gap:12px}
.topbar-chip{height:38px;padding:0 12px;border:1px solid var(--line);background:#fff;border-radius:999px;display:flex;align-items:center;gap:8px;box-shadow:0 8px 22px rgba(15,23,42,.04);font-size:.85rem;color:#475467}
.module-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:22px;padding:28px 30px;border-radius:30px;background:radial-gradient(circle at top left,rgba(255,255,255,.18),transparent 32%),linear-gradient(135deg,#0d3f7d,#0a7fd2 52%,#1ea866);color:#fff;box-shadow:0 26px 60px rgba(9,87,184,.18);position:relative;overflow:hidden;margin-bottom:22px}
.module-hero::after{content:"";position:absolute;right:-110px;top:-110px;width:280px;height:280px;border-radius:50%;background:rgba(255,255,255,.11)}
.module-hero>div{position:relative;z-index:1}
.module-hero h1{margin:.35rem 0 0;font-size:1.9rem;font-weight:900;letter-spacing:-.05em}
.module-hero p{margin:.45rem 0 0;color:rgba(255,255,255,.88);max-width:800px}
.hero-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end;position:relative;z-index:1}
.hero-kpis{display:grid;grid-template-columns:repeat(4, minmax(0,1fr));gap:14px;margin-bottom:22px}
.mini-kpi{padding:18px 18px;border-radius:24px;background:rgba(255,255,255,.94);box-shadow:0 18px 45px rgba(16,24,40,.07);display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:108px}
.mini-kpi i{font-size:1.4rem}
.mini-kpi .icon{width:48px;height:48px;border-radius:16px;display:flex;align-items:center;justify-content:center;background:#eef6ff;color:#0957b8}
.mini-kpi .icon.green{background:#ecf9ee;color:#1d9852}
.mini-kpi .icon.orange{background:#fff5e6;color:#b76b00}
.mini-kpi .icon.purple{background:#f1ecff;color:#6941c6}
.mini-kpi small{display:block;color:var(--muted);font-size:.82rem}
.mini-kpi strong{display:block;font-size:1.6rem;line-height:1.1;letter-spacing:-.04em}
.panel-card{border:1px solid rgba(231,235,242,.8)}
.panel-card .card-header-modern{padding:18px 20px}
.panel-body{padding:20px}
.section-muted{color:var(--muted);font-size:.92rem}
.stats-row{display:grid;grid-template-columns:repeat(3, minmax(0,1fr));gap:14px}
.info-chip{display:inline-flex;align-items:center;gap:8px;border-radius:999px;padding:8px 12px;background:#eef6ff;color:#0a5eb5;font-size:.82rem;font-weight:700}
.info-chip.success{background:#ebf8ef;color:#1a8f4a}
.info-chip.warning{background:#fff5e8;color:#b76b00}
.info-chip.danger{background:#ffeaea;color:#b42318}
.form-tip{padding:13px 15px;border-radius:16px;background:#f8fbff;border:1px solid #e5eef9;color:#41516a;font-size:.9rem}
.data-card{overflow:hidden}
.data-card .table-responsive{padding:0}
.table tbody tr td{padding:.88rem .9rem}
.table thead th{padding:.92rem .9rem}
.table-modern tbody tr:hover{background:#f8fbff}
.inline-metric{display:flex;align-items:center;gap:10px}
.inline-metric .dot{width:12px;height:12px;border-radius:50%;background:linear-gradient(135deg,#0a7fd2,#1ea866)}
.split-actions{display:flex;justify-content:space-between;align-items:center;gap:15px;flex-wrap:wrap}
.empty-note{padding:15px;border-radius:16px;border:1px dashed #c8d8eb;background:#f8fbff;color:#58708c}
.entity-pill{display:inline-flex;align-items:center;gap:10px}
.entity-pill .avatar-circle{flex:0 0 42px}
.meta-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.meta-item{padding:14px;border:1px solid var(--line);border-radius:18px;background:#fcfdff}
.meta-item span{display:block;color:var(--muted);font-size:.8rem}
.meta-item strong{display:block;margin-top:4px}
.audit-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:22px}
.audit-card{padding:18px;border-radius:22px;background:#fff;box-shadow:0 18px 45px rgba(16,24,40,.06)}
.audit-card .label{color:var(--muted);font-size:.83rem}
.audit-card .value{font-size:1.65rem;font-weight:900;letter-spacing:-.04em}
.sticky-summary{position:sticky;top:92px}
.border-soft{border:1px solid var(--line)}
.card-header-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.subgrid-2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.subgrid-3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.quick-stats{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}
.quick-stats .badge{padding:.55rem .8rem;border-radius:999px;font-weight:700}
.table caption{caption-side:top;padding:12px 18px 0;color:var(--muted)}
@media(max-width:1199px){.hero-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.audit-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:991px){.module-hero{flex-direction:column;align-items:flex-start;padding:24px}.module-hero h1{font-size:1.55rem}.hero-actions{justify-content:flex-start}.stats-row,.subgrid-3,.meta-list{grid-template-columns:1fr}.subgrid-2{grid-template-columns:1fr}.sticky-summary{position:static}.hero-kpis,.audit-grid{grid-template-columns:1fr}.topbar-chip{display:none}}

/* Nova entrega - experiência profissional */
.delivery-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:22px;padding:30px;border-radius:30px;background:radial-gradient(circle at top left,rgba(255,255,255,.25),transparent 30%),linear-gradient(135deg,#082f64,#0a83d9 48%,#28a745);color:#fff;box-shadow:0 26px 60px rgba(9,87,184,.22);position:relative;overflow:hidden}.delivery-hero::after{content:"";position:absolute;right:-88px;top:-110px;width:290px;height:290px;border-radius:50%;background:rgba(255,255,255,.14)}.delivery-hero>div{position:relative;z-index:1}.delivery-hero h1{font-size:2rem;font-weight:900;letter-spacing:-.045em;margin:.35rem 0}.delivery-hero p{max-width:760px;margin:0;color:rgba(255,255,255,.88)}.delivery-hero-meta{display:flex;gap:10px;flex-wrap:wrap;margin-top:16px}.delivery-hero-meta span{display:inline-flex;align-items:center;gap:8px;background:rgba(255,255,255,.14);border:1px solid rgba(255,255,255,.2);padding:9px 12px;border-radius:14px}.delivery-hero-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end;position:relative;z-index:1}.delivery-stepper{display:grid;grid-template-columns:repeat(4,1fr);gap:14px}.delivery-stepper .step{position:relative;display:flex;align-items:center;gap:12px;padding:16px;border-radius:20px;background:rgba(255,255,255,.88);border:1px solid rgba(231,235,242,.92);box-shadow:0 14px 35px rgba(16,24,40,.06)}.delivery-stepper .step span{width:38px;height:38px;border-radius:14px;display:flex;align-items:center;justify-content:center;background:linear-gradient(135deg,#0957b8,#28a745);color:#fff;font-weight:900;box-shadow:0 10px 20px rgba(9,87,184,.18)}.delivery-stepper .step strong{display:block;font-size:.95rem}.delivery-stepper .step small{display:block;color:var(--muted);margin-top:1px}.delivery-panel{border:1px solid rgba(231,235,242,.92);border-radius:28px;background:rgba(255,255,255,.95);box-shadow:0 18px 45px rgba(16,24,40,.08);padding:22px;overflow:hidden}.delivery-panel-header{display:flex;align-items:flex-start;gap:14px;margin-bottom:20px}.delivery-panel-header h5{margin:0;font-weight:850;letter-spacing:-.02em}.delivery-panel-header p{margin:.22rem 0 0;color:var(--muted)}.delivery-panel-icon{width:52px;height:52px;border-radius:18px;display:flex;align-items:center;justify-content:center;flex:0 0 52px;background:#eaf4ff;color:#0957b8;font-size:1.45rem}.delivery-panel-icon.green{background:#e9f8ef;color:#229b3c}.delivery-panel-icon.orange{background:#fff4e5;color:#b76b00}.selected-worker-card{display:flex;gap:16px;align-items:center;border:1px solid #e8eef7;background:linear-gradient(135deg,#fbfdff,#f6fbff);border-radius:24px;padding:18px}.selected-worker-avatar{width:58px;height:58px;border-radius:20px;display:flex;align-items:center;justify-content:center;flex:0 0 58px;background:linear-gradient(135deg,#0957b8,#28a745);color:#fff;font-size:1.55rem;font-weight:900;text-transform:uppercase;box-shadow:0 14px 30px rgba(9,87,184,.18)}.selected-worker-card strong{font-size:1.02rem}.selected-worker-card p{margin:.15rem 0 .55rem;color:var(--muted)}.worker-tags{display:flex;flex-wrap:wrap;gap:8px}.worker-tags span{display:inline-flex;align-items:center;gap:6px;padding:7px 10px;border-radius:999px;background:#fff;border:1px solid #e5eaf3;color:#465266;font-size:.82rem}.delivery-items{display:flex;flex-direction:column;gap:14px}.delivery-item{position:relative;display:flex;gap:14px;padding:16px;border:1px solid #e5eaf3;border-radius:24px;background:linear-gradient(180deg,#fff,#fbfcff);transition:.18s}.delivery-item:hover{border-color:#cfe0f7;box-shadow:0 16px 36px rgba(16,24,40,.08);transform:translateY(-1px)}.delivery-item-number{width:34px;height:34px;border-radius:13px;display:flex;align-items:center;justify-content:center;flex:0 0 34px;background:#eef6ff;color:#0957b8;font-weight:900}.delivery-item-body{flex:1;min-width:0}.epi-preview{display:flex;justify-content:space-between;align-items:center;gap:16px;border:1px dashed #d7e3f3;background:#f8fbff;border-radius:18px;padding:13px 14px}.epi-preview-main strong{display:block}.epi-preview-main span{display:block;color:var(--muted);font-size:.88rem;margin-top:2px}.epi-badges{display:flex;gap:7px;flex-wrap:wrap;justify-content:flex-end}.delivery-empty-help{display:flex;align-items:center;gap:10px;border-radius:18px;background:#f5f9ff;color:#556174;border:1px solid #e1ecfb;padding:13px 15px}.delivery-empty-help i{color:#0957b8}.term-box{border:1px solid #e7ebf2;background:linear-gradient(135deg,#fbfdff,#f8fbff);border-radius:22px;padding:18px}.term-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:12px}.term-grid div{display:flex;align-items:center;gap:9px;background:#fff;border:1px solid #e7ebf2;border-radius:16px;padding:12px;color:#344054}.term-grid i{color:#28a745;font-size:1.1rem}.delivery-side{z-index:2}.delivery-summary .card-header-modern h5 i{color:#0957b8}.summary-status{display:flex;justify-content:space-between;align-items:center;gap:12px;border-radius:20px;padding:15px;background:#f5f7fb;border:1px solid #e6ebf3}.summary-status strong{display:block;font-size:.98rem}.summary-status span{display:block;color:var(--muted);font-size:.84rem;margin-top:2px}.summary-status i{font-size:1.7rem;color:#667085}.summary-status.ok{background:#ecf9ee;border-color:#ccefd5}.summary-status.ok i{color:#28a745}.summary-status.warning{background:#fff7e6;border-color:#ffe1a8}.summary-status.warning i{color:#b76b00}.summary-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}.summary-grid div{border:1px solid #e7ebf2;border-radius:18px;background:#fff;padding:13px}.summary-grid span{display:block;color:var(--muted);font-size:.78rem}.summary-grid strong{display:block;font-size:1.45rem;font-weight:900;letter-spacing:-.04em}.summary-line{display:flex;justify-content:space-between;gap:12px;border-bottom:1px solid #edf1f7;padding:10px 0}.summary-line:last-child{border-bottom:0}.summary-line span{color:var(--muted)}.summary-line strong{text-align:right;max-width:64%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.signature-pad-large{height:230px;background:linear-gradient(180deg,#fff,#fbfdff)}.signature-status{display:flex;align-items:center;gap:8px;padding:10px 12px;border-radius:15px;background:#fff7e6;color:#9c6a00;border:1px solid #ffe1a8;font-weight:800}.signature-status.ok{background:#ecf9ee;color:#146b22;border-color:#ccefd5}.delivery-tips{border:1px solid #dbe7f8;border-radius:24px;padding:18px;background:linear-gradient(135deg,#eef6ff,#f5fbff);box-shadow:0 14px 32px rgba(9,87,184,.08)}.delivery-tips h6{font-weight:850;margin-bottom:10px}.delivery-tips ul{margin:0;padding-left:18px;color:#465266}.delivery-tips li{margin:6px 0}.delivery-form .form-select-lg,.delivery-form .form-control{min-height:48px}@media(max-width:1199px){.delivery-stepper{grid-template-columns:repeat(2,1fr)}.delivery-side{position:static!important}}@media(max-width:767px){.delivery-hero{align-items:flex-start;flex-direction:column;padding:23px}.delivery-hero h1{font-size:1.55rem}.delivery-hero-actions{justify-content:flex-start}.delivery-stepper{grid-template-columns:1fr}.delivery-panel{padding:17px;border-radius:22px}.delivery-panel-header{align-items:flex-start}.selected-worker-card,.delivery-item,.epi-preview{flex-direction:column;align-items:flex-start}.epi-badges{justify-content:flex-start}.term-grid{grid-template-columns:1fr}.summary-line strong{max-width:54%}}



/* V5 - EPI picker and map/audit improvements */
.epi-select-native{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  opacity:0!important;
  pointer-events:none!important;
  left:-9999px!important;
}
.epi-picker{position:relative}
.epi-picker-toggle{
  width:100%;
  border:1px solid #d9e5f5;
  background:#fff;
  min-height:58px;
  border-radius:18px;
  display:flex;
  align-items:center;
  gap:12px;
  padding:10px 14px;
  text-align:left;
  box-shadow:0 10px 28px rgba(16,24,40,.04);
  transition:.18s;
}
.epi-picker-toggle:hover,.epi-picker.open .epi-picker-toggle{
  border-color:#8bbcf2;
  box-shadow:0 0 0 .25rem rgba(9,87,184,.10), 0 14px 34px rgba(16,24,40,.07);
}
.epi-picker-icon{
  width:38px;
  height:38px;
  border-radius:14px;
  background:linear-gradient(135deg,#eaf4ff,#ebf8ef);
  color:#0965c4;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 38px;
}
.epi-picker-text{display:flex;flex-direction:column;min-width:0;flex:1}
.epi-picker-title{font-size:.98rem;color:#172033;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.epi-picker-subtitle{font-size:.78rem;color:#667085;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:2px}
.epi-picker-caret{color:#667085;transition:.18s}
.epi-picker.open .epi-picker-caret{transform:rotate(180deg)}
.epi-picker-dropdown{
  display:none;
  position:absolute;
  left:0;
  right:0;
  top:calc(100% + 10px);
  z-index:1080;
  background:#fff;
  border:1px solid #dbe7f6;
  border-radius:22px;
  box-shadow:0 24px 70px rgba(16,24,40,.20);
  overflow:hidden;
}
.epi-picker.open .epi-picker-dropdown{display:block}
.epi-picker-search-wrap{
  position:relative;
  padding:12px;
  border-bottom:1px solid #edf2f8;
  background:linear-gradient(180deg,#fff,#fbfdff);
}
.epi-picker-search-wrap i{
  position:absolute;
  left:28px;
  top:50%;
  transform:translateY(-50%);
  color:#7b8aa3;
}
.epi-picker-search{
  width:100%;
  border:1px solid #dce7f4;
  border-radius:15px;
  min-height:44px;
  padding:0 14px 0 42px;
  outline:none;
  background:#f8fbff;
}
.epi-picker-search:focus{
  border-color:#8bbcf2;
  box-shadow:0 0 0 .2rem rgba(9,87,184,.08);
  background:#fff;
}
.epi-picker-options{
  max-height:330px;
  overflow:auto;
  padding:8px;
}
.epi-picker-option{
  width:100%;
  display:flex;
  align-items:center;
  gap:12px;
  border:0;
  background:#fff;
  border-radius:16px;
  padding:11px;
  text-align:left;
  transition:.15s;
}
.epi-picker-option:hover{
  background:#f2f8ff;
  transform:translateY(-1px);
}
.epi-option-badge{
  width:38px;
  height:38px;
  border-radius:14px;
  background:#eef6ff;
  color:#0957b8;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 38px;
}
.epi-option-content{flex:1;min-width:0}
.epi-option-content strong{
  display:block;
  color:#172033;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.epi-option-content small{
  display:block;
  color:#667085;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  margin-top:2px;
}
.epi-option-stock{
  border-radius:999px;
  background:#ecf9ee;
  color:#157347;
  font-weight:800;
  font-size:.76rem;
  padding:7px 9px;
  white-space:nowrap;
}
.epi-option-stock.low{background:#fff5e6;color:#b76b00}
.epi-option-stock.danger{background:#ffeaea;color:#b42318}
.epi-picker.no-results .epi-picker-options::after{
  content:"Nenhum EPI encontrado para essa busca.";
  display:block;
  padding:18px;
  color:#667085;
  text-align:center;
}
.location-capture{
  display:flex;
  gap:13px;
  align-items:flex-start;
  padding:15px;
  border:1px solid #dce7f4;
  border-radius:18px;
  background:#f8fbff;
}
.location-capture-icon{
  width:42px;
  height:42px;
  border-radius:16px;
  background:#eef6ff;
  color:#0957b8;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 42px;
  font-size:1.18rem;
}
.location-capture strong{display:block}
.location-capture span{display:block;color:#667085;font-size:.86rem;margin-top:2px}
.location-capture.ok{background:#effaf2;border-color:#ccefd6}
.location-capture.ok .location-capture-icon{background:#dff7e6;color:#198754}
.location-capture.warning{background:#fff8ec;border-color:#ffe0ad}
.location-capture.warning .location-capture-icon{background:#fff0d5;color:#b76b00}
.location-capture.loading .location-capture-icon i{animation:locPulse 1.1s infinite ease-in-out}
@keyframes locPulse{0%,100%{transform:scale(1);opacity:.65}50%{transform:scale(1.16);opacity:1}}
.map-card{
  display:block;
  position:relative;
  border:1px solid #dce7f4;
  border-radius:20px;
  overflow:hidden;
  min-height:240px;
  background:#eef6ff;
  text-decoration:none;
  color:inherit;
  box-shadow:0 18px 45px rgba(16,24,40,.08);
}
.map-card iframe{
  width:100%;
  height:240px;
  border:0;
  display:block;
  pointer-events:none;
  filter:saturate(.95) contrast(.98);
}
.map-open-label{
  position:absolute;
  left:14px;
  bottom:14px;
  right:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:10px 12px;
  border-radius:14px;
  color:#fff;
  font-weight:800;
  background:linear-gradient(135deg,rgba(9,87,184,.95),rgba(40,167,69,.95));
  box-shadow:0 12px 30px rgba(0,0,0,.18);
}
.map-meta{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
  margin-top:12px;
}
.map-meta .meta-item{padding:12px}
@media(max-width:991px){
  .epi-picker-dropdown{position:fixed;left:16px;right:16px;top:90px;max-height:70vh}
  .epi-picker-options{max-height:55vh}
  .map-meta{grid-template-columns:1fr}
}


/* V6 - ficha de entrega compacta para PDF e tela */
.delivery-sheet{max-width:1100px;margin:0 auto 28px;}
.delivery-sheet .sheet-inner{padding:30px;}
.sheet-header{display:flex;justify-content:space-between;align-items:flex-start;gap:18px;margin-bottom:18px;}
.sheet-logo{max-width:210px;}
.sheet-title h2{font-size:1.35rem;font-weight:900;letter-spacing:-.03em;margin:0 0 4px;}
.sheet-status{padding:.55rem .85rem;border-radius:999px;}
.sheet-identity-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-bottom:18px;}
.compact-stat{min-height:72px;}
.delivery-section{margin-bottom:16px;}
.term-box{margin-bottom:16px;}
.signature-audit-grid{display:grid;grid-template-columns:1fr 1.18fr;gap:18px;align-items:stretch;}
.signature-frame{border:1px solid var(--line);border-radius:18px;background:#fff;min-height:150px;margin-top:14px;padding:12px;display:flex;align-items:center;justify-content:center;}
.signature-frame img{max-width:100%;max-height:122px;}
.compact-items-table{table-layout:fixed;width:100%;}
.compact-items-table th,.compact-items-table td{white-space:normal;vertical-align:middle;}
.compact-items-table .col-item{width:36%;}
.compact-items-table .col-qtd{width:8%;}
.compact-items-table .col-ca{width:11%;}
.compact-items-table .col-date{width:13%;}
.compact-items-table .col-dev{width:19%;}
.compact-items-table .item-main strong{display:block;line-height:1.22;}
.compact-items-table .item-main small{display:block;color:var(--muted);font-size:.78rem;margin-top:3px;line-height:1.2;}
.delivery-items-wrap{overflow-x:visible;}
.audit-grid-compact{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;}
.audit-grid-compact .meta-item{padding:11px 12px;}
.audit-grid-compact .meta-item strong{word-break:break-word;}
.map-card-compact{height:145px;margin-top:14px;}
.print-location-link{display:none;margin-top:10px;border:1px solid #dce8f7;background:#f8fbff;border-radius:12px;padding:9px 10px;text-decoration:none;color:#0957b8;font-weight:800;font-size:.86rem;}
.device-meta strong{font-size:.82rem;line-height:1.25;word-break:break-word;}

@page{size:A4 portrait;margin:8mm;}
@media print{
  html,body{background:#fff!important;color:#111!important;font-size:10px!important;width:210mm!important;}
  .page-container{padding:0!important;max-width:none!important;width:100%!important;}
  .content-wrap{margin:0!important;width:100%!important;}
  .delivery-sheet{max-width:none!important;margin:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;background:#fff!important;}
  .delivery-sheet .sheet-inner{padding:0!important;}
  .sheet-header{margin-bottom:7px!important;gap:8px!important;}
  .sheet-logo{max-width:118px!important;}
  .sheet-title h2{font-size:17px!important;line-height:1.1!important;margin-bottom:1px!important;}
  .sheet-title .text-muted{font-size:9px!important;}
  .sheet-status{font-size:8px!important;padding:3px 7px!important;}
  .sheet-identity-grid{grid-template-columns:1fr 1fr!important;gap:6px!important;margin-bottom:7px!important;}
  .compact-stat,.mini-stat{min-height:0!important;padding:7px 8px!important;border-radius:8px!important;gap:6px!important;}
  .compact-stat i,.mini-stat i{font-size:12px!important;}
  .compact-stat strong,.mini-stat strong{font-size:9.3px!important;line-height:1.15!important;}
  .compact-stat small,.mini-stat small{font-size:7.8px!important;line-height:1.15!important;}
  .card,.border-soft{box-shadow:none!important;border-radius:8px!important;background:#fff!important;}
  .delivery-section,.term-box{margin-bottom:7px!important;}
  .card-header-modern{padding:6px 8px!important;background:#fff!important;}
  .card-header-modern h5{font-size:11px!important;line-height:1.1!important;}
  .card-header-modern small{display:none!important;}
  .table-responsive,.delivery-items-wrap{overflow:visible!important;width:100%!important;}
  .compact-items-table{width:100%!important;table-layout:fixed!important;font-size:8.2px!important;}
  .compact-items-table th,.compact-items-table td{padding:3.5px 4px!important;white-space:normal!important;word-break:normal!important;overflow-wrap:anywhere!important;line-height:1.12!important;}
  .compact-items-table thead th{font-size:6.7px!important;letter-spacing:.02em!important;}
  .compact-items-table .col-item{width:34%!important;}
  .compact-items-table .col-qtd{width:6%!important;}
  .compact-items-table .col-ca{width:10%!important;}
  .compact-items-table .col-date{width:12%!important;}
  .compact-items-table .col-dev{width:14%!important;}
  .compact-items-table .item-main small{font-size:7px!important;line-height:1.1!important;margin-top:1px!important;}
  .badge{font-size:7px!important;padding:2px 4px!important;border-radius:6px!important;}
  .term-box .panel-body{padding:7px 8px!important;font-size:8.8px!important;line-height:1.22!important;}
  .term-box p{margin-top:3px!important;line-height:1.22!important;}
  .signature-audit-grid{display:grid!important;grid-template-columns:37% 63%!important;gap:7px!important;}
  .signature-card .panel-body,.audit-card-print .panel-body{padding:7px 8px!important;}
  .signature-card strong,.audit-card-print strong{font-size:9px!important;}
  .signature-frame{min-height:76px!important;max-height:82px!important;margin-top:5px!important;padding:5px!important;border-radius:8px!important;}
  .signature-frame img{max-height:66px!important;max-width:100%!important;}
  .audit-title{margin-bottom:0!important;}
  .audit-grid-compact{grid-template-columns:repeat(3,1fr)!important;gap:4px!important;margin-top:6px!important;}
  .audit-grid-compact .meta-item{padding:4px 5px!important;border-radius:7px!important;}
  .audit-grid-compact .meta-item span{font-size:6.6px!important;line-height:1!important;}
  .audit-grid-compact .meta-item strong{font-size:7.5px!important;line-height:1.05!important;margin-top:1px!important;}
  .map-card-compact,.map-card{display:none!important;}
  .print-location-link{display:block!important;font-size:7.6px!important;line-height:1.12!important;padding:5px 6px!important;margin-top:5px!important;border-radius:7px!important;}
  .device-meta{display:none!important;}
  .empty-note{font-size:7.6px!important;padding:5px 6px!important;margin-top:5px!important;border-radius:7px!important;}
  .no-break{break-inside:avoid!important;page-break-inside:avoid!important;}
  a[href]::after{content:""!important;}
}


/* V7 - seletores por modal para Nova Entrega */
.native-selector{
  position:absolute!important;
  left:-10000px!important;
  width:1px!important;
  height:1px!important;
  opacity:0!important;
  pointer-events:none!important;
}
.selector-grid .modal-select-card,
.delivery-item .modal-select-card{
  min-height:82px;
}
.modal-select-card{
  width:100%;
  border:1px solid #dbe7f6;
  background:linear-gradient(180deg,#ffffff,#f8fbff);
  border-radius:22px;
  padding:14px 16px;
  display:flex;
  align-items:center;
  gap:14px;
  text-align:left;
  color:var(--ink);
  box-shadow:0 10px 25px rgba(16,24,40,.05);
  transition:.18s ease;
}
.modal-select-card:hover{
  border-color:#8bbcf0;
  box-shadow:0 18px 38px rgba(9,87,184,.12);
  transform:translateY(-1px);
}
.modal-select-card.selected{
  border-color:#95c5f7;
  background:linear-gradient(180deg,#fafdff,#eef7ff);
}
.modal-select-icon{
  width:48px;
  height:48px;
  border-radius:17px;
  flex:0 0 48px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#eaf4ff;
  color:#0957b8;
  font-size:1.25rem;
}
.modal-select-icon.green{background:#e9f8ef;color:#1d9852}
.modal-select-icon.orange{background:#fff3e5;color:#b76b00}
.modal-select-content{
  min-width:0;
  flex:1 1 auto;
}
.modal-select-content strong{
  display:block;
  font-size:1rem;
  color:#111827;
  line-height:1.2;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.modal-select-content small{
  display:block;
  margin-top:4px;
  color:#667085;
  font-size:.82rem;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.modal-select-arrow{
  width:36px;
  height:36px;
  border-radius:50%;
  background:#fff;
  border:1px solid #e1e8f3;
  color:#0a5eb5;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 36px;
}
.selector-modal .modal-content{
  border:0;
  border-radius:30px;
  overflow:hidden;
  box-shadow:0 32px 90px rgba(15,23,42,.24);
}
.selector-modal-header{
  padding:24px 26px;
  background:radial-gradient(circle at top left,rgba(255,255,255,.18),transparent 34%),linear-gradient(135deg,#073b79,#0a83d9 54%,#28a745);
  color:#fff;
  border:0;
  align-items:flex-start;
}
.selector-modal-header .btn-close{
  filter:invert(1) grayscale(1) brightness(200%);
  opacity:.9;
}
.selector-modal-header h5{
  font-size:1.45rem;
  font-weight:900;
  letter-spacing:-.035em;
  margin:.35rem 0 .1rem;
}
.selector-modal-header p{
  margin:0;
  color:rgba(255,255,255,.84);
}
.selector-modal-body{
  padding:22px;
  background:#f6f8fb;
}
.modal-search-box{
  position:sticky;
  top:0;
  z-index:2;
  display:flex;
  align-items:center;
  gap:12px;
  padding:12px 14px;
  border-radius:20px;
  background:#fff;
  border:1px solid #dbe7f6;
  box-shadow:0 12px 28px rgba(15,23,42,.06);
}
.modal-search-box i{
  color:#0a5eb5;
  font-size:1.15rem;
}
.modal-search-box .form-control{
  border:0;
  box-shadow:none!important;
  padding:.4rem 0;
  background:transparent;
}
.selector-list{
  display:grid;
  gap:12px;
}
.selector-list-people{
  grid-template-columns:repeat(2,minmax(0,1fr));
}
.selector-option-card{
  width:100%;
  min-height:104px;
  border:1px solid #dbe7f6;
  border-radius:22px;
  background:#fff;
  padding:16px;
  display:flex;
  align-items:center;
  gap:14px;
  text-align:left;
  box-shadow:0 12px 24px rgba(15,23,42,.05);
  transition:.16s ease;
}
.selector-option-card:hover{
  border-color:#8fc2f4;
  box-shadow:0 18px 38px rgba(9,87,184,.12);
  transform:translateY(-1px);
}
.selector-option-card.compact{
  min-height:84px;
}
.selector-avatar{
  width:52px;
  height:52px;
  border-radius:18px;
  background:#eaf4ff;
  color:#0957b8;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 52px;
  font-weight:900;
  font-size:1.15rem;
}
.selector-avatar.green{background:#e9f8ef;color:#1d9852}
.selector-avatar.orange{background:#fff3e5;color:#b76b00}
.selector-option-main{
  min-width:0;
  flex:1 1 auto;
}
.selector-option-main strong{
  display:block;
  font-weight:900;
  color:#111827;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.selector-option-main small,
.selector-option-main em{
  display:block;
  color:#667085;
  font-size:.84rem;
  font-style:normal;
  margin-top:3px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.selector-option-action{
  width:38px;
  height:38px;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#eef6ff;
  color:#0957b8;
  flex:0 0 38px;
}
.motivo-list{
  grid-template-columns:repeat(2,minmax(0,1fr));
}
.epi-modal-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:14px;
}
.epi-modal-card{
  min-height:126px;
  border:1px solid #dbe7f6;
  background:#fff;
  border-radius:24px;
  padding:16px;
  display:flex;
  align-items:center;
  gap:14px;
  text-align:left;
  box-shadow:0 12px 24px rgba(15,23,42,.05);
  transition:.16s ease;
  position:relative;
}
.epi-modal-card:hover{
  border-color:#8fc2f4;
  box-shadow:0 18px 38px rgba(9,87,184,.12);
  transform:translateY(-1px);
}
.epi-modal-card-icon{
  width:54px;
  height:54px;
  border-radius:18px;
  background:#eaf4ff;
  color:#0957b8;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 54px;
  font-size:1.35rem;
}
.epi-modal-card-body{
  min-width:0;
  flex:1 1 auto;
  padding-right:88px;
}
.epi-modal-card-body strong{
  display:block;
  color:#111827;
  font-weight:900;
  line-height:1.2;
}
.epi-modal-card-body small,
.epi-modal-card-body em{
  display:block;
  font-size:.84rem;
  color:#667085;
  font-style:normal;
  margin-top:4px;
}
.epi-modal-stock{
  position:absolute;
  right:14px;
  top:16px;
  border-radius:999px;
  padding:7px 11px;
  font-size:.78rem;
  font-weight:900;
  background:#e9f8ef;
  color:#16803d;
}
.epi-modal-stock.low{
  background:#fff4d6;
  color:#9c6a00;
}
.epi-modal-stock.danger{
  background:#ffe7e7;
  color:#aa1f1f;
}
@media(max-width:991px){
  .selector-list-people,.motivo-list,.epi-modal-grid{
    grid-template-columns:1fr;
  }
  .modal-select-card{
    min-height:72px;
  }
  .selector-modal .modal-dialog{
    margin:10px;
  }
  .selector-modal-header{
    padding:20px;
  }
  .selector-modal-body{
    padding:16px;
  }
}
@media print{
  .selector-modal,.modal-backdrop{display:none!important}
}

/* V8 - Termo LGPD na entrega */
.lgpd-note{
  display:flex;
  gap:12px;
  align-items:flex-start;
  padding:14px 16px;
  border:1px solid #d9e8ff;
  border-radius:18px;
  background:linear-gradient(135deg,#f7fbff,#eef6ff);
  color:#31425f;
}
.lgpd-note-icon{
  width:38px;
  height:38px;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#e6f0ff;
  color:#0b63ce;
  flex:0 0 38px;
}
.lgpd-note strong{display:block;margin-bottom:3px;color:#12213a}
.lgpd-note p{margin:0;font-size:.9rem;line-height:1.45}
.term-box .form-check-label{line-height:1.45}
@media print{
  .lgpd-note{padding:8px 10px;border-radius:10px}
  .lgpd-note p{font-size:8.5pt;line-height:1.25}
}

/* V11B - Remover nome do topo das páginas */
.topbar-left{min-width:40px;}
.topbar{justify-content:space-between;}

/* V12 - Dashboard executivo aprimorado */
.dash-compact-hero{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:22px;
  margin-bottom:22px;
}
.dash-compact-hero h1{
  margin:.35rem 0 .25rem;
  font-size:1.86rem;
  font-weight:900;
  letter-spacing:-.045em;
  color:var(--ink);
}
.dash-compact-hero p{
  margin:0;
  color:var(--muted);
  max-width:820px;
}
.dash-eyebrow{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:7px 11px;
  border-radius:999px;
  background:#eef6ff;
  color:#0957b8;
  border:1px solid #d8e9ff;
  font-size:.73rem;
  text-transform:uppercase;
  letter-spacing:.12em;
  font-weight:800;
}
.dash-hero-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end}
.dashboard-grid{
  display:grid;
  grid-template-columns:1.45fr repeat(3, minmax(0,1fr));
  gap:16px;
}
.dashboard-primary-card,
.dash-kpi-card,
.dash-panel{
  border:1px solid rgba(231,235,242,.9);
  background:rgba(255,255,255,.96);
  box-shadow:0 18px 45px rgba(16,24,40,.075);
  border-radius:26px;
}
.dashboard-primary-card{
  padding:22px;
  overflow:hidden;
  position:relative;
}
.dashboard-primary-card:after{
  content:"";
  position:absolute;
  right:-50px;
  top:-60px;
  width:160px;
  height:160px;
  border-radius:50%;
  background:linear-gradient(135deg,rgba(9,87,184,.10),rgba(40,167,69,.14));
}
.dash-status-row{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;position:relative;z-index:1}
.dash-card-label,.dash-kpi-card span{
  display:block;
  color:var(--muted);
  font-size:.84rem;
  font-weight:700;
}
.dash-status-row h2{
  margin:2px 0 4px;
  font-size:2rem;
  font-weight:900;
  letter-spacing:-.05em;
}
.dash-status-row p{margin:0;color:var(--muted);font-size:.9rem}
.dash-status-badge{
  width:58px;
  height:58px;
  border-radius:20px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:1.65rem;
}
.dash-status-badge.success{background:#e9f8ef;color:#1d9852}
.dash-status-badge.warning{background:#fff5e6;color:#b76b00}
.dash-status-badge.danger{background:#ffeaea;color:#b42318}
.dash-health-bars{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
  margin-top:18px;
  position:relative;
  z-index:1;
}
.dash-health-bars div{
  padding:12px;
  border-radius:18px;
  background:#f8fafc;
  border:1px solid var(--line);
}
.dash-health-bars span{display:block;color:var(--muted);font-size:.77rem}
.dash-health-bars strong{display:block;font-size:1.25rem;font-weight:900}
.dash-kpi-card{
  padding:18px;
  min-height:158px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
}
.dash-kpi-card strong{
  font-size:2.05rem;
  font-weight:900;
  letter-spacing:-.05em;
}
.dash-kpi-card small{color:var(--muted)}
.dash-kpi-icon{
  width:48px;height:48px;border-radius:16px;display:flex;align-items:center;justify-content:center;font-size:1.45rem;
}
.dash-kpi-icon.blue{background:#eaf4ff;color:#0957b8}
.dash-kpi-icon.green{background:#e9f8ef;color:#229b3c}
.dash-kpi-icon.purple{background:#f1ecff;color:#6941c6}
.dash-panel{overflow:hidden}
.dash-panel-header{
  min-height:78px;
  padding:18px 20px;
  border-bottom:1px solid var(--line);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  background:linear-gradient(180deg,#fff,#fbfcff);
}
.dash-panel-header.compact{min-height:70px}
.dash-panel-header h5{
  margin:0;
  font-weight:850;
  letter-spacing:-.02em;
}
.dash-panel-header small{color:var(--muted)}
.dash-chip{
  display:inline-flex;
  align-items:center;
  gap:7px;
  padding:7px 10px;
  border-radius:999px;
  background:#eef6ff;
  color:#0957b8;
  font-size:.78rem;
  font-weight:800;
}
.dash-chip.success{background:#e9f8ef;color:#1d9852}
.dash-counter{
  min-width:34px;
  height:34px;
  border-radius:12px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-weight:900;
  background:#eef6ff;
  color:#0957b8;
}
.dash-counter.success{background:#e9f8ef;color:#1d9852}
.dash-counter.warning{background:#fff5e6;color:#b76b00}
.dash-counter.danger{background:#ffeaea;color:#b42318}
.dash-action-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}
.dash-action{
  min-height:86px;
  border-radius:20px;
  padding:15px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  text-decoration:none;
  background:#f8fafc;
  border:1px solid var(--line);
  transition:.18s;
}
.dash-action:hover{transform:translateY(-2px);box-shadow:0 14px 30px rgba(16,24,40,.08)}
.dash-action i{font-size:1.35rem;color:#0957b8}
.dash-action.success i{color:#1d9852}
.dash-action.primary i{color:#0957b8}
.dash-action span{font-weight:800}
.dash-list{display:flex;flex-direction:column;gap:10px}
.dash-list-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px;
  border:1px solid var(--line);
  border-radius:18px;
  background:#fff;
}
.dash-list-row.link{text-decoration:none}
.dash-list-row strong{display:block;font-size:.92rem}
.dash-list-row small{display:block;color:var(--muted);font-size:.78rem;margin-top:2px}
.dash-empty{
  min-height:120px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  color:var(--muted);
  gap:8px;
  text-align:center;
}
.dash-empty i{font-size:2rem;color:#b9c7dc}
@media(max-width:1399px){.dashboard-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard-primary-card{grid-column:span 2}}
@media(max-width:991px){
  .dash-compact-hero{flex-direction:column;align-items:flex-start}
  .dash-hero-actions{justify-content:flex-start}
  .dashboard-grid{grid-template-columns:1fr}
  .dashboard-primary-card{grid-column:auto}
  .dash-health-bars,.dash-action-grid{grid-template-columns:1fr}
}
@media print{.dash-compact-hero .dash-hero-actions{display:none!important}}


/* V13 - Remove a barra azul/verde grande dos cabeçalhos das páginas
   Mantém títulos, subtítulos, indicadores e botões em layout compacto. */
.module-hero,
.report-hero,
.delivery-hero{
  background: transparent !important;
  color: var(--ink) !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  padding: 0 0 16px 0 !important;
  margin: 0 0 18px 0 !important;
  overflow: visible !important;
  min-height: auto !important;
}
.module-hero::after,
.report-hero::after,
.delivery-hero::after{
  display: none !important;
  content: none !important;
}
.module-hero > div,
.report-hero > div,
.delivery-hero > div{
  position: relative !important;
  z-index: auto !important;
}
.module-hero h1,
.report-hero h1,
.delivery-hero h1{
  color: var(--ink) !important;
  font-size: 1.72rem !important;
  line-height: 1.14 !important;
  font-weight: 900 !important;
  letter-spacing: -.04em !important;
  margin: .35rem 0 .25rem !important;
}
.module-hero p,
.report-hero p,
.delivery-hero p{
  color: var(--muted) !important;
  max-width: 880px !important;
  margin: 0 !important;
}
.module-hero .eyebrow,
.report-hero .eyebrow,
.delivery-hero .eyebrow,
.eyebrow{
  background: #eef6ff !important;
  color: #0957b8 !important;
  border: 1px solid #d8e9ff !important;
  box-shadow: none !important;
  padding: 7px 11px !important;
}
.quick-stats,
.module-hero .quick-stats,
.report-hero .quick-stats,
.delivery-hero .quick-stats,
.delivery-hero-meta{
  margin-top: 10px !important;
}
.delivery-hero-meta span,
.report-period{
  background: #fff !important;
  color: var(--ink) !important;
  border: 1px solid var(--line) !important;
  box-shadow: 0 8px 22px rgba(15,23,42,.04) !important;
}
.hero-actions,
.report-actions,
.delivery-hero-actions{
  align-self: center !important;
  position: relative !important;
  z-index: auto !important;
}
.module-hero .btn-light,
.report-hero .btn-light,
.delivery-hero .btn-light{
  background: linear-gradient(135deg,var(--blue),var(--blue-2)) !important;
  border: 0 !important;
  color: #fff !important;
}
.module-hero .btn-light:hover,
.report-hero .btn-light:hover,
.delivery-hero .btn-light:hover{
  color: #fff !important;
  filter: brightness(.96);
}
.module-hero .btn-outline-light,
.report-hero .btn-outline-light,
.delivery-hero .btn-outline-light{
  background: #fff !important;
  color: var(--ink) !important;
  border: 1px solid #d6dce7 !important;
}
.module-hero .btn-outline-light:hover,
.report-hero .btn-outline-light:hover,
.delivery-hero .btn-outline-light:hover{
  background: #f8fafc !important;
  color: var(--ink) !important;
}
.report-filter-card{
  border: 1px solid var(--line) !important;
}
@media(max-width:991px){
  .module-hero,
  .report-hero,
  .delivery-hero{
    flex-direction: column !important;
    align-items: flex-start !important;
    padding: 0 0 14px 0 !important;
    margin-bottom: 16px !important;
  }
  .module-hero h1,
  .report-hero h1,
  .delivery-hero h1{
    font-size: 1.42rem !important;
  }
  .hero-actions,
  .report-actions,
  .delivery-hero-actions{
    justify-content: flex-start !important;
  }
}
@media print{
  .module-hero,
  .report-hero,
  .delivery-hero{
    display: none !important;
  }
}


/* V14 - Reconhecimento facial na entrega */
.facial-status{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px 14px;
  border-radius:16px;
  border:1px solid #ffe0b3;
  background:#fff8eb;
  color:#9a5b00;
  font-weight:800;
}
.facial-status.success{
  border-color:#c8f0d2;
  background:#ecf9ef;
  color:#1d7f43;
}
.facial-capture-box{
  position:relative;
  height:260px;
  border:1px dashed #bdd1ef;
  border-radius:22px;
  overflow:hidden;
  background:linear-gradient(180deg,#f8fbff,#eef6ff);
  display:flex;
  align-items:center;
  justify-content:center;
}
.face-video,
.face-preview{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.face-placeholder{
  text-align:center;
  color:#58708c;
  padding:22px;
  max-width:320px;
}
.face-placeholder i{
  font-size:2.4rem;
  color:#0957b8;
  display:block;
  margin-bottom:8px;
}
.face-placeholder strong{
  display:block;
  color:var(--ink);
  margin-bottom:4px;
}
.face-placeholder span{
  display:block;
  font-size:.9rem;
}
.lgpd-note.compact{
  padding:12px;
}
.lgpd-note.compact p{
  font-size:.84rem;
}
.facial-card-print .panel-body{
  height:100%;
}
.facial-frame{
  min-height:180px;
  border:1px solid var(--line);
  border-radius:18px;
  background:#f8fafc;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  margin-top:12px;
}
.facial-frame img{
  width:100%;
  height:180px;
  object-fit:cover;
}
.facial-proof{
  display:flex;
  align-items:center;
  gap:8px;
  color:#475467;
  font-size:.86rem;
}
.facial-proof i{
  color:#1d9852;
}
@media print{
  .facial-card-print{
    text-align:left;
  }
  .facial-frame{
    width:86px;
    height:153px;
    min-height:153px;
    max-width:86px;
    margin:10px auto 0 auto;
    border-radius:12px;
    background:#f8fafc;
    border:1px solid #d7e2f0;
    box-shadow:none;
  }
  .facial-frame img{
    width:86px;
    height:153px;
    min-width:86px;
    max-width:86px;
    object-fit:cover;
    object-position:center top;
    border-radius:12px;
    display:block;
  }
  .facial-proof{
    font-size:8pt;
    margin-top:6px;
  }
}
@media(max-width:991px){
  .facial-capture-box{
    height:220px;
  }
}


/* V15 - Cadastro da face do colaborador */
.colab-face-panel{
  padding:16px;
  border:1px solid #d9e8ff;
  border-radius:20px;
  background:linear-gradient(180deg,#fbfdff,#f4f9ff);
}
.colab-face-header{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:12px;
  margin-bottom:12px;
}
.colab-face-header small{
  display:block;
  color:var(--muted);
  font-size:.82rem;
  margin-top:2px;
}
.colab-face-capture{
  position:relative;
  height:220px;
  border:1px dashed #bdd1ef;
  border-radius:20px;
  overflow:hidden;
  background:linear-gradient(180deg,#f8fbff,#eef6ff);
  display:flex;
  align-items:center;
  justify-content:center;
}
.colab-face-video,
.colab-face-preview{
  width:100%;
  height:100%;
  object-fit:cover;
}
.colab-face-placeholder{
  text-align:center;
  padding:20px;
  color:#58708c;
}
.colab-face-placeholder i{
  display:block;
  font-size:2.1rem;
  color:#0957b8;
  margin-bottom:8px;
}
.colab-face-placeholder strong{
  display:block;
  color:var(--ink);
}
.colab-face-placeholder span{
  display:block;
  font-size:.86rem;
}
.avatar-face,
.selector-face{
  width:42px;
  height:42px;
  border-radius:16px;
  object-fit:cover;
  border:2px solid #d9e8ff;
  box-shadow:0 8px 18px rgba(16,24,40,.08);
}
.selector-face{
  width:54px;
  height:54px;
  flex:0 0 54px;
}
.selected-worker-face{
  width:72px;
  height:72px;
  border-radius:22px;
  object-fit:cover;
  border:2px solid #d9e8ff;
  box-shadow:0 12px 28px rgba(16,24,40,.10);
}
.registered-face-card{
  display:flex;
  align-items:center;
  gap:12px;
  padding:12px;
  border:1px solid #d9e8ff;
  border-radius:18px;
  background:#f8fbff;
  margin-bottom:12px;
}
.registered-face-card img{
  width:64px;
  height:64px;
  border-radius:18px;
  object-fit:cover;
  border:2px solid #fff;
  box-shadow:0 8px 22px rgba(16,24,40,.08);
}
.registered-face-card strong{
  display:block;
  color:var(--ink);
}
.registered-face-card span{
  display:block;
  color:var(--muted);
  font-size:.84rem;
}
.profile-face-large{
  width:88px;
  height:88px;
  border-radius:28px;
  object-fit:cover;
  border:3px solid #e4efff;
  box-shadow:0 14px 34px rgba(16,24,40,.10);
}
.profile-face-placeholder{
  width:88px;
  height:88px;
  border-radius:28px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,#eef6ff,#e8f8ee);
  color:#0957b8;
  font-size:2rem;
  font-weight:900;
}
@media(max-width:991px){
  .colab-face-capture{height:200px}
  .selected-worker-face{width:58px;height:58px;border-radius:18px}
}
@media print{
  .colab-face-panel,
  .registered-face-card{display:none!important}
}


/* V16 - Validação biométrica automática com face-api.js */
.faceapi-status{
  display:flex;
  align-items:center;
  gap:10px;
  padding:10px 12px;
  border-radius:15px;
  border:1px solid #d9e8ff;
  background:#f7fbff;
  color:#33536f;
  font-weight:800;
  font-size:.86rem;
}
.faceapi-status.loading{
  border-color:#d9e8ff;
  background:#f7fbff;
  color:#0957b8;
}
.faceapi-status.success{
  border-color:#c8f0d2;
  background:#ecf9ef;
  color:#1d7f43;
}
.faceapi-status.error,
.faceapi-status.danger{
  border-color:#ffd0d0;
  background:#fff0f0;
  color:#b42318;
}
.facial-status.danger{
  border-color:#ffd0d0;
  background:#fff0f0;
  color:#b42318;
}
.facial-status.warning{
  border-color:#ffe0b3;
  background:#fff8eb;
  color:#9a5b00;
}
.facial-proof.success{
  color:#1d7f43;
  font-weight:800;
}
.facial-proof.success i{
  color:#1d7f43;
}
.facial-proof.danger{
  color:#b42318;
  font-weight:800;
}
.facial-proof.danger i{
  color:#b42318;
}
.badge i{
  margin-right:4px;
}


/* V17 - Modal facial estilo banco */
.bank-face-modal .modal-dialog{
  max-width:760px;
}
.bank-face-content{
  border:0;
  border-radius:28px;
  overflow:hidden;
  box-shadow:0 30px 80px rgba(16,24,40,.28);
}
.bank-face-header{
  padding:22px 24px;
  border-bottom:1px solid var(--line);
  background:linear-gradient(180deg,#ffffff,#f8fbff);
}
.bank-face-header h5{
  font-weight:900;
  letter-spacing:-.03em;
  margin:.35rem 0 .15rem;
}
.bank-face-header p{
  margin:0;
  color:var(--muted);
}
.bank-face-body{
  padding:22px;
  background:#0b1220;
}
.bank-face-viewport{
  position:relative;
  height:520px;
  border-radius:28px;
  overflow:hidden;
  background:#050816;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.1);
}
.bank-face-video{
  width:100%;
  height:100%;
  object-fit:cover;
  transform:scaleX(-1);
}
.bank-face-overlay{
  position:absolute;
  inset:0;
  background:radial-gradient(ellipse 34% 43% at 50% 48%, transparent 0%, transparent 51%, rgba(3,8,20,.42) 53%, rgba(3,8,20,.82) 100%);
  pointer-events:none;
}
.bank-face-oval{
  position:absolute;
  left:50%;
  top:48%;
  width:285px;
  height:365px;
  transform:translate(-50%,-50%);
  border:4px solid rgba(40,167,69,.95);
  border-radius:50%;
  box-shadow:0 0 0 999px rgba(0,0,0,.04),0 0 28px rgba(40,167,69,.45);
}
.bank-face-oval::before,
.bank-face-oval::after{
  content:"";
  position:absolute;
  left:50%;
  transform:translateX(-50%);
  width:90px;
  height:5px;
  border-radius:999px;
  background:#28a745;
}
.bank-face-oval::before{top:-18px}
.bank-face-oval::after{bottom:-18px}
.bank-face-top-hint,
.bank-face-bottom-hint{
  position:absolute;
  left:50%;
  transform:translateX(-50%);
  color:#fff;
  text-align:center;
  font-weight:800;
  text-shadow:0 3px 14px rgba(0,0,0,.55);
}
.bank-face-top-hint{
  top:28px;
  font-size:1rem;
}
.bank-face-bottom-hint{
  bottom:26px;
  font-size:.9rem;
  background:rgba(5,12,25,.58);
  border:1px solid rgba(255,255,255,.16);
  backdrop-filter:blur(8px);
  padding:9px 13px;
  border-radius:999px;
}
.bank-face-instructions{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
  margin-top:16px;
}
.bank-face-instructions div{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:46px;
  border-radius:16px;
  background:rgba(255,255,255,.08);
  color:#eaf2ff;
  border:1px solid rgba(255,255,255,.12);
  font-weight:700;
  font-size:.86rem;
}
.bank-face-instructions i{
  color:#62c933;
  font-size:1.05rem;
}
.bank-face-footer{
  padding:16px 22px 22px;
  border-top:1px solid var(--line);
  background:#fff;
}
.face-preview,
.colab-face-preview{
  object-fit:cover;
}
@media(max-width:767px){
  .bank-face-modal .modal-dialog{
    margin:0;
    max-width:100%;
    height:100%;
  }
  .bank-face-content{
    min-height:100vh;
    border-radius:0;
  }
  .bank-face-body{
    padding:14px;
  }
  .bank-face-viewport{
    height:66vh;
    border-radius:22px;
  }
  .bank-face-oval{
    width:235px;
    height:315px;
  }
  .bank-face-instructions{
    grid-template-columns:1fr;
  }
}


/* V18 - Face ID identifica colaborador automaticamente na Nova Entrega */
#modalDeliveryFaceCamera .bank-face-header .modal-title{
  color:var(--ink);
}
#modalDeliveryFaceCamera .bank-face-footer .btn-success{
  min-width:190px;
}
#faceApiStatusEntrega strong{
  color:inherit;
}
.selected-worker-card.face-id-selected{
  border-color:#c8f0d2;
  background:linear-gradient(180deg,#ffffff,#f3fff7);
}
.bank-face-top-hint{
  letter-spacing:.02em;
}
.bank-face-bottom-hint{
  max-width:90%;
}


/* V19 - Face ID limpo, instruções dinâmicas e login mobile compacto */
.bank-face-minimal .bank-face-header.minimal{
  padding:18px 22px;
  align-items:center;
}
.bank-face-minimal .bank-face-header.minimal .modal-title{
  font-size:1.45rem;
  font-weight:950;
  letter-spacing:-.04em;
  margin:0;
}
.bank-face-minimal .bank-face-body{
  padding:18px;
}
.bank-face-minimal .bank-face-footer{
  display:flex;
  justify-content:space-between;
  gap:12px;
}
.bank-face-minimal .bank-face-footer .btn{
  min-height:46px;
  border-radius:14px;
  font-weight:800;
}
.bank-face-minimal .bank-face-footer .btn-success:disabled{
  opacity:.55;
  filter:grayscale(.25);
}
.bank-face-oval.ok{
  border-color:#28a745;
  box-shadow:0 0 0 999px rgba(0,0,0,.04),0 0 34px rgba(40,167,69,.62);
}
.bank-face-oval.warn{
  border-color:#f59e0b;
  box-shadow:0 0 0 999px rgba(0,0,0,.04),0 0 30px rgba(245,158,11,.52);
}
.bank-face-oval.error{
  border-color:#ef4444;
  box-shadow:0 0 0 999px rgba(0,0,0,.04),0 0 30px rgba(239,68,68,.52);
}
.bank-face-oval.ok::before,
.bank-face-oval.ok::after{background:#28a745}
.bank-face-oval.warn::before,
.bank-face-oval.warn::after{background:#f59e0b}
.bank-face-oval.error::before,
.bank-face-oval.error::after{background:#ef4444}
.bank-face-minimal .bank-face-bottom-hint{
  bottom:24px;
  font-size:.98rem;
  padding:10px 15px;
  min-width:260px;
  background:rgba(6,12,24,.68);
}

/* Ajustes gerais para não quebrar em telas pequenas */
@media(max-width:767px){
  body{
    min-width:0;
  }
  .topbar{
    height:62px;
    padding:0 10px!important;
  }
  .topbar-actions{
    gap:6px;
  }
  .topbar-actions .topbar-chip,
  .topbar-actions .user-pill{
    display:none!important;
  }
  .topbar-actions .btn{
    padding:.42rem .55rem;
    font-size:.78rem;
  }
  .page-container{
    padding:12px!important;
  }
  .card,
  .panel-card,
  .delivery-panel,
  .delivery-summary{
    border-radius:18px!important;
  }
  .delivery-stepper{
    overflow-x:auto;
    gap:8px;
    padding-bottom:3px;
  }
  .delivery-stepper .step{
    min-width:120px;
    flex:0 0 120px;
  }
  .hero-kpis,
  .dashboard-grid,
  .audit-grid{
    grid-template-columns:1fr!important;
  }
  .table-responsive{
    max-width:100%;
    overflow-x:auto;
  }
  .selector-modal .modal-dialog,
  .modal-dialog{
    margin:8px;
  }

  /* Login mobile simples em uma tela */
  .login-main{
    height:100dvh;
    min-height:100dvh;
    overflow:hidden;
    padding:0!important;
    align-items:stretch;
    background:linear-gradient(180deg,#f7fbff,#eef6ff)!important;
  }
  .login-card{
    width:100%!important;
    height:100dvh;
    min-height:100dvh;
    display:block!important;
    border-radius:0!important;
    box-shadow:none!important;
    background:#fff!important;
    overflow:hidden!important;
  }
  .login-hero{
    display:none!important;
  }
  .login-form{
    height:100dvh;
    padding:22px!important;
    display:flex;
    flex-direction:column;
    justify-content:center;
  }
  .login-form h2{
    font-size:1.45rem;
    line-height:1.1;
  }
  .login-form p.text-muted{
    margin-bottom:16px!important;
    font-size:.92rem;
  }
  .login-form .form-label{
    margin-bottom:5px;
    font-size:.9rem;
  }
  .login-form .form-control-lg{
    min-height:46px;
    font-size:.95rem;
    padding:.65rem .85rem;
  }
  .login-form .mb-3{
    margin-bottom:12px!important;
  }
  .login-form .mb-4{
    margin-bottom:16px!important;
  }
  .login-form .btn-lg{
    min-height:46px;
    font-size:.95rem;
    padding:.65rem .9rem;
  }
  .login-form .mt-4.p-3{
    display:none!important;
  }

  /* Face ID mobile */
  .bank-face-modal .modal-dialog{
    margin:0;
    max-width:100%;
    height:100%;
  }
  .bank-face-minimal .bank-face-content{
    min-height:100dvh;
    border-radius:0;
  }
  .bank-face-minimal .bank-face-header.minimal{
    padding:14px 16px;
  }
  .bank-face-minimal .bank-face-header.minimal .modal-title{
    font-size:1.25rem;
  }
  .bank-face-minimal .bank-face-body{
    padding:10px;
    display:flex;
    align-items:center;
    justify-content:center;
  }
  .bank-face-minimal .bank-face-viewport{
    height:calc(100dvh - 156px);
    width:100%;
    border-radius:22px;
  }
  .bank-face-minimal .bank-face-oval{
    width:225px;
    height:300px;
  }
  .bank-face-minimal .bank-face-bottom-hint{
    bottom:18px;
    min-width:0;
    width:calc(100% - 32px);
    max-width:360px;
    font-size:.9rem;
    padding:9px 12px;
  }
  .bank-face-minimal .bank-face-footer{
    padding:12px 14px 16px;
  }
  .bank-face-minimal .bank-face-footer .btn{
    flex:1;
    min-height:44px;
    font-size:.9rem;
  }
}


/* V20 - Login mobile com logo e botão de girar câmera no Face ID */
.mobile-login-brand{
  display:none;
}

@media(min-width:768px){
  .mobile-login-brand{
    display:none!important;
  }
}

@media(max-width:767px){
  .mobile-login-brand{
    display:flex!important;
    flex-direction:column;
    align-items:center;
    text-align:center;
    margin-bottom:22px;
  }
  .mobile-login-brand img{
    width:132px;
    max-width:58vw;
    border-radius:22px;
    background:#fff;
    box-shadow:0 16px 34px rgba(9,87,184,.16);
    margin-bottom:12px;
  }
  .mobile-login-brand h1{
    font-size:1.45rem;
    line-height:1.1;
    font-weight:900;
    letter-spacing:-.04em;
    margin:0 0 4px;
    color:var(--ink);
  }
  .mobile-login-brand p{
    margin:0;
    color:var(--muted);
    font-size:.9rem;
  }
  .login-form{
    justify-content:center;
    padding:18px 22px!important;
  }
  .login-form h2{
    text-align:center;
  }
  .login-form > p.text-muted{
    text-align:center;
  }

  .bank-face-minimal .bank-face-footer{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:10px;
  }
  .bank-face-minimal .bank-face-footer #captureFaceButtonModal{
    grid-column:1 / -1;
    order:3;
  }
  .bank-face-minimal .bank-face-footer #flipFaceCameraButton{
    order:2;
  }
  .bank-face-minimal .bank-face-footer [data-bs-dismiss="modal"]{
    order:1;
  }
}

#flipFaceCameraButton{
  font-weight:800;
}


/* V21 - Preview facial retangular, botão EPI menor e Face ID com loading */
.facial-capture-box{
  height:260px;
  border-radius:22px;
  background:#f7fbff;
  overflow:hidden;
}
.facial-capture-box .face-preview{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:center center!important;
  display:block!important;
  border-radius:20px;
}
.face-video,
.bank-face-video{
  object-fit:cover!important;
}
.btn-remove-epi{
  min-width:104px;
  height:48px;
  padding:.55rem .85rem;
  border-radius:16px;
  display:inline-flex!important;
  align-items:center;
  justify-content:center;
  gap:7px;
  font-weight:800;
}
.btn-remove-epi span{
  font-size:.86rem;
}
.item-row .col-lg-2:has(.btn-remove-epi){
  display:flex;
  align-items:end;
}
.item-row .btn-remove-epi{
  width:auto!important;
  margin-left:auto;
}
.bank-face-footer .spinner-border{
  width:1rem;
  height:1rem;
}
.faceapi-status.success strong{
  color:#146b22;
}
@media(max-width:767px){
  .facial-capture-box{
    height:210px;
  }
  .btn-remove-epi{
    width:48px!important;
    min-width:48px;
    height:48px;
    padding:0;
    border-radius:15px;
  }
  .btn-remove-epi span{
    display:none;
  }
}


/* V22 - Botão de girar câmera dentro do modal Face ID */
.bank-face-flip-btn{
  position:absolute;
  top:14px;
  left:14px;
  z-index:5;
  min-height:38px;
  padding:8px 12px;
  border:1px solid rgba(255,255,255,.24);
  border-radius:999px;
  background:rgba(6,12,24,.68);
  color:#fff;
  display:inline-flex;
  align-items:center;
  gap:7px;
  font-weight:850;
  font-size:.86rem;
  backdrop-filter:blur(10px);
  box-shadow:0 10px 28px rgba(0,0,0,.24);
}
.bank-face-flip-btn:hover{
  background:rgba(6,12,24,.82);
  color:#fff;
}
.bank-face-flip-btn i{
  font-size:1rem;
}
.bank-face-minimal .bank-face-footer{
  display:flex;
  justify-content:space-between;
  gap:12px;
}
.bank-face-minimal .bank-face-footer #captureFaceButtonModal{
  margin-left:auto;
}
@media(max-width:767px){
  .bank-face-flip-btn{
    top:12px;
    left:12px;
    min-height:36px;
    padding:7px 11px;
    font-size:.82rem;
  }
  .bank-face-minimal .bank-face-footer{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:10px;
  }
  .bank-face-minimal .bank-face-footer #captureFaceButtonModal{
    grid-column:2;
    order:2;
    margin-left:0;
  }
  .bank-face-minimal .bank-face-footer [data-bs-dismiss="modal"]{
    grid-column:1;
    order:1;
  }
}


/* V23 - Face ID obrigatório antes da Nova Entrega e câmera 9:16 */
.face-id-gate{
  position:fixed;
  inset:0;
  z-index:2040;
  background:linear-gradient(180deg,#f7fbff,#eef6ff);
  display:flex;
  align-items:center;
  justify-content:center;
}
.face-id-gate-card{
  width:min(320px,88vw);
  padding:28px;
  border-radius:28px;
  background:#fff;
  border:1px solid #d9e8ff;
  box-shadow:0 28px 70px rgba(16,24,40,.16);
  text-align:center;
}
.face-id-gate-logo{
  width:72px;
  height:72px;
  border-radius:24px;
  margin:0 auto 14px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#0957b8;
  background:#eef6ff;
  font-size:2rem;
}
.face-id-gate-card strong{
  display:block;
  font-size:1.35rem;
  font-weight:950;
  color:var(--ink);
  letter-spacing:-.04em;
}
.face-id-gate-card span{
  display:block;
  color:var(--muted);
  margin-top:4px;
}
body.face-gate-active{
  overflow:hidden;
}
body.face-gate-active .topbar,
body.face-gate-active .sidebar,
body.face-gate-active .delivery-hero,
body.face-gate-active .delivery-stepper,
body.face-gate-active .delivery-form{
  opacity:0;
  pointer-events:none;
}
.face-gate-modal{
  z-index:2060;
}
.face-gate-modal + .modal-backdrop,
.modal-backdrop.show{
  opacity:.92;
}
.face-gate-modal .modal-dialog{
  max-width:none;
  width:100vw;
  height:100dvh;
  margin:0;
  display:flex;
  align-items:center;
  justify-content:center;
}
.face-gate-modal .bank-face-content{
  width:min(440px,100vw);
  height:100dvh;
  max-height:100dvh;
  border-radius:0;
  display:flex;
  flex-direction:column;
}
.face-gate-modal .bank-face-header.minimal{
  min-height:56px;
  padding:12px 16px;
  flex:0 0 auto;
}
.face-gate-modal .bank-face-body{
  flex:1 1 auto;
  padding:0;
  background:#050816;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}
.face-gate-modal .bank-face-viewport{
  width:100%;
  height:100%;
  max-width:440px;
  aspect-ratio:9/16;
  border-radius:0;
  box-shadow:none;
}
.face-gate-modal .bank-face-video{
  width:100%;
  height:100%;
  object-fit:cover!important;
}
.face-gate-modal .bank-face-overlay{
  background:radial-gradient(ellipse 38% 29% at 50% 43%, transparent 0%, transparent 52%, rgba(3,8,20,.45) 54%, rgba(3,8,20,.84) 100%);
}
.face-gate-modal .bank-face-oval{
  width:255px;
  height:340px;
  top:43%;
}
.face-gate-modal .bank-face-footer{
  flex:0 0 auto;
  padding:12px 14px 16px;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  background:#fff;
}
.face-gate-modal .bank-face-footer #captureFaceButtonModal{
  grid-column:1 / -1;
  order:3;
  min-height:46px;
}
.face-gate-modal .bank-face-footer [data-bs-dismiss="modal"]{
  order:1;
}
.face-gate-modal .bank-face-bottom-hint{
  bottom:82px;
  width:calc(100% - 34px);
  max-width:360px;
}
.face-gate-modal .bank-face-flip-btn{
  top:70px;
  left:14px;
}
.face-gate-modal .btn-close{
  display:none;
}
.facial-capture-box{
  aspect-ratio:9/16;
  width:min(240px,100%);
  height:auto!important;
  margin:0 auto;
  border-radius:24px;
}
.facial-capture-box .face-preview{
  aspect-ratio:9/16;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  border-radius:22px;
}
@media(min-width:768px){
  .face-gate-modal .bank-face-content{
    border-radius:30px;
    height:min(92dvh,860px);
    max-height:860px;
    overflow:hidden;
  }
  .face-gate-modal .bank-face-header.minimal{
    min-height:58px;
  }
  .face-gate-modal .bank-face-footer{
    border-radius:0;
  }
}
@media(max-width:767px){
  .face-id-gate-card{
    width:84vw;
    padding:24px;
  }
  .face-gate-modal .bank-face-content{
    width:100vw;
  }
  .face-gate-modal .bank-face-oval{
    width:230px;
    height:315px;
  }
  .face-gate-modal .bank-face-flip-btn{
    top:66px;
    left:12px;
  }
}


/* V24 - Recorte facial centralizado e alinhamento mobile geral */
.facial-capture-box{
  width:min(260px,100%)!important;
  aspect-ratio:9/16!important;
  height:auto!important;
  margin:0 auto!important;
  border-radius:24px!important;
  padding:0!important;
  overflow:hidden!important;
  background:#f7fbff!important;
}
.facial-capture-box .face-preview{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  object-position:center center!important;
  display:block!important;
  border-radius:22px!important;
}
.face-gate-modal .bank-face-overlay{
  background:radial-gradient(ellipse 42% 32% at 50% 43%, transparent 0%, transparent 55%, rgba(3,8,20,.42) 57%, rgba(3,8,20,.84) 100%)!important;
}
.face-gate-modal .bank-face-oval{
  width:270px!important;
  height:360px!important;
  top:43%!important;
}

/* Mobile: impedir estouro horizontal e alinhar cards */
@media(max-width:767px){
  html, body{
    max-width:100%;
    overflow-x:hidden!important;
  }
  .app-shell,
  .content-wrap,
  .page-container,
  .delivery-form,
  .delivery-panel,
  .delivery-items,
  .delivery-item,
  .delivery-item-body{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }

  .page-container{
    padding-left:10px!important;
    padding-right:10px!important;
  }

  .delivery-panel{
    padding-left:0!important;
    padding-right:0!important;
  }
  .delivery-panel-header{
    padding:16px!important;
    align-items:flex-start!important;
  }
  .delivery-panel-header .btn{
    width:100%;
    justify-content:center;
  }

  .delivery-items{
    padding:0 10px 10px!important;
  }
  .delivery-item{
    display:flex!important;
    gap:10px!important;
    padding:14px 10px!important;
    border-radius:22px!important;
  }
  .delivery-item-number{
    width:38px!important;
    height:38px!important;
    min-width:38px!important;
    flex:0 0 38px!important;
    font-size:.95rem!important;
  }
  .delivery-item-body{
    min-width:0!important;
    flex:1 1 auto!important;
  }
  .delivery-item-body .row{
    --bs-gutter-x:.6rem!important;
    --bs-gutter-y:.85rem!important;
    margin-left:0!important;
    margin-right:0!important;
    width:100%!important;
  }
  .delivery-item-body .row > [class*="col-"]{
    min-width:0!important;
    padding-left:0!important;
    padding-right:0!important;
  }
  .delivery-item-body .col-lg-8{
    flex:0 0 100%!important;
    width:100%!important;
    max-width:100%!important;
  }
  .delivery-item-body .col-lg-2.col-6{
    flex:0 0 50%!important;
    width:50%!important;
    max-width:50%!important;
  }

  .modal-select-card,
  .epi-modal-button{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    padding:13px!important;
    gap:10px!important;
    border-radius:20px!important;
  }
  .modal-select-icon{
    width:46px!important;
    height:46px!important;
    flex:0 0 46px!important;
  }
  .modal-select-content{
    min-width:0!important;
    flex:1 1 auto!important;
  }
  .modal-select-content strong,
  .modal-select-content small{
    white-space:normal!important;
    overflow-wrap:anywhere!important;
    word-break:normal!important;
    line-height:1.25!important;
  }
  .modal-select-arrow{
    width:36px!important;
    height:36px!important;
    flex:0 0 36px!important;
  }

  .qtd-input{
    width:100%!important;
    max-width:100%!important;
  }
  .item-row .btn-remove-epi{
    margin-left:auto!important;
    margin-right:0!important;
  }

  .epi-preview{
    width:100%!important;
    max-width:100%!important;
    padding:14px!important;
    border-radius:18px!important;
    overflow:hidden!important;
  }
  .epi-preview-main strong,
  .epi-preview-main span{
    white-space:normal!important;
    overflow-wrap:anywhere!important;
  }
  .epi-badges{
    display:flex!important;
    flex-wrap:wrap!important;
    gap:7px!important;
    align-items:flex-start!important;
  }
  .epi-badges .badge{
    white-space:normal!important;
    text-align:left!important;
    max-width:100%!important;
  }

  .delivery-empty-help{
    margin-left:10px!important;
    margin-right:10px!important;
    border-radius:18px!important;
  }

  .selector-modal .modal-dialog,
  .modal-dialog{
    max-width:calc(100vw - 16px)!important;
  }
  .selector-modal .modal-content{
    border-radius:22px!important;
  }

  .face-gate-modal .bank-face-oval{
    width:245px!important;
    height:335px!important;
  }
  .facial-capture-box{
    width:min(220px,100%)!important;
  }
}

@media(max-width:390px){
  .delivery-item{
    padding:12px 8px!important;
    gap:8px!important;
  }
  .delivery-item-number{
    width:34px!important;
    height:34px!important;
    min-width:34px!important;
  }
  .modal-select-card,
  .epi-modal-button{
    padding:11px!important;
  }
  .modal-select-icon{
    width:42px!important;
    height:42px!important;
    flex-basis:42px!important;
  }
}


/* V25 - Foto Face ID igual ao enquadramento do modal e mobile global sem estouro */
.facial-capture-box{
  position:relative!important;
  width:min(280px,92vw)!important;
  aspect-ratio:9/16!important;
  height:auto!important;
  margin:0 auto!important;
  padding:0!important;
  overflow:hidden!important;
  border-radius:28px!important;
  background:#f7fbff!important;
  display:block!important;
}
.facial-capture-box .face-preview{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  max-width:none!important;
  max-height:none!important;
  object-fit:cover!important;
  object-position:center center!important;
  display:block!important;
  border-radius:26px!important;
}
.facial-capture-box .face-placeholder{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
}
.face-gate-modal .bank-face-video{
  object-fit:cover!important;
  object-position:center center!important;
}
.face-gate-modal .bank-face-viewport{
  background:#050816!important;
}

/* Mobile geral: evitar qualquer conteúdo estourando horizontalmente */
@media(max-width:767px){
  *{
    max-width:100%;
  }
  html,
  body{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }
  .app-shell,
  .content-wrap,
  .page-container,
  main,
  section,
  form,
  .card,
  .panel-card,
  .modern-card,
  .delivery-panel,
  .delivery-summary,
  .delivery-items,
  .delivery-item,
  .delivery-item-body,
  .table-responsive,
  .row{
    max-width:100%!important;
    overflow-x:hidden!important;
  }
  .row{
    margin-left:0!important;
    margin-right:0!important;
  }
  .row > *{
    min-width:0!important;
  }
  img,
  video,
  canvas{
    max-width:100%;
  }
  .btn{
    white-space:normal;
  }
  .topbar{
    max-width:100vw!important;
    overflow:hidden!important;
  }
  .topbar-actions{
    max-width:calc(100vw - 70px)!important;
    overflow:hidden!important;
  }
  .delivery-panel-header,
  .card-header-modern,
  .dash-panel-header{
    flex-wrap:wrap!important;
  }
  .delivery-panel-header > *,
  .card-header-modern > *,
  .dash-panel-header > *{
    min-width:0!important;
  }
  .delivery-panel-header .btn,
  .card-header-modern .btn{
    max-width:100%!important;
  }
  .selector-option,
  .epi-modal-option,
  .modal-select-card{
    max-width:100%!important;
    min-width:0!important;
  }
  .selector-option *,
  .epi-modal-option *,
  .modal-select-card *{
    min-width:0!important;
  }
  .selector-option strong,
  .selector-option span,
  .selector-option small,
  .epi-modal-option strong,
  .epi-modal-option span,
  .epi-modal-option small,
  .modal-select-content strong,
  .modal-select-content small{
    overflow-wrap:anywhere!important;
    word-break:normal!important;
  }
  .facial-capture-box{
    width:min(240px,86vw)!important;
  }
}

/* V26 - Restaurar somente o modal Face ID para V23 */
/* V23 - Face ID obrigatório antes da Nova Entrega e câmera 9:16 */
.face-id-gate{
  position:fixed;
  inset:0;
  z-index:2040;
  background:linear-gradient(180deg,#f7fbff,#eef6ff);
  display:flex;
  align-items:center;
  justify-content:center;
}
.face-id-gate-card{
  width:min(320px,88vw);
  padding:28px;
  border-radius:28px;
  background:#fff;
  border:1px solid #d9e8ff;
  box-shadow:0 28px 70px rgba(16,24,40,.16);
  text-align:center;
}
.face-id-gate-logo{
  width:72px;
  height:72px;
  border-radius:24px;
  margin:0 auto 14px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#0957b8;
  background:#eef6ff;
  font-size:2rem;
}
.face-id-gate-card strong{
  display:block;
  font-size:1.35rem;
  font-weight:950;
  color:var(--ink);
  letter-spacing:-.04em;
}
.face-id-gate-card span{
  display:block;
  color:var(--muted);
  margin-top:4px;
}
body.face-gate-active{
  overflow:hidden;
}
body.face-gate-active .topbar,
body.face-gate-active .sidebar,
body.face-gate-active .delivery-hero,
body.face-gate-active .delivery-stepper,
body.face-gate-active .delivery-form{
  opacity:0;
  pointer-events:none;
}
.face-gate-modal{
  z-index:2060;
}
.face-gate-modal + .modal-backdrop,
.modal-backdrop.show{
  opacity:.92;
}
.face-gate-modal .modal-dialog{
  max-width:none;
  width:100vw;
  height:100dvh;
  margin:0;
  display:flex;
  align-items:center;
  justify-content:center;
}
.face-gate-modal .bank-face-content{
  width:min(440px,100vw);
  height:100dvh;
  max-height:100dvh;
  border-radius:0;
  display:flex;
  flex-direction:column;
}
.face-gate-modal .bank-face-header.minimal{
  min-height:56px;
  padding:12px 16px;
  flex:0 0 auto;
}
.face-gate-modal .bank-face-body{
  flex:1 1 auto;
  padding:0;
  background:#050816;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}
.face-gate-modal .bank-face-viewport{
  width:100%;
  height:100%;
  max-width:440px;
  aspect-ratio:9/16;
  border-radius:0;
  box-shadow:none;
}
.face-gate-modal .bank-face-video{
  width:100%;
  height:100%;
  object-fit:cover!important;
}
.face-gate-modal .bank-face-overlay{
  background:radial-gradient(ellipse 38% 29% at 50% 43%, transparent 0%, transparent 52%, rgba(3,8,20,.45) 54%, rgba(3,8,20,.84) 100%);
}
.face-gate-modal .bank-face-oval{
  width:255px;
  height:340px;
  top:43%;
}
.face-gate-modal .bank-face-footer{
  flex:0 0 auto;
  padding:12px 14px 16px;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  background:#fff;
}
.face-gate-modal .bank-face-footer #captureFaceButtonModal{
  grid-column:1 / -1;
  order:3;
  min-height:46px;
}
.face-gate-modal .bank-face-footer [data-bs-dismiss="modal"]{
  order:1;
}
.face-gate-modal .bank-face-bottom-hint{
  bottom:82px;
  width:calc(100% - 34px);
  max-width:360px;
}
.face-gate-modal .bank-face-flip-btn{
  top:70px;
  left:14px;
}
.face-gate-modal .btn-close{
  display:none;
}
.facial-capture-box{
  aspect-ratio:9/16;
  width:min(240px,100%);
  height:auto!important;
  margin:0 auto;
  border-radius:24px;
}
.facial-capture-box .face-preview{
  aspect-ratio:9/16;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  border-radius:22px;
}
@media(min-width:768px){
  .face-gate-modal .bank-face-content{
    border-radius:30px;
    height:min(92dvh,860px);
    max-height:860px;
    overflow:hidden;
  }
  .face-gate-modal .bank-face-header.minimal{
    min-height:58px;
  }
  .face-gate-modal .bank-face-footer{
    border-radius:0;
  }
}
@media(max-width:767px){
  .face-id-gate-card{
    width:84vw;
    padding:24px;
  }
  .face-gate-modal .bank-face-content{
    width:100vw;
  }
  .face-gate-modal .bank-face-oval{
    width:230px;
    height:315px;
  }
  .face-gate-modal .bank-face-flip-btn{
    top:66px;
    left:12px;
  }
}


/* V28 - Desktop: assinatura, localização e boas práticas abaixo do termo */
.under-term-actions{
  display:grid;
  grid-template-columns:minmax(0,1.15fr) minmax(280px,.85fr);
  gap:16px;
  align-items:start;
}
.under-term-actions .delivery-summary,
.under-term-actions .delivery-tips{
  margin-bottom:0!important;
}
.under-term-actions .delivery-tips{
  align-self:stretch;
}
@media(min-width:1200px){
  .under-term-actions .delivery-tips{
    grid-column:2;
  }
  .under-term-actions .delivery-summary:first-child{
    grid-row:1 / span 2;
  }
}
@media(max-width:1199px){
  .under-term-actions{
    grid-template-columns:1fr;
  }
}
@media(max-width:767px){
  .under-term-actions{
    display:block;
  }
  .under-term-actions .delivery-summary,
  .under-term-actions .delivery-tips{
    margin-bottom:1rem!important;
  }
}


/* V29 - Cancelar Face ID como link para Dashboard */
.face-gate-modal .bank-face-footer a.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  text-decoration:none;
}
.faceid-cancel-dashboard.btn-close{
  display:none;
}


/* V30 - Download automático do PDF da ficha no dashboard */
.auto-download-card{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:14px 16px;
  margin-bottom:18px;
  border:1px solid #d9e8ff;
  background:linear-gradient(180deg,#ffffff,#f7fbff);
  border-radius:20px;
  box-shadow:0 14px 34px rgba(16,24,40,.07);
}
.auto-download-card strong{
  display:block;
  color:var(--ink);
  font-weight:900;
}
.auto-download-card span{
  display:block;
  color:var(--muted);
  font-size:.9rem;
  margin-top:2px;
}
@media(max-width:767px){
  .auto-download-card{
    flex-direction:column;
    align-items:stretch;
  }
  .auto-download-card .btn{
    width:100%;
  }
}


/* V31 - Fluxo seguro de PDF após entrega */
.face-gate-modal .bank-face-footer a.btn,
.faceid-cancel-dashboard{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  text-decoration:none;
}


/* V34 - Foto facial em 9:16 também na tela entrega_ver */
.facial-card-print .facial-frame{
  width:150px !important;
  height:267px !important;
  min-height:267px !important;
  max-width:150px !important;
  margin:12px auto 0 auto !important;
  border-radius:18px !important;
  background:#f8fafc !important;
  border:1px solid #d7e2f0 !important;
  overflow:hidden !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
}
.facial-card-print .facial-frame img{
  width:150px !important;
  height:267px !important;
  min-width:150px !important;
  max-width:150px !important;
  object-fit:cover !important;
  object-position:center top !important;
  border-radius:18px !important;
  display:block !important;
}
.facial-card-print .facial-proof{
  justify-content:center;
  text-align:center;
}
@media(min-width:992px){
  .facial-card-print .panel-body{
    display:flex;
    flex-direction:column;
    align-items:center;
  }
  .facial-card-print .panel-body > strong{
    align-self:flex-start;
  }
}
@media(max-width:767px){
  .facial-card-print .facial-frame{
    width:132px !important;
    height:235px !important;
    min-height:235px !important;
    max-width:132px !important;
  }
  .facial-card-print .facial-frame img{
    width:132px !important;
    height:235px !important;
    min-width:132px !important;
    max-width:132px !important;
  }
}
@media print{
  .facial-card-print .facial-frame{
    width:86px !important;
    height:153px !important;
    min-height:153px !important;
    max-width:86px !important;
    border-radius:12px !important;
  }
  .facial-card-print .facial-frame img{
    width:86px !important;
    height:153px !important;
    min-width:86px !important;
    max-width:86px !important;
    border-radius:12px !important;
  }
}


/* V35 - Face ID mobile alinhado na largura da tela */
@media(max-width:767px){
  html,
  body{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }

  body.modal-open{
    padding-right:0!important;
    overflow:hidden!important;
  }

  .face-gate-modal,
  #modalDeliveryFaceCamera{
    position:fixed!important;
    inset:0!important;
    width:100vw!important;
    max-width:100vw!important;
    height:100dvh!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
  }

  .face-gate-modal .modal-dialog,
  #modalDeliveryFaceCamera .modal-dialog{
    width:100vw!important;
    max-width:100vw!important;
    min-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    margin:0!important;
    padding:0!important;
    transform:none!important;
    display:block!important;
  }

  .face-gate-modal .bank-face-content,
  #modalDeliveryFaceCamera .bank-face-content{
    width:100vw!important;
    max-width:100vw!important;
    min-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    min-height:100dvh!important;
    margin:0!important;
    border-radius:0!important;
    border:0!important;
    display:flex!important;
    flex-direction:column!important;
    overflow:hidden!important;
  }

  .face-gate-modal .bank-face-header.minimal,
  #modalDeliveryFaceCamera .bank-face-header.minimal{
    width:100vw!important;
    max-width:100vw!important;
    min-height:62px!important;
    height:62px!important;
    padding:0 22px!important;
    display:flex!important;
    align-items:center!important;
    flex:0 0 62px!important;
    border-radius:0!important;
  }

  .face-gate-modal .bank-face-body,
  #modalDeliveryFaceCamera .bank-face-body{
    width:100vw!important;
    max-width:100vw!important;
    flex:1 1 auto!important;
    padding:0!important;
    margin:0!important;
    overflow:hidden!important;
    background:#050816!important;
  }

  .face-gate-modal .bank-face-viewport,
  #modalDeliveryFaceCamera .bank-face-viewport{
    width:100vw!important;
    max-width:100vw!important;
    min-width:100vw!important;
    height:calc(100dvh - 214px)!important;
    max-height:calc(100dvh - 214px)!important;
    margin:0!important;
    border-radius:0!important;
    box-shadow:none!important;
  }

  .face-gate-modal .bank-face-video,
  #modalDeliveryFaceCamera .bank-face-video{
    width:100vw!important;
    max-width:100vw!important;
    height:100%!important;
    object-fit:cover!important;
    object-position:center center!important;
    transform:scaleX(-1)!important;
  }

  .face-gate-modal .bank-face-overlay,
  #modalDeliveryFaceCamera .bank-face-overlay{
    width:100vw!important;
    max-width:100vw!important;
    left:0!important;
    right:0!important;
  }

  .face-gate-modal .bank-face-footer,
  #modalDeliveryFaceCamera .bank-face-footer{
    width:100vw!important;
    max-width:100vw!important;
    min-height:152px!important;
    flex:0 0 152px!important;
    padding:16px 20px 22px!important;
    margin:0!important;
    border-radius:0!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
    background:#fff!important;
  }

  .face-gate-modal .bank-face-footer .btn,
  #modalDeliveryFaceCamera .bank-face-footer .btn{
    width:100%!important;
    min-height:48px!important;
    margin:0!important;
  }

  .face-gate-modal .bank-face-footer #captureFaceButtonModal,
  #modalDeliveryFaceCamera .bank-face-footer #captureFaceButtonModal{
    grid-column:1!important;
    order:2!important;
  }

  .face-gate-modal .bank-face-footer [data-bs-dismiss="modal"],
  .face-gate-modal .bank-face-footer .faceid-cancel-dashboard,
  #modalDeliveryFaceCamera .bank-face-footer [data-bs-dismiss="modal"],
  #modalDeliveryFaceCamera .bank-face-footer .faceid-cancel-dashboard{
    grid-column:1!important;
    order:1!important;
  }

  .face-gate-modal .bank-face-flip-btn,
  #modalDeliveryFaceCamera .bank-face-flip-btn{
    top:78px!important;
    left:16px!important;
    z-index:8!important;
  }

  .face-gate-modal .bank-face-bottom-hint,
  #modalDeliveryFaceCamera .bank-face-bottom-hint{
    left:50%!important;
    right:auto!important;
    transform:translateX(-50%)!important;
    bottom:118px!important;
    width:calc(100vw - 48px)!important;
    max-width:calc(100vw - 48px)!important;
  }

  .face-gate-modal .bank-face-oval,
  #modalDeliveryFaceCamera .bank-face-oval{
    left:50%!important;
    top:44%!important;
    transform:translate(-50%,-50%)!important;
    width:min(285px,68vw)!important;
    height:min(390px,52dvh)!important;
  }

  .modal-backdrop{
    width:100vw!important;
    height:100dvh!important;
  }
}

/* V36 - Restaurar somente o layout do relatório PDF da entrega para o padrão V34 */
@media print{
  html,body{
    background:#fff!important;
    color:#111!important;
    font-size:10px!important;
    width:210mm!important;
  }
  .page-container{
    padding:0!important;
    max-width:none!important;
    width:100%!important;
  }
  .content-wrap{
    margin:0!important;
    width:100%!important;
  }
  .delivery-sheet{
    max-width:none!important;
    margin:0!important;
    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
    background:#fff!important;
  }
  .delivery-sheet .sheet-inner{
    padding:0!important;
  }
  .sheet-header{
    margin-bottom:7px!important;
    gap:8px!important;
  }
  .sheet-logo{
    max-width:118px!important;
  }
  .sheet-title h2{
    font-size:17px!important;
    line-height:1.1!important;
    margin-bottom:1px!important;
  }
  .sheet-title .text-muted{
    font-size:9px!important;
  }
  .sheet-status{
    font-size:8px!important;
    padding:3px 7px!important;
  }
  .sheet-identity-grid{
    grid-template-columns:1fr 1fr!important;
    gap:6px!important;
    margin-bottom:7px!important;
  }
  .compact-stat,
  .mini-stat{
    min-height:0!important;
    padding:7px 8px!important;
    border-radius:8px!important;
    gap:6px!important;
  }
  .compact-stat i,
  .mini-stat i{
    font-size:12px!important;
  }
  .compact-stat strong,
  .mini-stat strong{
    font-size:9.3px!important;
    line-height:1.15!important;
  }
  .compact-stat small,
  .mini-stat small{
    font-size:7.8px!important;
    line-height:1.15!important;
  }
  .card,
  .border-soft{
    box-shadow:none!important;
    border-radius:8px!important;
    background:#fff!important;
  }
  .delivery-section,
  .term-box{
    margin-bottom:7px!important;
  }
  .card-header-modern{
    padding:6px 8px!important;
    background:#fff!important;
  }
  .card-header-modern h5{
    font-size:11px!important;
    line-height:1.1!important;
  }
  .card-header-modern small{
    display:none!important;
  }
  .table-responsive,
  .delivery-items-wrap{
    overflow:visible!important;
    width:100%!important;
  }
  .compact-items-table{
    width:100%!important;
    table-layout:fixed!important;
    font-size:8.2px!important;
  }
  .compact-items-table th,
  .compact-items-table td{
    padding:3.5px 4px!important;
    white-space:normal!important;
    word-break:normal!important;
    overflow-wrap:anywhere!important;
    line-height:1.12!important;
  }
  .compact-items-table thead th{
    font-size:6.7px!important;
    letter-spacing:.02em!important;
  }
  .compact-items-table .col-item{
    width:34%!important;
  }
  .compact-items-table .col-qtd{
    width:6%!important;
  }
  .compact-items-table .col-ca{
    width:10%!important;
  }
  .compact-items-table .col-date{
    width:12%!important;
  }
  .compact-items-table .col-dev{
    width:14%!important;
  }
  .compact-items-table .item-main small{
    font-size:7px!important;
    line-height:1.1!important;
    margin-top:1px!important;
  }
  .badge{
    font-size:7px!important;
    padding:2px 4px!important;
    border-radius:6px!important;
  }
  .term-box .panel-body{
    padding:7px 8px!important;
    font-size:8.8px!important;
    line-height:1.22!important;
  }
  .term-box p{
    margin-top:3px!important;
    line-height:1.22!important;
  }
  .signature-audit-grid{
    display:grid!important;
    grid-template-columns:37% 63%!important;
    gap:7px!important;
  }
  .signature-card .panel-body,
  .audit-card-print .panel-body{
    padding:7px 8px!important;
  }
  .signature-card strong,
  .audit-card-print strong{
    font-size:9px!important;
  }
  .signature-frame{
    min-height:76px!important;
    max-height:82px!important;
    margin-top:5px!important;
    padding:5px!important;
    border-radius:8px!important;
  }
  .signature-frame img{
    max-height:66px!important;
    max-width:100%!important;
  }
  .facial-card-print{
    text-align:left!important;
  }
  .facial-card-print .panel-body{
    display:block!important;
    padding:7px 8px!important;
  }
  .facial-card-print .panel-body > strong{
    align-self:auto!important;
    font-size:9px!important;
  }
  .facial-card-print .facial-frame{
    width:86px!important;
    height:153px!important;
    min-height:153px!important;
    max-width:86px!important;
    margin:10px auto 0 auto!important;
    border-radius:12px!important;
    background:#f8fafc!important;
    border:1px solid #d7e2f0!important;
    box-shadow:none!important;
  }
  .facial-card-print .facial-frame img{
    width:86px!important;
    height:153px!important;
    min-width:86px!important;
    max-width:86px!important;
    object-fit:cover!important;
    object-position:center top!important;
    border-radius:12px!important;
    display:block!important;
  }
  .facial-card-print .facial-proof{
    justify-content:flex-start!important;
    text-align:left!important;
    font-size:8pt!important;
    margin-top:6px!important;
  }
  .audit-title{
    margin-bottom:0!important;
  }
  .audit-grid-compact{
    grid-template-columns:repeat(3,1fr)!important;
    gap:4px!important;
    margin-top:6px!important;
  }
  .audit-grid-compact .meta-item{
    padding:4px 5px!important;
    border-radius:7px!important;
  }
  .audit-grid-compact .meta-item span{
    font-size:6.6px!important;
    line-height:1!important;
  }
  .audit-grid-compact .meta-item strong{
    font-size:7.5px!important;
    line-height:1.05!important;
    margin-top:1px!important;
  }
  .map-card-compact,
  .map-card{
    display:none!important;
  }
  .print-location-link{
    display:block!important;
    font-size:7.6px!important;
    line-height:1.12!important;
    padding:5px 6px!important;
    margin-top:5px!important;
    border-radius:7px!important;
  }
  .device-meta{
    display:none!important;
  }
  .empty-note{
    font-size:7.6px!important;
    padding:5px 6px!important;
    margin-top:5px!important;
    border-radius:7px!important;
  }
  .no-break{
    break-inside:avoid!important;
    page-break-inside:avoid!important;
  }
  a[href]::after{
    content:""!important;
  }
}



/* V37 - Correção assinatura mobile e carregamento ao finalizar entrega */
.submit-pdf-overlay{
  position:fixed;
  inset:0;
  z-index:3000;
  background:rgba(241,245,249,.82);
  backdrop-filter:blur(8px);
  display:flex;
  align-items:center;
  justify-content:center;
}
.submit-pdf-box{
  width:min(360px,88vw);
  padding:28px;
  border-radius:28px;
  background:#fff;
  border:1px solid #d9e8ff;
  box-shadow:0 30px 70px rgba(16,24,40,.16);
  text-align:center;
}
.submit-pdf-box .spinner-border{
  width:3rem;
  height:3rem;
  margin-bottom:16px;
}
.submit-pdf-box strong{
  display:block;
  color:var(--ink);
  font-size:1.2rem;
  font-weight:900;
}
.submit-pdf-box span{
  display:block;
  color:var(--muted);
  margin-top:4px;
}


/* V38 - Assinatura mobile persistente e sem retorno ao Face ID após finalizar */
.signature-pad{
  background-color:#fff;
  background-size:100% 100%;
  background-repeat:no-repeat;
  background-position:center center;
}


/* V39 - Mobile: tabelas com rolagem lateral real em todas as páginas */
@media(max-width:767px){
  .data-card,
  .panel-card,
  .modern-card,
  .card{
    max-width:100%!important;
  }

  .data-card .table-responsive,
  .panel-card .table-responsive,
  .modern-card .table-responsive,
  .card .table-responsive,
  .table-responsive{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
    -webkit-overflow-scrolling:touch!important;
    touch-action:pan-x pan-y!important;
    overscroll-behavior-x:contain!important;
    padding-bottom:8px!important;
  }

  .data-card .table-responsive > table,
  .panel-card .table-responsive > table,
  .modern-card .table-responsive > table,
  .card .table-responsive > table,
  .table-responsive > table,
  .table-responsive .table{
    width:max-content!important;
    min-width:760px!important;
    max-width:none!important;
    table-layout:auto!important;
  }

  .table-responsive th,
  .table-responsive td{
    white-space:nowrap!important;
    max-width:none!important;
    overflow:visible!important;
    text-overflow:clip!important;
  }

  .table-responsive td strong,
  .table-responsive td span,
  .table-responsive td small,
  .table-responsive td div,
  .table-responsive th span,
  .table-responsive th div{
    max-width:none!important;
    white-space:nowrap!important;
  }

  /* Tabelas maiores, como estoque, movimentos, auditoria e relatórios */
  .table-responsive table.table-modern,
  .table-responsive table.compact-items-table{
    min-width:820px!important;
  }

  .table-responsive::-webkit-scrollbar{
    height:10px!important;
  }
  .table-responsive::-webkit-scrollbar-thumb{
    background:#b9c9df!important;
    border-radius:999px!important;
  }
  .table-responsive::-webkit-scrollbar-track{
    background:#eef4fb!important;
    border-radius:999px!important;
  }

  /* Aviso visual: dá espaço para o usuário perceber que pode arrastar */
  .table-responsive::after{
    content:'Arraste para o lado';
    display:block;
    width:max-content;
    color:#64748b;
    font-size:.76rem;
    font-weight:700;
    padding:6px 2px 0;
  }
}

/* V39 - Datas e tabelas */
.system-timezone-note{
  display:none;
}


/* V40 - Finalização sem PDF automático, com botão VER */
#deliveryDoneNotice.auto-download-card{
  border-color:#bbf7d0;
  background:linear-gradient(180deg,#ffffff,#f0fff4);
}
#deliveryDoneNotice.auto-download-card strong{
  color:#146b22;
}
#deliveryDoneNotice .btn{
  min-width:92px;
}
.submit-pdf-box strong::after{
  content:'';
}

/* V41 - Ficha de entrega mobile alinhada e impressão sem segunda página em branco */
@media(max-width:767px){
  body:has(.delivery-sheet){
    overflow-x:hidden!important;
  }
  .delivery-sheet{
    width:100%!important;
    max-width:100%!important;
    margin:0!important;
    border-radius:18px!important;
    overflow:hidden!important;
  }
  .delivery-sheet .sheet-inner{
    padding:14px!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  .sheet-header{
    flex-direction:column!important;
    align-items:flex-start!important;
    gap:12px!important;
    margin-bottom:14px!important;
  }
  .sheet-header .d-flex{
    width:100%!important;
    min-width:0!important;
    align-items:center!important;
  }
  .sheet-logo{
    max-width:96px!important;
    width:96px!important;
    flex:0 0 96px!important;
  }
  .sheet-title{
    min-width:0!important;
  }
  .sheet-title h2{
    font-size:1.12rem!important;
    line-height:1.18!important;
    overflow-wrap:anywhere!important;
  }
  .sheet-title .text-muted{
    font-size:.82rem!important;
    line-height:1.25!important;
    overflow-wrap:anywhere!important;
  }
  .sheet-status{
    align-self:flex-start!important;
  }
  .sheet-identity-grid,
  .signature-audit-grid{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
    width:100%!important;
  }
  .delivery-section,
  .term-box,
  .signature-card,
  .facial-card-print,
  .audit-card-print{
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  .term-box .panel-body,
  .signature-card .panel-body,
  .facial-card-print .panel-body,
  .audit-card-print .panel-body{
    padding:14px!important;
  }
  .term-box p{
    font-size:.92rem!important;
    line-height:1.45!important;
    overflow-wrap:anywhere!important;
  }
  .signature-frame{
    min-height:120px!important;
    margin-top:10px!important;
    border-radius:14px!important;
  }
  .signature-frame img{
    max-height:96px!important;
  }
  .facial-card-print .facial-frame{
    width:132px!important;
    height:235px!important;
    min-height:235px!important;
    max-width:132px!important;
    margin:12px auto 0!important;
  }
  .facial-card-print .facial-frame img{
    width:132px!important;
    height:235px!important;
    min-width:132px!important;
    max-width:132px!important;
  }
  .facial-proof{
    justify-content:center!important;
    text-align:center!important;
    flex-wrap:wrap!important;
    line-height:1.25!important;
  }
  .audit-grid-compact{
    grid-template-columns:1fr 1fr!important;
    gap:8px!important;
  }
  .audit-grid-compact .meta-item{
    min-width:0!important;
    padding:10px!important;
  }
  .audit-grid-compact .meta-item strong,
  .audit-grid-compact .meta-item span{
    overflow-wrap:anywhere!important;
    word-break:normal!important;
  }
  .map-card-compact{
    height:180px!important;
  }
  .delivery-sheet .delivery-items-wrap,
  .delivery-sheet .table-responsive{
    overflow-x:auto!important;
    overflow-y:hidden!important;
    -webkit-overflow-scrolling:touch!important;
    width:100%!important;
    max-width:100%!important;
    padding-bottom:8px!important;
  }
  .delivery-sheet .compact-items-table{
    width:max-content!important;
    min-width:680px!important;
    max-width:none!important;
    table-layout:auto!important;
  }
  .delivery-sheet .compact-items-table th,
  .delivery-sheet .compact-items-table td{
    white-space:nowrap!important;
  }
  .delivery-sheet .compact-items-table .item-main strong,
  .delivery-sheet .compact-items-table .item-main small{
    white-space:normal!important;
    overflow-wrap:anywhere!important;
    max-width:210px!important;
  }
}

@page{
  size:A4 portrait;
  margin:7mm;
}
@media print{
  html,body{
    width:auto!important;
    height:auto!important;
    min-height:0!important;
    overflow:visible!important;
    margin:0!important;
    background:#fff!important;
  }
  .app-shell,
  .content-wrap,
  .page-container{
    display:block!important;
    width:100%!important;
    max-width:none!important;
    min-height:0!important;
    height:auto!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
  }
  .delivery-sheet{
    width:100%!important;
    max-width:none!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    box-shadow:none!important;
    break-after:avoid!important;
    page-break-after:avoid!important;
    break-before:avoid!important;
    page-break-before:avoid!important;
  }
  .delivery-sheet .sheet-inner{
    padding:0!important;
    margin:0!important;
    break-after:avoid!important;
    page-break-after:avoid!important;
  }
  .delivery-sheet *{
    box-shadow:none!important;
  }
  .delivery-sheet::after,
  .delivery-sheet .sheet-inner::after,
  .page-container::after,
  .content-wrap::after{
    content:none!important;
    display:none!important;
  }
  .module-hero,
  .hero-actions,
  .no-print,
  .sidebar,
  .topbar,
  .sidebar-backdrop,
  .alert{
    display:none!important;
  }
  .delivery-section:last-child,
  .signature-audit-grid:last-child,
  .audit-card-print:last-child{
    margin-bottom:0!important;
    padding-bottom:0!important;
    break-after:avoid!important;
    page-break-after:avoid!important;
  }
  .signature-audit-grid{
    margin-bottom:0!important;
    break-inside:avoid!important;
    page-break-inside:avoid!important;
  }
  .audit-card-print{
    break-after:avoid!important;
    page-break-after:avoid!important;
  }
  .map-card-compact,
  .map-card,
  .device-meta{
    display:none!important;
  }
  /* deixa o conteúdo um pouco mais compacto para caber em uma única página */
  .sheet-header{margin-bottom:5px!important;}
  .sheet-identity-grid{margin-bottom:5px!important;}
  .delivery-section,.term-box{margin-bottom:5px!important;}
  .term-box .panel-body{padding:6px 8px!important;}
  .term-box p{font-size:8.2px!important;line-height:1.14!important;}
  .signature-card .panel-body,
  .facial-card-print .panel-body,
  .audit-card-print .panel-body{padding:6px 8px!important;}
  .signature-frame{min-height:64px!important;max-height:70px!important;margin-top:4px!important;}
  .signature-frame img{max-height:58px!important;}
  .facial-card-print .facial-frame{width:72px!important;height:128px!important;min-height:128px!important;max-width:72px!important;margin:5px auto 0!important;}
  .facial-card-print .facial-frame img{width:72px!important;height:128px!important;min-width:72px!important;max-width:72px!important;}
  .facial-proof{font-size:7.2pt!important;margin-top:4px!important;line-height:1.1!important;}
  .audit-grid-compact{gap:3px!important;margin-top:4px!important;}
  .audit-grid-compact .meta-item{padding:3px 4px!important;}
  .audit-grid-compact .meta-item span{font-size:6.1px!important;}
  .audit-grid-compact .meta-item strong{font-size:6.9px!important;}
  .print-location-link{font-size:6.8px!important;padding:3px 5px!important;margin-top:3px!important;}
  .compact-items-table th,.compact-items-table td{padding:2.8px 3.5px!important;line-height:1.08!important;}
  .compact-items-table .item-main small{font-size:6.5px!important;}
}



/* V42 - Face ID com câmera visualmente mais distante */
.bank-face-viewport{
  background:#050816!important;
}
.bank-face-video{
  transform:scaleX(-1) scale(.92)!important;
  transform-origin:center center!important;
}
.face-gate-modal .bank-face-video,
#modalDeliveryFaceCamera .bank-face-video{
  object-fit:cover!important;
  transform:scaleX(-1) scale(.92)!important;
  transform-origin:center center!important;
}
@media(max-width:767px){
  .face-gate-modal .bank-face-video,
  #modalDeliveryFaceCamera .bank-face-video{
    transform:scaleX(-1) scale(.88)!important;
  }
  .face-gate-modal .bank-face-oval,
  #modalDeliveryFaceCamera .bank-face-oval{
    width:min(265px,64vw)!important;
    height:min(360px,49dvh)!important;
  }
}


/* V44 - Mobile: Nova Entrega limpa e objetiva */
.mobile-term-card{
  display:none;
}

@media(max-width:767px){
  body:has(#formEntrega) .page-container{
    padding:10px!important;
  }

  body:has(#formEntrega) .delivery-hero,
  body:has(#formEntrega) .delivery-stepper,
  body:has(#formEntrega) .form-tip,
  body:has(#formEntrega) .delivery-panel-header p,
  body:has(#formEntrega) .delivery-panel-header small,
  body:has(#formEntrega) .delivery-empty-help,
  body:has(#formEntrega) .delivery-summary.no-print:has(#locationCapture),
  body:has(#formEntrega) .delivery-tips,
  body:has(#formEntrega) .delivery-side,
  body:has(#formEntrega) .facial-capture-box,
  body:has(#formEntrega) #faceStatus,
  body:has(#formEntrega) #registeredFaceCard,
  body:has(#formEntrega) #faceApiStatusEntrega,
  body:has(#formEntrega) #startFaceCamera,
  body:has(#formEntrega) #captureFaceButton,
  body:has(#formEntrega) #clearFaceButton{
    display:none!important;
  }

  /* Mantém dados técnicos ocultos para o PDF/auditoria, mas tira da tela mobile */
  body:has(#formEntrega) .delivery-panel:has(#locationCapture),
  body:has(#formEntrega) .delivery-summary:has(#faceStatus){
    display:none!important;
  }

  body:has(#formEntrega) .row.g-4{
    --bs-gutter-y:.85rem!important;
  }

  body:has(#formEntrega) .col-xxl-8,
  body:has(#formEntrega) .col-xxl-4,
  body:has(#formEntrega) .col-xl-5{
    width:100%!important;
    flex:0 0 100%!important;
    max-width:100%!important;
  }

  body:has(#formEntrega) .delivery-panel{
    border-radius:20px!important;
    margin-bottom:12px!important;
    box-shadow:0 10px 26px rgba(16,24,40,.06)!important;
  }

  body:has(#formEntrega) .delivery-panel-header{
    padding:13px 14px!important;
    gap:10px!important;
    min-height:auto!important;
  }

  body:has(#formEntrega) .delivery-panel-icon{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    border-radius:14px!important;
  }

  body:has(#formEntrega) .delivery-panel-header h5{
    font-size:1.02rem!important;
    margin:0!important;
    letter-spacing:-.03em!important;
  }

  /* Identificação: somente colaborador, filial, motivo e dados do colaborador */
  body:has(#formEntrega) .delivery-panel:first-of-type .p-4{
    padding:12px!important;
  }

  body:has(#formEntrega) .delivery-panel:first-of-type .row{
    gap:8px!important;
  }

  body:has(#formEntrega) .delivery-panel:first-of-type .row > [class*="col-"]{
    width:100%!important;
    flex:0 0 100%!important;
    padding:0!important;
  }

  body:has(#formEntrega) .form-label{
    font-size:.78rem!important;
    margin:0 0 5px!important;
  }

  body:has(#formEntrega) .modal-select-card{
    min-height:58px!important;
    padding:10px 12px!important;
    border-radius:16px!important;
  }

  body:has(#formEntrega) .modal-select-icon{
    width:38px!important;
    height:38px!important;
    min-width:38px!important;
    border-radius:13px!important;
  }

  body:has(#formEntrega) .modal-select-content strong{
    font-size:.94rem!important;
    line-height:1.15!important;
  }

  body:has(#formEntrega) .modal-select-content small{
    font-size:.72rem!important;
    line-height:1.15!important;
  }

  body:has(#formEntrega) .modal-select-arrow{
    width:32px!important;
    height:32px!important;
    min-width:32px!important;
  }

  body:has(#formEntrega) .selected-worker-card{
    margin-top:10px!important;
    padding:12px!important;
    border-radius:18px!important;
    gap:10px!important;
  }

  body:has(#formEntrega) .selected-worker-avatar{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    border-radius:14px!important;
  }

  body:has(#formEntrega) .selected-worker-card p{
    display:none!important;
  }

  body:has(#formEntrega) .worker-tags{
    margin-top:7px!important;
    gap:5px!important;
  }

  body:has(#formEntrega) .worker-tags span{
    font-size:.72rem!important;
    padding:5px 7px!important;
  }

  /* Itens: card pequeno, EPI de um lado e quantidade ao lado */
  body:has(#formEntrega) #itensEntrega{
    padding:10px!important;
  }

  body:has(#formEntrega) .item-row{
    display:grid!important;
    grid-template-columns:34px minmax(0,1fr)!important;
    gap:8px!important;
    padding:10px!important;
    border-radius:18px!important;
    margin-bottom:10px!important;
  }

  body:has(#formEntrega) .delivery-item-number{
    width:32px!important;
    height:32px!important;
    min-width:32px!important;
    border-radius:12px!important;
    font-size:.9rem!important;
  }

  body:has(#formEntrega) .delivery-item-body{
    width:100%!important;
    min-width:0!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) 74px 42px!important;
    gap:7px!important;
    align-items:end!important;
    margin:0!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div{
    padding:0!important;
    width:auto!important;
    max-width:none!important;
    flex:none!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(1){
    grid-column:1!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(2){
    grid-column:2!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(3){
    grid-column:3!important;
  }

  body:has(#formEntrega) .delivery-item-body .form-label{
    display:none!important;
  }

  body:has(#formEntrega) .epi-modal-button{
    min-height:50px!important;
    padding:8px 9px!important;
    border-radius:15px!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-icon{
    width:34px!important;
    height:34px!important;
    min-width:34px!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-content strong{
    font-size:.86rem!important;
    max-height:32px!important;
    overflow:hidden!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-content small{
    display:none!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-arrow{
    width:28px!important;
    height:28px!important;
    min-width:28px!important;
  }

  body:has(#formEntrega) .qtd-input{
    height:50px!important;
    min-height:50px!important;
    padding:0 8px!important;
    text-align:center!important;
    border-radius:15px!important;
    font-size:1rem!important;
  }

  body:has(#formEntrega) .btn-remove-epi{
    width:42px!important;
    height:50px!important;
    min-height:50px!important;
    padding:0!important;
    border-radius:15px!important;
    font-size:0!important;
  }

  body:has(#formEntrega) .btn-remove-epi i{
    font-size:1rem!important;
    margin:0!important;
  }

  body:has(#formEntrega) .epi-preview{
    display:none!important;
  }

  body:has(#formEntrega) #addItem{
    width:auto!important;
    min-height:38px!important;
    padding:7px 10px!important;
    border-radius:13px!important;
    font-size:.86rem!important;
  }

  /* Termo vira card com modal */
  body:has(#formEntrega) .term-box{
    display:none!important;
  }

  body:has(#formEntrega) .mobile-term-card{
    display:block!important;
    margin:0 0 12px!important;
  }

  body:has(#formEntrega) .mobile-term-button{
    width:100%;
    display:flex;
    align-items:center;
    gap:10px;
    padding:13px;
    border-radius:18px;
    border:1px solid #d8e8fb;
    background:#fff;
    color:var(--ink);
    text-align:left;
    box-shadow:0 10px 26px rgba(16,24,40,.06);
  }

  body:has(#formEntrega) .mobile-term-icon{
    width:42px;
    height:42px;
    min-width:42px;
    border-radius:14px;
    display:flex;
    align-items:center;
    justify-content:center;
    color:#0957b8;
    background:#eef6ff;
  }

  body:has(#formEntrega) .mobile-term-copy{
    flex:1;
    min-width:0;
  }

  body:has(#formEntrega) .mobile-term-copy strong{
    display:block;
    font-weight:900;
    line-height:1.15;
  }

  body:has(#formEntrega) .mobile-term-copy small{
    display:block;
    color:var(--muted);
    margin-top:2px;
  }

  body:has(#formEntrega) .mobile-term-state{
    width:34px;
    height:34px;
    min-width:34px;
    border-radius:12px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#f8fbff;
    color:#64748b;
  }

  body:has(#formEntrega) .mobile-term-state.ok{
    color:#15803d;
    background:#eaf8ef;
  }

  .mobile-term-modal .modal-header,
  .mobile-term-modal .modal-footer{
    border-color:#e7ebf2;
  }

  .mobile-term-modal .modal-body{
    font-size:.95rem;
    line-height:1.45;
  }

  /* Assinatura e finalizar */
  body:has(#formEntrega) .under-term-actions{
    display:block!important;
  }

  body:has(#formEntrega) .under-term-actions > .delivery-summary:first-child{
    display:block!important;
    margin-bottom:12px!important;
  }

  body:has(#formEntrega) .under-term-actions > .delivery-summary:first-child .p-3{
    padding:12px!important;
  }

  body:has(#formEntrega) .signature-pad-large{
    height:170px!important;
    min-height:170px!important;
    border-radius:16px!important;
  }

  body:has(#formEntrega) #clearSignature{
    min-height:42px!important;
  }

  body:has(#formEntrega) #submitEntrega{
    min-height:50px!important;
    border-radius:16px!important;
  }

  body:has(#formEntrega) .under-term-actions > .delivery-summary:first-child small.text-muted{
    display:none!important;
  }

  /* Biometria e LGPD fica no fim da tela, sem foto */
  body:has(#formEntrega) .delivery-side .lgpd-note,
  body:has(#formEntrega) .lgpd-note.compact{
    display:flex!important;
  }

  body:has(#formEntrega) .under-term-actions::after{
    content:'Biometria e LGPD: a imagem facial será usada somente para comprovação da entrega de EPI, auditoria, segurança do trabalho e defesa de direitos.';
    display:block;
    padding:12px 13px 12px 44px;
    margin-top:12px;
    border:1px solid #d8e8fb;
    border-radius:18px;
    background:linear-gradient(180deg,#ffffff,#f7fbff);
    color:#46566f;
    font-size:.78rem;
    line-height:1.32;
    position:relative;
  }

  body:has(#formEntrega) .under-term-actions::before{
    content:'\F47B';
    font-family:'bootstrap-icons';
    position:absolute;
    margin-top:24px;
    margin-left:14px;
    z-index:1;
    color:#0957b8;
    font-size:1rem;
  }
}


/* V45 - Mobile: Itens da entrega sem estourar e com nome completo */
@media(max-width:767px){
  body:has(#formEntrega) .item-row{
    display:grid!important;
    grid-template-columns:32px minmax(0,1fr)!important;
    gap:8px!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }

  body:has(#formEntrega) .delivery-item-body{
    min-width:0!important;
    max-width:100%!important;
    overflow:hidden!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) 74px 42px!important;
    gap:7px!important;
    width:100%!important;
    max-width:100%!important;
    margin:0!important;
    align-items:stretch!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div{
    min-width:0!important;
    max-width:100%!important;
    padding:0!important;
  }

  body:has(#formEntrega) .epi-modal-button{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    min-height:58px!important;
    height:auto!important;
    align-items:center!important;
    overflow:hidden!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-content{
    min-width:0!important;
    max-width:100%!important;
    flex:1 1 auto!important;
    overflow:hidden!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-content strong{
    display:block!important;
    white-space:normal!important;
    overflow:visible!important;
    overflow-wrap:anywhere!important;
    word-break:normal!important;
    text-overflow:clip!important;
    max-height:none!important;
    line-height:1.18!important;
    font-size:.86rem!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-content small{
    display:block!important;
    white-space:normal!important;
    overflow:hidden!important;
    overflow-wrap:anywhere!important;
    text-overflow:clip!important;
    max-height:2.35em!important;
    line-height:1.15!important;
    font-size:.68rem!important;
    opacity:.78!important;
    margin-top:2px!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-icon{
    flex:0 0 34px!important;
  }

  body:has(#formEntrega) .epi-modal-button .modal-select-arrow{
    flex:0 0 28px!important;
  }

  body:has(#formEntrega) .qtd-input{
    width:74px!important;
    max-width:74px!important;
    min-width:0!important;
  }

  body:has(#formEntrega) .btn-remove-epi{
    width:42px!important;
    max-width:42px!important;
    min-width:42px!important;
  }
}

@media(max-width:420px){
  body:has(#formEntrega) .delivery-item-body > .row{
    grid-template-columns:minmax(0,1fr)!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(1){
    grid-column:1!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(2),
  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(3){
    grid-column:auto!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row{
    grid-template-columns:1fr 42px!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(1){
    grid-column:1 / -1!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(2){
    grid-column:1!important;
  }

  body:has(#formEntrega) .delivery-item-body > .row > div:nth-child(3){
    grid-column:2!important;
  }

  body:has(#formEntrega) .qtd-input{
    width:100%!important;
    max-width:100%!important;
  }
}


/* V46 - Mobile: apenas o termo azul e modal com rolagem/aceite */
@media(max-width:767px){
  body.page-entrega-nova .term-panel-desktop{
    display:none!important;
  }

  body.page-entrega-nova #mobileTermCard.mobile-term-card{
    display:block!important;
    margin:0 0 12px!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-button{
    width:100%!important;
    display:flex!important;
    align-items:center!important;
    gap:10px!important;
    padding:13px!important;
    border-radius:18px!important;
    border:1px solid #b9d7ff!important;
    background:linear-gradient(180deg,#ffffff,#f0f7ff)!important;
    color:var(--ink)!important;
    text-align:left!important;
    box-shadow:0 10px 26px rgba(9,87,184,.10)!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-icon{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    border-radius:14px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    color:#0957b8!important;
    background:#e4f1ff!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-copy{
    flex:1!important;
    min-width:0!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-copy strong{
    display:block!important;
    font-weight:900!important;
    line-height:1.15!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-copy small{
    display:block!important;
    color:#50617a!important;
    margin-top:2px!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-state{
    width:34px!important;
    height:34px!important;
    min-width:34px!important;
    border-radius:12px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    background:#ffffff!important;
    color:#0957b8!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-state.ok{
    color:#15803d!important;
    background:#eaf8ef!important;
  }

  #modalTermoMobile .mobile-term-dialog{
    max-width:calc(100vw - 18px)!important;
    margin:.75rem auto!important;
  }

  #modalTermoMobile .mobile-term-modal{
    border:0!important;
    border-radius:22px!important;
    overflow:hidden!important;
    max-height:calc(100dvh - 24px)!important;
  }

  #modalTermoMobile .modal-header{
    flex:0 0 auto!important;
    padding:16px!important;
    border-bottom:1px solid #e7ebf2!important;
  }

  #modalTermoMobile .modal-body{
    max-height:calc(100dvh - 190px)!important;
    overflow-y:auto!important;
    -webkit-overflow-scrolling:touch!important;
    padding:16px!important;
    font-size:.94rem!important;
    line-height:1.45!important;
  }

  #modalTermoMobile .modal-footer{
    flex:0 0 auto!important;
    padding:12px 16px 16px!important;
    border-top:1px solid #e7ebf2!important;
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:10px!important;
  }

  #modalTermoMobile .modal-footer .btn{
    width:100%!important;
    min-height:44px!important;
  }

  /* Segurança extra: se algum navegador não aplicar :has, estes seletores escondem o termo antigo pelo painel marcado */
  .term-panel-desktop{
    display:none!important;
  }
}

@media(min-width:768px){
  .term-panel-desktop{
    display:block!important;
  }
  #mobileTermCard{
    display:none!important;
  }
}


/* V47 - Correção do modal do termo e alertas de finalização */
@media(max-width:767px){
  body.page-entrega-nova #mobileTermCard,
  body.page-entrega-nova #mobileTermCard .mobile-term-button{
    cursor:pointer!important;
    pointer-events:auto!important;
  }

  #modalTermoMobile{
    z-index:3060!important;
  }

  #modalTermoMobile .modal-dialog{
    max-width:calc(100vw - 18px)!important;
    margin:.75rem auto!important;
  }

  #modalTermoMobile .mobile-term-modal{
    max-height:calc(100dvh - 24px)!important;
    border:0!important;
    border-radius:22px!important;
    overflow:hidden!important;
    box-shadow:0 28px 70px rgba(16,24,40,.22)!important;
  }

  #modalTermoMobile .modal-body{
    max-height:calc(100dvh - 205px)!important;
    overflow-y:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }

  #modalTermoMobile .modal-footer{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:10px!important;
  }

  #modalTermoMobile .modal-footer .btn{
    width:100%!important;
    min-height:44px!important;
  }
}


/* V48 - cliques mobile no termo e botão finalizar */
@media(max-width:767px){
  body.page-entrega-nova.mobile-form-clickable .delivery-form{
    opacity:1!important;
    pointer-events:auto!important;
  }

  body.page-entrega-nova.mobile-form-clickable #faceIdGate.d-none,
  body.page-entrega-nova.mobile-form-clickable .face-id-gate.d-none{
    display:none!important;
    pointer-events:none!important;
  }

  body.page-entrega-nova #mobileTermCard,
  body.page-entrega-nova #mobileTermCard *,
  body.page-entrega-nova #submitEntrega{
    pointer-events:auto!important;
    touch-action:manipulation!important;
    -webkit-tap-highlight-color:rgba(9,87,184,.16)!important;
  }

  body.page-entrega-nova #mobileTermCard{
    position:relative!important;
    z-index:20!important;
  }

  body.page-entrega-nova #mobileTermCard .mobile-term-button{
    position:relative!important;
    z-index:21!important;
  }

  #modalTermoMobile{
    z-index:3065!important;
  }

  #modalTermoMobile.show{
    display:block!important;
  }

  #modalTermoMobile .modal-dialog{
    pointer-events:auto!important;
  }

  #modalTermoMobile .modal-content{
    pointer-events:auto!important;
  }

  #manualTermBackdrop{
    z-index:3050!important;
  }
}


/* V49 - modal do termo criado dinamicamente */
@media(max-width:767px){
  #modalTermoMobile{
    z-index:3065!important;
  }
  #modalTermoMobile.show{
    display:block!important;
  }
  #modalTermoMobile .mobile-term-dialog{
    max-width:calc(100vw - 18px)!important;
    margin:.75rem auto!important;
  }
  #modalTermoMobile .mobile-term-modal{
    max-height:calc(100dvh - 24px)!important;
    border:0!important;
    border-radius:22px!important;
    overflow:hidden!important;
    box-shadow:0 28px 70px rgba(16,24,40,.22)!important;
  }
  #modalTermoMobile .modal-body{
    max-height:calc(100dvh - 205px)!important;
    overflow-y:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }
  #modalTermoMobile .modal-footer{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:10px!important;
  }
  #modalTermoMobile .modal-footer .btn{
    width:100%!important;
    min-height:44px!important;
  }
}


/* V50 - Cadastro de colaborador usando o mesmo Face ID da Nova Entrega */
.colab-faceid-modal .bank-face-header.minimal{
  min-height:58px;
  padding:12px 16px;
}
.colab-faceid-modal .bank-face-header.minimal h5::after{
  content:' - Cadastro facial do colaborador';
  font-weight:700;
  color:#64748b;
  font-size:.92rem;
}
.colab-faceid-modal .bank-face-bottom-hint{
  bottom:82px;
}
.colab-faceid-modal .bank-face-footer{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
}
.colab-faceid-modal .bank-face-footer #captureColabFaceModal{
  grid-column:1 / -1;
  order:3;
  min-height:46px;
}
.colab-faceid-modal .bank-face-flip-btn{
  top:70px;
  left:14px;
}
.colab-face-preview{
  aspect-ratio:9/16!important;
  width:min(170px,100%)!important;
  height:auto!important;
  max-height:300px!important;
  object-fit:cover!important;
  object-position:center top!important;
  border-radius:20px!important;
  display:block;
  margin:0 auto;
}
.colab-face-capture{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:250px;
}
@media(max-width:767px){
  .colab-faceid-modal .modal-dialog{
    width:100vw!important;
    max-width:100vw!important;
    min-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    margin:0!important;
    padding:0!important;
    transform:none!important;
  }
  .colab-faceid-modal .bank-face-content{
    width:100vw!important;
    max-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    border-radius:0!important;
  }
  .colab-faceid-modal .bank-face-video{
    transform:scaleX(-1) scale(.88)!important;
  }
  .colab-faceid-modal .bank-face-oval{
    width:min(265px,64vw)!important;
    height:min(360px,49dvh)!important;
  }
  .colab-faceid-modal .bank-face-footer{
    grid-template-columns:1fr!important;
    padding:16px 20px 22px!important;
  }
  .colab-faceid-modal .bank-face-footer #captureColabFaceModal{
    grid-column:1!important;
  }
  .colab-faceid-modal .bank-face-footer .btn{
    width:100%!important;
    min-height:48px!important;
  }
}


/* V51 - bloqueio de face duplicada no colaborador */
.colab-faceid-modal .bank-face-oval.error{
  border-color:#ef4444!important;
  box-shadow:0 0 0 6px rgba(239,68,68,.18)!important;
}


/* V52 - validação mais forte de face duplicada */
.faceapi-status.duplicate{
  background:#fff1f2!important;
  color:#b42318!important;
  border-color:#fecdd3!important;
}


/* V53 - Face ID antes do formulário e modal de aviso do site */
.colab-face-first-gate{
  display:none;
}
.colab-site-notice{
  border:0;
  border-radius:24px;
  overflow:hidden;
  box-shadow:0 30px 80px rgba(16,24,40,.24);
}
.colab-site-notice .modal-header{
  border-bottom:1px solid #e7ebf2;
  background:linear-gradient(180deg,#ffffff,#f8fbff);
}
.colab-site-notice-body{
  display:flex;
  align-items:flex-start;
  gap:14px;
}
.colab-site-notice-icon{
  width:48px;
  height:48px;
  min-width:48px;
  border-radius:16px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#fff7e6;
  color:#b76b00;
  font-size:1.35rem;
}
.colab-site-notice-icon.danger{
  background:#fff1f2;
  color:#b42318;
}
.colab-site-notice-body p{
  margin:0;
  color:#344054;
  line-height:1.45;
}
body.colab-face-first-active #colabFormCard.colab-form-locked{
  opacity:.35;
  filter:blur(1px);
  pointer-events:none;
  user-select:none;
}
body.colab-face-first-active .colab-face-first-gate{
  display:block;
}
.colab-face-first-card{
  border:1px solid #b9d7ff;
  background:linear-gradient(180deg,#ffffff,#f0f7ff);
  border-radius:24px;
  padding:20px;
  margin-bottom:18px;
  text-align:center;
  box-shadow:0 16px 42px rgba(9,87,184,.10);
}
.colab-face-first-icon{
  width:62px;
  height:62px;
  border-radius:22px;
  display:flex;
  align-items:center;
  justify-content:center;
  margin:0 auto 12px;
  background:#e4f1ff;
  color:#0957b8;
  font-size:1.8rem;
}
.colab-face-first-card strong{
  display:block;
  font-size:1.2rem;
  font-weight:900;
  color:var(--ink);
}
.colab-face-first-card span{
  display:block;
  color:var(--muted);
  margin-top:4px;
}
@media(max-width:767px){
  body.colab-face-first-active .module-hero,
  body.colab-face-first-active .hero-kpis,
  body.colab-face-first-active .data-card{
    display:none!important;
  }
  body.colab-face-first-active #colabFormCard.colab-form-locked{
    display:none!important;
  }
  .colab-face-first-card{
    margin:12px 0 16px;
  }
}


/* V54 - Botão Excluir colaborador */
.table-actions{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:6px;
  flex-wrap:wrap;
}
.btn-excluir-colaborador{
  font-weight:800;
}
@media(max-width:767px){
  .table-actions{
    justify-content:flex-start;
    min-width:260px;
  }
  .table-actions .btn{
    padding:.34rem .55rem;
  }
}


/* V55 - Submenu de colaboradores e páginas separadas */
.sidebar-submenu{
  display:block;
  margin:2px 0;
}
.sidebar-submenu > summary{
  list-style:none;
  cursor:pointer;
  display:flex;
  align-items:center;
  gap:11px;
  padding:11px 14px;
  border-radius:16px;
  color:#d8e7ff;
  font-weight:800;
  user-select:none;
  transition:.18s;
}
.sidebar-submenu > summary::-webkit-details-marker{
  display:none;
}
.sidebar-submenu > summary:hover,
.sidebar-submenu.active > summary{
  background:rgba(255,255,255,.10);
  color:#fff;
}
.sidebar-submenu > summary i:first-child{
  width:22px;
  text-align:center;
}
.sidebar-submenu .submenu-caret{
  margin-left:auto;
  font-size:.82rem;
  transition:.18s;
}
.sidebar-submenu[open] .submenu-caret{
  transform:rotate(180deg);
}
.submenu-items{
  display:grid;
  gap:4px;
  margin:4px 0 8px 34px;
  padding-left:10px;
  border-left:1px solid rgba(255,255,255,.14);
}
.submenu-items a{
  min-height:36px!important;
  padding:8px 10px!important;
  border-radius:12px!important;
  font-size:.92rem;
}
.submenu-items a i{
  width:18px!important;
}
.page-colaborador-novo .colab-face-first-card{
  max-width:680px;
  margin-left:auto;
  margin-right:auto;
}
@media(max-width:767px){
  .submenu-items{
    margin-left:28px;
  }
}


/* V50 - Face ID: manter trava e garantir modal acima do overlay */
body.face-modal-open #modalDeliveryFaceCamera{
  z-index:3060!important;
}
body.face-modal-open .modal-backdrop.show{
  z-index:3050!important;
}
#startFaceGateButton{
  position:relative;
  z-index:1;
}


/* V43 - Corrige espelhamento: camera traseira da entrega sem inverter direita/esquerda */
#modalDeliveryFaceCamera.face-camera-rear .bank-face-video,
#modalDeliveryFaceCamera.face-camera-rear video.bank-face-video,
body #modalDeliveryFaceCamera.face-camera-rear .bank-face-viewport .bank-face-video{
  transform:scale(.92)!important;
  transform-origin:center center!important;
}
#modalDeliveryFaceCamera.face-camera-front .bank-face-video,
#modalDeliveryFaceCamera.face-camera-front video.bank-face-video,
body #modalDeliveryFaceCamera.face-camera-front .bank-face-viewport .bank-face-video{
  transform:scaleX(-1) scale(.92)!important;
  transform-origin:center center!important;
}
@media(max-width:767px){
  #modalDeliveryFaceCamera.face-camera-rear .bank-face-video,
  #modalDeliveryFaceCamera.face-camera-rear video.bank-face-video,
  body #modalDeliveryFaceCamera.face-camera-rear .bank-face-viewport .bank-face-video{
    transform:scale(.88)!important;
  }
  #modalDeliveryFaceCamera.face-camera-front .bank-face-video,
  #modalDeliveryFaceCamera.face-camera-front video.bank-face-video,
  body #modalDeliveryFaceCamera.face-camera-front .bank-face-viewport .bank-face-video{
    transform:scaleX(-1) scale(.88)!important;
  }
}

/* V57 - Avisos do Face ID acima do modal da camera */
#deliveryFaceNoticeModal{
  z-index:3090!important;
}
#deliveryFaceNoticeModal + .modal-backdrop{
  z-index:3080!important;
}
#deliveryFaceNoticeModal .modal-dialog{
  pointer-events:auto!important;
}

/* V58 - Aviso de duplicidade acima do modal de cadastro facial */
#colabSiteNoticeModal{
  z-index:3090!important;
}
#colabSiteNoticeModal + .modal-backdrop{
  z-index:3080!important;
}
#colabSiteNoticeModal .modal-dialog{
  pointer-events:auto!important;
}

/* Admin Master Premium */
.admin-master-tabs{display:flex;gap:.75rem;flex-wrap:wrap;align-items:center;background:rgba(255,255,255,.75);border:1px solid rgba(15,23,42,.08);border-radius:24px;padding:.6rem;box-shadow:0 18px 45px rgba(15,23,42,.06);backdrop-filter:blur(10px)}
.admin-master-tab{display:inline-flex;align-items:center;gap:.5rem;padding:.75rem 1rem;border-radius:18px;color:#334155;text-decoration:none;font-weight:700;transition:.2s ease;background:transparent}
.admin-master-tab:hover{background:#f1f5f9;color:#0f172a;transform:translateY(-1px)}
.admin-master-tab.active{background:linear-gradient(135deg,#0f172a,#1d4ed8);color:#fff;box-shadow:0 14px 30px rgba(29,78,216,.22)}
.admin-master-hero{background:linear-gradient(135deg,#0f172a,#1e3a8a 45%,#2563eb);color:#fff;border:0;box-shadow:0 24px 65px rgba(15,23,42,.18)}
.admin-master-hero .eyebrow,.admin-master-hero p{color:rgba(255,255,255,.82)}
.admin-master-hero .badge{border-color:rgba(255,255,255,.25)}
.admin-resource-card{display:block;height:100%;text-decoration:none;color:#0f172a;background:#fff;border:1px solid rgba(15,23,42,.08);border-radius:28px;padding:1.5rem;box-shadow:0 18px 45px rgba(15,23,42,.07);transition:.2s ease}
.admin-resource-card:hover{transform:translateY(-3px);box-shadow:0 26px 70px rgba(15,23,42,.12);color:#0f172a}
.admin-resource-card i{display:inline-flex;width:48px;height:48px;align-items:center;justify-content:center;border-radius:18px;background:#eff6ff;color:#1d4ed8;font-size:1.4rem;margin-bottom:1rem}
.admin-resource-card strong{display:block;font-size:1.1rem;margin-bottom:.35rem}.admin-resource-card span{color:#64748b}.mini-kpi.premium{border:1px solid rgba(15,23,42,.08);box-shadow:0 18px 45px rgba(15,23,42,.06)}
.admin-module-card{height:100%;background:#fff;border:1px solid rgba(15,23,42,.08);border-radius:24px;padding:1.25rem;box-shadow:0 18px 45px rgba(15,23,42,.06)}
.admin-module-card .admin-module-icon{width:42px;height:42px;border-radius:16px;background:#f1f5f9;display:flex;align-items:center;justify-content:center;color:#1d4ed8;margin-bottom:.85rem}
.admin-module-card strong{display:block;font-size:1rem}.admin-module-card code{display:inline-block;margin:.35rem 0 .55rem;padding:.2rem .5rem;border-radius:.5rem;background:#f8fafc;color:#475569}.admin-module-card span{display:block;color:#64748b;font-size:.9rem}

/* Admin Master - Mais opções em modal para não gerar rolagem na tabela */
.btn-action-sheet{
  display:inline-flex;
  align-items:center;
  gap:.35rem;
  border-radius:999px;
  font-weight:700;
  white-space:nowrap;
}
.admin-options-modal{
  z-index:3085!important;
}
.admin-options-modal + .modal-backdrop{
  z-index:3080!important;
}
.admin-options-card{
  border:1px solid rgba(15,23,42,.08);
  box-shadow:0 28px 90px rgba(15,23,42,.25);
}
.admin-options-card .btn{
  border-radius:16px;
  padding:.78rem .95rem;
  font-weight:700;
}
.admin-options-card .btn i{
  width:1.15rem;
  text-align:center;
}
@media(max-width:575px){
  .admin-options-modal .modal-dialog{
    margin:.75rem;
  }
  .btn-action-sheet{
    padding:.45rem .65rem;
  }
}

/* V58 - Correção Nova Entrega: seletores estáveis, sem instruções quebradas */
body:has(#formEntrega) .selector-grid > [class*="col-"]{
  min-width:0!important;
}
body:has(#formEntrega) .selector-grid .modal-select-card{
  min-height:64px!important;
  height:auto!important;
  align-items:center!important;
  overflow:hidden!important;
}
body:has(#formEntrega) .selector-grid .modal-select-content{
  min-width:0!important;
  overflow:hidden!important;
}
body:has(#formEntrega) .selector-grid .modal-select-content strong{
  display:block!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  line-height:1.18!important;
}
body:has(#formEntrega) .selector-grid .modal-select-content small{
  display:none!important;
}
body:has(#formEntrega) .selector-grid .modal-select-icon,
body:has(#formEntrega) .selector-grid .modal-select-arrow{
  flex-shrink:0!important;
}
body:has(#formEntrega) .selector-modal{
  z-index:1085!important;
}
body:has(#formEntrega) .selector-modal .selector-option-card,
body:has(#formEntrega) .selector-modal .epi-modal-card{
  cursor:pointer!important;
}
@media (min-width:992px){
  body:has(#formEntrega) .selector-grid > .col-lg-4{
    flex:0 0 33.333333%!important;
    max-width:33.333333%!important;
  }
}
@media (max-width:767px){
  body:has(#formEntrega) .selector-grid .modal-select-card{
    min-height:56px!important;
  }
  body:has(#formEntrega) .selector-grid .modal-select-content strong{
    font-size:.92rem!important;
  }
}

/* Modal próprio do sistema (substitui alert/confirm nativos do navegador) */
.app-system-modal{z-index:4200;}
.app-system-modal-backdrop{z-index:4190;}
.app-system-modal .modal-dialog{max-width:460px;}
.app-system-modal-content{border:0;border-radius:24px;box-shadow:0 24px 80px rgba(15,23,42,.24);overflow:hidden;}
.app-system-modal-header{border:0;padding:22px 22px 12px;display:flex;align-items:center;gap:14px;background:linear-gradient(135deg,#f8fafc,#eef4ff);}
.app-system-modal-header .btn-close{margin-left:auto;}
.app-system-modal-icon{width:46px;height:46px;border-radius:16px;display:grid;place-items:center;background:#e8f0ff;color:#1d4ed8;font-size:1.35rem;flex:0 0 auto;}
.app-system-modal-icon.danger{background:#fee2e2;color:#b91c1c;}
.app-system-modal .modal-title{font-weight:800;color:#172033;margin:0;}
.app-system-modal .modal-body{padding:10px 22px 18px;color:#475569;font-size:.98rem;line-height:1.5;}
.app-system-modal .modal-footer{border:0;padding:0 22px 22px;gap:10px;}
.app-system-modal .modal-footer .btn{border-radius:14px;font-weight:700;min-width:110px;}
@media (max-width:575.98px){.app-system-modal .modal-dialog{margin:1rem}.app-system-modal .modal-footer{display:grid;grid-template-columns:1fr;}.app-system-modal .modal-footer .btn{width:100%;}}


/* Contexto da empresa/filial no topo lateral */
.brand-context{margin-top:8px;padding-top:8px;border-top:1px solid rgba(255,255,255,.1);display:grid;gap:3px;max-width:178px}
.brand-context div{display:flex;align-items:center;gap:6px;color:#d7e5f6;font-size:.72rem;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.brand-context i{font-size:.78rem;color:#8ed7ff;flex:0 0 auto}
@media (max-width: 991px){.brand-context{max-width:210px}}

/* Entrega por dias / pacotes de EPIs */
.delivery-panel-icon.purple{background:linear-gradient(135deg,#7c3aed,#a855f7);color:#fff;}
.weekly-toggle{background:#f8fafc;border:1px solid #e2e8f0;border-radius:14px;padding:.75rem 1rem .75rem 3rem;}
.weekly-delivery-body{border-top:1px solid #e2e8f0;margin-top:1rem;padding-top:1rem;transition:.2s ease;}
.weekly-delivery-body.is-disabled{opacity:.52;filter:grayscale(.2);}
.weekly-days{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:.65rem;}
.weekly-day-pill{display:block;cursor:pointer;margin:0;}
.weekly-day-pill input{position:absolute;opacity:0;pointer-events:none;}
.weekly-day-pill span{display:flex;align-items:center;justify-content:center;border:1px solid #dbeafe;background:#fff;border-radius:999px;padding:.7rem .85rem;font-weight:700;color:#1e3a8a;box-shadow:0 6px 16px rgba(15,23,42,.06);transition:.18s ease;}
.weekly-day-pill input:checked + span{background:#0d6efd;color:#fff;border-color:#0d6efd;box-shadow:0 10px 22px rgba(13,110,253,.24);}
.weekly-day-pill.is-future-disabled{cursor:not-allowed;}
.weekly-day-pill.is-future-disabled span{background:#f1f5f9!important;border-color:#e2e8f0!important;color:#94a3b8!important;box-shadow:none!important;text-decoration:line-through;}
.weekly-day-pill.is-future-disabled span small{color:#94a3b8!important;opacity:.85;}
.weekly-day-pill.is-future-disabled span::after{content:'Bloqueado';font-size:.64rem;font-weight:900;letter-spacing:.04em;text-transform:uppercase;text-decoration:none;background:#e2e8f0;color:#64748b;border-radius:999px;padding:.12rem .42rem;margin-top:.12rem;}
.kit-builder{background:#f8fafc;border:1px solid #e2e8f0;border-radius:18px;padding:1rem;}
.kit-list{display:grid;gap:1rem;}
.kit-card{border:1px solid #e2e8f0;border-radius:20px;background:#fff;padding:1rem;box-shadow:0 10px 24px rgba(15,23,42,.05);}
.kit-card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;}
.kit-card-head p{margin:.25rem 0 0;color:#64748b;font-size:.9rem;}
.kit-items{display:flex;flex-wrap:wrap;gap:.5rem;margin-top:.85rem;}
.kit-items span{display:inline-flex;align-items:center;gap:.35rem;border:1px solid #e2e8f0;border-radius:999px;background:#f8fafc;padding:.45rem .7rem;font-size:.85rem;font-weight:700;color:#334155;}
.kit-items em{font-style:normal;color:#0d6efd;}
.weekly-sheet-card{background:#f8fbff;}
.weekly-sheet-days{display:flex;flex-wrap:wrap;gap:.5rem;}
.weekly-sheet-days span{border-radius:999px;background:#e0f2fe;color:#075985;padding:.45rem .7rem;font-weight:800;font-size:.85rem;}
@media (max-width: 767px){.kit-card-head{flex-direction:column}.weekly-days{grid-template-columns:repeat(2,1fr)}}

/* V31 - Ajustes Pacotes de EPIs: exclusão com modal próprio e cards sem quebra */
.kit-card{
  overflow:visible;
}
.kit-card-head{
  align-items:center;
}
.kit-card-title{
  min-width:0;
  flex:1 1 auto;
}
.kit-card-title strong{
  display:block;
  max-width:100%;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.kit-card-title p{
  max-width:100%;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.kit-card-actions{
  flex:0 0 auto;
  margin:0;
}
.btn-nowrap,
.kit-card-actions .btn{
  white-space:nowrap;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.35rem;
}
.kit-items span{
  max-width:100%;
  white-space:normal;
  word-break:normal;
  overflow-wrap:anywhere;
}
@media (max-width: 767px){
  .kit-card-head{
    align-items:stretch;
  }
  .kit-card-actions .btn{
    width:100%;
  }
  .kit-card-title strong,
  .kit-card-title p{
    white-space:normal;
  }
}

/* Entrega por dias - ficha e PDF/impressão */
.weekly-proof-layout{
  display:grid;
  grid-template-columns:minmax(0,1.6fr) minmax(240px,.9fr);
  gap:1rem;
  padding:1.15rem;
  border:1px solid rgba(13,110,253,.16);
  border-radius:22px;
  background:linear-gradient(135deg,#f8fbff 0%,#eef6ff 100%);
  box-shadow:0 16px 38px rgba(15,23,42,.08);
  margin-bottom:1rem;
}
.weekly-proof-main h3{font-size:1.25rem;margin:.25rem 0 .35rem;font-weight:900;color:#0f172a;}
.weekly-proof-main p{margin:0 0 .85rem;color:#475569;font-weight:600;}
.weekly-sheet-days-premium span{background:#0d6efd;color:#fff;border:1px solid rgba(255,255,255,.45);box-shadow:0 10px 22px rgba(13,110,253,.22);}
.weekly-proof-side{display:grid;gap:.65rem;}
.weekly-proof-info{background:#fff;border:1px solid #dbeafe;border-radius:16px;padding:.75rem .9rem;box-shadow:0 10px 24px rgba(15,23,42,.06);}
.weekly-proof-info small{display:block;color:#64748b;font-weight:800;text-transform:uppercase;letter-spacing:.04em;font-size:.68rem;margin-bottom:.15rem;}
.weekly-proof-info strong{display:block;color:#0f172a;font-size:.95rem;line-height:1.2;}
.weekly-proof-info span{display:block;color:#64748b;font-size:.8rem;margin-top:.2rem;line-height:1.25;}
.compact-items-table .col-source{width:120px;white-space:nowrap;}
@media (max-width: 767px){.weekly-proof-layout{grid-template-columns:1fr;padding:.9rem;border-radius:18px}.weekly-proof-side{grid-template-columns:1fr}.compact-items-table .col-source{min-width:110px}}
@media print{.weekly-proof-layout{box-shadow:none;background:#fff;border:1px solid #cbd5e1;break-inside:avoid}.weekly-proof-info{box-shadow:none}.weekly-sheet-days-premium span{background:#e0f2fe!important;color:#075985!important}}

/* V58 - Area segura para impressao/PDF da ficha de entrega
   Mantem folga visual mesmo quando o navegador esta em "Margens: Nenhuma". */
@page{
  size:A4 portrait;
  margin:12mm;
}
@media print{
  body:has(.delivery-sheet){
    background:#fff!important;
    -webkit-print-color-adjust:exact!important;
    print-color-adjust:exact!important;
  }
  body:has(.delivery-sheet) html,
  body:has(.delivery-sheet){
    width:auto!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
  }
  body:has(.delivery-sheet) .app-shell,
  body:has(.delivery-sheet) .content-wrap,
  body:has(.delivery-sheet) .page-container{
    width:100%!important;
    max-width:none!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
  }
  body:has(.delivery-sheet) .delivery-sheet{
    width:calc(100% - 16mm)!important;
    max-width:186mm!important;
    margin:0 auto!important;
    padding:0!important;
    border:0!important;
    box-shadow:none!important;
    overflow:visible!important;
  }
  body:has(.delivery-sheet) .delivery-sheet .sheet-inner{
    padding:4mm 5mm 5mm!important;
    margin:0!important;
    width:100%!important;
    max-width:100%!important;
    overflow:visible!important;
  }
  body:has(.delivery-sheet) .sheet-header,
  body:has(.delivery-sheet) .sheet-identity-grid,
  body:has(.delivery-sheet) .delivery-section,
  body:has(.delivery-sheet) .term-box,
  body:has(.delivery-sheet) .signature-audit-grid,
  body:has(.delivery-sheet) .audit-card-print{
    max-width:100%!important;
  }
  body:has(.delivery-sheet) .delivery-section,
  body:has(.delivery-sheet) .term-box,
  body:has(.delivery-sheet) .signature-audit-grid{
    break-inside:avoid!important;
    page-break-inside:avoid!important;
  }
  body:has(.delivery-sheet) .delivery-items-wrap,
  body:has(.delivery-sheet) .table-responsive{
    width:100%!important;
    max-width:100%!important;
    overflow:visible!important;
  }
  body:has(.delivery-sheet) .compact-items-table{
    width:100%!important;
    max-width:100%!important;
    table-layout:fixed!important;
  }
  body:has(.delivery-sheet) .compact-items-table th,
  body:has(.delivery-sheet) .compact-items-table td{
    overflow-wrap:anywhere!important;
  }
}

/* EPI descartavel */
.disposable-epi-option{
  border:1px solid #bcebd0;
  background:linear-gradient(135deg,#f0fdf4,#ffffff);
  border-radius:18px;
  padding:14px 16px;
}
.badge-descartavel{
  display:inline-flex;
  align-items:center;
  gap:4px;
  margin-left:6px;
  vertical-align:middle;
  white-space:nowrap;
}
.item-descartavel{
  background:linear-gradient(90deg,rgba(222,248,228,.46),transparent 70%);
}
.epi-modal-stock.disposable{
  background:#def8e4;
  color:#146b22;
}
.epi-modal-stock.disposable + .epi-modal-stock{
  top:52px;
}
@media(max-width:767px){
  .epi-modal-stock.disposable + .epi-modal-stock{
    top:auto;
  }
}

/* V35 - Pacotes de EPIs: cabeçalhos sem corte e edição de pacote */
.kits-page-row .kit-panel-card{
  height:100%;
  overflow:visible;
}
.kits-page-row .panel-header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:1rem;
  padding:20px 22px 0;
  min-width:0;
}
.kits-page-row .panel-header h5{
  margin:0;
  font-weight:900;
  letter-spacing:-.025em;
  line-height:1.2;
}
.kits-page-row .panel-header p{
  margin:.35rem 0 0;
  color:#64748b;
  line-height:1.35;
}
.kits-page-row .panel-body{
  padding:20px 22px 22px;
}
.kits-page-row .kit-builder{
  overflow:visible;
}
.kits-page-row .kit-item-row{
  margin-left:0;
  margin-right:0;
}
.kits-page-row .kit-item-row > [class*="col-"]{
  min-width:0;
}
.kit-card-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:.5rem;
  flex-wrap:nowrap;
}
.kit-card-actions form{
  margin:0;
}
.app-modal-content{
  border:0;
  border-radius:24px;
  box-shadow:0 30px 80px rgba(15,23,42,.28);
  overflow:hidden;
}
.app-modal-content .modal-header{
  align-items:flex-start;
  gap:1rem;
  background:linear-gradient(180deg,#fff,#f8fbff);
  border-bottom:1px solid #e7ebf2;
  padding:20px 22px;
}
.app-modal-content .modal-title{
  margin:.25rem 0 0;
  font-weight:900;
  letter-spacing:-.025em;
}
.modal-kicker{
  display:inline-flex;
  align-items:center;
  gap:.45rem;
  border-radius:999px;
  padding:.35rem .65rem;
  background:#eef6ff;
  color:#0957b8;
  font-size:.72rem;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.08em;
}
.app-modal-content .modal-body{
  padding:22px;
}
.app-modal-content .modal-footer{
  border-top:1px solid #e7ebf2;
  background:#fbfdff;
  padding:16px 22px;
}
@media (max-width: 767px){
  .kits-page-row .panel-header,
  .kits-page-row .panel-body{
    padding-left:16px;
    padding-right:16px;
  }
  .kit-card-actions{
    width:100%;
    justify-content:stretch;
    flex-wrap:wrap;
  }
  .kit-card-actions .btn,
  .kit-card-actions form{
    flex:1 1 140px;
  }
  .kit-card-actions .btn{
    width:100%;
  }
}

/* V60 - PDF/print mais legivel em todos os modos da ficha
   Prioriza nitidez e leitura: fonte maior, menos compactacao e area util maior. */
@page{
  size:A4 portrait;
  margin:8mm;
}
@media print{
  body:has(.delivery-sheet){
    font-size:11.5px!important;
    line-height:1.25!important;
    -webkit-print-color-adjust:exact!important;
    print-color-adjust:exact!important;
  }
  body:has(.delivery-sheet) .delivery-sheet{
    width:calc(100% - 4mm)!important;
    max-width:196mm!important;
    margin:0 auto!important;
    border:0!important;
    box-shadow:none!important;
    background:#fff!important;
  }
  body:has(.delivery-sheet) .delivery-sheet .sheet-inner{
    padding:3mm 3.5mm 4mm!important;
  }
  body:has(.delivery-sheet) .sheet-header{
    margin-bottom:8px!important;
    gap:10px!important;
  }
  body:has(.delivery-sheet) .sheet-logo{
    max-width:130px!important;
  }
  body:has(.delivery-sheet) .sheet-title h2{
    font-size:19px!important;
    line-height:1.12!important;
    margin-bottom:2px!important;
    letter-spacing:-.015em!important;
  }
  body:has(.delivery-sheet) .sheet-title .text-muted{
    font-size:10.2px!important;
    line-height:1.25!important;
  }
  body:has(.delivery-sheet) .sheet-status{
    font-size:9.2px!important;
    padding:4px 8px!important;
  }
  body:has(.delivery-sheet) .sheet-identity-grid{
    gap:8px!important;
    margin-bottom:8px!important;
  }
  body:has(.delivery-sheet) .compact-stat,
  body:has(.delivery-sheet) .mini-stat{
    padding:8px 10px!important;
    border-radius:9px!important;
    gap:7px!important;
  }
  body:has(.delivery-sheet) .compact-stat i,
  body:has(.delivery-sheet) .mini-stat i{
    font-size:13.5px!important;
  }
  body:has(.delivery-sheet) .compact-stat strong,
  body:has(.delivery-sheet) .mini-stat strong{
    font-size:10.4px!important;
    line-height:1.18!important;
  }
  body:has(.delivery-sheet) .compact-stat small,
  body:has(.delivery-sheet) .mini-stat small{
    font-size:8.8px!important;
    line-height:1.18!important;
  }
  body:has(.delivery-sheet) .delivery-section,
  body:has(.delivery-sheet) .term-box{
    margin-bottom:8px!important;
  }
  body:has(.delivery-sheet) .card-header-modern{
    padding:8px 10px!important;
  }
  body:has(.delivery-sheet) .card-header-modern h5{
    font-size:12.2px!important;
    line-height:1.15!important;
  }
  body:has(.delivery-sheet) .card-header-modern small{
    display:block!important;
    font-size:8.8px!important;
    line-height:1.15!important;
  }
  body:has(.delivery-sheet) .compact-items-table{
    font-size:9.7px!important;
    table-layout:fixed!important;
  }
  body:has(.delivery-sheet) .compact-items-table th,
  body:has(.delivery-sheet) .compact-items-table td{
    padding:4.2px 5px!important;
    line-height:1.16!important;
    vertical-align:middle!important;
  }
  body:has(.delivery-sheet) .compact-items-table thead th{
    font-size:8.1px!important;
    letter-spacing:.025em!important;
  }
  body:has(.delivery-sheet) .compact-items-table .item-main strong{
    font-size:9.9px!important;
    line-height:1.17!important;
  }
  body:has(.delivery-sheet) .compact-items-table .item-main small{
    font-size:8.1px!important;
    line-height:1.14!important;
    margin-top:2px!important;
  }
  body:has(.delivery-sheet) .badge,
  body:has(.delivery-sheet) .badge-descartavel{
    font-size:8px!important;
    padding:2.8px 5px!important;
    border-radius:7px!important;
  }
  body:has(.delivery-sheet) .weekly-proof-layout{
    padding:10px 12px!important;
    border-radius:13px!important;
  }
  body:has(.delivery-sheet) .weekly-proof-layout h5,
  body:has(.delivery-sheet) .weekly-proof-layout strong{
    font-size:11.2px!important;
    line-height:1.18!important;
  }
  body:has(.delivery-sheet) .weekly-proof-layout p,
  body:has(.delivery-sheet) .weekly-proof-layout small,
  body:has(.delivery-sheet) .weekly-proof-info span{
    font-size:9px!important;
    line-height:1.2!important;
  }
  body:has(.delivery-sheet) .weekly-sheet-days,
  body:has(.delivery-sheet) .weekly-sheet-days-premium{
    gap:5px!important;
  }
  body:has(.delivery-sheet) .weekly-sheet-days span,
  body:has(.delivery-sheet) .weekly-sheet-days-premium span{
    font-size:8.8px!important;
    padding:3.5px 6px!important;
  }
  body:has(.delivery-sheet) .term-box .panel-body{
    padding:8px 10px!important;
    font-size:9.8px!important;
    line-height:1.26!important;
  }
  body:has(.delivery-sheet) .term-box p{
    font-size:9.8px!important;
    line-height:1.26!important;
  }
  body:has(.delivery-sheet) .signature-audit-grid{
    grid-template-columns:38% 62%!important;
    gap:8px!important;
  }
  body:has(.delivery-sheet) .signature-card .panel-body,
  body:has(.delivery-sheet) .facial-card-print .panel-body,
  body:has(.delivery-sheet) .audit-card-print .panel-body{
    padding:8px 10px!important;
  }
  body:has(.delivery-sheet) .signature-card strong,
  body:has(.delivery-sheet) .facial-card-print .panel-body > strong,
  body:has(.delivery-sheet) .audit-card-print strong{
    font-size:10px!important;
    line-height:1.2!important;
  }
  body:has(.delivery-sheet) .signature-frame{
    min-height:72px!important;
    max-height:86px!important;
    margin-top:5px!important;
    padding:5px!important;
  }
  body:has(.delivery-sheet) .signature-frame img{
    max-height:70px!important;
  }
  body:has(.delivery-sheet) .audit-grid-compact{
    gap:4px!important;
    margin-top:5px!important;
  }
  body:has(.delivery-sheet) .audit-grid-compact .meta-item{
    padding:4.5px 5.5px!important;
  }
  body:has(.delivery-sheet) .audit-grid-compact .meta-item span{
    font-size:7.4px!important;
    line-height:1.05!important;
  }
  body:has(.delivery-sheet) .audit-grid-compact .meta-item strong{
    font-size:8.2px!important;
    line-height:1.08!important;
  }
  body:has(.delivery-sheet) .print-location-link,
  body:has(.delivery-sheet) .empty-note{
    font-size:8px!important;
    line-height:1.15!important;
    padding:4px 6px!important;
  }
}

.weekly-day-pill span{flex-direction:column;line-height:1.1;min-height:54px;gap:.18rem;}
.weekly-day-pill span small{display:block;font-size:.72rem;font-weight:800;opacity:.78;}
.weekly-day-pill input:checked + span small{opacity:.95;color:rgba(255,255,255,.92);}
.weekly-delivery-panel input[readonly]{background:#f8fafc;color:#0f172a;font-weight:800;}


/* Spinner global de navegação e ações: somente o ícone, sem texto, caixa ou modal. */
.app-global-spinner{
  position:fixed;
  inset:0;
  z-index:4000;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  background:transparent;
  backdrop-filter:none;
  -webkit-backdrop-filter:none;
  pointer-events:all;
}
.app-global-spinner[hidden]{display:none!important;}
.app-global-spinner-ring{
  width:46px;
  height:46px;
  flex:0 0 46px;
  border-radius:50%;
  border:4px solid rgba(37,99,235,.16);
  border-top-color:#2563eb;
  border-right-color:#16a34a;
  animation:appSpinnerRotate .72s linear infinite;
  box-shadow:0 0 0 7px rgba(37,99,235,.07);
}
.app-is-loading{cursor:progress!important;}
.app-is-loading a,
.app-is-loading button{cursor:progress!important;}
@keyframes appSpinnerRotate{to{transform:rotate(360deg);}}
@media (max-width:575.98px){
  .app-global-spinner{padding:18px;}
  .app-global-spinner-ring{width:40px;height:40px;flex-basis:40px;}
}


/* V42 - Face ID moderno com escaneamento visual e Amazon Rekognition */
.bank-face-modern .modal-dialog{
  max-width:840px;
}
.bank-face-modern .bank-face-content{
  border-radius:32px;
  background:#07111f;
  box-shadow:0 34px 100px rgba(4,12,28,.42);
}
.bank-face-modern .bank-face-modern-header{
  border:0;
  background:linear-gradient(135deg,#ffffff 0%,#f4f9ff 64%,#eaf3ff 100%);
  padding:18px 22px;
}
.bank-face-modern .bank-face-modern-header p{
  margin:.2rem 0 0;
  font-size:.86rem;
  color:#64748b;
  font-weight:650;
}
.face-ai-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  min-height:28px;
  padding:5px 10px;
  border-radius:999px;
  background:rgba(9,87,184,.1);
  color:#0957b8;
  border:1px solid rgba(9,87,184,.16);
  font-size:.72rem;
  font-weight:950;
  letter-spacing:.06em;
  text-transform:uppercase;
}
.bank-face-modern .bank-face-body{
  padding:16px;
  background:radial-gradient(circle at 50% 0%,rgba(18,112,255,.22),rgba(7,17,31,0) 34%),#07111f;
}
.face-scan-statusbar{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px;
  margin:0 0 12px;
}
.face-scan-step{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  min-height:38px;
  padding:8px 9px;
  border-radius:14px;
  background:rgba(255,255,255,.065);
  border:1px solid rgba(255,255,255,.1);
  color:rgba(232,240,255,.72);
  font-size:.78rem;
  font-weight:900;
  white-space:nowrap;
}
.face-scan-step.active{
  color:#fff;
  background:rgba(9,87,184,.36);
  border-color:rgba(89,162,255,.54);
  box-shadow:0 0 0 3px rgba(9,87,184,.14);
}
.face-scan-step.done{
  color:#d8ffe2;
  background:rgba(34,197,94,.18);
  border-color:rgba(34,197,94,.42);
}
.face-scan-step.error{
  color:#ffe2e2;
  background:rgba(239,68,68,.22);
  border-color:rgba(239,68,68,.48);
}
.face-scan-viewport{
  height:540px;
  border:1px solid rgba(255,255,255,.12);
  background:#020617;
}
.face-scan-viewport::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:linear-gradient(180deg,rgba(255,255,255,.08),rgba(255,255,255,0) 16%,rgba(255,255,255,0) 82%,rgba(255,255,255,.08));
  mix-blend-mode:screen;
}
.face-scan-grid{
  position:absolute;
  inset:0;
  z-index:1;
  pointer-events:none;
  opacity:.16;
  background-image:linear-gradient(rgba(255,255,255,.18) 1px, transparent 1px),linear-gradient(90deg,rgba(255,255,255,.18) 1px, transparent 1px);
  background-size:34px 34px;
}
.face-scan-glow{
  position:absolute;
  left:50%;
  top:50%;
  z-index:2;
  width:340px;
  height:430px;
  transform:translate(-50%,-50%);
  border-radius:50%;
  background:radial-gradient(ellipse at center,rgba(44,211,111,.18),rgba(9,87,184,.08) 48%,transparent 70%);
  filter:blur(5px);
  pointer-events:none;
  animation:facePulse 2.4s ease-in-out infinite;
}
.face-scan-line{
  position:absolute;
  left:50%;
  top:14%;
  z-index:4;
  width:min(330px,70%);
  height:3px;
  transform:translateX(-50%);
  border-radius:999px;
  background:linear-gradient(90deg,transparent,#67e8f9,#22c55e,#67e8f9,transparent);
  box-shadow:0 0 18px rgba(34,197,94,.85),0 0 38px rgba(9,87,184,.45);
  opacity:.88;
  pointer-events:none;
  animation:faceScanLine 2.25s ease-in-out infinite;
}
.bank-face-modern .bank-face-overlay{
  z-index:5;
  background:radial-gradient(ellipse 36% 45% at 50% 48%,transparent 0%,transparent 50%,rgba(3,8,20,.22) 54%,rgba(3,8,20,.78) 100%);
}
.bank-face-modern .bank-face-oval{
  border-width:3px;
  border-color:rgba(34,197,94,.95);
  box-shadow:0 0 0 999px rgba(0,0,0,.02),0 0 34px rgba(34,197,94,.58),inset 0 0 22px rgba(34,197,94,.12);
}
.bank-face-modern .bank-face-oval::before,
.bank-face-modern .bank-face-oval::after{
  display:none;
}
.face-scan-corner{
  position:absolute;
  width:44px;
  height:44px;
  border-color:#7dd3fc;
  filter:drop-shadow(0 0 10px rgba(125,211,252,.78));
}
.face-scan-corner.tl{left:-7px;top:-7px;border-left:4px solid;border-top:4px solid;border-top-left-radius:24px}
.face-scan-corner.tr{right:-7px;top:-7px;border-right:4px solid;border-top:4px solid;border-top-right-radius:24px}
.face-scan-corner.bl{left:-7px;bottom:-7px;border-left:4px solid;border-bottom:4px solid;border-bottom-left-radius:24px}
.face-scan-corner.br{right:-7px;bottom:-7px;border-right:4px solid;border-bottom:4px solid;border-bottom-right-radius:24px}
.face-scan-quality{
  position:absolute;
  top:18px;
  left:50%;
  transform:translateX(-50%);
  max-width:calc(100% - 120px);
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:9px 13px;
  border-radius:999px;
  background:rgba(6,12,24,.68);
  border:1px solid rgba(255,255,255,.16);
  color:#fff;
  backdrop-filter:blur(12px);
  font-size:.82rem;
  font-weight:900;
  text-align:center;
  box-shadow:0 12px 30px rgba(0,0,0,.18);
}
.face-scan-quality.ok{background:rgba(22,101,52,.72);border-color:rgba(134,239,172,.5)}
.face-scan-quality.warn{background:rgba(120,53,15,.72);border-color:rgba(251,191,36,.42)}
.face-scan-quality.error{background:rgba(127,29,29,.78);border-color:rgba(252,165,165,.48)}
.bank-face-modern .bank-face-bottom-hint{
  bottom:22px;
  background:rgba(2,6,23,.72);
  border-color:rgba(255,255,255,.16);
}
.face-scan-progress{
  height:8px;
  margin:12px 4px 0;
  border-radius:999px;
  overflow:hidden;
  background:rgba(255,255,255,.09);
  border:1px solid rgba(255,255,255,.12);
}
.face-scan-progress span{
  display:block;
  width:0%;
  height:100%;
  border-radius:999px;
  background:linear-gradient(90deg,#0957b8,#22c55e,#67e8f9);
  box-shadow:0 0 18px rgba(34,197,94,.55);
  transition:width .28s ease;
}
.bank-face-modern .bank-face-footer{
  background:linear-gradient(180deg,#fff,#f8fbff);
  border-top:1px solid rgba(226,232,240,.9);
}
.bank-face-modern .bank-face-footer .btn-success{
  background:linear-gradient(135deg,#16a34a,#22c55e);
  border:0;
  box-shadow:0 10px 24px rgba(34,197,94,.22);
}
.bank-face-modern .bank-face-footer .btn-success:disabled{
  box-shadow:none;
}
@keyframes faceScanLine{
  0%,100%{top:15%;opacity:.45}
  50%{top:78%;opacity:1}
}
@keyframes facePulse{
  0%,100%{opacity:.52;transform:translate(-50%,-50%) scale(.96)}
  50%{opacity:1;transform:translate(-50%,-50%) scale(1.04)}
}
@media(max-width:767px){
  .bank-face-modern .bank-face-body{padding:10px;display:block}
  .face-scan-statusbar{gap:6px;margin-bottom:8px}
  .face-scan-step{font-size:.68rem;min-height:34px;padding:6px 5px;gap:4px}
  .face-scan-viewport{height:calc(100dvh - 214px);border-radius:20px}
  .face-scan-quality{top:58px;max-width:calc(100% - 28px);font-size:.76rem;padding:8px 10px}
  .face-scan-glow{width:250px;height:340px}
  .face-scan-line{width:min(270px,72%)}
  .face-scan-corner{width:34px;height:34px}
  .bank-face-modern .bank-face-modern-header p{display:none}
  .face-ai-badge{font-size:.66rem;min-height:24px;padding:4px 8px}
}

/* V62 - Face ID automático: modal limpo, desktop corrigido e leitura por cores */
.face-scan-statusbar{
  display:none!important;
}
.face-scan-line.ok{
  background:linear-gradient(90deg,transparent,#86efac,#22c55e,#86efac,transparent)!important;
  box-shadow:0 0 18px rgba(34,197,94,.9),0 0 38px rgba(34,197,94,.45)!important;
}
.face-scan-line.warn{
  background:linear-gradient(90deg,transparent,#fde68a,#f59e0b,#fde68a,transparent)!important;
  box-shadow:0 0 18px rgba(245,158,11,.9),0 0 38px rgba(245,158,11,.35)!important;
}
.face-scan-line.error{
  background:linear-gradient(90deg,transparent,#fecaca,#ef4444,#fecaca,transparent)!important;
  box-shadow:0 0 18px rgba(239,68,68,.92),0 0 38px rgba(239,68,68,.36)!important;
}
.face-scan-glow.ok{
  background:radial-gradient(ellipse at center,rgba(34,197,94,.24),rgba(9,87,184,.08) 48%,transparent 70%)!important;
}
.face-scan-glow.warn{
  background:radial-gradient(ellipse at center,rgba(245,158,11,.24),rgba(9,87,184,.08) 48%,transparent 70%)!important;
}
.face-scan-glow.error{
  background:radial-gradient(ellipse at center,rgba(239,68,68,.24),rgba(9,87,184,.08) 48%,transparent 70%)!important;
}
#modalDeliveryFaceCamera .face-scan-manual-action,
#modalColabFaceCamera .face-scan-manual-action{
  display:none!important;
}
#modalDeliveryFaceCamera .bank-face-footer,
#modalColabFaceCamera .bank-face-footer{
  justify-content:center;
}
#modalDeliveryFaceCamera .bank-face-footer .faceid-cancel-dashboard,
#modalColabFaceCamera .bank-face-footer .btn-outline-secondary{
  min-width:210px;
}
@media (min-width:768px){
  .face-gate-modal .modal-dialog,
  #modalDeliveryFaceCamera .modal-dialog,
  #modalColabFaceCamera .modal-dialog{
    width:min(760px, calc(100vw - 48px))!important;
    max-width:min(760px, calc(100vw - 48px))!important;
    height:auto!important;
    max-height:calc(100dvh - 40px)!important;
    margin:20px auto!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
  }
  .face-gate-modal .bank-face-content,
  #modalDeliveryFaceCamera .bank-face-content,
  #modalColabFaceCamera .bank-face-content{
    width:100%!important;
    height:auto!important;
    max-height:calc(100dvh - 40px)!important;
    border-radius:30px!important;
    overflow:hidden!important;
  }
  .face-gate-modal .bank-face-body,
  #modalDeliveryFaceCamera .bank-face-body,
  #modalColabFaceCamera .bank-face-body{
    padding:16px!important;
    display:block!important;
    overflow:visible!important;
  }
  .face-gate-modal .bank-face-viewport,
  #modalDeliveryFaceCamera .bank-face-viewport,
  #modalColabFaceCamera .bank-face-viewport{
    width:100%!important;
    max-width:none!important;
    height:min(58vh, 520px)!important;
    min-height:430px!important;
    aspect-ratio:auto!important;
    border-radius:26px!important;
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.1)!important;
  }
  .face-gate-modal .bank-face-footer,
  #modalDeliveryFaceCamera .bank-face-footer,
  #modalColabFaceCamera .bank-face-footer{
    display:flex!important;
    grid-template-columns:none!important;
    min-height:auto!important;
    flex:0 0 auto!important;
    padding:16px 22px 22px!important;
  }
  .face-gate-modal .bank-face-bottom-hint,
  #modalDeliveryFaceCamera .bank-face-bottom-hint,
  #modalColabFaceCamera .bank-face-bottom-hint{
    bottom:22px!important;
    width:auto!important;
    max-width:calc(100% - 50px)!important;
  }
  .face-gate-modal .bank-face-flip-btn,
  #modalDeliveryFaceCamera .bank-face-flip-btn,
  #modalColabFaceCamera .bank-face-flip-btn{
    top:18px!important;
    left:18px!important;
  }
}
