:root {
    --bg: #f5f7fb;
    --panel: #ffffff;
    --text: #172033;
    --muted: #67728a;
    --primary: #355cff;
    --primary-soft: #e9edff;
    --border: #dfe5f2;
    --warning: #fff6df;
    --warning-border: #f2c45c;
    --shadow: 0 14px 40px rgba(31, 45, 75, .08);
}

* { box-sizing: border-box; }
body { margin: 0; font-family: Inter, Segoe UI, Roboto, Arial, sans-serif; background: var(--bg); color: var(--text); }
a { color: inherit; }
.shell { min-height: 100vh; display: grid; grid-template-columns: 280px 1fr; }
.sidebar { padding: 24px; background: #12192b; color: white; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; gap: 12px; align-items: center; margin-bottom: 28px; }
.brand-mark { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; background: linear-gradient(135deg, #5d7cff, #9fb1ff); font-weight: 800; }
.brand span { display: block; color: #b9c3df; font-size: .85rem; margin-top: 3px; }
.nav { display: grid; gap: 8px; }
.nav a { color: #dfe6ff; text-decoration: none; padding: 12px 14px; border-radius: 14px; }
.nav a.active, .nav a:hover { background: rgba(255,255,255,.12); color: #fff; }
.content { padding: 34px; max-width: 1440px; width: 100%; }
h1 { font-size: 2.1rem; margin: 0 0 8px; }
h2 { font-size: 1.25rem; margin: 0 0 16px; }
h3 { margin: 18px 0 10px; }
.lead { color: var(--muted); margin-top: 0; max-width: 960px; }
.panel { background: var(--panel); border: 1px solid var(--border); border-radius: 24px; padding: 22px; margin: 20px 0; box-shadow: var(--shadow); }
.panel.highlight { background: linear-gradient(135deg, #ffffff, #edf2ff); }
.panel.warning { background: var(--warning); border-color: var(--warning-border); }
.sticky { position: sticky; top: 24px; }
.metrics-grid { display: grid; grid-template-columns: repeat(4, minmax(160px, 1fr)); gap: 16px; margin: 20px 0; }
.metrics-grid.two { grid-template-columns: repeat(2, minmax(140px, 1fr)); }
.metrics-grid.three { grid-template-columns: repeat(3, minmax(150px, 1fr)); }
.metric-card { background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 18px; }
.metric-card .metric-label { color: var(--muted); font-size: .86rem; }
.metric-card strong { display: block; font-size: 1.45rem; margin-top: 8px; word-break: break-word; }
.metric-card small { color: var(--muted); }
.grid-2-panels { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.align-start { align-items: start; }
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0 20px; }
button, .button { border: 1px solid var(--border); background: #fff; border-radius: 12px; padding: 10px 14px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; }
button:hover, .button:hover { border-color: var(--primary); color: var(--primary); }
button.primary { background: var(--primary); color: white; border-color: var(--primary); }
.form-grid, .grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
label { display: grid; gap: 6px; color: var(--muted); font-size: .94rem; }
input, select, textarea { width: 100%; border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; font: inherit; color: var(--text); background: white; }
textarea { margin-top: 14px; font-family: Consolas, monospace; }
.checks { display: grid; gap: 8px; }
.checks.compact { grid-template-columns: repeat(7, auto); justify-content: start; }
.checks label { display: flex; gap: 8px; align-items: center; color: var(--text); }
.checks input { width: auto; }
.strategy-editor { display: grid; gap: 18px; }
.editor-section { border-top: 1px solid var(--border); padding-top: 14px; }
.bar-row { display: grid; grid-template-columns: 120px 1fr 130px; gap: 12px; align-items: center; margin: 10px 0; }
.bar-label { color: var(--muted); }
.bar-track { height: 11px; border-radius: 999px; background: #edf1f8; overflow: hidden; }
.bar-track span { display: block; height: 100%; border-radius: inherit; background: var(--primary); }
.bar-value { text-align: right; color: var(--muted); font-size: .9rem; }
.table-wrap { overflow: auto; border: 1px solid var(--border); border-radius: 16px; }
table { width: 100%; border-collapse: collapse; background: white; }
th, td { padding: 12px 14px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; }
th { background: #f8faff; color: var(--muted); font-size: .85rem; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
.numbers { white-space: nowrap; }
.numbers span, .number-cloud span { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 34px; border-radius: 999px; background: var(--primary-soft); color: var(--primary); font-weight: 800; margin: 2px; }
.numbers.one span { margin: 0; }
.number-cloud { display: flex; flex-wrap: wrap; gap: 10px; }
.number-cloud span { min-width: 54px; height: 54px; flex-direction: column; }
.number-cloud small { display: block; color: var(--muted); font-size: .72rem; font-weight: 600; }
.number-cloud.cold span { background: #eef8f2; color: #137a42; }
.muted { color: var(--muted); }
.status { color: #137a42; font-weight: 700; }
.error { color: #b32020; font-weight: 700; }
.mini-list { display: grid; gap: 8px; color: var(--muted); }
@media (max-width: 980px) {
    .shell { grid-template-columns: 1fr; }
    .sidebar { position: relative; height: auto; }
    .content { padding: 20px; }
    .metrics-grid, .grid-2-panels, .form-grid, .grid-2 { grid-template-columns: 1fr; }
    .bar-row { grid-template-columns: 1fr; }
    .bar-value { text-align: left; }
}

/* v4 tabs and extended strategy editor */
.tabs { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0; padding: 8px; background: #eef2fb; border: 1px solid var(--border); border-radius: 18px; }
.tab { border: 1px solid transparent; background: transparent; color: var(--muted); border-radius: 12px; padding: 10px 14px; cursor: pointer; }
.tab:hover { background: #fff; border-color: var(--border); color: var(--primary); }
.tab.active { background: #fff; border-color: var(--primary); color: var(--primary); box-shadow: 0 6px 18px rgba(53, 92, 255, .12); }
.compact-tabs { margin: 0 0 10px; padding: 6px; gap: 6px; }
.compact-tabs .tab { padding: 8px 10px; font-size: .92rem; }
.panel.success { background: #effaf3; border-color: #78c895; color: #126734; }
.panel-soft { background: #f8faff; border: 1px solid var(--border); border-radius: 16px; padding: 14px 16px; margin-top: 16px; color: var(--muted); }
.form-grid .wide { grid-column: 1 / -1; }
button:disabled, .button:disabled { opacity: .55; cursor: not-allowed; }
.strategy-editor .editor-section:first-of-type { border-top: 0; }
@media (max-width: 980px) {
    .tabs { gap: 6px; }
    .tab { flex: 1 1 auto; }
    .form-grid .wide { grid-column: auto; }
}

/* v6 profile buttons and status */
.profile-toolbar button.profile-active {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-soft);
    font-weight: 800;
}
.profile-summary {
    margin-bottom: 8px;
}

/* v7 contextual help / tooltips */
.info-tip {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    margin-left: 6px;
    border-radius: 999px;
    border: 1px solid #b8c4df;
    background: #f8faff;
    color: var(--primary);
    font-size: .72rem;
    font-weight: 800;
    line-height: 1;
    vertical-align: middle;
    cursor: help;
    flex: 0 0 auto;
}

.info-tip:focus {
    outline: 2px solid rgba(53, 92, 255, .28);
    outline-offset: 2px;
}

.info-tip-content {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 10px);
    transform: translateX(-50%) translateY(4px);
    z-index: 50;
    width: min(320px, 80vw);
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: #12192b;
    color: #fff;
    box-shadow: 0 14px 35px rgba(18, 25, 43, .22);
    font-size: .84rem;
    line-height: 1.35;
    font-weight: 500;
    text-align: left;
    white-space: normal;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .12s ease, transform .12s ease, visibility .12s ease;
}

.info-tip-content::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 100%;
    transform: translateX(-50%);
    border-width: 7px 7px 0 7px;
    border-style: solid;
    border-color: #12192b transparent transparent transparent;
}

.info-tip:hover .info-tip-content,
.info-tip:focus .info-tip-content,
.info-tip:focus-within .info-tip-content {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.field-caption,
.metric-label {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

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

h2 .info-tip,
h3 .info-tip,
.panel-soft .info-tip,
.metric-label .info-tip {
    transform: translateY(-1px);
}

th[title],
tr[title],
.number-cloud span[title],
.bar-row[title] {
    cursor: help;
}

button[title],
.button[title],
.nav a[title] {
    cursor: pointer;
}

/* v11 card tooltip placement */
.metric-card {
    position: relative;
    overflow: visible;
    min-height: 112px;
}

.metric-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    min-height: 22px;
}

.metric-card .metric-label {
    min-width: 0;
    padding-right: 4px;
    line-height: 1.25;
}

.metric-card .metric-info-tip {
    margin-left: auto;
    margin-top: -2px;
}

.metric-card .info-tip-content {
    z-index: 5000;
}

.info-tip.align-right .info-tip-content {
    left: auto;
    right: -4px;
    transform: translateY(4px);
}

.info-tip.align-right .info-tip-content::after {
    left: auto;
    right: 12px;
    transform: none;
}

.info-tip.align-right:hover .info-tip-content,
.info-tip.align-right:focus .info-tip-content,
.info-tip.align-right:focus-within .info-tip-content {
    transform: translateY(0);
}

.info-tip.align-left .info-tip-content {
    left: -4px;
    transform: translateY(4px);
}

.info-tip.align-left .info-tip-content::after {
    left: 12px;
    transform: none;
}

.info-tip.align-left:hover .info-tip-content,
.info-tip.align-left:focus .info-tip-content,
.info-tip.align-left:focus-within .info-tip-content {
    transform: translateY(0);
}

.info-tip.placement-bottom .info-tip-content {
    top: calc(100% + 10px);
    bottom: auto;
}

.info-tip.placement-bottom .info-tip-content::after {
    top: auto;
    bottom: 100%;
    border-width: 0 7px 7px 7px;
    border-color: transparent transparent #12192b transparent;
}

.metrics-grid,
.grid-2-panels,
.panel {
    overflow: visible;
}

/* v12 full-width desktop layout and non-wrapping result tables */
.shell {
    width: 100%;
}

.content {
    max-width: none;
    width: 100%;
    min-width: 0;
}

.panel,
.tabs,
.profile-summary {
    width: 100%;
}

.table-wrap {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
}

.table-wrap table {
    width: max-content;
    min-width: 100%;
}

.table-wrap th,
.table-wrap td {
    white-space: nowrap;
}

.table-wrap td .numbers,
.table-wrap td.numbers {
    white-space: nowrap;
}

.table-wrap td:last-child {
    max-width: none;
}

@media (min-width: 981px) {
    .content {
        padding-right: 24px;
    }
}

/* v13 recent draw compliance */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid var(--border);
    padding: 4px 9px;
    font-size: .78rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.badge.pass {
    background: #effaf3;
    border-color: #78c895;
    color: #126734;
}

.badge.fail {
    background: #fff1f1;
    border-color: #f1a6a6;
    color: #9d1c1c;
}

.badge.neutral {
    background: #eef2ff;
    border-color: #bac7ff;
    color: var(--primary);
}

.badge.muted-badge {
    background: #f4f6fb;
    color: var(--muted);
}

.badge-list {
    display: flex;
    flex-wrap: nowrap;
    gap: 6px;
    align-items: center;
    white-space: nowrap;
}

.status-cell {
    text-align: center;
}

.matrix-table-wrap th,
.matrix-table-wrap td {
    text-align: center;
}

.matrix-table-wrap th:nth-child(1),
.matrix-table-wrap th:nth-child(2),
.matrix-table-wrap th:nth-child(3),
.matrix-table-wrap td:nth-child(1),
.matrix-table-wrap td:nth-child(2),
.matrix-table-wrap td:nth-child(3) {
    text-align: left;
}

/* v17 custom compliance window */
.inline-window-picker {
    display: inline-flex;
    align-items: end;
    gap: 10px;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: #f8faff;
}

.inline-window-picker label {
    min-width: 210px;
    gap: 5px;
}

.inline-window-picker input {
    width: 130px;
}

@media (max-width: 980px) {
    .inline-window-picker {
        width: 100%;
        flex-wrap: wrap;
    }

    .inline-window-picker label {
        min-width: 0;
        flex: 1 1 220px;
    }
}

/* v18 unified compliance tuning action */
.auto-tune-selector {
    display: grid;
    gap: 12px;
    margin-top: -8px;
    margin-bottom: 18px;
}

.auto-tune-selector.in-tab {
    margin: 14px 0 10px;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: #f8faff;
}

.auto-tune-selector-title {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text);
}

.radio-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(220px, 1fr));
    gap: 12px;
}

.radio-card {
    display: flex;
    grid-template-columns: auto 1fr;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: #fff;
    color: var(--text);
    cursor: pointer;
}

.radio-card:hover,
.radio-card.selected {
    border-color: var(--primary);
    background: var(--primary-soft);
}

.radio-card input {
    width: auto;
    margin-top: 3px;
}

.radio-card span {
    display: grid;
    gap: 4px;
}

.radio-card small {
    color: var(--muted);
    font-size: .84rem;
}

.auto-tune-current {
    color: var(--muted);
}

@media (max-width: 980px) {
    .radio-card-grid {
        grid-template-columns: 1fr;
    }
}

/* v19 compact compliance header */
.content {
    max-width: none;
}

.compliance-command-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(360px, .85fr);
    gap: 16px;
    margin: 18px 0 14px;
}

.compliance-command-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(31, 45, 75, .05);
}

.command-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.command-card-header > div {
    display: grid;
    gap: 3px;
}

.command-card-header strong {
    color: var(--text);
}

.command-card-header span {
    color: var(--muted);
    font-size: .9rem;
}

.quick-window-grid {
    display: grid;
    grid-template-columns: repeat(8, minmax(70px, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.quick-window-grid button {
    min-height: 42px;
    padding: 8px 10px;
    border-radius: 12px;
    white-space: nowrap;
    font-weight: 700;
}

.custom-window-row {
    display: flex;
    align-items: end;
    gap: 10px;
    flex-wrap: wrap;
}

.custom-window-field {
    min-width: 220px;
    max-width: 260px;
}

.custom-window-field input {
    height: 42px;
}

.compact-action {
    min-height: 42px;
    padding: 8px 14px;
    white-space: nowrap;
}

.adjust-card {
    display: grid;
    align-content: start;
}

.compact-radio-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.compact-radio-grid .radio-card {
    min-height: 74px;
    padding: 10px 12px;
}

.adjust-action-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 12px;
    color: var(--muted);
}


@media (max-width: 1280px) {
    .compliance-command-panel {
        grid-template-columns: 1fr;
    }

    .quick-window-grid {
        grid-template-columns: repeat(4, minmax(70px, 1fr));
    }
}

@media (max-width: 640px) {
    .quick-window-grid,
    .compact-radio-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .custom-window-field,
    .custom-window-row button {
        width: 100%;
        max-width: none;
    }
}

/* v23 equal-height cards across pages */
.metrics-grid {
    align-items: stretch;
}

.metrics-grid > .metric-card {
    height: 100%;
    min-height: 128px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.metrics-grid.two > .metric-card {
    min-height: 136px;
}

.metrics-grid.three > .metric-card {
    min-height: 136px;
}

.metric-card .metric-card-header {
    flex: 0 0 auto;
}

.metric-card strong {
    margin-top: 12px;
    line-height: 1.15;
}

.grid-2-panels {
    align-items: stretch;
}

.grid-2-panels.align-start {
    align-items: stretch;
}

.grid-2-panels > .panel,
.compliance-command-panel > .compliance-command-card,
.radio-card-grid > .radio-card,
.compact-radio-grid > .radio-card {
    height: 100%;
}

.panel > .metrics-grid:last-child,
.panel > .metrics-grid.two:last-child,
.panel > .metrics-grid.three:last-child {
    margin-bottom: 0;
}

@media (max-width: 980px) {
    .metrics-grid > .metric-card,
    .metrics-grid.two > .metric-card,
    .metrics-grid.three > .metric-card,
    .grid-2-panels > .panel,
    .grid-2-panels.align-start > .panel {
        min-height: 0;
        height: auto;
    }
}


/* v24 three-column simulated prize summary */
@media (max-width: 1280px) and (min-width: 981px) {
    .metrics-grid.three {
        grid-template-columns: repeat(2, minmax(150px, 1fr));
    }
}

/* v25 target simulation page */
.target-command-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(420px, .95fr);
    gap: 16px;
    margin: 18px 0 14px;
}

.target-command-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(31, 45, 75, .05);
    height: 100%;
}

.compact-toolbar {
    margin-bottom: 12px;
}

button.profile-active,
.button.profile-active {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-soft);
    font-weight: 800;
}

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

.target-checks {
    margin-top: 12px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.target-checks label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text);
    background: #f8faff;
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 10px 12px;
}

.target-checks input {
    width: auto;
}

@media (max-width: 1280px) {
    .target-command-panel {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .target-checks,
    .compact-form {
        grid-template-columns: 1fr;
    }
}

/* v27 inline target simulation progress */
.simulation-actions {
    align-items: center;
}

.secondary-primary {
    background: linear-gradient(135deg, #256d36, #46a44f) !important;
    color: #fff !important;
    border-color: #256d36 !important;
}

button.danger {
    border-color: #dc3545;
    background: #fff5f5;
    color: #a61e2f;
    font-weight: 800;
}

button.danger:hover {
    background: #ffe3e3;
}

.simulation-live-strip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin: 12px 0 16px;
    padding: 12px 14px;
    border: 1px solid rgba(22, 121, 54, .22);
    border-radius: 18px;
    background: linear-gradient(135deg, #f5fff8, #ffffff);
    box-shadow: 0 8px 22px rgba(31, 130, 55, .08);
}

.live-strip-title {
    display: grid;
    gap: 2px;
    min-width: 220px;
}

.live-strip-title strong {
    color: var(--text);
}

.live-strip-title span {
    color: var(--muted);
    font-size: .9rem;
}

.live-badge-row,
.simulation-tab-status {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.simulation-tab-status {
    margin-bottom: 14px;
}

.live-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 12px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text);
    font-weight: 850;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(31, 45, 75, .06);
}

.primary-live {
    border-color: rgba(22, 121, 54, .28);
    background: #eaf8ef;
    color: #136b31;
}

@media (max-width: 720px) {
    .simulation-live-strip {
        align-items: stretch;
        flex-direction: column;
    }

    .live-badge-row,
    .simulation-tab-status {
        align-items: stretch;
        flex-direction: column;
    }

    .live-badge {
        width: 100%;
    }
}

/* v28 La Primitiva official-menu style */
:root {
    --primitiva-green: #4f8f52;
    --primitiva-green-strong: #36773d;
    --primitiva-green-dark: #062b1c;
    --primitiva-green-deep: #031c13;
    --primitiva-green-soft: #eaf6ec;
    --primitiva-menu-text: #f3fff4;
    --primitiva-menu-muted: #b8d8bd;
}

.shell.lottery-primitiva {
    --primitiva-green: #4f8f52;
    --primitiva-green-strong: #36773d;
    --primitiva-green-dark: #062b1c;
    --primitiva-green-deep: #031c13;
    --primitiva-menu-text: #f3fff4;
    --primitiva-menu-muted: #b8d8bd;
}

.shell.lottery-bonoloto {
    --primitiva-green: #7d9429;
    --primitiva-green-strong: #657820;
    --primitiva-green-dark: #27310e;
    --primitiva-green-deep: #151b08;
    --primitiva-menu-text: #fbffe8;
    --primitiva-menu-muted: #d5dfa2;
}

.shell.lottery-gordo {
    --primitiva-green: #d94e5a;
    --primitiva-green-strong: #b93e4a;
    --primitiva-green-dark: #391117;
    --primitiva-green-deep: #22090d;
    --primitiva-menu-text: #fff1f3;
    --primitiva-menu-muted: #f0aab1;
}

.shell.lottery-eurodreams {
    --primitiva-green: #8a34c4;
    --primitiva-green-strong: #6d249d;
    --primitiva-green-dark: #250d3a;
    --primitiva-green-deep: #160722;
    --primitiva-menu-text: #fbf0ff;
    --primitiva-menu-muted: #d3a6ed;
}

.shell.lottery-euromillones {
    --primitiva-green: #d9bf58;
    --primitiva-green-strong: #26306f;
    --primitiva-green-dark: #101641;
    --primitiva-green-deep: #070b22;
    --primitiva-menu-text: #f4f5ff;
    --primitiva-menu-muted: #c6c8f0;
}

.shell.lottery-lototurf {
    --primitiva-green: #e87927;
    --primitiva-green-strong: #c85f15;
    --primitiva-green-dark: #3b1804;
    --primitiva-green-deep: #220d02;
    --primitiva-menu-text: #fff5ec;
    --primitiva-menu-muted: #f2bc91;
}

.sidebar {
    padding: 22px 20px;
    background:
        radial-gradient(circle at 26px 24px, rgba(118, 178, 119, .24), transparent 32px),
        linear-gradient(180deg, var(--primitiva-green-dark) 0%, var(--primitiva-green-deep) 100%);
    color: var(--primitiva-menu-text);
    border-right: 1px solid rgba(118, 178, 119, .28);
    box-shadow: inset -1px 0 0 rgba(255, 255, 255, .04);
}

.brand-primitiva {
    display: grid;
    gap: 14px;
    align-items: start;
    margin-bottom: 24px;
    padding: 14px 12px 16px;
    border-radius: 22px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(118, 178, 119, .32);
    box-shadow: 0 14px 30px rgba(0, 0, 0, .16);
}

.brand-logo {
    display: block;
    width: min(190px, 100%);
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 7px 16px rgba(0, 0, 0, .22));
}

.brand-copy {
    display: grid;
    gap: 4px;
}

.brand-copy strong {
    color: #ffffff;
    font-size: 1rem;
    letter-spacing: .01em;
}

.brand-copy span,
.brand span {
    color: var(--primitiva-menu-muted);
    font-size: .84rem;
    margin-top: 0;
}

.nav {
    gap: 7px;
}

.nav a {
    position: relative;
    color: rgba(243, 255, 244, .84);
    padding: 12px 14px 12px 16px;
    border-radius: 16px;
    border: 1px solid transparent;
    transition: background-color .14s ease, border-color .14s ease, color .14s ease, transform .14s ease;
}

.nav a::before {
    content: "";
    position: absolute;
    left: 8px;
    top: 50%;
    width: 4px;
    height: 0;
    border-radius: 999px;
    transform: translateY(-50%);
    background: var(--primitiva-green);
    transition: height .14s ease;
}

.nav a:hover {
    background: rgba(255, 255, 255, .08);
    border-color: rgba(118, 178, 119, .22);
    color: #ffffff;
    transform: translateX(2px);
}

.nav a.active {
    background: linear-gradient(135deg, rgba(79, 143, 82, .95), rgba(54, 119, 61, .95));
    border-color: rgba(198, 235, 202, .45);
    color: #ffffff;
    box-shadow: 0 10px 22px rgba(0, 0, 0, .20), inset 0 1px 0 rgba(255, 255, 255, .18);
    font-weight: 800;
}

.nav a.active::before {
    height: 24px;
    background: #ffffff;
}

@media (max-width: 980px) {
    .sidebar {
        padding: 16px;
    }

    .brand-primitiva {
        grid-template-columns: minmax(130px, 190px) 1fr;
        align-items: center;
        margin-bottom: 16px;
    }

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

@media (max-width: 640px) {
    .brand-primitiva {
        grid-template-columns: 1fr;
    }

    .nav {
        grid-template-columns: 1fr;
    }
}

/* v28 logo contrast refinements */
.brand-primitiva {
    background: linear-gradient(180deg, #ffffff 0%, #f1fbf3 100%);
    border-color: rgba(79, 143, 82, .28);
}

.brand-copy strong {
    color: var(--primitiva-green-dark);
}

.brand-copy span,
.brand-primitiva span {
    color: #4f6f55;
}

/* v30 menu footer game odds */
.sidebar {
    display: flex;
    flex-direction: column;
}

.sidebar .nav {
    flex: 1 1 auto;
}

.sidebar-footer {
    margin-top: 18px;
    padding: 14px 14px 15px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, .12), rgba(255, 255, 255, .06));
    border: 1px solid rgba(198, 235, 202, .28);
    color: var(--primitiva-menu-text);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .10);
}

.sidebar-footer-label {
    display: block;
    color: var(--primitiva-menu-muted);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    margin-bottom: 6px;
}

.sidebar-footer strong {
    display: block;
    color: #ffffff;
    font-size: 1.38rem;
    line-height: 1.05;
    letter-spacing: .01em;
}

.sidebar-footer small {
    display: block;
    color: var(--primitiva-menu-muted);
    font-size: .78rem;
    margin-top: 5px;
}

@media (max-width: 980px) {
    .sidebar {
        display: block;
    }

    .sidebar-footer {
        margin-top: 14px;
    }
}

/* v31 target objective card richer content */
.target-selection-card {
    display: flex;
    flex-direction: column;
    min-height: 360px;
}

.target-card-fill {
    flex: 1 1 auto;
    display: grid;
    place-items: center;
    min-height: 210px;
    padding: 12px 0 2px;
}

.target-live-center,
.target-insight-card,
.target-empty-state {
    width: min(720px, 100%);
    border: 1px solid var(--border);
    border-radius: 22px;
    background: linear-gradient(135deg, #f8fff9 0%, #ffffff 58%, #f5f8ff 100%);
    box-shadow: 0 14px 34px rgba(31, 45, 75, .07);
    padding: 22px;
}

.target-live-center {
    text-align: center;
}

.target-live-kicker {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 26px;
    padding: 5px 10px;
    border-radius: 999px;
    background: var(--primitiva-green-soft, #eaf6ec);
    color: var(--primitiva-green-strong, #36773d);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.target-live-center > strong,
.target-insight-card > strong {
    display: block;
    color: var(--text);
    font-size: 1.35rem;
    line-height: 1.2;
    margin-bottom: 8px;
}

.target-progress-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    color: var(--muted);
    font-size: .92rem;
    font-weight: 800;
    margin: 10px 0 12px;
}

.target-progress-row span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 10px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: #fff;
}

.target-progress-bar {
    width: 100%;
    height: 12px;
    border-radius: 999px;
    background: #e8edf6;
    overflow: hidden;
    margin: 12px 0 16px;
}

.target-progress-bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--primitiva-green-strong, #36773d), var(--primitiva-green, #4f8f52));
    transition: width .16s ease;
}

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

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

.seed-analysis-progress-modal {
    width: min(760px, calc(100vw - 32px));
}

.seed-analysis-progress-body {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.generator-progress-modal {
    width: min(900px, calc(100vw - 32px));
}

.generator-progress-body {
    gap: 14px;
}

.generator-progress-metrics {
    margin-top: 12px;
}

.generator-progress-best-combination {
    margin: 10px 0 0;
    overflow-wrap: anywhere;
}

.seed-analysis-sample-panel {
    margin-top: 12px;
}

.seed-analysis-sample-text {
    margin: 0;
    line-height: 1.7;
    word-break: break-word;
}

@media (max-width: 900px) {
    .seed-analysis-controls {
        grid-template-columns: 1fr;
    }

    .seed-analysis-secondary {
        grid-template-columns: 1fr;
    }
}

.target-live-stat-grid,
.target-insight-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.target-insight-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.target-live-stat-grid span,
.target-insight-grid span {
    display: grid;
    gap: 3px;
    align-content: center;
    min-height: 64px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: rgba(255, 255, 255, .78);
}

.target-live-stat-grid strong,
.target-insight-grid strong {
    color: var(--text);
    font-size: 1.08rem;
}

.target-live-stat-grid small,
.target-insight-grid small {
    color: var(--muted);
    font-size: .78rem;
    font-weight: 750;
}

.target-insight-card p {
    color: var(--muted);
    margin: 0 0 12px;
    max-width: 720px;
}

.target-ok {
    color: #137a42 !important;
}

.target-ko {
    color: #9d1c1c !important;
}

.target-reason-preview {
    display: grid;
    gap: 7px;
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 16px;
    border: 1px solid #f1a6a6;
    background: #fff7f7;
    color: #9d1c1c;
    font-size: .9rem;
}

.target-reason-preview strong {
    color: #7f1515;
}

.target-empty-state {
    color: var(--muted);
    text-align: center;
}

@media (max-width: 720px) {
    .target-card-fill {
        place-items: stretch;
        min-height: 0;
    }

    .target-live-stat-grid,
    .target-insight-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* v32 selector and multi-lottery cards */
.selector-shell {
    min-height: 100vh;
    padding: 36px;
    background:
        radial-gradient(circle at 12% 10%, rgba(79, 143, 82, .18), transparent 34%),
        radial-gradient(circle at 88% 18%, rgba(138, 52, 196, .16), transparent 30%),
        linear-gradient(180deg, #f6f8fb 0%, #eef2f7 100%);
}

.lottery-selector-page {
    max-width: 1240px;
    margin: 0 auto;
}

.selector-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    overflow: hidden;
}

.selector-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    margin-bottom: 10px;
    padding: 7px 11px;
    border-radius: 999px;
    background: var(--primary-soft);
    color: var(--primary);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.lottery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 22px;
}

.lottery-card {
    --card-accent: #4f8f52;
    display: grid;
    grid-template-rows: 110px auto 1fr;
    gap: 14px;
    min-height: 290px;
    padding: 20px;
    text-decoration: none;
    border-radius: 26px;
    border: 1px solid var(--border);
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: var(--shadow);
    transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.lottery-card:hover {
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--card-accent) 55%, var(--border));
    box-shadow: 0 20px 46px rgba(31, 45, 75, .14);
}

.lottery-card img {
    max-width: 100%;
    max-height: 104px;
    object-fit: contain;
    object-position: left center;
}

.lottery-card strong {
    display: block;
    color: var(--text);
    font-size: 1.22rem;
    margin-bottom: 6px;
}

.lottery-card span {
    display: block;
    color: var(--muted);
    line-height: 1.42;
}

.lottery-card footer {
    align-self: end;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

.lottery-card footer small {
    padding: 7px 10px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--card-accent) 12%, #ffffff);
    color: color-mix(in srgb, var(--card-accent) 82%, #172033);
    font-weight: 800;
}

.lottery-card.lottery-primitiva { --card-accent: #4f8f52; }
.lottery-card.lottery-bonoloto { --card-accent: #7d9429; }
.lottery-card.lottery-gordo { --card-accent: #d94e5a; }
.lottery-card.lottery-eurodreams { --card-accent: #8a34c4; }
.lottery-card.lottery-euromillones { --card-accent: #26306f; }
.lottery-card.lottery-lototurf { --card-accent: #e87927; }

@media (max-width: 1100px) {
    .lottery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
    .selector-shell { padding: 18px; }
    .lottery-grid { grid-template-columns: 1fr; }
    .lottery-card { min-height: auto; }
}

/* v33: static asset recovery + isolated lottery menus */
html, body {
    min-height: 100%;
}

.lottery-shell.lottery-primitiva,
.lottery-card.lottery-primitiva {
    --lottery-accent: #4f8f52;
    --lottery-accent-strong: #36773d;
    --lottery-surface: #f1fbf3;
}

.lottery-shell.lottery-bonoloto,
.lottery-card.lottery-bonoloto {
    --lottery-accent: #7d9429;
    --lottery-accent-strong: #657820;
    --lottery-surface: #fbffe8;
}

.lottery-shell.lottery-gordo,
.lottery-card.lottery-gordo {
    --lottery-accent: #d94e5a;
    --lottery-accent-strong: #b93e4a;
    --lottery-surface: #fff1f3;
}

.lottery-shell.lottery-eurodreams,
.lottery-card.lottery-eurodreams {
    --lottery-accent: #8a34c4;
    --lottery-accent-strong: #6d249d;
    --lottery-surface: #fbf0ff;
}

.lottery-shell.lottery-euromillones,
.lottery-card.lottery-euromillones {
    --lottery-accent: #26306f;
    --lottery-accent-strong: #d9bf58;
    --lottery-surface: #f4f5ff;
}

.lottery-shell.lottery-lototurf,
.lottery-card.lottery-lototurf {
    --lottery-accent: #e87927;
    --lottery-accent-strong: #c85f15;
    --lottery-surface: #fff5ec;
}

.lottery-brand {
    min-height: 178px;
}

.lottery-brand .brand-logo {
    margin: 0 auto;
}

.lottery-menu-block {
    display: grid;
    gap: 10px;
}

.menu-heading {
    display: grid;
    gap: 2px;
    padding: 0 4px 2px;
}

.menu-heading span {
    color: var(--primitiva-menu-muted);
    font-size: .68rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.menu-heading strong {
    color: var(--primitiva-menu-text);
    font-size: .95rem;
}

.lottery-menu.nav {
    flex: 1 1 auto;
}

.lottery-menu.menu-primitiva a.active {
    background: linear-gradient(135deg, #4f8f52, #36773d);
}

.lottery-menu.menu-bonoloto a.active {
    background: linear-gradient(135deg, #7d9429, #657820);
}

.lottery-menu.menu-gordo-primitiva a.active {
    background: linear-gradient(135deg, #d94e5a, #b93e4a);
}

.lottery-menu.menu-eurodreams a.active {
    background: linear-gradient(135deg, #8a34c4, #6d249d);
}

.lottery-menu.menu-euromillones a.active {
    background: linear-gradient(135deg, #26306f, #d9bf58);
}

.lottery-menu.menu-lototurf a.active {
    background: linear-gradient(135deg, #e87927, #c85f15);
}

.selector-shell .panel,
.selector-shell .selector-hero {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 24px;
    box-shadow: var(--shadow);
}

.lottery-card {
    border-left: 7px solid var(--card-accent, var(--lottery-accent, #4f8f52));
}

.lottery-card:hover {
    border-color: var(--card-accent, var(--lottery-accent, #4f8f52));
}

.lottery-card footer small {
    background: #f5f7fb;
    color: var(--card-accent, var(--lottery-accent, #4f8f52));
}

.lottery-card.lottery-primitiva { --card-accent: #4f8f52; }
.lottery-card.lottery-bonoloto { --card-accent: #7d9429; }
.lottery-card.lottery-gordo { --card-accent: #d94e5a; }
.lottery-card.lottery-eurodreams { --card-accent: #8a34c4; }
.lottery-card.lottery-euromillones { --card-accent: #26306f; }
.lottery-card.lottery-lototurf { --card-accent: #e87927; }

@media (max-width: 980px) {
    .lottery-brand {
        min-height: 0;
    }

    .menu-heading {
        grid-column: 1 / -1;
    }
}

/* v36 menu logo fit and compact lottery navigation */
.lottery-sidebar {
    padding: 18px 16px;
}

.lottery-sidebar .lottery-brand,
.brand-primitiva.lottery-brand {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 8px;
    margin-bottom: 14px;
    padding: 12px 10px 13px;
    border-radius: 20px;
    min-height: 0;
    overflow: hidden;
}

.lottery-sidebar .brand-logo,
.lottery-brand .brand-logo {
    width: 100%;
    max-width: 206px;
    height: 118px;
    max-height: 118px;
    object-fit: contain;
    object-position: center center;
    margin: 0 auto;
}

.lottery-sidebar .brand-copy {
    width: 100%;
    gap: 3px;
    text-align: center;
}

.lottery-sidebar .brand-copy strong {
    font-size: .96rem;
    line-height: 1.15;
}

.lottery-sidebar .brand-copy span {
    font-size: .76rem;
    line-height: 1.25;
}

.lottery-menu-block {
    gap: 7px;
}

.lottery-sidebar .nav,
.lottery-sidebar .lottery-menu.nav {
    gap: 4px;
}

.lottery-sidebar .nav a,
.lottery-sidebar .lottery-menu.nav a {
    min-height: 36px;
    padding: 8px 10px 8px 15px;
    border-radius: 12px;
    font-size: .92rem;
    line-height: 1.15;
}

.lottery-sidebar .nav a::before,
.lottery-sidebar .lottery-menu.nav a::before {
    left: 6px;
    width: 3px;
}

.lottery-sidebar .nav a.active::before,
.lottery-sidebar .lottery-menu.nav a.active::before {
    height: 20px;
}

.lottery-sidebar .menu-heading {
    padding: 0 2px;
}

.lottery-sidebar .menu-heading span {
    font-size: .64rem;
}

.lottery-sidebar .menu-heading strong {
    font-size: .88rem;
    line-height: 1.16;
}

.lottery-sidebar .sidebar-footer {
    margin-top: 12px;
    padding: 11px 12px 12px;
    border-radius: 16px;
}

.lottery-sidebar .sidebar-footer strong {
    font-size: 1.16rem;
}

.lottery-sidebar .sidebar-footer small {
    font-size: .72rem;
}

.lottery-card {
    grid-template-rows: 96px auto 1fr;
    min-height: 270px;
    gap: 12px;
}

.lottery-card img {
    width: 100%;
    height: 92px;
    max-height: 92px;
    object-fit: contain;
    object-position: left center;
}

@media (max-width: 980px) {
    .lottery-sidebar .lottery-brand,
    .brand-primitiva.lottery-brand {
        grid-template-columns: minmax(110px, 160px) 1fr;
        justify-items: start;
        gap: 12px;
        margin-bottom: 12px;
    }

    .lottery-sidebar .brand-logo,
    .lottery-brand .brand-logo {
        max-width: 160px;
        height: 82px;
        max-height: 82px;
    }

    .lottery-sidebar .brand-copy {
        text-align: left;
    }

    .lottery-sidebar .nav,
    .lottery-sidebar .lottery-menu.nav {
        gap: 5px;
    }
}

@media (max-width: 640px) {
    .lottery-sidebar .lottery-brand,
    .brand-primitiva.lottery-brand {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .lottery-sidebar .brand-copy {
        text-align: center;
    }
}


/* v37 automatic history refresh status */
.sidebar-update-status {
    margin-top: 10px;
    padding: 10px 12px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .08);
    color: rgba(255, 255, 255, .9);
    display: grid;
    gap: 3px;
}

.sidebar-update-status.success {
    border-color: rgba(79, 209, 139, .34);
    background: rgba(79, 209, 139, .13);
}

.sidebar-update-status.warning {
    border-color: rgba(252, 196, 25, .42);
    background: rgba(252, 196, 25, .14);
}

.sidebar-update-status.checking {
    border-color: rgba(255, 255, 255, .18);
    background: rgba(255, 255, 255, .10);
}

.sidebar-update-label {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: .64rem;
    color: rgba(255, 255, 255, .64);
    font-weight: 800;
}

.sidebar-update-status strong {
    font-size: .95rem;
    line-height: 1.14;
}

.sidebar-update-status small {
    color: rgba(255, 255, 255, .66);
    font-size: .72rem;
    line-height: 1.25;
}

/* v39 menu logo card correction: show the complete official logo in every lottery menu */
.lottery-sidebar .lottery-brand,
.brand-primitiva.lottery-brand {
    min-height: 156px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
}

.lottery-sidebar .lottery-brand .brand-copy,
.brand-primitiva.lottery-brand .brand-copy {
    display: none;
}

.lottery-sidebar .brand-logo,
.lottery-brand .brand-logo {
    display: block;
    width: 100%;
    max-width: 220px;
    height: 132px;
    max-height: 132px;
    object-fit: contain;
    object-position: center center;
    margin: 0 auto;
}

.lottery-shell.lottery-euromillones .lottery-brand .brand-logo {
    max-width: 150px;
}

.lottery-shell.lottery-gordo .lottery-brand .brand-logo {
    max-width: 178px;
}

.lottery-shell.lottery-eurodreams .lottery-brand .brand-logo {
    max-width: 224px;
}

@media (max-width: 980px) {
    .lottery-sidebar .lottery-brand,
    .brand-primitiva.lottery-brand {
        display: flex;
        min-height: 132px;
        padding: 10px 12px;
        justify-items: center;
    }

    .lottery-sidebar .brand-logo,
    .lottery-brand .brand-logo {
        height: 108px;
        max-height: 108px;
        max-width: 204px;
    }
}

@media (max-width: 640px) {
    .lottery-sidebar .lottery-brand,
    .brand-primitiva.lottery-brand {
        min-height: 124px;
    }

    .lottery-sidebar .brand-logo,
    .lottery-brand .brand-logo {
        height: 102px;
        max-height: 102px;
    }
}

/* v40 fixed lottery menu footers, scrollable options and selector history summary */
.lottery-sidebar {
    height: 100vh;
    max-height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.lottery-sidebar .lottery-brand,
.brand-primitiva.lottery-brand {
    flex: 0 0 auto;
}

.lottery-sidebar .lottery-menu-block {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.lottery-sidebar .menu-heading {
    flex: 0 0 auto;
    width: 100%;
    text-align: center;
    justify-items: center;
    padding: 0 4px 3px;
}

.lottery-sidebar .menu-heading span,
.lottery-sidebar .menu-heading strong {
    text-align: center;
}

.lottery-sidebar .lottery-menu.nav,
.lottery-sidebar .nav.lottery-menu {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    align-content: start;
    padding-right: 4px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, .34) transparent;
}

.lottery-sidebar .lottery-menu.nav::-webkit-scrollbar,
.lottery-sidebar .nav.lottery-menu::-webkit-scrollbar {
    width: 6px;
}

.lottery-sidebar .lottery-menu.nav::-webkit-scrollbar-thumb,
.lottery-sidebar .nav.lottery-menu::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .28);
    border-radius: 999px;
}

.lottery-sidebar .sidebar-footer,
.lottery-sidebar .sidebar-update-status {
    flex: 0 0 auto;
    position: relative;
    z-index: 1;
}

.lottery-sidebar .sidebar-footer {
    margin-top: 10px;
}

.lottery-sidebar .sidebar-update-status {
    margin-top: 8px;
}

.lottery-card {
    grid-template-rows: 96px auto auto 1fr;
    min-height: 330px;
}

.lottery-card-status {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 10px;
    border-radius: 16px;
    background: color-mix(in srgb, var(--card-accent, #4f8f52) 8%, #ffffff);
    border: 1px solid color-mix(in srgb, var(--card-accent, #4f8f52) 22%, var(--border));
}

.lottery-card-status div {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.lottery-card-status span {
    color: var(--muted);
    font-size: .68rem;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.lottery-card-status strong {
    color: color-mix(in srgb, var(--card-accent, #4f8f52) 78%, #172033);
    font-size: .92rem;
    line-height: 1.18;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lottery-card-status small {
    color: var(--muted);
    font-size: .76rem;
    line-height: 1.18;
}

@media (max-width: 980px) {
    .lottery-sidebar {
        height: auto;
        max-height: none;
        overflow: visible;
        display: block;
    }

    .lottery-sidebar .lottery-menu-block {
        display: grid;
        min-height: 0;
    }

    .lottery-sidebar .lottery-menu.nav,
    .lottery-sidebar .nav.lottery-menu {
        overflow: visible;
        padding-right: 0;
    }
}

@media (max-width: 720px) {
    .mobile-lottery-bar {
        gap: 8px;
    }

    .mobile-lottery-home img {
        width: 44px;
        height: 44px;
    }

    .mobile-menu-toggle {
        min-width: 82px;
        padding-inline: 10px;
    }

    .lottery-sidebar.menu-open .lottery-sidebar-inner {
        top: calc(env(safe-area-inset-top, 0px) + 74px);
        left: 8px;
        right: 8px;
        bottom: calc(env(safe-area-inset-bottom, 0px) + 8px);
        max-height: none;
    }

    .lottery-sidebar .lottery-menu.nav,
    .lottery-sidebar .nav.lottery-menu {
        grid-template-columns: 1fr;
        padding-bottom: 14px;
    }

    .tabs,
    .compact-tabs {
        padding-bottom: 10px;
    }

    .table-wrap {
        margin-inline: 0;
    }

    .lottery-card {
        min-height: auto;
    }

    .lottery-card-status {
        grid-template-columns: 1fr;
    }
}


/* v41 wider selector cards and complete lottery/dashboard data */
.lottery-selector-page-wide {
    max-width: 1480px;
}

.lottery-grid-wide {
    grid-template-columns: repeat(2, minmax(420px, 1fr));
    gap: 22px;
}

.lottery-card-wide,
.lottery-card.lottery-card-wide {
    grid-template-rows: auto auto auto auto auto 1fr;
    min-height: 0;
    padding: 22px;
    gap: 15px;
}

.lottery-card-wide .lottery-card-logo {
    min-height: 118px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 12px;
    border-radius: 22px;
    background: linear-gradient(135deg, #ffffff 0%, color-mix(in srgb, var(--card-accent, #4f8f52) 10%, #ffffff) 100%);
    border: 1px solid color-mix(in srgb, var(--card-accent, #4f8f52) 18%, var(--border));
}

.lottery-card-wide .lottery-card-logo img {
    width: 100%;
    height: 112px;
    max-height: 112px;
    object-fit: contain;
    object-position: center center;
}

.lottery-card-title strong {
    color: var(--text);
    font-size: 1.34rem;
    line-height: 1.12;
    margin-bottom: 6px;
}

.lottery-card-title span {
    color: var(--muted);
    line-height: 1.42;
}

.lottery-card-facts,
.dashboard-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.lottery-card-facts div,
.dashboard-summary-grid div,
.latest-draw-panel {
    min-width: 0;
    padding: 11px 12px;
    border-radius: 16px;
    background: #f8fafc;
    border: 1px solid var(--border);
}

.lottery-card-facts span,
.lottery-card-latest span,
.dashboard-summary-grid span,
.latest-draw-panel span {
    display: block;
    color: var(--muted);
    font-size: .68rem;
    font-weight: 900;
    letter-spacing: .06em;
    line-height: 1.1;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.lottery-card-facts strong,
.lottery-card-latest strong,
.dashboard-summary-grid strong,
.latest-draw-panel strong {
    color: color-mix(in srgb, var(--card-accent, var(--lottery-accent, #4f8f52)) 78%, #172033);
    font-size: .96rem;
    line-height: 1.22;
    margin: 0;
    word-break: break-word;
}

.lottery-card-facts small,
.lottery-card-latest small,
.dashboard-summary-grid small,
.latest-draw-panel small {
    display: block;
    color: var(--muted);
    font-size: .76rem;
    line-height: 1.22;
    margin-top: 3px;
}

.lottery-card-latest {
    padding: 12px 13px;
    border-radius: 18px;
    background: color-mix(in srgb, var(--card-accent, #4f8f52) 10%, #ffffff);
    border: 1px solid color-mix(in srgb, var(--card-accent, #4f8f52) 22%, var(--border));
}

.lottery-card-latest strong {
    font-size: 1rem;
}

.lottery-card-wide .lottery-card-status {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.lottery-card-wide .lottery-card-status strong {
    white-space: normal;
}

.lottery-card-wide .lottery-card-status small {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.lottery-card-wide footer {
    align-self: end;
}

.lottery-dashboard-summary {
    border-left: 7px solid var(--lottery-accent, var(--primary));
}

.dashboard-summary-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.dashboard-summary-header h2 {
    margin-bottom: 6px;
}

.dashboard-summary-header p {
    margin: 0;
    color: var(--muted);
    line-height: 1.45;
}

.dashboard-lottery-logo {
    width: min(220px, 36%);
    max-height: 130px;
    object-fit: contain;
    object-position: center center;
}

.latest-draw-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(220px, .8fr);
    gap: 12px;
    margin-top: 12px;
    background: color-mix(in srgb, var(--lottery-accent, var(--primary)) 8%, #ffffff);
    border-color: color-mix(in srgb, var(--lottery-accent, var(--primary)) 22%, var(--border));
}

.latest-draw-panel > div {
    min-width: 0;
}

.latest-aux-list {
    display: grid;
    gap: 4px;
}

.latest-aux-list small b {
    color: var(--text);
}

.dashboard-metrics-complete {
    grid-template-columns: repeat(4, minmax(170px, 1fr));
}

@media (max-width: 1180px) {
    .lottery-grid-wide {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .lottery-grid-wide {
        grid-template-columns: 1fr;
    }

    .lottery-card-facts,
    .dashboard-summary-grid,
    .latest-draw-panel,
    .lottery-card-wide .lottery-card-status {
        grid-template-columns: 1fr;
    }

    .dashboard-summary-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .dashboard-lottery-logo {
        width: 100%;
        max-height: 110px;
    }

    .dashboard-metrics-complete {
        grid-template-columns: 1fr;
    }
}

/* v42 selector cards: ampliar ancho real usando toda la página, sin aumentar alto */
.selector-shell {
    width: 100%;
    padding: 32px clamp(20px, 4vw, 64px);
}

.lottery-selector-page-wide {
    width: 100%;
    max-width: none;
    margin: 0;
}

.lottery-grid-wide {
    width: 100%;
    grid-template-columns: 1fr;
    gap: 16px;
}

.lottery-card-wide,
.lottery-card.lottery-card-wide {
    width: 100%;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(170px, 230px) minmax(230px, .85fr) minmax(390px, 1.25fr) minmax(330px, 1fr);
    grid-template-areas:
        "logo title facts latest"
        "logo status status footer";
    align-items: stretch;
    gap: 14px;
    padding: 18px;
}

.lottery-card-wide .lottery-card-logo {
    grid-area: logo;
    min-height: 0;
    height: 100%;
    padding: 10px;
}

.lottery-card-wide .lottery-card-logo img {
    width: 100%;
    height: 100%;
    max-height: 150px;
    object-fit: contain;
    object-position: center center;
}

.lottery-card-wide .lottery-card-title {
    grid-area: title;
    align-self: center;
}

.lottery-card-wide .lottery-card-title strong {
    font-size: clamp(1.18rem, 1.6vw, 1.5rem);
}

.lottery-card-wide .lottery-card-title span {
    font-size: .92rem;
    line-height: 1.3;
}

.lottery-card-wide .lottery-card-facts {
    grid-area: facts;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
}

.lottery-card-wide .lottery-card-facts div,
.lottery-card-wide .lottery-card-latest,
.lottery-card-wide .lottery-card-status {
    padding: 9px 10px;
    border-radius: 15px;
}

.lottery-card-wide .lottery-card-facts strong,
.lottery-card-wide .lottery-card-latest strong,
.lottery-card-wide .lottery-card-status strong {
    font-size: .9rem;
    line-height: 1.18;
}

.lottery-card-wide .lottery-card-facts small,
.lottery-card-wide .lottery-card-latest small,
.lottery-card-wide .lottery-card-status small {
    font-size: .72rem;
    line-height: 1.16;
}

.lottery-card-wide .lottery-card-latest {
    grid-area: latest;
    align-self: stretch;
}

.lottery-card-wide .lottery-card-status {
    grid-area: status;
    align-self: stretch;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.lottery-card-wide footer {
    grid-area: footer;
    align-self: stretch;
    display: flex;
    align-items: center;
    align-content: center;
    gap: 7px;
    padding-top: 0;
    border-top: 0;
}

.lottery-card-wide footer small {
    padding: 6px 9px;
    font-size: .72rem;
}

@media (max-width: 1500px) {
    .lottery-card-wide,
    .lottery-card.lottery-card-wide {
        grid-template-columns: minmax(150px, 210px) minmax(260px, .85fr) minmax(360px, 1.25fr);
        grid-template-areas:
            "logo title facts"
            "logo latest status"
            "logo footer footer";
    }

    .lottery-card-wide .lottery-card-facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 1100px) {
    .selector-shell {
        padding: 24px;
    }

    .lottery-card-wide,
    .lottery-card.lottery-card-wide {
        grid-template-columns: minmax(140px, 190px) minmax(0, 1fr);
        grid-template-areas:
            "logo title"
            "logo facts"
            "latest status"
            "footer footer";
    }
}

@media (max-width: 720px) {
    .selector-shell {
        padding: 18px;
    }

    .lottery-card-wide,
    .lottery-card.lottery-card-wide {
        grid-template-columns: 1fr;
        grid-template-areas:
            "logo"
            "title"
            "facts"
            "latest"
            "status"
            "footer";
        padding: 16px;
    }

    .lottery-card-wide .lottery-card-logo {
        min-height: 112px;
    }

    .lottery-card-wide .lottery-card-logo img {
        height: 112px;
    }

    .lottery-card-wide .lottery-card-facts,
    .lottery-card-wide .lottery-card-status {
        grid-template-columns: 1fr;
    }
}

/* v43 responsive mobile compatibility across selector, menus and lottery pages */
html {
    -webkit-text-size-adjust: 100%;
}

body {
    overflow-x: hidden;
}

img,
svg,
canvas,
video {
    max-width: 100%;
}

.mobile-lottery-bar {
    display: none;
}

.lottery-sidebar-inner {
    display: contents;
}

.content,
.selector-shell,
.panel,
.metric-card,
.compliance-command-card,
.target-command-card,
.lottery-card,
.lottery-card-wide,
.table-wrap,
.tabs,
.toolbar {
    min-width: 0;
}

.table-wrap {
    -webkit-overflow-scrolling: touch;
}

.toolbar > button,
.toolbar > .button,
.profile-toolbar > button,
.profile-toolbar > .button,
.tabs > .tab,
.tabs > button {
    min-height: 42px;
}

@media (max-width: 1180px) {
    .content {
        padding: 26px;
    }

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

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

    .lottery-card-wide,
    .lottery-card.lottery-card-wide {
        grid-template-columns: minmax(128px, 180px) minmax(0, 1fr);
        grid-template-areas:
            "logo title"
            "facts facts"
            "latest latest"
            "status status"
            "footer footer";
    }

    .lottery-card-wide .lottery-card-facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    .shell,
    .shell.lottery-shell {
        display: block;
        min-height: 100dvh;
    }

    .content {
        width: 100%;
        padding: 18px clamp(12px, 4vw, 24px) 28px;
    }

    h1 {
        font-size: clamp(1.55rem, 7vw, 2rem);
        line-height: 1.08;
        overflow-wrap: anywhere;
    }

    h2 {
        font-size: clamp(1.1rem, 4.8vw, 1.32rem);
        line-height: 1.18;
    }

    h3 {
        font-size: 1.04rem;
        line-height: 1.22;
    }

    .lead {
        font-size: .96rem;
        line-height: 1.45;
    }

    .panel,
    .metric-card,
    .compliance-command-card,
    .target-command-card {
        border-radius: 18px;
        padding: 16px;
        margin: 14px 0;
    }

    .metrics-grid,
    .metrics-grid.two,
    .metrics-grid.three,
    .dashboard-metrics-complete,
    .grid-2-panels,
    .grid-2-panels.align-start,
    .form-grid,
    .grid-2,
    .compliance-command-panel,
    .target-command-panel {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .metric-card {
        min-height: 0;
    }

    .metric-card strong {
        font-size: 1.16rem;
        line-height: 1.14;
    }

    .toolbar,
    .profile-toolbar,
    .adjust-action-row,
    .custom-window-row,
    .simulation-actions {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 9px;
        align-items: stretch;
    }

    .toolbar > button,
    .toolbar > .button,
    .profile-toolbar > button,
    .profile-toolbar > .button,
    .custom-window-row > button,
    .adjust-action-row > button,
    .simulation-actions > button,
    .simulation-actions > .button {
        width: 100%;
    }

    .tabs,
    .compact-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        padding: 7px;
        gap: 7px;
        scroll-snap-type: x proximity;
        scrollbar-width: thin;
    }

    .tabs .tab,
    .tabs > button,
    .compact-tabs .tab {
        flex: 0 0 auto;
        min-width: max-content;
        scroll-snap-align: start;
        white-space: nowrap;
    }

    .quick-window-grid {
        grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
    }

    .radio-card-grid,
    .compact-radio-grid,
    .target-checks,
    .checks.compact {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }

    .checks label,
    .target-checks label,
    .radio-card {
        min-height: 44px;
    }

    input,
    select,
    textarea,
    button,
    .button {
        font-size: 16px;
    }

    .table-wrap {
        border-radius: 14px;
        margin-inline: -2px;
    }

    th,
    td {
        padding: 10px 11px;
        font-size: .92rem;
    }

    .badge-list {
        flex-wrap: wrap;
        white-space: normal;
    }

    .number-cloud {
        gap: 7px;
    }

    .number-cloud span {
        min-width: 46px;
        height: 46px;
    }

    .numbers span,
    .number-cloud span {
        min-width: 30px;
        height: 30px;
        font-size: .88rem;
    }

    .latest-draw-panel,
    .dashboard-summary-grid {
        grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
    }

    .dashboard-summary-header {
        gap: 14px;
    }

    .dashboard-lottery-logo {
        max-width: 260px;
        width: 100%;
        max-height: 104px;
    }

    .latest-draw-panel {
        padding: 12px;
    }

    .bar-row {
        grid-template-columns: 1fr;
        gap: 7px;
    }

    .bar-value {
        text-align: left;
    }

    /* Mobile lottery menu: compact top bar, collapsible panel. */
    .lottery-sidebar.sidebar {
        position: sticky;
        top: 0;
        z-index: 1000;
        height: auto;
        max-height: 100dvh;
        width: 100%;
        padding: 10px;
        overflow: visible;
        border-right: 0;
        border-bottom: 1px solid rgba(255, 255, 255, .12);
    }

    .lottery-sidebar.menu-open.sidebar {
        z-index: 1200;
    }

    .mobile-lottery-bar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
        min-height: 58px;
        width: 100%;
    }

    .mobile-lottery-home {
        min-width: 0;
        display: flex;
        align-items: center;
        gap: 10px;
        color: var(--primitiva-menu-text);
        text-decoration: none;
    }

    .mobile-lottery-home img {
        width: 48px;
        height: 48px;
        object-fit: contain;
        border-radius: 13px;
        padding: 5px;
        background: #ffffff;
        box-shadow: 0 6px 18px rgba(0, 0, 0, .18);
    }

    .mobile-lottery-home span {
        min-width: 0;
        display: grid;
        gap: 2px;
    }

    .mobile-lottery-home small {
        color: var(--primitiva-menu-muted);
        font-size: .68rem;
        text-transform: uppercase;
        letter-spacing: .08em;
        font-weight: 900;
    }

    .mobile-lottery-home strong {
        overflow: hidden;
        color: #ffffff;
        font-size: 1rem;
        line-height: 1.08;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .mobile-menu-toggle {
        flex: 0 0 auto;
        min-width: 88px;
        min-height: 42px;
        padding: 9px 12px;
        border-color: rgba(255, 255, 255, .22);
        background: rgba(255, 255, 255, .12);
        color: #ffffff;
        font-weight: 900;
    }

    .mobile-menu-toggle:hover {
        border-color: rgba(255, 255, 255, .42);
        color: #ffffff;
    }

    .lottery-sidebar .lottery-sidebar-inner {
        display: none;
        width: 100%;
    }

    .lottery-sidebar.menu-open.sidebar {
        z-index: 1200;
    }

    .lottery-sidebar.menu-open.sidebar::after {
        content: "";
        position: fixed;
        inset: 0;
        z-index: 1199;
        background: rgba(7, 17, 38, .44);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
    }

    .lottery-sidebar.menu-open .lottery-sidebar-inner {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: calc(env(safe-area-inset-top, 0px) + 78px);
        left: 10px;
        right: 10px;
        bottom: calc(env(safe-area-inset-bottom, 0px) + 10px);
        z-index: 1201;
        gap: 10px;
        width: auto;
        max-height: none;
        overflow: hidden;
        padding: 10px 10px 12px;
        border: 1px solid rgba(255, 255, 255, .14);
        border-radius: 20px;
        background: color-mix(in srgb, #162507 92%, #20330a);
        box-shadow: 0 22px 54px rgba(7, 17, 38, .34);
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }

    .lottery-sidebar .lottery-brand,
    .brand-primitiva.lottery-brand {
        min-height: 86px;
        margin-bottom: 0;
        padding: 9px 10px;
    }

    .lottery-sidebar .brand-logo,
    .lottery-brand .brand-logo {
        height: 68px;
        max-height: 68px;
        max-width: 180px;
    }

    .lottery-sidebar .lottery-menu-block {
        min-height: 0;
        gap: 8px;
        overflow: hidden;
        flex: 1 1 auto;
    }

    .lottery-sidebar .lottery-menu.nav,
    .lottery-sidebar .nav.lottery-menu {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
        width: 100%;
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        overflow-x: hidden;
        padding-right: 2px;
        padding-bottom: 8px;
        overscroll-behavior: contain;
    }

    .lottery-sidebar .nav a,
    .lottery-sidebar .lottery-menu.nav a {
        min-height: 42px;
        display: flex;
        align-items: center;
        min-width: 0;
        padding: 10px 10px 10px 14px;
        font-size: .9rem;
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .lottery-sidebar .sidebar-footer,
    .lottery-sidebar .sidebar-update-status {
        margin-top: 0;
    }

    .lottery-sidebar .sidebar-footer strong {
        font-size: 1.04rem;
    }

    /* Mobile selector: use full width and compact each card. */
    .selector-shell {
        min-height: 100dvh;
        padding: 16px clamp(10px, 4vw, 22px) 24px;
    }

    .lottery-selector-page,
    .lottery-selector-page-wide {
        width: 100%;
        max-width: none;
    }

    .app-topbar {
        min-height: 64px;
        gap: 10px;
        padding: 10px 14px;
        margin-bottom: 18px;
    }

    .app-topbar-brand {
        flex: 1 1 auto;
        min-width: 0;
    }

    .app-topbar-brand img {
        width: min(280px, 56vw);
        height: 40px;
    }

    .app-topbar-session {
        flex: 0 1 auto;
        min-width: 0;
        gap: 8px;
        padding: 6px 8px 6px 10px;
    }

    .app-topbar-session .button.mini {
        min-height: 34px;
        padding: 7px 11px;
    }

    .selector-hero {
        align-items: stretch;
        flex-direction: column;
        gap: 12px;
        padding: 18px;
    }

    .selector-kicker {
        font-size: .7rem;
    }

    .lottery-grid,
    .lottery-grid-wide {
        grid-template-columns: 1fr;
        gap: 12px;
        margin-top: 14px;
    }

    .lottery-card-wide,
    .lottery-card.lottery-card-wide {
        grid-template-columns: 104px minmax(0, 1fr);
        grid-template-areas:
            "logo title"
            "facts facts"
            "latest latest"
            "status status"
            "footer footer";
        gap: 10px;
        padding: 13px;
        border-radius: 20px;
    }

    .lottery-card-wide .lottery-card-logo {
        min-height: 92px;
        padding: 8px;
        border-radius: 16px;
    }

    .lottery-card-wide .lottery-card-logo img {
        height: 76px;
        max-height: 76px;
    }

    .lottery-card-title {
        min-width: 0;
    }

    .lottery-card-title strong,
    .lottery-card-wide .lottery-card-title strong {
        font-size: 1.1rem;
        line-height: 1.12;
    }

    .lottery-card-title span,
    .lottery-card-wide .lottery-card-title span {
        display: -webkit-box;
        overflow: hidden;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        font-size: .86rem;
    }

    .lottery-card-wide .lottery-card-facts,
    .lottery-card-wide .lottery-card-status {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .lottery-card-wide .lottery-card-facts div,
    .lottery-card-wide .lottery-card-latest,
    .lottery-card-wide .lottery-card-status {
        padding: 8px;
        border-radius: 13px;
    }

    .lottery-card-wide .lottery-card-facts span,
    .lottery-card-wide .lottery-card-latest span,
    .lottery-card-wide .lottery-card-status span {
        font-size: .61rem;
    }

    .lottery-card-wide .lottery-card-facts strong,
    .lottery-card-wide .lottery-card-latest strong,
    .lottery-card-wide .lottery-card-status strong {
        font-size: .82rem;
        line-height: 1.15;
    }

    .lottery-card-wide .lottery-card-facts small,
    .lottery-card-wide .lottery-card-latest small,
    .lottery-card-wide .lottery-card-status small {
        font-size: .68rem;
    }

    .lottery-card-wide footer {
        gap: 6px;
        flex-wrap: wrap;
    }

    .lottery-card-wide footer small {
        padding: 6px 8px;
        font-size: .68rem;
    }
}

@media (max-width: 640px) {
    .content {
        padding: 14px 10px 22px;
    }

    .panel,
    .metric-card,
    .compliance-command-card,
    .target-command-card {
        border-radius: 16px;
        padding: 13px;
    }

    .toolbar,
    .profile-toolbar,
    .adjust-action-row,
    .custom-window-row,
    .simulation-actions {
        grid-template-columns: 1fr;
    }

    .tabs .tab,
    .tabs > button,
    .compact-tabs .tab {
        padding: 9px 11px;
        font-size: .88rem;
    }

    .quick-window-grid,
    .radio-card-grid,
    .compact-radio-grid,
    .target-checks,
    .checks.compact {
        grid-template-columns: 1fr;
    }

    .inline-window-picker,
    .custom-window-row {
        align-items: stretch;
    }

    .inline-window-picker label,
    .custom-window-field,
    .custom-window-field input,
    .custom-window-row button,
    .compact-action {
        width: 100%;
        max-width: none;
    }

    .dashboard-summary-grid,
    .latest-draw-panel,
    .target-live-stat-grid,
    .target-insight-grid {
        grid-template-columns: 1fr;
    }

    .target-live-center,
    .target-insight-card,
    .target-empty-state {
        padding: 14px;
        border-radius: 18px;
    }

    .target-progress-row,
    .live-badge-row,
    .simulation-tab-status {
        align-items: stretch;
        flex-direction: column;
    }

    .target-progress-row span,
    .live-badge {
        width: 100%;
        justify-content: center;
    }

    .lottery-sidebar .lottery-menu.nav,
    .lottery-sidebar .nav.lottery-menu {
        grid-template-columns: 1fr;
    }

    .lottery-card-wide,
    .lottery-card.lottery-card-wide {
        grid-template-columns: 88px minmax(0, 1fr);
    }

    .lottery-card-wide .lottery-card-logo {
        min-height: 78px;
    }

    .lottery-card-wide .lottery-card-logo img {
        height: 66px;
        max-height: 66px;
    }
}

@media (max-width: 440px) {
    .content {
        padding-left: 8px;
        padding-right: 8px;
    }

    .selector-shell {
        padding-left: 8px;
        padding-right: 8px;
    }

    .lottery-card-wide,
    .lottery-card.lottery-card-wide {
        grid-template-columns: 1fr;
        grid-template-areas:
            "logo"
            "title"
            "facts"
            "latest"
            "status"
            "footer";
    }

    .lottery-card-wide .lottery-card-logo {
        min-height: 86px;
    }

    .lottery-card-wide .lottery-card-facts,
    .lottery-card-wide .lottery-card-status {
        grid-template-columns: 1fr;
    }

    .mobile-menu-toggle {
        min-width: 78px;
        padding-inline: 10px;
    }

    .mobile-lottery-home img {
        width: 42px;
        height: 42px;
    }

    .mobile-lottery-home strong {
        font-size: .94rem;
    }

    th,
    td {
        padding: 9px;
        font-size: .88rem;
    }
}


/* v48 compact one-line metric cards for Simulación and Premios tabs */
.metrics-grid.compact-nowrap-metrics {
    grid-template-columns: repeat(auto-fit, minmax(235px, 1fr));
    gap: 10px;
    align-items: stretch;
}

.metrics-grid.compact-nowrap-metrics.target-simulation-metrics {
    grid-template-columns: repeat(auto-fit, minmax(245px, 1fr));
}

.metrics-grid.compact-nowrap-metrics.target-prize-metrics,
.metrics-grid.compact-nowrap-metrics.prize-summary-metrics {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.metrics-grid.compact-nowrap-metrics > .metric-card {
    min-height: 0;
    padding: 12px 14px;
    border-radius: 15px;
}

.metrics-grid.compact-nowrap-metrics > .metric-card .metric-card-header {
    gap: 6px;
    align-items: center;
    flex-wrap: nowrap;
}

.metrics-grid.compact-nowrap-metrics > .metric-card .metric-label {
    min-width: 0;
    max-width: 100%;
    white-space: nowrap;
    overflow: visible;
    text-overflow: clip;
    font-size: .74rem;
    line-height: 1.05;
    letter-spacing: .045em;
}

.metrics-grid.compact-nowrap-metrics > .metric-card .metric-info-tip {
    flex: 0 0 auto;
}

.metrics-grid.compact-nowrap-metrics > .metric-card strong {
    margin-top: 7px;
    white-space: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    text-overflow: clip;
    scrollbar-width: thin;
    font-size: clamp(1rem, 1.05vw, 1.18rem);
    line-height: 1.1;
}

.metrics-grid.compact-nowrap-metrics > .metric-card small {
    white-space: nowrap;
}

@media (max-width: 980px) {
    .metrics-grid.compact-nowrap-metrics,
    .metrics-grid.compact-nowrap-metrics.target-simulation-metrics,
    .metrics-grid.compact-nowrap-metrics.target-prize-metrics,
    .metrics-grid.compact-nowrap-metrics.prize-summary-metrics {
        display: flex;
        gap: 10px;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x proximity;
    }

    .metrics-grid.compact-nowrap-metrics > .metric-card {
        flex: 0 0 min(260px, 82vw);
        scroll-snap-align: start;
    }
}

/* v49 centered loading overlay with lottery logo */
.loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: grid;
    place-items: center;
    padding: 22px;
    background: rgba(8, 14, 28, .56);
    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);
}

.loading-overlay.inline-loading-overlay {
    position: absolute;
}

.loading-card {
    width: min(420px, calc(100vw - 32px));
    display: grid;
    justify-items: center;
    gap: 12px;
    padding: 24px 22px 22px;
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 26px;
    background: linear-gradient(145deg, rgba(255, 255, 255, .97), rgba(248, 250, 252, .94));
    box-shadow: 0 28px 80px rgba(2, 6, 23, .34);
    color: var(--text, #172033);
    text-align: center;
}

.loading-logo-shell {
    width: min(210px, 58vw);
    min-height: 104px;
    display: grid;
    place-items: center;
    padding: 14px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, .08), 0 12px 30px rgba(15, 23, 42, .11);
}

.loading-logo {
    width: 100%;
    max-width: 178px;
    max-height: 96px;
    object-fit: contain;
}

.loading-spinner {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    border: 4px solid rgba(15, 23, 42, .12);
    border-top-color: var(--accent, #22c55e);
    animation: loadingSpin .85s linear infinite;
}

.loading-card strong {
    font-size: 1.15rem;
    line-height: 1.15;
}

.loading-card span {
    max-width: 32rem;
    color: var(--muted, #667085);
    font-size: .94rem;
    line-height: 1.35;
}

@keyframes loadingSpin {
    to { transform: rotate(360deg); }
}

@media (max-width: 640px) {
    .loading-overlay {
        padding: 16px;
    }

    .loading-card {
        width: min(360px, calc(100vw - 24px));
        gap: 10px;
        padding: 20px 18px 18px;
        border-radius: 22px;
    }

    .loading-logo-shell {
        width: min(180px, 62vw);
        min-height: 90px;
        padding: 12px;
    }

    .loading-logo {
        max-height: 82px;
    }

    .loading-card strong {
        font-size: 1.05rem;
    }

    .loading-card span {
        font-size: .88rem;
    }
}

/* v51 startup auto-update popup progress */
.loading-progress {
    width: min(320px, 100%);
    display: grid;
    gap: 7px;
    margin-top: 2px;
}

.loading-progress-text {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: var(--muted, #667085);
    font-weight: 800;
}

.loading-progress-text small {
    font-size: .78rem;
    line-height: 1.2;
}

.loading-progress-track {
    height: 9px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(15, 23, 42, .1);
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, .08);
}

.loading-progress-track span {
    display: block;
    height: 100%;
    min-width: 8px;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent, #22c55e), color-mix(in srgb, var(--accent, #22c55e) 72%, #ffffff));
    transition: width .18s ease;
}

@media (max-width: 640px) {
    .loading-progress {
        width: 100%;
    }

    .loading-progress-text small {
        font-size: .74rem;
    }
}

/* v53 fixed-size loading logo shell: logos no longer change the popup height while startup update advances */
.loading-card {
    grid-auto-rows: max-content;
}

.loading-logo-shell {
    width: min(220px, 58vw);
    height: 124px;
    min-height: 0;
    box-sizing: border-box;
    overflow: hidden;
    flex: 0 0 auto;
}

.loading-logo {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    object-position: center center;
}

@media (max-width: 640px) {
    .loading-logo-shell {
        width: min(188px, 62vw);
        height: 104px;
        min-height: 0;
    }

    .loading-logo {
        max-height: 100%;
    }
}

/* v54 logo containment: keep every lottery logo fully visible inside menu, selector and loading cards */
.loading-logo-shell {
    width: min(240px, 62vw) !important;
    height: 150px !important;
    min-height: 150px !important;
    max-height: 150px !important;
    box-sizing: border-box !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 18px 20px !important;
    overflow: visible !important;
}

.loading-logo-shell .loading-logo,
.loading-logo {
    display: block !important;
    width: auto !important;
    height: auto !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
    flex: 0 1 auto !important;
}

.lottery-sidebar .lottery-brand,
.brand-primitiva.lottery-brand {
    min-height: 168px !important;
    box-sizing: border-box !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 16px 18px !important;
    overflow: visible !important;
}

.lottery-sidebar .brand-logo,
.lottery-brand .brand-logo {
    display: block !important;
    width: auto !important;
    height: auto !important;
    max-width: min(230px, 100%) !important;
    max-height: 136px !important;
    object-fit: contain !important;
    object-position: center center !important;
}

.lottery-shell.lottery-euromillones .lottery-brand .brand-logo {
    max-width: 156px !important;
    max-height: 136px !important;
}

.lottery-shell.lottery-gordo .lottery-brand .brand-logo {
    max-width: 190px !important;
    max-height: 136px !important;
}

.lottery-shell.lottery-eurodreams .lottery-brand .brand-logo {
    max-width: min(236px, 100%) !important;
    max-height: 128px !important;
}

.lottery-card-wide .lottery-card-logo,
.lottery-card-logo {
    box-sizing: border-box !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 14px !important;
    overflow: visible !important;
}

.lottery-card-wide .lottery-card-logo img,
.lottery-card-logo img,
.lottery-card img {
    display: block !important;
    width: auto !important;
    height: auto !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
}

.mobile-lottery-home img {
    object-fit: contain !important;
}

@media (max-width: 980px) {
    .lottery-sidebar .lottery-brand,
    .brand-primitiva.lottery-brand {
        min-height: 142px !important;
        padding: 14px 16px !important;
    }

    .lottery-sidebar .brand-logo,
    .lottery-brand .brand-logo {
        max-width: min(210px, 100%) !important;
        max-height: 112px !important;
    }

    .loading-logo-shell {
        width: min(220px, 66vw) !important;
        height: 136px !important;
        min-height: 136px !important;
        max-height: 136px !important;
        padding: 16px 18px !important;
    }
}

@media (max-width: 640px) {
    .lottery-sidebar .lottery-brand,
    .brand-primitiva.lottery-brand {
        min-height: 104px !important;
        padding: 12px 14px !important;
    }

    .lottery-sidebar .brand-logo,
    .lottery-brand .brand-logo {
        max-width: min(190px, 100%) !important;
        max-height: 78px !important;
    }

    .loading-logo-shell {
        width: min(204px, 72vw) !important;
        height: 128px !important;
        min-height: 128px !important;
        max-height: 128px !important;
        padding: 16px !important;
    }

    .lottery-card-wide .lottery-card-logo,
    .lottery-card-logo {
        min-height: 92px !important;
        padding: 12px !important;
    }
}


/* v60 no-wrap result metric cards for Generador and Ruedas */
.metrics-grid.generator-result-metrics,
.metrics-grid.wheel-result-metrics {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 12px;
    align-items: stretch;
}

.metrics-grid.generator-result-metrics > .metric-card,
.metrics-grid.wheel-result-metrics > .metric-card {
    min-height: 98px;
    padding: 14px 16px;
    border-radius: 16px;
}

.metrics-grid.generator-result-metrics > .metric-card-short,
.metrics-grid.wheel-result-metrics > .metric-card-short {
    grid-column: span 2;
}

.metrics-grid.generator-result-metrics > .metric-card-wide,
.metrics-grid.wheel-result-metrics > .metric-card-wide {
    grid-column: span 3;
}

.metrics-grid.generator-result-metrics > .metric-card .metric-card-header,
.metrics-grid.wheel-result-metrics > .metric-card .metric-card-header {
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
}

.metrics-grid.generator-result-metrics > .metric-card .metric-label,
.metrics-grid.wheel-result-metrics > .metric-card .metric-label {
    white-space: nowrap;
    overflow: visible;
    text-overflow: clip;
    line-height: 1.08;
}

.metrics-grid.generator-result-metrics > .metric-card strong,
.metrics-grid.wheel-result-metrics > .metric-card strong {
    white-space: nowrap;
    word-break: normal;
    overflow-wrap: normal;
    overflow: visible;
    font-size: clamp(1.08rem, 1.2vw, 1.28rem);
    line-height: 1.1;
}

.metrics-grid.generator-result-metrics > .metric-card .metric-info-tip,
.metrics-grid.wheel-result-metrics > .metric-card .metric-info-tip {
    flex: 0 0 auto;
}

@media (max-width: 1180px) and (min-width: 981px) {
    .metrics-grid.generator-result-metrics,
    .metrics-grid.wheel-result-metrics {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

    .metrics-grid.generator-result-metrics > .metric-card-short,
    .metrics-grid.wheel-result-metrics > .metric-card-short {
        grid-column: span 2;
    }

    .metrics-grid.generator-result-metrics > .metric-card-wide,
    .metrics-grid.wheel-result-metrics > .metric-card-wide {
        grid-column: span 3;
    }
}

@media (max-width: 980px) {
    .metrics-grid.generator-result-metrics,
    .metrics-grid.wheel-result-metrics {
        display: flex;
        gap: 10px;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x proximity;
    }

    .metrics-grid.generator-result-metrics > .metric-card,
    .metrics-grid.wheel-result-metrics > .metric-card {
        flex: 0 0 auto;
        min-width: max-content;
        min-height: 92px;
        scroll-snap-align: start;
    }

    .metrics-grid.generator-result-metrics > .metric-card-short,
    .metrics-grid.wheel-result-metrics > .metric-card-short {
        min-width: 190px;
    }

    .metrics-grid.generator-result-metrics > .metric-card-wide,
    .metrics-grid.wheel-result-metrics > .metric-card-wide {
        min-width: 245px;
    }
}

/* v61 La Quiniela independent module */
.quiniela-page {
    width: 100%;
}

.quiniela-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: start;
    background: linear-gradient(135deg, #ffffff, #f2fff6);
}

.quiniela-toolbar {
    justify-content: flex-end;
    margin: 0;
    min-width: 420px;
}

.quiniela-metrics {
    grid-template-columns: repeat(4, minmax(170px, 1fr));
}

.quiniela-main-grid {
    grid-template-columns: minmax(640px, .95fr) minmax(560px, 1.05fr);
}

.quiniela-latest-summary {
    display: grid;
    gap: 10px;
    margin-bottom: 16px;
}

.quiniela-latest-summary strong {
    font-size: 1.35rem;
}


/* v91 - Quiniela dashboard: mantener resultado de última jornada en una sola línea */
.quiniela-latest-panel > div:first-child strong,
.quiniela-latest-panel > div:first-child small {
    display: block;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: normal;
}

.quiniela-latest-panel > div:first-child {
    min-width: 0;
}

.quiniela-sign-strip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    flex-wrap: nowrap;
    white-space: nowrap;
}

.quiniela-sign {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    padding: 0 8px;
    border-radius: 999px;
    border: 1px solid var(--border);
    font-weight: 900;
    line-height: 1;
    background: #eef2ff;
    color: var(--primary);
}

.quiniela-sign.sign-x {
    background: #fff6df;
    border-color: #f2c45c;
    color: #9a6200;
}

.quiniela-sign.sign-2 {
    background: #effaf3;
    border-color: #78c895;
    color: #126734;
}

.quiniela-progress-panel {
    display: grid;
    gap: 10px;
}

.quiniela-progress-header {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
}

.quiniela-progress-header div {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.quiniela-progress-header small {
    color: var(--muted);
    font-weight: 700;
    line-height: 1.35;
}

.quiniela-progress-header span {
    flex: 0 0 auto;
    color: var(--primary);
    font-weight: 900;
}

.quiniela-progress-bar {
    height: 12px;
    border-radius: 999px;
    background: #edf1f8;
    overflow: hidden;
}

.quiniela-progress-bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--primary);
    transition: width .16s ease;
}

.quiniela-card-logo {
    background: linear-gradient(135deg, #0c7c3c, #d7f5dd);
    color: #ffffff;
    border-radius: 22px;
    min-height: 124px;
}

.quiniela-card-logo span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    border-radius: 999px;
    background: rgba(255,255,255,.18);
    border: 1px solid rgba(255,255,255,.32);
    color: #ffffff;
    font-size: 2rem;
    font-weight: 950;
    letter-spacing: -.04em;
    box-shadow: 0 12px 34px rgba(8, 90, 42, .18);
}

.quiniela-selector-card {
    border-color: #bfe7ca;
}

.disabled-link {
    opacity: .55;
    pointer-events: none;
    cursor: not-allowed;
}

@media (max-width: 1180px) {
    .quiniela-hero,
    .quiniela-main-grid {
        grid-template-columns: 1fr;
    }

    .quiniela-toolbar {
        justify-content: flex-start;
        min-width: 0;
    }
}

@media (max-width: 980px) {
    .quiniela-metrics {
        grid-template-columns: repeat(2, minmax(150px, 1fr));
    }
}

@media (max-width: 640px) {
    .quiniela-toolbar,
    .quiniela-toolbar .button,
    .quiniela-toolbar button {
        width: 100%;
    }

    .quiniela-metrics {
        grid-template-columns: 1fr;
    }

    .quiniela-sign-strip {
        overflow-x: auto;
        max-width: 100%;
        padding-bottom: 4px;
    }
}


/* v63 Quiniela branding + dashboard style alignment */
.lottery-card.lottery-quiniela,
.quiniela-page.lottery-quiniela {
    --lottery-accent: #d31f26;
    --lottery-accent-strong: #af171d;
    --lottery-surface: #fff1f1;
}

.lottery-card.lottery-quiniela {
    --card-accent: var(--lottery-accent);
}

.quiniela-dashboard-summary {
    border-left-color: var(--lottery-accent);
}

.quiniela-dashboard-logo {
    width: min(240px, 36%);
    max-height: 156px;
}

.quiniela-page-toolbar {
    margin: 16px 0 0;
    justify-content: flex-end;
}

.quiniela-summary-grid {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
}

.quiniela-latest-panel {
    margin-top: 18px;
}

.quiniela-latest-aux-list {
    align-content: start;
}

.quiniela-latest-aux-list a {
    color: var(--lottery-accent-strong);
    font-weight: 700;
}

.quiniela-card-logo {
    background: linear-gradient(135deg, #fff5f5, #ffe2e3);
    border: 1px solid #f1c3c5;
    color: #d31f26;
    border-radius: 22px;
    min-height: 124px;
}

.quiniela-card-logo img {
    width: 100%;
    max-width: 188px;
    max-height: 96px;
    object-fit: contain;
    object-position: center center;
    filter: drop-shadow(0 12px 24px rgba(160, 18, 26, .12));
}

.quiniela-selector-card {
    border-color: #f0c2c6;
}

.quiniela-sign {
    border-color: color-mix(in srgb, var(--lottery-accent) 18%, var(--border));
    background: #fff1f1;
    color: var(--lottery-accent-strong);
}

.quiniela-sign.sign-x {
    background: #fff7e8;
    border-color: #efc767;
    color: #9d6b00;
}

.quiniela-sign.sign-2 {
    background: #eefaf2;
    border-color: #79c596;
    color: #126734;
}

.quiniela-progress-bar span {
    background: var(--lottery-accent);
}

@media (max-width: 1180px) {
    .quiniela-summary-grid {
        grid-template-columns: repeat(2, minmax(160px, 1fr));
    }
}

@media (max-width: 720px) {
    .quiniela-summary-grid {
        grid-template-columns: 1fr;
    }

    .quiniela-page-toolbar {
        justify-content: stretch;
    }
}

/* v65 Quiniela yearly range import controls */
.quiniela-range-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: end;
    margin-top: 16px;
    border-left: 7px solid var(--lottery-accent, #d31f26);
}

.quiniela-range-panel h2 {
    margin: 4px 0 6px;
}

.quiniela-range-controls {
    display: flex;
    gap: 12px;
    align-items: end;
    flex-wrap: wrap;
}

.quiniela-range-controls label {
    display: grid;
    gap: 6px;
    min-width: 132px;
    color: var(--muted);
    font-size: .82rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.quiniela-range-controls input {
    min-height: 42px;
    border-radius: 14px;
    border: 1px solid var(--border);
    padding: 9px 12px;
    color: var(--text);
    background: #ffffff;
    font-size: 1rem;
    font-weight: 900;
}

@media (max-width: 820px) {
    .quiniela-range-panel {
        grid-template-columns: 1fr;
    }

    .quiniela-range-controls,
    .quiniela-range-controls label {
        width: 100%;
    }
}


/* v72 Quiniela PDF import: annulled/unknown historical signs */
.quiniela-sign.sign-empty {
    background: #f3f4f6;
    border-color: #cbd5e1;
    color: #64748b;
}

/* La Quiniela: módulo deportivo independiente */
.menu-quiniela .menu-heading,
.lottery-menu.menu-quiniela a.active,
.lottery-menu.menu-quiniela a:hover {
    border-color: rgba(46, 125, 50, .35);
}

.menu-quiniela .menu-heading strong,
.lottery-shell.lottery-quiniela .brand-copy strong {
    color: #184d25;
}

.lottery-shell.lottery-quiniela .sidebar-footer strong {
    color: #184d25;
}

.badge-soft {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: .22rem .55rem;
    border-radius: 999px;
    background: rgba(15, 23, 42, .06);
    font-size: .78rem;
    font-weight: 700;
    color: #334155;
    white-space: nowrap;
}

.quiniela-page ul {
    margin: .7rem 0 0;
    padding-left: 1.2rem;
}

.quiniela-page li + li {
    margin-top: .35rem;
}

/* v75 fix3: tarjetas de carga inicial y apertura más anchas y homogéneas */
.loading-card {
    width: min(640px, calc(100vw - 36px)) !important;
    min-height: 430px !important;
    grid-template-rows: auto auto auto auto 1fr !important;
    align-content: center !important;
    gap: 14px !important;
    padding: 28px 32px 26px !important;
}

.loading-card strong {
    max-width: 100% !important;
    font-size: 1.22rem !important;
    line-height: 1.18 !important;
}

.loading-card span {
    max-width: 560px !important;
    width: 100% !important;
    line-height: 1.35 !important;
}

.loading-progress {
    width: min(520px, 100%) !important;
}

.loading-progress-text {
    width: 100% !important;
}

.loading-logo-shell {
    width: min(260px, 62vw) !important;
}

@media (max-width: 640px) {
    .loading-card {
        width: min(420px, calc(100vw - 24px)) !important;
        min-height: 390px !important;
        gap: 11px !important;
        padding: 22px 18px 20px !important;
    }

    .loading-card span {
        max-width: 100% !important;
        font-size: .9rem !important;
    }

    .loading-progress {
        width: 100% !important;
    }
}

/* v75 fix5: popup de carga inicial más amplio para todos los sorteos */
.loading-card {
    width: min(760px, calc(100vw - 40px)) !important;
    min-height: 470px !important;
    padding: 34px 42px 32px !important;
    gap: 16px !important;
}

.loading-card span {
    max-width: 680px !important;
    font-size: 1rem !important;
    line-height: 1.38 !important;
}

.loading-card strong {
    font-size: 1.32rem !important;
}

.loading-progress {
    width: min(640px, 100%) !important;
}

.loading-logo-shell {
    width: min(300px, 66vw) !important;
}

@media (max-width: 760px) {
    .loading-card {
        width: min(520px, calc(100vw - 24px)) !important;
        min-height: 430px !important;
        padding: 26px 22px 24px !important;
        gap: 13px !important;
    }

    .loading-card strong {
        font-size: 1.18rem !important;
    }

    .loading-card span {
        max-width: 100% !important;
        font-size: .94rem !important;
    }
}

/* Quiniela Pro - ajustes visuales fix6 */
.single-field {
    grid-template-columns: minmax(280px, 1fr);
    margin-top: 1rem;
}

.checkbox-card {
    display: flex;
    align-items: center;
    gap: .75rem;
    min-height: 42px;
    padding: .75rem 1rem;
    border: 1px solid var(--border, #dbe4f5);
    border-radius: 14px;
    background: rgba(248, 251, 255, .9);
}

.checkbox-card input {
    width: auto;
}

button.success,
.button.success {
    background: #23833b;
    border-color: #23833b;
    color: #fff;
}

.target-reading-card {
    margin-top: 5rem;
    max-width: 720px;
}

.target-parameters-panel .form-grid,
.target-objective-panel .form-grid {
    gap: 1rem;
}

/* fix7 - Quiniela simulacion objetivo: tarjetas proporcionadas y sin metricas estrechas */
.target-objective-panel,
.target-parameters-panel {
    min-height: 560px;
}

.target-objective-panel {
    display: flex;
    flex-direction: column;
}

.target-reading-card {
    margin-top: 3.25rem;
    width: 100%;
    max-width: none;
    padding: 1.35rem 1.5rem;
    border: 1px solid var(--border, #dbe4f5);
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(248,251,255,.96));
    box-shadow: 0 18px 38px rgba(15, 35, 70, .08);
}

.target-reading-card .badge-soft {
    display: inline-flex;
    width: auto;
    max-width: max-content;
    margin-bottom: .65rem;
}

.target-reading-card h3 {
    margin: .2rem 0 .65rem;
}

.target-reading-card p {
    max-width: 760px;
}

.target-reading-card .metrics-grid.generator-result-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(110px, 1fr));
    gap: 12px;
    margin: 1rem 0 0;
}

.target-reading-card .metrics-grid.generator-result-metrics > .metric-card {
    grid-column: auto;
    min-height: 76px;
    padding: 12px 14px;
}

.target-reading-card .metrics-grid.generator-result-metrics > .metric-card .metric-label {
    font-size: .78rem;
}

.target-reading-card .metrics-grid.generator-result-metrics > .metric-card strong {
    font-size: 1.15rem;
    overflow: visible;
}

.metrics-grid.target-objective-metrics {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    margin-top: 0;
}

.metrics-grid.target-objective-metrics > .metric-card {
    min-height: 82px;
}

.metrics-grid.target-objective-metrics > .metric-card strong {
    overflow-x: hidden;
    text-overflow: ellipsis;
}

.target-parameters-panel .toolbar.simulation-actions {
    margin-top: 1rem;
    align-items: center;
}

@media (max-width: 980px) {
    .target-objective-panel,
    .target-parameters-panel {
        min-height: 0;
    }

    .target-reading-card {
        margin-top: 1.5rem;
    }

    .target-reading-card .metrics-grid.generator-result-metrics {
        display: grid;
        grid-template-columns: repeat(2, minmax(120px, 1fr));
        overflow: visible;
    }
}

/* fix8/fix11 - Quiniela: vista tipo boleto real 1X2 */
.quiniela-ticket-shell {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    padding: .25rem 0 .5rem;
}

.quiniela-ticket-shell.full-width-ticket {
    width: 100%;
}

.quiniela-real-ticket {
    min-width: var(--ticket-width, 760px);
    width: max-content;
    max-width: none;
    border: 1px solid #d7e2f4;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 18px 38px rgba(15, 35, 70, .08);
    overflow: hidden;
}

.quiniela-real-ticket-header {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .75rem 1rem;
    background: #16498f;
    color: #fff;
    font-weight: 900;
    letter-spacing: .02em;
}

.quiniela-real-ticket-header span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2rem;
    height: 2rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, .16);
    font-size: .82rem;
}

.quiniela-real-ticket-grid {
    display: grid;
    grid-template-columns: minmax(310px, 1.8fr) repeat(var(--ticket-columns, 6), minmax(84px, .72fr));
    gap: 0;
    padding: .75rem 1rem 1rem;
}

.quiniela-real-ticket-grid:has(.ticket-column-title:nth-child(2):last-child) {
    grid-template-columns: minmax(310px, 1.8fr) minmax(120px, .85fr);
}

.ticket-cell,
.ticket-match-cell,
.ticket-sign-group,
.ticket-pleno-box {
    min-height: 30px;
    border-bottom: 1px solid rgba(239, 68, 68, .32);
}

.ticket-round {
    display: flex;
    align-items: center;
    color: #e11d1d;
    font-size: .86rem;
    font-weight: 900;
    text-transform: uppercase;
}

.ticket-column-title {
    display: flex;
    align-items: center;
    justify-content: center;
    border-left: 3px solid rgba(239, 68, 68, .38);
    color: #ef6f6a;
    font-size: .86rem;
    font-weight: 900;
}

.ticket-match-cell {
    display: grid;
    grid-template-columns: 2rem 1fr;
    align-items: center;
    gap: .35rem;
    padding-right: .45rem;
}

.ticket-match-number {
    color: #0f4c9d;
    font-weight: 800;
    text-align: right;
    font-size: .8rem;
}

.ticket-match-name {
    color: #0f3f8f;
    font-weight: 700;
    font-size: .78rem;
    text-transform: uppercase;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ticket-sign-group {
    display: grid;
    grid-template-columns: repeat(3, minmax(20px, 1fr));
    border-left: 3px solid rgba(239, 68, 68, .38);
    align-items: center;
    justify-items: center;
    padding: 3px 4px;
    gap: 2px;
}

.ticket-sign {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.35rem;
    height: 1.35rem;
    border: 1px solid rgba(239, 68, 68, .3);
    border-radius: 3px;
    color: #f29b95;
    font-size: .78rem;
    font-weight: 900;
    background: #fff;
}

.ticket-sign.selected {
    background: #e53935;
    border-color: #e53935;
    color: #fff;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .35);
}

.ticket-pleno-cell {
    min-height: 46px;
    border-bottom: 0;
}

.ticket-pleno-box {
    display: flex;
    border-left: 3px solid rgba(239, 68, 68, .38);
    align-items: center;
    justify-content: center;
    color: #e53935;
    font-weight: 900;
    font-size: .78rem;
    border-bottom: 0;
}

.compact-ticket .quiniela-real-ticket {
    min-width: 520px;
    max-width: 680px;
}

.compact-ticket .quiniela-real-ticket-grid {
    grid-template-columns: minmax(310px, 1.8fr) minmax(120px, .85fr);
}

@media (max-width: 900px) {
    .quiniela-real-ticket {
        min-width: 720px;
    }
}

/* fix12 - Dashboard Quiniela: ultima jornada en formato boleto */
.dashboard-ticket .quiniela-real-ticket {
    min-width: 620px;
    width: 100%;
}

.dashboard-ticket .quiniela-real-ticket-grid {
    grid-template-columns: minmax(360px, 1.8fr) minmax(130px, .85fr);
}


/* fix13 - Dashboard Quiniela: centrar boleto y ampliar frecuencia */
.quiniela-main-grid {
    align-items: start;
}

.dashboard-ticket {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    width: 100%;
}

.dashboard-ticket .quiniela-real-ticket {
    width: min(100%, 680px);
    min-width: 620px;
}

.quiniela-history-controls {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    gap: .85rem;
    margin: 0;
    flex-wrap: wrap;
}

.quiniela-history-controls label {
    display: grid;
    gap: .35rem;
    min-width: 150px;
}

.quiniela-history-controls label span {
    color: var(--muted);
    font-size: .82rem;
    font-weight: 800;
}

.quiniela-history-controls select {
    min-height: 40px;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 8px 10px;
    background: #fff;
    color: var(--text);
}

/* Quiniela dashboard: paged recent draws and ticket modal */
.quiniela-history-pagination {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: .75rem;
    margin-top: .85rem;
    flex-wrap: wrap;
}

.quiniela-history-pagination span {
    color: var(--muted);
    font-size: .9rem;
    font-weight: 800;
}

.ssl-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(15, 23, 42, .58);
}

.ssl-modal {
    width: min(94vw, 820px);
    max-height: 90vh;
    overflow: auto;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, .42);
    background: #fff;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .28);
    padding: 1rem;
}

.ssl-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: .9rem;
}

.ssl-modal-header h2 {
    margin: .15rem 0 0;
}

.history-ticket {
    justify-content: flex-start;
}

.history-ticket .quiniela-real-ticket {
    width: min(100%, 680px);
    min-width: 620px;
}

.history-ticket-modal {
    justify-content: center;
    display: flex;
    width: 100%;
}

.history-ticket-modal .quiniela-real-ticket {
    margin-inline: auto;
}

.quiniela-frequency-panel {
    min-width: 560px;
}

.quiniela-frequency-table {
    overflow-x: visible;
}

.quiniela-frequency-table table {
    width: 100%;
}

.quiniela-frequency-table th,
.quiniela-frequency-table td {
    padding-left: .85rem;
    padding-right: .85rem;
}

@media (max-width: 1260px) {
    .quiniela-main-grid {
        grid-template-columns: 1fr;
    }

    .quiniela-frequency-panel {
        min-width: 0;
    }
}

@media (max-width: 720px) {
    .dashboard-ticket {
        justify-content: flex-start;
    }

    .dashboard-ticket .quiniela-real-ticket {
        width: max-content;
    }

    .quiniela-frequency-table {
        overflow-x: auto;
    }
}

/* fix15 - Quiniela: mantener partidos visibles y desplazar solo apuestas */
.quiniela-ticket-shell {
    overflow-x: auto;
    overflow-y: hidden;
}

.quiniela-real-ticket-grid > .ticket-round,
.quiniela-real-ticket-grid > .ticket-match-cell {
    position: sticky;
    left: 0;
    z-index: 3;
    background: #fff;
    box-shadow: 8px 0 12px rgba(15, 35, 70, .06);
}

.quiniela-real-ticket-grid > .ticket-round {
    z-index: 4;
}

.quiniela-real-ticket-grid > .ticket-match-cell::after,
.quiniela-real-ticket-grid > .ticket-round::after {
    content: "";
    position: absolute;
    top: 0;
    right: -1px;
    width: 3px;
    height: 100%;
    background: rgba(239, 68, 68, .42);
}

.quiniela-real-ticket-grid > .ticket-sign-group,
.quiniela-real-ticket-grid > .ticket-column-title,
.quiniela-real-ticket-grid > .ticket-pleno-box {
    min-width: 84px;
}

.full-width-ticket .quiniela-real-ticket {
    width: max-content;
}

/* fix16 - Quiniela simulacion objetivo: lectura y botones operativos */
.quiniela-target-card-fill {
    min-height: 260px;
    align-items: center;
}

.quiniela-target-reading-card {
    width: min(820px, 100%);
}

.quiniela-target-reading-card p {
    color: var(--muted);
    margin: 0 0 12px;
}

.quiniela-target-insight-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.quiniela-simulation-status {
    margin-top: .9rem;
}

@media (max-width: 980px) {
    .quiniela-target-insight-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* fix17 - Generador Quiniela: scroll solo en apuestas, partidos fuera del contenedor desplazable */
.full-width-ticket.quiniela-ticket-shell {
    overflow-x: visible;
    overflow-y: visible;
}

.full-width-ticket .quiniela-real-ticket-split {
    width: 100%;
    min-width: 0;
    max-width: 100%;
}

.quiniela-ticket-split-body {
    display: grid;
    grid-template-columns: minmax(320px, 410px) minmax(0, 1fr);
    padding: .75rem 1rem 1rem;
}

.quiniela-ticket-fixed-matches {
    position: relative;
    z-index: 2;
    background: #fff;
    border-right: 3px solid rgba(239, 68, 68, .42);
    box-shadow: 8px 0 12px rgba(15, 35, 70, .06);
}

.quiniela-ticket-bets-scroll {
    overflow-x: auto;
    overflow-y: hidden;
    min-width: 0;
    max-width: 100%;
    padding-bottom: .35rem;
}

.quiniela-ticket-bets-grid {
    display: grid;
    grid-template-columns: repeat(var(--ticket-columns, 6), minmax(84px, 84px));
    width: max-content;
    min-width: var(--ticket-scroll-width, 520px);
}

.quiniela-ticket-fixed-matches .ticket-round,
.quiniela-ticket-fixed-matches .ticket-match-cell {
    position: static;
    box-shadow: none;
}

.quiniela-ticket-fixed-matches .ticket-match-cell::after,
.quiniela-ticket-fixed-matches .ticket-round::after {
    content: none;
}

@media (max-width: 760px) {
    .quiniela-ticket-split-body {
        grid-template-columns: minmax(260px, 300px) minmax(0, 1fr);
        padding-left: .75rem;
        padding-right: .75rem;
    }

    .quiniela-ticket-fixed-matches .ticket-match-name {
        font-size: .72rem;
    }
}

/* fix18 - Generador Quiniela: separacion visual entre apuestas del boleto */
.quiniela-ticket-bets-grid {
    grid-template-columns: repeat(var(--ticket-columns, 6), minmax(92px, 92px));
    column-gap: 8px;
    padding-left: 8px;
}

.quiniela-ticket-bets-grid > .ticket-column-title,
.quiniela-ticket-bets-grid > .ticket-sign-group,
.quiniela-ticket-bets-grid > .ticket-pleno-box {
    border-left-width: 2px;
    border-radius: 4px 0 0 4px;
}

.quiniela-ticket-bets-grid > .ticket-column-title {
    background: linear-gradient(90deg, rgba(239, 68, 68, .045), transparent 65%);
}

/* Real lottery ticket shared view */
.real-ticket-shell {
    width: 100%;
    display: flex;
    justify-content: center;
    overflow-x: auto;
    padding: .35rem 0 .55rem;
}

.real-ticket-shell.centered-real-ticket {
    justify-content: center;
}

.real-ticket {
    width: min(100%, 980px);
    background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(248,250,252,.96));
    border: 1px solid rgba(15, 23, 42, .12);
    border-radius: 22px;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .10);
    padding: 1rem;
}

.real-ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    border-bottom: 1px dashed rgba(15, 23, 42, .20);
    padding-bottom: .75rem;
    margin-bottom: .85rem;
}

.real-ticket-header span,
.real-ticket-header small {
    display: block;
    color: var(--muted);
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.real-ticket-header strong {
    display: block;
    font-size: 1.12rem;
    color: var(--text);
}

.real-ticket-plays {
    display: flex;
    gap: .9rem;
    justify-content: center;
    overflow-x: auto;
    padding-bottom: .25rem;
}

.real-ticket-play {
    flex: 0 0 auto;
    width: min(100%, 430px);
    border: 1px solid rgba(15, 23, 42, .10);
    border-radius: 18px;
    background: rgba(255,255,255,.78);
    padding: .75rem;
}

.real-ticket-play-title {
    text-align: center;
    font-weight: 800;
    margin-bottom: .6rem;
    color: var(--text);
}

.real-ticket-number-grid {
    display: grid;
    grid-template-columns: repeat(var(--ticket-number-columns, 10), 1fr);
    gap: .38rem;
}

.real-ticket-number {
    min-width: 0;
    aspect-ratio: 1;
    border: 1px solid rgba(15, 23, 42, .18);
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: .78rem;
    font-weight: 700;
    color: var(--muted);
    background: #fff;
}

.real-ticket-number.selected {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
    box-shadow: 0 8px 18px rgba(15, 23, 42, .16);
}

.real-ticket-selected-line {
    margin-top: .65rem;
    text-align: center;
    font-weight: 800;
    color: var(--text);
}

.real-ticket-auxiliaries {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .6rem;
    border-top: 1px dashed rgba(15, 23, 42, .18);
    margin-top: .85rem;
    padding-top: .85rem;
}

.real-ticket-auxiliaries span {
    min-width: 96px;
    border: 1px solid rgba(15, 23, 42, .12);
    border-radius: 16px;
    padding: .45rem .65rem;
    background: rgba(255,255,255,.8);
    text-align: center;
}

.real-ticket-auxiliaries small {
    display: block;
    color: var(--muted);
    font-size: .72rem;
}

.real-ticket-auxiliaries strong {
    display: block;
    color: var(--text);
}

.real-ticket-empty {
    color: var(--muted);
    padding: 1rem;
}

.compact-real-ticket .real-ticket {
    max-width: 760px;
}

.compact-real-ticket .real-ticket-play {
    width: min(100%, 390px);
}

.dashboard-real-ticket-wrap {
    margin-top: 1rem;
}

@media (max-width: 720px) {
    .real-ticket {
        min-width: 520px;
    }

    .real-ticket-shell {
        justify-content: flex-start;
    }
}

/* fix23 - Boleto real por sorteo basado en formato original */
.real-ticket-shell {
    width: 100%;
    display: flex;
    justify-content: center;
    overflow-x: auto;
    padding: .35rem 0 .55rem;
}

.real-ticket-shell.centered-real-ticket {
    justify-content: center;
}

.real-ticket {
    width: auto;
    max-width: 100%;
    background: #fff;
    border: 1px solid rgba(15, 23, 42, .12);
    border-radius: 0;
    box-shadow: 0 18px 42px rgba(15, 23, 42, .10);
    padding: 0 10px 14px;
    color: #00408f;
    overflow: hidden;
}

.original-ticket-header {
    margin: 0 -10px 0;
    padding: 8px 12px;
    background: #154a8f;
    color: #fff;
    border-bottom: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.original-ticket-header strong {
    color: #fff;
    font-size: .98rem;
    line-height: 1.15;
    text-transform: uppercase;
}

.original-ticket-date {
    color: #ff1b0f;
    font-weight: 800;
    font-size: .82rem;
    text-transform: uppercase;
    padding: 10px 4px 7px;
    border-bottom: 1px solid #ff3d32;
    margin-bottom: 10px;
    white-space: nowrap;
}

.original-ticket-plays {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    gap: 18px;
    align-items: start;
    overflow-x: auto;
    padding: 0 0 4px;
    scrollbar-width: thin;
}

.original-ticket-play {
    position: relative;
    min-width: max-content;
    padding-top: 0;
}

.original-ticket-play-number {
    position: absolute;
    left: 2px;
    top: 2px;
    z-index: 1;
    color: #ffb7b2;
    font-size: 1.05rem;
    font-weight: 800;
    line-height: 1;
}

.original-ticket-main-grid {
    display: grid;
    grid-template-columns: repeat(var(--ticket-main-columns), 22px);
    grid-auto-rows: 22px;
    border-left: 2px solid #ffb8b2;
    border-top: 2px solid #ffb8b2;
    background: #fff4f2;
}

.original-ticket-cell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-right: 2px solid #ffb8b2;
    border-bottom: 2px solid #ffb8b2;
    color: #ffaaa3;
    font-size: .76rem;
    font-weight: 700;
    line-height: 1;
    background: #fffafa;
}

.original-ticket-cell.empty {
    background: #fffafa;
    color: transparent;
}

.original-ticket-cell.selected {
    color: #00408f;
    background: #ffe4e0;
    border-color: #ff9b94;
    font-weight: 900;
    box-shadow: inset 0 0 0 1px rgba(0, 64, 143, .06);
}

.original-ticket-aux-blocks {
    margin-top: 9px;
    display: grid;
    gap: 7px;
}

.original-ticket-aux-label {
    color: #ffb4ad;
    font-size: .62rem;
    font-weight: 800;
    text-transform: uppercase;
    margin: 0 0 2px 2px;
}

.original-ticket-aux-grid {
    display: grid;
    grid-template-columns: repeat(var(--ticket-aux-columns), 22px);
    grid-auto-rows: 22px;
    border-left: 2px solid #ffb8b2;
    border-top: 2px solid #ffb8b2;
    background: #fffafa;
}

.original-ticket-aux-cell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-right: 2px solid #ffb8b2;
    border-bottom: 2px solid #ffb8b2;
    color: #ffaaa3;
    font-size: .76rem;
    font-weight: 700;
    background: #fffafa;
}

.original-ticket-aux-cell.selected {
    color: #00408f;
    background: #ffe4e0;
    border-color: #ff9b94;
    font-weight: 900;
}

.original-ticket-auto {
    color: #ff1b0f;
    text-align: center;
    font-size: .6rem;
    font-weight: 900;
    margin-top: 4px;
}

.real-ticket-euromillones .original-ticket-aux-pair .original-ticket-aux-grid,
.real-ticket-euromillones .original-ticket-aux-pair .original-ticket-aux-cell,
.real-ticket-euromillones .original-ticket-aux-estrella-1 .original-ticket-aux-grid,
.real-ticket-euromillones .original-ticket-aux-estrella-1 .original-ticket-aux-cell,
.real-ticket-euromillones .original-ticket-aux-estrella-2 .original-ticket-aux-grid,
.real-ticket-euromillones .original-ticket-aux-estrella-2 .original-ticket-aux-cell {
    background: #fff36f;
}

.real-ticket-euromillones .original-ticket-aux-pair .original-ticket-aux-cell,
.real-ticket-euromillones .original-ticket-aux-estrella-1 .original-ticket-aux-cell,
.real-ticket-euromillones .original-ticket-aux-estrella-2 .original-ticket-aux-cell {
    clip-path: polygon(50% 4%, 61% 35%, 95% 35%, 68% 55%, 78% 88%, 50% 68%, 22% 88%, 32% 55%, 5% 35%, 39% 35%);
    border: 0;
    margin: 1px;
    background: #fff;
    color: #ffaaa3;
}

.real-ticket-euromillones .original-ticket-aux-pair .original-ticket-aux-cell.selected,
.real-ticket-euromillones .original-ticket-aux-estrella-1 .original-ticket-aux-cell.selected,
.real-ticket-euromillones .original-ticket-aux-estrella-2 .original-ticket-aux-cell.selected {
    background: #fff;
    color: #00408f;
}

.real-ticket-eurodreams .original-ticket-aux-sueño .original-ticket-aux-grid,
.real-ticket-eurodreams .original-ticket-aux-sueño .original-ticket-aux-cell {
    background: #fffafa;
}

.real-ticket-lototurf .original-ticket-cell.selected,
.real-ticket-lototurf .original-ticket-aux-cell.selected {
    color: #00346f;
    background: #fff;
    border-color: #e87927;
    outline: 2px solid #e87927;
    outline-offset: -3px;
}

.compact-real-ticket .real-ticket {
    max-width: 100%;
}

@media (max-width: 720px) {
    .real-ticket {
        min-width: 0;
    }

    .real-ticket-shell {
        justify-content: flex-start;
    }
}

/* fix24 - Quiniela: espacio equilibrado antes y despues de la barra separadora entre apuestas */
.quiniela-ticket-bets-grid {
    grid-template-columns: repeat(var(--ticket-columns, 6), minmax(108px, 108px));
    column-gap: 10px;
    padding-left: 10px;
}

.quiniela-ticket-bets-grid > .ticket-column-title,
.quiniela-ticket-bets-grid > .ticket-sign-group,
.quiniela-ticket-bets-grid > .ticket-pleno-box {
    box-sizing: border-box;
    padding-left: 10px;
    padding-right: 10px;
}

.quiniela-ticket-bets-grid > .ticket-sign-group {
    gap: 4px;
}

/* fix25 - Quiniela estrategias: tarjetas de distribución y parametrización */
.quiniela-distribution-cards {
    display: grid;
    grid-template-columns: repeat(4, minmax(130px, 1fr));
    gap: 14px;
    align-items: stretch;
}

.quiniela-distribution-card {
    min-height: 86px;
    border: 1px solid var(--border, #d8e2f3);
    border-radius: 16px;
    background: #fff;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
}

.quiniela-distribution-card span {
    color: var(--muted, #5b6a8a);
    font-size: .82rem;
    white-space: nowrap;
}

.quiniela-distribution-card strong {
    color: var(--ink, #081a3a);
    font-size: 1.3rem;
    line-height: 1.15;
    white-space: nowrap;
}

.quiniela-strategy-params-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 14px;
    margin-top: 16px;
}

.quiniela-strategy-param-card {
    border: 1px solid var(--border, #d8e2f3);
    border-radius: 18px;
    background: #fff;
    padding: 16px;
    display: grid;
    gap: 10px;
}

.strategy-param-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.strategy-param-header span {
    border-radius: 999px;
    border: 1px solid var(--border, #d8e2f3);
    padding: 4px 9px;
    font-size: .75rem;
    color: var(--muted, #5b6a8a);
    white-space: nowrap;
}

.quiniela-strategy-param-card label {
    display: grid;
    gap: 5px;
}

.quiniela-strategy-param-card input[type="number"] {
    width: 100%;
}

.quiniela-strategy-param-card small {
    color: var(--muted, #5b6a8a);
}

.section-subtitle {
    margin-top: 24px;
}

.quiniela-import-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.quiniela-import-defaults {
    margin-top: 14px;
}

@media (max-width: 900px) {
    .quiniela-distribution-cards {
        grid-template-columns: repeat(2, minmax(130px, 1fr));
    }
}

@media (max-width: 540px) {
    .quiniela-distribution-cards,
    .quiniela-strategy-params-grid {
        grid-template-columns: 1fr;
    }
}

/* fix29 - Simulacion objetivo: auxiliares del boleto a la derecha */
.target-objective-ticket .real-ticket {
    max-width: none;
}

.target-objective-ticket .original-ticket-plays {
    display: block;
    overflow-x: visible;
    padding-bottom: 0;
}

.target-objective-ticket .original-ticket-play {
    display: grid;
    grid-template-columns: max-content max-content;
    grid-template-areas:
        "main aux"
        "auto auto";
    column-gap: 16px;
    align-items: start;
}

.target-objective-ticket .original-ticket-main-block {
    grid-area: main;
}

.target-objective-ticket .original-ticket-aux-blocks {
    grid-area: aux;
    margin-top: 0;
    align-self: start;
}

.target-objective-ticket .original-ticket-auto {
    grid-area: auto;
}

@media (max-width: 720px) {
    .target-objective-ticket .original-ticket-play {
        grid-template-columns: max-content;
        grid-template-areas:
            "main"
            "aux"
            "auto";
        row-gap: 8px;
    }
}

/* fix30 - Simulacion objetivo: bloques del boleto a la derecha en columnas alineadas */
.target-objective-ticket .original-ticket-play {
    grid-template-columns: max-content max-content;
    align-items: start;
}

.target-objective-ticket .original-ticket-aux-blocks {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    grid-template-rows: none;
    gap: 16px;
    align-items: start;
    align-content: start;
}

.target-objective-ticket .original-ticket-aux-block {
    align-self: start;
}

.target-objective-ticket .original-ticket-aux-label {
    min-height: 14px;
}

.target-objective-ticket .original-ticket-auto {
    justify-self: start;
    width: 100%;
    text-align: center;
}

@media (max-width: 720px) {
    .target-objective-ticket .original-ticket-aux-blocks {
        grid-auto-flow: row;
        gap: 8px;
    }
}


/* fix31 - Simulacion objetivo: cabecera Objetivo alineada con auxiliares */
.original-ticket-main-block {
    grid-area: main;
}

.original-ticket-main-label {
    display: none;
    color: #ffb4ad;
    font-size: .62rem;
    font-weight: 800;
    text-transform: uppercase;
    margin: 0 0 2px 2px;
    min-height: 14px;
}

.target-objective-ticket .original-ticket-main-label {
    display: block;
}

.target-objective-ticket .original-ticket-main-grid {
    grid-area: auto;
}


/* fix32 Quiniela import layout: full-width tab content and default restore */
.quiniela-import-tabs {
    width: 100%;
}

.quiniela-range-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    gap: 18px;
    width: 100%;
}

.quiniela-range-panel > div {
    min-width: 0;
}

.quiniela-range-panel p,
.quiniela-range-panel h2,
.quiniela-range-panel .selector-kicker {
    max-width: 980px;
    overflow-wrap: normal;
    word-break: normal;
}

.quiniela-range-controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(220px, 320px));
    justify-content: start;
    align-items: end;
    gap: 14px;
    width: 100%;
}

.quiniela-range-controls label {
    min-width: 0;
    width: 100%;
}

.quiniela-import-presets {
    width: 100%;
}

.quiniela-import-defaults {
    max-width: 980px;
}

.panel-title-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

.panel-title-row h2 {
    margin-top: 0;
}

.quiniela-default-values-panel .table-wrap {
    width: 100%;
}

@media (max-width: 720px) {
    .quiniela-range-controls {
        grid-template-columns: 1fr;
    }

    .panel-title-row {
        display: grid;
    }
}



.access-page {
    min-height: 100vh;
    width: 100%;
    position: relative;
    overflow: hidden;
    padding: clamp(28px, 4vw, 64px);
    background:
        radial-gradient(circle at 8% 12%, rgba(49, 87, 255, .28), transparent 32%),
        radial-gradient(circle at 92% 10%, rgba(34, 197, 94, .20), transparent 30%),
        radial-gradient(circle at 74% 88%, rgba(245, 158, 11, .16), transparent 34%),
        linear-gradient(135deg, #071126 0%, #0d1b3d 46%, #f7faff 46%, #edf3fb 100%);
}
.access-landing { display: flex; align-items: stretch; }
.access-background-orb { position: absolute; border-radius: 999px; pointer-events: none; filter: blur(.2px); }
.access-background-orb.orb-one { width: 420px; height: 420px; left: -180px; bottom: -180px; border: 52px solid rgba(255,255,255,.06); }
.access-background-orb.orb-two { width: 260px; height: 260px; right: 9vw; top: 7vh; background: rgba(255,255,255,.38); box-shadow: 0 24px 90px rgba(49, 87, 255, .18); }
.access-landing-content { position: relative; z-index: 1; width: 100%; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(380px, .65fr); gap: clamp(28px, 4vw, 72px); align-items: center; }
.access-copy { color: #fff; max-width: 980px; display: grid; gap: 24px; }
.access-kicker { width: fit-content; padding: 8px 14px; border-radius: 999px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.18); color: #dbe6ff; font-size: .78rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.access-copy h1 { max-width: 980px; margin: 0; font-size: clamp(2.6rem, 6vw, 6.8rem); line-height: .92; letter-spacing: -.065em; }
.access-lead { max-width: 760px; margin: 0; color: rgba(255,255,255,.82); font-size: clamp(1rem, 1.5vw, 1.28rem); line-height: 1.65; }
.access-highlights { width: min(960px, 100%); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.access-highlights article { min-height: 132px; padding: 20px; border-radius: 24px; background: rgba(255,255,255,.10); border: 1px solid rgba(255,255,255,.16); box-shadow: 0 20px 70px rgba(0,0,0,.14); backdrop-filter: blur(12px); display: grid; align-content: start; gap: 9px; }
.access-highlights strong { color: #fff; font-size: 1.02rem; }
.access-highlights span { color: rgba(255,255,255,.76); line-height: 1.5; font-size: .92rem; }
.access-form-area { justify-self: end; width: min(460px, 100%); padding: clamp(26px, 3vw, 38px); border-radius: 34px; background: rgba(255,255,255,.88); border: 1px solid rgba(255,255,255,.72); box-shadow: 0 28px 90px rgba(15, 30, 64, .22); backdrop-filter: blur(18px); display: grid; align-content: center; }
.access-shell, .access-hero, .access-card { width: auto; }
.access-brand { display: grid; gap: 8px; margin-bottom: 12px; }
.access-badge { width: fit-content; padding: 7px 12px; border-radius: 999px; background: #edf3ff; color: #3157ff; font-weight: 900; font-size: .76rem; letter-spacing: .04em; text-transform: uppercase; }
.access-brand h2 { margin: 0; font-size: clamp(2rem, 3vw, 2.8rem); letter-spacing: -.045em; color: #0b1636; }
.access-brand p { margin: 0; color: #4d5d7a; line-height: 1.45; }
.access-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 18px 0 12px; padding: 7px; border-radius: 18px; background: #eef3ff; border: 1px solid #d7e2ff; }
.access-tabs button { min-height: 42px; padding: 9px 18px; border-radius: 14px; justify-content: center; }
.access-tabs button.active { border-color: #3157ff; color: #3157ff; font-weight: 900; background: #fff; box-shadow: 0 10px 24px rgba(49, 87, 255, .16); }
.access-form { margin-top: 6px; display: grid; gap: 14px; }
.access-form label { display: grid; gap: 7px; }
.access-form input { min-height: 50px; border-radius: 16px; border: 1px solid #d7e2ff; background: #f8fbff; padding: 12px 14px; font-weight: 700; }
.access-form input:focus { outline: none; border-color: #3157ff; box-shadow: 0 0 0 4px rgba(49, 87, 255, .12); background: #fff; }
.access-actions { margin-top: 4px; display: flex; flex-wrap: wrap; gap: 12px; }
.access-actions .primary { width: 100%; justify-content: center; min-height: 52px; border-radius: 17px; font-size: 1rem; font-weight: 900; }
.access-form-note, .access-security-note { display: none; }
@media (max-width: 1080px) {
    .access-page { background: radial-gradient(circle at 8% 12%, rgba(49, 87, 255, .28), transparent 32%), linear-gradient(160deg, #071126 0%, #0d1b3d 58%, #edf3fb 58%, #edf3fb 100%); }
    .access-landing-content { grid-template-columns: 1fr; }
    .access-form-area { justify-self: start; width: min(560px, 100%); }
}
@media (max-width: 700px) {
    .access-page { padding: 22px; }
    .access-highlights { grid-template-columns: 1fr; }
    .access-copy h1 { font-size: clamp(2.4rem, 13vw, 4.6rem); }
    .access-form-area { border-radius: 26px; padding: 24px; }
}

.sidebar-user-card {
    margin: 14px 12px;
    padding: 12px;
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,.22);
    background: rgba(255,255,255,.08);
    color: #fff;
    display: grid;
    gap: 4px;
}

.sidebar-user-card span {
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    opacity: .78;
}

.sidebar-user-card strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-user-card button {
    margin-top: 6px;
    width: fit-content;
    min-height: 30px;
    padding: 5px 12px;
}

.sidebar-user-card a.button.mini {
    margin-top: 6px;
    width: fit-content;
    min-height: 30px;
    padding: 5px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.32);
    color: #fff;
    text-decoration: none;
    font-weight: 800;
    background: rgba(255,255,255,.12);
}

@media (max-width: 980px) {
    .access-shell {
        grid-template-columns: 1fr;
    }

    .access-feature-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .access-page {
        padding: 18px;
    }

    .access-card,
    .access-hero {
        padding: 24px;
        border-radius: 24px;
    }
}


/* v57 professional full-page access landing with Sorteos Strategy Lab brand */
.access-landing-pro {
    min-height: 100vh;
    width: 100%;
    padding: clamp(26px, 4vw, 68px);
    background:
        radial-gradient(circle at 8% 12%, rgba(30, 136, 42, .18), transparent 30%),
        radial-gradient(circle at 92% 8%, rgba(49, 87, 255, .16), transparent 28%),
        linear-gradient(135deg, #f7fbff 0%, #eef5ff 48%, #ffffff 100%);
    color: #071126;
    overflow: hidden;
}
.access-pro-glow { position: absolute; pointer-events: none; border-radius: 999px; filter: blur(6px); opacity: .85; }
.access-pro-glow-one { width: 520px; height: 520px; left: -220px; bottom: -220px; background: rgba(21, 158, 40, .13); }
.access-pro-glow-two { width: 390px; height: 390px; right: -150px; top: -140px; background: rgba(49, 87, 255, .13); }
.access-pro-shell {
    position: relative;
    z-index: 1;
    min-height: calc(100vh - clamp(52px, 8vw, 136px));
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(390px, 520px);
    gap: clamp(30px, 5vw, 86px);
    align-items: center;
}
.access-pro-copy { display: grid; gap: clamp(18px, 2.2vw, 30px); max-width: 1080px; color: #071126; }
.access-pro-logo { width: min(720px, 78vw); max-height: 190px; object-fit: contain; object-position: left center; filter: drop-shadow(0 22px 45px rgba(7, 17, 38, .10)); }
.access-pro-kicker { background: #e9f7eb; border-color: #c8ebcf; color: #168a26; }
.access-pro-copy h1 { margin: 0; max-width: 1050px; font-size: clamp(2.4rem, 5.8vw, 6.5rem); line-height: .94; letter-spacing: -.065em; color: #071126; }
.access-pro-lead { max-width: 900px; color: #43516e; font-size: clamp(1rem, 1.4vw, 1.24rem); line-height: 1.65; }
.access-pro-features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; width: min(980px, 100%); }
.access-pro-features article {
    min-height: 128px;
    padding: 20px;
    border-radius: 26px;
    background: rgba(255,255,255,.78);
    border: 1px solid #d9e5f7;
    box-shadow: 0 18px 55px rgba(15, 30, 64, .08);
    display: grid;
    gap: 8px;
    align-content: start;
}
.access-pro-features strong { color: #071126; font-size: 1.02rem; }
.access-pro-features span { color: #51607f; line-height: 1.5; font-size: .93rem; }
.access-pro-panel {
    width: 100%;
    padding: clamp(24px, 3vw, 36px);
    border-radius: 34px;
    background: rgba(255,255,255,.92);
    border: 1px solid #d9e5f7;
    box-shadow: 0 32px 80px rgba(15, 30, 64, .16);
    backdrop-filter: blur(14px);
}
.access-pro-panel-header { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 16px; align-items: center; margin-bottom: 14px; }
.access-pro-panel-header img { width: 92px; height: 92px; object-fit: contain; border-radius: 20px; background: #fff; box-shadow: 0 14px 36px rgba(15, 30, 64, .08); }
.access-pro-panel-header h2 { margin: 8px 0 4px; color: #071126; font-size: clamp(1.9rem, 2.5vw, 2.6rem); line-height: 1; letter-spacing: -.045em; }
.access-pro-panel-header p { margin: 0; color: #52607b; line-height: 1.45; }
.access-pro-alert { margin: 14px 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.access-pro-alert button { min-height: 34px; padding: 7px 12px; border-radius: 11px; background: #fff; font-weight: 900; }
.access-pro-tabs { margin: 18px 0 14px; }
.access-pro-form .link-button {
    border: 0;
    background: transparent;
    color: #3157ff;
    padding: 4px 0;
    min-height: auto;
    justify-content: flex-start;
    font-weight: 900;
    text-decoration: none;
}
.access-pro-form .link-button:hover { text-decoration: underline; background: transparent; }
.alert.success { background: #eaf8ee; color: #126b23; border: 1px solid #bfe8c7; }
@media (max-width: 1120px) {
    .access-pro-shell { grid-template-columns: 1fr; }
    .access-pro-panel { max-width: 620px; }
}
@media (max-width: 720px) {
    .access-landing-pro { padding: 20px; }
    .access-pro-logo { width: min(520px, 100%); }
    .access-pro-features { grid-template-columns: 1fr; }
    .access-pro-panel-header { grid-template-columns: 72px 1fr; }
    .access-pro-panel-header img { width: 72px; height: 72px; }
}

/* v57 brand placement on lottery selector without replacing official lottery logos */
.selector-hero-branded { display: grid; grid-template-columns: minmax(220px, 360px) minmax(0, 1fr); gap: 26px; align-items: center; }
.selector-brand-logo { width: 100%; max-height: 132px; object-fit: contain; object-position: left center; filter: drop-shadow(0 18px 36px rgba(15, 30, 64, .10)); }
@media (max-width: 860px) {
    .selector-hero-branded { grid-template-columns: 1fr; }
    .selector-brand-logo { max-width: 420px; }
}

/* v58 full-viewport access/login refinement */
html, body {
    min-height: 100%;
}

.access-page.access-landing-pro {
    min-height: 100vh;
    width: 100vw;
    padding: 0;
    overflow-x: hidden;
    overflow-y: auto;
    background:
        radial-gradient(circle at 18% 18%, rgba(30, 136, 42, .22), transparent 28%),
        radial-gradient(circle at 82% 10%, rgba(49, 87, 255, .16), transparent 26%),
        linear-gradient(115deg, #071126 0%, #0c1b3d 47%, #f6f9ff 47%, #ffffff 100%);
    color: #071126;
}

.access-landing-pro .access-pro-glow-one,
.access-landing-pro .access-pro-glow-two {
    opacity: .55;
}

.access-landing-pro .access-pro-shell {
    min-height: 100vh;
    width: 100%;
    max-width: none;
    padding: clamp(26px, 4.5vw, 76px);
    grid-template-columns: minmax(0, 1.28fr) minmax(400px, 560px);
    gap: clamp(34px, 6vw, 104px);
    align-items: center;
}

.access-landing-pro .access-pro-copy {
    max-width: 1160px;
    color: #ffffff;
}

.access-landing-pro .access-pro-logo {
    width: min(780px, 58vw);
    max-height: 210px;
    object-fit: contain;
    object-position: left center;
    background: rgba(255,255,255,.94);
    border-radius: 28px;
    padding: clamp(14px, 1.5vw, 22px);
    box-shadow: 0 28px 70px rgba(0,0,0,.22);
}

.access-landing-pro .access-pro-kicker {
    background: rgba(255,255,255,.13);
    border-color: rgba(255,255,255,.22);
    color: #b9f2c1;
}

.access-landing-pro .access-pro-copy h1 {
    color: #ffffff;
    text-shadow: 0 16px 46px rgba(0,0,0,.26);
}

.access-landing-pro .access-pro-lead {
    color: #dbe6ff;
    max-width: 980px;
}

.access-landing-pro .access-pro-features article {
    background: rgba(255,255,255,.10);
    border: 1px solid rgba(255,255,255,.18);
    box-shadow: 0 22px 70px rgba(0,0,0,.18);
    backdrop-filter: blur(14px);
}

.access-landing-pro .access-pro-features strong {
    color: #ffffff;
}

.access-landing-pro .access-pro-features span {
    color: #d6e2fb;
}

.access-landing-pro .access-pro-panel {
    align-self: stretch;
    display: grid;
    align-content: center;
    border-radius: 0;
    border: 0;
    border-left: 1px solid #dce6f6;
    background: rgba(255,255,255,.96);
    box-shadow: -28px 0 80px rgba(15, 30, 64, .10);
    min-height: 100vh;
    padding: clamp(34px, 4vw, 58px);
}

.access-landing-pro .access-pro-panel-header img {
    background: #ffffff;
    border: 1px solid #e1e9f7;
}

.access-landing-pro .access-pro-panel-header h2,
.access-landing-pro .access-brand h2,
.access-landing-pro .field-caption,
.access-landing-pro label,
.access-landing-pro .access-tabs button,
.access-landing-pro .access-form input {
    color: #071126;
}

.access-landing-pro .access-pro-panel-header p,
.access-landing-pro .access-brand p {
    color: #43516e;
}

.access-landing-pro .access-form input {
    background: #ffffff;
    border-color: #cfdcf0;
}

.access-landing-pro .access-form input::placeholder {
    color: #8090ad;
}

.access-landing-pro .access-tabs {
    background: #eaf1ff;
    border-color: #cfdbf2;
}

.access-landing-pro .access-tabs button:not(.active) {
    background: transparent;
    color: #42516f;
}

.access-landing-pro .access-tabs button.active {
    background: #ffffff;
    color: #2148f3;
}

.access-landing-pro .access-actions .primary {
    background: linear-gradient(135deg, #3157ff 0%, #1739d7 100%);
    color: #ffffff;
    box-shadow: 0 16px 30px rgba(49, 87, 255, .26);
}

.access-landing-pro .alert.warning {
    background: #fff7ed;
    color: #7c2d12;
    border-color: #fed7aa;
}

.access-landing-pro .alert.success {
    background: #ecfdf3;
    color: #166534;
    border-color: #bbf7d0;
}

@media (max-width: 1120px) {
    .access-page.access-landing-pro {
        width: 100%;
        background: linear-gradient(180deg, #071126 0%, #0c1b3d 54%, #f6f9ff 54%, #ffffff 100%);
    }

    .access-landing-pro .access-pro-shell {
        grid-template-columns: 1fr;
        padding: clamp(22px, 5vw, 48px);
    }

    .access-landing-pro .access-pro-logo {
        width: min(680px, 100%);
    }

    .access-landing-pro .access-pro-panel {
        min-height: auto;
        max-width: none;
        border-radius: 30px;
        border: 1px solid #dce6f6;
        box-shadow: 0 28px 80px rgba(15, 30, 64, .18);
    }
}

@media (max-width: 720px) {
    .access-landing-pro .access-pro-shell {
        padding: 18px;
    }

    .access-landing-pro .access-pro-features {
        grid-template-columns: 1fr;
    }

    .access-landing-pro .access-pro-panel {
        padding: 24px;
        border-radius: 24px;
    }
}


/* v59 auth branding, secure mail flows, topbar and loading refresh */
.access-landing-pro .access-pro-logo,
.access-landing-pro .access-pro-panel-header img {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
}

.access-brand-line {
    display: grid;
    grid-template-columns: minmax(280px, 720px) minmax(280px, 560px);
    gap: clamp(20px, 3vw, 42px);
    align-items: center;
    max-width: 1320px;
}

.access-brand-line p {
    margin: 0;
    color: #ffffff;
    font-size: clamp(1.65rem, 3.2vw, 4.25rem);
    line-height: 1.02;
    letter-spacing: -.055em;
    font-weight: 950;
    text-shadow: 0 16px 46px rgba(0,0,0,.24);
}

.access-landing-pro .access-pro-copy h1 {
    font-size: clamp(2rem, 4.2vw, 5rem);
}

.access-landing-pro .access-pro-panel-header {
    grid-template-columns: 108px minmax(0, 1fr);
}

.access-landing-pro .access-pro-panel-header img {
    width: 108px;
    height: 108px;
    object-fit: contain;
}

.app-topbar {
    position: sticky;
    top: 0;
    z-index: 30;
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 12px clamp(18px, 2vw, 32px);
    margin: calc(var(--content-padding, 18px) * -1) calc(var(--content-padding, 18px) * -1) 24px;
    background: rgba(255,255,255,.92);
    border-bottom: 1px solid #dce6f6;
    box-shadow: 0 14px 40px rgba(15,30,64,.08);
    backdrop-filter: blur(16px);
}

.app-topbar-brand {
    display: inline-flex;
    align-items: center;
    min-width: 0;
    text-decoration: none;
}

.app-topbar-brand img {
    height: 48px;
    width: min(420px, 42vw);
    object-fit: contain;
    object-position: left center;
}

.app-topbar-session {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 8px 10px 8px 16px;
    border: 1px solid #dce6f6;
    border-radius: 999px;
    background: #f8fbff;
    color: #071126;
    font-weight: 900;
    box-shadow: 0 10px 24px rgba(15,30,64,.07);
}

.app-topbar-session span {
    max-width: 240px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-topbar-session .button.mini {
    min-height: 34px;
    padding: 7px 13px;
    border-radius: 999px;
    background: #071126;
    color: #fff;
    text-decoration: none;
}

.loading-card {
    overflow: hidden;
}

.loading-brand-row {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-bottom: 14px;
}

.loading-brand-logo {
    height: 56px;
    max-width: min(440px, 72vw);
    object-fit: contain;
}

.loading-lottery-logo {
    height: 58px;
    width: 74px;
    object-fit: contain;
    border-radius: 16px;
    background: rgba(255,255,255,.78);
    border: 1px solid #dce6f6;
    padding: 6px;
}

@media (max-width: 900px) {
    .access-brand-line { grid-template-columns: 1fr; }
    .access-brand-line p { max-width: 780px; }
    .app-topbar { min-height: 66px; }
    .app-topbar-brand img { width: min(320px, 52vw); height: 42px; }
}

@media (max-width: 560px) {
    .content {
        padding: 16px 12px 24px;
    }

    .panel,
    .metric-card,
    .compliance-command-card,
    .target-command-card {
        padding: 14px;
    }

    .mobile-lottery-home strong {
        font-size: .94rem;
    }

    .app-topbar {
        flex-wrap: wrap;
        align-items: center;
        justify-content: center;
        padding: 10px 12px;
    }

    .app-topbar-brand {
        justify-content: center;
        width: 100%;
    }

    .app-topbar-brand img {
        width: min(260px, 78vw);
        height: 38px;
        object-position: center center;
    }

    .app-topbar-session {
        width: 100%;
        justify-content: center;
        border-radius: 18px;
        flex-wrap: wrap;
    }

    .app-topbar-session span { display: none; }
    .access-landing-pro .access-pro-panel-header { grid-template-columns: 76px 1fr; }
    .access-landing-pro .access-pro-panel-header img { width: 76px; height: 76px; }
}

/* v60 transparent brand assets and refreshed update loading card */
.access-landing-pro .access-pro-logo,
.access-landing-pro .access-pro-panel-header img,
.app-topbar-brand img,
.selector-brand-logo,
.loading-brand-logo {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

.access-landing-pro .access-pro-logo {
    width: min(760px, 56vw);
    max-height: 230px;
    filter: drop-shadow(0 24px 48px rgba(0,0,0,.25));
}

.access-brand-line {
    grid-template-columns: minmax(300px, 760px) minmax(300px, 620px);
}

.access-brand-line p {
    color: #f8fbff;
    text-shadow: 0 18px 48px rgba(0,0,0,.32);
}

.access-landing-pro .access-pro-panel-header img {
    object-fit: contain;
    filter: drop-shadow(0 12px 22px rgba(7,17,38,.10));
}

.loading-overlay {
    gap: 14px;
}

.loading-lottery-logo-outside {
    width: 92px;
    height: 92px;
    display: grid;
    place-items: center;
    border-radius: 26px;
    background: rgba(255,255,255,.88);
    border: 1px solid #dce6f6;
    box-shadow: 0 22px 58px rgba(15,30,64,.18);
    backdrop-filter: blur(14px);
}

.loading-lottery-logo-outside img {
    width: 74px;
    height: 74px;
    object-fit: contain;
}

.loading-card {
    text-align: center;
}

.loading-brand-row {
    justify-content: center;
    margin-bottom: 16px;
}

.loading-brand-logo {
    height: 64px;
    max-width: min(470px, 76vw);
    object-fit: contain;
    filter: drop-shadow(0 12px 22px rgba(7,17,38,.10));
}

@media (max-width: 900px) {
    .access-landing-pro .access-pro-logo {
        width: min(680px, 100%);
    }

    .loading-lottery-logo-outside {
        width: 82px;
        height: 82px;
        border-radius: 22px;
    }

    .loading-lottery-logo-outside img {
        width: 66px;
        height: 66px;
    }
}

/* v61 full-bleed access, admin panel and mail-ready auth */
html, body { min-height: 100%; }
.access-page.access-landing-pro {
    width: 100%;
    min-height: 100vh;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 12% 12%, rgba(255,255,255,.9), rgba(255,255,255,.15) 22%, transparent 42%),
        radial-gradient(circle at 72% 18%, rgba(49,87,255,.16), transparent 30%),
        linear-gradient(124deg, #f4f8ff 0%, #eef8f0 34%, #071126 34.2%, #0a1734 67%, #f7faff 67.2%, #ffffff 100%);
}
.access-landing-pro *,
.access-landing-pro *::before,
.access-landing-pro *::after {
    box-sizing: border-box;
}
.access-landing-pro h1,
.access-landing-pro h2,
.access-landing-pro p,
.access-landing-pro span,
.access-landing-pro strong,
.access-landing-pro article {
    outline: 0 !important;
}
.access-landing-pro .access-pro-shell {
    min-height: 100vh;
    width: 100%;
    max-width: none;
    padding: clamp(34px, 4vw, 72px) clamp(28px, 5vw, 86px);
    grid-template-columns: minmax(0, 1fr) minmax(380px, 520px);
    align-items: center;
    gap: clamp(34px, 6vw, 96px);
}
.access-landing-pro .access-pro-copy {
    align-content: center;
    max-width: 1180px;
    gap: clamp(18px, 2vw, 28px);
}
.access-landing-pro .access-brand-line {
    grid-template-columns: minmax(260px, 520px) minmax(300px, 610px);
    gap: clamp(18px, 3vw, 44px);
    align-items: center;
    margin-bottom: clamp(8px, 1vw, 18px);
}
.access-landing-pro .access-pro-logo {
    width: min(520px, 100%);
    max-height: 260px;
    object-fit: contain;
    object-position: left center;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    filter: drop-shadow(0 18px 38px rgba(7, 17, 38, .18));
}
.access-landing-pro .access-brand-line p {
    margin: 0;
    color: #071126;
    font-size: clamp(1.7rem, 3.1vw, 4.2rem);
    line-height: 1.03;
    letter-spacing: -.055em;
    font-weight: 950;
    text-shadow: none;
}
.access-landing-pro .access-pro-kicker {
    background: rgba(185,242,193,.18);
    border: 1px solid rgba(185,242,193,.28);
    color: #b9f2c1;
    box-shadow: none;
}
.access-landing-pro .access-pro-copy h1 {
    color: #ffffff;
    max-width: 1080px;
    font-size: clamp(2.4rem, 5.2vw, 6.1rem);
    line-height: .94;
    letter-spacing: -.065em;
    text-shadow: 0 18px 48px rgba(0,0,0,.26);
    border: 0 !important;
    box-shadow: none !important;
}
.access-landing-pro .access-pro-lead {
    max-width: 980px;
    color: #e5edff;
    font-weight: 650;
}
.access-landing-pro .access-pro-features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 1000px;
}
.access-landing-pro .access-pro-features article {
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.18);
    box-shadow: 0 20px 58px rgba(0,0,0,.16);
}
.access-landing-pro .access-pro-features strong { color: #ffffff; }
.access-landing-pro .access-pro-features span { color: #dbe6ff; }
.access-landing-pro .access-pro-panel {
    width: 100%;
    max-width: 520px;
    min-height: auto;
    align-self: center;
    padding: clamp(28px, 3vw, 44px);
    border-radius: 34px;
    border: 1px solid rgba(210, 222, 242, .95);
    background: rgba(255,255,255,.94);
    box-shadow: 0 34px 100px rgba(15, 30, 64, .16);
    backdrop-filter: blur(18px);
}
.access-landing-pro .access-pro-panel-header {
    grid-template-columns: 86px minmax(0,1fr);
    gap: 16px;
}
.access-landing-pro .access-pro-panel-header img {
    width: 86px;
    height: 86px;
    object-fit: contain;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    filter: drop-shadow(0 12px 20px rgba(7,17,38,.16));
}
.access-landing-pro .access-pro-panel-header h2 { color: #071126; }
.access-landing-pro .access-pro-panel-header p { color: #50607d; }
.access-landing-pro .access-tabs { background: #eef4ff; border-color: #d5e1f6; }
.access-landing-pro .access-form input { color: #071126; background: #fff; }
.access-landing-pro .access-form input::placeholder { color: #8090ad; }
.access-landing-pro .access-pro-form .link-button { color: #2048f4; }
.access-landing-pro .access-pro-alert { border-radius: 16px; }

.app-topbar-session { gap: 8px; }
.app-topbar-session .button.mini.admin-link { background: #168a26; color: #fff; }

.loading-overlay {
    background:
        radial-gradient(circle at 50% 18%, rgba(255,255,255,.92), transparent 30%),
        linear-gradient(135deg, rgba(244,248,255,.96), rgba(236,247,238,.96));
}
.loading-card {
    border-radius: 30px;
    border: 1px solid #d9e4f5;
    background: rgba(255,255,255,.96);
    box-shadow: 0 30px 90px rgba(15,30,64,.16);
}
.loading-lottery-logo-outside img,
.loading-brand-logo {
    background: transparent !important;
    box-shadow: none !important;
    border: 0 !important;
}
.loading-brand-logo {
    height: 66px;
    max-width: min(500px, 78vw);
    object-fit: contain;
    filter: drop-shadow(0 12px 20px rgba(7,17,38,.10));
}

.admin-page {
    min-height: 100vh;
    padding: clamp(24px, 3vw, 48px);
    background:
        radial-gradient(circle at 10% 0%, rgba(49,87,255,.12), transparent 30%),
        linear-gradient(180deg, #f6f9ff 0%, #eef4fb 100%);
    color: #071126;
}
.admin-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
    padding: clamp(22px, 3vw, 36px);
    border-radius: 32px;
    background: linear-gradient(135deg, #071126 0%, #0f2552 62%, #ffffff 62.2%, #ffffff 100%);
    box-shadow: 0 24px 70px rgba(15,30,64,.13);
    overflow: hidden;
}
.admin-hero h1 { margin: 8px 0; color: #fff; font-size: clamp(2.2rem, 4vw, 4.6rem); letter-spacing: -.06em; line-height: .95; }
.admin-hero p { margin: 0; color: #dbe6ff; max-width: 720px; font-weight: 650; }
.admin-hero img { width: min(420px, 32vw); max-height: 130px; object-fit: contain; filter: drop-shadow(0 14px 28px rgba(7,17,38,.16)); }
.admin-kicker { display: inline-flex; width: fit-content; padding: 8px 13px; border-radius: 999px; background: #e9f7eb; color: #168a26; font-weight: 950; letter-spacing: .08em; text-transform: uppercase; font-size: .78rem; }
.admin-toolbar { display: grid; grid-template-columns: minmax(280px, 1fr) repeat(3, minmax(120px, 180px)); gap: 14px; align-items: end; margin-bottom: 18px; }
.admin-toolbar label { display: grid; gap: 7px; color: #50607d; font-weight: 800; }
.admin-toolbar input, .admin-inline-form input { min-height: 42px; border-radius: 14px; border: 1px solid #d5e1f6; background: #fff; padding: 10px 12px; color: #071126; font-weight: 750; }
.admin-stat { min-height: 64px; border-radius: 18px; background: #fff; border: 1px solid #dbe6f6; display: grid; align-content: center; padding: 12px 16px; box-shadow: 0 14px 36px rgba(15,30,64,.07); }
.admin-stat strong { font-size: 1.55rem; }
.admin-stat span { color: #61708c; font-size: .86rem; font-weight: 800; }
.admin-table-card { overflow-x: auto; background: #fff; border: 1px solid #dbe6f6; border-radius: 26px; box-shadow: 0 24px 70px rgba(15,30,64,.10); }
.admin-users-table { width: 100%; min-width: 1180px; border-collapse: separate; border-spacing: 0; }
.admin-users-table th { text-align: left; padding: 16px; color: #50607d; font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; background: #f4f8ff; }
.admin-users-table td { padding: 16px; border-top: 1px solid #edf2fa; vertical-align: top; }
.admin-users-table td strong { display: block; color: #071126; }
.admin-users-table td span { display: block; color: #61708c; margin-top: 3px; }
.status-pills, .admin-actions { display: flex; flex-wrap: wrap; gap: 7px; }
.pill { display: inline-flex; align-items: center; min-height: 28px; border-radius: 999px; padding: 5px 10px; font-weight: 900; font-size: .78rem; }
.pill.success { background: #ecfdf3; color: #166534; }
.pill.warning { background: #fff7ed; color: #9a3412; }
.pill.danger { background: #fef2f2; color: #991b1b; }
.pill.admin { background: #eef4ff; color: #2148f3; }
.admin-inline-form { display: grid; grid-template-columns: minmax(130px, 1fr) minmax(190px, 1fr) auto; gap: 8px; }
.admin-inline-form button, .admin-actions button, .admin-card .button { min-height: 38px; border-radius: 12px; border: 1px solid #d5e1f6; background: #fff; color: #071126; font-weight: 900; padding: 8px 12px; cursor: pointer; }
.admin-actions button:hover, .admin-inline-form button:hover { border-color: #3157ff; color: #3157ff; }
.admin-actions button.danger { border-color: #fecaca; color: #b91c1c; background: #fff5f5; }
.admin-denied { display: grid; place-items: center; }
.admin-card { width: min(560px, 100%); padding: 34px; border-radius: 28px; background: #fff; border: 1px solid #dbe6f6; box-shadow: 0 24px 70px rgba(15,30,64,.12); }
.admin-card h1 { margin: 12px 0 8px; color: #071126; }
.admin-card p { color: #50607d; }

@media (max-width: 1120px) {
    .access-page.access-landing-pro { background: linear-gradient(180deg, #f4f8ff 0%, #eef8f0 24%, #071126 24.2%, #0a1734 68%, #ffffff 68.2%, #ffffff 100%); }
    .access-landing-pro .access-pro-shell { grid-template-columns: 1fr; }
    .access-landing-pro .access-pro-panel { max-width: 680px; justify-self: center; }
    .access-landing-pro .access-brand-line { grid-template-columns: 1fr; }
    .access-landing-pro .access-pro-logo { width: min(640px, 100%); }
    .admin-hero { background: linear-gradient(135deg, #071126 0%, #0f2552 100%); }
    .admin-hero img { width: min(360px, 45vw); }
}
@media (max-width: 760px) {
    .access-landing-pro .access-pro-shell { padding: 20px; }
    .access-landing-pro .access-pro-features { grid-template-columns: 1fr; }
    .admin-toolbar { grid-template-columns: 1fr; }
    .admin-hero { flex-direction: column; align-items: flex-start; }
    .admin-hero img { width: min(100%, 360px); }
}

/* fix46: integración de logos con fondo blanco sin recuadro visible */
.access-page.access-landing-pro {
    min-height: 100dvh;
    width: 100%;
    padding: 0 !important;
    overflow-x: hidden;
    background:
        radial-gradient(circle at 16% 18%, rgba(42, 170, 64, .16), transparent 30%),
        radial-gradient(circle at 84% 16%, rgba(49, 87, 255, .16), transparent 32%),
        linear-gradient(135deg, #f7fbff 0%, #eef6ff 46%, #ffffff 46.2%, #ffffff 100%) !important;
}

.access-landing-pro .access-pro-shell {
    width: 100%;
    min-height: 100dvh;
    padding: clamp(28px, 4vw, 70px) !important;
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(420px, .75fr);
    gap: clamp(34px, 5vw, 92px);
    align-items: center;
    max-width: none !important;
    margin: 0 !important;
}

.access-landing-pro .access-pro-copy {
    position: relative;
    max-width: none !important;
    color: #08152d !important;
    padding: clamp(28px, 4vw, 58px);
    border-radius: 38px;
    background:
        linear-gradient(135deg, rgba(255,255,255,.98), rgba(255,255,255,.92)),
        radial-gradient(circle at 0 0, rgba(22,138,38,.08), transparent 34%);
    border: 1px solid rgba(213, 225, 246, .92);
    box-shadow: 0 32px 100px rgba(15, 30, 64, .10);
    overflow: hidden;
}

.access-landing-pro .access-pro-copy::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(115deg, transparent 0 58%, rgba(49,87,255,.055) 58.2% 100%);
}

.access-landing-pro .access-brand-line {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(320px, 560px) minmax(260px, 1fr);
    gap: clamp(22px, 4vw, 56px);
    align-items: center;
}

.access-landing-pro .access-pro-logo {
    width: 100% !important;
    max-width: 560px;
    max-height: 230px;
    object-fit: contain;
    object-position: left center;
    background: #ffffff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: drop-shadow(0 18px 30px rgba(8,21,45,.10));
    mix-blend-mode: normal;
}

.access-landing-pro .access-brand-line p {
    color: #08152d !important;
    font-size: clamp(1.55rem, 2.6vw, 3.8rem) !important;
    line-height: 1.02;
    letter-spacing: -.055em;
    text-shadow: none !important;
}

.access-landing-pro .access-pro-kicker {
    position: relative;
    z-index: 1;
    background: #ecfdf3 !important;
    color: #147a24 !important;
    border: 1px solid #bbf7d0 !important;
    box-shadow: none !important;
}

.access-landing-pro .access-pro-copy h1 {
    position: relative;
    z-index: 1;
    color: #08152d !important;
    border: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;
    text-shadow: none !important;
    background: transparent !important;
    max-width: 980px;
}

.access-landing-pro .access-pro-copy h1::before,
.access-landing-pro .access-pro-copy h1::after {
    display: none !important;
    content: none !important;
}

.access-landing-pro .access-pro-lead {
    position: relative;
    z-index: 1;
    color: #42516f !important;
    text-shadow: none !important;
}

.access-landing-pro .access-pro-features {
    position: relative;
    z-index: 1;
}

.access-landing-pro .access-pro-features article {
    background: #ffffff !important;
    border: 1px solid #dce7f7 !important;
    box-shadow: 0 18px 50px rgba(15, 30, 64, .08) !important;
}

.access-landing-pro .access-pro-features strong { color: #08152d !important; }
.access-landing-pro .access-pro-features span { color: #53627f !important; }

.access-landing-pro .access-pro-panel {
    width: min(520px, 100%) !important;
    justify-self: center;
    border-radius: 34px;
    background: #ffffff !important;
    border: 1px solid #dce7f7 !important;
    box-shadow: 0 34px 100px rgba(15, 30, 64, .14) !important;
}

.access-landing-pro .access-pro-panel-header img {
    width: 96px !important;
    height: 96px !important;
    object-fit: contain;
    background: #ffffff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: drop-shadow(0 12px 22px rgba(8,21,45,.12));
}

.app-topbar-brand img,
.selector-brand-logo,
.loading-brand-logo,
.admin-hero img {
    background: #ffffff !important;
    border-radius: 0 !important;
    border: 0 !important;
    box-shadow: none !important;
    mix-blend-mode: normal;
}

.app-topbar-brand img {
    padding: 3px 8px;
    border-radius: 12px !important;
}

.loading-brand-row,
.selector-brand-logo-wrap,
.admin-hero .brand-logo-wrap {
    background: #ffffff;
}

@media (max-width: 1120px) {
    .access-landing-pro .access-pro-shell {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    .access-landing-pro .access-brand-line {
        grid-template-columns: 1fr;
    }
    .access-landing-pro .access-pro-logo {
        max-width: 620px;
    }
}

@media (max-width: 720px) {
    .access-landing-pro .access-pro-shell {
        padding: 18px !important;
    }
    .access-landing-pro .access-pro-copy,
    .access-landing-pro .access-pro-panel {
        border-radius: 24px;
    }
}

/* v60 clean single-card authentication and white logo pages */
.ssl-auth-page {
    min-height: 100vh;
    width: 100%;
    position: relative;
    overflow-x: hidden;
    background: #ffffff;
    color: #071126;
}

.ssl-auth-background {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(circle at 12% 10%, rgba(34, 159, 53, .10), transparent 30%),
        radial-gradient(circle at 90% 12%, rgba(49, 87, 255, .12), transparent 28%),
        linear-gradient(135deg, #ffffff 0%, #f7fbff 52%, #eef5ff 100%);
}

.ssl-auth-layout {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(390px, 520px);
    gap: clamp(28px, 5vw, 88px);
    align-items: center;
    padding: clamp(26px, 5vw, 78px);
}

.ssl-auth-intro {
    display: grid;
    gap: clamp(24px, 3vw, 42px);
    align-content: center;
}

.ssl-auth-logo {
    width: min(760px, 100%);
    max-height: 220px;
    object-fit: contain;
    object-position: left center;
    background: #ffffff;
    mix-blend-mode: normal;
    filter: drop-shadow(0 22px 44px rgba(15, 30, 64, .10));
}

.ssl-auth-copy {
    display: grid;
    gap: 18px;
    max-width: 960px;
}

.ssl-auth-kicker,
.ssl-auth-badge {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 8px 13px;
    background: #eaf8ee;
    color: #168a26;
    border: 1px solid #c9ebd1;
    font-size: .78rem;
    font-weight: 950;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ssl-auth-copy h1 {
    margin: 0;
    color: #071126;
    font-size: clamp(2.45rem, 5.6vw, 6.4rem);
    line-height: .94;
    letter-spacing: -.065em;
    max-width: 1050px;
}

.ssl-auth-copy p {
    margin: 0;
    color: #43516e;
    font-size: clamp(1rem, 1.35vw, 1.22rem);
    line-height: 1.65;
    max-width: 860px;
}

.ssl-auth-highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.ssl-auth-highlights span {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    border-radius: 999px;
    padding: 8px 14px;
    background: #ffffff;
    color: #0b1d3f;
    border: 1px solid #dbe6f6;
    box-shadow: 0 12px 28px rgba(15, 30, 64, .06);
    font-weight: 850;
    font-size: .92rem;
}

.ssl-auth-card {
    width: 100%;
    border-radius: 34px;
    padding: clamp(26px, 3.2vw, 42px);
    background: #ffffff;
    border: 1px solid #dbe6f6;
    box-shadow: 0 34px 90px rgba(15, 30, 64, .16);
}

.ssl-auth-card-header {
    display: grid;
    grid-template-columns: 94px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    margin-bottom: 20px;
}

.ssl-auth-card-header img {
    width: 94px;
    height: 94px;
    object-fit: contain;
    background: #ffffff;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.ssl-auth-card-header h2 {
    margin: 10px 0 5px;
    color: #071126;
    font-size: clamp(2rem, 2.6vw, 2.7rem);
    line-height: .95;
    letter-spacing: -.045em;
}

.ssl-auth-card-header p {
    margin: 0;
    color: #52607b;
    line-height: 1.45;
}

.ssl-auth-tabs {
    margin: 18px 0 18px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 8px;
    border-radius: 19px;
    background: #eef4ff;
    border: 1px solid #d3def2;
}

.ssl-auth-tabs button {
    min-height: 44px;
    border-radius: 14px;
    border: 0;
    background: transparent;
    color: #42516f;
    font-weight: 900;
}

.ssl-auth-tabs button.active {
    background: #ffffff;
    color: #2148f3;
    box-shadow: 0 10px 24px rgba(15, 30, 64, .08);
}

.ssl-auth-form {
    display: grid;
    gap: 15px;
}

.ssl-auth-form label {
    display: grid;
    gap: 7px;
    color: #52607b;
    font-size: .94rem;
}

.ssl-auth-form input {
    min-height: 50px;
    border-radius: 16px;
    border: 1px solid #cfdbef;
    background: #ffffff;
    color: #071126;
    padding: 12px 15px;
    font: inherit;
    outline: none;
}

.ssl-auth-form input:focus {
    border-color: #3157ff;
    box-shadow: 0 0 0 4px rgba(49, 87, 255, .10);
}

.ssl-auth-form input::placeholder {
    color: #8190aa;
}

.ssl-auth-submit {
    min-height: 52px;
    border-radius: 16px;
    margin-top: 4px;
    background: linear-gradient(135deg, #3157ff 0%, #1739d7 100%) !important;
    color: #ffffff !important;
    border-color: transparent !important;
    box-shadow: 0 18px 34px rgba(49, 87, 255, .26);
    font-weight: 950;
}

.ssl-auth-link {
    width: fit-content;
    border: 0;
    background: transparent;
    color: #2148f3;
    padding: 4px 0;
    min-height: auto;
    font-weight: 900;
    text-decoration: none;
}

.ssl-auth-link:hover {
    text-decoration: underline;
    background: transparent;
}

.ssl-auth-alert {
    margin: 14px 0;
    border-radius: 16px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.ssl-auth-alert button {
    min-height: 34px;
    padding: 7px 12px;
    border-radius: 11px;
    background: #ffffff;
    font-weight: 900;
}

.selector-hero-branded,
.app-topbar,
.admin-hero-brand,
.loading-card,
.loading-brand-row {
    background-color: #ffffff;
}

.selector-brand-logo,
.app-topbar-brand img,
.admin-brand-logo,
.loading-brand-logo {
    background: #ffffff;
    border-radius: 0;
    box-shadow: none;
    mix-blend-mode: normal;
}

.loading-card .loading-brand-logo {
    max-width: min(340px, 82vw);
    height: auto;
    object-fit: contain;
}

@media (max-width: 1100px) {
    .ssl-auth-layout {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .ssl-auth-card {
        max-width: 640px;
    }
}

@media (max-width: 680px) {
    .ssl-auth-layout {
        padding: 20px;
    }

    .ssl-auth-card {
        border-radius: 26px;
        padding: 24px;
    }

    .ssl-auth-card-header {
        grid-template-columns: 74px minmax(0, 1fr);
    }

    .ssl-auth-card-header img {
        width: 74px;
        height: 74px;
    }
}

/* v77 login estilo laboratorio profesional inspirado en mockup: fondo blanco en zonas con logotipo */
.ssl-auth-page {
    min-height: 100dvh;
    width: 100%;
    position: relative;
    overflow: hidden;
    background: #ffffff;
    color: #071126;
}

.ssl-auth-background {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(circle at 11% 6%, rgba(17, 148, 38, .065), transparent 24%),
        radial-gradient(circle at 86% 20%, rgba(34, 87, 255, .075), transparent 30%),
        linear-gradient(105deg, #ffffff 0 57%, #f5f8fc 57.15% 100%);
}

.ssl-auth-background::before {
    content: "";
    position: absolute;
    left: -9vw;
    bottom: -13vh;
    width: 58vw;
    height: 36vh;
    opacity: .22;
    background: repeating-radial-gradient(ellipse at 45% 65%, transparent 0 12px, rgba(22, 138, 38, .34) 13px 14px, transparent 15px 26px);
    transform: rotate(-4deg);
}

.ssl-auth-background::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(101deg, transparent 0 57.1%, rgba(7, 17, 38, .028) 57.2% 100%);
}

.ssl-auth-layout {
    position: relative;
    z-index: 1;
    min-height: 100dvh;
    width: min(1760px, 100%);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1.24fr) minmax(390px, 600px);
    align-items: center;
    gap: clamp(34px, 5vw, 92px);
    padding: clamp(32px, 5vw, 70px) clamp(30px, 6vw, 104px);
}

.ssl-auth-intro {
    display: grid;
    align-content: center;
    gap: clamp(28px, 3.4vw, 56px);
    min-width: 0;
}

.ssl-auth-logo-shell {
    width: fit-content;
    max-width: 100%;
    padding: 0;
    background: #ffffff;
    border-radius: 0;
}

.ssl-auth-logo {
    display: block;
    width: min(690px, 100%);
    max-height: 178px;
    object-fit: contain;
    object-position: left center;
    background: #ffffff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    mix-blend-mode: normal;
    filter: drop-shadow(0 18px 30px rgba(7, 17, 38, .08));
}

.ssl-auth-copy {
    display: grid;
    gap: 20px;
    max-width: 820px;
}

.ssl-auth-kicker,
.ssl-auth-badge,
.ssl-auth-highlights {
    display: none !important;
}

.ssl-auth-copy h1 {
    margin: 0;
    max-width: 820px;
    color: #071a41;
    font-size: clamp(2.6rem, 4.7vw, 4.75rem);
    line-height: 1.05;
    letter-spacing: -.058em;
    font-weight: 950;
}

.ssl-auth-copy h1 span {
    color: #139228;
}

.ssl-auth-title-line {
    width: 92px;
    height: 3px;
    border-radius: 999px;
    background: #139228;
}

.ssl-auth-copy p {
    margin: 0;
    max-width: 650px;
    color: #42506b;
    font-size: clamp(1rem, 1.14vw, 1.15rem);
    line-height: 1.6;
    font-weight: 600;
}

.ssl-auth-feature-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(18px, 2.3vw, 42px);
    max-width: 850px;
}

.ssl-auth-feature-grid article {
    min-width: 0;
    display: grid;
    justify-items: center;
    text-align: center;
    gap: 9px;
}

.ssl-feature-icon,
.ssl-stat-icon,
.ssl-auth-trust span {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    width: 58px;
    height: 58px;
    border-radius: 16px;
    font-size: 1.55rem;
    font-weight: 950;
}

.ssl-feature-icon.green,
.ssl-stat-icon.green,
.ssl-auth-trust .green { color: #11932b; background: linear-gradient(135deg, #e8f8ed, #d5f1dd); }
.ssl-feature-icon.blue,
.ssl-stat-icon.blue,
.ssl-auth-trust .blue { color: #2468ff; background: linear-gradient(135deg, #edf4ff, #dfeaff); }
.ssl-feature-icon.gold,
.ssl-stat-icon.gold { color: #f0a500; background: linear-gradient(135deg, #fff7df, #ffedbd); }
.ssl-feature-icon.purple,
.ssl-stat-icon.purple,
.ssl-auth-trust .purple { color: #8d45df; background: linear-gradient(135deg, #f3eaff, #eadcff); }

.ssl-auth-feature-grid strong {
    color: #091a3e;
    font-size: .92rem;
    line-height: 1.25;
    font-weight: 950;
}

.ssl-auth-feature-grid span:last-child {
    color: #45536e;
    font-size: .9rem;
    line-height: 1.45;
    font-weight: 600;
}

.ssl-auth-stats {
    width: min(840px, 100%);
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: center;
    gap: 0;
    border-radius: 16px;
    border: 1px solid #e2e9f3;
    background: rgba(255, 255, 255, .94);
    box-shadow: 0 20px 56px rgba(15, 30, 64, .10);
    backdrop-filter: blur(10px);
    overflow: hidden;
}

.ssl-auth-stats > div {
    min-height: 78px;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    column-gap: 12px;
    align-items: center;
    padding: 14px 20px;
    position: relative;
}

.ssl-auth-stats > div + div::before {
    content: "";
    position: absolute;
    left: 0;
    top: 18px;
    bottom: 18px;
    width: 1px;
    background: #d9e2ef;
}

.ssl-stat-icon {
    grid-row: span 2;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 1.05rem;
}

.ssl-auth-stats strong {
    align-self: end;
    color: #0d9430;
    font-size: clamp(1.1rem, 1.4vw, 1.45rem);
    line-height: 1;
    font-weight: 950;
    letter-spacing: -.025em;
}

.ssl-auth-stats > div:nth-child(2) strong { color: #1d5dff; }
.ssl-auth-stats > div:nth-child(3) strong { color: #ec9d00; }
.ssl-auth-stats > div:nth-child(4) strong { color: #8846de; }

.ssl-auth-stats span:last-child {
    align-self: start;
    color: #3f4d68;
    font-size: .78rem;
    font-weight: 650;
}

.ssl-auth-side {
    display: grid;
    justify-items: center;
    gap: 28px;
    min-width: 0;
}

.ssl-auth-card {
    width: min(100%, 560px);
    min-height: 640px;
    display: grid;
    align-content: center;
    border-radius: 24px;
    padding: clamp(36px, 4vw, 56px) clamp(28px, 3.5vw, 42px);
    background: rgba(255, 255, 255, .96);
    border: 1px solid rgba(223, 230, 240, .86);
    box-shadow: 0 34px 86px rgba(15, 30, 64, .13);
    backdrop-filter: blur(16px);
}

.ssl-auth-card-header {
    display: grid;
    justify-items: center;
    text-align: center;
    gap: 12px;
    margin: 0 0 28px;
}

.ssl-auth-shield {
    width: 82px;
    height: 82px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #118f2b;
    background: linear-gradient(135deg, #ebf9ee, #d8f1df);
    box-shadow: inset 0 0 0 10px rgba(255, 255, 255, .36);
}

.ssl-auth-shield svg {
    width: 34px;
    height: 34px;
}

.ssl-auth-card-header h2 {
    margin: 8px 0 0;
    color: #061a42;
    font-size: clamp(2rem, 2.3vw, 2.45rem);
    line-height: 1;
    letter-spacing: -.045em;
    font-weight: 950;
}

.ssl-auth-card-header p {
    margin: 0;
    color: #59667f;
    font-size: 1.03rem;
    line-height: 1.35;
    font-weight: 700;
}

.ssl-auth-form {
    display: grid;
    gap: 19px;
}

.ssl-auth-form label {
    display: grid;
    gap: 9px;
    color: #071a41;
}

.ssl-auth-form .field-caption {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #071a41;
    font-size: .92rem;
    font-weight: 950;
}

.ssl-input-wrap {
    min-height: 58px;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    border: 1px solid #d3dbe8;
    border-radius: 10px;
    background: #ffffff;
    padding: 0 15px;
    color: #7d8799;
    transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.ssl-input-wrap:focus-within {
    border-color: #129331;
    box-shadow: 0 0 0 4px rgba(18, 147, 49, .10);
    transform: translateY(-1px);
}

.ssl-auth-form input:not([type="checkbox"]) {
    width: 100%;
    min-height: 56px;
    border: 0 !important;
    border-radius: 0;
    background: transparent !important;
    color: #071a41;
    padding: 0;
    font: inherit;
    font-weight: 750;
    outline: 0 !important;
    box-shadow: none !important;
}

.ssl-auth-form input::placeholder { color: #98a1b4; }

.ssl-login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 2px;
}

.ssl-auth-remember {
    display: inline-flex !important;
    grid-template-columns: none !important;
    flex-direction: row;
    align-items: center;
    gap: 9px !important;
    color: #56627a !important;
    font-weight: 750;
    white-space: nowrap;
}

.ssl-auth-remember input {
    width: 18px;
    height: 18px;
    accent-color: #11932b;
}

.ssl-auth-link,
.ssl-auth-switch button,
.ssl-auth-switch a,
.ssl-auth-alert a {
    border: 0;
    background: transparent;
    color: #078a27;
    padding: 0;
    min-height: auto;
    font: inherit;
    font-weight: 950;
    text-decoration: none;
    cursor: pointer;
}

.ssl-auth-link:hover,
.ssl-auth-switch button:hover,
.ssl-auth-switch a:hover,
.ssl-auth-alert a:hover {
    background: transparent;
    text-decoration: underline;
}

.ssl-auth-submit {
    min-height: 58px;
    width: 100%;
    justify-content: center;
    border-radius: 10px;
    background: linear-gradient(180deg, #14a83a 0%, #07912b 100%) !important;
    color: #ffffff !important;
    border: 1px solid #078a27 !important;
    box-shadow: 0 18px 32px rgba(10, 142, 44, .28);
    font-size: 1.04rem;
    font-weight: 950;
    letter-spacing: .01em;
}

.ssl-auth-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 22px 40px rgba(10, 142, 44, .33);
}

.ssl-auth-divider {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 14px;
    color: #66728a;
    font-size: .94rem;
    font-weight: 700;
}

.ssl-auth-divider::before,
.ssl-auth-divider::after {
    content: "";
    height: 1px;
    background: #e1e7f0;
}

.ssl-google-button {
    min-height: 56px;
    width: 100%;
    justify-content: center;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    border-radius: 10px;
    border: 1px solid #d5dde9;
    background: #ffffff;
    color: #33415b;
    font-weight: 900;
    cursor: not-allowed;
    opacity: .78;
}

.ssl-google-button span {
    display: inline-grid;
    place-items: center;
    width: 22px;
    height: 22px;
    color: #1a73e8;
    font-weight: 950;
    font-size: 1.12rem;
}

.ssl-auth-switch {
    margin: 4px 0 0;
    text-align: center;
    color: #56627a;
    font-weight: 700;
}

.ssl-auth-alert {
    margin: 0 0 18px;
    border-radius: 14px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-weight: 800;
}

.ssl-auth-alert button,
.ssl-auth-alert a {
    min-height: 32px;
    padding: 6px 12px;
    border-radius: 10px;
    background: #ffffff;
    font-weight: 950;
}

.ssl-auth-trust {
    width: min(560px, 100%);
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
}

.ssl-auth-trust > div {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    padding: 6px 18px;
    position: relative;
}

.ssl-auth-trust > div + div::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 1px;
    background: #d9e1ec;
}

.ssl-auth-trust span {
    grid-row: span 2;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    font-size: 1rem;
}

.ssl-auth-trust strong {
    color: #071a41;
    font-size: .95rem;
    line-height: 1.15;
    font-weight: 950;
}

.ssl-auth-trust small {
    color: #56627a;
    font-size: .8rem;
    line-height: 1.35;
    font-weight: 600;
}

/* Garantiza que los logos con fondo blanco queden integrados en superficies blancas. */
.ssl-auth-logo-shell,
.app-topbar-brand,
.selector-brand-logo-wrap,
.loading-brand-row,
.admin-hero .brand-logo-wrap {
    background: #ffffff !important;
}

.ssl-auth-logo,
.app-topbar-brand img,
.selector-brand-logo,
.loading-brand-logo,
.admin-brand-logo,
.admin-hero img {
    background-color: #ffffff !important;
    border: 0 !important;
    box-shadow: none !important;
    mix-blend-mode: normal;
}

@media (max-width: 1220px) {
    .ssl-auth-layout {
        grid-template-columns: 1fr;
        align-items: start;
        gap: 34px;
    }

    .ssl-auth-background {
        background: linear-gradient(180deg, #ffffff 0 58%, #f5f8fc 58% 100%);
    }

    .ssl-auth-copy,
    .ssl-auth-copy h1,
    .ssl-auth-copy p,
    .ssl-auth-feature-grid,
    .ssl-auth-stats {
        max-width: 100%;
    }

    .ssl-auth-side {
        justify-items: start;
    }

    .ssl-auth-card,
    .ssl-auth-trust {
        width: min(680px, 100%);
    }
}

@media (max-width: 820px) {
    .ssl-auth-page { overflow-y: auto; }

    .ssl-auth-layout {
        padding: 22px;
    }

    .ssl-auth-feature-grid,
    .ssl-auth-stats,
    .ssl-auth-trust {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ssl-auth-stats > div:nth-child(3)::before,
    .ssl-auth-trust > div:nth-child(3)::before {
        display: none;
    }

    .ssl-auth-card {
        min-height: auto;
        border-radius: 22px;
    }
}

@media (max-width: 560px) {
    .ssl-auth-layout { padding: 18px; }
    .ssl-auth-copy h1 { font-size: clamp(2.25rem, 12vw, 3.4rem); }
    .ssl-auth-feature-grid,
    .ssl-auth-stats,
    .ssl-auth-trust { grid-template-columns: 1fr; }
    .ssl-auth-stats > div::before,
    .ssl-auth-trust > div::before { display: none !important; }
    .ssl-auth-stats > div { min-height: 70px; }
    .ssl-auth-card { padding: 28px 20px; }
    .ssl-login-options { align-items: flex-start; flex-direction: column; gap: 10px; }
}

/* v78 ajuste login: logo sobre zona blanca, tarjeta elevada y métricas alineadas abajo */
.ssl-auth-background {
    background: linear-gradient(105deg, #ffffff 0 58.2%, #f5f8fc 58.35% 100%) !important;
}

.ssl-auth-background::after {
    background: linear-gradient(101deg, transparent 0 58.25%, rgba(7, 17, 38, .026) 58.4% 100%) !important;
}

.ssl-auth-logo-shell {
    position: relative;
    isolation: isolate;
    padding: 10px 18px 10px 0;
    background: #ffffff !important;
}

.ssl-auth-logo-shell::before {
    content: "";
    position: absolute;
    z-index: -1;
    inset: -30px -42px -26px -120px;
    background: #ffffff;
    border-radius: 0 34px 34px 0;
}

.ssl-auth-logo {
    background: #ffffff !important;
    filter: drop-shadow(0 16px 28px rgba(7, 17, 38, .075));
}

@media (min-width: 1221px) {
    .ssl-auth-layout {
        align-items: stretch;
    }

    .ssl-auth-intro {
        align-content: stretch;
        grid-template-rows: auto auto auto minmax(18px, 1fr) auto;
    }

    .ssl-auth-intro > .ssl-auth-stats {
        align-self: end;
    }

    .ssl-auth-side {
        align-self: stretch;
        align-content: stretch;
        grid-template-rows: minmax(0, 1fr) auto;
        gap: 18px;
    }

    .ssl-auth-card {
        align-self: center;
        min-height: 600px;
        transform: translateY(-34px);
    }

    .ssl-auth-side-stats {
        align-self: end;
        width: min(560px, 100%);
    }
}

.ssl-auth-side-stats {
    border-radius: 15px;
    box-shadow: 0 18px 46px rgba(15, 30, 64, .09);
}

.ssl-auth-side-stats > div {
    min-height: 72px;
    grid-template-columns: 38px minmax(0, 1fr);
    column-gap: 10px;
    padding: 12px 14px;
}

.ssl-auth-side-stats .ssl-stat-icon {
    width: 38px;
    height: 38px;
    font-size: .98rem;
}

.ssl-auth-side-stats strong {
    font-size: clamp(.98rem, 1vw, 1.16rem);
    letter-spacing: -.018em;
}

.ssl-auth-side-stats span:last-child {
    font-size: .68rem;
    line-height: 1.2;
}

@media (max-width: 1220px) {
    .ssl-auth-background {
        background: linear-gradient(180deg, #ffffff 0 62%, #f5f8fc 62.2% 100%) !important;
    }

    .ssl-auth-logo-shell::before {
        inset: -22px -28px -20px -40px;
        border-radius: 0 26px 26px 0;
    }

    .ssl-auth-side-stats {
        width: min(680px, 100%);
    }
}

@media (max-width: 820px) {
    .ssl-auth-side-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ssl-auth-side-stats > div:nth-child(3)::before {
        display: none;
    }
}

@media (max-width: 560px) {
    .ssl-auth-side-stats {
        grid-template-columns: 1fr;
    }
}

/* v79 alineacion final login: tarjeta a la altura del logo, fondo blanco y metricas inferiores centradas */
.ssl-auth-page {
    background: #ffffff !important;
}

.ssl-auth-background {
    background: #ffffff !important;
}

.ssl-auth-background::after {
    background: linear-gradient(101deg, transparent 0 58.25%, rgba(7, 17, 38, .022) 58.4% 100%) !important;
}

.ssl-auth-logo-shell,
.ssl-auth-logo-shell::before {
    background: #ffffff !important;
}

.ssl-auth-logo {
    background: #ffffff !important;
    filter: none !important;
}

.ssl-auth-card {
    background: #ffffff !important;
    backdrop-filter: none !important;
}

.ssl-auth-stats {
    justify-self: center;
}

@media (min-width: 1221px) {
    .ssl-auth-layout {
        align-items: stretch !important;
        padding-top: clamp(44px, 4.8vw, 72px);
        padding-bottom: clamp(32px, 4vw, 58px);
    }

    .ssl-auth-intro {
        align-content: stretch !important;
        grid-template-rows: auto auto auto minmax(24px, 1fr) auto !important;
    }

    .ssl-auth-intro > .ssl-auth-stats {
        grid-row: 5;
        align-self: end !important;
        justify-self: center;
        margin: 0 auto;
    }

    .ssl-auth-side {
        align-self: stretch !important;
        align-content: stretch !important;
        align-items: stretch;
        justify-items: center;
        grid-template-rows: auto minmax(24px, 1fr) auto !important;
        gap: 0 !important;
    }

    .ssl-auth-card {
        grid-row: 1;
        align-self: start !important;
        justify-self: center;
        transform: none !important;
        min-height: 600px;
        margin: 0;
    }

    .ssl-auth-side-stats {
        grid-row: 3;
        align-self: end !important;
        justify-self: center;
        margin: 0 auto;
    }
}

@media (max-width: 1220px) {
    .ssl-auth-background,
    .ssl-auth-background::after {
        background: #ffffff !important;
    }

    .ssl-auth-side {
        justify-items: center !important;
    }

    .ssl-auth-card,
    .ssl-auth-side-stats,
    .ssl-auth-intro > .ssl-auth-stats {
        margin-left: auto;
        margin-right: auto;
    }
}


/* v80 login: una sola tarjeta de metricas, colocada debajo del login y alineada con la fila de Resultados claros */
@media (min-width: 1221px) {
    .ssl-auth-intro {
        grid-template-rows: auto auto auto !important;
        align-content: start !important;
    }

    .ssl-auth-intro > .ssl-auth-stats {
        display: none !important;
    }

    .ssl-auth-side {
        grid-template-rows: auto auto !important;
        align-content: start !important;
        align-items: start !important;
        gap: clamp(18px, 2vw, 28px) !important;
    }

    .ssl-auth-card {
        align-self: start !important;
    }

    .ssl-auth-side-stats {
        grid-row: 2 !important;
        align-self: start !important;
        justify-self: center !important;
        margin: 0 auto !important;
        transform: none !important;
    }
}

@media (max-width: 1220px) {
    .ssl-auth-intro > .ssl-auth-stats {
        display: none !important;
    }

    .ssl-auth-side-stats {
        margin-top: 0 !important;
    }
}

/* v83 loading update screen: swap logo positions and integrate white-background brand assets */
.loading-overlay {
    background: #ffffff !important;
    gap: clamp(18px, 2.4vw, 30px) !important;
    align-content: center !important;
    justify-items: center !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.loading-brand-row.loading-brand-row-outside {
    width: min(520px, calc(100vw - 48px)) !important;
    min-height: 128px !important;
    margin: 0 !important;
    padding: 18px 24px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #ffffff !important;
    border-radius: 0 !important;
    border: 0 !important;
    box-shadow: none !important;
}

.loading-brand-row.loading-brand-row-outside .loading-brand-logo {
    width: 100% !important;
    height: auto !important;
    max-width: 500px !important;
    max-height: 112px !important;
    padding: 0 !important;
    object-fit: contain !important;
    background: #ffffff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: none !important;
    mix-blend-mode: normal !important;
}

.loading-card {
    width: min(460px, calc(100vw - 48px)) !important;
    padding: 30px 28px 28px !important;
    background: #ffffff !important;
    border: 1px solid #dbe5f3 !important;
    box-shadow: 0 28px 80px rgba(15, 30, 64, .14) !important;
}

.loading-card .loading-lottery-logo-in-card {
    position: static !important;
    width: 104px !important;
    height: 104px !important;
    margin: 0 0 4px !important;
    padding: 12px !important;
    display: grid !important;
    place-items: center !important;
    background: #ffffff !important;
    border: 1px solid #dbe5f3 !important;
    border-radius: 26px !important;
    box-shadow: 0 18px 42px rgba(15, 30, 64, .10) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.loading-card .loading-lottery-logo-in-card img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

@media (max-width: 640px) {
    .loading-overlay {
        padding: 18px !important;
        gap: 18px !important;
    }

    .loading-brand-row.loading-brand-row-outside {
        width: min(430px, calc(100vw - 28px)) !important;
        min-height: 96px !important;
        padding: 12px 14px !important;
    }

    .loading-brand-row.loading-brand-row-outside .loading-brand-logo {
        max-height: 86px !important;
    }

    .loading-card {
        width: min(380px, calc(100vw - 28px)) !important;
        padding: 24px 20px 22px !important;
    }

    .loading-card .loading-lottery-logo-in-card {
        width: 88px !important;
        height: 88px !important;
        border-radius: 22px !important;
    }
}

/* v84 admin page: transparent brand logo integration and reliable action buttons */
.admin-page {
    background: linear-gradient(180deg, #f7fbff 0%, #edf3fb 100%) !important;
}

.admin-hero {
    align-items: stretch !important;
    background: linear-gradient(135deg, #071126 0%, #0f2552 58%, #ffffff 58.15%, #ffffff 100%) !important;
}

.admin-hero > div:first-child {
    min-width: 0;
    flex: 1 1 auto;
    align-self: center;
}

.admin-hero-logo-panel {
    flex: 0 0 min(500px, 36vw);
    min-height: 168px;
    display: grid;
    place-items: center;
    padding: clamp(12px, 2vw, 24px);
    background: #ffffff !important;
    border-radius: 28px;
    box-shadow: none !important;
    overflow: visible;
}

.admin-hero .admin-brand-logo,
.admin-hero-logo-panel img.admin-brand-logo {
    display: block;
    width: min(460px, 100%);
    height: auto;
    max-height: 150px;
    object-fit: contain;
    background: transparent !important;
    background-color: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: none !important;
    mix-blend-mode: normal;
}

.admin-actions form,
.admin-inline-form {
    margin: 0;
}

.admin-actions button,
.admin-inline-form button {
    position: relative;
    z-index: 1;
    pointer-events: auto;
    white-space: nowrap;
}

.admin-actions button.primary,
.admin-inline-form button {
    border-color: #0f9f3d !important;
    background: linear-gradient(180deg, #16a645 0%, #0b8f32 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 10px 22px rgba(15, 159, 61, .18);
}

.admin-actions button.primary:hover,
.admin-inline-form button:hover {
    border-color: #087a2b !important;
    color: #ffffff !important;
    transform: translateY(-1px);
}

.admin-actions button.danger {
    border-color: #fca5a5 !important;
    background: #fff5f5 !important;
    color: #b91c1c !important;
}

.admin-actions button.danger:hover {
    border-color: #dc2626 !important;
    background: #fee2e2 !important;
    color: #991b1b !important;
}

@media (max-width: 1120px) {
    .admin-hero {
        background: linear-gradient(180deg, #071126 0%, #0f2552 58%, #ffffff 58.2%, #ffffff 100%) !important;
    }

    .admin-hero-logo-panel {
        flex: 1 1 auto;
        width: 100%;
        min-height: 130px;
    }
}

@media (max-width: 760px) {
    .admin-hero {
        align-items: stretch !important;
    }

    .admin-hero-logo-panel {
        width: 100%;
        flex-basis: auto;
    }

    .admin-hero .admin-brand-logo {
        width: min(360px, 100%);
    }
}

/* v85 startup updater and selector logo refinement */
.loading-overlay:not(.inline-loading-overlay) {
    align-content: start !important;
    justify-items: center !important;
    gap: clamp(16px, 2.4vh, 30px) !important;
    padding-top: clamp(34px, 7vh, 86px) !important;
    background: #ffffff !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.loading-brand-row.loading-brand-row-outside {
    width: min(760px, calc(100vw - 40px)) !important;
    min-height: 126px !important;
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

.loading-brand-row.loading-brand-row-outside .loading-brand-logo,
.loading-brand-logo {
    width: min(720px, 82vw) !important;
    height: auto !important;
    max-height: 142px !important;
    object-fit: contain !important;
    object-position: center center !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    filter: none !important;
}

.loading-card.startup-update-card {
    width: min(900px, calc(100vw - 44px)) !important;
    min-height: 560px !important;
    padding: clamp(36px, 4vw, 54px) clamp(42px, 5vw, 70px) clamp(34px, 4vw, 50px) !important;
    gap: clamp(17px, 2vh, 24px) !important;
    border-radius: 34px !important;
    background: #ffffff !important;
    border: 1px solid #dce6f6 !important;
    box-shadow: 0 34px 92px rgba(15, 30, 64, .14) !important;
}

.loading-card.startup-update-card .loading-lottery-logo-in-card {
    width: 148px !important;
    height: 148px !important;
    border-radius: 34px !important;
    padding: 16px !important;
    background: #ffffff !important;
    border: 1px solid #dce6f6 !important;
    box-shadow: 0 20px 54px rgba(15, 30, 64, .12) !important;
    backdrop-filter: none !important;
}

.loading-card.startup-update-card .loading-lottery-logo-in-card img {
    width: 118px !important;
    height: 118px !important;
    object-fit: contain !important;
}

.loading-card.startup-update-card .loading-spinner {
    width: 44px !important;
    height: 44px !important;
    border-width: 5px !important;
}

.loading-card.startup-update-card strong {
    font-size: clamp(1.55rem, 2.2vw, 2rem) !important;
    letter-spacing: -.03em !important;
    color: #071126 !important;
}

.loading-card.startup-update-card span {
    max-width: 720px !important;
    font-size: 1.05rem !important;
    color: #50607d !important;
}

.loading-card.startup-update-card .loading-progress {
    width: min(720px, 100%) !important;
}

.selector-hero-branded {
    background: #ffffff !important;
}

.selector-hero-branded .selector-brand-logo {
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: none !important;
}

@media (max-width: 760px) {
    .loading-overlay:not(.inline-loading-overlay) {
        padding-top: 24px !important;
        gap: 14px !important;
    }

    .loading-brand-row.loading-brand-row-outside {
        width: min(460px, calc(100vw - 28px)) !important;
        min-height: 96px !important;
    }

    .loading-brand-row.loading-brand-row-outside .loading-brand-logo,
    .loading-brand-logo {
        width: min(430px, 88vw) !important;
        max-height: 96px !important;
    }

    .loading-card.startup-update-card {
        width: min(440px, calc(100vw - 28px)) !important;
        min-height: 500px !important;
        padding: 28px 22px 24px !important;
        border-radius: 28px !important;
    }

    .loading-card.startup-update-card .loading-lottery-logo-in-card {
        width: 112px !important;
        height: 112px !important;
        border-radius: 26px !important;
        padding: 12px !important;
    }

    .loading-card.startup-update-card .loading-lottery-logo-in-card img {
        width: 88px !important;
        height: 88px !important;
    }

    .loading-card.startup-update-card strong {
        font-size: 1.35rem !important;
    }
}

/* v86: quitar recuadro de foco de FocusOnNavigate en títulos al cargar páginas */
h1[tabindex="-1"]:focus,
h2[tabindex="-1"]:focus,
h3[tabindex="-1"]:focus,
[tabindex="-1"]:focus:not(input):not(select):not(textarea):not(button):not(a) {
    outline: none !important;
    box-shadow: none !important;
}

/* v86: panel admin en tarjetas por usuario y acciones con confirmación visual */
.admin-users-list {
    display: grid;
    gap: 16px;
}

.admin-user-card {
    background: #ffffff;
    border: 1px solid #dce6f6;
    border-radius: 26px;
    box-shadow: 0 20px 58px rgba(15, 30, 64, .09);
    padding: clamp(16px, 2vw, 22px);
    display: grid;
    gap: 14px;
    overflow: hidden;
}

.admin-user-line {
    min-width: 0;
}

.admin-user-main-line {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(260px, .72fr) minmax(340px, auto);
    gap: 16px;
    align-items: center;
}

.admin-user-identity {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    min-width: 0;
}

.admin-user-avatar {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #eaf8ee 0%, #eef4ff 100%);
    color: #087a2b !important;
    font-weight: 1000;
    letter-spacing: .03em;
    border: 1px solid #d8eee0;
}

.admin-user-identity strong {
    display: block;
    color: #071126;
    font-size: 1.08rem;
    letter-spacing: -.02em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-user-identity span:not(.admin-user-avatar) {
    display: block;
    color: #5f6f8b;
    font-weight: 800;
    margin-top: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

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

.admin-user-dates span,
.admin-usage-detail span {
    display: grid;
    gap: 3px;
    min-width: 0;
    padding: 10px 12px;
    border-radius: 16px;
    background: #f7faff;
    border: 1px solid #e0e9f8;
}

.admin-user-dates small,
.admin-usage-detail small {
    color: #6a7894;
    font-size: .72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.admin-user-dates strong,
.admin-usage-detail strong {
    color: #071126;
    font-size: .9rem;
    font-weight: 900;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.admin-user-status-line {
    padding-top: 2px;
}

.admin-user-detail-line {
    display: grid;
    grid-template-columns: minmax(320px, 1fr) minmax(380px, .95fr);
    gap: 14px;
    align-items: stretch;
}

.admin-usage-detail {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.pill.neutral {
    background: #f4f7fb;
    color: #475569;
}

.admin-actions {
    justify-content: flex-end;
    align-items: center;
}

.admin-actions form,
.admin-edit-form {
    margin: 0;
}

.admin-actions button,
.admin-inline-form button {
    min-height: 38px;
    border-radius: 13px;
}

.admin-edit-form {
    align-self: stretch;
    display: grid !important;
    grid-template-columns: minmax(120px, 1fr) minmax(180px, 1.25fr) auto !important;
    align-items: center;
    gap: 9px;
    padding: 12px;
    border-radius: 18px;
    background: #f8fbff;
    border: 1px solid #e0e9f8;
}

.admin-edit-form input {
    min-height: 40px !important;
    background: #ffffff !important;
}

.ssl-confirm-open body {
    overflow: hidden;
}

.ssl-confirm-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    place-items: center;
    padding: 24px;
    background: rgba(7, 17, 38, .46);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.ssl-confirm-backdrop.show {
    display: grid;
}

.ssl-confirm-dialog {
    width: min(460px, calc(100vw - 40px));
    border-radius: 28px;
    padding: 26px;
    background: #ffffff;
    border: 1px solid #dce6f6;
    box-shadow: 0 34px 100px rgba(7, 17, 38, .28);
    display: grid;
    gap: 18px;
    text-align: center;
    animation: sslConfirmPop .16s ease-out;
}

.ssl-confirm-icon {
    width: 58px;
    height: 58px;
    border-radius: 20px;
    display: grid;
    place-items: center;
    justify-self: center;
    background: #eaf8ee;
    color: #087a2b;
    font-size: 1.6rem;
    font-weight: 1000;
    border: 1px solid #c9ebd1;
}

.ssl-confirm-backdrop.danger .ssl-confirm-icon {
    background: #fff1f2;
    color: #b91c1c;
    border-color: #fecaca;
}

.ssl-confirm-copy h2 {
    margin: 0 0 7px;
    color: #071126;
    font-size: 1.35rem;
    letter-spacing: -.03em;
}

.ssl-confirm-copy p {
    margin: 0;
    color: #52617d;
    font-weight: 750;
    line-height: 1.45;
}

.ssl-confirm-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.ssl-confirm-actions button {
    min-height: 44px;
    border-radius: 15px;
    border: 1px solid #d5e1f6;
    cursor: pointer;
    font-weight: 950;
    padding: 10px 14px;
}

.ssl-confirm-cancel {
    background: #ffffff;
    color: #071126;
}

.ssl-confirm-accept {
    background: linear-gradient(180deg, #16a645 0%, #0b8f32 100%);
    color: #ffffff;
    border-color: #0b8f32 !important;
    box-shadow: 0 12px 28px rgba(15, 159, 61, .22);
}

.ssl-confirm-backdrop.danger .ssl-confirm-accept {
    background: linear-gradient(180deg, #ef4444 0%, #b91c1c 100%);
    border-color: #b91c1c !important;
    box-shadow: 0 12px 28px rgba(185, 28, 28, .22);
}

.ssl-progress-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10001;
    display: none;
    place-items: center;
    padding: 24px;
    background: rgba(7, 17, 38, .50);
    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);
}

.ssl-progress-backdrop.show {
    display: grid;
}

.ssl-progress-dialog {
    width: min(520px, calc(100vw - 40px));
    border-radius: 28px;
    padding: 28px;
    background: #ffffff;
    border: 1px solid #dce6f6;
    box-shadow: 0 34px 100px rgba(7, 17, 38, .30);
    display: grid;
    gap: 18px;
    text-align: center;
    animation: sslConfirmPop .16s ease-out;
}

.ssl-progress-spinner {
    width: 56px;
    height: 56px;
    justify-self: center;
    border-radius: 50%;
    border: 5px solid #dfe9fb;
    border-top-color: #168a26;
    animation: sslProgressSpin .8s linear infinite;
}

.ssl-progress-copy h2 {
    margin: 0 0 7px;
    color: #071126;
    font-size: 1.35rem;
    letter-spacing: -.03em;
}

.ssl-progress-copy p {
    margin: 0;
    color: #52617d;
    font-weight: 800;
    line-height: 1.45;
}

.ssl-progress-copy small {
    display: block;
    margin-top: 8px;
    color: #72809a;
    font-weight: 850;
}

.ssl-progress-bar {
    height: 12px;
    overflow: hidden;
    border-radius: 999px;
    background: #e8eef9;
    border: 1px solid #d9e4f5;
}

.ssl-progress-bar span {
    display: block;
    width: 8%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #16a645 0%, #43d26f 100%);
    transition: width .25s ease;
}

@keyframes sslProgressSpin {
    to { transform: rotate(360deg); }
}

@keyframes sslConfirmPop {
    from { opacity: 0; transform: translateY(12px) scale(.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* fix - Quiniela simulación objetivo: espaciado acotado a esta página */
.quiniela-target-command-grid {
    margin-bottom: 24px;
}

.quiniela-target-objective-metrics {
    margin-top: 24px;
    margin-bottom: 24px;
    gap: 16px;
}

.quiniela-target-objective-metrics + .tabs {
    margin-top: 0;
    margin-bottom: 22px;
}

.quiniela-target-card-fill,
.quiniela-target-reading-card {
    min-width: 0;
}

/* v86: pantalla de actualización más grande, más arriba y en tarjeta apaisada */
.loading-card-content {
    display: contents;
}

.loading-overlay:not(.inline-loading-overlay) {
    align-content: start !important;
    padding-top: clamp(22px, 5vh, 58px) !important;
    gap: clamp(16px, 2.2vh, 26px) !important;
}

.loading-brand-row.loading-brand-row-outside {
    width: min(760px, calc(100vw - 48px)) !important;
    min-height: 170px !important;
    padding: 18px 26px !important;
}

.loading-brand-row.loading-brand-row-outside .loading-brand-logo,
.loading-brand-logo {
    max-width: 700px !important;
    max-height: 150px !important;
}

.loading-card.startup-update-card {
    width: min(900px, calc(100vw - 48px)) !important;
    min-height: 300px !important;
    padding: clamp(30px, 3vw, 44px) !important;
    display: grid !important;
    grid-template-columns: minmax(170px, 220px) minmax(0, 1fr) !important;
    grid-template-areas: "lottery content" !important;
    align-items: center !important;
    justify-items: stretch !important;
    gap: clamp(26px, 4vw, 46px) !important;
    text-align: left !important;
    border-radius: 38px !important;
}

.loading-card.startup-update-card .loading-lottery-logo-in-card {
    grid-area: lottery !important;
    width: 190px !important;
    height: 190px !important;
    margin: 0 !important;
    padding: 18px !important;
    border-radius: 38px !important;
    justify-self: center !important;
    align-self: center !important;
}

.loading-card.startup-update-card .loading-lottery-logo-in-card img {
    width: 150px !important;
    height: 150px !important;
}

.loading-card.startup-update-card .loading-card-content {
    grid-area: content !important;
    display: grid !important;
    gap: 12px !important;
    justify-items: start !important;
    align-content: center !important;
    min-width: 0 !important;
}

.loading-card.startup-update-card .loading-spinner {
    width: 48px !important;
    height: 48px !important;
    border-width: 5px !important;
    justify-self: start !important;
}

.loading-card.startup-update-card strong {
    font-size: clamp(1.8rem, 3vw, 2.55rem) !important;
    line-height: 1.02 !important;
}

.loading-card.startup-update-card span {
    max-width: 620px !important;
    font-size: clamp(1.02rem, 1.3vw, 1.18rem) !important;
    line-height: 1.45 !important;
}

.loading-card.startup-update-card .loading-progress {
    width: min(620px, 100%) !important;
    margin-top: 6px !important;
}

.selector-hero-branded .selector-brand-logo,
.selector-brand-logo {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    filter: none !important;
    mix-blend-mode: normal !important;
}

@media (max-width: 1180px) {
    .admin-user-main-line,
    .admin-user-detail-line {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .admin-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 760px) {
    .admin-user-dates,
    .admin-usage-detail,
    .admin-edit-form {
        grid-template-columns: 1fr !important;
    }

    .ssl-confirm-actions {
        grid-template-columns: 1fr;
    }

    .loading-overlay:not(.inline-loading-overlay) {
        padding-top: 18px !important;
    }

    .loading-brand-row.loading-brand-row-outside {
        width: min(500px, calc(100vw - 28px)) !important;
        min-height: 118px !important;
        padding: 12px 16px !important;
    }

    .loading-brand-row.loading-brand-row-outside .loading-brand-logo,
    .loading-brand-logo {
        max-height: 108px !important;
    }

    .loading-card.startup-update-card {
        width: min(500px, calc(100vw - 28px)) !important;
        min-height: auto !important;
        grid-template-columns: 1fr !important;
        grid-template-areas: "lottery" "content" !important;
        text-align: center !important;
        padding: 28px 22px 24px !important;
        gap: 18px !important;
    }

    .loading-card.startup-update-card .loading-lottery-logo-in-card {
        width: 132px !important;
        height: 132px !important;
        border-radius: 30px !important;
    }

    .loading-card.startup-update-card .loading-lottery-logo-in-card img {
        width: 104px !important;
        height: 104px !important;
    }

    .loading-card.startup-update-card .loading-card-content,
    .loading-card.startup-update-card .loading-spinner {
        justify-items: center !important;
        justify-self: center !important;
        text-align: center !important;
    }
}


/* v87 dashboard Quiniela: centrar signos 1X2 y evitar desbordes */
.quiniela-latest-panel {
    overflow: hidden;
}

.quiniela-latest-aux-list {
    min-width: 0;
    justify-items: center;
    text-align: center;
}

.quiniela-latest-aux-list .quiniela-sign-strip {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 7px !important;
    max-width: 100%;
    min-width: 0;
    white-space: normal !important;
    overflow: visible;
}

.quiniela-latest-aux-list .quiniela-sign {
    box-sizing: border-box;
    flex: 0 0 32px;
    width: 32px;
    min-width: 32px;
    height: 32px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

/* fix - Quiniela dashboard: resumen 1X2 en una sola línea */
.quiniela-latest-panel .quiniela-latest-aux-list {
    justify-items: start;
    text-align: left;
    transform: translateX(-18px);
}

.quiniela-latest-panel .quiniela-latest-aux-list .quiniela-sign-strip {
    flex-wrap: nowrap !important;
    justify-content: flex-start !important;
    gap: 4px !important;
    white-space: nowrap !important;
}

.quiniela-latest-panel .quiniela-latest-aux-list .quiniela-sign {
    flex-basis: 25px;
    width: 25px;
    min-width: 25px;
    height: 25px;
    font-size: .78rem;
}

/* fix - Quiniela dashboard: dar ancho real al resumen 1X2 */
.latest-draw-panel.quiniela-latest-panel {
    grid-template-columns: minmax(0, .95fr) minmax(460px, 1.05fr) !important;
}

.latest-draw-panel.quiniela-latest-panel .quiniela-latest-aux-list {
    width: 100%;
    max-width: none;
}

.latest-draw-panel.quiniela-latest-panel .quiniela-latest-aux-list .quiniela-sign-strip {
    width: max-content;
    max-width: none;
    overflow: visible;
}

.latest-draw-panel.quiniela-latest-panel .quiniela-latest-aux-list .quiniela-sign {
    flex: 0 0 24px !important;
    width: 24px !important;
    min-width: 24px !important;
    height: 24px !important;
}

@media (max-width: 1280px) {
    .quiniela-latest-panel {
        grid-template-columns: 1fr;
    }
}

/* v87 panel admin: acceso claro para volver a selección de sorteos */
.admin-hero-actions {
    margin-top: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.admin-back-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 18px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,.42);
    background: rgba(255,255,255,.12);
    color: #ffffff !important;
    font-weight: 950;
    letter-spacing: .01em;
    text-decoration: none !important;
    box-shadow: 0 16px 34px rgba(3, 10, 28, .18);
    backdrop-filter: blur(10px);
}

.admin-back-button:hover,
.admin-back-button:focus-visible {
    background: #ffffff;
    color: #071126 !important;
    border-color: #ffffff;
    transform: translateY(-1px);
}

/* v88: pantalla de actualización inicial corregida: logo de app grande, sorteo centrado y datos debajo */
.loading-overlay:not(.inline-loading-overlay) {
    align-content: start !important;
    justify-items: center !important;
    padding: clamp(20px, 3vh, 34px) clamp(18px, 3vw, 42px) !important;
    gap: clamp(14px, 2vh, 22px) !important;
    background: #ffffff !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.loading-brand-row.loading-brand-row-outside {
    width: min(900px, calc(100vw - 40px)) !important;
    min-height: clamp(150px, 20vh, 220px) !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #ffffff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

.loading-brand-row.loading-brand-row-outside .loading-brand-logo,
.loading-brand-logo {
    display: block !important;
    width: min(860px, 88vw) !important;
    height: auto !important;
    max-width: min(860px, 88vw) !important;
    max-height: clamp(140px, 19vh, 210px) !important;
    object-fit: contain !important;
    object-position: center center !important;
    background: #ffffff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: none !important;
    mix-blend-mode: normal !important;
}

.loading-card.startup-update-card {
    width: min(980px, calc(100vw - 44px)) !important;
    min-height: 0 !important;
    padding: clamp(26px, 3.2vw, 42px) !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-areas:
        "lottery"
        "content" !important;
    align-items: center !important;
    justify-items: center !important;
    gap: clamp(20px, 3vh, 30px) !important;
    text-align: center !important;
    border-radius: 36px !important;
    background: #ffffff !important;
    border: 1px solid #dce6f6 !important;
    box-shadow: 0 30px 90px rgba(15, 30, 64, .13) !important;
}

.loading-card.startup-update-card .loading-lottery-logo-in-card {
    grid-area: lottery !important;
    width: min(740px, 100%) !important;
    height: clamp(190px, 24vh, 250px) !important;
    margin: 0 !important;
    padding: clamp(22px, 3vw, 34px) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    justify-self: center !important;
    align-self: center !important;
    border-radius: 32px !important;
    background: #ffffff !important;
    border: 1px solid #dce6f6 !important;
    box-shadow: 0 18px 52px rgba(15, 30, 64, .10) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.loading-card.startup-update-card .loading-lottery-logo-in-card img {
    display: block !important;
    width: auto !important;
    height: auto !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}

.loading-card.startup-update-card .loading-card-content {
    grid-area: content !important;
    width: min(760px, 100%) !important;
    display: grid !important;
    justify-items: center !important;
    align-content: center !important;
    gap: 12px !important;
    text-align: center !important;
    min-width: 0 !important;
}

.loading-card.startup-update-card .loading-spinner {
    width: 46px !important;
    height: 46px !important;
    border-width: 5px !important;
    justify-self: center !important;
}

.loading-card.startup-update-card strong {
    font-size: clamp(1.75rem, 2.6vw, 2.45rem) !important;
    line-height: 1.05 !important;
    color: #071126 !important;
    letter-spacing: -.035em !important;
    text-align: center !important;
}

.loading-card.startup-update-card span {
    max-width: 720px !important;
    font-size: clamp(1rem, 1.35vw, 1.16rem) !important;
    line-height: 1.45 !important;
    color: #50607d !important;
    text-align: center !important;
}

.loading-card.startup-update-card .loading-progress {
    width: min(720px, 100%) !important;
    margin-top: 6px !important;
}

.loading-card.startup-update-card .loading-progress-text {
    justify-content: space-between !important;
    text-align: left !important;
}

@media (max-width: 760px) {
    .loading-overlay:not(.inline-loading-overlay) {
        padding: 18px 14px !important;
        gap: 14px !important;
    }

    .loading-brand-row.loading-brand-row-outside {
        width: min(520px, calc(100vw - 28px)) !important;
        min-height: 118px !important;
    }

    .loading-brand-row.loading-brand-row-outside .loading-brand-logo,
    .loading-brand-logo {
        width: min(500px, 92vw) !important;
        max-width: min(500px, 92vw) !important;
        max-height: 112px !important;
    }

    .loading-card.startup-update-card {
        width: min(520px, calc(100vw - 28px)) !important;
        padding: 22px 18px !important;
        border-radius: 28px !important;
        gap: 18px !important;
    }

    .loading-card.startup-update-card .loading-lottery-logo-in-card {
        width: 100% !important;
        height: 148px !important;
        border-radius: 24px !important;
        padding: 16px !important;
    }

    .loading-card.startup-update-card .loading-spinner {
        width: 40px !important;
        height: 40px !important;
    }

    .loading-card.startup-update-card strong {
        font-size: 1.45rem !important;
    }

    .loading-card.startup-update-card span {
        font-size: .96rem !important;
    }
}

/* v89 admin: edicion alineada con estados, detalles plegables y tarjeta de carga unificada */
.admin-user-card {
    gap: 12px !important;
}

.admin-user-status-line {
    display: grid !important;
    grid-template-columns: minmax(300px, 1fr) minmax(520px, auto) !important;
    gap: 14px !important;
    align-items: center !important;
}

.admin-user-status-line .status-pills {
    justify-content: flex-start !important;
    align-items: center !important;
    min-width: 0 !important;
}

.admin-status-edit-form {
    justify-self: end !important;
    width: min(760px, 100%) !important;
    grid-template-columns: minmax(170px, 1fr) minmax(230px, 1.15fr) auto !important;
    margin-left: auto !important;
}

.admin-user-detail-line {
    grid-template-columns: 1fr !important;
    padding: 12px !important;
    border-radius: 20px !important;
    background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%) !important;
    border: 1px solid #e0e9f8 !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.85) !important;
}

.admin-user-detail-line[hidden] {
    display: none !important;
}

.admin-user-card.details-open {
    border-color: #bdd2f2 !important;
    box-shadow: 0 26px 72px rgba(15, 30, 64, .12) !important;
}

.admin-user-card.details-open .admin-user-detail-line {
    display: grid !important;
}

.admin-details-toggle {
    border-color: #cfe0fb !important;
    background: #f7fbff !important;
    color: #0f2552 !important;
}

.admin-details-toggle:hover,
.admin-details-toggle:focus-visible,
.admin-user-card.details-open .admin-details-toggle {
    border-color: #3157ff !important;
    background: #eef4ff !important;
    color: #3157ff !important;
}

.admin-usage-detail {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.loading-card.startup-update-card {
    isolation: isolate !important;
}

.loading-card.startup-update-card .loading-card-content {
    display: grid !important;
}

@media (max-width: 1320px) {
    .admin-user-main-line {
        grid-template-columns: minmax(260px, 1fr) minmax(260px, .8fr) !important;
    }

    .admin-actions {
        grid-column: 1 / -1 !important;
        justify-content: flex-start !important;
    }

    .admin-user-status-line {
        grid-template-columns: 1fr !important;
    }

    .admin-status-edit-form {
        justify-self: stretch !important;
        width: 100% !important;
        margin-left: 0 !important;
    }
}

@media (max-width: 760px) {
    .admin-user-status-line {
        gap: 10px !important;
    }

    .admin-status-edit-form {
        grid-template-columns: 1fr !important;
    }

    .admin-usage-detail {
        grid-template-columns: 1fr !important;
    }
}


/* v90 - Dashboard: boleto horizontal en columnas igual que Simulacion objetivo */
.dashboard-horizontal-ticket .real-ticket {
    max-width: none;
}

.dashboard-horizontal-ticket .original-ticket-plays {
    display: block;
    overflow-x: auto;
    padding-bottom: 2px;
}

.dashboard-horizontal-ticket .original-ticket-play {
    display: grid;
    grid-template-columns: max-content max-content;
    grid-template-areas:
        "main aux"
        "auto auto";
    column-gap: 16px;
    align-items: start;
    width: max-content;
    max-width: 100%;
}

.dashboard-horizontal-ticket .original-ticket-main-block {
    grid-area: main;
}

.dashboard-horizontal-ticket .original-ticket-main-label {
    display: block;
}

.dashboard-horizontal-ticket .original-ticket-aux-blocks {
    grid-area: aux;
    margin-top: 0;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: max-content;
    gap: 16px;
    align-items: start;
    align-content: start;
}

.dashboard-horizontal-ticket .original-ticket-aux-block {
    align-self: start;
}

.dashboard-horizontal-ticket .original-ticket-aux-label {
    min-height: 14px;
}

.dashboard-horizontal-ticket .original-ticket-auto {
    grid-area: auto;
    justify-self: start;
    width: 100%;
    text-align: center;
}

.dashboard-horizontal-ticket .original-ticket-main-grid {
    grid-area: auto;
}

.dashboard-real-ticket-wrap {
    overflow-x: auto;
}

@media (max-width: 720px) {
    .dashboard-horizontal-ticket .original-ticket-play {
        grid-template-columns: max-content;
        grid-template-areas:
            "main"
            "aux"
            "auto";
        row-gap: 8px;
    }

    .dashboard-horizontal-ticket .original-ticket-aux-blocks {
        grid-auto-flow: row;
        gap: 8px;
    }
}


/* v92 - Ajuste de pantalla de actualización: tarjeta del logo de sorteo más estrecha y progreso por sorteo completado */
.loading-card.startup-update-card .loading-lottery-logo-in-card {
    width: min(640px, 100%) !important;
    max-width: 100% !important;
}

.loading-card.startup-update-card .loading-progress-track span {
    transition: width .32s ease !important;
}

.loading-card.startup-update-card .loading-progress-text small:first-child {
    color: #0f2552 !important;
    font-weight: 950 !important;
}

.loading-card.startup-update-card .loading-progress-text small:last-child {
    color: #079536 !important;
    font-weight: 950 !important;
}

@media (max-width: 760px) {
    .loading-card.startup-update-card .loading-lottery-logo-in-card {
        width: 100% !important;
    }
}

/* v93 - Pantalla de actualización: tarjeta algo más ancha y progreso general único */
.loading-card.startup-update-card {
    width: min(1080px, calc(100vw - 44px)) !important;
}

.loading-card.startup-update-card .loading-lottery-logo-in-card {
    width: min(780px, 100%) !important;
    height: clamp(190px, 24vh, 250px) !important;
}

.loading-card.startup-update-card .loading-card-content {
    width: min(920px, 100%) !important;
}

.loading-card.startup-update-card span {
    max-width: 900px !important;
}

.loading-card.startup-update-card .loading-progress {
    width: min(860px, 100%) !important;
}

.loading-card.startup-update-card .loading-progress-text small:first-child {
    white-space: nowrap !important;
}

@media (min-width: 980px) {
    .loading-card.startup-update-card > .loading-card-content > strong,
    .loading-card.startup-update-card > .loading-card-content > span {
        white-space: nowrap !important;
    }
}

@media (max-width: 760px) {
    .loading-card.startup-update-card {
        width: min(520px, calc(100vw - 28px)) !important;
    }

    .loading-card.startup-update-card .loading-lottery-logo-in-card {
        width: 100% !important;
        height: 148px !important;
    }

    .loading-card.startup-update-card > .loading-card-content > strong,
    .loading-card.startup-update-card > .loading-card-content > span {
        white-space: normal !important;
    }
}


/* v94 - Corregir barra de progreso: las reglas genericas de .loading-card span forzaban el relleno al 100% */
.loading-card .loading-progress-track .loading-progress-fill {
    display: block !important;
    width: var(--loading-progress-value, 0%) !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 100% !important;
    border-radius: inherit !important;
    font-size: 0 !important;
    line-height: 0 !important;
    color: transparent !important;
    background: linear-gradient(90deg, var(--accent, #22c55e), color-mix(in srgb, var(--accent, #22c55e) 72%, #ffffff)) !important;
    transition: width .32s ease !important;
}

.loading-card .loading-progress-track .loading-progress-fill[style*="0%"] {
    min-width: 0 !important;
}

.checkbox-line {
    display: flex;
    align-items: center;
    gap: .6rem;
    min-height: 44px;
}

.checkbox-line input[type="checkbox"] {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
}

/* v95 - Sistemas / Reducciones: explicación de origen de base */
.base-source-table {
    margin-top: 16px;
}

.base-source-table td,
.base-source-table th {
    white-space: nowrap;
}

.base-source-table td:last-child {
    white-space: normal;
    min-width: 240px;
}

/* v124 - Restaurar menus de escritorio: los ajustes moviles solo aplican en pantallas pequenas reales. */
@media (min-width: 721px) {
    .shell.lottery-shell {
        min-height: 100vh;
        display: grid !important;
        grid-template-columns: 280px minmax(0, 1fr) !important;
    }

    .lottery-sidebar.sidebar {
        position: sticky !important;
        top: 0 !important;
        z-index: 1 !important;
        height: 100vh !important;
        max-height: 100vh !important;
        width: auto !important;
        padding: 18px 16px !important;
        overflow: hidden !important;
        border-right: 0 !important;
        border-bottom: 0 !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .mobile-lottery-bar {
        display: none !important;
    }

    .lottery-sidebar-inner {
        display: contents !important;
    }

    .lottery-sidebar.menu-open.sidebar::after {
        display: none !important;
    }

    .lottery-sidebar .sidebar-footer {
        display: grid !important;
        margin-top: 10px !important;
    }

    .lottery-sidebar .sidebar-update-status {
        display: grid !important;
        margin-top: 8px !important;
    }
}

@media (min-width: 981px) {
    .selector-shell {
        padding: 32px !important;
    }
}


/* v91: readable reduction metric cards and persistent reduction settings */
.reduction-reading-panel .metrics-grid.wheel-result-metrics {
    grid-template-columns: repeat(auto-fit, minmax(185px, 1fr));
    gap: 12px;
    overflow: visible;
}

.reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card,
.reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card-short,
.reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card-wide {
    grid-column: auto;
    min-width: 0;
    min-height: 108px;
}

.reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card .metric-card-header {
    align-items: flex-start;
    gap: 8px;
    min-height: auto;
}

.reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card .metric-label {
    flex: 1 1 auto;
    min-width: 0;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    line-height: 1.22;
    overflow-wrap: anywhere;
    padding-right: 0;
}

.reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card .metric-info-tip {
    flex: 0 0 auto;
    margin-left: 0;
}

.reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card strong {
    white-space: normal;
    word-break: normal;
    overflow-wrap: anywhere;
}

.wheel-value-summary {
    margin-top: 18px;
}

.wheel-value-summary .panel-title-row {
    align-items: start;
    margin-bottom: 14px;
}

.wheel-value-summary .wheel-summary-reading {
    margin: 14px 0 0;
    color: var(--muted);
    line-height: 1.45;
}

.metrics-grid.wheel-key-metrics {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    overflow: visible;
}

.metrics-grid.wheel-key-metrics > .metric-card,
.metrics-grid.wheel-key-metrics > .metric-card-short,
.metrics-grid.wheel-key-metrics > .metric-card-wide {
    grid-column: auto;
    min-width: 0;
    min-height: 104px;
}

.metrics-grid.wheel-key-metrics > .metric-card .metric-card-header {
    min-height: auto;
    align-items: flex-start;
}

.metrics-grid.wheel-key-metrics > .metric-card .metric-label,
.metrics-grid.wheel-key-metrics > .metric-card strong {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    overflow-wrap: anywhere;
}

@media (max-width: 980px) {
    .reduction-reading-panel .metrics-grid.wheel-result-metrics {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
        overflow: visible;
        padding-bottom: 0;
        scroll-snap-type: none;
    }

    .reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card,
    .reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card-short,
    .reduction-reading-panel .metrics-grid.wheel-result-metrics > .metric-card-wide {
        min-width: 0;
        width: auto;
        scroll-snap-align: none;
    }

    .metrics-grid.wheel-key-metrics {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
        overflow: visible;
        padding-bottom: 0;
        scroll-snap-type: none;
    }

    .metrics-grid.wheel-key-metrics > .metric-card,
    .metrics-grid.wheel-key-metrics > .metric-card-short,
    .metrics-grid.wheel-key-metrics > .metric-card-wide {
        min-width: 0;
        width: auto;
        scroll-snap-align: none;
    }
}
