html, body {
    height: 100%;
    margin: 0;
    font-family: "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
    background: #eef1f6;
    color: rgb(5, 21, 104);
}

a, .btn-link {
    color: rgb(5, 21, 104);
}

.btn-primary {
    color: #fefefe;
    background-color: rgb(5, 21, 104);
    border-color: rgb(5, 21, 104);
}

.btn-primary:hover,
.btn-primary:focus {
    color: #fefefe;
    background-color: rgb(5, 21, 104);
    border-color: rgb(5, 21, 104);
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

:root {
    --sv-primary: rgb(5, 21, 104);
    --sv-white: rgb(254, 254, 254);
    --sv-gray: rgb(153, 161, 175);
    --sv-rail: #071247;
    --sv-topbar: #DADADD;
    --sv-canvas: #eef1f6;
}

.sv-wordmark {
    display: inline-flex;
    align-items: baseline;
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: -0.06em;
    line-height: 1;
    text-transform: uppercase;
}

.sv-wordmark-s {
    color: #2b6cff;
}

.sv-wordmark-rest {
    color: #0b1228;
}

.sv-topbar .sv-wordmark {
    font-size: 1.15rem;
}

.auth-identity .sv-wordmark {
    font-size: 1.65rem;
}

.auth-brandline {
    display: inline-flex;
    align-items: baseline;
    gap: 0.02em;
}

.auth-fleet {
    color: #2b6cff;
    font-size: 1.15rem;
    font-weight: 750;
    letter-spacing: -0.05em;
    line-height: 1;
    text-transform: lowercase;
}

.auth-shell {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--sv-primary);
    padding: 1.5rem;
    position: relative;
}

.auth-shell.setup-bg {
    background-color: var(--sv-primary);
    background-image: url("/img/bg.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.auth-shell.setup-bg::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(5, 21, 104, 0.35);
}

.auth-center {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 440px;
}

.auth-center-setup {
    max-width: 560px;
}

.auth-shell:has(.auth-center-gate) {
    align-items: flex-start;
    justify-content: center;
    overflow: auto;
}

.auth-center-gate {
    max-width: 1040px;
    width: 100%;
    margin: auto;
}

.conn-gate {
    background: var(--sv-white);
    border-radius: 16px;
    padding: 1.5rem 1.4rem 1.25rem;
    box-shadow:
        0 1px 2px rgba(5, 21, 104, 0.06),
        0 18px 44px rgba(5, 21, 104, 0.22);
}

.conn-gate .auth-logo {
    width: 48px;
    height: 48px;
}

.auth-panel {
    background: var(--sv-white);
    border: 1px solid rgba(5, 21, 104, 0.06);
    border-radius: 16px;
    padding: 2rem 1.75rem 1.5rem;
    box-shadow:
        0 1px 2px rgba(5, 21, 104, 0.06),
        0 18px 44px rgba(5, 21, 104, 0.22);
}

.auth-identity {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 0.85rem;
}

.auth-logo {
    width: 72px;
    height: 72px;
    object-fit: contain;
}

.auth-title {
    margin: 0 0 0.45rem;
    color: var(--sv-primary);
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1.25;
}

.page-lead {
    margin: 0 0 1.35rem;
    color: #6b7585;
    font-size: 0.95rem;
    line-height: 1.45;
}

.auth-panel .form-label,
.auth-panel .form-check-label {
    color: var(--sv-primary);
    font-size: 0.9rem;
    font-weight: 600;
}

.auth-panel .form-control {
    background: var(--sv-white);
    border-color: var(--sv-gray);
    color: var(--sv-primary);
}

.auth-panel .form-control:focus {
    border-color: var(--sv-primary);
    box-shadow: 0 0 0 0.15rem rgba(5, 21, 104, 0.15);
}

.auth-panel .form-check-input {
    border-color: var(--sv-gray);
}

.auth-panel .form-check-input:checked {
    background-color: var(--sv-primary);
    border-color: var(--sv-primary);
}

.auth-panel .btn-primary {
    background-color: var(--sv-primary);
    border-color: var(--sv-primary);
    color: var(--sv-white);
}

.auth-panel .btn-primary:hover,
.auth-panel .btn-primary:focus {
    background-color: var(--sv-primary);
    border-color: var(--sv-primary);
    color: var(--sv-white);
}

.auth-panel .btn-link {
    color: var(--sv-gray);
    text-decoration: none;
}

.auth-panel .btn-link:hover {
    color: var(--sv-primary);
}

.engine-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 0.6rem;
    margin-bottom: 1.25rem;
}

.engine-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    border: 1px solid rgba(5, 21, 104, 0.1);
    background: var(--sv-white);
    color: var(--sv-primary);
    border-radius: 12px;
    padding: 0.7rem 0.8rem;
    text-align: left;
    box-shadow: 0 6px 16px rgba(5, 21, 104, 0.06);
}

.engine-card:hover {
    border-color: var(--sv-primary);
}

.engine-card.selected {
    border-color: var(--sv-primary);
    background: var(--sv-primary);
    color: var(--sv-white);
}

.engine-card small {
    color: var(--sv-gray);
    font-size: 0.75rem;
}

.engine-card.selected small {
    color: var(--sv-white);
    opacity: 0.8;
}

.setup-message {
    margin-top: 0;
    margin-bottom: 1rem;
    padding: 0.7rem 0.8rem;
    border-radius: 4px;
    font-size: 0.9rem;
}

.setup-message.is-ok {
    color: var(--sv-primary);
    border: 1px solid var(--sv-primary);
}

.setup-message.is-error {
    color: var(--sv-primary);
    border: 1px solid var(--sv-gray);
    background: var(--sv-white);
}

.setup-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.35rem;
}

.setup-actions .btn:disabled {
    opacity: 0.4;
    pointer-events: none;
}

.setup-busy {
    height: 3px;
    margin-top: 1rem;
    background: var(--sv-gray);
    overflow: hidden;
}

.setup-busy::after {
    content: "";
    display: block;
    height: 100%;
    width: 40%;
    background: var(--sv-primary);
    animation: setup-busy 0.9s linear infinite;
}

@keyframes setup-busy {
    from { transform: translateX(-100%); }
    to { transform: translateX(350%); }
}

@media (max-width: 640px) {
    .engine-grid {
        grid-template-columns: 1fr;
    }
}

.sv-app {
    display: grid;
    grid-template-columns: 264px minmax(0, 1fr);
    grid-template-rows: 52px minmax(0, 1fr);
    height: 100%;
    overflow: hidden;
}

.sv-app:has(.sv-rail-toggle:checked) {
    grid-template-columns: 0 minmax(0, 1fr);
}

.sv-rail-toggle {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
    pointer-events: none;
}

.sv-topbar {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0 0.85rem;
    background: var(--sv-topbar);
    color: var(--sv-primary);
    border-bottom: 1px solid #929292;
}

.sv-collapse {
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--sv-primary);
    cursor: pointer;
    display: grid;
    place-items: center;
    padding: 0;
    margin: 0;
}

.sv-collapse svg {
    width: 20px;
    height: 20px;
}

.sv-collapse:hover {
    background: rgba(5, 21, 104, 0.08);
}

.sv-logo {
    width: 30px;
    height: 30px;
    object-fit: contain;
    flex-shrink: 0;
}

.sv-rail {
    display: flex;
    flex-direction: column;
    background: var(--sv-rail);
    color: #d5dee5;
    min-height: 0;
    overflow: hidden;
}

.sv-app:has(.sv-rail-toggle:checked) .sv-rail {
    pointer-events: none;
}

.sv-nav {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.7rem 0.6rem 0.4rem;
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
}

.sv-nav-link {
    display: block;
    padding: 0.55rem 0.75rem;
    border-radius: 8px;
    color: #c5d0d6;
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 550;
}

.sv-nav-link:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
}

.sv-nav-link.active {
    background: rgba(254, 254, 254, 0.16);
    color: #fff;
}

.sv-nav-group {
    margin: 0.9rem 0.75rem 0.15rem;
    color: #8ea0a8;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.sv-nav-sub {
    padding-left: 1.35rem;
}

.sv-session {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 0 0 auto;
    padding: 0.75rem 0.7rem 0.95rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.sv-session-block {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.22rem;
    width: 100%;
    box-sizing: border-box;
    min-width: 0;
    padding: 0.58rem 0.72rem 0.62rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
}

.sv-session-label {
    display: block;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(158, 176, 184, 0.92);
    line-height: 1;
}

a.sv-session-conn {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

a.sv-session-conn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.sv-session-block strong {
    color: #f4f7f8;
    font-size: 0.84rem;
    font-weight: 650;
    line-height: 1.28;
    overflow-wrap: anywhere;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.sv-session-user {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.35rem 0.45rem 0.15rem;
    min-width: 0;
}

.sv-session-user > span:last-child {
    min-width: 0;
    overflow: hidden;
}

.sv-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    background: #d8c4a3;
    color: var(--sv-primary);
    font-weight: 700;
    font-size: 0.72rem;
}

.sv-session-user strong {
    display: block;
    color: #f4f7f8;
    font-size: 0.86rem;
    font-weight: 650;
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sv-session-user em {
    display: block;
    font-style: normal;
    font-size: 0.72rem;
    color: #9eb0b8;
}

.sv-session form {
    margin: 0;
}

.sv-logout {
    display: block;
    width: 100%;
    padding: 0.52rem 0.7rem;
    border: 0;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    color: #c5d0d6;
    text-align: center;
    text-decoration: none;
    font-size: 0.78rem;
    font-weight: 650;
    letter-spacing: 0.04em;
    cursor: pointer;
    font-family: inherit;
}

.sv-logout:hover {
    background: rgba(196, 92, 38, 0.22);
    color: #fff;
}

.sv-main {
    min-width: 0;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    background: var(--sv-canvas);
}

.sv-page {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 1.35rem 1.6rem 2.5rem;
}

#blazor-error-ui {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-sizing: border-box;
    padding: 0.6rem 1.25rem 0.7rem;
    background: #fff6d8;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

@media (max-width: 900px) {
    .sv-app,
    .sv-app:has(.sv-rail-toggle:checked) {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: 52px auto minmax(0, 1fr);
    }

    .sv-app:has(.sv-rail-toggle:checked) {
        grid-template-rows: 52px 0 minmax(0, 1fr);
    }

    .sv-rail {
        flex-direction: row;
        align-items: stretch;
        overflow-x: auto;
        overflow-y: hidden;
    }

    .sv-nav {
        flex-direction: row;
        flex: 1 1 auto;
        min-width: 0;
        padding: 0.45rem;
        overflow-x: auto;
        overflow-y: hidden;
    }

    .sv-session {
        flex-direction: row;
        align-items: center;
        border-top: 0;
        border-left: 1px solid rgba(255, 255, 255, 0.08);
        min-width: 280px;
    }
}

.page-kicker {
    margin: 0 0 0.35rem;
    color: var(--sv-gray);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.page-title {
    margin: 0 0 0.45rem;
    color: var(--sv-primary);
    font-size: 1.65rem;
    font-weight: 650;
    letter-spacing: -0.03em;
}

.page-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.2rem;
}

.sv-back {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    margin: 0 0 0.4rem;
    padding: 0.28rem 0.7rem 0.28rem 0.4rem;
    border-radius: 999px;
    background: #e8eefc;
    color: var(--sv-primary);
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
}

.sv-back svg {
    width: 16px;
    height: 16px;
}

.sv-back:hover {
    background: #d9e3fa;
    color: var(--sv-primary);
}

.home-screen {
    width: 100%;
    max-width: none;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.home-head {
    flex: 0 0 auto;
}

.home-head h1 {
    margin: 0;
    color: var(--sv-primary);
    font-size: 1.2rem;
    font-weight: 650;
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.home-head p {
    margin: 0.12rem 0 0;
    color: #6d7788;
    font-size: 0.82rem;
}

.home-group {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    min-width: 0;
}

@media (min-width: 901px) {
    .sv-main:has(.home-screen) {
        display: flex;
        flex-direction: column;
        background:
            radial-gradient(880px 380px at 0% -8%, rgba(43, 108, 255, 0.09), transparent 58%),
            radial-gradient(640px 320px at 100% 0%, rgba(5, 21, 104, 0.06), transparent 52%),
            var(--sv-canvas);
    }

    .sv-page:has(.home-screen) {
        display: flex;
        flex-direction: column;
        flex: 1 0 auto;
        min-height: 100%;
        padding: 1.15rem 1.35rem 1rem;
    }

    .home-screen {
        flex: 0 0 auto;
        justify-content: flex-start;
        gap: 0.7rem;
        min-height: 0;
    }

    .home-group {
        flex: 0 0 auto;
    }

    .home-group.is-feature,
    .home-group.is-tiles {
        flex-grow: 0;
    }
}

.home-context {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin: -0.35rem 0 1.15rem;
}

.home-context span,
.home-context a {
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
    min-width: 11rem;
    max-width: 22rem;
    padding: 0.55rem 0.8rem;
    background: var(--sv-white);
    border: 1px solid rgba(5, 21, 104, 0.08);
    border-radius: 10px;
    text-decoration: none;
    color: inherit;
}

.home-context a:hover {
    border-color: rgba(5, 21, 104, 0.28);
}

.home-context em {
    font-style: normal;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #8b93a3;
}

.home-context strong {
    color: var(--sv-primary);
    font-size: 0.88rem;
    font-weight: 650;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.home-screen .page-head {
    margin-bottom: 1rem;
}

.home-screen .page-lead {
    margin: 0;
}

.home-kicker {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin: 0;
    color: #8b95a7;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    flex: 0 0 auto;
}

.home-kicker::after {
    content: "";
    flex: 1 1 auto;
    height: 1px;
    background: linear-gradient(90deg, rgba(5, 21, 104, 0.16), rgba(5, 21, 104, 0.04));
}

.home-primary,
.home-grid,
.home-rows,
.home-tiles,
.home-group:last-child .home-rows {
    display: grid;
    grid-template-columns: repeat(auto-fill, 112px);
    justify-content: start;
    align-content: start;
    gap: 0.45rem 0.55rem;
    min-height: 0;
}

.home-card {
    --tone: #051568;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 0.42rem;
    width: 112px;
    height: auto;
    min-height: 0;
    padding: 0.72rem 0.35rem 0.58rem;
    background: #fff;
    border: 1px solid rgba(16, 24, 40, 0.06);
    border-radius: 18px;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.04);
    color: #172033;
    text-align: center;
    text-decoration: none;
    transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.home-card:hover {
    transform: translateY(-2px);
    border-color: color-mix(in srgb, var(--tone) 28%, white);
    box-shadow: 0 8px 16px rgba(5, 21, 104, 0.1);
    color: #172033;
    text-decoration: none;
}

.home-card:focus-visible {
    outline: 2px solid var(--sv-primary);
    outline-offset: 2px;
}

.home-card:has(.is-info) { --tone: #0284c7; }
.home-card:has(.is-ok) { --tone: #059669; }
.home-card:has(.is-warn) { --tone: #d97706; }
.home-card:has(.is-violet) { --tone: #7c3aed; }
.home-card:has(.is-rose) { --tone: #e11d48; }
.home-card:has(.is-navy) { --tone: #1d4ed8; }
.home-card:has(.is-slate) { --tone: #475569; }

.home-card-lg,
.home-rows .home-card,
.home-tiles .home-card {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    width: 112px;
    min-height: 0;
    padding: 0.72rem 0.35rem 0.58rem;
    background: #fff;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.04);
}

.home-card-lg::after,
.home-rows .home-card::after {
    content: none;
}

.home-copy {
    display: flex;
    flex-direction: column;
    gap: 0.16rem;
    min-width: 0;
}

.home-copy {
    align-items: center;
}

.home-copy em {
    display: none;
}

.home-card strong,
.home-card-lg strong,
.home-rows strong {
    font-size: 0.72rem;
    font-weight: 650;
    line-height: 1.2;
    letter-spacing: -0.01em;
}

.home-icon,
.home-card-lg .home-icon,
.home-rows .home-icon,
.home-tiles .home-icon {
    width: 2.45rem;
    height: 2.45rem;
    margin: 0;
    border-radius: 14px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}

.home-icon svg {
    width: 1.3rem;
    height: 1.3rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.home-card-lg .home-icon svg {
    width: 1.35rem;
    height: 1.35rem;
}

.home-icon.is-info { background: #e0f2fe; color: #0369a1; }
.home-icon.is-ok { background: #d1fae5; color: #047857; }
.home-icon.is-warn { background: #fef3c7; color: #b45309; }
.home-icon.is-violet { background: #ede9fe; color: #6d28d9; }
.home-icon.is-rose { background: #ffe4e6; color: #be123c; }
.home-icon.is-navy { background: #e8eefc; color: var(--sv-primary); }
.home-icon.is-slate { background: #eef1f6; color: #475569; }

@media (max-width: 640px) {
    .home-primary,
    .home-grid,
    .home-rows,
    .home-tiles,
    .home-group:last-child .home-rows {
        grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
        justify-content: stretch;
    }

    .home-card,
    .home-card-lg,
    .home-rows .home-card,
    .home-tiles .home-card {
        width: auto;
    }
}

.conn-card {
    background: var(--sv-white);
    border: 1px solid rgba(5, 21, 104, 0.08);
    border-radius: 14px;
    box-shadow:
        0 1px 2px rgba(5, 21, 104, 0.04),
        0 10px 28px rgba(5, 21, 104, 0.08);
}

.conn-board {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.conn-stack {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.85rem;
}

.conn-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 0.85rem 1rem;
}

.conn-toolbar input {
    max-width: 22rem;
}

.conn-count {
    color: #6b7585;
    font-size: 0.82rem;
    white-space: nowrap;
}

.conn-item {
    display: flex;
    flex-direction: column;
    min-height: 132px;
    padding: 0.8rem 0.85rem 0.65rem;
    background: var(--sv-white);
    border: 1px solid #e4e7ee;
    border-left: 3px solid var(--sv-primary);
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(5, 21, 104, 0.05), 0 8px 18px rgba(5, 21, 104, 0.06);
}

.conn-item-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.6rem;
}

.conn-item-top strong {
    color: #1c2434;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.conn-db {
    color: var(--sv-primary);
    flex-shrink: 0;
    line-height: 0;
}

.conn-item-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.9rem;
    margin-top: 0.45rem;
    color: #8b93a3;
    font-size: 0.8rem;
}

.conn-meta {
    display: block;
    color: #6b7585;
    font-size: 0.75rem;
}

.conn-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    justify-content: flex-end;
    margin-top: auto;
    padding-top: 0.7rem;
    border-top: 1px solid #eceff4;
}

.conn-actions button {
    width: 32px;
    height: 32px;
    padding: 0;
    display: grid;
    place-items: center;
    border: 1px solid #d5dbe6;
    background: #fff;
    color: #5c677a;
    border-radius: 8px;
    cursor: pointer;
}

.conn-actions button.is-use {
    color: var(--sv-primary);
    border-color: rgba(5, 21, 104, 0.28);
}

.conn-actions button.is-label {
    width: auto;
    padding: 0 0.65rem;
    font-size: 0.78rem;
    font-weight: 650;
}

.conn-form-actions button {
    border: 1px solid rgba(5, 21, 104, 0.16);
    background: #fff;
    color: var(--sv-primary);
    border-radius: 8px;
    padding: 0.35rem 0.65rem;
    font-size: 0.8rem;
    font-weight: 650;
    cursor: pointer;
}

.conn-item.is-ok {
    background: #e7f8f5;
    border-color: rgba(18, 148, 128, 0.22);
    border-left-color: #149480;
}

.conn-item.is-error {
    background: #fdf1f1;
    border-color: rgba(180, 35, 24, 0.16);
    border-left-color: #d2645c;
}

.conn-actions button:hover,
.conn-form-actions button:hover {
    background: rgba(5, 21, 104, 0.06);
    border-color: rgba(5, 21, 104, 0.28);
    color: var(--sv-primary);
    box-shadow: 0 8px 16px rgba(5, 21, 104, 0.18);
}

.conn-actions button:active {
    transform: translateY(1px);
    box-shadow: 0 3px 8px rgba(5, 21, 104, 0.16);
}

.conn-actions button:disabled {
    opacity: 0.45;
    box-shadow: none;
    transform: none;
    cursor: default;
}

.conn-actions button.is-use:hover {
    background: rgba(5, 21, 104, 0.1);
}

.conn-actions button.is-danger {
    color: #b42318;
    border-color: rgba(180, 35, 24, 0.28);
}

.conn-actions button.is-danger:hover {
    background: rgba(180, 35, 24, 0.08);
    border-color: rgba(180, 35, 24, 0.4);
    color: #b42318;
}

.conn-empty {
    padding: 2.4rem 1.2rem;
    text-align: center;
    color: #6b7585;
}

.conn-empty h2 {
    margin: 0 0 0.4rem;
    color: var(--sv-primary);
    font-size: 1.15rem;
}

.conn-form {
    padding: 1rem 1.1rem 1.15rem;
}

.conn-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-top: 1rem;
}

.solid-toasts {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    width: min(360px, calc(100vw - 2rem));
    pointer-events: none;
}

.solid-toast {
    pointer-events: auto;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 0.85rem 0.85rem 1rem;
    border-radius: 12px;
    color: #fff;
    font-size: 0.92rem;
    line-height: 1.4;
    box-shadow: 0 14px 32px rgba(5, 21, 104, 0.24);
}

.solid-toast.is-ok { background: #0e7c68; }
.solid-toast.is-error { background: #9d2c24; }
.solid-toast.is-info { background: rgb(5, 21, 104); }

.solid-toast span {
    flex: 1;
}

.solid-toast button {
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 1.15rem;
    line-height: 1;
    padding: 0;
    cursor: pointer;
}

.sv-main:has(.sync-screen),
.sv-main:has(.equipo-screen),
.sv-main:has(.neu-screen),
.sv-main:has(.chasis-screen) {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.sv-page:has(.sync-screen),
.sv-page:has(.equipo-screen),
.sv-page:has(.neu-screen),
.sv-page:has(.chasis-screen) {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    height: 100%;
    min-height: 0;
    padding-bottom: 1.35rem;
}

.sync-screen,
.equipo-screen,
.neu-screen,
.chasis-screen {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    height: 100%;
    overflow: auto;
    padding: 1.15rem 1.25rem 1.35rem;
    background: #fff;
    border: 1px solid rgba(5, 21, 104, 0.08);
    border-radius: 14px;
    box-shadow:
        0 1px 2px rgba(5, 21, 104, 0.04),
        0 10px 28px rgba(5, 21, 104, 0.06);
}

.neu-screen.is-embedded,
.wizard-screen > .wizard-stage,
.equipo-screen > .equipo-board,
.equipo-screen > .conn-card,
.chasis-screen > .chasis-board,
.neu-screen > .neu-board,
.neu-screen > .conn-card.neu-catalog {
    background: transparent;
    border: 0;
    box-shadow: none;
    border-radius: 0;
}

.neu-screen > .page-head,
.neu-screen > .neu-tabs,
.wizard-screen > .wizard-rail,
.chasis-screen > .page-head {
    flex: 0 0 auto;
}

.canvas-fill,
.wizard-screen > .wizard-stage,
.neu-screen > .neu-board,
.neu-screen > .conn-card.neu-catalog,
.chasis-screen > .chasis-board {
    flex: 1 1 auto;
    min-height: 0;
}

.sync-screen .page-head,
.equipo-screen .page-head {
    flex: 0 0 auto;
    margin-bottom: 0.85rem;
}

.sync-screen .page-lead,
.equipo-screen .page-lead {
    margin-bottom: 0;
}

.equipo-board {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    gap: 0;
    min-height: 0;
    overflow: hidden;
}

.equipo-load {
    flex-shrink: 0;
    border: 0;
    border-radius: 8px;
    padding: 0.55rem 0.95rem;
    background: var(--sv-primary);
    color: var(--sv-white);
    font-size: 0.86rem;
    font-weight: 650;
    cursor: pointer;
}

.equipo-load:hover:not(:disabled) {
    box-shadow: 0 8px 16px rgba(5, 21, 104, 0.18);
}

.equipo-load:disabled {
    opacity: 0.45;
    cursor: default;
}

.equipo-actions {
    display: flex;
    flex-shrink: 0;
    gap: 0.5rem;
}

.equipo-load.is-ghost {
    border: 1px solid rgba(5, 21, 104, 0.22);
    background: #fff;
    color: var(--sv-primary);
}

.sync-view {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.sync-rows {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
}

.sync-row {
    display: grid;
    grid-template-columns: 2.75rem minmax(5.5rem, 8.5rem) minmax(0, 1fr) 8.75rem;
    align-items: center;
    column-gap: 0.75rem;
    padding: 0.72rem 0.9rem;
    border-bottom: 1px solid #eef1f5;
    color: #1c2434;
    font-size: 0.92rem;
}

.sync-head {
    flex: 0 0 auto;
    background: #f7f8fb;
    color: var(--sv-primary);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    border-bottom: 1px solid #e4e7ee;
    border-radius: 14px 14px 0 0;
}

.sync-row.is-loaded {
    color: #8b93a3;
}

.sync-check {
    display: grid;
    place-items: center;
}

.sync-check input {
    width: 1rem;
    height: 1rem;
    accent-color: var(--sv-primary);
}

.sync-code,
.sync-name {
    min-width: 0;
    overflow-wrap: anywhere;
}

.sync-badge {
    justify-self: start;
    max-width: 100%;
    padding: 0.18rem 0.5rem;
    border-radius: 999px;
    background: #eef1f6;
    color: #5c677a;
    font-size: 0.75rem;
    font-style: normal;
    font-weight: 700;
    line-height: 1.3;
    white-space: nowrap;
}

.sync-badge.is-new {
    background: rgba(5, 21, 104, 0.1);
    color: var(--sv-primary);
}

.sync-badge.is-done {
    background: #e7f8f5;
    color: #0e7c68;
}

.sync-badge.is-baja {
    background: #fdf1f1;
    color: #9d2c24;
}

.sync-badge.is-fuera {
    background: #fff1e4;
    color: #9a4d12;
}

.equipo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.8rem;
    align-content: start;
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    overflow: auto;
    padding: 0.85rem;
}

.equipo-tile {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    min-height: 158px;
    padding: 1rem 1rem 0.9rem;
    border: 1px solid #e6ebf2;
    border-radius: 16px;
    background: #f8f9fc;
    color: #1c2434;
    text-align: left;
    cursor: pointer;
    box-shadow: none;
}

.chasis-ref {
    display: grid;
    grid-template-columns: minmax(260px, 380px) minmax(0, 1fr);
    gap: 1.25rem;
    align-items: stretch;
    flex: 1 1 auto;
    min-height: 0;
}

.chasis-picker {
    position: relative;
    align-self: start;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.chasis-picker > span {
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.chasis-picker-value,
.chasis-picker-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.7rem 0.8rem;
    border: 1px solid #d5dce8;
    border-radius: 14px;
    background: #fff;
    color: #1c2434;
    text-align: left;
    cursor: pointer;
}

.chasis-picker-value {
    min-height: 72px;
    box-shadow: 0 1px 2px rgba(5, 21, 104, 0.04);
}

.chasis-picker-value::after {
    content: "";
    width: 0.45rem;
    height: 0.45rem;
    margin-left: auto;
    border-right: 2px solid rgb(5, 21, 104);
    border-bottom: 2px solid rgb(5, 21, 104);
    transform: rotate(45deg) translateY(-2px);
}

.chasis-picker.is-open .chasis-picker-value {
    border-color: rgb(5, 21, 104);
    box-shadow: 0 0 0 3px rgba(5, 21, 104, 0.12);
}

.chasis-picker.is-open .chasis-picker-value::after {
    transform: rotate(225deg) translateY(-2px);
}

.chasis-picker-copy {
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
    min-width: 0;
}

.chasis-picker-copy strong,
.chasis-picker-copy em,
.chasis-ref-view p {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chasis-picker-copy strong {
    font-size: 0.95rem;
}

.chasis-picker-copy em,
.chasis-ref-view p {
    color: #6b7585;
    font-size: 0.78rem;
    font-style: normal;
}

.chasis-picker-menu {
    position: absolute;
    z-index: 4;
    top: calc(100% + 0.35rem);
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    max-height: 320px;
    padding: 0.4rem;
    overflow: auto;
    border: 1px solid #d5dce8;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 16px 40px rgba(5, 21, 104, 0.16);
}

.chasis-picker-option:hover,
.chasis-picker-option.is-selected {
    border-color: rgb(5, 21, 104);
    background: #f4f7ff;
}

.chasis-ref-view {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.65rem;
    min-height: 100%;
    padding: 1rem;
    border-radius: 16px;
    background:
        linear-gradient(180deg, rgba(5, 21, 104, 0.03), rgba(5, 21, 104, 0.01)),
        repeating-linear-gradient(90deg, #f4f6fa, #f4f6fa 18px, #eef1f6 18px, #eef1f6 19px);
}

.chasis-ref-view p {
    margin: 0;
}

.equipo-tile:hover {
    border-color: rgba(5, 21, 104, 0.28);
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(5, 21, 104, 0.12);
}

.equipo-tile.is-baja {
    background: #fbfbfc;
}

.equipo-tile.is-fuera {
    background:
        linear-gradient(180deg, rgba(154, 77, 18, 0.08), transparent 46%),
        #fff;
}

.equipo-tile-range {
    color: #9a4d12;
    font-size: 0.75rem;
    font-weight: 700;
}

.equipo-tile-code {
    color: var(--sv-primary);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.equipo-tile strong {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    font-size: 0.98rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.equipo-tile-meta {
    color: #6b7585;
    font-size: 0.78rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.equipo-tile .sync-badge {
    margin-top: auto;
}

.equipo-modal {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    background: rgba(8, 14, 32, 0.62);
}

.equipo-dialog {
    display: flex;
    flex-direction: column;
    width: min(880px, calc(100vw - 2.5rem));
    max-height: calc(100vh - 3rem);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 24px 60px rgba(5, 21, 104, 0.28);
}

.equipo-dialog-head {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 1.05rem 1.1rem 0.95rem;
    border-bottom: 1px solid #eef1f5;
}

.equipo-dialog-head > div {
    flex: 1 1 auto;
    min-width: 0;
}

.equipo-dialog-head p {
    margin: 0;
    color: var(--sv-primary);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.equipo-dialog-head h2 {
    margin: 0.2rem 0 0;
    color: #1c2434;
    font-size: 1.25rem;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.equipo-close {
    width: 2.1rem;
    height: 2.1rem;
    border: 0;
    border-radius: 999px;
    background: #f3f5f9;
    color: #1c2434;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
}

.equipo-close:hover {
    background: rgba(5, 21, 104, 0.08);
    color: var(--sv-primary);
}

.equipo-dialog-body {
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    min-height: 0;
    overflow: hidden;
}

.equipo-gallery {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    min-width: 0;
    min-height: 0;
    padding: 1rem;
    background: #f7f8fb;
    border-right: 1px solid #eef1f5;
}

.equipo-stage {
    display: grid;
    place-items: center;
    height: 220px;
    overflow: hidden;
    border: 1px solid #e6eaf1;
    border-radius: 16px;
    background: #fff;
}

.equipo-stage img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.equipo-stage p,
.equipo-caption {
    margin: 0;
    color: #6b7585;
    font-size: 0.84rem;
    text-align: center;
}

.equipo-caption {
    min-height: 1.2rem;
    overflow-wrap: anywhere;
}

.equipo-thumbs {
    display: flex;
    gap: 0.45rem;
    overflow-x: auto;
    padding-bottom: 0.15rem;
}

.equipo-thumb {
    flex: 0 0 auto;
    width: 64px;
    height: 64px;
    padding: 0;
    overflow: hidden;
    border: 2px solid transparent;
    border-radius: 12px;
    background: #fff;
    color: var(--sv-primary);
    font-size: 0.72rem;
    font-weight: 700;
    cursor: pointer;
}

.equipo-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.equipo-thumb.is-selected {
    border-color: var(--sv-primary);
}

.equipo-dialog .equipo-detail-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.15rem 1.25rem;
    align-content: start;
    max-height: calc(100vh - 8.5rem);
    overflow: auto;
    padding: 0.85rem 1.1rem 1rem;
}

.equipo-dialog .equipo-group {
    min-width: 0;
    padding: 0.2rem 0;
}

.equipo-dialog .equipo-group dl {
    grid-template-columns: 1fr;
    gap: 0.35rem;
}

.equipo-dialog .equipo-group dl > div,
.equipo-dialog .equipo-group .is-wide {
    display: grid;
    grid-template-columns: 8.4rem minmax(0, 1fr);
    column-gap: 0.65rem;
    align-items: start;
}

.equipo-dialog .equipo-group dd {
    margin: 0;
}

.equipo-split {
    display: grid;
    grid-template-columns: minmax(16rem, 22rem) minmax(0, 1fr);
    gap: 0.75rem;
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
}

.equipo-cards {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    min-width: 0;
    min-height: 0;
    overflow: auto;
    padding-right: 0.15rem;
}

.equipo-pick {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.28rem;
    width: 100%;
    padding: 0.8rem 0.85rem;
    border: 1px solid #e4e7ee;
    border-radius: 12px;
    background: #fff;
    color: #1c2434;
    text-align: left;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(5, 21, 104, 0.04);
}

.equipo-pick:hover,
.equipo-pick.is-selected {
    border-color: rgba(5, 21, 104, 0.45);
    box-shadow: 0 8px 16px rgba(5, 21, 104, 0.12);
}

.equipo-pick.is-baja {
    background: #fbfbfc;
}

.equipo-pick-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.equipo-pick-top strong {
    min-width: 0;
    color: var(--sv-primary);
    font-size: 0.84rem;
    overflow-wrap: anywhere;
}

.equipo-pick-name {
    font-size: 0.92rem;
    font-weight: 650;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.equipo-pick-meta {
    color: #6b7585;
    font-size: 0.78rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.equipo-detail {
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
}

.equipo-detail-head {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.05rem 0.85rem;
    border-bottom: 1px solid #eef1f5;
}

.equipo-detail-head h2 {
    margin: 0;
    color: #1c2434;
    font-size: 1.05rem;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.equipo-detail-head p {
    margin: 0.2rem 0 0;
    color: var(--sv-primary);
    font-size: 0.82rem;
    font-weight: 700;
}

.equipo-detail-head > div {
    flex: 1 1 auto;
    min-width: 0;
}

.equipo-back {
    display: none;
    flex: 0 0 auto;
    border: 1px solid #d5dbe6;
    border-radius: 8px;
    background: #fff;
    color: var(--sv-primary);
    padding: 0.35rem 0.6rem;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
}

.equipo-detail-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    padding: 0.35rem 1.05rem 1.1rem;
}

.equipo-group {
    padding: 0.85rem 0 0.2rem;
}

.equipo-group h3 {
    margin: 0 0 0.55rem;
    color: var(--sv-primary);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.equipo-group dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem 1rem;
    margin: 0;
}

.equipo-group .is-wide {
    grid-column: 1 / -1;
}

.equipo-group dt {
    color: #8b93a3;
    font-size: 0.72rem;
    font-weight: 700;
}

.equipo-group dd {
    margin: 0.12rem 0 0;
    color: #1c2434;
    font-size: 0.9rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.equipo-board .conn-toolbar {
    flex-wrap: wrap;
    min-width: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    border-bottom: 1px solid #e6ebf2;
}

.equipo-board .conn-toolbar input {
    flex: 1 1 14rem;
    width: auto;
    min-width: 0;
    max-width: none;
}

.sync-screen .page-head > div,
.equipo-screen .page-head > div,
.equipo-board {
    min-width: 0;
}

.equipo-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    color: #1c2434;
    font-size: 0.92rem;
}

.equipo-table th {
    position: sticky;
    top: 0;
    z-index: 1;
    padding: 0.75rem 0.85rem;
    background: #f7f8fb;
    color: var(--sv-primary);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-align: left;
    border-bottom: 1px solid #e4e7ee;
}

.equipo-table td {
    padding: 0.7rem 0.85rem;
    border-bottom: 1px solid #eef1f5;
    vertical-align: middle;
    overflow-wrap: anywhere;
}

.equipo-table tr.is-loaded td {
    color: #8b93a3;
}

.equipo-check {
    width: 3rem;
    text-align: center;
}

.equipo-state {
    width: auto;
    white-space: nowrap;
    color: #6b7585;
    font-size: 0.82rem;
}

.equipo-table.wide {
    min-width: 72rem;
}

.equipo-table .form-check-input,
.equipo-check input {
    width: 1rem;
    height: 1rem;
    accent-color: var(--sv-primary);
}

.equipo-gate {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(8, 14, 32, 0.72);
}

.equipo-gate-card {
    width: min(28rem, 100%);
    padding: 1.4rem 1.35rem 1.2rem;
    border: 1px solid #e4e7ee;
    border-radius: 12px;
    background: #fff;
    color: #1c2434;
    box-shadow: 0 18px 40px rgba(5, 21, 104, 0.28);
}

.equipo-gate-card h2 {
    margin: 0 0 0.55rem;
    color: var(--sv-primary);
    font-size: 1.15rem;
}

.equipo-gate-card p {
    margin: 0 0 1.1rem;
    line-height: 1.45;
}

.equipo-gate-card .equipo-load {
    width: 100%;
}

@media (max-width: 900px) {
    .conn-stack {
        grid-template-columns: 1fr 1fr;
    }

    .page-head {
        flex-direction: column;
    }

    .sync-head {
        display: none;
    }

    .sync-row {
        grid-template-columns: 2.5rem minmax(0, 1fr);
        row-gap: 0.15rem;
    }

    .sync-check {
        grid-row: 1 / span 3;
    }

    .sync-code,
    .sync-name,
    .sync-badge {
        grid-column: 2;
    }

    .equipo-split {
        grid-template-columns: minmax(0, 1fr);
    }

    .equipo-dialog {
        width: calc(100vw - 1.2rem);
    }

    .equipo-dialog-body {
        grid-template-columns: minmax(0, 1fr);
        overflow: auto;
    }

    .equipo-dialog .equipo-detail-body {
        grid-template-columns: 1fr;
        overflow: visible;
    }

    .equipo-dialog .equipo-group:nth-child(4),
    .equipo-dialog .equipo-group:nth-child(5) {
        grid-row: auto;
        grid-column: auto;
    }

    .equipo-gallery {
        border-right: 0;
        border-bottom: 1px solid #eef1f5;
    }

    .equipo-stage {
        min-height: 180px;
    }

    .equipo-back {
        display: inline-flex;
    }

    .equipo-cards.is-hidden-narrow,
    .equipo-detail.is-hidden-narrow {
        display: none;
    }

    .equipo-group dl {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .conn-stack {
        grid-template-columns: 1fr;
    }

    .ficha-grid,
    .ficha-section.is-span .ficha-fields,
    .ficha-fields {
        grid-template-columns: 1fr;
    }
}

.ficha-modal {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(8, 14, 32, 0.55);
}

.ficha {
    display: flex;
    flex-direction: column;
    width: min(1080px, 100%);
    max-height: calc(100vh - 1.5rem);
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 18px 48px rgba(5, 21, 104, 0.24);
}

.ficha-head {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e8ecf2;
}

.ficha-head > div {
    flex: 1 1 auto;
    min-width: 0;
}

.ficha-head p {
    margin: 0;
    color: var(--sv-primary);
    font-size: 0.75rem;
    font-weight: 700;
}

.ficha-head h2 {
    margin: 0.15rem 0 0;
    color: #1c2434;
    font-size: 1.12rem;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.ficha-close {
    width: 2rem;
    height: 2rem;
    border: 0;
    border-radius: 999px;
    background: #f3f5f9;
    color: #1c2434;
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
}

.ficha-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 0.65rem;
    min-height: 0;
    overflow: hidden;
    padding: 0.75rem 0.9rem 0.85rem;
    background: #f4f6fa;
}

.ficha-media {
    display: flex;
    flex: 0 1 auto;
    flex-direction: column;
    gap: 0.4rem;
    min-height: 0;
    min-width: 0;
    padding: 0.5rem;
    overflow: hidden;
    border: 1px solid #e3e8f0;
    border-radius: 14px;
    background: #fff;
}

.ficha-photo {
    display: flex;
    flex: 0 1 auto;
    align-items: center;
    justify-content: center;
    min-height: 0;
    overflow: hidden;
    border-radius: 10px;
    background: #eef1f6;
}

.ficha-photo img {
    display: block;
    width: 100%;
    height: auto;
    max-height: max(7rem, calc(100vh - 38rem));
    object-fit: contain;
    object-position: center;
}

.ficha-photo p,
.ficha-caption {
    margin: 0;
    color: #6b7585;
    font-size: 0.78rem;
    line-height: 1.35;
    text-align: left;
}

.ficha-caption {
    padding: 0 0.1rem;
}

.ficha-thumbs {
    display: flex;
    flex: 0 0 auto;
    gap: 0.4rem;
    overflow-x: auto;
}

.ficha-thumb {
    flex: 0 0 auto;
    width: 52px;
    height: 52px;
    padding: 0;
    overflow: hidden;
    border: 2px solid transparent;
    border-radius: 10px;
    background: #f3f5f9;
    cursor: pointer;
}

.ficha-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ficha-thumb.is-selected {
    border-color: var(--sv-primary);
}

.ficha-grid {
    display: grid;
    flex: 0 0 auto;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.65rem;
    align-items: start;
}

.ficha-section {
    min-width: 0;
    padding: 0.75rem;
    border: 1px solid #e3e8f0;
    border-radius: 14px;
    background: #fff;
}

.ficha-section.is-span {
    grid-column: 1 / -1;
}

.ficha-section.is-fuera {
    border-color: #f0d3b8;
    background: #fff8f1;
}

.ficha-section h3 {
    margin: 0 0 0.55rem;
    color: var(--sv-primary);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.ficha-section.is-fuera h3 {
    color: #9a4d12;
}

.ficha-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem;
}

.ficha-section.is-span .ficha-fields,
.ficha-section.is-line .ficha-fields {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ficha-section.is-fuera .ficha-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ficha-fields .is-wide {
    grid-column: 1 / -1;
}

.ficha-fields > div {
    min-width: 0;
    padding: 0.5rem 0.6rem;
    border: 1px solid #e7ecf3;
    border-radius: 10px;
    background: #f7f8fb;
}

.ficha-section.is-fuera .ficha-fields > div {
    border-color: #f3dfcc;
}

.ficha-fields span {
    display: block;
    color: #8b93a3;
    font-size: 0.7rem;
    font-weight: 700;
}

.ficha-fields strong {
    display: block;
    margin-top: 0.12rem;
    color: #1c2434;
    font-size: 0.9rem;
    font-weight: 650;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.ficha-head .sync-badge {
    flex: 0 0 auto;
}

@media (max-width: 860px) {
    .ficha-grid {
        grid-template-columns: 1fr;
    }

    .ficha-section.is-line .ficha-fields {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

.sv-main:has(.equipo-detalle) > .sv-page {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.equipo-detalle {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    gap: 0.9rem;
    min-height: 0;
}

.equipo-detalle > .equipo-detalle-card:last-child {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
}

.equipo-detalle-pane {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
}

.equipo-detalle-head,
.equipo-detalle-card {
    padding: 1rem;
    border: 1px solid rgba(5, 21, 104, 0.08);
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(5, 21, 104, 0.04);
}

.equipo-detalle-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.equipo-detalle-heading {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-width: 0;
}

.equipo-detalle-heading .sv-back {
    margin-bottom: 0.35rem;
}

.equipo-detalle-head h1,
.equipo-detalle-card h2,
.equipo-detalle-card h3,
.equipo-detalle-title strong {
    margin: 0;
    color: #1c2434;
}

.equipo-detalle-head h1,
.equipo-detalle-card > h2 {
    font-size: 1.15rem;
}

.equipo-detalle-title {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    margin: 0.85rem 0;
}

.equipo-detalle-title p,
.equipo-detalle-note p,
.equipo-detalle-plan p {
    margin: 0;
    color: #5c677a;
}

.equipo-detalle-badges,
.equipo-detalle-tabs,
.equipo-detalle-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    align-items: end;
}

.equipo-detalle-columns,
.equipo-detalle-pair,
.equipo-detalle-gallery {
    display: grid;
    gap: 0.75rem;
}

.equipo-detalle-columns {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.equipo-detalle-pair {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.equipo-detalle-columns article,
.equipo-detalle-field,
.equipo-detalle-note,
.equipo-detalle-plan {
    padding: 0.85rem;
    border: 1px solid #e6ebf2;
    border-radius: 12px;
    background: #f7f8fb;
}

.equipo-detalle-columns h3,
.equipo-detalle-pane h3 {
    margin: 0 0 0.65rem;
    color: rgb(5, 21, 104);
    font-size: 0.95rem;
}

.equipo-detalle-row {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.35rem 0;
    border-bottom: 1px dashed #e3e8f0;
}

.equipo-detalle-row span,
.equipo-detalle-field span,
.equipo-detalle-filters label {
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.equipo-detalle-row strong,
.equipo-detalle-field strong {
    color: #1c2434;
    font-size: 0.92rem;
    text-align: right;
}

.equipo-detalle-field {
    margin-bottom: 0.65rem;
}

.equipo-detalle-field span,
.equipo-detalle-field strong {
    display: block;
}

.equipo-detalle-field strong {
    margin-top: 0.2rem;
    text-align: left;
}

.equipo-detalle-tabs {
    margin-bottom: 0.9rem;
    overflow-x: auto;
}

.equipo-detalle-tabs button,
.equipo-detalle-head .btn {
    border: 1px solid #d5dce8;
    border-radius: 999px;
    background: #fff;
    color: #1c2434;
    padding: 0.4rem 0.75rem;
    cursor: pointer;
}

.equipo-detalle-tabs button.is-active {
    border-color: rgb(5, 21, 104);
    background: rgb(5, 21, 104);
    color: #fff;
}

.equipo-detalle-gallery {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
}

.equipo-detalle-shot {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-height: 180px;
    padding: 0.7rem;
    border: 1px solid #e6ebf2;
    border-radius: 12px;
    background: #fff;
    color: #1c2434;
    text-align: left;
    cursor: pointer;
}

.equipo-detalle-shot img {
    width: 100%;
    height: 140px;
    object-fit: contain;
    background: #eef1f6;
    border-radius: 8px;
}

.equipo-detalle-empty {
    margin: 1.5rem 0;
    color: #6b7585;
    text-align: center;
}

.adjunto-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 0.85rem;
}

.adjunto-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #e6ebf2;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(5, 21, 104, 0.04);
}

.adjunto-plate {
    display: grid;
    place-items: center;
    height: 132px;
    background: #eef2f8;
    color: rgb(5, 21, 104);
    text-decoration: none;
}

.adjunto-plate strong {
    font-size: 1.35rem;
    letter-spacing: 0.04em;
}

.adjunto-plate.is-pdf { background: #fdecec; color: #b42318; }
.adjunto-plate.is-doc { background: #e8f1ff; color: #1849a9; }
.adjunto-plate.is-sheet { background: #e7f6ee; color: #067647; }
.adjunto-plate.is-image { background: #f3e8ff; color: #6927da; }
.adjunto-plate.is-zip { background: #fff6e8; color: #b54708; }

.adjunto-body {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 0.8rem;
}

.adjunto-body h3,
.adjunto-body p {
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.adjunto-body h3 {
    color: #1c2434;
    font-size: 0.92rem;
}

.adjunto-body p,
.adjunto-meta {
    color: #6b7585;
    font-size: 0.78rem;
}

.adjunto-meta {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
}

.adjunto-open {
    display: block;
    margin-top: 0.35rem;
    padding: 0.4rem 0.6rem;
    border: 1px solid rgb(5, 21, 104);
    border-radius: 999px;
    color: rgb(5, 21, 104);
    font-size: 0.82rem;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
}

.adjunto-open:hover {
    background: rgb(5, 21, 104);
    color: #fff;
}

.plan-banner {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.4rem 1rem;
    margin-bottom: 0.75rem;
    padding: 0.75rem 0.9rem;
    border-radius: 12px;
    background: #f1f5ff;
}

.plan-banner strong {
    color: #1c2434;
}

.plan-banner span {
    color: #5c677a;
    font-size: 0.82rem;
}

.plan-folds {
    overflow: hidden;
    border: 1px solid #e6ebf2;
    border-radius: 12px;
    background: #fff;
}

.plan-fold {
    border-bottom: 1px solid #e6ebf2;
}

.plan-fold:last-child {
    border-bottom: 0;
}

.plan-fold summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.7rem 0.9rem;
    background: #f7f8fb;
    color: #3d4654;
    font-weight: 700;
    cursor: pointer;
}

.plan-fold summary em {
    color: #6b7585;
    font-size: 0.75rem;
    font-style: normal;
    font-weight: 650;
}

.plan-fold ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.plan-fold li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.7rem 0.9rem;
    border-top: 1px solid #eef1f6;
}

.plan-fold li strong,
.plan-fold li small {
    display: block;
}

.plan-fold li strong {
    color: #1c2434;
    font-size: 0.9rem;
}

.plan-fold li small {
    margin-top: 0.15rem;
    color: #6b7585;
}

.plan-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.35rem;
}

.plan-badges span,
.orden-badges span,
.orden-counts span,
.orden-section > header span {
    padding: 0.2rem 0.5rem;
    border: 1px solid #e1e6ef;
    border-radius: 999px;
    background: #f7f8fb;
    color: #3d4654;
    font-size: 0.72rem;
    font-weight: 700;
}

.plan-badges .is-stop {
    border-color: #f3c7c7;
    background: #fdecec;
    color: #b42318;
}

.plan-empty {
    margin: 0;
    padding: 0.7rem;
    color: #6b7585;
    font-size: 0.82rem;
    font-style: italic;
    text-align: center;
    background: #f7f8fb;
}

.historial-filters {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    align-items: end;
}

.historial-filters label {
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.historial-filters input,
.historial-filters select,
.historial-filters .btn {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
}

.historial-filters input,
.historial-filters select {
    padding: 0.45rem 0.55rem;
    border: 1px solid #d5dce8;
    border-radius: 8px;
    background: #fff;
    color: #1c2434;
}

.historial-count {
    margin: 0.85rem 0 0;
    color: #6b7585;
    font-size: 0.8rem;
    font-weight: 700;
}

.historial-table-wrap,
.orden-section {
    overflow: auto;
}

.historial-table,
.orden-section table,
.orden-plan table {
    width: 100%;
    border-collapse: collapse;
}

.historial-table {
    margin-top: 0.45rem;
}

.historial-table th,
.orden-section th,
.orden-plan th {
    padding: 0.55rem 0.65rem;
    background: #f7f8fb;
    color: #6b7585;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-align: left;
    text-transform: uppercase;
}

.historial-table td,
.orden-section td,
.orden-plan td {
    padding: 0.65rem;
    border-top: 1px solid #eef1f6;
    color: #1c2434;
    vertical-align: top;
}

.historial-table tbody tr {
    cursor: pointer;
}

.historial-table tbody tr:hover {
    background: rgba(5, 21, 104, 0.04);
}

.historial-table button {
    padding: 0;
    border: 0;
    background: transparent;
    color: rgb(5, 21, 104);
    font-weight: 700;
    cursor: pointer;
}

.orden-dialog {
    width: min(920px, 100%);
    background: #f7f8fb;
}

.orden-body {
    flex: 1 1 auto;
    min-height: 0;
}

.orden-head,
.orden-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.9rem 1rem;
    background: #fff;
}

.orden-head {
    background: linear-gradient(135deg, #0b1125 0%, #162135 100%);
    color: #fff;
}

.orden-head p,
.orden-head h2 {
    margin: 0;
}

.orden-head p {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.75rem;
    font-weight: 700;
}

.orden-head h2 {
    margin-top: 0.15rem;
    font-size: 1.15rem;
}

.orden-head .ficha-close {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
}

.orden-body {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1rem;
    overflow: auto;
}

.orden-badges,
.orden-counts {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.orden-badges .is-status,
.orden-counts .is-rut,
.orden-section > header.is-rut {
    border-color: rgba(5, 21, 104, 0.18);
    background: #e8eefc;
    color: rgb(5, 21, 104);
}

.orden-counts .is-norut,
.orden-section > header.is-norut {
    border-color: #f3dfcc;
    background: #fff6e8;
    color: #b54708;
}

.orden-note {
    margin: 0;
    padding: 0.75rem 0.85rem;
    border: 1px solid #e6ebf2;
    border-radius: 12px;
    background: #fff;
    color: #3d4654;
}

.orden-section {
    overflow: hidden;
    border: 1px solid #e6ebf2;
    border-radius: 12px;
    background: #fff;
}

.orden-section > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.7rem 0.9rem;
    font-size: 0.92rem;
}

.orden-section > header span {
    background: rgb(5, 21, 104);
    color: #fff;
    border-color: transparent;
}

.orden-section > header.is-norut span {
    background: #b54708;
}

.orden-section-body {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 0.75rem;
}

.orden-plan {
    overflow: hidden;
    border: 1px solid #e6ebf2;
    border-radius: 10px;
}

.orden-plan h3 {
    margin: 0;
    padding: 0.55rem 0.75rem;
    background: #f1f5ff;
    color: #0b1125;
    font-size: 0.84rem;
}

.orden-estado {
    font-weight: 700;
}

.orden-estado.is-done { color: #067647; }
.orden-estado.is-late { color: #b42318; }
.orden-estado.is-pending { color: #5c677a; }

@media (max-width: 860px) {
    .historial-filters,
    .plan-fold li {
        grid-template-columns: 1fr;
        display: grid;
    }

    .plan-badges {
        justify-content: flex-start;
    }
}

.equipo-detalle-filters input,
.equipo-detalle-filters select {
    display: block;
    margin-top: 0.25rem;
    padding: 0.4rem 0.5rem;
    border: 1px solid #d5dce8;
    border-radius: 8px;
}

.equipo-detalle-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 0.8rem;
}

.equipo-detalle-table th,
.equipo-detalle-table td {
    padding: 0.45rem 0.35rem;
    border-bottom: 1px solid #e6ebf2;
    text-align: left;
    vertical-align: top;
}

.equipo-detalle-viewer,
.equipo-detalle-order {
    width: min(920px, 100%);
    max-height: calc(100vh - 2rem);
    overflow: auto;
}

.equipo-detalle-viewer-body {
    display: grid;
    place-items: center;
    min-height: 240px;
    padding: 1rem;
    background: #111;
}

.equipo-detalle-viewer-body img {
    max-width: 100%;
    max-height: calc(100vh - 10rem);
    object-fit: contain;
}

@media (max-width: 860px) {
    .equipo-detalle-columns,
    .equipo-detalle-pair {
        grid-template-columns: 1fr;
    }
}

.chasis-layout {
    display: grid;
    grid-template-columns: minmax(240px, 320px) minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.chasis-list,
.chasis-editor {
    padding: 0.85rem;
}

.chasis-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    max-height: calc(100vh - 12rem);
    overflow: auto;
}

.chasis-card {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 0.65rem;
    align-items: center;
    width: 100%;
    padding: 0.55rem;
    border: 1px solid #e6ebf2;
    border-radius: 12px;
    background: #fff;
    color: #1c2434;
    text-align: left;
    cursor: pointer;
}

.chasis-card.is-selected {
    border-color: rgb(5, 21, 104);
    box-shadow: inset 0 0 0 1px rgb(5, 21, 104);
}

.chasis-card.is-off {
    opacity: 0.62;
}

.chasis-card strong,
.chasis-card em {
    display: block;
}

.chasis-card strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chasis-card em {
    margin-top: 0.15rem;
    color: #6b7585;
    font-size: 0.78rem;
    font-style: normal;
}

.chasis-card .sync-badge {
    display: inline-flex;
    margin-top: 0.35rem;
}

.chasis-editor {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.chasis-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.fuel-panel {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.75rem;
    padding: 1rem 1.15rem;
    border: 1px solid #e6ebf2;
    border-radius: 16px;
    background: #fff;
}

.fuel-panel .equipo-load {
    margin-left: auto;
}

.fuel-switch {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.2rem 0.15rem;
    border: 0;
    background: transparent;
    color: #1c2434;
    font: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
}

.fuel-switch i {
    position: relative;
    width: 2.45rem;
    height: 1.4rem;
    border-radius: 999px;
    background: #d5dce8;
}

.fuel-switch i::after {
    content: "";
    position: absolute;
    top: 0.16rem;
    left: 0.16rem;
    width: 1.08rem;
    height: 1.08rem;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(5, 21, 104, 0.2);
    transition: transform 0.16s ease;
}

.fuel-switch.is-on {
    border-color: rgb(5, 21, 104);
    color: rgb(5, 21, 104);
}

.fuel-switch.is-on i {
    background: rgb(5, 21, 104);
}

.fuel-switch.is-on i::after {
    transform: translateX(1.05rem);
}

.fuel-switch:disabled {
    opacity: 0.55;
    cursor: default;
}

.fuel-choices,
.fuel-grades {
    display: flex;
    gap: 0.65rem;
}

.fuel-choice,
.fuel-grade {
    padding: 0.45rem 0.9rem;
    border: 1px solid #e4e9f2;
    border-radius: 999px;
    background: #fff;
    color: #1c2434;
    font: inherit;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
}

.fuel-choice.is-on,
.fuel-grade.is-on {
    border-color: rgb(5, 21, 104);
    background: rgb(5, 21, 104);
    color: #fff;
}

.fuel-read {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    margin: 0;
    color: #1c2434;
    font-size: 0.9rem;
    font-weight: 700;
}

.fuel-read input {
    width: 7rem;
    padding: 0.45rem 0.7rem;
    border: 1px solid #d5dce8;
    border-radius: 10px;
    background: #fff;
    color: #1c2434;
    font: inherit;
    font-size: 0.95rem;
    font-weight: 700;
}

.fuel-read input:focus {
    outline: 3px solid rgba(5, 21, 104, 0.12);
    border-color: rgb(5, 21, 104);
}

.chasis-form label {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.chasis-input {
    width: 100%;
    padding: 0.5rem 0.6rem;
    border: 1px solid #d5dce8;
    border-radius: 8px;
    background: #fff;
    color: #1c2434;
    font: inherit;
    font-size: 0.92rem;
    font-weight: 550;
}

.chasis-check {
    flex: 0 0 auto !important;
    flex-direction: row !important;
    align-items: center;
    min-height: 2.4rem;
    color: #1c2434 !important;
    font-size: 0.9rem !important;
}

.chasis-axle-actions,
.chasis-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.chasis-actions {
    padding-top: 0.35rem;
    border-top: 1px solid #e6ebf2;
}

.chasis-stage {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.85rem;
    padding: 1rem 1rem 1.35rem;
    border-radius: 16px;
    background:
        linear-gradient(180deg, rgba(5, 21, 104, 0.03), rgba(5, 21, 104, 0.01)),
        repeating-linear-gradient(90deg, #f4f6fa, #f4f6fa 18px, #eef1f6 18px, #eef1f6 19px);
}

.chasis-hint,
.chasis-empty {
    margin: 0;
    color: #6b7585;
    font-size: 0.86rem;
}

.equipo-load.is-danger {
    background: #b42318;
}

.chasis-rig {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: min(100%, 560px);
    gap: 0.35rem;
    padding: 0.35rem 0 0.15rem;
}

.chasis-rig.is-mini {
    width: auto;
    padding: 0.35rem 0.2rem;
    border: 0;
    background: transparent;
}

.chasis-end {
    color: #6b7585;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.chasis-axles {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 1.15rem;
    width: min(100%, 520px);
    padding: 1.35rem 0 1.1rem;
}

.chasis-rig.is-mini .chasis-axles {
    gap: 0.28rem;
    width: 84px;
    padding: 0.15rem 0;
}

.chasis-axles::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 108px;
    transform: translateX(-50%);
    border: 2px solid #c5cedd;
    border-radius: 36px 36px 18px 18px;
    background: linear-gradient(180deg, #e7edf6 0%, #f7f8fb 28%, #f7f8fb 100%);
    box-shadow: inset 0 10px 0 #d5deec;
}

.chasis-rig.is-mini .chasis-axles::before {
    top: 0.2rem;
    bottom: 0.2rem;
    width: 8px;
    border: 0;
    border-radius: 4px;
    background: #b7c2d4;
    box-shadow: none;
}

.chasis-axle {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 34px 1fr;
    align-items: center;
}

.chasis-rig.is-mini .chasis-axle {
    grid-template-columns: 1fr 10px 1fr;
}

.chasis-hub {
    display: grid;
    place-items: center;
    height: 28px;
    border-radius: 999px;
    background: #3d4654;
    color: #fff;
    font-size: 0.78rem;
    font-weight: 700;
    box-shadow: 0 0 0 6px #c5cedd;
}

.chasis-rig.is-mini .chasis-hub {
    height: 6px;
    background: #8b97ab;
    box-shadow: none;
}

.chasis-side {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    min-height: 58px;
    padding: 0.2rem 0.35rem;
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: #5c677a;
    cursor: pointer;
}

.chasis-side.is-left {
    flex-direction: row-reverse;
    justify-content: flex-start;
}

.chasis-side.is-right {
    justify-content: flex-start;
}

.chasis-side:hover {
    background: rgba(5, 21, 104, 0.05);
}

.chasis-side small {
    padding: 0.18rem 0.45rem;
    border: 1px solid #e1e6ef;
    border-radius: 999px;
    background: #fff;
    font-size: 0.72rem;
    font-weight: 700;
}

.chasis-side.is-dual small {
    border-color: #c9d4ee;
    background: #e8eefc;
    color: rgb(5, 21, 104);
}

.chasis-side:hover .chasis-tires i {
    background: rgb(5, 21, 104);
}

.chasis-tires {
    display: flex;
    gap: 3px;
}

.chasis-tires i {
    display: block;
    width: 22px;
    height: 48px;
    border-radius: 6px;
    background: #1c2434;
    box-shadow: inset 0 0 0 2px #4b5568, inset 4px 0 0 rgba(255, 255, 255, 0.18);
}

.chasis-tires.is-dual {
    gap: 4px;
}

.chasis-tires.is-dual i {
    width: 16px;
}

.chasis-rig.is-mini .chasis-side {
    min-height: 0;
    padding: 0;
    cursor: default;
}

.chasis-rig.is-mini .chasis-tires {
    gap: 1px;
}

.chasis-rig.is-mini .chasis-tires i {
    width: 6px;
    height: 12px;
    border-radius: 2px;
    box-shadow: none;
}

.chasis-rig.is-mini .chasis-tires.is-dual i {
    width: 4px;
}

@media (max-width: 980px) {
    .chasis-layout,
    .chasis-editor,
    .chasis-ref {
        grid-template-columns: 1fr;
    }

    .chasis-list {
        max-height: none;
    }
}

.sv-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.75rem;
    align-content: start;
}

.sv-item-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
    min-height: 7.25rem;
    padding: 0.9rem 1rem;
    border: 1px solid #e6ebf2;
    border-radius: 14px;
    background: #f8f9fc;
    box-shadow: none;
    color: #1c2434;
    text-align: left;
    cursor: pointer;
}

.sv-item-card strong {
    font-size: 1rem;
}

.sv-item-card em {
    color: #6b7585;
    font-style: normal;
    font-size: 0.82rem;
}

.sv-item-card.is-off {
    opacity: 0.62;
}

.sv-item-card.is-on {
    border-color: rgb(5, 21, 104);
    box-shadow: 0 0 0 2px rgba(5, 21, 104, 0.16);
}

.wizard-rail {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 0 0 1.1rem;
}

.wizard-rail button {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    border: 0;
    background: transparent;
    color: #8b95a5;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
}

.wizard-rail button:disabled {
    cursor: default;
}

.wizard-rail button i {
    display: grid;
    place-items: center;
    width: 2.15rem;
    height: 2.15rem;
    border: 2px solid #d5dce8;
    border-radius: 999px;
    background: #fff;
    font-style: normal;
    z-index: 1;
}

.wizard-rail button::before {
    content: "";
    position: absolute;
    top: 1.05rem;
    right: 50%;
    width: 100%;
    height: 2px;
    background: #d5dce8;
}

.wizard-rail button:first-child::before {
    display: none;
}

.wizard-rail button.is-on,
.wizard-rail button.is-done {
    color: rgb(5, 21, 104);
}

.wizard-rail button.is-on i,
.wizard-rail button.is-done i,
.wizard-rail button.is-on::before,
.wizard-rail button.is-done::before {
    border-color: rgb(5, 21, 104);
    background: rgb(5, 21, 104);
    color: #fff;
}

.wizard-stage {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    align-content: start;
    column-gap: 1.25rem;
    row-gap: 0.85rem;
    overflow: visible;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.wizard-stage > * {
    grid-column: 1;
    min-width: 0;
}

.wizard-intro p,
.wizard-intro h2 {
    margin: 0;
}

.wizard-intro p:first-child {
    color: rgb(5, 21, 104);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.wizard-intro h2 {
    margin-top: 0.2rem;
    color: #1c2434;
    font-size: 1.45rem;
}

.wizard-intro p:last-child {
    max-width: 42rem;
    margin-top: 0.35rem;
    color: #5c677a;
}

.wizard-group h3,
.wizard-form h3 {
    margin: 0.2rem 0 0;
    color: #1c2434;
    font-size: 0.78rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.wizard-ops,
.wizard-tires {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.75rem;
}

.wizard-op,
.wizard-tire {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    min-height: 8.5rem;
    padding: 0.95rem 1rem;
    border: 1px solid #e4e9f2;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(5, 21, 104, 0.06);
    color: #1c2434;
    text-align: left;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.wizard-op:hover,
.wizard-tire:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(5, 21, 104, 0.12);
}

.wizard-op.is-on,
.wizard-tire.is-on {
    border-color: rgb(5, 21, 104);
    box-shadow: 0 0 0 3px rgba(5, 21, 104, 0.14);
}

.wizard-op-mark {
    display: grid;
    place-items: center;
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 10px;
    background: #eef1f8;
    color: rgb(5, 21, 104);
    font-size: 0.75rem;
    font-weight: 800;
}

.wizard-op.is-in .wizard-op-mark { background: #e7eefc; }
.wizard-op.is-out .wizard-op-mark { background: #fff1df; color: #8a4b08; }
.wizard-op.is-back .wizard-op-mark { background: #e5f6ee; color: #0d6b45; }
.wizard-op.is-send .wizard-op-mark { background: #ece8ff; color: #43338f; }
.wizard-op.is-return .wizard-op-mark { background: #e5f4f6; color: #0c6670; }
.wizard-op.is-scrap .wizard-op-mark { background: #fdeceb; color: #9d2c2c; }

.wizard-op strong,
.wizard-tire strong {
    font-size: 1.02rem;
}

.wizard-op em,
.wizard-tire em,
.wizard-tire span {
    color: #5c677a;
    font-style: normal;
    font-size: 0.84rem;
}

.wizard-split {
    display: grid;
    grid-template-columns: minmax(230px, 300px) minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.wizard-preview {
    position: sticky;
    top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-height: 16rem;
    padding: 1.15rem;
    border-radius: 18px;
    background: linear-gradient(165deg, #071247 0%, #24357f 70%, #3d4f9a 100%);
    color: #f4f6fb;
    box-shadow: 0 18px 36px rgba(7, 18, 71, 0.28);
}

.wizard-preview p,
.wizard-preview span {
    margin: 0;
    color: rgba(244, 246, 251, 0.78);
    font-size: 0.84rem;
}

.wizard-preview strong {
    font-size: 1.55rem;
    line-height: 1.15;
}

.wizard-preview b {
    margin-top: auto;
    font-size: 1.35rem;
}

.wizard-preview.is-scrap {
    background: linear-gradient(165deg, #4a1d1d 0%, #8a3030 100%);
}

.wizard-form,
.wizard-receipt {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.wizard-form label,
.wizard-stage label {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.wizard-money input {
    font-size: 1.35rem;
    font-weight: 700;
}

.wizard-note {
    margin: 0;
    padding: 0.7rem 0.8rem;
    border-radius: 12px;
    background: #f4f6fb;
    color: #3d4a60;
    font-size: 0.86rem;
}

.wizard-note.is-alert {
    background: #fdeceb;
    color: #7a2424;
}

.wizard-search {
    max-width: 28rem;
}

.wizard-pick {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.85rem;
}

.wizard-pick .wizard-search {
    flex: 1 1 16rem;
    margin: 0;
}

.wizard-pick p {
    margin: 0;
    color: #1c2434;
    font-weight: 700;
}

.wizard-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.wizard-chip {
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    background: #eef1f8;
    color: #1c2434;
    font-size: 0.84rem;
    font-weight: 700;
}

.wizard-lines {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.wizard-line {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) repeat(auto-fit, minmax(8.5rem, 0.7fr));
    gap: 0.7rem;
    align-items: end;
    padding: 0.75rem 0.85rem;
    border: 1px solid #e4e9f2;
    border-radius: 14px;
    background: #fff;
}

.wizard-line strong,
.wizard-line span {
    display: block;
}

.wizard-line span {
    color: #5c677a;
    font-size: 0.84rem;
}

.wizard-line label {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin: 0;
    color: #5c677a;
    font-size: 0.78rem;
}

.wizard-empty {
    padding: 1.4rem;
    border: 1px dashed #c9d2e2;
    border-radius: 16px;
    background: #f8f9fc;
}

.wizard-empty strong,
.wizard-empty p {
    margin: 0;
}

.wizard-empty p {
    margin-top: 0.3rem;
    color: #5c677a;
}

.wizard-ticket {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    background: #f4f6fb;
}

.wizard-ticket p,
.wizard-ticket span {
    margin: 0;
    color: #5c677a;
    font-size: 0.84rem;
}

.wizard-ticket strong {
    color: #1c2434;
    font-size: 1.15rem;
}

.wizard-receipt {
    display: grid;
    grid-template-columns: 1fr;
    margin: 0;
}

.wizard-receipt div {
    display: grid;
    grid-template-columns: 8rem minmax(0, 1fr);
    gap: 0.5rem;
    padding: 0.55rem 0;
    border-bottom: 1px solid #e8ecf2;
}

.wizard-receipt dt {
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.wizard-receipt dd {
    margin: 0;
    color: #1c2434;
}

.wizard-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 0.25rem;
    padding-top: 0.9rem;
    border-top: 1px solid #e8ecf2;
}

.wizard-stage > .wizard-bar {
    grid-column: 2;
    grid-row: 1;
    align-self: start;
    position: sticky;
    top: 0;
    z-index: 2;
    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-start;
    width: auto;
    margin: 0;
    padding: 0.15rem 0 0;
    border-top: 0;
    background: #fff;
}

.wizard-stage > .wizard-bar p {
    text-align: right;
}

.wizard-bar p {
    margin: 0;
    color: #5c677a;
    font-size: 0.86rem;
}

.wizard-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
}

@media (max-width: 860px) {
    .wizard-split {
        grid-template-columns: 1fr;
    }

    .wizard-preview {
        position: static;
        min-height: 0;
    }

    .wizard-stage {
        display: flex;
        flex-direction: column;
    }

    .wizard-stage > .wizard-bar {
        position: static;
        align-self: stretch;
        align-items: flex-end;
        order: -1;
        width: 100%;
    }

    .wizard-bar {
        flex-direction: column;
        align-items: stretch;
    }
}

.neu-screen.is-embedded {
    margin: 0;
    height: auto;
    flex: 1 1 auto;
    min-height: 0;
    padding: 0;
    overflow: visible;
    background: transparent;
    border: 0;
    box-shadow: none;
}

.neu-screen {
    min-width: 0;
}

.neu-board {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    overflow: auto;
}

.neu-board > .conn-toolbar {
    box-shadow: none;
}

.neu-catalog {
    overflow: auto;
}

.chasis-screen > .chasis-board {
    align-content: start;
    overflow: auto;
}

.chasis-screen > .chasis-board > .conn-card,
.equipo-board > .conn-card {
    box-shadow: none;
}

.neu-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: -0.35rem 0 1rem;
}

.neu-tab,
.neu-chip {
    border: 1px solid #d5dce8;
    border-radius: 999px;
    background: #fff;
    color: #5c677a;
    font: inherit;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
}

.neu-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.85rem;
}

.neu-tab span {
    opacity: 0.75;
}

.neu-tab.is-on,
.neu-chip.is-on {
    border-color: rgb(5, 21, 104);
    background: rgb(5, 21, 104);
    color: #fff;
}

.neu-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 400px);
    gap: 1rem;
    align-items: start;
}

.neu-layout.is-single {
    grid-template-columns: minmax(0, 1fr);
}

.neu-toolbar {
    flex-wrap: wrap;
    margin-bottom: 0.85rem;
}

.neu-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.neu-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.28rem 0.7rem;
}

.neu-chip span {
    opacity: 0.75;
}

.neu-table-wrap {
    overflow: auto;
    max-height: calc(100vh - 16rem);
}

.neu-table tbody tr {
    cursor: pointer;
}

.neu-table tbody tr:hover td,
.neu-table tr.is-selected td {
    background: rgba(5, 21, 104, 0.05);
}

.neu-piece strong,
.neu-sub {
    display: block;
}

.neu-sub {
    margin-top: 0.12rem;
    color: #6b7585;
    font-size: 0.75rem;
    font-style: normal;
}

.neu-date.is-expired,
.neu-date.is-expired .neu-sub {
    color: #9d2c24;
}

.neu-date.is-soon,
.neu-date.is-soon .neu-sub {
    color: #9a4d12;
}

.neu-panel {
    position: sticky;
    top: 0.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    max-height: calc(100vh - 7.5rem);
    padding: 1rem;
    overflow: auto;
}

.neu-panel h2,
.neu-catalog h2 {
    margin: 0;
    color: rgb(5, 21, 104);
    font-size: 1.2rem;
}

.neu-panel h3 {
    margin: 0.4rem 0 0;
    color: #1c2434;
    font-size: 0.95rem;
}

.neu-panel label,
.neu-catalog label {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.neu-kicker,
.neu-help,
.neu-piece-title,
.neu-notes {
    margin: 0;
}

.neu-kicker {
    color: #6b7585;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.neu-help,
.neu-piece-title,
.neu-notes {
    color: #5c677a;
    font-size: 0.86rem;
}

.neu-notes {
    padding: 0.65rem 0.75rem;
    border-radius: 10px;
    background: #f7f8fb;
}

.neu-notes-input {
    min-height: 4.5rem;
    resize: vertical;
}

.neu-close {
    align-self: flex-start;
}

.neu-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
}

.neu-facts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem 0.8rem;
    margin: 0;
}

.neu-facts div {
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
}

.neu-facts dt {
    color: #6b7585;
    font-size: 0.72rem;
    font-weight: 700;
}

.neu-facts dd {
    margin: 0;
    color: #1c2434;
    font-size: 0.9rem;
}

.neu-history {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.neu-history li {
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid #eef1f5;
}

.neu-history strong {
    color: #1c2434;
}

.neu-history em,
.neu-history span {
    color: #6b7585;
    font-size: 0.8rem;
    font-style: normal;
}

.neu-catalogs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    align-items: start;
}

.neu-catalog {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    padding: 1rem;
}

.neu-catalog p {
    margin: 0;
    color: #6b7585;
    font-size: 0.84rem;
}

.neu-cat-list {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    max-height: 22rem;
    overflow: auto;
}

.neu-cat-list.is-page {
    max-height: none;
}

.chasis-board {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 0.75rem;
}

.crud-modal {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    background: rgba(8, 14, 32, 0.55);
}

.crud-dialog {
    display: flex;
    flex-direction: column;
    width: min(520px, 100%);
    max-height: calc(100vh - 2.5rem);
    overflow: hidden;
    border: 1px solid #e6ebf2;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 18px 48px rgba(5, 21, 104, 0.24);
}

.crud-dialog.is-wide {
    width: min(920px, 100%);
}

.crud-head {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid #e8ecf2;
}

.crud-head h2 {
    flex: 1 1 auto;
    margin: 0;
    color: #1c2434;
    font-size: 1.05rem;
}

.crud-body {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    overflow: auto;
    padding: 1rem;
}

.crud-body label {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.crud-body .chasis-editor {
    padding: 0;
}

.crud-body .chasis-actions {
    justify-content: flex-end;
}

.neu-cat-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    width: 100%;
    padding: 0.55rem 0.65rem;
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    background: #fff;
    color: #1c2434;
    text-align: left;
    cursor: pointer;
}

.neu-cat-item.is-selected {
    border-color: rgb(5, 21, 104);
    box-shadow: inset 0 0 0 1px rgb(5, 21, 104);
}

.neu-cat-item.is-off {
    opacity: 0.62;
}

.neu-cat-item em {
    color: #6b7585;
    font-size: 0.75rem;
    font-style: normal;
}

@media (max-width: 1100px) {
    .neu-catalogs,
    .neu-layout {
        grid-template-columns: 1fr;
    }

    .neu-layout.has-panel .neu-main {
        display: none;
    }

    .neu-panel {
        position: static;
        max-height: none;
    }
}

.sync-badge.is-montada {
    background: #e5f4f6;
    color: #0c6670;
}

.mount-board {
    display: grid;
    grid-template-columns: minmax(280px, 420px) minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.mount-diagram,
.mount-bank {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.mount-rig {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    padding: 0.8rem;
    border-radius: 16px;
    background: #f4f6fb;
}

.mount-axles {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    width: 100%;
}

.mount-axle {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 0.45rem;
    align-items: center;
}

.mount-side {
    display: flex;
    gap: 0.35rem;
}

.mount-axle .mount-side:first-child {
    justify-content: flex-end;
}

.mount-axle .mount-side:last-child {
    justify-content: flex-start;
}

.mount-slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    min-width: 4.6rem;
    padding: 0.4rem 0.35rem 0.45rem;
    border: 1px dashed #b7c0d0;
    border-radius: 12px;
    background: #fff;
    color: #5c677a;
    cursor: pointer;
}

.mount-slot i {
    width: 1.15rem;
    height: 2.3rem;
    border: 3px solid #9aa6ba;
    border-radius: 8px;
}

.mount-slot small {
    max-width: 5.2rem;
    overflow: hidden;
    font-size: 0.68rem;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mount-slot.is-filled {
    border-style: solid;
    border-color: rgb(5, 21, 104);
    color: rgb(5, 21, 104);
}

.mount-slot.is-filled i {
    border-color: rgb(5, 21, 104);
    background: rgba(5, 21, 104, 0.12);
}

.mount-slot.is-on {
    box-shadow: 0 0 0 3px rgba(5, 21, 104, 0.18);
}

@media (max-width: 900px) {
    .mount-board {
        grid-template-columns: 1fr;
    }
}

.fuel-form {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    overflow: auto;
    padding: 1rem 1.1rem 1.1rem;
}

.canvas-fill {
    overflow: auto;
}

.fuel-form label {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    color: #6b7585;
    font-size: 0.78rem;
    font-weight: 700;
}

.fuel-head {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: 0.75rem;
}

.fuel-inline-actions,
.ops-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
}

.fuel-form.ops-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    column-gap: 1.25rem;
}

.ops-fields {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    min-width: 0;
}

.ops-actions {
    position: sticky;
    top: 0;
    align-self: start;
    padding-top: 1.35rem;
}

.fuel-head > label {
    width: min(100%, 18rem);
}

.fuel-line {
    display: grid;
    grid-template-columns: minmax(16rem, 24rem) 8.5rem 9.5rem 11rem auto;
    justify-content: start;
    gap: 0.65rem;
    align-items: end;
}

.fuel-form .chasis-actions {
    margin-top: 0;
    border-top: 0;
    justify-content: flex-end;
}

.fuel-preview,
.fuel-last {
    margin: 0;
    color: #3d4758;
    font-size: 0.88rem;
}

.fuel-preview {
    color: rgb(5, 21, 104);
    font-weight: 700;
}

.fuel-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem 1.5rem;
    width: 100%;
}

.fuel-stats div {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    min-width: 8.5rem;
}

.fuel-stats span {
    color: #6b7585;
    font-size: 0.75rem;
    font-weight: 700;
}

.fuel-stats strong {
    color: #1c2434;
    font-size: 1.05rem;
}

.fuel-panel .fuel-stats,
.fuel-panel .fuel-last {
    flex-basis: 100%;
}

.fuel-results {
    padding-top: 0.85rem;
    border-top: 1px solid #e6ebf2;
}

.canvas-fill .neu-table-wrap {
    max-height: none;
}

@media (max-width: 900px) {
    .fuel-line {
        grid-template-columns: 1fr 1fr;
    }

    .fuel-form.ops-form {
        grid-template-columns: 1fr;
    }

    .ops-actions {
        position: static;
        padding-top: 0;
    }
}