:root {
    --app-bg: #f4f8fb;
    --app-surface: #fcfdff;
    --app-surface-soft: #f8fbff;
    --app-text: #132033;
    --app-text-soft: #4f6078;
    --app-primary: #1976f2;
    --app-primary-strong: #0d4fb8;
    --app-accent: #14b8a6;
    --app-border: #bccde4;
    --app-shadow: 0 18px 42px rgba(13, 52, 110, 0.14);
    --app-radius-lg: 20px;
    --app-radius-md: 14px;
}

* {
    box-sizing: border-box;
}

body.app-body {
    margin: 0;
    min-height: 100vh;
    overflow-x: hidden;
    font-family: "Manrope", "Segoe UI", sans-serif;
    color: var(--app-text);
    background:
        radial-gradient(1100px 500px at 92% -10%, rgba(25, 118, 242, 0.22), transparent 58%),
        radial-gradient(900px 430px at -8% -16%, rgba(37, 99, 235, 0.15), transparent 54%),
        linear-gradient(180deg, #f8fbff 0%, var(--app-bg) 56%, #eef5fb 100%);
}

.app-flash-stack {
    position: fixed;
    top: 0.8rem;
    left: 50%;
    transform: translateX(-50%);
    width: min(94vw, 920px);
    z-index: 1060;
}

.app-flash-stack .alert {
    margin-bottom: 0.5rem;
    box-shadow: 0 10px 24px rgba(15, 32, 56, 0.12);
    overflow-wrap: anywhere;
    word-break: break-word;
    line-height: 1.35;
    transition: opacity 0.28s ease, transform 0.28s ease;
}

.app-flash-stack .alert.alert-hide {
    opacity: 0;
    transform: translateY(-6px);
}

.alert-dev-link a {
    display: inline-block;
    margin-top: 0.28rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.85rem;
}

.app-install-banner {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    left: 1rem;
    z-index: 1050;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 0.75rem;
    align-items: center;
    max-width: 560px;
    margin: 0 auto;
    padding: 0.85rem 0.9rem;
    color: #132033;
    background: rgba(252, 253, 255, 0.98);
    border: 1px solid rgba(188, 205, 228, 0.95);
    border-radius: var(--app-radius-md);
    box-shadow: 0 18px 42px rgba(13, 52, 110, 0.2);
}

.app-install-banner[hidden] {
    display: none;
}

.app-install-banner__text {
    display: grid;
    gap: 0.12rem;
    min-width: 0;
    font-size: 0.88rem;
    line-height: 1.25;
}

.app-install-banner__text strong {
    font-size: 0.92rem;
}

.app-install-banner__ios {
    display: none;
}

.app-install-banner[data-install-banner="ios"] .app-install-banner__android,
.app-install-banner[data-install-banner="ios"] .app-install-banner__action {
    display: none;
}

.app-install-banner[data-install-banner="ios"] .app-install-banner__ios {
    display: inline;
}

.app-install-banner__action {
    min-height: 2.25rem;
    padding: 0.42rem 0.9rem;
    white-space: nowrap;
}

.app-install-banner__close {
    width: 2.1rem;
    height: 2.1rem;
    border: 0;
    border-radius: 999px;
    color: #4f6078;
    background: transparent;
    font-size: 1.35rem;
    line-height: 1;
}

.app-install-banner__close:hover,
.app-install-banner__close:focus {
    color: #132033;
    background: #eef5fb;
}

.app-shell {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 1.2rem;
}

.app-frame {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 260px 1fr;
    position: relative;
}

.app-sidebar {
    background: linear-gradient(180deg, #1e2f44 0%, #1b2738 100%);
    color: #d7e2f2;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    padding: 1rem 0.75rem;
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 60;
}

.app-sidebar-brand {
    padding: 0.5rem 0.75rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 0.9rem;
}

.app-sidebar-title {
    font-size: 1.02rem;
    font-weight: 800;
    letter-spacing: 0.03em;
}

.app-sidebar-subtitle {
    font-size: 0.82rem;
    color: #9db2cf;
}

.app-nav {
    display: grid;
    gap: 0.35rem;
    flex: 1;
    align-content: start;
}

.app-nav-section {
    margin: 0.6rem 0.25rem 0.2rem;
    padding-top: 0.45rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #9db2cf;
}

.app-nav-item {
    display: block;
    text-decoration: none;
    color: #d8e3f4;
    padding: 0.62rem 0.75rem;
    border-radius: 10px;
    border: 1px solid transparent;
    transition: background 0.18s ease, border-color 0.18s ease;
}

.app-nav-item:hover {
    background: rgba(39, 122, 221, 0.2);
    border-color: rgba(96, 163, 255, 0.35);
    color: #f2f7ff;
}

.app-nav-item.is-active {
    background: linear-gradient(90deg, #1f74ea 0%, #2a9bff 100%);
    border-color: rgba(157, 204, 255, 0.5);
    color: #ffffff;
    font-weight: 700;
}

.app-nav-empty {
    display: block;
    color: #9db2cf;
    font-size: 0.88rem;
    padding: 0.5rem 0.75rem;
}

.app-sidebar-footer {
    padding-top: 0.6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.app-nav-danger {
    background: rgba(220, 38, 38, 0.18);
    border-color: rgba(252, 165, 165, 0.3);
    color: #fecaca;
    font-weight: 700;
}

.app-nav-danger:hover {
    background: rgba(220, 38, 38, 0.28);
    border-color: rgba(252, 165, 165, 0.52);
    color: #ffe4e6;
}

.app-main-wrap {
    min-width: 0;
    display: grid;
    grid-template-rows: auto 1fr;
    min-height: 100vh;
}

.app-topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    background: rgba(247, 251, 255, 0.92);
    backdrop-filter: blur(7px);
    border-bottom: 1px solid #c6d9f2;
    padding: 0.7rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
}

.app-menu-toggle {
    display: none;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    border: 1px solid #b9cfee;
    background: #eef5ff;
    color: #1a4d91;
    font-size: 1rem;
    line-height: 1;
}

.app-menu-overlay {
    display: none;
}

.app-topbar-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: #123f78;
}

.app-topbar-subtitle {
    font-size: 0.83rem;
    color: #537095;
}

.app-main-content {
    padding: 1rem;
    min-width: 0;
    overflow-x: hidden;
}

.auth-layout {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card-header {
    margin: -1.35rem -1.35rem 1.15rem;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--app-border);
    border-radius: var(--app-radius-lg) var(--app-radius-lg) 0 0;
    background: linear-gradient(180deg, #f7fbff 0%, #edf4ff 100%);
    color: #173661;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.86rem;
    font-weight: 800;
}

.auth-grid {
    width: 100%;
    display: grid;
    gap: 1rem;
    grid-template-columns: 1fr;
}

.auth-grid-single {
    max-width: 520px;
    margin: 0 auto;
}

.app-card {
    border: 1px solid var(--app-border);
    background: var(--app-surface);
    border-radius: var(--app-radius-lg);
    box-shadow: var(--app-shadow);
    position: relative;
    overflow: hidden;
}

.app-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    border-radius: var(--app-radius-lg) var(--app-radius-lg) 0 0;
    background: linear-gradient(90deg, #1f74ea, #2a9bff);
}

.app-card-soft {
    border: 1px solid var(--app-border);
    background: var(--app-surface-soft);
    border-radius: var(--app-radius-md);
}

.auth-card {
    padding: 1.35rem;
}

.auth-card-single {
    width: 100%;
}

.auth-title-login {
    margin-bottom: 1rem;
}

.auth-title {
    margin: 0 0 0.35rem;
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.auth-subtitle {
    margin: 0 0 1rem;
    color: var(--app-text-soft);
    font-size: 0.95rem;
}

.auth-side {
    display: none;
    padding: 1.35rem;
}

.error-layout .app-shell {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.error-card {
    width: min(100%, 540px);
    padding: 2rem 1.5rem;
    text-align: center;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 249, 255, 0.98));
}

.error-mark {
    width: 84px;
    height: 84px;
    margin: 0 auto 1.15rem;
    border: 1px solid #b7d2f7;
    border-radius: 24px;
    background:
        linear-gradient(135deg, #1976f2 0%, #0d4fb8 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 16px 34px rgba(13, 79, 184, 0.22);
}

.error-mark span {
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1;
}

.error-kicker {
    margin: 0 0 0.35rem;
    color: #155cc4;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.error-title {
    margin: 0 0 0.7rem;
    color: #102848;
    font-size: 1.75rem;
    font-weight: 800;
    line-height: 1.12;
}

.error-message {
    margin: 0 auto;
    max-width: 420px;
    color: var(--app-text-soft);
    line-height: 1.55;
}

.error-actions {
    margin-top: 1.45rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.65rem;
}

.error-actions .btn {
    min-width: 150px;
}

.badge-soft {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: #e8f0ff;
    color: #1249a8;
    border: 1px solid #c7dbff;
    border-radius: 999px;
    padding: 0.28rem 0.7rem;
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.section-title {
    margin: 0.65rem 0 0.4rem;
    font-size: 1.05rem;
    font-weight: 700;
}

.section-text {
    margin: 0;
    color: var(--app-text-soft);
    line-height: 1.55;
}

.app-label {
    font-weight: 700;
    font-size: 0.86rem;
    color: #1d3458;
}

.app-input {
    border-radius: 12px;
    border: 1px solid var(--app-border);
    min-height: 46px;
    padding-left: 0.9rem;
    padding-right: 0.9rem;
}

.app-input:focus {
    border-color: #8ab6ff;
    box-shadow: 0 0 0 0.22rem rgba(13, 110, 253, 0.14);
}

.form-control.is-invalid,
.form-select.is-invalid,
.app-input.is-invalid {
    border-color: #e58a96;
    background-image: none;
    box-shadow: 0 0 0 0.2rem rgba(220, 38, 38, 0.12);
}

.form-control.is-invalid:focus,
.form-select.is-invalid:focus,
.app-input.is-invalid:focus {
    border-color: #dc5f70;
    box-shadow: 0 0 0 0.23rem rgba(220, 38, 38, 0.16);
}

.invalid-feedback {
    display: flex;
    align-items: flex-start;
    gap: 0.56rem;
    margin-top: 0.45rem;
    padding: 0.46rem 0.6rem;
    border: 1px solid #f4b3bc;
    border-radius: 10px;
    background: #fff4f5;
    color: #9f1239;
    font-size: 0.84rem;
    font-weight: 600;
    line-height: 1.35;
}

.invalid-feedback::before {
    content: "!";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 999px;
    background: #dc2626;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1;
    flex: 0 0 auto;
    margin-top: 0.05rem;
    margin-right: 0.06rem;
}

.btn-app {
    border: 0;
    border-radius: 12px;
    min-height: 46px;
    background: linear-gradient(135deg, var(--app-primary), var(--app-primary-strong));
    font-weight: 700;
}

.btn-app:hover,
.btn-app:focus {
    background: linear-gradient(135deg, #0b5ed7, #0749af);
}

.btn-outline-app {
    border: 1px solid #b9cae4;
    color: #2a3f60;
    border-radius: 12px;
    min-height: 44px;
    font-weight: 700;
}

.btn-outline-app:hover {
    background: #ecf3ff;
    color: #1d3354;
    border-color: #95b6e4;
}

.app-btn-icon-inline {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.app-btn-icon-inline svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.app-btn-back {
    display: inline-flex;
    align-items: center;
    gap: 0.34rem;
    min-height: 34px;
    padding: 0.32rem 0.68rem;
    border-radius: 8px;
    border: 1px solid #5f738e;
    background: linear-gradient(180deg, #6f8298 0%, #5d6f86 100%);
    color: #ffffff;
    text-decoration: none;
    font-size: 0.83rem;
    font-weight: 700;
    line-height: 1;
}

.app-btn-back:hover {
    background: linear-gradient(180deg, #63768f 0%, #53657d 100%);
    border-color: #4f6279;
    color: #ffffff;
}

.app-btn-back svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.panel-header {
    padding: 1rem;
    margin-bottom: 1rem;
}

.dashboard-hero {
    padding: 1rem;
    margin-bottom: 1rem;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(239, 247, 255, 0.96));
}

.dashboard-hero .panel-title {
    color: #0e356a;
}

.panel-title {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

.panel-subtitle {
    margin: 0.15rem 0 0;
    color: var(--app-text-soft);
    font-size: 0.92rem;
}

.metrics-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

.metric-card {
    padding: 1rem;
}

.metric-card-strong {
    border-color: #9ebce5;
    background: linear-gradient(180deg, #ffffff, #eef6ff);
}

.metric-label {
    margin: 0 0 0.2rem;
    font-size: 0.82rem;
    color: var(--app-text-soft);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.metric-value {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
}

.dashboard-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

.dashboard-action {
    display: block;
    padding: 0.95rem 1rem;
    border: 1px solid #aac6e9;
    border-radius: 14px;
    text-decoration: none;
    color: #18345d;
    background: linear-gradient(180deg, #ffffff, #ebf4ff);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.dashboard-action:hover {
    transform: translateY(-1px);
    border-color: #5b93d8;
    box-shadow: 0 12px 28px rgba(22, 73, 150, 0.16);
    color: #122948;
}

.dashboard-action-title {
    display: block;
    font-weight: 800;
    margin-bottom: 0.15rem;
}

.dashboard-action-subtitle {
    display: block;
    font-size: 0.88rem;
    color: #4f6078;
}

.admin-chart-card {
    overflow: hidden;
}

.admin-section-card {
    background: linear-gradient(180deg, #ffffff, #f7fbff);
    border-top: 3px solid #2a86f4;
}

.admin-chart-title {
    font-size: 1.12rem;
}

.admin-chart-totals {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.admin-chart-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.62rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    border: 1px solid;
}

.admin-chart-pill-new {
    color: #0f4a9e;
    background: #e7f1ff;
    border-color: #bcd5f7;
}

.admin-chart-pill-renew {
    color: #0f766e;
    background: #e7faf6;
    border-color: #b5ece3;
}

.admin-chart-pill-pending {
    color: #9a4a00;
    background: #fff3e8;
    border-color: #ffd8b5;
}

.admin-chart-pill-validated {
    color: #14532d;
    background: #e9f9ef;
    border-color: #bdeccc;
}

.admin-chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    font-size: 0.84rem;
    color: #425672;
}

.admin-chart-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.38rem;
}

.admin-chart-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    flex-shrink: 0;
}

.admin-chart-dot-new {
    background: linear-gradient(90deg, #1f74ea, #2a9bff);
}

.admin-chart-dot-renew {
    background: linear-gradient(90deg, #14b8a6, #20c997);
}

.admin-chart-dot-pending {
    background: linear-gradient(90deg, #f59e0b, #f97316);
}

.admin-chart-dot-validated {
    background: linear-gradient(90deg, #22c55e, #16a34a);
}

.admin-chart-grid {
    display: grid;
    gap: 0.55rem;
}

.admin-chart-row {
    display: grid;
    grid-template-columns: 84px minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.55rem;
    align-items: center;
}

.admin-chart-month {
    font-size: 0.8rem;
    color: #4d6486;
    font-weight: 700;
}

.admin-chart-bars {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.45rem;
    align-items: center;
}

.admin-chart-bar-wrap {
    height: 12px;
    border-radius: 999px;
    background: #ecf3fd;
    overflow: hidden;
}

.admin-chart-bar {
    height: 100%;
    min-width: 0;
    border-radius: 999px;
}

.admin-chart-bar-new {
    background: linear-gradient(90deg, #1f74ea, #2a9bff);
}

.admin-chart-bar-renew {
    background: linear-gradient(90deg, #14b8a6, #20c997);
}

.admin-chart-bar-pending {
    background: linear-gradient(90deg, #f59e0b, #f97316);
}

.admin-chart-bar-validated {
    background: linear-gradient(90deg, #22c55e, #16a34a);
}

.admin-chart-value {
    min-width: 1.6rem;
    text-align: right;
    font-size: 0.8rem;
    color: #294264;
    font-weight: 700;
}

.admin-metrics-grid .metric-card {
    min-height: 94px;
}

.admin-line-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    align-items: center;
}

.admin-line-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    font-size: 0.85rem;
    color: #3b5374;
    font-weight: 600;
}

.admin-line-toggle input {
    margin: 0;
}

.admin-line-toggle.is-static {
    opacity: 0.96;
}

.admin-line-dot {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    flex-shrink: 0;
}

.admin-line-dot.is-blue {
    background: #1f74ea;
}

.admin-line-dot.is-teal {
    background: #14b8a6;
}

.admin-line-dot.is-green {
    background: #16a34a;
}

.admin-line-canvas-wrap {
    border: 1px solid #d0def2;
    border-radius: 14px;
    padding: 0.5rem 0.6rem;
    background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.admin-line-canvas {
    display: block;
    width: 100%;
    height: 300px;
}

.admin-incident-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.admin-half-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.95rem;
}

.table thead th {
    background: #eaf3ff;
    color: #12417e;
    border-bottom: 1px solid #b4cced;
}

.worker-clock-shell {
    background: #f7fbff;
}

.worker-clock-topbar {
    margin: -1rem -1rem 1rem;
    padding: 0.75rem 1rem;
    background: linear-gradient(90deg, #1976f2, #0f5fd2);
    color: #fff;
    font-weight: 700;
    border-radius: var(--app-radius-lg) var(--app-radius-lg) 0 0;
}

.worker-clock-topbar-main {
    font-weight: 800;
}

.worker-clock-topbar-sub {
    margin-top: 0.2rem;
    font-size: 0.84rem;
    color: rgba(241, 247, 255, 0.96);
}

.worker-summary-card {
    border: 1px solid #bbcff0;
    border-left: 5px solid #1976f2;
    border-radius: 14px;
    background: #fff;
    padding: 0.75rem 0.9rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
}

.worker-summary-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #5b7192;
    font-weight: 700;
}

.worker-summary-value {
    font-size: 1.7rem;
    font-weight: 800;
    color: #122c50;
}

.worker-summary-open-mobile {
    border: 1px solid #0e5ecf;
    background: linear-gradient(135deg, #1976f2, #0f5fd2);
    color: #ffffff;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    line-height: 1;
}

.worker-summary-open-icon {
    font-size: 1.35rem;
    font-weight: 800;
    transform: translateY(-1px);
}

.worker-actions-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.6rem;
}

.worker-actions-grid-2 {
    grid-template-columns: 1fr;
}

.worker-action-btn {
    border: 1px solid #c4d4ea;
    border-radius: 14px;
    background: #eef3f9;
    color: #6e7f94;
    min-height: 68px;
    text-transform: uppercase;
    font-weight: 800;
    letter-spacing: 0.02em;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.22rem;
}

.worker-action-icon {
    font-size: 2rem;
    line-height: 1;
    font-weight: 900;
}

.worker-action-text {
    font-size: 0.72rem;
}

.worker-action-btn.is-entry {
    background: linear-gradient(135deg, #1976f2, #0f5fd2);
    border-color: #0e5ecf;
    color: #fff;
}

.worker-action-btn.is-ready {
    background: linear-gradient(135deg, #3b8cff, #1f74ea);
    border-color: #1d69d4;
    color: #fff;
}

.worker-action-btn.is-break {
    background: linear-gradient(135deg, #2ca54a, #238a3e);
    border-color: #1f7a37;
    color: #fff;
}

.worker-action-btn.is-resume {
    background: linear-gradient(135deg, #2ca54a, #238a3e);
    border-color: #1f7a37;
    color: #fff;
}

.worker-action-btn.is-extra {
    background: linear-gradient(135deg, #de2f46, #be1f34);
    border-color: #b41a2d;
    color: #fff;
}

.worker-action-btn:disabled {
    background: #edf1f6;
    color: #9ca8b7;
    border-color: #d4dce7;
    opacity: 1;
}

.worker-geo-box {
    border: 1px solid #c9d7eb;
    border-radius: 12px;
    background: #fff;
    padding: 0.75rem 0.9rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-transform: uppercase;
    font-size: 0.82rem;
    font-weight: 700;
    color: #46648b;
}

.worker-geo-box #geo_status[data-mode="ok"] {
    color: #0f7c38;
}

.worker-geo-box #geo_status[data-mode="loading"] {
    color: #1a5ec0;
}

.worker-geo-box #geo_status[data-mode="error"] {
    color: #b42318;
}

.worker-history-filters {
    padding: 0.8rem;
    border: 1px solid #c4d6ee;
    border-radius: 14px;
    background: linear-gradient(180deg, #fafdff, #f2f8ff);
}

.worker-history-day {
    background: linear-gradient(180deg, #ffffff, #f4f9ff);
    border-color: #b9cdea;
}

.worker-history-open {
    white-space: nowrap;
}

.worker-history-modal {
    border-radius: 16px;
    border: 1px solid #bfd0e6;
}

.worker-history-modal .modal-header {
    background: #f2f8ff;
    border-bottom: 1px solid #ccdaec;
}

.worker-history-modal-body {
    max-height: 62vh;
}

.worker-history-event-list .list-group-item {
    border-color: #d6e2f1;
}

.worker-history-event-list .list-group-item:nth-child(odd) {
    background: #ffffff;
}

.worker-history-event-list .list-group-item:nth-child(even) {
    background: #f4f8ff;
}

.worker-location-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 26px;
    padding: 0 0.5rem;
    border-radius: 999px;
    border: 1px solid #bfd4f2;
    background: #eef5ff;
    color: #1f62bf;
    text-decoration: none;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1;
}

.worker-location-link:hover {
    background: #dfeeff;
    border-color: #8db6ea;
    color: #154c96;
}

.worker-adjusted-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 58px;
    height: 22px;
    padding: 0 0.45rem;
    border-radius: 999px;
    border: 1px solid #f7c984;
    background: #fff4df;
    color: #a35b00;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1;
}

.empresa-screen {
    min-width: 0;
}

.empresa-worker-item,
.empresa-entry-item {
    min-width: 0;
    overflow: hidden;
}

.empresa-entry-item p {
    overflow-wrap: anywhere;
}

.empresa-day-workers {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.empresa-pdf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

.empresa-pdf-icon {
    width: 16px;
    height: 16px;
}

.empresa-day-modal-dialog {
    max-width: min(760px, calc(100vw - 1.5rem));
}

.empresa-day-modal-dialog .modal-content {
    overflow: hidden;
}

.empresa-day-modal-dialog .list-group-item {
    padding: 0.38rem 0.55rem;
}

.empresa-event-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    column-gap: 0.45rem;
}

.empresa-event-label {
    min-width: 0;
}

.empresa-event-meta {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.34rem;
    min-width: 0;
}

.empresa-event-time {
    min-width: 58px;
    text-align: right;
}

.empresa-info-btn {
    width: 36px;
    height: 36px;
    min-height: 36px;
    border-radius: 999px;
    padding: 0;
    font-weight: 800;
}

.empresa-worker-filters {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.empresa-worker-filters .btn {
    min-height: 34px;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
}

.empresa-status-chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0.16rem 0.55rem;
    font-size: 0.72rem;
    font-weight: 700;
    border: 1px solid transparent;
    white-space: nowrap;
}

.empresa-status-chip.is-active {
    background: #e9f9ee;
    color: #1d7d3f;
    border-color: #bfe9cb;
}

.empresa-status-chip.is-inactive {
    background: #fff4e6;
    color: #a15413;
    border-color: #ffd5ad;
}

.empresa-status-chip.is-pending {
    background: #e9f2ff;
    color: #1b5fb8;
    border-color: #bdd6f7;
}

.empresa-worker-meta {
    font-variant-numeric: tabular-nums;
}

.empresa-contract-line {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-variant-numeric: tabular-nums;
}

.gestor-license-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 1rem;
    align-items: center;
    font-size: 0.88rem;
    color: #355176;
}

.gestor-license-legend-item {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
}

.gestor-license-dot {
    display: inline-block;
    flex: 0 0 auto;
    width: 10px;
    height: 10px;
    border-radius: 999px;
    margin-right: 0.3rem;
    vertical-align: middle;
}

.gestor-license-dot-green {
    background: #1f9d55;
}

.gestor-license-dot-orange {
    background: #d97706;
}

.gestor-license-dot-red {
    background: #dc2626;
}

.gestor-license-end {
    letter-spacing: 0.01em;
}

.gestor-license-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 96px;
    padding: 0.22rem 0.62rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.gestor-license-chip-green {
    background: #1f9d55;
    color: #ffffff;
}

.gestor-license-chip-orange {
    background: #f59e0b;
    color: #111827;
}

.gestor-license-chip-red {
    background: #dc2626;
    color: #ffffff;
}

.gestor-license-chip-muted {
    background: #e5e7eb;
    color: #374151;
}

.gestor-workers-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    min-width: 52px;
    height: 30px;
    border-radius: 999px;
    border: 1px solid #a9c4e7;
    background: #eef5ff;
    color: #1450a4;
    font-weight: 800;
    text-decoration: none;
}

.gestor-workers-link:hover {
    background: #dceaff;
    color: #0e3f84;
}

.gestor-workers-link svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.gestor-info-hover-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.gestor-info-icon {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    border: 1px solid #c3d4ec;
    background: #eef5ff;
    color: #2b5fa9;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    cursor: default;
}

.gestor-info-icon svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.gestor-info-tooltip {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 260px;
    max-width: 320px;
    border: 1px solid #f2d28d;
    background: #fff4df;
    color: #8a5b00;
    border-radius: 10px;
    padding: 0.45rem 0.6rem;
    font-size: 0.78rem;
    line-height: 1.3;
    box-shadow: 0 8px 20px rgba(15, 32, 56, 0.14);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-4px);
    transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s ease;
    z-index: 12;
}

.gestor-info-hover-wrap:hover .gestor-info-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.gestor-action-icon-btn {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    border: 1px solid #aec4e2;
    background: #f4f8ff;
    color: #174a95;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.gestor-action-icon-btn svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.gestor-action-icon-btn:hover {
    background: #e3efff;
    color: #123f83;
    border-color: #8db0dc;
}

.gestor-action-icon-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.gestor-action-icon-btn-danger {
    border-color: #f4b4bd;
    background: #fff1f2;
    color: #b42318;
}

.gestor-action-icon-btn-danger:hover {
    background: #ffe4e6;
    color: #991b1b;
    border-color: #ef98a5;
}

.gestor-action-icon-btn-warning {
    border-color: #f5d8a1;
    background: #fff8eb;
    color: #9a5b00;
}

.gestor-action-icon-btn-warning:hover {
    border-color: #e6ba67;
    background: #ffefcc;
    color: #7a4500;
}

.gestor-action-icon-btn-success {
    border-color: #9ad8bb;
    background: #ecfdf3;
    color: #067647;
}

.gestor-action-icon-btn-success:hover {
    border-color: #6dc39b;
    background: #dcfce7;
    color: #065f46;
}

.action-legend-trigger {
    width: 28px;
    height: 28px;
}

.action-legend-list {
    display: grid;
    gap: 0.75rem;
}

.action-legend-item {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 0.75rem;
    align-items: center;
    padding: 0.65rem 0;
    border-bottom: 1px solid #d8e4f3;
}

.action-legend-item:last-child {
    border-bottom: 0;
}

.action-legend-item small {
    color: #667085;
}

.admin-manager-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.45rem;
}

.admin-license-adjust-form {
    display: inline-flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.35rem;
    min-width: 240px;
}

.admin-license-adjust-input {
    width: 64px !important;
    min-width: 64px;
    text-align: center;
    font-weight: 700;
}

.admin-license-save-btn {
    min-width: 76px;
}

.worker-history-days-scroll {
    max-height: 58vh;
    overflow-y: auto;
    padding-right: 0.2rem;
}

.worker-incident-form textarea.app-input {
    min-height: 120px;
}

.worker-incident-blocks {
    display: grid;
    gap: 0.55rem;
    max-height: 220px;
    overflow-y: auto;
    padding-right: 0.2rem;
}

.worker-incident-block-option {
    display: block;
    cursor: pointer;
}

.worker-incident-block-option.is-locked {
    cursor: not-allowed;
}

.worker-incident-block-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.worker-incident-block-content {
    display: block;
    border: 1px solid #c3d5ee;
    border-radius: 12px;
    background: #f9fcff;
    padding: 0.65rem 0.75rem;
}

.worker-incident-block-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.45rem;
}

.worker-incident-block-hours {
    font-weight: 700;
    color: #18345d;
    font-size: 0.9rem;
}

.worker-incident-block-option input:checked + .worker-incident-block-content {
    border-color: #2d7df3;
    box-shadow: 0 0 0 0.18rem rgba(25, 118, 242, 0.15);
    background: #eff6ff;
}

.worker-incident-block-option.is-locked .worker-incident-block-content {
    opacity: 0.72;
    background: #f2f5fa;
}

.worker-incident-locked {
    border: 0;
    margin: 0;
    padding: 0;
}

.worker-incident-confirm {
    border-color: #7bb4ff;
}

.security-note {
    padding: 0.8rem 0.95rem;
    border-radius: 12px;
    border: 1px dashed #bcd9d5;
    background: #effbf8;
    color: #0f766e;
    font-size: 0.88rem;
}

.forgot-link {
    color: #1855b5;
    font-weight: 700;
    text-decoration: none;
}

.forgot-link:hover {
    color: #0f3f8f;
    text-decoration: underline;
}

.cart-qty-form {
    margin: 0;
}

.cart-qty-control {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    min-width: 148px;
    padding: 0.28rem 0.38rem;
    border: 1px solid var(--app-border);
    border-radius: 12px;
    background: #f6faff;
}

.cart-qty-btn {
    width: 34px;
    height: 34px;
    border: 1px solid #a8c5f0;
    border-radius: 10px;
    background: #eaf3ff;
    color: #0f4da8;
    font-size: 1.22rem;
    font-weight: 800;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}

.cart-qty-btn:hover {
    border-color: #76a8ed;
    background: #dcecff;
    color: #0b3f8d;
}

.cart-qty-value {
    min-width: 34px;
    text-align: center;
    font-weight: 800;
    color: #173661;
}

.cart-totals {
    display: grid;
    gap: 0.32rem;
    max-width: 360px;
}

.cart-totals-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    color: #1c355a;
}

.cart-totals-row-total {
    margin-top: 0.22rem;
    padding-top: 0.34rem;
    border-top: 1px solid #bfd3ee;
}

.app-table-zebra tbody tr:nth-child(odd) > * {
    background-color: #ffffff;
}

.app-table-zebra tbody tr:nth-child(even) > * {
    background-color: #f6faff;
}

.app-nav-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.app-nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 0.34rem;
    border-radius: 999px;
    background: #d92d20;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1;
}

.app-nav-badge[hidden] {
    display: none;
}

.support-thread-list {
    max-height: 72vh;
    overflow-y: auto;
}

.support-thread-item {
    display: block;
    text-decoration: none;
    color: var(--app-text);
    border: 1px solid #c6d8ef;
    background: #f8fbff;
    border-radius: 12px;
    padding: 0.65rem 0.7rem;
    margin-bottom: 0.55rem;
}

.support-thread-item:hover {
    border-color: #8db8ef;
    background: #eef6ff;
}

.support-thread-item.is-active {
    border-color: #2f7be8;
    background: #e9f2ff;
}

.support-thread-preview {
    margin-top: 0.25rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.support-chat-list {
    max-height: 65vh;
    overflow-y: auto;
}

.support-message {
    border: 1px solid #c9daef;
    border-radius: 12px;
    padding: 0.6rem 0.72rem;
    margin-bottom: 0.58rem;
    background: #f8fbff;
}

.support-message.is-mine {
    border-color: #9ec4f7;
    background: #edf6ff;
}

.support-message-meta {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.3rem;
    font-size: 0.83rem;
    color: #4f6383;
}

.support-compose textarea.app-input {
    min-height: 110px;
}

.support-message-gestor.is-mine {
    border-color: #8eb8ef;
    background: #eaf3ff;
}

.support-message-gestor.is-other {
    border-color: #9fd9b8;
    background: #eaf9f1;
}

.support-message-role-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: 0.4rem;
    padding: 0.08rem 0.45rem;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: 0.68rem;
    font-weight: 800;
    line-height: 1.2;
    vertical-align: middle;
}

.support-message-role-pill.is-admin {
    color: #0e7441;
    background: #e5f7ee;
    border-color: #9edcb8;
}

.support-message-role-pill.is-manager {
    color: #1c4c89;
    background: #e8f2ff;
    border-color: #9ec2f2;
}

.support-admin-counter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.34rem 0.72rem;
    border-radius: 999px;
    border: 1px solid #b9d2f1;
    color: #214a82;
    background: #edf5ff;
    font-size: 0.78rem;
    font-weight: 700;
}

.support-admin-panel {
    border: 1px solid #c7daf1;
    background: linear-gradient(180deg, #f8fbff 0%, #f4f9ff 100%);
    border-radius: 14px;
}

.support-admin-panel-title {
    font-weight: 800;
    color: #173d72;
    margin-bottom: 0.55rem;
}

.support-thread-list-admin {
    max-height: 62vh;
    padding-right: 0.2rem;
}

.support-thread-item-admin {
    padding: 0.72rem 0.75rem;
    margin-bottom: 0.62rem;
}

.support-thread-title {
    color: #163865;
}

.support-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 0.18rem 0.55rem;
    border: 1px solid transparent;
}

.support-status-pill.is-open {
    color: #0f7340;
    border-color: #97dbb5;
    background: #e8f8ef;
}

.support-status-pill.is-closed {
    color: #636f86;
    border-color: #c8d4e7;
    background: #f1f5fb;
}

.support-chat-list-admin {
    max-height: 52vh;
    background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}

.support-message-admin {
    border-radius: 14px;
    padding: 0.7rem 0.8rem;
}

.support-message-admin.is-other {
    border-color: #c8d9ee;
    background: #ffffff;
}

.support-message-admin.is-mine {
    border-color: #9fc4f3;
    background: #ebf4ff;
}

.support-admin-empty {
    border-style: dashed;
    min-height: 190px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.support-history-list {
    display: grid;
    gap: 0.55rem;
}

.support-history-item {
    display: block;
    text-decoration: none;
    color: var(--app-text);
    border: 1px solid #c6d8ef;
    border-radius: 12px;
    background: #f8fbff;
    padding: 0.65rem 0.72rem;
}

.support-history-item:hover {
    border-color: #8db8ef;
    background: #eef6ff;
}

.communication-history-link {
    color: var(--app-text);
    text-decoration: none;
}

.communication-history-link:hover {
    color: #174f94;
}

.sidebar-mini-calendar {
    margin-bottom: 0.65rem;
    padding: 0.55rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    background: rgba(10, 26, 46, 0.34);
}

.sidebar-mini-calendar-legend-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin-bottom: 0.35rem;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #f9a11b;
}

.sidebar-mini-calendar-legend-trigger:hover {
    background: rgba(249, 161, 27, 0.14);
    color: #ffb13b;
    transform: translateY(-1px);
}

.sidebar-mini-calendar-legend-trigger svg {
    width: 28px;
    height: 28px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
}

.action-legend-trigger.sidebar-mini-calendar-legend-trigger {
    margin-bottom: 0;
}

.sidebar-mini-calendar-header {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr) 24px;
    gap: 0.2rem;
    align-items: center;
    margin-bottom: 0.4rem;
}

.sidebar-mini-calendar-title {
    color: #ffffff;
    font-size: 0.82rem;
    font-weight: 800;
    text-align: center;
}

.sidebar-mini-calendar-arrow {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    color: #dceaff;
    text-align: center;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 800;
    line-height: 22px;
}

.sidebar-mini-calendar-arrow:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.sidebar-mini-calendar-weekdays,
.sidebar-mini-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.12rem;
}

.sidebar-mini-calendar-weekdays {
    margin-bottom: 0.18rem;
    color: #b7c7df;
    font-size: 0.66rem;
    font-weight: 800;
    text-align: center;
}

.sidebar-mini-calendar-day {
    position: relative;
    min-height: 24px;
    border-radius: 6px;
    color: #e9f1ff;
    text-decoration: none;
    font-size: 0.72rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-mini-calendar-day span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 999px;
}

.sidebar-mini-calendar-number {
    background: var(--marker-color);
    color: #ffffff;
    font-weight: 900;
    box-shadow: 0 4px 10px color-mix(in srgb, var(--marker-color) 24%, transparent);
}

.sidebar-mini-calendar-day:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.sidebar-mini-calendar-day.is-muted {
    color: rgba(214, 226, 244, 0.34);
}

.sidebar-mini-calendar-day.is-weekend,
.sidebar-mini-calendar-day.is-holiday {
    color: #ff6b72;
}

.sidebar-mini-calendar-day.is-muted.is-weekend,
.sidebar-mini-calendar-day.is-muted.is-holiday {
    color: rgba(255, 107, 114, 0.45);
}

.sidebar-mini-calendar-day.is-today {
    outline: 1px solid #7db5ff;
}

.sidebar-mini-calendar-day i {
    position: absolute;
    right: 3px;
    bottom: 3px;
    min-width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    font-size: 0.46rem;
    font-style: normal;
    font-weight: 900;
    line-height: 10px;
    text-align: center;
}

.sidebar-mini-calendar-day i[hidden] {
    display: none;
}

.calendar-month-toolbar {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0.75rem;
    align-items: center;
    margin-bottom: 1rem;
}

.calendar-month-title {
    margin: 0;
    color: #0f3564;
    font-size: 1.25rem;
    font-weight: 800;
    text-align: center;
}

.calendar-month-grid {
    overflow: hidden;
    border: 1px solid #bfd3ee;
    border-radius: 14px;
    background: #ffffff;
}

.calendar-weekdays,
.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.calendar-days {
    grid-auto-rows: minmax(74px, auto);
}

.calendar-weekdays span {
    padding: 0.65rem 0.35rem;
    background: #eef5ff;
    color: #143d74;
    font-size: 0.82rem;
    font-weight: 800;
    text-align: center;
}

.calendar-day {
    min-width: 0;
    min-height: 74px;
    padding: 0.35rem;
    border-top: 1px solid #d8e5f4;
    border-right: 1px solid #d8e5f4;
    background: #ffffff;
    text-align: center;
}

.calendar-day:nth-child(7n) {
    border-right: 0;
}

.calendar-day.is-muted {
    background: #f6f9fd;
    color: #9ca9ba;
}

.calendar-day.is-weekend .calendar-day-number,
.calendar-day.is-holiday .calendar-day-number {
    color: #d62f3a;
}

.calendar-day.is-muted.is-weekend .calendar-day-number,
.calendar-day.is-muted.is-holiday .calendar-day-number {
    color: #d9868c;
}

.calendar-day.is-today {
    box-shadow: inset 0 0 0 1px #1976f2;
}

.calendar-day.has-event .calendar-day-number,
.calendar-day.has-event .calendar-day-extra {
    cursor: help;
}

.calendar-day-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 999px;
    font-weight: 800;
    line-height: 1;
}

.calendar-day-badge {
    border: 2px solid var(--marker-color);
    background: color-mix(in srgb, var(--marker-color) 14%, #ffffff);
    color: #17324f;
    box-shadow: 0 4px 10px color-mix(in srgb, var(--marker-color) 24%, transparent);
}

.calendar-day.is-weekend .calendar-day-badge,
.calendar-day.is-holiday .calendar-day-badge {
    color: #17324f;
}

.calendar-day-extra {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    margin-left: 0.12rem;
    border-radius: 999px;
    background: #1f3552;
    color: #ffffff;
    font-size: 0.62rem;
    font-weight: 700;
}

.calendar-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem 1rem;
    color: #3b4e66;
    font-size: 0.88rem;
}

.calendar-legend span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.calendar-legend i {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    flex: 0 0 auto;
}

.calendar-legend-modal {
    display: grid;
    gap: 0.65rem;
}

.calendar-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 88px;
    border-radius: 999px;
    padding: 0.18rem 0.55rem;
    font-size: 0.74rem;
    font-weight: 800;
}

.calendar-status-pending {
    border: 1px solid #f3c46d;
    background: #fff4d8;
    color: #9a5b00;
}

.calendar-status-approved {
    border: 1px solid #95d2c8;
    background: #e7f7f4;
    color: #12665e;
}

.calendar-status-rejected {
    border: 1px solid #f0a4a4;
    background: #fff0f0;
    color: #a71919;
}

.calendar-half-day {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 46px;
    font-size: 0.84rem;
    font-weight: 700;
}

.calendar-management-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.calendar-shift-management {
    width: 100%;
}

.calendar-compact-list,
.calendar-request-list {
    display: grid;
    gap: 0.6rem;
}

.calendar-shift-group-list {
    display: grid;
    gap: 0.7rem;
    max-height: 560px;
    overflow: auto;
    padding-right: 0.2rem;
}

.calendar-shift-group {
    display: grid;
    gap: 0.55rem;
    border: 1px solid #c9daee;
    border-radius: 8px;
    background: #ffffff;
    padding: 0.72rem;
}

.calendar-shift-group-summary {
    display: flex;
    gap: 0.65rem;
    align-items: flex-start;
    justify-content: space-between;
}

.calendar-shift-group-summary > div {
    display: grid;
    gap: 0.1rem;
    min-width: 0;
}

.calendar-shift-group-summary span,
.calendar-shift-group-summary small,
.calendar-history-row span,
.calendar-history-row small {
    color: #405773;
    font-size: 0.82rem;
}

.calendar-shift-count {
    flex: 0 0 auto;
    border-radius: 999px;
    background: #eef5ff;
    color: #0f4f9a;
    padding: 0.16rem 0.45rem;
    font-size: 0.72rem;
    font-weight: 800;
}

.calendar-shift-edit summary {
    cursor: pointer;
    color: #155cc4;
    font-size: 0.82rem;
    font-weight: 800;
}

.calendar-shift-delete {
    display: flex;
    justify-content: flex-end;
}

.calendar-history-modal-list {
    max-height: none;
}

.calendar-request-delete {
    display: flex;
    justify-content: flex-end;
}

.calendar-list-row {
    display: grid;
    gap: 0.12rem;
    padding-bottom: 0.55rem;
    border-bottom: 1px dashed #cad9ec;
}

.calendar-list-row:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.calendar-history-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.75rem;
    align-items: center;
}

.calendar-history-row > div {
    display: grid;
    gap: 0.12rem;
    min-width: 0;
}

.calendar-request-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.75rem;
}

.calendar-review-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
    align-items: end;
}

.calendar-review-form > div:nth-child(6) {
    grid-column: 1 / -1;
}

.calendar-review-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    align-items: center;
}

@media (min-width: 992px) {
    .calendar-management-grid {
        grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    }

    .calendar-request-card {
        grid-template-columns: minmax(0, 0.9fr) minmax(480px, 1fr);
        align-items: start;
    }
}

@media (max-width: 767.98px) {
    .calendar-month-toolbar {
        grid-template-columns: 1fr 1fr;
    }

    .calendar-month-title {
        grid-column: 1 / -1;
        grid-row: 1;
        font-size: 1.05rem;
    }

    .calendar-day {
        min-height: 48px;
        padding: 0.22rem;
    }

    .calendar-days {
        grid-auto-rows: minmax(48px, auto);
    }

    .calendar-day-number {
        width: 26px;
        height: 26px;
        font-size: 0.78rem;
    }

    .calendar-day-extra {
        min-width: 15px;
        height: 15px;
        font-size: 0.56rem;
    }
}

@media (min-width: 768px) {
    .app-shell {
        padding: 1.4rem;
    }

    .app-main-content {
        padding: 1.4rem;
    }

    .auth-card,
    .auth-side {
        padding: 1.8rem;
    }

    .metrics-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-hero {
        padding: 1.25rem 1.4rem;
    }

    .worker-clock-topbar {
        margin: -1.5rem -1.5rem 1.1rem;
        padding: 0.85rem 1.2rem;
    }

    .worker-actions-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .worker-actions-grid-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .worker-history-days {
        gap: 0.75rem;
    }

    .worker-history-days-scroll {
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }

    .support-thread-list-admin {
        max-height: 70vh;
    }
}

@media (min-width: 992px) {
    .app-topbar-worker {
        display: none;
    }

    .auth-grid-single {
        max-width: 620px;
        justify-items: center;
    }

    .auth-card-single {
        max-width: 620px;
        margin: 0 auto;
        padding: 2rem;
    }

    .auth-card-single .auth-title {
        font-size: 2rem;
        line-height: 1.1;
        margin-bottom: 0.9rem;
        white-space: nowrap;
    }

    .auth-card-single .badge-soft {
        font-size: 0.82rem;
        padding: 0.35rem 0.85rem;
    }

    .auth-card-single .app-label {
        font-size: 0.98rem;
    }

    .auth-card-single .app-input {
        min-height: 52px;
        font-size: 1rem;
    }

    .auth-card-single .btn-app {
        min-height: 52px;
        font-size: 1.05rem;
    }

    .login-card-header {
        margin: -2rem -2rem 1.2rem;
        font-size: 0.9rem;
    }

    .auth-grid {
        grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
        gap: 1.2rem;
    }

    .auth-grid.auth-grid-single {
        grid-template-columns: minmax(0, 1fr);
    }

    .auth-side {
        display: block;
    }

    .metrics-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .admin-metrics-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .dashboard-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-half-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 991.98px) {
    .app-frame {
        grid-template-columns: 1fr;
    }

    .app-sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        width: 280px;
        max-width: calc(100vw - 56px);
        height: 100vh;
        transform: translateX(-110%);
        transition: transform 0.22s ease;
        box-shadow: 0 14px 34px rgba(11, 24, 40, 0.36);
    }

    .app-frame.is-menu-open .app-sidebar {
        transform: translateX(0);
    }

    .app-menu-overlay {
        position: fixed;
        inset: 0;
        background: rgba(5, 16, 32, 0.44);
        z-index: 55;
    }

    .app-frame.is-menu-open .app-menu-overlay {
        display: block;
    }

    .app-topbar {
        top: 0;
    }

    .app-topbar-worker {
        padding: 0.42rem 0.62rem;
        min-height: 52px;
    }

    .app-menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .empresa-home-card {
        border-radius: 16px;
    }

    .empresa-home-card .metric-label {
        font-size: 0.75rem;
    }

    .empresa-home-card .panel-title {
        font-size: 1.02rem;
    }

    .admin-chart-row {
        grid-template-columns: 1fr;
        gap: 0.3rem;
        padding: 0.42rem 0;
        border-bottom: 1px dashed #d4e2f5;
    }

    .admin-chart-row:last-child {
        border-bottom: 0;
    }

    .admin-chart-month {
        font-size: 0.86rem;
    }

    .admin-line-canvas {
        height: 260px;
    }

    .empresa-home-card .panel-subtitle {
        font-size: 0.83rem;
    }

    .empresa-workers-scroll {
        max-height: 56vh;
        overflow-y: auto;
        padding-right: 0.2rem;
    }

    .empresa-worker-item {
        padding: 0.55rem !important;
    }

    .empresa-worker-filters {
        gap: 0.4rem;
    }

    .empresa-worker-filters .btn {
        min-height: 32px;
        padding: 0.24rem 0.68rem;
        font-size: 0.82rem;
    }

    .gestor-license-legend {
        gap: 0.34rem 0.7rem;
        font-size: 0.82rem;
    }
}

