:root {
    --wm-red: #D42B1E;
    --wm-red-dark: #A8200F;
    --wm-red-soft: #FCECEA;
    --wm-charcoal: #252525;
    --wm-charcoal-2: #3A3735;
    --wm-cream: #F5F0E8;
    --wm-paper: #FFFDF9;
    --wm-line: #DDD8CE;
    --wm-muted: #756F68;
    --wm-green: #1F7A43;
    --wm-amber: #A45F00;
    --wm-blue: #1565C0;
    --wm-shadow: 0 18px 48px rgba(45, 45, 45, .16);
}

* { box-sizing: border-box; }

.wm-body {
    margin: 0;
    min-height: 100vh;
    background:
        linear-gradient(90deg, rgba(45,45,45,.035) 1px, transparent 1px),
        linear-gradient(0deg, rgba(45,45,45,.025) 1px, transparent 1px),
        var(--wm-cream);
    background-size: 44px 44px;
    color: var(--wm-charcoal);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.wm-topbar {
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 0 34px;
    background: rgba(255, 253, 249, .92);
    border-bottom: 1px solid var(--wm-line);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 30;
}

.wm-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--wm-charcoal);
    text-decoration: none;
}

.wm-brand-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    background: var(--wm-charcoal);
    color: #fff;
    font-family: Barlow, Arial, sans-serif;
    font-weight: 900;
    position: relative;
    overflow: hidden;
}

.wm-brand-mark::before {
    content: "";
    position: absolute;
    left: 12px;
    right: -10px;
    bottom: 7px;
    height: 5px;
    border-radius: var(--radius-pill);
    background: var(--wm-red);
    transform: rotate(-45deg);
}

.wm-brand-mark { isolation: isolate; }
.wm-brand-mark::after {
    content: "WM";
    position: relative;
    z-index: 1;
    font-size: .78rem;
}
.wm-brand-mark { font-size: 0; }

.wm-brand-text {
    font-family: Barlow, Arial, sans-serif;
    font-weight: 900;
    letter-spacing: .08em;
    font-size: .92rem;
}

.wm-brand-text b { color: var(--wm-red); }

.wm-userbox {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--wm-muted);
    font-size: .86rem;
}

.wm-userbox a {
    color: var(--wm-muted);
    text-decoration: none;
    border: 1px solid var(--wm-line);
    border-radius: var(--radius-sm);
    padding: 7px 11px;
}

.wm-userbox a:hover {
    border-color: rgba(212, 43, 30, .35);
    color: var(--wm-red);
    background: var(--wm-red-soft);
}

.wm-page {
    width: min(1280px, calc(100% - 44px));
    margin: 0 auto;
    padding: 28px 0 54px;
}

.wm-command,
.wm-portal-hero,
.wm-page-hero {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, .75fr);
    gap: 18px;
    background: linear-gradient(135deg, #242424 0%, #32302D 58%, #421F1C 100%);
    color: #fff;
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--wm-shadow);
}

.wm-command::before,
.wm-portal-hero::before,
.wm-page-hero::before {
    content: "";
    position: absolute;
    inset: -80px -120px auto auto;
    width: 330px;
    height: 420px;
    background: var(--wm-red);
    transform: rotate(21deg);
    opacity: .86;
    box-shadow: -26px 0 0 rgba(212, 43, 30, .22);
}

.wm-command-main,
.wm-portal-hero > *,
.wm-page-hero > * {
    position: relative;
    z-index: 1;
}

.wm-command-main {
    min-height: 260px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.wm-command-kicker,
.wm-label {
    display: block;
    font-size: .7rem;
    line-height: 1.2;
    font-weight: 900;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: rgba(255,255,255,.62);
}

.wm-label {
    color: var(--wm-muted);
}

.wm-command h1,
.wm-portal-hero h1,
.wm-page-hero h1 {
    margin: 7px 0 8px;
    font-family: Barlow, Arial, sans-serif;
    font-size: clamp(2rem, 4vw, 3.45rem);
    line-height: .98;
    font-weight: 900;
    letter-spacing: 0;
}

.wm-command p,
.wm-portal-hero p,
.wm-page-hero p {
    max-width: 650px;
    margin: 0;
    color: rgba(255,255,255,.74);
}

.wm-page-hero.compact {
    grid-template-columns: minmax(0, 1fr) auto;
    margin-bottom: 18px;
}

.wm-page-hero.compact h1 {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
}

.wm-command-stats {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.wm-stat-pill {
    min-width: 94px;
    min-height: 62px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    padding: 10px 13px;
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.10);
    border: 1px solid rgba(255,255,255,.15);
}

.wm-stat-pill strong {
    font-family: Barlow, Arial, sans-serif;
    font-size: 1.75rem;
    line-height: 1;
}

.wm-stat-pill span {
    font-size: .72rem;
    color: rgba(255,255,255,.72);
    text-transform: uppercase;
    letter-spacing: .08em;
    font-weight: 800;
}

.wm-stat-pill.is-warn strong { color: #FFC766; }

.wm-agenda-panel {
    position: relative;
    z-index: 1;
    background: rgba(255,255,255,.95);
    color: var(--wm-charcoal);
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: 0 20px 48px rgba(0,0,0,.22);
}

.wm-panel-head,
.wm-section-head,
.wm-module-top,
.wm-task-actions,
.wm-filterbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.wm-panel-head h2,
.wm-section-head h2,
.wm-task-form h2 {
    margin: 0;
    font-family: Barlow, Arial, sans-serif;
    font-weight: 900;
    font-size: 1.2rem;
}

.wm-icon-link {
    width: 36px;
    height: 36px;
    display: inline-grid;
    place-items: center;
    border-radius: var(--radius-sm);
    color: var(--wm-red);
    border: 1px solid var(--wm-line);
    text-decoration: none;
}

.wm-agenda-list,
.wm-task-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}

.wm-agenda-item,
.wm-task-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--wm-line);
    border-left: 5px solid var(--wm-red);
    border-radius: var(--radius-sm);
    background: #fff;
}

.priority-media { border-left-color: var(--wm-blue); }
.priority-baja { border-left-color: var(--wm-green); }
.priority-alta { border-left-color: var(--wm-red); }

.wm-agenda-item strong,
.wm-task-title {
    display: block;
    font-weight: 850;
}

.wm-agenda-item span,
.wm-task-meta,
.wm-task-row p {
    color: var(--wm-muted);
    font-size: .82rem;
}

.wm-check-button,
.wm-quick-task button {
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: var(--radius-sm);
    display: grid;
    place-items: center;
    color: #fff;
    background: var(--wm-red);
}

.wm-quick-task {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 136px 38px;
    gap: 8px;
    margin-top: 14px;
}

.wm-quick-task input,
.wm-task-actions input {
    height: 38px;
    border: 1px solid var(--wm-line);
    border-radius: var(--radius-sm);
    padding: 0 10px;
}

.wm-empty {
    min-height: 145px;
    display: grid;
    place-items: center;
    align-content: center;
    text-align: center;
    gap: 5px;
    border: 1px dashed var(--wm-line);
    border-radius: var(--radius-sm);
    color: var(--wm-muted);
    margin-top: 14px;
    padding: 16px;
}

.wm-empty.large { min-height: 280px; }
.wm-empty i { font-size: 1.8rem; color: var(--wm-red); }
.wm-empty strong { color: var(--wm-charcoal); }

.wm-section-head {
    margin: 28px 2px 14px;
    border-bottom: 1px solid var(--wm-line);
    padding-bottom: 10px;
}

.wm-section-head span {
    color: var(--wm-muted);
    font-size: .85rem;
    font-weight: 700;
}

.wm-module-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(266px, 1fr));
    gap: 14px;
}

.wm-module-card {
    --accent: var(--wm-red);
    min-height: 206px;
    color: var(--wm-charcoal);
    background: var(--wm-paper);
    text-decoration: none;
    border: 1px solid var(--wm-line);
    border-radius: var(--radius-sm);
    padding: 17px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(45,45,45,.06);
    transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}

.wm-module-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    background: var(--accent);
}

.wm-module-card:not(.is-locked):hover {
    transform: translateY(-3px);
    border-color: var(--accent);
    box-shadow: 0 18px 36px rgba(45,45,45,.16);
}

.wm-module-card.is-locked {
    opacity: .74;
    cursor: not-allowed;
}

.wm-module-icon {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 12%, white);
    font-size: 1.45rem;
}

.wm-state {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: var(--radius-pill);
    padding: 5px 10px;
    font-size: .72rem;
    font-weight: 850;
    white-space: nowrap;
}

.wm-state.is-ok { color: var(--wm-green); background: var(--ok-soft); }
.wm-state.is-review { color: var(--wm-amber); background: var(--warn-soft); }
.wm-state.is-blocked { color: #6E6963; background: #F0EEE9; }

.wm-module-card h3 {
    font-family: Barlow, Arial, sans-serif;
    font-size: 1.18rem;
    line-height: 1.1;
    font-weight: 900;
    margin: 18px 0 8px;
}

.wm-module-card p {
    margin: 0;
    color: var(--wm-muted);
    line-height: 1.42;
    font-size: .9rem;
}

.wm-module-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 18px;
    color: var(--accent);
    font-weight: 850;
}

.wm-foot {
    margin-top: 36px;
    color: var(--wm-muted);
    text-align: center;
    font-size: .82rem;
}

.wm-content-shell {
    width: min(1240px, 100%);
    margin: 0 auto;
}

.wm-agenda-layout {
    display: grid;
    grid-template-columns: minmax(300px, 360px) minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.wm-task-form,
.wm-task-board {
    background: linear-gradient(145deg, rgba(255,255,255,.082), rgba(255,255,255,.034)), rgba(12,17,17,.94);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: var(--radius-sm);
    padding: 16px;
    color: #f7f2ea;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 22px 56px rgba(0,0,0,.24);
}

.wm-task-form label {
    display: block;
    margin: 12px 0 5px;
    color: rgba(255,255,255,.64);
    font-size: .78rem;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.wm-task-form .form-control,
.wm-task-form .form-select,
.wm-task-board .form-control,
.wm-task-board .form-select,
.wm-task-actions input {
    color: #fff;
    background-color: rgba(255,255,255,.065);
    border-color: rgba(255,255,255,.15);
}

.wm-task-form .form-control::placeholder,
.wm-task-board .form-control::placeholder {
    color: rgba(255,255,255,.60);
}

.wm-task-form h2,
.wm-task-title,
.wm-empty strong {
    color: #fff;
}

.wm-task-guidance {
    margin: 10px 0 4px;
    padding: 12px;
    border: 1px solid rgba(255,51,43,.26);
    border-radius: var(--radius);
    background: rgba(255,51,43,.08);
}

.wm-task-guidance span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #ffb5ad;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: .72rem;
}

.wm-task-guidance p {
    margin: 6px 0 0;
    color: rgba(255,255,255,.66);
    font-size: .86rem;
    line-height: 1.35;
}

.wm-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.wm-form-grid > * {
    min-width: 0;
}

.wm-form-grid > div:nth-child(3) {
    grid-column: 1 / -1;
}

.wm-form-grid.two {
    grid-template-columns: 1fr 1fr;
}

.wm-form-grid.two > div:nth-child(3) {
    grid-column: auto;
}

.wm-filterbar {
    justify-content: flex-start;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.wm-filterbar .form-select,
.wm-filterbar .form-control {
    width: auto;
    min-width: 170px;
}

.wm-empty {
    color: rgba(255,255,255,.62);
    border-color: rgba(255,255,255,.12);
    background: rgba(255,255,255,.025);
}

.wm-empty-hints {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.wm-empty-hints span {
    display: inline-flex;
    gap: 5px;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: var(--radius-pill);
    padding: 6px 9px;
    color: rgba(255,255,255,.68);
    background: rgba(255,255,255,.045);
    font-size: .78rem;
}

.wm-empty-hints b {
    color: #ffb5ad;
}

.wm-task-row {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
}

.wm-task-actions {
    align-items: start;
    flex-wrap: wrap;
}

.wm-task-actions form {
    display: flex;
    gap: 6px;
}

.wm-login-body {
    min-height: 100vh;
    margin: 0;
    display: grid;
    place-items: center;
    padding: 24px;
    background:
        linear-gradient(115deg, transparent 0 43%, rgba(212,43,30,.22) 43% 44%, transparent 44% 100%),
        linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.04) 1px, transparent 1px),
        #171717;
    background-size: auto, 44px 44px, 44px 44px;
    color: #fff;
}

.wm-login-shell {
    width: min(980px, 100%);
    min-height: 560px;
    display: grid;
    grid-template-columns: 1.08fr .92fr;
    overflow: hidden;
    border-radius: 14px;
    background: #202020;
    box-shadow: 0 30px 80px rgba(0,0,0,.38);
    border: 1px solid rgba(255,255,255,.09);
}

.wm-login-brand {
    position: relative;
    padding: 38px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
}

.wm-login-brand::before {
    content: "";
    position: absolute;
    inset: -40% -20%;
    background: linear-gradient(110deg, transparent 38%, rgba(212,43,30,.66) 45%, rgba(255,255,255,.18) 46%, transparent 54%);
    animation: wm-login-scan 5.8s ease-in-out infinite;
}

.wm-login-brand > * {
    position: relative;
    z-index: 1;
}

.wm-login-title {
    font-family: Barlow, Arial, sans-serif;
    font-size: clamp(2.6rem, 5vw, 4.4rem);
    font-weight: 900;
    line-height: .92;
    margin: 0;
}

.wm-login-title span { color: var(--wm-red); }

.wm-login-brand p {
    max-width: 420px;
    color: rgba(255,255,255,.72);
    margin: 16px 0 0;
}

.wm-login-panel {
    margin: 18px;
    padding: 30px;
    border-radius: var(--radius);
    background: rgba(255,255,255,.96);
    color: var(--wm-charcoal);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.wm-login-panel .form-label {
    font-size: .78rem;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.wm-login-panel .form-control {
    min-height: 44px;
    border-radius: var(--radius-sm);
}

.wm-login-panel .form-control:focus {
    border-color: var(--wm-red);
    box-shadow: 0 0 0 .2rem rgba(212,43,30,.15);
}

.wm-login-note {
    color: #607069;
    font-size: .76rem;
    line-height: 1.35;
}

.wm-login-button {
    min-height: 46px;
    border: 0;
    border-radius: var(--radius-sm);
    background: var(--wm-red);
    color: #fff;
    font-weight: 900;
    width: 100%;
}

.wm-login-transition {
    display: none;
    margin-top: 14px;
    padding: 12px;
    border-radius: var(--radius-sm);
    background: #222;
    color: #fff;
}

.is-entering .wm-login-transition {
    display: block;
}

.wm-launch-screen {
    min-height: 100vh;
    margin: 0;
    overflow: hidden;
    color: #fff;
    background: #070909;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.wm-launch-stage {
    min-height: 100vh;
    position: relative;
    display: grid;
    place-items: center;
    isolation: isolate;
    background:
        radial-gradient(circle at 70% 45%, rgba(255,51,43,.22), transparent 30%),
        linear-gradient(115deg, transparent 0 42%, rgba(255,51,43,.18) 42% 43%, transparent 43% 100%);
}

.wm-launch-grid {
    position: absolute;
    inset: 0;
    z-index: -4;
    background:
        linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.035) 1px, transparent 1px);
    background-size: 52px 52px;
    mask-image: radial-gradient(circle at center, #000 0 55%, transparent 82%);
}

.wm-launch-orbit,
.wm-launch-beam {
    position: absolute;
    z-index: -2;
    border-radius: var(--radius-pill);
    pointer-events: none;
}

.wm-launch-orbit {
    width: 72vw;
    height: 26vh;
    border-bottom: 3px solid rgba(255,51,43,.78);
    transform: rotate(-7deg);
    filter: drop-shadow(0 0 14px rgba(255,51,43,.95)) drop-shadow(0 0 42px rgba(255,51,43,.44));
    animation: wm-launch-orbit 4.8s ease-in-out infinite;
}

.wm-launch-beam {
    left: 10vw;
    right: 6vw;
    top: 58%;
    height: 3px;
    background: linear-gradient(90deg, transparent, rgba(255,51,43,.35), #fff, var(--wm-red-hot), transparent);
    box-shadow: 0 0 22px rgba(255,51,43,.9), 0 0 70px rgba(255,51,43,.45);
    transform: rotate(-12deg);
    animation: wm-launch-beam 3.4s ease-in-out infinite;
}

.wm-launch-card {
    width: min(560px, calc(100% - 36px));
    position: relative;
    overflow: hidden;
    padding: 34px;
    border-radius: var(--radius);
    border: 1px solid rgba(255,255,255,.14);
    background:
        linear-gradient(145deg, rgba(255,255,255,.10), rgba(255,255,255,.04)),
        rgba(13,17,17,.84);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 34px 90px rgba(0,0,0,.46);
    backdrop-filter: blur(18px);
}

.wm-launch-card::before {
    content: "";
    position: absolute;
    inset: -30% -18% auto auto;
    width: 210px;
    height: 330px;
    background: linear-gradient(180deg, rgba(255,51,43,.86), rgba(255,51,43,.08));
    transform: rotate(23deg);
    opacity: .82;
}

.wm-launch-card > * {
    position: relative;
    z-index: 1;
}

.wm-launch-kicker {
    display: block;
    margin-top: 34px;
    color: var(--wm-red-hot);
    font-family: Barlow, Arial, sans-serif;
    font-weight: 900;
    letter-spacing: .14em;
    text-transform: uppercase;
    font-size: .72rem;
}

.wm-launch-card h1 {
    margin: 8px 0 10px;
    font-family: Barlow, Arial, sans-serif;
    font-size: clamp(2.2rem, 5vw, 4rem);
    line-height: .92;
    font-weight: 900;
}

.wm-launch-card p {
    margin: 0;
    max-width: 410px;
    color: rgba(255,255,255,.68);
}

.wm-launch-status {
    display: flex;
    gap: 8px;
    margin-top: 26px;
}

.wm-launch-status span {
    width: 42px;
    height: 5px;
    border-radius: var(--radius-pill);
    background: rgba(255,255,255,.18);
    animation: wm-launch-step 1.1s ease-in-out infinite;
}

.wm-launch-status span:nth-child(2) { animation-delay: .16s; }
.wm-launch-status span:nth-child(3) { animation-delay: .32s; }

.wm-launch-link {
    display: inline-flex;
    margin-top: 22px;
    color: rgba(255,255,255,.58);
    font-size: .82rem;
    text-decoration: none;
}

@keyframes wm-login-scan {
    0%, 100% { transform: translateX(-32%); opacity: .22; }
    48%, 56% { transform: translateX(18%); opacity: .42; }
}

@keyframes wm-launch-orbit {
    0%, 100% { transform: translateX(-2%) rotate(-7deg); opacity: .68; }
    50% { transform: translateX(3%) rotate(-5deg); opacity: 1; }
}

@keyframes wm-launch-beam {
    0%, 100% { transform: translateX(-4%) rotate(-12deg); opacity: .48; }
    50% { transform: translateX(5%) rotate(-11deg); opacity: 1; }
}

@keyframes wm-launch-step {
    0%, 100% { background: rgba(255,255,255,.18); box-shadow: none; }
    50% { background: var(--wm-red-hot); box-shadow: 0 0 18px rgba(255,51,43,.9); }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: .001ms !important;
    }
}

@media (max-width: 920px) {
    .wm-page { width: calc(100% - 24px); padding-top: 16px; }
    .wm-command,
    .wm-portal-hero,
    .wm-page-hero,
    .wm-agenda-layout,
    .wm-login-shell {
        grid-template-columns: 1fr;
    }
    .wm-page-hero.compact {
        grid-template-columns: 1fr;
    }
    .wm-page-hero.compact .wm-command-stats {
        width: 100%;
        justify-content: stretch;
    }
    .wm-page-hero.compact .wm-stat-pill {
        flex: 1 1 0;
        min-width: 0;
    }
    .wm-command-main { min-height: 220px; }
    .wm-form-grid,
    .wm-form-grid.two,
    .wm-quick-task,
    .wm-task-row {
        grid-template-columns: 1fr;
    }
    .wm-task-actions,
    .wm-filterbar {
        align-items: stretch;
        flex-direction: column;
    }
    .wm-filterbar .form-select,
    .wm-filterbar .form-control {
        width: 100%;
    }
    .wm-login-shell { min-height: 0; }
    .wm-login-brand { min-height: 330px; }
}

@media (max-width: 860px) {
    body { overflow-x: hidden; }
    .sidebar {
        position: sticky !important;
        top: 0 !important;
        width: 100% !important;
        min-height: auto !important;
        max-height: 48vh;
        overflow: auto;
    }
    .sidebar .brand {
        position: sticky;
        top: 0;
        background: var(--wm-charcoal);
        z-index: 2;
    }
    .sidebar nav {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: 2px;
        padding: 8px !important;
    }
    .sidebar .nav-section,
    .sidebar-footer {
        display: none !important;
    }
    .main,
    .wrap {
        margin-left: 0 !important;
        width: 100% !important;
        padding: 16px !important;
    }
    .page-header {
        align-items: flex-start !important;
        flex-direction: column;
    }
    .card-body,
    .table-responsive {
        overflow-x: auto;
    }
}

@media (max-width: 620px) {
    .wm-topbar {
        height: auto;
        align-items: flex-start;
        flex-direction: column;
        padding: 12px 16px;
    }
    .wm-userbox {
        width: 100%;
        justify-content: space-between;
    }
    .wm-command,
    .wm-portal-hero,
    .wm-page-hero,
    .wm-agenda-panel,
    .wm-task-form,
    .wm-task-board {
        padding: 16px;
        border-radius: var(--radius-sm);
    }
    .wm-module-grid { grid-template-columns: 1fr; }
    .wm-login-body { padding: 12px; }
    .wm-login-brand,
    .wm-login-panel { padding: 22px; margin: 0; border-radius: 0; }
    .wm-login-shell { border-radius: var(--radius); }
    .wm-page-hero.compact h1 {
        font-size: 2.15rem;
        line-height: .96;
    }
    .wm-page-hero.compact p {
        max-width: none;
    }
    .wm-page-hero.compact .wm-command-stats {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
    }
    .wm-page-hero.compact .wm-stat-pill {
        min-height: 58px;
        padding: 9px 8px;
    }
    .wm-page-hero.compact .wm-stat-pill strong {
        font-size: 1.45rem;
    }
    .wm-page-hero.compact .wm-stat-pill span {
        font-size: .64rem;
        letter-spacing: .04em;
    }
}

/* Global polish for legacy module templates */
body:not(.wm-login-body):not(.wm-body) {
    background:
        linear-gradient(90deg, rgba(45,45,45,.028) 1px, transparent 1px),
        linear-gradient(0deg, rgba(45,45,45,.022) 1px, transparent 1px),
        var(--wm-cream) !important;
    background-size: 44px 44px !important;
}

body .page-header {
    background: rgba(255,253,249,.82);
    border: 1px solid var(--wm-line);
    border-left: 5px solid var(--wm-red);
    border-radius: var(--radius-sm);
    padding: 15px 18px;
    box-shadow: 0 2px 5px rgba(45,45,45,.05);
}

body .page-header h1 {
    font-family: Barlow, Arial, sans-serif !important;
    font-weight: 900 !important;
    letter-spacing: 0 !important;
}

body .card {
    border-color: var(--wm-line) !important;
    border-radius: var(--radius-sm) !important;
    box-shadow: 0 2px 7px rgba(45,45,45,.06) !important;
}

body .card-header {
    border-bottom-color: var(--wm-line) !important;
    font-family: Barlow, Arial, sans-serif;
    font-weight: 850 !important;
}

body .btn {
    border-radius: var(--radius-sm);
    font-weight: 750;
}

body .btn-primary {
    background: var(--wm-red) !important;
    border-color: var(--wm-red) !important;
}

body .btn-primary:hover,
body .btn-primary:focus {
    background: var(--wm-red-dark) !important;
    border-color: var(--wm-red-dark) !important;
}

body .btn-outline-primary {
    color: var(--wm-red) !important;
    border-color: var(--wm-red) !important;
}

body .btn-outline-primary:hover,
body .btn-outline-primary:focus {
    color: #fff !important;
    background: var(--wm-red) !important;
    border-color: var(--wm-red) !important;
}

body .table {
    --bs-table-bg: #fff;
    border-color: var(--wm-line);
}

body .table th {
    color: var(--wm-muted) !important;
    font-size: .72rem !important;
    font-weight: 850 !important;
    text-transform: uppercase;
    letter-spacing: .06em;
}

body .table td {
    vertical-align: middle;
}

body .table-responsive {
    border-radius: var(--radius-sm);
}

body input.form-control,
body select.form-select,
body textarea.form-control {
    border-radius: var(--radius-sm);
    border-color: #D8D2C8;
}

body input.form-control:focus,
body select.form-select:focus,
body textarea.form-control:focus {
    border-color: var(--wm-red) !important;
    box-shadow: 0 0 0 .2rem rgba(212,43,30,.15) !important;
}

/* Command center v2 */
.wm-body-command {
    background:
        radial-gradient(circle at 18% 0%, rgba(212,43,30,.16), transparent 30%),
        radial-gradient(circle at 86% 8%, rgba(255,255,255,.52), transparent 24%),
        linear-gradient(90deg, rgba(45,45,45,.04) 1px, transparent 1px),
        linear-gradient(0deg, rgba(45,45,45,.03) 1px, transparent 1px),
        var(--wm-cream);
    background-size: auto, auto, 44px 44px, 44px 44px;
}

.wm-command-page {
    width: min(1360px, calc(100% - 44px));
}

.wm-command-hero {
    position: relative;
    min-height: 310px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 330px);
    align-items: end;
    gap: 22px;
    overflow: hidden;
    padding: 30px;
    border-radius: 14px;
    color: #fff;
    background:
        radial-gradient(circle at 78% 22%, rgba(212,43,30,.34), transparent 28%),
        linear-gradient(135deg, #181818 0%, #272525 48%, #3B1713 100%);
    border: 1px solid rgba(255,255,255,.10);
    box-shadow:
        0 26px 70px rgba(34,24,20,.28),
        inset 0 1px 0 rgba(255,255,255,.08);
}

.wm-command-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.04) 1px, transparent 1px);
    background-size: 46px 46px;
    opacity: .55;
}

.wm-command-hero::after {
    content: "";
    position: absolute;
    left: -18%;
    right: -12%;
    top: 50%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.45), var(--wm-red), rgba(255,255,255,.28), transparent);
    box-shadow: 0 0 26px rgba(212,43,30,.86), 0 0 72px rgba(212,43,30,.38);
    transform: rotate(-12deg);
    animation: wm-ribbon-sweep 7s ease-in-out infinite;
}

.wm-light-ribbon {
    position: absolute;
    inset: -32% auto auto 52%;
    width: 140px;
    height: 760px;
    transform: rotate(22deg);
    background: linear-gradient(180deg, transparent, rgba(212,43,30,.82), rgba(255,255,255,.25), rgba(212,43,30,.50), transparent);
    filter: blur(.2px);
    opacity: .62;
    box-shadow: 0 0 48px rgba(212,43,30,.48);
    animation: wm-red-thread 8.5s ease-in-out infinite;
}

.wm-command-copy,
.wm-clock-panel {
    position: relative;
    z-index: 1;
}

.wm-command-copy h1 {
    margin: 9px 0 10px;
    font-family: Barlow, Arial, sans-serif;
    font-size: clamp(2.6rem, 5vw, 4.85rem);
    line-height: .9;
    font-weight: 900;
    letter-spacing: 0;
    text-shadow: 0 10px 38px rgba(0,0,0,.32);
}

.wm-command-copy p {
    max-width: 720px;
    color: rgba(255,255,255,.76);
    font-size: 1.02rem;
}

.wm-clock-panel {
    justify-self: end;
    width: min(100%, 320px);
    padding: 20px;
    border-radius: var(--radius);
    background: rgba(255,255,255,.10);
    border: 1px solid rgba(255,255,255,.18);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 24px 70px rgba(0,0,0,.28);
    backdrop-filter: blur(16px);
}

.wm-clock-panel .wm-label {
    color: rgba(255,255,255,.58);
}

.wm-live-clock {
    display: block;
    margin: 10px 0 2px;
    font-family: Barlow, Arial, sans-serif;
    font-size: clamp(3rem, 7vw, 5.4rem);
    line-height: .86;
    font-weight: 900;
    color: #fff;
    text-shadow: 0 0 22px rgba(212,43,30,.8), 0 0 54px rgba(212,43,30,.48);
}

.wm-clock-panel span:last-child {
    color: rgba(255,255,255,.70);
    text-transform: capitalize;
}

.wm-command-grid {
    display: grid;
    grid-template-columns: minmax(320px, .9fr) minmax(300px, .72fr) minmax(320px, .86fr);
    gap: 16px;
    margin-top: 16px;
    align-items: stretch;
}

.wm-command-card {
    min-height: 330px;
    background: rgba(255,253,249,.94);
    border: 1px solid rgba(221,216,206,.95);
    border-radius: var(--radius);
    box-shadow: 0 16px 42px rgba(45,45,45,.10);
    backdrop-filter: blur(10px);
}

.wm-calendar-panel,
.wm-alert-panel {
    padding: 16px;
}

.wm-calendar-panel .bi-calendar3,
.wm-alert-panel > .wm-panel-head > .bi {
    color: var(--wm-red);
    font-size: 1.35rem;
    filter: drop-shadow(0 0 10px rgba(212,43,30,.28));
}

.wm-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 6px;
    margin-top: 16px;
}

.wm-calendar-weekday {
    color: var(--wm-muted);
    font-size: .68rem;
    font-weight: 900;
    text-align: center;
    letter-spacing: .08em;
}

.wm-calendar-day {
    position: relative;
    min-height: 35px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    background: #fff;
    border: 1px solid #E8E2D8;
    color: var(--wm-charcoal);
    font-size: .82rem;
    font-weight: 850;
}

.wm-calendar-day.is-muted {
    opacity: .38;
}

.wm-calendar-day.is-today {
    color: #fff;
    background: var(--wm-red);
    border-color: var(--wm-red);
    box-shadow: 0 0 0 3px rgba(212,43,30,.14), 0 10px 22px rgba(212,43,30,.22);
}

.wm-calendar-day.has-marker::after {
    content: "";
    position: absolute;
    right: 6px;
    bottom: 5px;
    width: 6px;
    height: 6px;
    border-radius: var(--radius-pill);
    background: var(--wm-red);
    box-shadow: 0 0 12px rgba(212,43,30,.55);
}

.wm-calendar-day.marker-certificacion::after,
.wm-calendar-legend .marker-certificacion {
    background: var(--wm-amber);
}

.wm-calendar-day.marker-sis::after,
.wm-calendar-legend .marker-sis {
    background: var(--wm-red);
}

.wm-calendar-legend {
    display: grid;
    gap: 6px;
    margin-top: 14px;
    color: var(--wm-muted);
    font-size: .76rem;
    font-weight: 750;
}

.wm-calendar-legend span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.wm-calendar-legend i {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-pill);
    box-shadow: 0 0 10px currentColor;
}

.wm-alert-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}

.wm-alert-item {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--wm-line);
    border-left: 5px solid var(--wm-red);
    border-radius: var(--radius-sm);
    background: #fff;
}

.wm-alert-item.is-steady {
    border-left-color: var(--wm-charcoal-2);
}

.wm-alert-item.is-active {
    border-left-color: var(--wm-green);
}

.wm-alert-item.is-warning {
    border-left-color: var(--wm-amber);
    background: #FFF8EA;
}

.wm-alert-item.is-danger {
    border-left-color: var(--wm-red);
    background: #FFF1EF;
}

.wm-alert-icon {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    color: var(--wm-red);
    background: var(--wm-red-soft);
}

.wm-alert-item strong {
    display: block;
    font-weight: 900;
}

.wm-alert-item p {
    margin: 2px 0 0;
    color: var(--wm-muted);
    font-size: .82rem;
    line-height: 1.32;
}

.wm-alert-item small {
    color: var(--wm-charcoal-2);
    font-size: .7rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.wm-module-card {
    background:
        linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,253,249,.98)),
        var(--wm-paper);
}

.wm-module-card::after {
    content: "";
    position: absolute;
    inset: -40% -30% auto auto;
    width: 180px;
    height: 180px;
    border-radius: var(--radius-pill);
    background: color-mix(in srgb, var(--accent) 18%, transparent);
    filter: blur(34px);
    opacity: 0;
    transition: opacity .18s ease;
}

.wm-module-card:not(.is-locked):hover::after {
    opacity: 1;
}

.wm-module-card > * {
    position: relative;
    z-index: 1;
}

@keyframes wm-ribbon-sweep {
    0%, 100% { transform: translateX(-7%) rotate(-12deg); opacity: .34; }
    48%, 58% { transform: translateX(8%) rotate(-12deg); opacity: .92; }
}

@keyframes wm-red-thread {
    0%, 100% { transform: translateX(-16px) rotate(22deg); opacity: .38; }
    50% { transform: translateX(22px) rotate(22deg); opacity: .78; }
}

@media (max-width: 1120px) {
    .wm-command-grid {
        grid-template-columns: 1fr 1fr;
    }
    .wm-alert-panel {
        grid-column: 1 / -1;
    }
}

@media (max-width: 920px) {
    .wm-command-hero {
        grid-template-columns: 1fr;
        min-height: 0;
    }
    .wm-clock-panel {
        justify-self: stretch;
    }
    .wm-command-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .wm-command-page {
        width: calc(100% - 24px);
    }
    .wm-command-hero {
        padding: 18px;
    }
    .wm-command-copy h1 {
        font-size: 2.8rem;
    }
    .wm-command-stats {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
    }
    .wm-stat-pill {
        min-width: 0;
        padding: 9px 8px;
    }
    .wm-alert-item {
        grid-template-columns: 34px minmax(0, 1fr);
    }
    .wm-alert-item small {
        grid-column: 2;
    }
}

/* Dark command system */
:root {
    --wm-night: #070909;
    --wm-night-2: #0c1111;
    --wm-night-3: #141817;
    --wm-red-hot: #ff332b;
    --wm-red-glow: rgba(255, 51, 43, .58);
    --wm-ink-soft: rgba(255,255,255,.72);
    /* Contraste del texto atenuado del tema oscuro (fase 2 de
       accesibilidad). Calculo hecho sobre los fondos MEDIDOS en el
       navegador, no leidos del CSS: van de rgb(15,19,19) a rgb(31,35,35).
       El alfa minimo del blanco para llegar al 4,5:1 de AA es .47 sobre el
       mas claro de esos fondos. Este .48 da 4,54:1, o sea que cumple justo
       y se deja como esta; los textos que estaban por debajo se han subido
       a .60 (6,57:1) para tener margen. Regla practica para lo que venga:
       en este tema, por debajo de .47 el texto NO cumple. */
    --wm-ink-muted: rgba(255,255,255,.48);
    --wm-dark-line: rgba(255,255,255,.105);
}

.wm-dark-shell {
    margin: 0;
    min-height: 100vh;
    min-height: 100dvh;
    color: #f6f2ec;
    background:
        radial-gradient(circle at 78% -10%, rgba(255,51,43,.20), transparent 28%),
        radial-gradient(circle at 8% 26%, rgba(37,199,181,.08), transparent 26%),
        linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.035) 1px, transparent 1px),
        #070909 !important;
    background-size: auto, auto, 48px 48px, 48px 48px, auto !important;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.wm-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 50;
    width: 260px;
    display: flex;
    flex-direction: column;
    background:
        radial-gradient(circle at 120% 8%, rgba(255,51,43,.18), transparent 30%),
        linear-gradient(180deg, rgba(8,14,14,.98), rgba(5,10,10,.98));
    border-right: 1px solid rgba(255,255,255,.12);
    box-shadow: 18px 0 60px rgba(0,0,0,.42);
}

.wm-sidebar-brand {
    min-height: 92px;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 22px;
    color: #fff;
    text-decoration: none;
    border-bottom: 1px solid rgba(255,255,255,.08);
}

.wm-sidebar-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    overflow: hidden;
    position: relative;
    flex: 0 0 auto;
    border-radius: var(--radius);
    background: linear-gradient(145deg, #fff 0%, #f4f1ec 62%, #e7e0d5 100%);
    border: 1px solid rgba(255,255,255,.72);
    color: #101111;
    font-family: Barlow, Arial, sans-serif;
    font-size: .78rem;
    font-weight: 900;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,.9),
        0 0 0 1px rgba(0,0,0,.18),
        0 14px 30px rgba(0,0,0,.28);
}

.wm-sidebar-mark::after {
    content: "";
    position: absolute;
    right: -9px;
    bottom: 5px;
    width: 34px;
    height: 7px;
    border-radius: var(--radius-pill);
    background: var(--wm-red-hot);
    transform: rotate(-42deg);
    box-shadow: 0 0 18px rgba(255,51,43,.58);
}

.wm-sidebar-brand strong {
    display: block;
    font-family: Barlow, Arial, sans-serif;
    font-size: 1rem;
    line-height: 1;
    font-weight: 900;
    letter-spacing: .05em;
}

.wm-sidebar-brand b {
    color: var(--wm-red-hot);
}

.wm-sidebar-brand small {
    display: block;
    margin-top: 8px;
    color: rgba(255,255,255,.60);
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .12em;
}

.wm-project-switch {
    margin: 0 16px 8px;
    padding: 12px;
    border: 1px solid rgba(255,51,43,.24);
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, rgba(255,51,43,.13), rgba(255,255,255,.045));
    box-shadow: inset 0 1px 0 rgba(255,255,255,.05), 0 0 28px rgba(255,51,43,.08);
}

.wm-project-switch label {
    display: block;
    margin-bottom: 7px;
    color: rgba(255,255,255,.60);
    font-size: .64rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .13em;
}

.wm-project-switch-current {
    display: grid;
    gap: 3px;
    margin: 0 0 9px;
    padding: 10px 11px;
    border-radius: var(--radius-sm);
    background:
        linear-gradient(90deg, rgba(255,51,43,.22), rgba(255,255,255,.055)),
        rgba(0,0,0,.24);
    border: 1px solid rgba(255,51,43,.28);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 0 28px rgba(255,51,43,.12);
}

.wm-project-switch-current span {
    color: rgba(255,255,255,.48);
    font-size: .58rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .13em;
}

.wm-project-switch-current strong {
    color: #fff;
    font-family: Barlow, Arial, sans-serif;
    font-size: .92rem;
    font-style: normal;
    font-weight: 900;
    line-height: 1.08;
    text-transform: uppercase;
    text-shadow: 0 0 18px rgba(255,51,43,.32);
}

.wm-project-switch select {
    width: 100%;
    min-height: 38px;
    padding: 0 10px;
    border: 1px solid rgba(255,255,255,.14);
    border-radius: var(--radius-sm);
    color: #fff;
    background: rgba(8,13,13,.92);
    font-weight: 800;
    outline: none;
}

.wm-project-switch select:focus {
    border-color: rgba(255,51,43,.72);
    box-shadow: 0 0 0 3px rgba(255,51,43,.16);
}

.wm-project-context {
    position: sticky;
    top: 14px;
    z-index: 26;
    display: grid;
    grid-template-columns: auto minmax(220px, 1fr) auto auto;
    align-items: center;
    gap: 13px;
    min-height: 74px;
    margin: 0 0 18px;
    padding: 12px 14px;
    overflow: hidden;
    border: 1px solid rgba(255,51,43,.28);
    border-radius: var(--radius-sm);
    color: #f7f2ea;
    background:
        radial-gradient(circle at 16% 50%, rgba(255,51,43,.22), transparent 30%),
        linear-gradient(115deg, rgba(255,255,255,.08), rgba(255,255,255,.035) 42%, rgba(255,51,43,.12)),
        rgba(9,14,14,.94);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,.08),
        0 22px 64px rgba(0,0,0,.28),
        0 0 42px rgba(255,51,43,.10);
    backdrop-filter: blur(18px);
}

.wm-project-context::after {
    content: "";
    position: absolute;
    inset: -60% -20% auto auto;
    width: 240px;
    height: 180px;
    pointer-events: none;
    background: linear-gradient(120deg, transparent, rgba(255,51,43,.24), transparent);
    transform: rotate(-18deg);
    animation: wm-project-sweep 5.8s ease-in-out infinite;
}

.wm-project-context-beacon {
    position: relative;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid rgba(255,51,43,.52);
    background: rgba(255,51,43,.10);
    box-shadow: 0 0 28px rgba(255,51,43,.24);
}

.wm-project-context-beacon::before,
.wm-project-context-beacon::after {
    content: "";
    position: absolute;
    inset: 11px;
    border-radius: inherit;
    background: var(--wm-red-hot);
    box-shadow: 0 0 18px rgba(255,51,43,.92), 0 0 42px rgba(255,51,43,.45);
}

.wm-project-context-beacon::after {
    inset: 3px;
    background: transparent;
    border: 1px solid rgba(255,51,43,.32);
    animation: wm-project-pulse 2.4s ease-out infinite;
}

.wm-project-context-main {
    position: relative;
    z-index: 1;
    min-width: 0;
}

.wm-project-context-main span {
    display: block;
    margin-bottom: 3px;
    color: rgba(255,255,255,.52);
    font-size: .66rem;
    font-weight: 900;
    letter-spacing: .15em;
    line-height: 1.15;
    text-transform: uppercase;
}

.wm-project-context-main strong {
    display: flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
    color: #fff;
    font-family: Barlow, Arial, sans-serif;
    font-size: clamp(1.2rem, 2vw, 1.75rem);
    font-weight: 900;
    line-height: 1;
    letter-spacing: 0;
    text-shadow: 0 0 24px rgba(255,51,43,.24);
}

.wm-project-context-main strong b,
.wm-hero-project.is-featured strong b {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    color: #fff;
    background: var(--wm-red-hot);
    box-shadow: 0 0 18px rgba(255,51,43,.45);
    font-size: .78em;
    line-height: 1;
}

.wm-project-context-main small {
    display: block;
    margin-top: 5px;
    color: rgba(255,255,255,.66);
    font-size: .82rem;
    line-height: 1.25;
}

.wm-project-context-obras {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 7px;
    max-width: min(44vw, 520px);
}

.wm-project-context-obras span,
.wm-project-context-obras em {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 30px;
    padding: 5px 9px;
    border-radius: var(--radius-pill);
    color: rgba(255,255,255,.82);
    background: rgba(255,255,255,.075);
    border: 1px solid rgba(255,255,255,.12);
    font-size: .78rem;
    font-style: normal;
    font-weight: 800;
    white-space: nowrap;
}

.wm-project-context-obras span b {
    color: var(--wm-red-hot);
    font-family: Barlow, Arial, sans-serif;
    font-weight: 900;
}

.wm-project-context-action {
    position: relative;
    z-index: 1;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    border-radius: var(--radius-sm);
    color: #fff;
    text-decoration: none;
    background: rgba(255,51,43,.16);
    border: 1px solid rgba(255,51,43,.34);
    font-size: .78rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.wm-project-context-action:hover {
    color: #fff;
    background: rgba(255,51,43,.28);
    box-shadow: 0 0 24px rgba(255,51,43,.18);
}

.wm-sidebar-nav {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 12px 10px 18px;
}

.wm-sidebar-section {
    display: block;
    margin: 26px 12px 9px;
    color: rgba(255,255,255,.60);
    font-size: .68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .13em;
}

.wm-sidebar-group {
    margin: 18px 0 0;
}

.wm-sidebar-group summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 0 12px 8px;
    color: rgba(255,255,255,.60);
    cursor: pointer;
    list-style: none;
    font-size: .68rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .13em;
    user-select: none;
}

.wm-sidebar-group summary::-webkit-details-marker {
    display: none;
}

.wm-sidebar-group summary i {
    color: rgba(255,255,255,.60);
    font-size: .76rem;
    transition: transform .16s ease, color .16s ease;
}

.wm-sidebar-group:not([open]) summary i {
    transform: rotate(-90deg);
}

.wm-sidebar-group summary:hover,
.wm-sidebar-group summary:hover i {
    color: rgba(255,255,255,.78);
}

.wm-sidebar-group-links {
    display: grid;
    gap: 4px;
}

.wm-sidebar-link {
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 4px;
    padding: 0 13px;
    border-radius: var(--radius-sm);
    color: rgba(255,255,255,.66);
    text-decoration: none;
    border-left: 3px solid transparent;
    transition: transform .16s ease, color .16s ease, background .16s ease, border-color .16s ease;
}

.wm-sidebar-link i {
    width: 18px;
    color: rgba(255,255,255,.66);
    font-size: 1.05rem;
    transition: color .16s ease, transform .16s ease, filter .16s ease;
}

.wm-sidebar-link small {
    margin-left: auto;
    color: rgba(255,255,255,.60);
    font-size: .62rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.wm-sidebar-link:hover,
.wm-sidebar-link.active {
    color: #fff;
    background: linear-gradient(90deg, rgba(255,51,43,.22), rgba(255,255,255,.055));
    border-left-color: var(--wm-red-hot);
    transform: translateX(2px);
}

.wm-sidebar-link:hover i,
.wm-sidebar-link.active i {
    color: var(--wm-red-hot);
    filter: drop-shadow(0 0 10px rgba(255,51,43,.68));
}

.wm-sidebar-link.is-locked {
    opacity: .38;
    cursor: not-allowed;
    filter: grayscale(.42);
}

.wm-sidebar-link.is-locked:hover {
    color: rgba(255,255,255,.66);
    background: transparent;
    border-left-color: transparent;
    transform: none;
}

.wm-sidebar-link.is-locked:hover i {
    color: rgba(255,255,255,.66);
    filter: none;
}

.wm-sidebar-footer {
    padding: 20px 22px 24px;
    border-top: 1px solid rgba(255,255,255,.08);
    color: var(--wm-ink-muted);
}

.wm-sidebar-maker {
    margin-bottom: 18px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255,255,255,.08);
}

.wm-sidebar-footer span {
    display: block;
    margin-bottom: 8px;
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .13em;
}

.wm-sidebar-footer strong {
    display: block;
    margin-bottom: 18px;
    color: rgba(255,255,255,.78);
    font-family: Georgia, "Times New Roman", serif;
    font-style: italic;
    font-weight: 400;
}

.wm-sidebar-maker strong {
    margin-bottom: 0;
    color: rgba(255,255,255,.88);
    line-height: 1.2;
}

.wm-sidebar-footer a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,.52);
    text-decoration: none;
    font-size: .85rem;
}

.wm-sidebar-footer a:hover {
    color: #fff;
}

.wm-dark-main {
    margin-left: 260px;
    min-height: 100vh;
    padding: 20px 22px 46px;
}

.wm-dark-hero,
.wm-dark-card {
    border: 1px solid var(--wm-dark-line);
    background:
        linear-gradient(145deg, rgba(255,255,255,.075), rgba(255,255,255,.035)),
        rgba(12,17,17,.82);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 24px 70px rgba(0,0,0,.28);
    backdrop-filter: blur(18px);
}

.wm-dark-hero {
    position: relative;
    min-height: 220px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
    align-items: center;
    gap: 24px;
    overflow: hidden;
    border-radius: var(--radius-sm);
    padding: 30px 34px;
    isolation: isolate;
}

.wm-dark-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -3;
    background:
        radial-gradient(circle at 62% 50%, rgba(255,51,43,.16), transparent 29%),
        linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.025) 1px, transparent 1px);
    background-size: auto, 48px 48px, 48px 48px;
}

.wm-dark-hero::after {
    content: "";
    position: absolute;
    z-index: -2;
    left: 30%;
    right: 4%;
    top: 2%;
    height: 180px;
    border-bottom: 3px solid rgba(255,51,43,.82);
    border-radius: 0 0 65% 65%;
    transform: rotate(2deg);
    filter: drop-shadow(0 0 10px rgba(255,51,43,.85)) drop-shadow(0 0 34px rgba(255,51,43,.42));
    animation: wm-dark-curve 8s ease-in-out infinite;
}

.wm-red-beam {
    position: absolute;
    z-index: -1;
    left: 24%;
    right: -8%;
    top: 50%;
    height: 3px;
    border-radius: var(--radius-pill);
    background: linear-gradient(90deg, transparent, rgba(255,51,43,.18), #fff, var(--wm-red-hot), transparent);
    box-shadow: 0 0 18px var(--wm-red-glow), 0 0 62px rgba(255,51,43,.46);
    transform: rotate(-8deg);
    animation: wm-dark-beam 7.5s ease-in-out infinite;
}

.wm-red-beam.secondary {
    left: 35%;
    right: -5%;
    top: 15%;
    opacity: .74;
    transform: rotate(-48deg);
    animation-duration: 9.5s;
}

.wm-llorca-arrow {
    position: absolute;
    z-index: -1;
    right: 5%;
    top: -22%;
    width: clamp(300px, 25vw, 520px);
    height: auto;
    opacity: .96;
    transform-origin: 55% 58%;
    filter:
        drop-shadow(0 0 30px rgba(255,51,43,1))
        drop-shadow(0 0 92px rgba(255,51,43,.72))
        drop-shadow(0 0 190px rgba(255,51,43,.48));
    transform: rotate(-9deg);
    animation: wm-llorca-arrow-flight 5.8s cubic-bezier(.45,0,.2,1) infinite;
}

.wm-hero-copy span {
    display: block;
    margin-bottom: 8px;
    color: var(--wm-red-hot);
    font-family: Barlow, Arial, sans-serif;
    font-size: 1.05rem;
    font-weight: 900;
}

.wm-hero-copy h1 {
    margin: 0;
    font-family: Barlow, Arial, sans-serif;
    font-size: clamp(2.35rem, 4vw, 3.35rem);
    line-height: .92;
    font-weight: 900;
    letter-spacing: 0;
}

.wm-hero-copy h1 b {
    color: var(--wm-red-hot);
    font-weight: 900;
    text-shadow: 0 0 28px rgba(255,51,43,.42);
}

.wm-hero-copy p {
    max-width: 610px;
    margin: 14px 0 0;
    color: rgba(255,255,255,.74);
    font-size: 1.02rem;
    line-height: 1.45;
}

.wm-hero-project {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-top: 16px;
    padding: 8px 12px;
    border: 1px solid rgba(255,51,43,.28);
    border-radius: var(--radius-pill);
    background: rgba(255,51,43,.11);
    color: rgba(255,255,255,.74);
    box-shadow: 0 0 28px rgba(255,51,43,.12);
}

.wm-hero-project i,
.wm-hero-project strong {
    color: #ff3b30;
}

.wm-hero-project span {
    margin: 0;
    color: rgba(255,255,255,.54);
    font-size: .72rem;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.wm-hero-project strong {
    font-family: Barlow, Arial, sans-serif;
    font-size: .92rem;
    letter-spacing: .02em;
}

.wm-hero-project.is-featured {
    align-items: flex-start;
    gap: 12px;
    width: min(100%, 520px);
    margin-top: 20px;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    background:
        linear-gradient(105deg, rgba(255,51,43,.22), rgba(255,255,255,.055)),
        rgba(7,9,9,.48);
    border-color: rgba(255,51,43,.42);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.07), 0 0 42px rgba(255,51,43,.16);
}

.wm-hero-project.is-featured > i {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 50%;
    background: rgba(255,51,43,.14);
    border: 1px solid rgba(255,51,43,.32);
    filter: drop-shadow(0 0 12px rgba(255,51,43,.55));
}

.wm-hero-project.is-featured div {
    min-width: 0;
}

.wm-hero-project.is-featured span {
    margin-bottom: 5px;
}

.wm-hero-project.is-featured strong {
    display: flex;
    align-items: center;
    gap: 9px;
    color: #fff;
    font-size: clamp(1.1rem, 1.6vw, 1.42rem);
    line-height: 1;
    text-transform: uppercase;
}

.wm-hero-project.is-featured small {
    display: block;
    margin-top: 6px;
    color: rgba(255,255,255,.66);
    font-size: .86rem;
    line-height: 1.28;
}

.wm-hero-clock {
    justify-self: end;
    text-align: left;
}

.wm-hero-clock .wm-live-clock {
    margin: 0 0 10px;
    color: #f7f2ec;
    font-family: "JetBrains Mono", Consolas, monospace;
    font-size: clamp(2.7rem, 4.6vw, 4.2rem);
    line-height: .95;
    font-weight: 700;
    text-shadow: 0 0 22px rgba(255,51,43,.38);
}

.wm-hero-clock span {
    display: block;
    color: rgba(255,255,255,.68);
    font-size: 1rem;
    text-transform: capitalize;
}

.wm-metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin: 12px 0;
}

.wm-metric-card {
    min-height: 112px;
    display: grid;
    grid-template-columns: 62px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    border-radius: var(--radius-sm);
    padding: 18px;
}

.wm-metric-icon {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-pill);
    color: #fff;
    border: 1px solid rgba(255,51,43,.82);
    background: radial-gradient(circle, rgba(255,51,43,.18), rgba(255,255,255,.04));
    box-shadow: 0 0 30px rgba(255,51,43,.24);
    font-size: 1.35rem;
}

.wm-metric-card small,
.wm-dark-panel-head span,
.wm-dark-section-head span {
    display: block;
    color: rgba(255,255,255,.58);
    font-size: .72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .12em;
}

.wm-metric-card strong {
    display: block;
    margin-top: 4px;
    color: #fff;
    font-family: Barlow, Arial, sans-serif;
    font-size: 1.45rem;
    line-height: 1;
    font-weight: 900;
}

.wm-metric-card strong.is-green {
    color: #20c76d;
}

.wm-metric-card p {
    margin: 8px 0 0;
    color: rgba(255,255,255,.58);
    font-size: .82rem;
}

.wm-metric-card p i {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 7px;
    border-radius: var(--radius-pill);
    background: #20c76d;
    box-shadow: 0 0 14px rgba(32,199,109,.58);
}

.wm-metric-progress {
    display: block;
    height: 6px;
    overflow: hidden;
    margin-top: 8px;
    border-radius: var(--radius-pill);
    background: rgba(255,255,255,.15);
}

.wm-metric-progress span {
    display: block;
    height: 100%;
    max-width: 100%;
    border-radius: inherit;
    background: var(--wm-red-hot);
    box-shadow: 0 0 18px rgba(255,51,43,.65);
}

.wm-command-layout {
    display: grid;
    grid-template-columns: minmax(420px, .82fr) minmax(460px, 1fr);
    gap: 12px;
}

.wm-right-stack {
    display: grid;
    gap: 12px;
}

.wm-dark-panel {
    border-radius: var(--radius-sm);
    padding: 16px;
}

.wm-dark-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 36px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,.09);
}

.wm-dark-panel-head div {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.wm-dark-panel-head i {
    color: var(--wm-red-hot);
    font-size: 1.2rem;
    filter: drop-shadow(0 0 10px rgba(255,51,43,.58));
}

.wm-dark-panel-head a,
.wm-dark-panel-head small {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 32px;
    padding: 0 12px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,.15);
    color: rgba(255,255,255,.82);
    background: rgba(255,255,255,.035);
    text-decoration: none;
    font-size: .78rem;
    font-weight: 800;
}

.wm-timeline-list {
    display: grid;
}

.wm-timeline-item {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr) 34px;
    gap: 10px;
    align-items: center;
    min-height: 62px;
    border-bottom: 1px solid rgba(255,255,255,.09);
}

.wm-timeline-item time {
    color: rgba(255,255,255,.58);
    font-variant-numeric: tabular-nums;
}

.wm-timeline-item strong {
    display: block;
    color: #fff;
    font-weight: 850;
}

.wm-timeline-item span {
    display: block;
    margin-top: 4px;
    color: rgba(255,255,255,.52);
    font-size: .82rem;
}

.wm-timeline-item button,
.wm-dark-quick-task button {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: var(--radius-sm);
    color: #fff;
    background: var(--wm-red-hot);
    box-shadow: 0 0 18px rgba(255,51,43,.35);
}

.wm-dark-empty {
    min-height: 148px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 6px;
    margin: 12px 0;
    border: 1px dashed rgba(255,255,255,.14);
    border-radius: var(--radius-sm);
    color: rgba(255,255,255,.56);
    text-align: center;
}

.wm-dark-empty i {
    color: var(--wm-red-hot);
    font-size: 1.8rem;
    filter: drop-shadow(0 0 12px rgba(255,51,43,.55));
}

.wm-dark-empty strong {
    color: #fff;
}

.wm-dark-quick-task {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 150px 36px;
    gap: 8px;
    margin: 12px 0 4px;
}

.wm-dark-quick-task input {
    height: 36px;
    min-width: 0;
    color: #fff;
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.14);
    border-radius: var(--radius-sm);
    padding: 0 10px;
}

.wm-dark-quick-task input::placeholder {
    color: rgba(255,255,255,.60);
}

.wm-dark-calendar {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid rgba(255,255,255,.09);
}

.wm-dark-calendar header {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr) 30px auto;
    gap: 8px;
    align-items: center;
    margin-bottom: 12px;
}

.wm-dark-calendar header button,
.wm-dark-calendar header span {
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,.15);
    color: rgba(255,255,255,.78);
    background: rgba(255,255,255,.035);
}

.wm-dark-calendar header button {
    cursor: default;
}

.wm-dark-calendar header strong {
    color: #fff;
    font-family: Barlow, Arial, sans-serif;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.wm-dark-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 6px;
}

.wm-dark-calendar .wm-calendar-weekday {
    color: rgba(255,255,255,.48);
}

.wm-dark-calendar .wm-calendar-day {
    /* El min-height (zona tactil, fase 2 de accesibilidad punto a) se fija
       mas abajo, en la regla que trae el resto del layout de esta misma
       clase -- ver el comentario alli. */
    color: rgba(255,255,255,.90);
    background: transparent;
    border: 0;
    font-size: .88rem;
}

.wm-dark-calendar .wm-calendar-day.is-muted {
    color: rgba(255,255,255,.60);
}

.wm-dark-calendar .wm-calendar-day.is-today {
    color: #fff;
    background: var(--wm-red-hot);
    border-radius: var(--radius-sm);
    box-shadow: 0 0 22px rgba(255,51,43,.48);
}

.wm-dark-calendar .wm-calendar-day.has-marker::after {
    right: 50%;
    bottom: 1px;
    transform: translateX(50%);
    width: 5px;
    height: 5px;
}

.wm-dark-calendar p {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
    align-items: center;
    margin: 12px 0 0;
    color: rgba(255,255,255,.55);
    font-size: .78rem;
}

.wm-dark-calendar p i {
    display: inline-block;
    width: 7px;
    height: 7px;
    margin-right: -12px;
    border-radius: var(--radius-pill);
}

.wm-dark-alert-list {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.wm-dark-alert {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    min-height: 70px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,.10);
    background: rgba(255,255,255,.035);
}

.wm-dark-alert > span {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-pill);
    color: var(--wm-red-hot);
    background: rgba(255,51,43,.12);
    border: 1px solid rgba(255,51,43,.32);
}

.wm-dark-alert strong {
    display: block;
    color: #fff;
    font-weight: 850;
}

.wm-dark-alert p {
    margin: 3px 0 0;
    color: rgba(255,255,255,.55);
    line-height: 1.32;
}

.wm-dark-alert small {
    display: inline-flex;
    margin-top: 4px;
    color: rgba(255,255,255,.60);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.wm-dark-alert a,
.wm-alert-state-actions button {
    min-width: 74px;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,.15);
    color: #fff;
    background: rgba(255,255,255,.035);
    text-align: center;
    text-decoration: none;
    font-size: .76rem;
    font-weight: 850;
}

.wm-alert-state-actions {
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.wm-alert-state-actions button {
    min-width: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
}

.wm-alert-state-actions button[value="done"] {
    border-color: rgba(31,180,102,.35);
    background: rgba(31,180,102,.12);
}

.wm-alert-state-actions button[value="partial"] {
    border-color: rgba(255,176,46,.38);
    background: rgba(255,176,46,.10);
}

.wm-alert-state-actions button:disabled {
    opacity: .48;
    cursor: not-allowed;
}

.wm-dark-alert.is-partial > span,
.wm-dark-alert.is-upcoming > span {
    color: #ffb02e;
    background: rgba(255,176,46,.12);
    border-color: rgba(255,176,46,.34);
}

.wm-dark-alert.is-danger > span,
.wm-dark-alert.is-warning > span {
    box-shadow: 0 0 22px rgba(255,51,43,.25);
}

.wm-quick-module-grid,
.wm-dark-module-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.wm-quick-module,
.wm-dark-module-card {
    --accent: var(--wm-red-hot);
    position: relative;
    overflow: hidden;
    min-height: 100px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,.10);
    background: linear-gradient(145deg, rgba(255,255,255,.085), rgba(255,255,255,.045));
    color: #fff;
    text-decoration: none;
    transition: transform .16s ease, border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

.wm-quick-module {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 2px 12px;
    align-items: center;
    padding: 16px;
}

.wm-quick-module i {
    grid-row: 1 / 3;
    color: var(--accent);
    font-size: 1.9rem;
    filter: drop-shadow(0 0 12px color-mix(in srgb, var(--accent) 50%, transparent));
}

.wm-quick-module strong {
    font-size: 1rem;
    line-height: 1.12;
}

.wm-quick-module span {
    color: rgba(255,255,255,.55);
    line-height: 1.25;
}

.wm-quick-module em {
    grid-column: 2;
    color: rgba(255,255,255,.60);
    font-size: .7rem;
    font-style: normal;
    font-weight: 850;
}

.wm-quick-module:hover,
.wm-dark-module-card:hover {
    transform: translateY(-2px);
    border-color: color-mix(in srgb, var(--accent) 60%, rgba(255,255,255,.12));
    background: linear-gradient(145deg, rgba(255,255,255,.12), rgba(255,255,255,.055));
    box-shadow: 0 16px 42px rgba(0,0,0,.25), 0 0 28px color-mix(in srgb, var(--accent) 18%, transparent);
}

.wm-quick-module.is-locked,
.wm-dark-module-card.is-locked {
    opacity: .52;
    cursor: not-allowed;
}

.wm-all-modules {
    margin-top: 16px;
}

.wm-dark-section-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.wm-dark-section-head h2 {
    margin: 0;
    color: #fff;
    font-family: Barlow, Arial, sans-serif;
    font-size: 1.35rem;
    font-weight: 900;
}

.wm-dark-module-grid {
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
}

.wm-dark-module-card {
    min-height: 118px;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr) auto;
    gap: 10px 12px;
    padding: 15px;
}

.wm-dark-module-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: var(--accent);
    box-shadow: 0 0 18px color-mix(in srgb, var(--accent) 60%, transparent);
}

.wm-dark-module-icon {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 12%, rgba(255,255,255,.06));
    font-size: 1.35rem;
}

.wm-dark-module-card strong {
    display: block;
    color: #fff;
    font-family: Barlow, Arial, sans-serif;
    font-size: 1.08rem;
    line-height: 1.05;
}

.wm-dark-module-card p {
    margin: 6px 0 0;
    color: rgba(255,255,255,.55);
    line-height: 1.32;
}

.wm-dark-module-card small {
    grid-column: 2;
    color: color-mix(in srgb, var(--accent) 62%, #fff);
    font-weight: 850;
}

@keyframes wm-dark-beam {
    0%, 100% { transform: translateX(-5%) rotate(-8deg); opacity: .52; }
    50% { transform: translateX(8%) rotate(-8deg); opacity: 1; }
}

@keyframes wm-llorca-arrow-flight {
    0%, 100% {
        transform: translate(-42px, 16px) rotate(-12deg) scale(.9);
        opacity: .72;
        filter:
            drop-shadow(0 0 20px rgba(255,51,43,.92))
            drop-shadow(0 0 68px rgba(255,51,43,.52));
    }
    28% {
        transform: translate(34px, -18px) rotate(-5deg) scale(1.18);
        opacity: 1;
    }
    52% {
        transform: translate(76px, -4px) rotate(-9deg) scale(1.35);
        opacity: .96;
        filter:
            drop-shadow(0 0 40px rgba(255,51,43,1))
            drop-shadow(0 0 122px rgba(255,51,43,.78))
            drop-shadow(0 0 230px rgba(255,51,43,.52));
    }
    78% {
        transform: translate(18px, 14px) rotate(-15deg) scale(1.12);
        opacity: .98;
    }
}

@keyframes wm-dark-curve {
    0%, 100% { transform: translateX(-4%) rotate(2deg); opacity: .42; }
    50% { transform: translateX(5%) rotate(2deg); opacity: 1; }
}

@keyframes wm-project-sweep {
    0%, 100% { transform: translateX(-24%) rotate(-18deg); opacity: .18; }
    48% { transform: translateX(18%) rotate(-18deg); opacity: .7; }
}

@keyframes wm-project-pulse {
    0% { transform: scale(.82); opacity: .9; }
    100% { transform: scale(1.55); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .wm-llorca-arrow,
    .wm-red-beam,
    .wm-dark-hero::after,
    .wm-project-context::after,
    .wm-project-context-beacon::after {
        animation: none !important;
    }
}

@media (min-width: 1180px) and (min-height: 680px) {
    .wm-dashboard-fit {
        overflow: hidden;
    }

    .wm-dashboard-fit .wm-dark-main {
        height: 100vh;
        height: 100dvh;
        min-height: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
        padding: 16px 18px 18px;
    }

    .wm-dashboard-fit .wm-dark-hero {
        min-height: 162px;
        padding: 18px 34px;
        flex: 0 0 auto;
    }

    .wm-dashboard-fit .wm-llorca-arrow {
        right: 5%;
        top: -24%;
        width: clamp(250px, 21vw, 420px);
    }

    .wm-dashboard-fit .wm-hero-copy h1 {
        font-size: clamp(2rem, 3.25vw, 2.75rem);
    }

    .wm-dashboard-fit .wm-hero-copy p {
        margin-top: 8px;
        max-width: 560px;
        font-size: .98rem;
    }

    .wm-dashboard-fit .wm-hero-project {
        margin-top: 8px;
        padding: 6px 10px;
    }

    .wm-dashboard-fit .wm-hero-project.is-featured {
        width: min(100%, 480px);
        padding: 9px 12px;
    }

    .wm-dashboard-fit .wm-hero-project.is-featured > i {
        width: 34px;
        height: 34px;
    }

    .wm-dashboard-fit .wm-hero-project.is-featured strong {
        font-size: clamp(1rem, 1.35vw, 1.2rem);
    }

    .wm-dashboard-fit .wm-hero-project.is-featured small {
        margin-top: 4px;
        font-size: .78rem;
    }

    .wm-dashboard-fit .wm-hero-clock .wm-live-clock {
        font-size: clamp(2.6rem, 4vw, 3.65rem);
    }

    .wm-dashboard-fit .wm-metrics-grid {
        flex: 0 0 auto;
        margin: 9px 0;
        gap: 10px;
    }

    .wm-dashboard-fit .wm-metric-card {
        min-height: 84px;
        grid-template-columns: 52px minmax(0, 1fr);
        gap: 13px;
        padding: 11px 14px;
    }

    .wm-dashboard-fit .wm-metric-icon {
        width: 46px;
        height: 46px;
        font-size: 1.15rem;
    }

    .wm-dashboard-fit .wm-metric-card strong {
        font-size: 1.25rem;
    }

    .wm-dashboard-fit .wm-metric-card p {
        margin-top: 5px;
    }

    .wm-dashboard-fit .wm-command-layout {
        flex: 1 1 auto;
        min-height: 0;
        gap: 10px;
    }

    .wm-dashboard-fit .wm-dark-panel {
        padding: 13px;
    }

    .wm-dashboard-fit .wm-private-agenda,
    .wm-dashboard-fit .wm-right-stack {
        min-height: 0;
    }

    .wm-dashboard-fit .wm-private-agenda {
        display: flex;
        flex-direction: column;
    }

    .wm-dashboard-fit .wm-dark-panel-head {
        min-height: 32px;
        padding-bottom: 9px;
    }

    .wm-dashboard-fit .wm-dark-empty {
        min-height: 96px;
        margin: 9px 0;
    }

    .wm-dashboard-fit .wm-dark-quick-task {
        margin: 9px 0 2px;
    }

    .wm-dashboard-fit .wm-dark-calendar {
        margin-top: 10px;
        padding-top: 10px;
    }

    .wm-dashboard-fit .wm-dark-calendar header {
        margin-bottom: 8px;
    }

    .wm-dashboard-fit .wm-dark-calendar-grid {
        gap: 4px;
    }

    .wm-dashboard-fit .wm-dark-calendar .wm-calendar-day {
        /* No bajar de 44px (zona tactil): sin esto, un viewport ancho
           (>=1180px, p.ej. una tablet grande en horizontal) volvia a
           encoger el dia por debajo del minimo. */
        min-height: 44px;
        font-size: .78rem;
    }

    .wm-dashboard-fit .wm-dark-calendar p {
        margin-top: 8px;
        font-size: .72rem;
    }

    .wm-dashboard-fit .wm-right-stack {
        grid-template-rows: auto minmax(0, 1fr);
        gap: 10px;
    }

    .wm-dashboard-fit .wm-dark-alert-list,
    .wm-dashboard-fit .wm-quick-module-grid {
        margin-top: 9px;
    }

    .wm-dashboard-fit .wm-dark-alert {
        min-height: 52px;
        padding: 8px 10px;
    }

    .wm-dashboard-fit .wm-dark-alert > span {
        width: 36px;
        height: 36px;
    }

    .wm-dashboard-fit .wm-dark-alert p {
        margin-top: 2px;
        font-size: .82rem;
    }

    .wm-dashboard-fit .wm-quick-module {
        min-height: 72px;
        padding: 10px;
    }

    .wm-dashboard-fit .wm-quick-module i {
        font-size: 1.55rem;
    }

    .wm-dashboard-fit .wm-quick-module strong {
        font-size: .95rem;
    }

    .wm-dashboard-fit .wm-quick-module span {
        font-size: .82rem;
    }
}

@media (min-width: 1180px) and (max-height: 759px) {
    .wm-dashboard-fit .wm-dark-main {
        padding: 12px 14px;
    }

    .wm-dashboard-fit .wm-dark-hero {
        min-height: 146px;
        padding: 18px 28px;
    }

    .wm-dashboard-fit .wm-llorca-arrow {
        right: 5%;
        top: -30%;
        width: clamp(220px, 19vw, 340px);
    }

    .wm-dashboard-fit .wm-hero-copy h1 {
        font-size: clamp(1.9rem, 3vw, 2.45rem);
    }

    .wm-dashboard-fit .wm-hero-copy p {
        margin-top: 8px;
        font-size: .92rem;
    }

    .wm-dashboard-fit .wm-hero-clock .wm-live-clock {
        font-size: clamp(2.15rem, 3.6vw, 3rem);
    }

    .wm-dashboard-fit .wm-metric-card {
        min-height: 74px;
        padding: 10px 12px;
        grid-template-columns: 42px minmax(0, 1fr);
    }

    .wm-dashboard-fit .wm-metric-icon {
        width: 38px;
        height: 38px;
    }

    .wm-dashboard-fit .wm-dark-empty {
        min-height: 70px;
    }

    .wm-dashboard-fit .wm-dark-calendar .wm-calendar-day {
        /* No bajar de 44px (zona tactil), mismo motivo que la variante
           anterior de este breakpoint. */
        min-height: 44px;
    }

    .wm-dashboard-fit .wm-dark-alert {
        min-height: 50px;
    }

    .wm-dashboard-fit .wm-quick-module {
        min-height: 66px;
        padding: 9px 10px;
    }

    .wm-dashboard-fit .wm-quick-module span,
    .wm-dashboard-fit .wm-quick-module em,
    .wm-dashboard-fit .wm-dark-alert p {
        font-size: .76rem;
    }
}

@media (max-width: 1220px) {
    .wm-metrics-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .wm-command-layout {
        grid-template-columns: 1fr;
    }
    .wm-project-context {
        grid-template-columns: auto minmax(0, 1fr) auto;
    }
    .wm-project-context-obras {
        grid-column: 2 / -1;
        justify-content: flex-start;
        max-width: none;
    }
}

@media (max-width: 900px) {
    .wm-sidebar {
        position: relative;
        width: 100%;
        min-height: 0;
    }
    .wm-sidebar-nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-height: none;
    }
    .wm-sidebar-section {
        grid-column: 1 / -1;
    }
    .wm-sidebar-footer {
        display: none;
    }
    .wm-dark-main {
        margin-left: 0;
    }
    .wm-dark-hero {
        grid-template-columns: 1fr;
    }
    .wm-hero-clock {
        justify-self: start;
    }
    .wm-project-context {
        position: relative;
        top: auto;
        grid-template-columns: auto minmax(0, 1fr);
    }
    .wm-project-context-action {
        grid-column: 2;
        justify-self: start;
    }
}

@media (max-width: 680px) {
    .wm-sidebar {
        position: sticky;
        top: 0;
        z-index: 60;
        max-width: 100vw;
    }
    .wm-sidebar-brand {
        min-height: 56px;
        padding: 10px 12px;
    }
    .wm-sidebar-mark {
        width: 34px;
        height: 34px;
        font-size: .68rem;
    }
    .wm-sidebar-brand strong {
        font-size: .78rem;
    }
    .wm-sidebar-brand small {
        margin-top: 4px;
        font-size: .56rem;
    }
    .wm-sidebar-nav {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
        overflow: visible;
        padding: 7px 8px 9px;
        scrollbar-width: none;
    }
    .wm-sidebar-nav::-webkit-scrollbar {
        display: none;
    }
    .wm-sidebar-section {
        display: none;
    }
    .wm-sidebar-group {
        min-width: 0;
        margin: 0;
    }
    .wm-sidebar-group[open] {
        grid-column: 1 / -1;
    }
    .wm-sidebar-group summary {
        min-height: 36px;
        display: flex;
        margin: 0;
        padding: 0 10px;
        border-radius: var(--radius-sm);
        background: rgba(255,255,255,.035);
        border-bottom: 2px solid transparent;
        font-size: .66rem;
    }
    .wm-sidebar-group-links {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
        margin-top: 6px;
    }
    .wm-sidebar-link {
        min-width: 0;
        min-height: 36px;
        margin: 0;
        padding: 0 12px;
        border-left: 0;
        border-bottom: 2px solid transparent;
        font-size: .82rem;
    }
    .wm-sidebar-link:hover,
    .wm-sidebar-link.active {
        transform: none;
        border-left-color: transparent;
        border-bottom-color: var(--wm-red-hot);
    }
    .wm-dark-main {
        padding: 12px;
    }
    .wm-dark-hero {
        padding: 22px;
    }
    .wm-project-context {
        grid-template-columns: 1fr;
    }
    .wm-project-context-beacon {
        display: none;
    }
    .wm-project-context-main strong {
        align-items: flex-start;
        flex-direction: column;
    }
    .wm-project-context-obras,
    .wm-project-context-action {
        grid-column: 1;
    }
    .wm-metrics-grid,
    .wm-quick-module-grid,
    .wm-dark-module-grid {
        grid-template-columns: 1fr;
    }
    .wm-command-layout {
        grid-template-columns: minmax(0, 1fr);
    }
    .wm-dark-quick-task,
    .wm-dark-alert,
    .wm-timeline-item {
        grid-template-columns: 1fr;
    }
    .wm-timeline-item button {
        justify-self: start;
    }
    .wm-dark-calendar header {
        grid-template-columns: 30px minmax(0, 1fr) 30px;
    }
    .wm-dark-calendar header span {
        grid-column: 1 / -1;
    }
}

/* Legacy pages: same dark product language for Bootstrap screens. */
body:not(.wm-login-body):not(.wm-dark-shell) {
    background:
        radial-gradient(circle at 88% -12%, rgba(255,51,43,.16), transparent 28%),
        linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.026) 1px, transparent 1px),
        #070909 !important;
    background-size: auto, 46px 46px, 46px 46px, auto !important;
    color: var(--cream) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .sidebar {
    background:
        radial-gradient(circle at 120% 8%, rgba(255,51,43,.18), transparent 32%),
        linear-gradient(180deg, #081010, #050808) !important;
    border-right: 1px solid rgba(255,255,255,.12) !important;
    box-shadow: 18px 0 60px rgba(0,0,0,.42) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .wrap,
body:not(.wm-login-body):not(.wm-dark-shell) .main {
    background: transparent !important;
    color: var(--cream) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .page-header {
    background: linear-gradient(145deg, rgba(255,255,255,.08), rgba(255,255,255,.035)) !important;
    border-color: rgba(255,255,255,.11) !important;
    border-left-color: var(--wm-red-hot) !important;
    color: #fff !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 20px 54px rgba(0,0,0,.24) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .page-header h1,
body:not(.wm-login-body):not(.wm-dark-shell) h1,
body:not(.wm-login-body):not(.wm-dark-shell) h2,
body:not(.wm-login-body):not(.wm-dark-shell) h3,
body:not(.wm-login-body):not(.wm-dark-shell) h4 {
    color: #fff !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .card,
body:not(.wm-login-body):not(.wm-dark-shell) .modal-content,
body:not(.wm-login-body):not(.wm-dark-shell) .dropdown-menu {
    color: var(--cream) !important;
    background: linear-gradient(145deg, rgba(255,255,255,.078), rgba(255,255,255,.035)), rgba(12,17,17,.92) !important;
    border-color: rgba(255,255,255,.11) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.055), 0 20px 54px rgba(0,0,0,.24) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .card-header,
body:not(.wm-login-body):not(.wm-dark-shell) .modal-header,
body:not(.wm-login-body):not(.wm-dark-shell) .modal-footer {
    color: #fff !important;
    background: rgba(255,255,255,.045) !important;
    border-color: rgba(255,255,255,.10) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .table {
    --bs-table-bg: rgba(255,255,255,.025) !important;
    --bs-table-color: var(--cream) !important;
    --bs-table-striped-bg: rgba(255,255,255,.045) !important;
    --bs-table-striped-color: var(--cream) !important;
    --bs-table-hover-bg: rgba(255,51,43,.11) !important;
    --bs-table-hover-color: #fff !important;
    color: var(--cream) !important;
    border-color: rgba(255,255,255,.09) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .table-light,
body:not(.wm-login-body):not(.wm-dark-shell) .table-secondary {
    --bs-table-bg: rgba(255,255,255,.065) !important;
    --bs-table-color: #fff !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .form-label,
body:not(.wm-login-body):not(.wm-dark-shell) label,
body:not(.wm-login-body):not(.wm-dark-shell) .text-muted {
    color: rgba(255,255,255,.62) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .form-control,
body:not(.wm-login-body):not(.wm-dark-shell) .form-select,
body:not(.wm-login-body):not(.wm-dark-shell) textarea,
body:not(.wm-login-body):not(.wm-dark-shell) input,
body:not(.wm-login-body):not(.wm-dark-shell) select {
    color: #fff !important;
    background-color: rgba(255,255,255,.055) !important;
    border-color: rgba(255,255,255,.14) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) select option,
body:not(.wm-login-body):not(.wm-dark-shell) .form-select option,
.wm-dark-shell select option,
.wm-dark-shell .form-select option {
    color: #111 !important;
    background: #fff !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .form-control::placeholder,
body:not(.wm-login-body):not(.wm-dark-shell) input::placeholder {
    color: rgba(255,255,255,.60) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-kpi,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-check,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-item,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-record {
    color: var(--charcoal) !important;
    background: #fff !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-check,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-item {
    background: var(--paper-soft) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card h2,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card h3,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card strong,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card b {
    color: var(--charcoal) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card p,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card small,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card li,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-kpi span {
    color: #5F5A54 !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card label {
    color: #5B554E !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card input,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card select,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card textarea {
    color: var(--charcoal) !important;
    background-color: var(--paper-soft) !important;
    border-color: #DCD3C8 !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card input::placeholder,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card textarea::placeholder {
    color: #8B8580 !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .permission-card,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-main-toggle,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-chip {
    color: var(--ink) !important;
    background: var(--paper-soft) !important;
    border-color: #E1D7CC !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .permission-card {
    box-shadow: inset 4px 0 0 rgba(255,51,43,.08), 0 12px 30px rgba(0,0,0,.16) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .permission-card.can-enter {
    box-shadow: inset 4px 0 0 var(--wm-red-hot), 0 14px 34px rgba(255,51,43,.16) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .permission-card label,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-card span,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-card i,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-title,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-slug,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-main-toggle,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-chip {
    color: var(--ink) !important;
    opacity: 1 !important;
    visibility: visible !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .permission-icon,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-main-toggle i,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-chip i {
    color: var(--wm-red-hot) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .permission-main-toggle span,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-chip span {
    display: inline-block !important;
    min-width: 0;
    color: inherit !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .permission-main-toggle:has(input:checked),
body:not(.wm-login-body):not(.wm-dark-shell) .permission-chip:has(input:checked) {
    color: var(--wm-red-hot) !important;
    background: rgba(255,51,43,.10) !important;
    border-color: rgba(255,51,43,.48) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .planning-shell,
body:not(.wm-login-body):not(.wm-dark-shell) .planning-shell .card-body,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-table {
    color: var(--ink) !important;
    background: var(--paper-soft) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-table th,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-table td {
    border-color: #E4DAD0 !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-table thead th {
    color: #fff !important;
    background: linear-gradient(180deg, #342F2C, #201F1E) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-table thead th.findesemana {
    background: linear-gradient(180deg, #703430, #3C2422) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-tech-cell {
    color: #211F1D !important;
    background: linear-gradient(90deg, #FFF6EF, var(--paper-soft)) !important;
    box-shadow: inset 4px 0 0 var(--wm-red-hot), inset -1px 0 0 #E5DAD0 !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-tech-name,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-name,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-name div,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-name small {
    color: #211F1D !important;
    opacity: 1 !important;
    visibility: visible !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-name small {
    color: #6A625A !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-obra,
body:not(.wm-login-body):not(.wm-dark-shell) .cell-sin,
body:not(.wm-login-body):not(.wm-dark-shell) .cell-libre {
    color: var(--ink) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-hora {
    color: #008A5A !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-vacaciones {
    color: #1C57B7 !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-festivo {
    color: #008A5A !important;
}

.wm-period-summary {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 7px 11px;
    border-radius: var(--radius-sm);
    color: #fff;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
}

.wm-period-summary i {
    color: var(--wm-red-hot, #ff332b);
}

.wm-period-summary strong {
    display: block;
    font-size: .78rem;
    line-height: 1.1;
}

.wm-period-summary small {
    display: block;
    color: rgba(255,255,255,.62);
    font-size: .72rem;
}

body:not(.wm-login-body):not(.wm-dark-shell) .badge,
body:not(.wm-login-body):not(.wm-dark-shell) .alert {
    border-color: rgba(255,255,255,.12) !important;
}

/* Phase 2 visual consistency: final dark pass for legacy module tables. */
body:not(.wm-login-body):not(.wm-dark-shell) thead.table-light,
body:not(.wm-login-body):not(.wm-dark-shell) .table thead.table-light,
body:not(.wm-login-body):not(.wm-dark-shell) .table-light th,
body:not(.wm-login-body):not(.wm-dark-shell) .table-light td,
body:not(.wm-login-body):not(.wm-dark-shell) thead.table-light th {
    --bs-table-bg: rgba(255,255,255,.075) !important;
    --bs-table-color: rgba(255,255,255,.78) !important;
    color: rgba(255,255,255,.78) !important;
    background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.055)) !important;
    border-color: rgba(255,255,255,.12) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .bg-primary-subtle,
body:not(.wm-login-body):not(.wm-dark-shell) .badge.bg-primary-subtle {
    color: #ffd8d2 !important;
    background: rgba(255,51,43,.14) !important;
    border-color: rgba(255,51,43,.30) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .planning-shell,
body:not(.wm-login-body):not(.wm-dark-shell) .planning-shell .card-body,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-table {
    color: #f7f2ea !important;
    background: rgba(9,13,13,.94) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-table th,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-table td {
    color: #f7f2ea !important;
    border-color: rgba(255,255,255,.10) !important;
    background: rgba(255,255,255,.026) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-table thead th {
    color: #fff !important;
    background: linear-gradient(180deg, #302f2d, #242322) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-table thead th.findesemana {
    background: linear-gradient(180deg, #5f2c29, #3a2422) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-table td.findesemana {
    background: rgba(255,51,43,.08) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-tech-cell {
    color: #fff !important;
    background: linear-gradient(90deg, rgba(255,51,43,.10), rgba(255,255,255,.045)) !important;
    box-shadow: inset 4px 0 0 var(--wm-red-hot), inset -1px 0 0 rgba(255,255,255,.10) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-tech-name,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-name,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-name div {
    color: #fff !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-name small {
    color: rgba(255,255,255,.58) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-obra {
    color: #fff !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-sin,
body:not(.wm-login-body):not(.wm-dark-shell) .cell-libre {
    color: rgba(255,255,255,.56) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-hora,
body:not(.wm-login-body):not(.wm-dark-shell) .cell-festivo {
    color: #72e19a !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .cell-vacaciones {
    color: #7fb6ff !important;
}

/* Sober product pass: graphite, calmer red, consistent module surfaces. */
:root {
    --wm-night: #090c0c;
    --wm-night-2: #111515;
    --wm-night-3: #181d1c;
    --wm-red-hot: #e0352d;
    --wm-red-glow: rgba(224, 53, 45, .34);
    --wm-ink-soft: rgba(247,242,234,.76);
    --wm-ink-muted: rgba(247,242,234,.52);
    --wm-dark-line: rgba(247,242,234,.12);
    --wm-panel: rgba(18,23,22,.94);
    --wm-panel-soft: rgba(255,255,255,.045);
    --wm-panel-hover: rgba(255,255,255,.072);
}

.wm-dark-shell {
    background:
        linear-gradient(90deg, rgba(255,255,255,.022) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.018) 1px, transparent 1px),
        radial-gradient(circle at 86% -18%, rgba(224,53,45,.10), transparent 30%),
        #090c0c !important;
    background-size: 52px 52px, 52px 52px, auto, auto !important;
    color: #f2eee7;
}

.wm-sidebar,
body:not(.wm-login-body):not(.wm-dark-shell) .sidebar {
    background: linear-gradient(180deg, #101514, #070909) !important;
    border-right-color: rgba(247,242,234,.10) !important;
    box-shadow: 12px 0 38px rgba(0,0,0,.32) !important;
}

.wm-sidebar-mark,
.brand-icon,
.wm-brand-mark,
.logo-mark,
.login-mark {
    box-shadow: 0 10px 28px rgba(0,0,0,.18) !important;
}

.wm-sidebar-mark::after,
.brand-icon::before,
.wm-brand-mark::before,
.login-mark::before,
.logo-mark::before {
    box-shadow: none !important;
}

.wm-project-switch,
.wm-project-context,
.wm-hero-project.is-featured {
    background:
        linear-gradient(135deg, rgba(255,255,255,.065), rgba(255,255,255,.028)),
        rgba(14,18,18,.94) !important;
    border-color: rgba(224,53,45,.28) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.055), 0 12px 34px rgba(0,0,0,.22) !important;
}

.wm-project-context::after {
    opacity: .22;
    animation: none !important;
}

.wm-project-context-beacon {
    width: 36px;
    height: 36px;
    background: rgba(224,53,45,.08);
    box-shadow: 0 0 18px rgba(224,53,45,.20);
}

.wm-project-context-beacon::before {
    inset: 10px;
    box-shadow: 0 0 14px rgba(224,53,45,.58);
}

.wm-project-context-beacon::after {
    animation-duration: 2.8s;
    border-color: rgba(224,53,45,.22);
}

.wm-project-context-main strong,
.wm-project-switch-current strong,
.wm-hero-project.is-featured strong {
    text-shadow: none !important;
}

.wm-project-context-main strong b,
.wm-hero-project.is-featured strong b {
    background: #d8322b;
    box-shadow: none !important;
}

.wm-sidebar-link:hover,
.wm-sidebar-link.active {
    background: rgba(224,53,45,.13);
    transform: none;
}

.wm-sidebar-link:hover i,
.wm-sidebar-link.active i,
.wm-dark-panel-head i,
.wm-quick-module i {
    filter: none !important;
}

.wm-dark-hero,
.wm-dark-card,
body:not(.wm-login-body):not(.wm-dark-shell) .card,
body:not(.wm-login-body):not(.wm-dark-shell) .modal-content,
body:not(.wm-login-body):not(.wm-dark-shell) .dropdown-menu {
    background:
        linear-gradient(145deg, rgba(255,255,255,.058), rgba(255,255,255,.028)),
        var(--wm-panel) !important;
    border-color: rgba(247,242,234,.11) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.045), 0 14px 34px rgba(0,0,0,.20) !important;
    backdrop-filter: blur(12px);
}

.wm-dark-hero {
    min-height: 204px;
}

.wm-dark-hero::before {
    background:
        radial-gradient(circle at 67% 46%, rgba(224,53,45,.08), transparent 30%),
        linear-gradient(90deg, rgba(255,255,255,.022) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.017) 1px, transparent 1px) !important;
    background-size: auto, 52px 52px, 52px 52px !important;
}

.wm-dark-hero::after,
.wm-red-beam {
    opacity: .28;
    filter: drop-shadow(0 0 8px rgba(224,53,45,.34)) !important;
    animation: none !important;
}

.wm-red-beam.secondary {
    opacity: .18;
}

.wm-llorca-arrow {
    right: 5.5%;
    top: -20%;
    width: clamp(250px, 22vw, 440px);
    opacity: .82;
    transform: rotate(-10deg) scale(1);
    filter:
        drop-shadow(0 0 16px rgba(224,53,45,.70))
        drop-shadow(0 0 52px rgba(224,53,45,.35)) !important;
    animation: wm-llorca-heartbeat 2.65s ease-in-out infinite !important;
}

@keyframes wm-llorca-heartbeat {
    0%, 100% {
        transform: rotate(-10deg) scale(.985);
        opacity: .70;
        filter:
            drop-shadow(0 0 12px rgba(224,53,45,.52))
            drop-shadow(0 0 38px rgba(224,53,45,.22));
    }
    12% {
        transform: rotate(-10deg) scale(1.055);
        opacity: .92;
        filter:
            drop-shadow(0 0 22px rgba(224,53,45,.82))
            drop-shadow(0 0 68px rgba(224,53,45,.42));
    }
    22% {
        transform: rotate(-10deg) scale(1.01);
        opacity: .84;
    }
    34% {
        transform: rotate(-10deg) scale(1.035);
        opacity: .90;
    }
    52% {
        transform: rotate(-10deg) scale(.995);
        opacity: .76;
    }
}

.wm-hero-copy span,
.wm-hero-copy h1 b,
.wm-hero-project i,
.wm-hero-project strong,
.wm-dark-panel-head i,
.wm-dark-empty i,
.wm-period-summary i {
    color: #ef4a42 !important;
    text-shadow: none !important;
}

.wm-hero-clock .wm-live-clock {
    text-shadow: none;
    color: #f3eee6;
}

.wm-metric-icon {
    border-radius: var(--radius-sm);
    border-color: rgba(224,53,45,.36);
    background: rgba(224,53,45,.10);
    box-shadow: none;
}

.wm-metric-progress span,
.wm-dark-calendar .wm-calendar-day.is-today,
.wm-timeline-item button,
.wm-dark-quick-task button {
    background: #df342d;
    box-shadow: none;
}

.wm-dark-panel-head,
body:not(.wm-login-body):not(.wm-dark-shell) .card-header,
body:not(.wm-login-body):not(.wm-dark-shell) .modal-header,
body:not(.wm-login-body):not(.wm-dark-shell) .modal-footer {
    background: rgba(255,255,255,.035) !important;
    border-color: rgba(247,242,234,.10) !important;
}

.wm-dark-alert,
.wm-quick-module,
.wm-dark-module-card,
.wm-timeline-item,
.wm-dark-empty,
.wm-dark-quick-task input,
body:not(.wm-login-body):not(.wm-dark-shell) .form-control,
body:not(.wm-login-body):not(.wm-dark-shell) .form-select,
body:not(.wm-login-body):not(.wm-dark-shell) textarea,
body:not(.wm-login-body):not(.wm-dark-shell) input,
body:not(.wm-login-body):not(.wm-dark-shell) select {
    background-color: var(--wm-panel-soft) !important;
    border-color: rgba(247,242,234,.12) !important;
}

.wm-quick-module,
.wm-dark-module-card {
    background: rgba(255,255,255,.045) !important;
    box-shadow: none !important;
}

.wm-quick-module:hover,
.wm-dark-module-card:hover {
    background: rgba(255,255,255,.072) !important;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 32%, transparent) !important;
    transform: translateY(-1px);
}

.wm-quick-module i,
.wm-dark-module-icon {
    color: color-mix(in srgb, var(--accent) 82%, #f7f2ea) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) {
    background:
        linear-gradient(90deg, rgba(255,255,255,.022) 1px, transparent 1px),
        linear-gradient(0deg, rgba(255,255,255,.017) 1px, transparent 1px),
        radial-gradient(circle at 90% -14%, rgba(224,53,45,.09), transparent 28%),
        #090c0c !important;
    background-size: 52px 52px, 52px 52px, auto, auto !important;
    color: #f2eee7 !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .page-header {
    background:
        linear-gradient(145deg, rgba(255,255,255,.058), rgba(255,255,255,.028)),
        rgba(18,23,22,.94) !important;
    border-color: rgba(247,242,234,.11) !important;
    border-left-color: #df342d !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.045), 0 12px 30px rgba(0,0,0,.20) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .table,
body:not(.wm-login-body):not(.wm-dark-shell) .table > :not(caption) > * > * {
    --bs-table-bg: rgba(255,255,255,.024) !important;
    --bs-table-color: #f2eee7 !important;
    --bs-table-striped-bg: rgba(255,255,255,.04) !important;
    --bs-table-striped-color: #f2eee7 !important;
    --bs-table-hover-bg: rgba(224,53,45,.08) !important;
    color: #f2eee7 !important;
    border-color: rgba(247,242,234,.095) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) thead.table-light,
body:not(.wm-login-body):not(.wm-dark-shell) .table thead.table-light,
body:not(.wm-login-body):not(.wm-dark-shell) .table-light th,
body:not(.wm-login-body):not(.wm-dark-shell) .table-light td,
body:not(.wm-login-body):not(.wm-dark-shell) thead.table-light th,
body:not(.wm-login-body):not(.wm-dark-shell) .table-secondary {
    background: linear-gradient(180deg, rgba(255,255,255,.075), rgba(255,255,255,.045)) !important;
    color: rgba(247,242,234,.78) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .btn-primary,
body:not(.wm-login-body):not(.wm-dark-shell) .btn-danger,
.wm-login-button {
    background: #df342d !important;
    border-color: #df342d !important;
    box-shadow: none !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .btn-outline-primary,
body:not(.wm-login-body):not(.wm-dark-shell) .btn-outline-danger {
    color: #ffb7b1 !important;
    border-color: rgba(224,53,45,.55) !important;
    background: rgba(224,53,45,.04) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .btn-outline-primary:hover,
body:not(.wm-login-body):not(.wm-dark-shell) .btn-outline-danger:hover {
    color: #fff !important;
    background: rgba(224,53,45,.20) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-kpi,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-check,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-item,
body:not(.wm-login-body):not(.wm-dark-shell) .privacy-record,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-card,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-main-toggle,
body:not(.wm-login-body):not(.wm-dark-shell) .permission-chip {
    background:
        linear-gradient(145deg, rgba(255,255,255,.94), rgba(247,242,234,.90)) !important;
    border-color: rgba(221,216,206,.92) !important;
    box-shadow: 0 10px 26px rgba(0,0,0,.14) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .planning-shell,
body:not(.wm-login-body):not(.wm-dark-shell) .planning-shell .card-body,
body:not(.wm-login-body):not(.wm-dark-shell) .plan-table {
    background: rgba(14,18,18,.94) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .plan-tech-cell {
    background: rgba(224,53,45,.075) !important;
    box-shadow: inset 3px 0 0 #df342d, inset -1px 0 0 rgba(247,242,234,.10) !important;
}

.wm-red-beam {
    animation: wm-red-beam-drift 15s ease-in-out infinite alternate !important;
}

.wm-red-beam.secondary {
    animation: wm-red-beam-drift 19s ease-in-out infinite alternate-reverse !important;
}

.wm-llorca-brand {
    position: absolute;
    top: 31%;
    right: clamp(320px, 31vw, 560px);
    z-index: 2;
    display: grid;
    gap: 2px;
    color: rgba(247,242,234,.86);
    font-family: Barlow, Arial, sans-serif;
    pointer-events: none;
}

.wm-llorca-brand span {
    color: #f7f2ea;
    font-size: clamp(1.2rem, 1.7vw, 2.05rem);
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
}

.wm-llorca-brand small {
    color: rgba(247,242,234,.44);
    font-size: .62rem;
    font-weight: 800;
    letter-spacing: .18em;
    text-transform: uppercase;
}

.wm-llorca-arrow,
.wm-dashboard-fit .wm-llorca-arrow {
    top: 23%;
    right: clamp(300px, 23vw, 470px);
    width: clamp(82px, 6.2vw, 128px);
    height: auto;
    opacity: .86;
    transform: rotate(0deg) scale(1);
}

@keyframes wm-red-beam-drift {
    0% {
        transform: translate3d(-18px, 8px, 0) rotate(-8deg) scaleX(.96);
    }
    50% {
        transform: translate3d(10px, -5px, 0) rotate(-5deg) scaleX(1.03);
    }
    100% {
        transform: translate3d(25px, 9px, 0) rotate(-8deg) scaleX(.98);
    }
}

@keyframes wm-llorca-heartbeat {
    0%, 100% {
        transform: rotate(0deg) scale(.99);
        opacity: .72;
        filter:
            drop-shadow(0 0 10px rgba(224,53,45,.50))
            drop-shadow(0 0 28px rgba(224,53,45,.20));
    }
    12% {
        transform: rotate(0deg) scale(1.075);
        opacity: .94;
        filter:
            drop-shadow(0 0 18px rgba(224,53,45,.82))
            drop-shadow(0 0 54px rgba(224,53,45,.38));
    }
    24% {
        transform: rotate(0deg) scale(1.015);
        opacity: .84;
    }
    38% {
        transform: rotate(0deg) scale(1.045);
        opacity: .90;
    }
    56% {
        transform: rotate(0deg) scale(.995);
        opacity: .78;
    }
}

.wm-dark-calendar .wm-calendar-day {
    position: relative;
    display: grid;
    place-items: center;
    width: 100%;
    /* 44px, no 31px: hay OTRA declaracion de min-height mas arriba
       (junto al resto de colores del calendario) que quedaba anulada por
       esta -- misma especificidad y esta va despues en el fichero. */
    min-height: 44px;
    cursor: pointer;
    font-family: inherit;
    font-weight: 800;
    transition: background .18s ease, border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}

.wm-dark-calendar .wm-calendar-day:hover,
.wm-dark-calendar .wm-calendar-day.is-open {
    color: #fff;
    background: rgba(224,53,45,.14);
    border-radius: var(--radius-sm);
    box-shadow: inset 0 0 0 1px rgba(224,53,45,.34);
    transform: translateY(-1px);
}

.wm-dark-calendar .wm-calendar-day.has-agenda::before {
    content: "";
    position: absolute;
    top: 4px;
    right: 5px;
    width: 6px;
    height: 6px;
    border-radius: var(--radius-pill);
    background: #f7f2ea;
    box-shadow: 0 0 10px rgba(247,242,234,.45);
}

.wm-calendar-popover[hidden] {
    display: none;
}

.wm-calendar-popover {
    margin-top: 12px;
    padding: 12px;
    border: 1px solid rgba(247,242,234,.13);
    border-radius: var(--radius-sm);
    background: linear-gradient(145deg, rgba(255,255,255,.07), rgba(255,255,255,.035)), rgba(12,16,16,.96);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
}

.wm-calendar-popover header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 0 0 10px;
}

.wm-calendar-popover header strong {
    color: #fff;
    font-weight: 900;
}

.wm-calendar-popover header button {
    width: 28px;
    height: 28px;
    cursor: pointer;
}

.wm-calendar-popover-body {
    display: grid;
    gap: 8px;
}

.wm-calendar-popover-body article {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 10px;
    padding: 8px;
    border: 1px solid rgba(247,242,234,.10);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.035);
}

.wm-calendar-popover-body time {
    color: #ffb5ad;
    font-variant-numeric: tabular-nums;
    font-weight: 900;
}

.wm-calendar-popover-body strong {
    display: block;
    color: #fff;
}

.wm-calendar-popover-body span,
.wm-calendar-popover-body p,
.wm-calendar-empty {
    color: rgba(247,242,234,.62);
    margin: 2px 0 0;
}

.wm-calendar-empty {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    border: 1px dashed rgba(247,242,234,.14);
    border-radius: var(--radius-sm);
}

.wm-calendar-popover > a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    color: #ffb5ad;
    font-size: .8rem;
    font-weight: 900;
    text-decoration: none;
}

.wm-dark-alert.is-quiet {
    grid-template-columns: 46px minmax(0, 1fr);
    color: rgba(247,242,234,.66);
    background: rgba(255,255,255,.028) !important;
    border-style: dashed;
}

body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table tfoot,
body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table tfoot tr,
body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table tfoot td,
body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table tfoot.table-light,
body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table tfoot.table-light td {
    --bs-table-bg: rgba(18,23,22,.98) !important;
    --bs-table-color: #f7f2ea !important;
    background: linear-gradient(180deg, rgba(255,255,255,.075), rgba(255,255,255,.045)), #141817 !important;
    color: #f7f2ea !important;
    border-color: rgba(247,242,234,.16) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table tfoot td:last-child {
    color: #ffb02e !important;
}

.badge-oficial,
.badge-encargado,
.badge-gruista,
.badge-peon,
.badge-maquinista {
    box-shadow: none !important;
}

@media (prefers-reduced-motion: reduce) {
    .wm-red-beam,
    .wm-red-beam.secondary {
        animation: none !important;
    }

    .wm-llorca-arrow {
        animation: none !important;
        transform: rotate(0deg) scale(1);
    }
}

@media (min-width: 1180px) and (max-height: 759px) {
    .wm-dashboard-fit .wm-llorca-arrow {
        width: clamp(110px, 9vw, 170px);
        top: 20%;
    }
}

/* Command center 2026-06: compact, useful home surface. */
.wm-dark-shell .wm-dark-hero.wm-hero-compact,
.wm-dashboard-fit .wm-dark-hero.wm-hero-compact {
    min-height: 118px;
    display: grid;
    grid-template-columns: minmax(150px, 240px) minmax(220px, 1fr) minmax(230px, 340px);
    gap: 18px;
    align-items: center;
    padding: 18px 28px;
    margin-bottom: 12px;
}

.wm-dark-shell .wm-dark-hero.wm-hero-compact::after {
    left: 24%;
    right: 16%;
    top: -14%;
    height: 115px;
    border-bottom-width: 2px;
    opacity: .62;
}

.wm-hero-today {
    display: grid;
    gap: 5px;
    color: rgba(247,242,234,.72);
}

.wm-hero-today span {
    color: var(--wm-red-hot);
    font-family: Barlow, Arial, sans-serif;
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.wm-hero-today strong {
    color: #f7f2ea;
    font-size: 1rem;
    font-weight: 850;
    text-transform: capitalize;
}

.wm-hero-brandmark {
    justify-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(14px, 2vw, 28px);
    min-width: 0;
}

.wm-hero-brandmark .wm-llorca-brand {
    position: static;
    right: auto;
    top: auto;
    z-index: 2;
    gap: 1px;
    text-align: right;
}

.wm-hero-brandmark .wm-llorca-brand span {
    font-size: clamp(1.35rem, 2.2vw, 2.1rem);
}

.wm-hero-brandmark .wm-llorca-brand small {
    font-size: .56rem;
}

.wm-hero-brandmark .wm-llorca-arrow,
.wm-dashboard-fit .wm-hero-brandmark .wm-llorca-arrow {
    position: static;
    width: clamp(72px, 7.4vw, 118px);
    opacity: .9;
    transform: rotate(0deg) scale(1);
    animation: wm-llorca-heartbeat 2.85s ease-in-out infinite;
    filter:
        drop-shadow(0 0 12px rgba(224,53,45,.68))
        drop-shadow(0 0 38px rgba(224,53,45,.25));
}

.wm-hero-compact .wm-hero-clock {
    justify-self: end;
    min-width: 0;
}

.wm-hero-compact .wm-hero-clock .wm-live-clock,
.wm-dashboard-fit .wm-hero-compact .wm-hero-clock .wm-live-clock {
    font-size: clamp(2.2rem, 4.1vw, 3.6rem);
}

.wm-hero-compact .wm-hero-clock span {
    font-size: .9rem;
}

.wm-dashboard-fit .wm-command-layout {
    grid-template-columns: minmax(440px, .92fr) minmax(430px, 1fr);
}

.wm-pending-list {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.wm-pending-item {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 4px 12px;
    align-items: center;
    min-height: 56px;
    padding: 10px 12px;
    border: 1px solid rgba(247,242,234,.11);
    border-left: 3px solid var(--wm-red-hot);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.034);
}

.wm-pending-item time {
    grid-row: span 2;
    color: rgba(247,242,234,.56);
    font-size: .75rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.wm-pending-item strong {
    color: #f7f2ea;
    font-weight: 850;
}

.wm-pending-item span {
    color: rgba(247,242,234,.55);
    font-size: .82rem;
}

.wm-pending-item.is-muted {
    border-left-color: rgba(247,242,234,.24);
}

.wm-pending-item.is-cycle {
    border-left-color: #ffb02e;
    background: rgba(255,176,46,.06);
}

.wm-calendar-overlay[hidden] {
    display: none;
}

.wm-calendar-overlay {
    position: fixed;
    inset: 0;
    z-index: 1800;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(5,7,7,.64);
    backdrop-filter: blur(8px);
}

.wm-calendar-overlay .wm-calendar-popover {
    width: min(560px, 100%);
    margin: 0;
    padding: 16px;
    border-color: rgba(247,242,234,.18);
    box-shadow: 0 26px 80px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.05);
}

.wm-calendar-popover-next {
    display: grid;
    gap: 7px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(247,242,234,.10);
}

.wm-calendar-popover-next > strong {
    color: rgba(247,242,234,.78);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.wm-calendar-popover-next article {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 10px;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.035);
}

.wm-calendar-popover-next time {
    color: #ffb5ad;
    font-size: .76rem;
    font-weight: 850;
}

.wm-calendar-popover-next span,
.wm-calendar-popover-next p {
    margin: 0;
    color: rgba(247,242,234,.66);
}

@media (max-width: 980px) {
    .wm-dark-shell .wm-dark-hero.wm-hero-compact,
    .wm-dashboard-fit .wm-dark-hero.wm-hero-compact {
        grid-template-columns: 1fr;
        min-height: auto;
        text-align: left;
    }

    .wm-hero-brandmark {
        justify-content: flex-start;
    }

    .wm-hero-compact .wm-hero-clock {
        justify-self: start;
    }
}

body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot,
body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot tr,
body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot td,
body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot.table-light,
body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot.table-light tr,
body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot.table-light td,
body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tfoot,
body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tfoot tr,
body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tfoot td {
    --bs-table-bg: #171d1c !important;
    --bs-table-color: #f7f2ea !important;
    background: #171d1c !important;
    color: #f7f2ea !important;
    border-color: rgba(247,242,234,.18) !important;
}

body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot td:last-child,
body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tfoot .total-cell {
    color: #ffb02e !important;
}

/* 2026-06-30 final visual system: Gris operativo premium.
   One sober, readable theme for Work Manager and all internal modules. */
:root {
    --wm-premium-bg: #e7ebe8;
    --wm-premium-bg-grid: rgba(30, 39, 36, .04);
    --wm-premium-surface: #f8f9f6;
    --wm-premium-surface-2: #ffffff;
    --wm-premium-row: #f3f5f2;
    --wm-premium-row-alt: #ecefeb;
    --wm-premium-ink: #202725;
    --wm-premium-ink-2: #3e4743;
    --wm-premium-muted: #69736f;
    --wm-premium-line: #cfd7d1;
    --wm-premium-line-2: #b8c2bc;
    --wm-premium-side: #171d1c;
    --wm-premium-side-2: #222a28;
    --wm-premium-red: #d42b1e;
    --wm-premium-red-2: #a8200f;
    --wm-premium-red-soft: #fff0ee;
    --wm-premium-green: #1e7d49;
    --wm-premium-green-soft: #e7f4ec;
    --wm-premium-amber: #a46605;
    --wm-premium-amber-soft: #fff4d8;
    --wm-premium-blue: #27679f;
    --wm-premium-shadow: 0 14px 34px rgba(28, 37, 34, .10);
    --wm-premium-shadow-soft: 0 8px 22px rgba(28, 37, 34, .075);
    --wm-premium-radius: 8px;
}

body:not(.wm-login-body),
.wm-body:not(.wm-login-body),
body:not(.wm-login-body).wm-dark-shell,
body:not(.wm-login-body).wm-dashboard-fit {
    background:
        linear-gradient(90deg, var(--wm-premium-bg-grid) 1px, transparent 1px),
        linear-gradient(0deg, rgba(30, 39, 36, .032) 1px, transparent 1px),
        radial-gradient(circle at 86% -20%, rgba(212, 43, 30, .075), transparent 30%),
        var(--wm-premium-bg) !important;
    background-size: 46px 46px, 46px 46px, auto, auto !important;
    color: var(--wm-premium-ink) !important;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
    font-size: .92rem !important;
}

body:not(.wm-login-body) .main,
body:not(.wm-login-body) .wrap,
body:not(.wm-login-body) .wm-dark-main,
body:not(.wm-login-body) .wm-page {
    background:
        linear-gradient(90deg, var(--wm-premium-bg-grid) 1px, transparent 1px),
        linear-gradient(0deg, rgba(30, 39, 36, .032) 1px, transparent 1px),
        var(--wm-premium-bg) !important;
    background-size: 46px 46px !important;
    color: var(--wm-premium-ink) !important;
}

body:not(.wm-login-body) .sidebar,
body:not(.wm-login-body) .wm-sidebar {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, .045), transparent 22%),
        linear-gradient(155deg, rgba(212, 43, 30, .16), transparent 34%),
        var(--wm-premium-side) !important;
    border-right: 1px solid rgba(255, 255, 255, .10) !important;
    box-shadow: 14px 0 36px rgba(20, 28, 26, .16) !important;
}

body:not(.wm-login-body) .sidebar .brand,
body:not(.wm-login-body) .wm-sidebar-brand {
    background: rgba(255, 255, 255, .025) !important;
    border-bottom-color: rgba(255, 255, 255, .10) !important;
}

body:not(.wm-login-body) .sidebar .nav-link,
body:not(.wm-login-body) .sidebar .nav-sub-link,
body:not(.wm-login-body) .wm-sidebar-link,
body:not(.wm-login-body) .wm-sidebar-group summary {
    color: rgba(247, 249, 246, .72) !important;
    border-radius: 0 8px 8px 0 !important;
}

body:not(.wm-login-body) .sidebar .nav-link:hover,
body:not(.wm-login-body) .sidebar .nav-sub-link:hover,
body:not(.wm-login-body) .wm-sidebar-link:hover,
body:not(.wm-login-body) .wm-sidebar-group summary:hover {
    color: #fff !important;
    background: rgba(255, 255, 255, .075) !important;
    border-left-color: rgba(212, 43, 30, .72) !important;
}

body:not(.wm-login-body) .sidebar .nav-link.active,
body:not(.wm-login-body) .sidebar .nav-sub-link.active,
body:not(.wm-login-body) .wm-sidebar-link.active {
    color: #fff !important;
    background: linear-gradient(90deg, rgba(212, 43, 30, .30), rgba(212, 43, 30, .10)) !important;
    border-left-color: var(--wm-premium-red) !important;
}

body:not(.wm-login-body) .wm-sidebar-link.is-locked {
    opacity: .42 !important;
    background: rgba(255, 255, 255, .025) !important;
}

/* Contraste (fase 2 de accesibilidad). Aqui caen los creditos del pie del
   menu ("Design by", "Conectado como") y las etiquetas del lateral. Estaba
   en .42, que MEDIDO en el navegador da 3,89:1 sobre el fondo real del
   sidebar -- por debajo del 4,5:1 de AA. El fondo efectivo medido va de
   rgb(15,19,19) a rgb(31,35,35); con esta tinta hueso el alfa minimo para
   4,5:1 es .48 sobre el mas claro, asi que se sube a .60 (6,27:1) para
   dejar margen, el mismo valor que se uso en la fase 1. */
body:not(.wm-login-body) .sidebar .nav-section,
body:not(.wm-login-body) .wm-sidebar-group summary span,
body:not(.wm-login-body) .wm-project-switch label,
body:not(.wm-login-body) .wm-sidebar-footer > span,
body:not(.wm-login-body) .wm-sidebar-maker span {
    color: rgba(247, 249, 246, .60) !important;
}

/* "Cerrar sesion" del pie del menu. La regla generica de mas arriba
   (body:not(.wm-login-body) a, especificidad 0-2-1 y con !important) pinta
   TODOS los enlaces del rojo de marca: medido, ese rojo sobre el casi negro
   del sidebar da 3,39:1. Repitiendo el :not() del body mas la clase del pie
   queda en 0-3-1 y gana, devolviendo el blanco que ya pedia
   .wm-sidebar-footer a (.60 sobre el fondo medido = 6,57:1). Mismo caso y
   misma solucion que el .sidebar-footer-link de la fase 1. */
body:not(.wm-login-body) .wm-sidebar-footer a {
    color: rgba(255, 255, 255, .60) !important;
}

body:not(.wm-login-body) .wm-sidebar-footer a:hover,
body:not(.wm-login-body) .wm-sidebar-footer a:focus-visible {
    color: rgba(255, 255, 255, .95) !important;
}

body:not(.wm-login-body) .wm-project-switch-current,
body:not(.wm-login-body) .wm-project-switch select {
    background: rgba(255, 255, 255, .07) !important;
    border-color: rgba(255, 255, 255, .14) !important;
    color: #fff !important;
}

body:not(.wm-login-body) .wm-project-switch-current strong {
    color: #fff !important;
}

body:not(.wm-login-body) .wm-topbar,
body:not(.wm-login-body) .control-hero,
body:not(.wm-login-body) .wm-command,
body:not(.wm-login-body) .wm-portal-hero,
body:not(.wm-login-body) .wm-page-hero,
body:not(.wm-login-body) .wm-dark-hero {
    background:
        linear-gradient(90deg, rgba(212, 43, 30, .075), transparent 48%),
        linear-gradient(180deg, #fbfcfa, #f0f3ef) !important;
    border: 1px solid var(--wm-premium-line) !important;
    color: var(--wm-premium-ink) !important;
    box-shadow: var(--wm-premium-shadow) !important;
}

body:not(.wm-login-body) .wm-dark-hero.wm-hero-compact {
    min-height: 108px !important;
    padding: 16px 24px !important;
}

body:not(.wm-login-body) .wm-red-beam {
    border-color: rgba(212, 43, 30, .22) !important;
    opacity: .34 !important;
}

body:not(.wm-login-body) .control-hero h1,
body:not(.wm-login-body) .page-header h1,
body:not(.wm-login-body) .wm-command h1,
body:not(.wm-login-body) .wm-portal-hero h1,
body:not(.wm-login-body) .wm-page-hero h1,
body:not(.wm-login-body) .wm-dark-hero h1,
body:not(.wm-login-body) .wm-hero-today strong,
body:not(.wm-login-body) .wm-hero-clock .wm-live-clock,
body:not(.wm-login-body) .wm-live-clock {
    color: var(--wm-premium-ink) !important;
    text-shadow: none !important;
}

body:not(.wm-login-body) .control-hero p,
body:not(.wm-login-body) .wm-command p,
body:not(.wm-login-body) .wm-portal-hero p,
body:not(.wm-login-body) .wm-page-hero p,
body:not(.wm-login-body) .wm-hero-clock span,
body:not(.wm-login-body) .wm-hero-today {
    color: var(--wm-premium-muted) !important;
}

body:not(.wm-login-body) .eyebrow,
body:not(.wm-login-body) .wm-label,
body:not(.wm-login-body) .wm-command-kicker,
body:not(.wm-login-body) .wm-hero-today span,
body:not(.wm-login-body) .card-header .header-dot,
body:not(.wm-login-body) .header-dot {
    color: var(--wm-premium-red) !important;
}

body:not(.wm-login-body) .wm-hero-brandmark .wm-llorca-brand span,
body:not(.wm-login-body) .wm-hero-brandmark .wm-llorca-brand small {
    color: var(--wm-premium-ink) !important;
    text-shadow: none !important;
}

body:not(.wm-login-body) .wm-hero-brandmark .wm-llorca-arrow {
    opacity: .84 !important;
    filter: drop-shadow(0 0 12px rgba(212, 43, 30, .28)) !important;
}

body:not(.wm-login-body) .card,
body:not(.wm-login-body) .wm-card,
body:not(.wm-login-body) .wm-dark-card,
body:not(.wm-login-body) .wm-dark-panel,
body:not(.wm-login-body) .metric-card,
body:not(.wm-login-body) .action-tile,
body:not(.wm-login-body) .project-card,
body:not(.wm-login-body) .project-module-card,
body:not(.wm-login-body) .user-card,
body:not(.wm-login-body) .privacy-record,
body:not(.wm-login-body) .wm-collapsible-card,
body:not(.wm-login-body) .theme-option {
    background: linear-gradient(180deg, rgba(255, 255, 255, .92), rgba(248, 249, 246, .98)) !important;
    border: 1px solid var(--wm-premium-line) !important;
    color: var(--wm-premium-ink) !important;
    box-shadow: var(--wm-premium-shadow-soft) !important;
    border-radius: var(--wm-premium-radius) !important;
}

body:not(.wm-login-body) .card-header,
body:not(.wm-login-body) .wm-dark-panel-head,
body:not(.wm-login-body) .wm-collapsible-head,
body:not(.wm-login-body) .modal-header {
    background: linear-gradient(180deg, var(--paper), #f2f5f1) !important;
    border-bottom: 1px solid var(--wm-premium-line) !important;
    color: var(--wm-premium-ink) !important;
}

body:not(.wm-login-body) .card-body,
body:not(.wm-login-body) .modal-body,
body:not(.wm-login-body) .wm-dark-empty,
body:not(.wm-login-body) .wm-pending-item,
body:not(.wm-login-body) .wm-timeline-item,
body:not(.wm-login-body) .wm-dark-alert,
body:not(.wm-login-body) .wm-dark-calendar,
body:not(.wm-login-body) .wm-calendar-popover,
body:not(.wm-login-body) .wm-calendar-popover-next article {
    background: rgba(255, 255, 255, .58) !important;
    border-color: var(--wm-premium-line) !important;
    color: var(--wm-premium-ink) !important;
}

body:not(.wm-login-body) .wm-dark-alert {
    border-left: 3px solid var(--wm-premium-red) !important;
}

body:not(.wm-login-body) .wm-dark-alert.is-ok,
body:not(.wm-login-body) .wm-pending-item.is-muted {
    border-left-color: var(--wm-premium-green) !important;
}

body:not(.wm-login-body) .wm-dark-alert.is-warn,
body:not(.wm-login-body) .wm-pending-item.is-cycle {
    border-left-color: var(--wm-premium-amber) !important;
}

body:not(.wm-login-body) .wm-dark-panel-head span,
body:not(.wm-login-body) .wm-dark-panel-head strong,
body:not(.wm-login-body) .wm-dark-empty strong,
body:not(.wm-login-body) .wm-pending-item strong,
body:not(.wm-login-body) .wm-timeline-item strong,
body:not(.wm-login-body) .wm-dark-alert strong,
body:not(.wm-login-body) .wm-calendar-popover header strong,
body:not(.wm-login-body) .wm-calendar-popover-body strong {
    color: var(--wm-premium-ink) !important;
}

body:not(.wm-login-body) .wm-dark-panel-head a,
body:not(.wm-login-body) .wm-calendar-popover > a,
body:not(.wm-login-body) a {
    color: var(--wm-premium-red) !important;
}

body:not(.wm-login-body) .text-muted,
body:not(.wm-login-body) .card p,
body:not(.wm-login-body) .metric-note,
body:not(.wm-login-body) .action-text,
body:not(.wm-login-body) .wm-dark-empty span,
body:not(.wm-login-body) .wm-pending-item span,
body:not(.wm-login-body) .wm-timeline-item span,
body:not(.wm-login-body) .wm-dark-alert p,
body:not(.wm-login-body) .wm-dark-alert small,
body:not(.wm-login-body) .wm-calendar-popover-body span,
body:not(.wm-login-body) .wm-calendar-popover-body p,
body:not(.wm-login-body) .wm-calendar-empty,
body:not(.wm-login-body) .form-text {
    color: var(--wm-premium-muted) !important;
}

body:not(.wm-login-body) .form-control,
body:not(.wm-login-body) .form-select,
body:not(.wm-login-body) .wm-dark-quick-task input,
body:not(.wm-login-body) .wm-dark-quick-task select,
body:not(.wm-login-body) input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
body:not(.wm-login-body) textarea,
body:not(.wm-login-body) select {
    background: #fff !important;
    border-color: var(--wm-premium-line-2) !important;
    color: var(--wm-premium-ink) !important;
    border-radius: var(--radius-sm) !important;
}

body:not(.wm-login-body) .form-control:focus,
body:not(.wm-login-body) .form-select:focus,
body:not(.wm-login-body) input:focus,
body:not(.wm-login-body) textarea:focus,
body:not(.wm-login-body) select:focus {
    border-color: rgba(212, 43, 30, .72) !important;
    box-shadow: 0 0 0 .18rem rgba(212, 43, 30, .14) !important;
}

body:not(.wm-login-body) .btn,
body:not(.wm-login-body) button,
body:not(.wm-login-body) .wm-dark-panel-head a,
body:not(.wm-login-body) .wm-alert-state-actions button {
    border-radius: var(--radius-sm) !important;
    font-weight: 800 !important;
}

body:not(.wm-login-body) .btn-primary,
body:not(.wm-login-body) .btn-danger,
body:not(.wm-login-body) .wm-dark-quick-task button,
body:not(.wm-login-body) .wm-alert-state-actions button[name="state"][value="done"] {
    background: var(--wm-premium-red) !important;
    border-color: var(--wm-premium-red) !important;
    color: #fff !important;
}

body:not(.wm-login-body) .btn-primary:hover,
body:not(.wm-login-body) .btn-danger:hover,
body:not(.wm-login-body) .wm-dark-quick-task button:hover {
    background: var(--wm-premium-red-2) !important;
    border-color: var(--wm-premium-red-2) !important;
}

body:not(.wm-login-body) .btn-outline-primary,
body:not(.wm-login-body) .btn-outline-danger,
body:not(.wm-login-body) .btn-outline-secondary,
body:not(.wm-login-body) .wm-alert-state-actions button {
    background: #fff !important;
    border-color: var(--wm-premium-line-2) !important;
    color: var(--wm-premium-ink-2) !important;
}

body:not(.wm-login-body) .btn-outline-primary:hover,
body:not(.wm-login-body) .btn-outline-danger:hover,
body:not(.wm-login-body) .btn-outline-secondary:hover,
body:not(.wm-login-body) .wm-alert-state-actions button:hover {
    background: var(--wm-premium-red-soft) !important;
    border-color: rgba(212, 43, 30, .34) !important;
    color: var(--wm-premium-red-2) !important;
}

body:not(.wm-login-body) .badge,
body:not(.wm-login-body) .status-pill,
body:not(.wm-login-body) .module-status,
body:not(.wm-login-body) .wm-stat-pill,
body:not(.wm-login-body) .hour-badge,
body:not(.wm-login-body) .discount-hour-badge {
    box-shadow: none !important;
    border-radius: 7px !important;
}

body:not(.wm-login-body) .table,
body:not(.wm-login-body) .dashboard-table,
body:not(.wm-login-body) .proforma-table,
body:not(.wm-login-body) .plan-table,
body:not(.wm-login-body) .project-tariff-table {
    --bs-table-bg: #fff !important;
    --bs-table-color: var(--wm-premium-ink) !important;
    --bs-table-border-color: var(--wm-premium-line) !important;
    background: #fff !important;
    color: var(--wm-premium-ink) !important;
    border-color: var(--wm-premium-line) !important;
}

body:not(.wm-login-body) .table-responsive,
body:not(.wm-login-body) .dashboard-table-wrap {
    border-color: var(--wm-premium-line) !important;
    border-radius: var(--radius-sm) !important;
}

body:not(.wm-login-body) .table thead th,
body:not(.wm-login-body) .table-light,
body:not(.wm-login-body) .table-light th,
body:not(.wm-login-body) .dashboard-table thead th,
body:not(.wm-login-body) .proforma-table thead th,
body:not(.wm-login-body) .plan-table thead th,
body:not(.wm-login-body) .project-tariff-table thead th {
    --bs-table-bg: #2c3532 !important;
    --bs-table-color: #f8f9f6 !important;
    background: linear-gradient(180deg, #37413e, #262f2c) !important;
    color: #f8f9f6 !important;
    border-color: #48534f !important;
    text-shadow: none !important;
}

body:not(.wm-login-body) .table tbody tr:nth-child(odd) td,
body:not(.wm-login-body) .dashboard-table tbody tr:nth-child(odd) td,
body:not(.wm-login-body) .proforma-table tbody tr:nth-child(odd) td,
body:not(.wm-login-body) .plan-table tbody tr:nth-child(odd) td {
    --bs-table-bg: var(--wm-premium-row) !important;
    background: var(--wm-premium-row) !important;
}

body:not(.wm-login-body) .table tbody tr:nth-child(even) td,
body:not(.wm-login-body) .dashboard-table tbody tr:nth-child(even) td,
body:not(.wm-login-body) .proforma-table tbody tr:nth-child(even) td,
body:not(.wm-login-body) .plan-table tbody tr:nth-child(even) td {
    --bs-table-bg: var(--wm-premium-row-alt) !important;
    background: var(--wm-premium-row-alt) !important;
}

body:not(.wm-login-body) .table-hover tbody tr:hover td,
body:not(.wm-login-body) .dashboard-table tbody tr:hover td,
body:not(.wm-login-body) .proforma-table tbody tr:hover td,
body:not(.wm-login-body) .plan-table tbody tr:hover td {
    --bs-table-bg: var(--wm-premium-red-soft) !important;
    background: var(--wm-premium-red-soft) !important;
    color: var(--wm-premium-ink) !important;
}

body:not(.wm-login-body) .dashboard-table tfoot,
body:not(.wm-login-body) .dashboard-table tfoot tr,
body:not(.wm-login-body) .dashboard-table tfoot td,
body:not(.wm-login-body) .dashboard-table tfoot.table-light,
body:not(.wm-login-body) .dashboard-table tfoot.table-light tr,
body:not(.wm-login-body) .dashboard-table tfoot.table-light td,
body:not(.wm-login-body) .proforma-table tfoot,
body:not(.wm-login-body) .proforma-table tfoot tr,
body:not(.wm-login-body) .proforma-table tfoot td,
body:not(.wm-login-body) .table tfoot,
body:not(.wm-login-body) .table tfoot tr,
body:not(.wm-login-body) .table tfoot td {
    --bs-table-bg: #dfe5df !important;
    --bs-table-color: var(--wm-premium-ink) !important;
    background: #dfe5df !important;
    color: var(--wm-premium-ink) !important;
    border-color: var(--wm-premium-line-2) !important;
}

body:not(.wm-login-body) .dashboard-table tfoot td:last-child,
body:not(.wm-login-body) .proforma-table tfoot .total-cell,
body:not(.wm-login-body) .final-total-row .total-cell:last-child {
    color: var(--wm-premium-red-2) !important;
    font-weight: 900 !important;
}

body:not(.wm-login-body) .discount-row td,
body:not(.wm-login-body) .table-danger,
body:not(.wm-login-body) .table-danger td {
    --bs-table-bg: #fff0ee !important;
    background: #fff0ee !important;
    color: #8d2118 !important;
}

body:not(.wm-login-body) .alert-success {
    background: var(--wm-premium-green-soft) !important;
    border-color: #acd8ba !important;
    color: #135f34 !important;
}

body:not(.wm-login-body) .alert-warning,
body:not(.wm-login-body) .table-warning,
body:not(.wm-login-body) .table-warning td {
    background: var(--wm-premium-amber-soft) !important;
    border-color: #e7ce88 !important;
    color: #715006 !important;
}

body:not(.wm-login-body) .alert-danger {
    background: var(--wm-premium-red-soft) !important;
    border-color: #efb9b2 !important;
    color: #8d2118 !important;
}

body:not(.wm-login-body) .modal-content,
body:not(.wm-login-body) .modal-dialog .card {
    background: var(--wm-premium-surface-2) !important;
    color: var(--wm-premium-ink) !important;
    border: 1px solid var(--wm-premium-line) !important;
    box-shadow: 0 24px 70px rgba(28, 37, 34, .24) !important;
}

body:not(.wm-login-body) .wm-calendar-overlay {
    background: rgba(22, 29, 27, .38) !important;
}

body:not(.wm-login-body) .wm-calendar-day,
body:not(.wm-login-body) .wm-dark-calendar-grid button {
    color: var(--wm-premium-ink) !important;
    background: rgba(255, 255, 255, .62) !important;
    border-color: var(--wm-premium-line) !important;
}

body:not(.wm-login-body) .wm-calendar-day.is-today,
body:not(.wm-login-body) .wm-dark-calendar-grid button.is-today {
    color: #fff !important;
    background: var(--wm-premium-red) !important;
    border-color: var(--wm-premium-red) !important;
}

body:not(.wm-login-body) .wm-calendar-weekday {
    color: var(--wm-premium-muted) !important;
}

body:not(.wm-login-body) ::selection {
    color: #fff;
    background: var(--wm-premium-red);
}

body:not(.wm-login-body) ::-webkit-scrollbar-track {
    background: #dfe5df;
}

body:not(.wm-login-body) ::-webkit-scrollbar-thumb {
    background: #9fa9a3;
    border-radius: var(--radius-pill);
}

@media (max-width: 980px) {
    body:not(.wm-login-body) .wm-dark-hero.wm-hero-compact {
        grid-template-columns: 1fr !important;
    }
}

body:not(.wm-login-body) .btn-outline-light,
body:not(.wm-login-body) .hero-actions .btn-outline-light {
    background: #fff !important;
    border-color: var(--wm-premium-line-2) !important;
    color: var(--wm-premium-ink) !important;
}

body:not(.wm-login-body) .btn-outline-light:hover,
body:not(.wm-login-body) .hero-actions .btn-outline-light:hover {
    background: var(--wm-premium-red-soft) !important;
    border-color: rgba(212, 43, 30, .34) !important;
    color: var(--wm-premium-red-2) !important;
}

body:not(.wm-login-body) .sidebar a.nav-link,
body:not(.wm-login-body) .sidebar a.nav-sub-link,
body:not(.wm-login-body) .wm-sidebar a.wm-sidebar-link {
    color: rgba(247, 249, 246, .72) !important;
}

body:not(.wm-login-body) .sidebar a.nav-link.active,
body:not(.wm-login-body) .sidebar a.nav-sub-link.active,
body:not(.wm-login-body) .wm-sidebar a.wm-sidebar-link.active {
    color: #fff !important;
}

/* Final readability pass for dashboard microcopy and calendar overlays. */
body:not(.wm-login-body) .wm-dark-calendar header strong,
body:not(.wm-login-body) .wm-calendar-popover header strong {
    color: var(--wm-premium-ink) !important;
    text-shadow: none !important;
}

body:not(.wm-login-body) .wm-dark-calendar p,
body:not(.wm-login-body) .wm-dark-calendar p span,
body:not(.wm-login-body) .wm-pending-item time,
body:not(.wm-login-body) .wm-pending-item span,
body:not(.wm-login-body) .wm-calendar-popover-next time,
body:not(.wm-login-body) .wm-calendar-popover-next span,
body:not(.wm-login-body) .wm-calendar-popover-next p {
    color: var(--wm-premium-muted) !important;
    text-shadow: none !important;
}

body:not(.wm-login-body) .wm-pending-item strong,
body:not(.wm-login-body) .wm-calendar-popover-next strong {
    color: var(--wm-premium-ink) !important;
}

/* Highest-specificity cleanup: overrides older graphite module rules. */
html body:not(.wm-login-body):not(.wm-dark-shell),
html body:not(.wm-login-body):not(.wm-dark-shell) .main,
html body:not(.wm-login-body):not(.wm-dark-shell) .wrap {
    background:
        linear-gradient(rgba(22, 30, 28, .035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(22, 30, 28, .035) 1px, transparent 1px),
        var(--wm-premium-bg) !important;
    background-size: 46px 46px !important;
    color: var(--wm-premium-ink) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .page-header,
html body:not(.wm-login-body):not(.wm-dark-shell) .card,
html body:not(.wm-login-body):not(.wm-dark-shell) .modal-content,
html body:not(.wm-login-body):not(.wm-dark-shell) .dropdown-menu,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-collapsible-card,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-kpi-row .card,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context,
html body:not(.wm-login-body):not(.wm-dark-shell) .privacy-card,
html body:not(.wm-login-body):not(.wm-dark-shell) .permission-card {
    background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(247,249,246,.97)) !important;
    border-color: var(--wm-premium-line) !important;
    color: var(--wm-premium-ink) !important;
    box-shadow: 0 16px 38px rgba(28, 36, 33, .10) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .card-header,
html body:not(.wm-login-body):not(.wm-dark-shell) .modal-header,
html body:not(.wm-login-body):not(.wm-dark-shell) .modal-footer,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-collapsible-card > summary {
    background: linear-gradient(180deg, var(--paper), #f2f5f1) !important;
    border-color: var(--wm-premium-line) !important;
    color: var(--wm-premium-ink) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .table,
html body:not(.wm-login-body):not(.wm-dark-shell) .table > :not(caption) > * > *,
html body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-collapsible-card .table {
    --bs-table-bg: transparent !important;
    --bs-table-color: var(--wm-premium-ink) !important;
    background: #fff !important;
    border-color: var(--wm-premium-line) !important;
    color: var(--wm-premium-ink) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .table thead th,
html body:not(.wm-login-body):not(.wm-dark-shell) thead.table-light th,
html body:not(.wm-login-body):not(.wm-dark-shell) .dashboard-table thead th,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table thead th,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-collapsible-card .table thead th {
    --bs-table-bg: #29332f !important;
    background: linear-gradient(180deg, #3a4541, #29332f) !important;
    color: #f8f7f1 !important;
    border-color: rgba(255,255,255,.12) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .table tbody tr:nth-child(odd) td,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tbody tr:nth-child(odd) td,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-collapsible-card .table tbody tr:nth-child(odd) td {
    --bs-table-bg: var(--paper) !important;
    background: var(--paper) !important;
    color: var(--wm-premium-ink) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .table tbody tr:nth-child(even) td,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tbody tr:nth-child(even) td,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-collapsible-card .table tbody tr:nth-child(even) td {
    --bs-table-bg: var(--wm-premium-row-alt) !important;
    background: var(--wm-premium-row-alt) !important;
    color: var(--wm-premium-ink) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .table tfoot,
html body:not(.wm-login-body):not(.wm-dark-shell) .table tfoot tr,
html body:not(.wm-login-body):not(.wm-dark-shell) .table tfoot td,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tfoot,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tfoot tr,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table tfoot td,
html body:not(.wm-login-body):not(.wm-dark-shell) table.dashboard-table tfoot td {
    --bs-table-bg: #dfe5df !important;
    background: #dfe5df !important;
    color: var(--wm-premium-ink) !important;
    border-color: var(--wm-premium-line-2) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .discount-row td,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .discount-summary-row td {
    --bs-table-bg: var(--wm-premium-red-soft) !important;
    background: var(--wm-premium-red-soft) !important;
    color: #86231e !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .discount-title,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .discount-money,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .discount-total,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .final-total-row .total-cell:last-child {
    color: var(--wm-premium-red-2) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .text-muted,
html body:not(.wm-login-body):not(.wm-dark-shell) small,
html body:not(.wm-login-body):not(.wm-dark-shell) .form-text,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .text-muted,
html body:not(.wm-login-body):not(.wm-dark-shell) .proforma-table .discount-meta {
    color: var(--wm-premium-muted) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .page-header h1,
html body:not(.wm-login-body):not(.wm-dark-shell) .page-header h1 i,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-main strong,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-main strong b,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-obras span,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-obras span b,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-obras em,
html body:not(.wm-login-body):not(.wm-dark-shell) .card-body strong,
html body:not(.wm-login-body):not(.wm-dark-shell) .table .fw-semibold,
html body:not(.wm-login-body):not(.wm-dark-shell) .table .fw-bold {
    color: var(--wm-premium-ink) !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-main span,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-main small,
html body:not(.wm-login-body):not(.wm-dark-shell) .form-label,
html body:not(.wm-login-body):not(.wm-dark-shell) .card-body,
html body:not(.wm-login-body):not(.wm-dark-shell) .card-body p,
html body:not(.wm-login-body):not(.wm-dark-shell) .empty-state,
html body:not(.wm-login-body):not(.wm-dark-shell) .text-secondary {
    color: var(--wm-premium-muted) !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .form-control,
html body:not(.wm-login-body):not(.wm-dark-shell) .form-select,
html body:not(.wm-login-body):not(.wm-dark-shell) input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
html body:not(.wm-login-body):not(.wm-dark-shell) textarea,
html body:not(.wm-login-body):not(.wm-dark-shell) select {
    background: #fff !important;
    border-color: var(--wm-premium-line-2) !important;
    color: var(--wm-premium-ink) !important;
    box-shadow: none !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) select option,
html body:not(.wm-login-body):not(.wm-dark-shell) .form-select option {
    background: #fff !important;
    color: var(--wm-premium-ink) !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .badge.bg-primary-subtle,
html body:not(.wm-login-body):not(.wm-dark-shell) .bg-primary-subtle,
html body:not(.wm-login-body):not(.wm-dark-shell) .wm-period-summary {
    background: var(--wm-premium-red-soft) !important;
    border: 1px solid #efb9b2 !important;
    color: #8d2118 !important;
}

html body:not(.wm-login-body):not(.wm-dark-shell) .wm-project-context-action {
    background: var(--wm-premium-red-soft) !important;
    border-color: rgba(212, 43, 30, .34) !important;
    color: var(--wm-premium-red-2) !important;
}

/* 2026-06-30 contrast audit: one readable system for every Work Manager module. */
html body:not(.wm-login-body) {
    --wm-audit-bg: #e7ebe8;
    --wm-audit-surface: #f8faf7;
    --wm-audit-white: var(--paper);
    --wm-audit-row: var(--paper);
    --wm-audit-row-alt: #f1f5f1;
    --wm-audit-ink: #1b2421;
    --wm-audit-muted: #5f6b66;
    --wm-audit-line: #cbd6d0;
    --wm-audit-head: #29332f;
    --wm-audit-red: var(--red);
    --wm-audit-red-2: var(--red-dark);
    --wm-audit-red-soft: #fff0ee;
    --wm-audit-green: #176b43;
    --wm-audit-green-soft: #e6f4eb;
    --wm-audit-amber: #996706;
    --wm-audit-amber-soft: #fff4d8;
    color: var(--wm-audit-ink) !important;
}

html body:not(.wm-login-body) .wm-page-hero,
html body:not(.wm-login-body) .wm-dark-hero,
html body:not(.wm-login-body) .page-header,
html body:not(.wm-login-body) .card,
html body:not(.wm-login-body) .modal-content,
html body:not(.wm-login-body) .wm-collapsible-card,
html body:not(.wm-login-body) .company-toolbar-card,
html body:not(.wm-login-body) .permission-card,
html body:not(.wm-login-body) .project-module-card,
html body:not(.wm-login-body) .proforma-kpi-row .card,
html body:not(.wm-login-body) .dash-kpi,
html body:not(.wm-login-body) .insight-card,
html body:not(.wm-login-body) .chart-card {
    background: linear-gradient(180deg, rgba(255,255,255,.97), rgba(247,249,246,.98)) !important;
    border-color: var(--wm-audit-line) !important;
    color: var(--wm-audit-ink) !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body) .wm-page-hero::before,
html body:not(.wm-login-body) .wm-dark-hero::before {
    opacity: .16 !important;
}

html body:not(.wm-login-body) .wm-page-hero h1,
html body:not(.wm-login-body) .wm-page-hero p,
html body:not(.wm-login-body) .wm-command-stats,
html body:not(.wm-login-body) .wm-stat-pill,
html body:not(.wm-login-body) .wm-stat-pill *,
html body:not(.wm-login-body) .wm-hero-today,
html body:not(.wm-login-body) .wm-hero-today *,
html body:not(.wm-login-body) .wm-hero-clock,
html body:not(.wm-login-body) .wm-hero-clock *,
html body:not(.wm-login-body) .dash-kpi *,
html body:not(.wm-login-body) .insight-card *,
html body:not(.wm-login-body) .chart-card *,
html body:not(.wm-login-body) .company-toolbar *,
html body:not(.wm-login-body) .company-chip,
html body:not(.wm-login-body) .company-chip *,
html body:not(.wm-login-body) .company-context-note {
    color: var(--wm-audit-ink) !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body) .wm-page-hero p,
html body:not(.wm-login-body) .wm-hero-today small,
html body:not(.wm-login-body) .dash-kpi-body span,
html body:not(.wm-login-body) .dash-kpi-body em,
html body:not(.wm-login-body) .insight-label,
html body:not(.wm-login-body) .insight-meta,
html body:not(.wm-login-body) .company-context-note,
html body:not(.wm-login-body) .company-count {
    color: var(--wm-audit-muted) !important;
}

html body:not(.wm-login-body) .wm-stat-pill {
    background: rgba(255,255,255,.82) !important;
    border: 1px solid var(--wm-audit-line) !important;
}

html body:not(.wm-login-body) .wm-stat-pill strong,
html body:not(.wm-login-body) .wm-page-hero .wm-label,
html body:not(.wm-login-body) .wm-hero-today span {
    color: var(--wm-audit-red) !important;
}

html body:not(.wm-login-body) .wm-hero-focus {
    align-self: end !important;
    padding: 12px 14px !important;
    border: 1px solid rgba(212,43,30,.18) !important;
    border-radius: var(--radius) !important;
    background: rgba(255,255,255,.58) !important;
}

html body:not(.wm-login-body) .wm-hero-focus strong,
html body:not(.wm-login-body) .wm-hero-focus small {
    display: block !important;
}

html body:not(.wm-login-body) .btn-primary,
html body:not(.wm-login-body) .btn-danger,
html body:not(.wm-login-body) .btn-success,
html body:not(.wm-login-body) .btn-dark,
html body:not(.wm-login-body) .btn-action,
html body:not(.wm-login-body) button.btn-primary,
html body:not(.wm-login-body) button.btn-danger,
html body:not(.wm-login-body) button.btn-success,
html body:not(.wm-login-body) a.btn-primary,
html body:not(.wm-login-body) a.btn-danger,
html body:not(.wm-login-body) a.btn-success {
    color: #fff !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body) .btn-primary *,
html body:not(.wm-login-body) .btn-danger *,
html body:not(.wm-login-body) .btn-success *,
html body:not(.wm-login-body) .btn-dark *,
html body:not(.wm-login-body) .btn-action * {
    color: inherit !important;
}

html body:not(.wm-login-body) .btn-success {
    background: var(--wm-audit-green) !important;
    border-color: var(--wm-audit-green) !important;
}

html body:not(.wm-login-body) .btn-primary,
html body:not(.wm-login-body) .btn-danger,
html body:not(.wm-login-body) .btn-dark,
html body:not(.wm-login-body) .btn-action {
    background: var(--wm-audit-red) !important;
    border-color: var(--wm-audit-red) !important;
}

html body:not(.wm-login-body) .btn-outline-primary,
html body:not(.wm-login-body) .btn-outline-danger,
html body:not(.wm-login-body) .btn-outline-secondary,
html body:not(.wm-login-body) .btn-outline-success,
html body:not(.wm-login-body) .btn-outline-light {
    background: #fff !important;
    border-color: var(--wm-audit-line) !important;
    color: var(--wm-audit-ink) !important;
}

html body:not(.wm-login-body) .btn-outline-primary:hover,
html body:not(.wm-login-body) .btn-outline-danger:hover,
html body:not(.wm-login-body) .btn-outline-secondary:hover,
html body:not(.wm-login-body) .btn-outline-success:hover,
html body:not(.wm-login-body) .btn-outline-light:hover {
    background: var(--wm-audit-red-soft) !important;
    border-color: rgba(212,43,30,.42) !important;
    color: var(--wm-audit-red-2) !important;
}

html body:not(.wm-login-body) .table .badge,
html body:not(.wm-login-body) .dashboard-table .badge,
html body:not(.wm-login-body) .proforma-table .badge,
html body:not(.wm-login-body) .badge.bg-secondary,
html body:not(.wm-login-body) .badge.bg-secondary-subtle,
html body:not(.wm-login-body) .badge.bg-primary-subtle,
html body:not(.wm-login-body) .company-chip,
html body:not(.wm-login-body) .project-pill,
html body:not(.wm-login-body) .work-chip {
    background: #edf2ed !important;
    border: 1px solid var(--wm-audit-line) !important;
    color: var(--wm-audit-ink) !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body) .badge.bg-primary-subtle,
html body:not(.wm-login-body) .table .badge.bg-primary-subtle,
html body:not(.wm-login-body) .company-chip.project,
html body:not(.wm-login-body) .wm-period-summary {
    background: var(--wm-audit-red-soft) !important;
    border-color: #efb9b2 !important;
    color: #8d2118 !important;
}

html body:not(.wm-login-body) .badge.bg-warning,
html body:not(.wm-login-body) .badge.text-bg-warning {
    background: var(--wm-audit-amber-soft) !important;
    color: #6b4a05 !important;
}

html body:not(.wm-login-body) .badge.bg-success,
html body:not(.wm-login-body) .status-active {
    background: var(--wm-audit-green-soft) !important;
    color: #145c37 !important;
}

html body:not(.wm-login-body) .table > :not(caption) > * > *,
html body:not(.wm-login-body) .dashboard-table > :not(caption) > * > *,
html body:not(.wm-login-body) .proforma-table > :not(caption) > * > *,
html body:not(.wm-login-body) .plan-table > :not(caption) > * > * {
    color: var(--wm-audit-ink) !important;
    border-color: var(--wm-audit-line) !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body) .table thead th,
html body:not(.wm-login-body) .dashboard-table thead th,
html body:not(.wm-login-body) .proforma-table thead th,
html body:not(.wm-login-body) .plan-table thead th {
    background: linear-gradient(180deg, #3a4541, #29332f) !important;
    color: #f8f7f1 !important;
}

html body:not(.wm-login-body) .table tbody tr:nth-child(odd) td,
html body:not(.wm-login-body) .dashboard-table tbody tr:nth-child(odd) td,
html body:not(.wm-login-body) .proforma-table tbody tr:nth-child(odd) td,
html body:not(.wm-login-body) .plan-table tbody tr:nth-child(odd) td {
    background: var(--wm-audit-row) !important;
}

html body:not(.wm-login-body) .table tbody tr:nth-child(even) td,
html body:not(.wm-login-body) .dashboard-table tbody tr:nth-child(even) td,
html body:not(.wm-login-body) .proforma-table tbody tr:nth-child(even) td,
html body:not(.wm-login-body) .plan-table tbody tr:nth-child(even) td {
    background: var(--wm-audit-row-alt) !important;
}

html body:not(.wm-login-body) .proforma-table tfoot td,
html body:not(.wm-login-body) .dashboard-table tfoot td,
html body:not(.wm-login-body) .table tfoot td {
    background: #dfe5df !important;
    color: var(--wm-audit-ink) !important;
}

html body:not(.wm-login-body) .proforma-table .discount-row td,
html body:not(.wm-login-body) .proforma-table .discount-summary-row td,
html body:not(.wm-login-body) .table-danger td {
    background: var(--wm-audit-red-soft) !important;
    color: #86231e !important;
}

html body:not(.wm-login-body) .proforma-table .desc-cell,
html body:not(.wm-login-body) .proforma-table .money-cell,
html body:not(.wm-login-body) .proforma-table .total-cell,
html body:not(.wm-login-body) .plan-name,
html body:not(.wm-login-body) .plan-tech-name,
html body:not(.wm-login-body) .cell-obra,
html body:not(.wm-login-body) .cell-libre,
html body:not(.wm-login-body) .cell-sin {
    color: var(--wm-audit-ink) !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body) .cell-hora {
    color: var(--wm-audit-green) !important;
}

html body:not(.wm-login-body) .cell-vacaciones {
    color: var(--info) !important;
}

html body:not(.wm-login-body) .cell-festivo {
    color: var(--wm-audit-green) !important;
}

html body:not(.wm-login-body) .plan-table td.findesemana {
    background: #fff0ee !important;
    color: var(--wm-audit-ink) !important;
}

html body:not(.wm-login-body) .company-search,
html body:not(.wm-login-body) .company-toolbar select,
html body:not(.wm-login-body) .company-toolbar input {
    background: #fff !important;
    border-color: var(--wm-audit-line) !important;
    color: var(--wm-audit-ink) !important;
}

html body:not(.wm-login-body) .company-search input::placeholder {
    color: #7e8984 !important;
}

html body:not(.wm-login-body) canvas {
    background: transparent !important;
}

/* Master console: keep daily controls visible and advanced tools quiet. */
html body:not(.wm-login-body) .system-command-section {
    background: linear-gradient(180deg, rgba(255,255,255,.94), rgba(248,249,246,.98));
    border: 1px solid var(--wm-premium-line);
    border-radius: var(--wm-premium-radius);
    box-shadow: var(--wm-premium-shadow-soft);
    padding: 18px;
}

html body:not(.wm-login-body) .system-section-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, .65fr);
    gap: 18px;
    align-items: end;
    margin-bottom: 14px;
}

html body:not(.wm-login-body) .system-section-head h2 {
    margin: 0;
    color: var(--wm-premium-ink);
    font-size: 1.25rem;
    font-weight: 900;
    letter-spacing: 0;
}

html body:not(.wm-login-body) .system-section-head p {
    margin: 0;
    color: var(--wm-premium-muted);
    line-height: 1.45;
}

html body:not(.wm-login-body) .action-grid-priority,
html body:not(.wm-login-body) .action-grid-secondary {
    margin: 0;
}

html body:not(.wm-login-body) .action-tile-primary {
    border-color: rgba(212,43,30,.22) !important;
    box-shadow: inset 4px 0 0 rgba(212,43,30,.88), var(--wm-premium-shadow-soft) !important;
}

html body:not(.wm-login-body) .system-advanced {
    padding: 0;
    overflow: hidden;
}

html body:not(.wm-login-body) .system-advanced > summary.system-section-head {
    cursor: pointer;
    list-style: none;
    margin: 0;
    padding: 18px;
    align-items: center;
}

html body:not(.wm-login-body) .system-advanced > summary.system-section-head::-webkit-details-marker {
    display: none;
}

html body:not(.wm-login-body) .system-advanced[open] > summary.system-section-head {
    border-bottom: 1px solid var(--wm-premium-line);
}

html body:not(.wm-login-body) .system-advanced .action-grid-secondary {
    padding: 18px;
}

html body:not(.wm-login-body) .system-advanced:not([open]) {
    background: linear-gradient(180deg, rgba(255,255,255,.72), rgba(245,247,244,.88));
}

@media (max-width: 900px) {
    html body:not(.wm-login-body) .system-section-head {
        grid-template-columns: 1fr;
    }
}

/* ── Calendario del menu: fondo oscuro fijo, siempre ─────────────────────
   .wm-dark-calendar se diseño con texto claro para fondo oscuro, pero el
   bloque "premium" de mas arriba (body:not(.wm-login-body) ..., ~4800-5170)
   nunca excluye .wm-dark-shell y le aplicaba fondo claro + tinta oscura de
   todas formas -- unico sitio de esa lista sin re-colorear TODOS sus
   textos (los botones/"Hoy" de la cabecera se quedaban con su rgba blanca
   original encima de ese fondo claro). Medido en el navegador: el chip
   "Hoy" quedaba en 1,06:1. Decision (04-ago-2026): el calendario NUNCA
   cambia de tema segun donde aparezca -- fondo solido y opaco propio
   (no depende de lo que haya detras, a diferencia de un rgba semitransp-
   arente) y se recupera el texto claro original. Selectores con el
   prefijo "html body:not(.wm-login-body)" para tener mas especificidad
   que las reglas del bloque premium y ganar siempre, sea cual sea el
   orden en el fichero -- mismo patron ya usado en la "Highest-specificity
   cleanup" de mas arriba. */
html body:not(.wm-login-body) .wm-dark-calendar {
    background-color: var(--wm-night-3) !important;
    border: 1px solid var(--wm-dark-line) !important;
    border-radius: var(--radius-sm) !important;
    padding: 16px !important;
}

html body:not(.wm-login-body) .wm-dark-calendar .wm-calendar-weekday {
    color: rgba(255,255,255,.48) !important;
}

html body:not(.wm-login-body) .wm-dark-calendar .wm-calendar-day {
    color: rgba(255,255,255,.90) !important;
    background: transparent !important;
    border-color: transparent !important;
}

html body:not(.wm-login-body) .wm-dark-calendar .wm-calendar-day.is-muted {
    color: rgba(255,255,255,.60) !important;
}

html body:not(.wm-login-body) .wm-dark-calendar .wm-calendar-day.is-today {
    color: #fff !important;
    background: var(--wm-red-hot) !important;
    border-color: var(--wm-red-hot) !important;
}

html body:not(.wm-login-body) .wm-dark-calendar header strong {
    color: #fff !important;
    text-shadow: none !important;
}

html body:not(.wm-login-body) .wm-dark-calendar p,
html body:not(.wm-login-body) .wm-dark-calendar p span {
    color: rgba(255,255,255,.55) !important;
    text-shadow: none !important;
}

/* ── Buscador por palabra sobre <select> largos ──────────────────────────
   Los estilos .bsc-* NO están aquí: los inyecta el propio buscador-select.js.
   La aplicación tiene tres mundos de CSS distintos (esta hoja, llorca-ui.css
   en module_base.html, y las pantallas de tablet que no cargan ninguna de las
   dos), así que atar el componente a una sola hoja lo dejaba sin estilo en dos
   tercios de las pantallas. Viajando dentro del JS funciona en las tres. */
