﻿:root {
    --pvr-bg: #08111f;
    --pvr-header: #050d19;
    --pvr-panel: #101d32;
    --pvr-panel-2: #14243d;
    --pvr-input: #091426;
    --pvr-line: rgba(255,255,255,.14);
    --pvr-line-strong: rgba(255,255,255,.24);
    --pvr-text: #f5f7fb;
    --pvr-muted: #aebbd0;
    --pvr-gold: #f2c552;
    --pvr-green: #66d6a2;
    --pvr-red: #ff8989;
    --pvr-blue: #6cacff;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--pvr-bg); }
body { min-height: 100vh; margin: 0; color: var(--pvr-text); background: var(--pvr-bg); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }

.pvr-header { min-height: 58px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 6px 20px; border-bottom: 1px solid var(--pvr-line); background: var(--pvr-header); position: sticky; top: 0; z-index: 20; }
.pvr-header-side { min-width: 1px; }
.pvr-brand { grid-column: 2; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; font-weight: 800; white-space: nowrap; }
.pvr-brand img { width: 74px; height: auto; display: block; }
.pvr-brand span { color: var(--pvr-gold); font-size: .94rem; }
.pvr-account-area { grid-column: 3; display: flex; align-items: center; justify-content: flex-end; gap: 12px; min-width: 0; }
.pvr-account-link { color: var(--pvr-muted); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pvr-account-link:hover { color: var(--pvr-text); text-decoration: underline; }
.pvr-admin-link { color: var(--pvr-gold); font-weight: 800; }
.pvr-admin-link:hover { color: #ffd975; }
.pvr-logout-form { display: inline-flex; margin: 0; }
.pvr-link-button { border: 0; color: var(--pvr-gold); background: transparent; cursor: pointer; padding: 4px 0; font-weight: 700; }

.pvr-shell { width: calc(100% - 28px); max-width: none; margin: 0 auto; padding: 16px 0 28px; }
.pvr-page { margin: 0 auto; }
.pvr-page-medium { width: 100%; max-width: none; }
.pvr-page-wide { width: 100%; max-width: none; }
.pvr-page-head { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 10px; }
.pvr-page-head h1 { margin: 0; font-size: clamp(1.55rem, 2.5vw, 2.05rem); line-height: 1.08; }
.pvr-page-head > p { margin: 0; max-width: 620px; color: var(--pvr-muted); text-align: right; font-size: .9rem; line-height: 1.35; }
.pvr-hero { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 10px; }
.pvr-home-head { margin-bottom: 10px; }
.pvr-eyebrow { margin: 0 0 3px; color: var(--pvr-gold); text-transform: uppercase; letter-spacing: .13em; font-size: .66rem; font-weight: 800; }
.pvr-title { margin: 0; font-size: clamp(1.6rem, 2.7vw, 2.15rem); line-height: 1.06; }
.pvr-subtitle { margin: 5px 0 0; color: var(--pvr-muted); max-width: 820px; line-height: 1.35; font-size: .9rem; }

.pvr-mega-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.pvr-mega-card { min-height: 132px; display: grid; grid-template-columns: 34px 1fr; grid-template-rows: 1fr auto; gap: 8px 12px; padding: 14px; text-decoration: none; border: 1px solid var(--pvr-line); background: var(--pvr-panel-2); transition: border-color .12s ease, background .12s ease; }
.pvr-mega-card:hover { border-color: var(--pvr-gold); background: #182a47; }
.pvr-mega-icon { grid-row: 1 / 3; width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--pvr-line-strong); background: #26364b; color: var(--pvr-gold); font-size: 1.05rem; font-weight: 900; }
.pvr-mega-card h2 { margin: 0 0 3px; font-size: 1.02rem; }
.pvr-mega-card p { margin: 0; color: var(--pvr-muted); line-height: 1.3; font-size: .84rem; }
.pvr-card-state { color: var(--pvr-blue); font-size: .68rem; font-weight: 750; text-transform: uppercase; letter-spacing: .055em; }

.pvr-panel { border: 1px solid var(--pvr-line); background: var(--pvr-panel); padding: 13px; }
.pvr-panel + .pvr-panel { margin-top: 10px; }
.pvr-panel-tight { padding: 12px; }
.pvr-panel h1, .pvr-panel h2, .pvr-panel h3 { margin-top: 0; }
.pvr-panel h2 { margin-bottom: 8px; font-size: 1.05rem; }
.pvr-panel-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.pvr-panel-header p { margin: 2px 0 0; color: var(--pvr-muted); font-size: .85rem; }
.pvr-section-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.pvr-section-title h2 { margin: 0; font-size: 1.02rem; }
.pvr-section-title span { color: var(--pvr-muted); font-size: .8rem; }
.pvr-section-title-spaced { margin-top: 12px; }
.pvr-section-divider { height: 1px; margin: 12px 0; background: var(--pvr-line); }

.pvr-compact-page { width: min(760px, 100%); margin: 0 auto; }
.pvr-compact-head { margin-bottom: 9px; }
.pvr-compact-head h1 { margin: 0; font-size: 1.7rem; line-height: 1.08; }
.pvr-compact-head > p:last-child { margin: 4px 0 0; color: var(--pvr-muted); line-height: 1.35; font-size: .88rem; }

.pvr-form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 10px; }
.pvr-form-grid-compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pvr-form-grid-single { grid-template-columns: 1fr; }
.pvr-form-grid-dense { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.pvr-form-grid-scanner { grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: end; }
.pvr-field { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pvr-field-wide { grid-column: 1 / -1; }
.pvr-field-span-2 { grid-column: span 2; }
.pvr-field-small { max-width: 210px; }
.pvr-field label { color: #c5d0e2; font-size: .78rem; font-weight: 700; }
.pvr-field input, .pvr-field select, .pvr-field textarea { width: 100%; min-height: 36px; border: 1px solid var(--pvr-line-strong); border-radius: 0; background: var(--pvr-input); color: var(--pvr-text); padding: 6px 8px; outline: none; }
.pvr-field input[readonly] { color: var(--pvr-muted); background: #0c1728; }
.pvr-field textarea { min-height: 54px; resize: vertical; line-height: 1.3; }
.pvr-field input:focus, .pvr-field select:focus, .pvr-field textarea:focus { border-color: var(--pvr-blue); box-shadow: 0 0 0 1px rgba(103,169,255,.16); }
.pvr-provider-form { display: grid; grid-template-columns: minmax(260px, 1.3fr) 190px 150px; gap: 8px 10px; align-items: end; }
.pvr-provider-form > .pvr-field:nth-of-type(3), .pvr-provider-form > .pvr-field:nth-of-type(4) { grid-column: span 1; }
.pvr-provider-form > .pvr-field:nth-of-type(3) { grid-column: 1 / 2; }
.pvr-provider-form > .pvr-field:nth-of-type(4) { grid-column: 2 / 4; }
.pvr-check { display: flex; gap: 7px; align-items: center; color: var(--pvr-muted); font-size: .84rem; }
.pvr-check input { margin: 0; }
.pvr-check-inline { min-height: 36px; }
.pvr-check-centered { justify-content: center; margin-top: 8px; }
.pvr-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 9px; }
.pvr-actions-end { justify-content: flex-end; margin-top: 0; align-self: end; }
.pvr-actions-centered { justify-content: center; }
.pvr-btn { min-height: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid transparent; border-radius: 0; padding: 6px 11px; cursor: pointer; text-decoration: none; font-weight: 800; font-size: .84rem; }
.pvr-btn-primary { background: var(--pvr-gold); color: #171208; }
.pvr-btn-primary:hover { background: #ffd56e; }
.pvr-btn-secondary { background: #182c4a; color: #c4ddff; border-color: #36577f; }
.pvr-btn-danger { background: #3b1e25; color: #ffc0c0; border-color: #74404a; }
.pvr-btn-ghost { background: transparent; color: var(--pvr-muted); border-color: var(--pvr-line-strong); }
.pvr-btn-small { min-height: 27px; padding: 3px 7px; font-size: .72rem; }
.pvr-form-note { margin: 6px 0 0; color: var(--pvr-muted); font-size: .76rem; }

.pvr-alert { border: 1px solid var(--pvr-line-strong); border-radius: 0; padding: 8px 10px; margin-bottom: 9px; color: var(--pvr-muted); background: #0d1829; font-size: .84rem; }
.pvr-alert:empty, .validation-summary-valid { display: none; }
.pvr-alert-inline { padding: 7px 9px; }
.pvr-alert-ok { border-color: #33775b; color: #bcf4da; background: #0e2a20; }
.pvr-alert-warn { border-color: #756331; color: #f8dda0; background: #2b2512; }
.pvr-alert-error { border-color: #7f4141; color: #ffc0c0; background: #2c171a; }
.field-validation-error, .validation-summary-errors { color: #ffaaaa; font-size: .75rem; }

.pvr-table-wrap { overflow: auto; border: 1px solid var(--pvr-line); }
.pvr-table { width: 100%; min-width: 760px; border-collapse: collapse; table-layout: auto; background: #0b1628; font-size: .82rem; }
.pvr-table th, .pvr-table td { padding: 6px 8px; border-bottom: 1px solid rgba(255,255,255,.08); text-align: left; vertical-align: middle; line-height: 1.22; }
.pvr-table th { position: sticky; top: 0; z-index: 1; background: #162641; color: #dbe6f8; white-space: nowrap; }
.pvr-table th a { color: inherit; text-decoration: none; display: block; }
.pvr-table th a:hover { color: var(--pvr-gold); }
.pvr-table tbody tr:hover { background: rgba(255,255,255,.035); }
.pvr-table-compact th, .pvr-table-compact td { padding: 5px 7px; }
.pvr-table-scanner { min-width: 1480px; }
.pvr-table-scanner th, .pvr-table-scanner td { white-space: nowrap; }
.pvr-table-scanner .pvr-actions-col { min-width: 145px; }
.pvr-table-archive { min-width: 1260px; }
.pvr-table-edit { min-width: 900px; table-layout: fixed; }
.pvr-table-edit th:nth-child(1), .pvr-table-edit td:nth-child(1) { width: 44px; }
.pvr-table-edit th:nth-child(2), .pvr-table-edit td:nth-child(2) { width: 54px; }
.pvr-table-edit th:nth-child(4), .pvr-table-edit td:nth-child(4) { width: 125px; }
.pvr-table-edit th:nth-child(n+5), .pvr-table-edit td:nth-child(n+5) { width: 120px; }
.pvr-table input, .pvr-table select { width: 100%; min-width: 0; max-width: none; min-height: 30px; border: 1px solid var(--pvr-line-strong); border-radius: 0; background: var(--pvr-input); color: var(--pvr-text); padding: 4px 6px; }
.pvr-table input[type="checkbox"] { width: auto; min-height: auto; }
.pvr-number { text-align: right !important; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pvr-nowrap { white-space: nowrap; }
.pvr-cell-wrap { min-width: 130px; max-width: 260px; white-space: normal; overflow-wrap: anywhere; }
.pvr-subline { display: block; margin-top: 1px; color: var(--pvr-muted); font-size: .7rem; }
.pvr-empty { text-align: center !important; color: var(--pvr-muted); padding: 12px !important; }
.pvr-actions-col { min-width: 190px; }
.pvr-positive { color: var(--pvr-green); font-weight: 800; }
.pvr-negative { color: var(--pvr-red); font-weight: 800; }
.pvr-muted { color: var(--pvr-muted); }
.pvr-status { display: inline-flex; align-items: center; min-height: 21px; padding: 2px 6px; background: #263248; font-size: .68rem; font-weight: 800; }
.pvr-status-approved { color: #adf0d0; background: #153b2e; }
.pvr-status-pending { color: #f6db9b; background: #3a3015; }
.pvr-status-blocked { color: #ffc0c0; background: #401f26; }
.pvr-status-ok { color: #adf0d0; background: #153b2e; }
.pvr-status-error { color: #ffc0c0; background: #401f26; }
.pvr-role-list { display: inline-flex; flex-wrap: wrap; gap: 4px; }
.pvr-role-badge { display: inline-flex; align-items: center; min-height: 21px; padding: 2px 6px; border: 1px solid var(--pvr-line-strong); font-size: .68rem; font-weight: 800; white-space: nowrap; }
.pvr-role-admin { color: #ffe3a0; border-color: #80682d; background: #3a3015; }
.pvr-role-pvr { color: #c8e2ff; border-color: #365d8b; background: #142d4a; }
.pvr-inline-actions { display: flex; flex-wrap: nowrap; gap: 4px; align-items: center; }
.pvr-inline-actions form { display: inline-flex; margin: 0; }
.pvr-check-cell { text-align: center !important; }

.pvr-sort-button { width: 100%; border: 0; padding: 0 16px 0 0; color: inherit; background: transparent; text-align: inherit; font-weight: inherit; cursor: pointer; position: relative; white-space: nowrap; }
th[data-sort-direction="asc"] .pvr-sort-button::after { content: "▲"; position: absolute; right: 0; font-size: .58rem; color: var(--pvr-gold); }
th[data-sort-direction="desc"] .pvr-sort-button::after { content: "▼"; position: absolute; right: 0; font-size: .58rem; color: var(--pvr-gold); }

.pvr-auth-shell { min-height: calc(100vh - 100px); display: grid; place-items: center; padding: 8px 0; }
.pvr-auth-card { width: min(480px, 100%); border: 1px solid var(--pvr-line-strong); padding: 18px; background: var(--pvr-panel); }
.pvr-auth-card-wide { width: min(660px, 100%); }
.pvr-auth-card h1 { margin: 0 0 4px; font-size: 1.55rem; }
.pvr-auth-card > p { margin: 0 0 12px; color: var(--pvr-muted); line-height: 1.35; font-size: .86rem; }
.pvr-auth-links { display: flex; justify-content: space-between; gap: 10px; margin-top: 10px; color: var(--pvr-muted); font-size: .82rem; }
.pvr-auth-links-centered { justify-content: center; align-items: center; flex-wrap: wrap; text-align: center; }
.pvr-auth-links a { color: #c6dfff; }

.pvr-kpi-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; margin: 0 0 10px; }
.pvr-kpi-grid-compact { grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); }
.pvr-kpi { border: 1px solid var(--pvr-line); padding: 8px; background: #0d192b; min-width: 0; }
.pvr-kpi span { display: block; color: var(--pvr-muted); font-size: .67rem; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pvr-kpi strong { font-size: .94rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pvr-copy-input { width: 100%; margin-top: 5px; min-height: 34px; border: 1px solid var(--pvr-line); border-radius: 0; background: #07101f; color: var(--pvr-text); padding: 5px 7px; }
.pvr-inline-filter select { min-height: 34px; border: 1px solid var(--pvr-line); border-radius: 0; background: var(--pvr-input); color: var(--pvr-text); padding: 5px 7px; }

.pvr-scan-stats { display: flex; flex-wrap: wrap; gap: 14px; margin: 7px 0; color: var(--pvr-muted); font-size: .78rem; }
.pvr-details summary { color: var(--pvr-blue); cursor: pointer; font-weight: 700; }
.pvr-mini-table { width: 100%; min-width: 650px; margin-top: 5px; border-collapse: collapse; font-size: .73rem; background: #07101f; }
.pvr-mini-table th, .pvr-mini-table td { padding: 4px 5px; border: 1px solid var(--pvr-line); vertical-align: top; }

.pvr-whatsapp { position: fixed; right: 16px; bottom: 16px; z-index: 50; display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid #2cc56e; border-radius: 50%; background: #138a4b; color: #fff; text-decoration: none; box-shadow: 0 5px 14px rgba(0,0,0,.28); }
.pvr-whatsapp:hover { background: #159b55; }
.pvr-whatsapp-icon { display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; }
.pvr-whatsapp-icon svg { display: block; width: 23px; height: 23px; fill: #fff; }

.pvr-section-gap { margin-top: 10px; }
.pvr-form-compact { margin: 0; }
.pvr-form-grid-system { grid-template-columns: minmax(240px, 1.8fr) minmax(150px, .7fr) minmax(150px, .7fr) minmax(150px, .7fr); align-items: end; }
.pvr-form-grid-system .pvr-span-2 { grid-column: span 2; }
.pvr-system-sizes { min-height: 36px; justify-content: flex-end; }
.pvr-check-row { min-height: 36px; display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; padding: 5px 0; }
.pvr-check-row label { display: inline-flex; align-items: center; gap: 5px; color: var(--pvr-muted); font-size: .82rem; white-space: nowrap; }
.pvr-check-row input { width: auto; min-height: auto; margin: 0; }
.pvr-alert-info { border-color: #345e8d; color: #c9e0ff; background: #10233b; }

@media (max-width: 1050px) {
    .pvr-mega-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-form-grid, .pvr-form-grid-dense, .pvr-form-grid-scanner { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-provider-form { grid-template-columns: 1fr 180px; }
    .pvr-form-grid-system { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-provider-form > .pvr-field:nth-of-type(3), .pvr-provider-form > .pvr-field:nth-of-type(4) { grid-column: auto; }
}

@media (max-width: 700px) {
    .pvr-header { grid-template-columns: 1fr auto; padding: 6px 10px; }
    .pvr-header-side { display: none; }
    .pvr-brand { grid-column: 1; justify-self: start; }
    .pvr-brand img { width: 64px; }
    .pvr-brand span { font-size: .82rem; }
    .pvr-account-area { grid-column: 2; gap: 8px; max-width: 52vw; font-size: .78rem; }
    .pvr-shell { width: min(100% - 16px, 1240px); padding: 12px 0 22px; }
    .pvr-page-head, .pvr-hero, .pvr-panel-header, .pvr-section-title { align-items: flex-start; flex-direction: column; gap: 4px; }
    .pvr-page-head > p { text-align: left; }
    .pvr-mega-grid, .pvr-form-grid, .pvr-form-grid-compact, .pvr-form-grid-dense, .pvr-form-grid-scanner, .pvr-provider-form { grid-template-columns: 1fr; }
    .pvr-field-span-2, .pvr-provider-form > .pvr-field:nth-of-type(3), .pvr-provider-form > .pvr-field:nth-of-type(4) { grid-column: auto; }
    .pvr-form-grid-system { grid-template-columns: 1fr; }
    .pvr-form-grid-system .pvr-span-2 { grid-column: auto; }
    .pvr-mega-card { min-height: 112px; }
    .pvr-auth-card, .pvr-auth-card-wide { padding: 14px; }
    .pvr-auth-links { flex-direction: column; align-items: center; }
    .pvr-inline-actions { flex-wrap: wrap; }
    .pvr-whatsapp { right: 10px; bottom: 10px; }
}
.pvr-action-input { width: 105px !important; min-width: 105px !important; min-height: 27px !important; padding: 3px 5px !important; font-size: .72rem !important; }
.pvr-provider-form > .pvr-actions { grid-column: 1 / -1; }



.pvr-risk-limits { margin-top: 9px; border-top: 1px solid var(--pvr-line); padding-top: 7px; }
.pvr-risk-limits > summary { width: fit-content; color: var(--pvr-gold); cursor: pointer; font-size: .76rem; font-weight: 800; text-transform: uppercase; letter-spacing: .055em; }
.pvr-risk-limits[open] > summary { margin-bottom: 7px; }
.pvr-form-grid-risk { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px 8px; }
.pvr-form-grid-risk .pvr-field { min-width: 0; }
.pvr-form-grid-risk .pvr-field label,
.pvr-form-grid-risk .pvr-field > span:first-child { color: #c5d0e2; font-size: .70rem; font-weight: 700; line-height: 1.15; }
.pvr-form-grid-risk input { min-height: 31px; padding: 4px 6px; font-size: .79rem; }

@media (max-width: 1050px) {
    .pvr-form-grid-risk { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
    .pvr-form-grid-risk { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Release 0010: densità, allineamenti e guida contestuale */
.pvr-center { text-align: center !important; }
.pvr-center .pvr-sort-button { text-align: center; padding-left: 12px; padding-right: 12px; }
.pvr-page-head-guide { align-items: flex-start; }
.pvr-head-tools { display: flex; align-items: center; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.pvr-head-tools > p { margin: 0; color: var(--pvr-muted); font-size: .84rem; }
.pvr-quick-guide { position: relative; }
.pvr-quick-guide > summary { list-style: none; cursor: pointer; border: 1px solid var(--pvr-line-strong); padding: 5px 8px; color: #c6dfff; background: #102039; font-size: .76rem; font-weight: 800; white-space: nowrap; }
.pvr-quick-guide > summary::-webkit-details-marker { display: none; }
.pvr-quick-guide-panel { position: absolute; top: calc(100% + 5px); right: 0; z-index: 30; width: min(590px, calc(100vw - 28px)); border: 1px solid var(--pvr-line-strong); background: #0d192b; padding: 12px 14px; box-shadow: 0 10px 24px rgba(0,0,0,.35); }
.pvr-quick-guide-panel h2 { margin: 0 0 7px; font-size: 1rem; }
.pvr-quick-guide-panel ol { margin: 0; padding-left: 20px; columns: 2; column-gap: 24px; }
.pvr-quick-guide-panel li { break-inside: avoid; margin: 0 0 6px; color: var(--pvr-muted); font-size: .78rem; line-height: 1.3; }
.pvr-quick-guide-panel li strong { color: var(--pvr-text); }
.pvr-quick-guide-panel p { margin: 7px 0 0; padding-top: 7px; border-top: 1px solid var(--pvr-line); color: #f8dda0; font-size: .77rem; line-height: 1.3; }

.pvr-form-grid-scanner-one-line { grid-template-columns: minmax(180px,1.65fr) 82px 100px 112px 102px 105px 82px 105px minmax(150px,1.35fr); gap: 6px 8px; }
.pvr-form-grid-risk { grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: minmax(0, 1fr); gap: 6px; }
.pvr-form-grid-risk .pvr-field label,
.pvr-form-grid-risk .pvr-field > span:first-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pvr-form-grid-risk input { min-width: 0; }

.pvr-login-fields { width: min(350px, 100%); margin-inline: auto; }

.pvr-sequence-row td { background: linear-gradient(90deg, hsl(42 84% 61% / calc(.02 + var(--pvr-seq) * .14)), transparent 80%); }
.pvr-sequence-row td:first-child { border-left: 3px solid hsl(42 84% 61% / calc(.18 + var(--pvr-seq) * .82)); }
.pvr-sequence-row:last-child td { background: linear-gradient(90deg, hsl(42 84% 61% / .24), transparent 84%); }

.pvr-scenario-badge, .pvr-result-badge { display: inline-flex; align-items: center; justify-content: center; min-height: 22px; padding: 2px 7px; border: 1px solid transparent; font-weight: 850; font-size: .72rem; white-space: nowrap; }
.pvr-scenario-ko { color: #ffc0c0; background: #3b1e25; border-color: #74404a; }
.pvr-scenario-win { color: #bdf4db; background: #153b2e; border-color: #33775b; }
.pvr-result-positive { color: #bdf4db; background: #153b2e; border-color: #33775b; }
.pvr-result-negative { color: #ffc0c0; background: #3b1e25; border-color: #74404a; }
.pvr-result-neutral { color: #d5deea; background: #273247; border-color: #45536b; }

.pvr-kpi-grid-system { grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 5px; }
.pvr-kpi-grid-system .pvr-kpi { padding: 7px 6px; }
.pvr-kpi-grid-system .pvr-kpi span { font-size: .62rem; }
.pvr-kpi-grid-system .pvr-kpi strong { font-size: .84rem; }

.pvr-system-coupons { min-width: 0; table-layout: fixed; }
.pvr-system-coupons th:nth-child(1), .pvr-system-coupons td:nth-child(1) { width: 78px; }
.pvr-system-coupons th:nth-child(2), .pvr-system-coupons td:nth-child(2) { width: 58px; text-align: center !important; }
.pvr-system-coupons th:nth-child(4), .pvr-system-coupons td:nth-child(4) { width: 68px; text-align: center !important; }
.pvr-system-coupons th:nth-child(5), .pvr-system-coupons td:nth-child(5) { width: 72px; text-align: center !important; }
.pvr-system-coupons th:nth-child(n+6), .pvr-system-coupons td:nth-child(n+6) { width: 102px; }
.pvr-system-coupons td:nth-child(3) { white-space: normal; overflow-wrap: anywhere; }

.pvr-system-aggregates { min-width: 0; }
.pvr-system-aggregates th:nth-child(4), .pvr-system-aggregates td:nth-child(4),
.pvr-system-aggregates th:nth-child(6), .pvr-system-aggregates td:nth-child(6) { text-align: center !important; }
.pvr-system-aggregates th:nth-child(4), .pvr-system-aggregates td:nth-child(4) { width: 72px; }
.pvr-system-aggregates th:nth-child(6), .pvr-system-aggregates td:nth-child(6) { width: 94px; }

.pvr-table-archive { min-width: 0; table-layout: fixed; font-size: .74rem; }
.pvr-table-archive th, .pvr-table-archive td { padding: 5px 6px; }
.pvr-table-archive th:nth-child(1), .pvr-table-archive td:nth-child(1) { width: 225px; white-space: normal; }
.pvr-table-archive th:nth-child(2), .pvr-table-archive td:nth-child(2) { width: 66px; }
.pvr-table-archive th:nth-child(3), .pvr-table-archive td:nth-child(3) { width: 92px; }
.pvr-table-archive th:nth-child(4), .pvr-table-archive td:nth-child(4) { width: 48px; text-align: center !important; }
.pvr-table-archive th:nth-child(5), .pvr-table-archive td:nth-child(5) { width: 76px; }
.pvr-table-archive th:nth-child(6), .pvr-table-archive td:nth-child(6) { width: 57px; }
.pvr-table-archive th:nth-child(7), .pvr-table-archive td:nth-child(7) { width: 84px; }
.pvr-table-archive th:nth-child(8), .pvr-table-archive td:nth-child(8),
.pvr-table-archive th:nth-child(9), .pvr-table-archive td:nth-child(9) { width: 72px; }
.pvr-table-archive th:nth-child(10), .pvr-table-archive td:nth-child(10) { width: 68px; }
.pvr-table-archive th:nth-child(11), .pvr-table-archive td:nth-child(11) { width: 118px; }
.pvr-table-archive th:nth-child(12), .pvr-table-archive td:nth-child(12) { width: 114px; }
.pvr-table-wrap-no-scroll { overflow-x: hidden; }

.pvr-table-scanner { min-width: 1180px; }
.pvr-table-scanner .pvr-col-events { width: 58px; }

.pvr-help-enabled { cursor: help; }
.pvr-field .pvr-help-enabled, .pvr-kpi .pvr-help-enabled { text-decoration: underline dotted rgba(198,223,255,.42); text-underline-offset: 3px; }

@media (max-width: 1160px) {
    .pvr-form-grid-scanner-one-line { grid-template-columns: repeat(5, minmax(0,1fr)); }
    .pvr-form-grid-risk { grid-auto-flow: row; grid-template-columns: repeat(5, minmax(0,1fr)); }
    .pvr-kpi-grid-system { grid-template-columns: repeat(6, minmax(0,1fr)); }
    .pvr-table-wrap-no-scroll { overflow-x: auto; }
    .pvr-table-archive { min-width: 1080px; }
}

@media (max-width: 700px) {
    .pvr-head-tools { justify-content: flex-start; }
    .pvr-quick-guide-panel { position: fixed; top: 70px; right: 8px; left: 8px; width: auto; max-height: calc(100vh - 90px); overflow: auto; }
    .pvr-quick-guide-panel ol { columns: 1; }
    .pvr-form-grid-scanner-one-line { grid-template-columns: 1fr; }
    .pvr-form-grid-risk { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .pvr-kpi-grid-system { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

/* Release 0011: scanner compatto, dialog, stato ricalcolo e portafoglio */
.pvr-form-grid-scanner-one-line { grid-template-columns: minmax(190px,1.7fr) 72px 86px 92px 96px 118px 78px minmax(150px,1.25fr); gap: 6px; }
.pvr-form-grid-risk-one-line { grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: minmax(96px,1fr); gap: 6px; }
.pvr-form-grid-risk-one-line .pvr-field label { font-size: .66rem; }
.pvr-form-grid-risk-one-line input { padding-inline: 5px; }
.pvr-table-scanner { min-width: 1160px; table-layout: fixed; }
.pvr-table-scanner th:nth-child(1), .pvr-table-scanner td:nth-child(1) { width: 120px; }
.pvr-table-scanner th:nth-child(2), .pvr-table-scanner td:nth-child(2) { width: 56px; }
.pvr-table-scanner th:nth-child(3), .pvr-table-scanner td:nth-child(3),
.pvr-table-scanner th:nth-child(4), .pvr-table-scanner td:nth-child(4) { width: 62px; }
.pvr-table-scanner th:nth-child(5), .pvr-table-scanner td:nth-child(5) { width: 70px; }
.pvr-table-scanner th:nth-child(6), .pvr-table-scanner td:nth-child(6),
.pvr-table-scanner th:nth-child(7), .pvr-table-scanner td:nth-child(7) { width: 96px; text-align: center !important; }
.pvr-table-scanner th:nth-child(n+8):nth-child(-n+11), .pvr-table-scanner td:nth-child(n+8):nth-child(-n+11) { width: 90px; }
.pvr-table-scanner th:nth-child(12), .pvr-table-scanner td:nth-child(12) { width: 108px; }
.pvr-table-scanner th:nth-child(13), .pvr-table-scanner td:nth-child(13) { width: 145px; }

.pvr-dialog { width: min(1040px, calc(100vw - 30px)); max-height: min(720px, calc(100vh - 30px)); padding: 0; border: 1px solid var(--pvr-line-strong); border-radius: 0; color: var(--pvr-text); background: #0b1628; }
.pvr-dialog::backdrop { background: rgba(2,7,14,.78); }
.pvr-dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 10px 12px; border-bottom: 1px solid var(--pvr-line); background: #14243d; }
.pvr-dialog-head div { display: flex; flex-direction: column; gap: 2px; }
.pvr-dialog-head span { color: var(--pvr-muted); font-size: .75rem; }
.pvr-dialog-close { width: 30px; height: 30px; border: 1px solid var(--pvr-line); border-radius: 0; color: var(--pvr-text); background: #0b1628; cursor: pointer; font-size: 1.2rem; }
.pvr-dialog-body { padding: 10px; overflow: auto; }
.pvr-dialog-body .pvr-table { min-width: 820px; }

.pvr-result-stale { opacity: .44; filter: grayscale(.35); pointer-events: none; }
.pvr-btn:disabled { opacity: .48; cursor: not-allowed; }
.pvr-scenario-body td:nth-child(n+3):nth-child(-n+7) { padding-left: 3px; padding-right: 10px; }

.pvr-kpi-grid-portfolio { grid-template-columns: repeat(8, minmax(0,1fr)); }
.pvr-table-portfolio { min-width: 1040px; }
.pvr-status-badge { display: inline-flex; padding: 2px 6px; border: 1px solid var(--pvr-line); background: #1b2d48; font-size: .68rem; font-weight: 800; }
.pvr-warn-text { color: var(--pvr-gold); }
.pvr-row-warning { background: rgba(242,197,82,.08); }
.pvr-portfolio-source-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.pvr-portfolio-source-grid h3 { margin: 0 0 7px; font-size: .92rem; }
.pvr-source-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; padding: 7px 0; border-bottom: 1px solid var(--pvr-line); }
.pvr-source-row span { min-width: 0; }
.pvr-source-row strong, .pvr-source-row small { display: block; }
.pvr-source-row strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .79rem; }
.pvr-source-row small { margin-top: 2px; color: var(--pvr-muted); font-size: .68rem; }

@media (max-width: 1160px) {
    .pvr-form-grid-scanner-one-line { grid-template-columns: repeat(4,minmax(0,1fr)); }
    .pvr-form-grid-risk-one-line { grid-auto-flow: row; grid-template-columns: repeat(4,minmax(0,1fr)); }
    .pvr-kpi-grid-portfolio { grid-template-columns: repeat(4,minmax(0,1fr)); }
}
@media (max-width: 700px) {
    .pvr-form-grid-scanner-one-line, .pvr-form-grid-risk-one-line, .pvr-portfolio-source-grid { grid-template-columns: 1fr; }
    .pvr-kpi-grid-portfolio { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

/* Release 0011: portafoglio operativo */
.pvr-table-portfolio { min-width: 0; table-layout: fixed; font-size: .75rem; }
.pvr-table-portfolio th, .pvr-table-portfolio td { padding: 5px 6px; }
.pvr-table-portfolio th:nth-child(1), .pvr-table-portfolio td:nth-child(1) { width: 86px; }
.pvr-table-portfolio th:nth-child(2), .pvr-table-portfolio td:nth-child(2) { width: 220px; }
.pvr-table-portfolio th:nth-child(3), .pvr-table-portfolio td:nth-child(3) { width: 98px; }
.pvr-table-portfolio th:nth-child(4), .pvr-table-portfolio td:nth-child(4),
.pvr-table-portfolio th:nth-child(6), .pvr-table-portfolio td:nth-child(6) { width: 78px; }
.pvr-table-portfolio th:nth-child(5), .pvr-table-portfolio td:nth-child(5),
.pvr-table-portfolio th:nth-child(7), .pvr-table-portfolio td:nth-child(7) { width: 92px; }
.pvr-table-portfolio th:nth-child(8), .pvr-table-portfolio td:nth-child(8) { width: 90px; }
.pvr-table-portfolio th:nth-child(9), .pvr-table-portfolio td:nth-child(9) { width: 250px; }
.pvr-portfolio-actions { gap: 3px; }
.pvr-status-planned { color: #f8dda0; background: #3a3015; border-color: #756331; }
.pvr-status-active { color: #bdf4db; background: #153b2e; border-color: #33775b; }
.pvr-status-closed { color: #c5cfdd; background: #263248; border-color: #45536b; }

@media (max-width: 1160px) {
    .pvr-table-portfolio { min-width: 1040px; }
}

/* Release 0015: valori centrati solo in Pronostico, Quota Punta e Quota Banca */
.pvr-table-edit tbody td:nth-child(4) input,
.pvr-table-edit tbody td:nth-child(5) input,
.pvr-table-edit tbody td:nth-child(6) input { text-align: center; }

/* Release 0015: riferimenti progressivi nel Portafoglio */
.pvr-table-portfolio th:nth-child(1), .pvr-table-portfolio td:nth-child(1) { width: 48px; text-align: center !important; }
.pvr-table-portfolio th:nth-child(2), .pvr-table-portfolio td:nth-child(2) { width: 86px; }
.pvr-table-portfolio th:nth-child(3), .pvr-table-portfolio td:nth-child(3) { width: 210px; }
.pvr-table-portfolio th:nth-child(4), .pvr-table-portfolio td:nth-child(4) { width: 94px; }

/* Release 0015: larghezze aggiornate dopo l'aggiunta della colonna Rif. */
.pvr-table-portfolio th:nth-child(1), .pvr-table-portfolio td:nth-child(1) { width: 48px; text-align: center !important; }
.pvr-table-portfolio th:nth-child(2), .pvr-table-portfolio td:nth-child(2) { width: 84px; }
.pvr-table-portfolio th:nth-child(3), .pvr-table-portfolio td:nth-child(3) { width: 210px; }
.pvr-table-portfolio th:nth-child(4), .pvr-table-portfolio td:nth-child(4) { width: 92px; }
.pvr-table-portfolio th:nth-child(5), .pvr-table-portfolio td:nth-child(5) { width: 76px; }
.pvr-table-portfolio th:nth-child(6), .pvr-table-portfolio td:nth-child(6) { width: 90px; }
.pvr-table-portfolio th:nth-child(7), .pvr-table-portfolio td:nth-child(7) { width: 76px; }
.pvr-table-portfolio th:nth-child(8), .pvr-table-portfolio td:nth-child(8) { width: 90px; }
.pvr-table-portfolio th:nth-child(9), .pvr-table-portfolio td:nth-child(9) { width: 88px; }
.pvr-table-portfolio th:nth-child(10), .pvr-table-portfolio td:nth-child(10) { width: 248px; }

.pvr-table-portfolio-events { min-width: 0; table-layout: fixed; }
.pvr-table-portfolio-events th:nth-child(1), .pvr-table-portfolio-events td:nth-child(1) { width: 58px; text-align: center !important; }
.pvr-table-portfolio-events th:nth-child(2), .pvr-table-portfolio-events td:nth-child(2) { width: 98px; }
.pvr-table-portfolio-events th:nth-child(5), .pvr-table-portfolio-events td:nth-child(5),
.pvr-table-portfolio-events th:nth-child(6), .pvr-table-portfolio-events td:nth-child(6),
.pvr-table-portfolio-events th:nth-child(7), .pvr-table-portfolio-events td:nth-child(7) { width: 78px; text-align: center !important; }
.pvr-table-portfolio-events th:nth-child(8), .pvr-table-portfolio-events td:nth-child(8),
.pvr-table-portfolio-events th:nth-child(9), .pvr-table-portfolio-events td:nth-child(9) { width: 105px; }
.pvr-table-portfolio-events th:nth-child(10), .pvr-table-portfolio-events td:nth-child(10) { width: 130px; }

/* Analyzer integrato: origine e navigazione tra sorgenti/coupon */
.pvr-analyzer-origin {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin: 0 0 10px;
    padding: 10px 12px;
    border: 1px solid #31547a;
    background: #0d2139;
}
.pvr-analyzer-origin > div:first-child { min-width: 0; }
.pvr-analyzer-origin span {
    display: block;
    margin-bottom: 2px;
    color: #f4c74c;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .05em;
}
.pvr-analyzer-origin strong { display: block; color: #fff; font-size: 15px; }
.pvr-analyzer-origin small { display: block; margin-top: 3px; color: #b9cbea; }
.pvr-origin-coupons { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 5px; }
.pvr-origin-coupons a,
.pvr-origin-coupon-current {
    display: inline-block;
    padding: 5px 7px;
    border: 1px solid #3b5c82;
    background: #102743;
    color: #dce9ff;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
}
.pvr-origin-coupons a:hover { border-color: #f4c74c; color: #fff; }
.pvr-origin-coupon-current { border-color: #f4c74c; color: #f4c74c; }
@media (max-width: 900px) {
    .pvr-analyzer-origin { align-items: flex-start; flex-direction: column; }
    .pvr-origin-coupons { justify-content: flex-start; }
}
.pvr-combination-lines { display: grid; gap: 2px; }
.pvr-combination-lines span { display: block; }
.pvr-table-scanner th:nth-child(13), .pvr-table-scanner td:nth-child(13) { width: 220px; }


/* Release 0017: portafoglio più compatto senza barra orizzontale desktop */
.pvr-table-wrap-portfolio { overflow-x: hidden; }
.pvr-table-wrap-portfolio .pvr-table-portfolio { width: 100%; min-width: 0; }
.pvr-table-portfolio td { vertical-align: middle; }
.pvr-table-portfolio th:nth-child(1), .pvr-table-portfolio td:nth-child(1) { width: 42px; text-align: center !important; }
.pvr-table-portfolio th:nth-child(2), .pvr-table-portfolio td:nth-child(2) { width: 72px; }
.pvr-table-portfolio th:nth-child(3), .pvr-table-portfolio td:nth-child(3) { width: 190px; }
.pvr-table-portfolio th:nth-child(4), .pvr-table-portfolio td:nth-child(4) { width: 82px; }
.pvr-table-portfolio th:nth-child(5), .pvr-table-portfolio td:nth-child(5) { width: 72px; }
.pvr-table-portfolio th:nth-child(6), .pvr-table-portfolio td:nth-child(6) { width: 88px; }
.pvr-table-portfolio th:nth-child(7), .pvr-table-portfolio td:nth-child(7) { width: 72px; }
.pvr-table-portfolio th:nth-child(8), .pvr-table-portfolio td:nth-child(8) { width: 88px; }
.pvr-table-portfolio th:nth-child(9), .pvr-table-portfolio td:nth-child(9) { width: 82px; }
.pvr-table-portfolio th:nth-child(10), .pvr-table-portfolio td:nth-child(10) { width: 210px; }
.pvr-portfolio-actions { display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-start; }
.pvr-portfolio-actions form { display: inline-flex; }
.pvr-table-portfolio .pvr-btn-small { min-height: 25px; padding: 2px 6px; font-size: .68rem; }
@media (max-width: 1160px) {
    .pvr-table-wrap-portfolio { overflow-x: auto; }
    .pvr-table-wrap-portfolio .pvr-table-portfolio { min-width: 1000px; }
}


/* Release 0019: azioni Scanner completamente visibili su desktop */
.pvr-scanner-submit { margin-top: 22px; }
.pvr-table-wrap-scanner-results { overflow-x: hidden; }
.pvr-table-wrap-scanner-results .pvr-table-scanner { width: 100%; min-width: 0; table-layout: fixed; }
.pvr-table-scanner th, .pvr-table-scanner td { padding-left: 5px; padding-right: 5px; }
.pvr-table-scanner th:nth-child(1), .pvr-table-scanner td:nth-child(1) { width: 110px; }
.pvr-table-scanner th:nth-child(2), .pvr-table-scanner td:nth-child(2) { width: 52px; }
.pvr-table-scanner th:nth-child(3), .pvr-table-scanner td:nth-child(3),
.pvr-table-scanner th:nth-child(4), .pvr-table-scanner td:nth-child(4) { width: 56px; }
.pvr-table-scanner th:nth-child(5), .pvr-table-scanner td:nth-child(5) { width: 64px; }
.pvr-table-scanner th:nth-child(6), .pvr-table-scanner td:nth-child(6),
.pvr-table-scanner th:nth-child(7), .pvr-table-scanner td:nth-child(7) { width: 88px; }
.pvr-table-scanner th:nth-child(8), .pvr-table-scanner td:nth-child(8),
.pvr-table-scanner th:nth-child(9), .pvr-table-scanner td:nth-child(9) { width: 76px; }
.pvr-table-scanner th:nth-child(10), .pvr-table-scanner td:nth-child(10) { width: 92px; }
.pvr-table-scanner th:nth-child(11), .pvr-table-scanner td:nth-child(11) { width: 76px; }
.pvr-table-scanner th:nth-child(12), .pvr-table-scanner td:nth-child(12) { width: 102px; }
.pvr-table-scanner th:nth-child(13), .pvr-table-scanner td:nth-child(13) { width: 190px; }
.pvr-scanner-actions { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 4px; width: 100%; }
.pvr-scanner-actions form { display: block; min-width: 0; }
.pvr-scanner-actions .pvr-btn { width: 100%; min-width: 0; padding: 3px 5px; font-size: .68rem; white-space: nowrap; }
@media (max-width: 1120px) {
    .pvr-table-wrap-scanner-results { overflow-x: auto; }
    .pvr-table-wrap-scanner-results .pvr-table-scanner { min-width: 1110px; }
}

/* Release 0021: chiusura cumulativa fix UI e tabelle */
.pvr-scanner-submit {
    margin-top: 36px;
    padding-top: 10px;
}

/* Scanner: tutte e tre le azioni devono rientrare integralmente nel contenitore. */
.pvr-table-wrap-scanner-results { overflow-x: hidden; }
.pvr-table-wrap-scanner-results .pvr-table-scanner { width: 100%; min-width: 0; table-layout: fixed; }
.pvr-table-scanner th, .pvr-table-scanner td { box-sizing: border-box; padding-left: 4px; padding-right: 4px; }
.pvr-table-scanner th:nth-child(1), .pvr-table-scanner td:nth-child(1) { width: 100px; }
.pvr-table-scanner th:nth-child(2), .pvr-table-scanner td:nth-child(2) { width: 46px; }
.pvr-table-scanner th:nth-child(3), .pvr-table-scanner td:nth-child(3),
.pvr-table-scanner th:nth-child(4), .pvr-table-scanner td:nth-child(4) { width: 52px; }
.pvr-table-scanner th:nth-child(5), .pvr-table-scanner td:nth-child(5) { width: 60px; }
.pvr-table-scanner th:nth-child(6), .pvr-table-scanner td:nth-child(6),
.pvr-table-scanner th:nth-child(7), .pvr-table-scanner td:nth-child(7) { width: 82px; }
.pvr-table-scanner th:nth-child(8), .pvr-table-scanner td:nth-child(8),
.pvr-table-scanner th:nth-child(9), .pvr-table-scanner td:nth-child(9) { width: 70px; }
.pvr-table-scanner th:nth-child(10), .pvr-table-scanner td:nth-child(10) { width: 86px; }
.pvr-table-scanner th:nth-child(11), .pvr-table-scanner td:nth-child(11) { width: 68px; }
.pvr-table-scanner th:nth-child(12), .pvr-table-scanner td:nth-child(12) { width: 96px; }
.pvr-table-scanner th:nth-child(13), .pvr-table-scanner td:nth-child(13) { width: 166px; min-width: 0; }
.pvr-scanner-actions { display: grid; grid-template-columns: 1.25fr 1.12fr .88fr; gap: 3px; width: 100%; min-width: 0; }
.pvr-scanner-actions form { display: block; min-width: 0; }
.pvr-scanner-actions .pvr-btn { width: 100%; min-width: 0; padding: 3px 3px; font-size: .64rem; white-space: nowrap; }

/* Archivio opportunità: niente azione finale tagliata e niente scrollbar desktop. */
.pvr-table-wrap-opportunities { overflow-x: hidden; }
.pvr-table-wrap-opportunities .pvr-table-archive { width: 100%; min-width: 0; table-layout: fixed; }
.pvr-table-archive th:nth-child(1), .pvr-table-archive td:nth-child(1) { width: 205px; }
.pvr-table-archive th:nth-child(2), .pvr-table-archive td:nth-child(2) { width: 62px; }
.pvr-table-archive th:nth-child(3), .pvr-table-archive td:nth-child(3) { width: 84px; }
.pvr-table-archive th:nth-child(4), .pvr-table-archive td:nth-child(4) { width: 44px; }
.pvr-table-archive th:nth-child(5), .pvr-table-archive td:nth-child(5) { width: 70px; }
.pvr-table-archive th:nth-child(6), .pvr-table-archive td:nth-child(6) { width: 54px; }
.pvr-table-archive th:nth-child(7), .pvr-table-archive td:nth-child(7) { width: 78px; }
.pvr-table-archive th:nth-child(8), .pvr-table-archive td:nth-child(8),
.pvr-table-archive th:nth-child(9), .pvr-table-archive td:nth-child(9) { width: 66px; }
.pvr-table-archive th:nth-child(10), .pvr-table-archive td:nth-child(10) { width: 64px; }
.pvr-table-archive th:nth-child(11), .pvr-table-archive td:nth-child(11) { width: 106px; }
.pvr-table-archive th:nth-child(12), .pvr-table-archive td:nth-child(12) { width: 166px; min-width: 0; }
.pvr-opportunity-actions { display: grid; grid-template-columns: .75fr 1fr 1fr; gap: 3px; width: 100%; min-width: 0; }
.pvr-opportunity-actions form { display: block; min-width: 0; }
.pvr-opportunity-actions .pvr-btn { width: 100%; min-width: 0; padding: 3px 4px; font-size: .66rem; white-space: nowrap; }

/* Portafoglio: tutte le azioni su una sola riga e nessuna barra desktop. */
.pvr-table-wrap-portfolio { overflow-x: hidden; }
.pvr-table-wrap-portfolio .pvr-table-portfolio { width: 100%; min-width: 0; table-layout: fixed; }
.pvr-table-portfolio th:nth-child(1), .pvr-table-portfolio td:nth-child(1) { width: 38px; }
.pvr-table-portfolio th:nth-child(2), .pvr-table-portfolio td:nth-child(2) { width: 68px; }
.pvr-table-portfolio th:nth-child(3), .pvr-table-portfolio td:nth-child(3) { width: 182px; }
.pvr-table-portfolio th:nth-child(4), .pvr-table-portfolio td:nth-child(4) { width: 78px; }
.pvr-table-portfolio th:nth-child(5), .pvr-table-portfolio td:nth-child(5) { width: 68px; }
.pvr-table-portfolio th:nth-child(6), .pvr-table-portfolio td:nth-child(6) { width: 84px; }
.pvr-table-portfolio th:nth-child(7), .pvr-table-portfolio td:nth-child(7) { width: 68px; }
.pvr-table-portfolio th:nth-child(8), .pvr-table-portfolio td:nth-child(8) { width: 84px; }
.pvr-table-portfolio th:nth-child(9), .pvr-table-portfolio td:nth-child(9) { width: 78px; }
.pvr-table-portfolio th:nth-child(10), .pvr-table-portfolio td:nth-child(10) { width: 252px; min-width: 0; }
.pvr-portfolio-actions { display: flex; flex-wrap: nowrap; gap: 3px; align-items: center; width: 100%; min-width: 0; }
.pvr-portfolio-actions form { display: inline-flex; min-width: 0; margin: 0; }
.pvr-table-portfolio .pvr-btn-small { min-height: 25px; padding: 2px 5px; font-size: .66rem; white-space: nowrap; }

/* Campionato visibile senza trasformare le combinazioni in un blocco illeggibile. */
.pvr-combination-event,
.pvr-event-with-league { display: block; }
.pvr-combination-event + .pvr-combination-event { margin-top: 4px; }
.pvr-combination-event small,
.pvr-event-with-league small { display: block; color: var(--pvr-muted); font-size: .64rem; line-height: 1.15; }
.pvr-combination-event strong,
.pvr-event-with-league strong { display: block; color: inherit; font-size: inherit; line-height: 1.25; }

@media (max-width: 1120px) {
    .pvr-table-wrap-scanner-results,
    .pvr-table-wrap-opportunities,
    .pvr-table-wrap-portfolio { overflow-x: auto; }
    .pvr-table-wrap-scanner-results .pvr-table-scanner { min-width: 1080px; }
    .pvr-table-wrap-opportunities .pvr-table-archive { min-width: 1080px; }
    .pvr-table-wrap-portfolio .pvr-table-portfolio { min-width: 1030px; }
}

/* Release 0022: Global Portfolio Optimizer */
.pvr-global-last-run { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.pvr-kpi-grid-global { flex: 1; grid-template-columns: repeat(6, minmax(0, 1fr)); }
.pvr-form-grid-global { grid-template-columns: repeat(8, minmax(0, 1fr)); align-items: end; gap: 6px; }
.pvr-form-grid-global .pvr-actions { margin: 0; }
.pvr-form-grid-global .pvr-btn { width: 100%; min-height: 31px; }
.pvr-kpi-grid-global-detail { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.pvr-table-global-scenarios { min-width: 1180px; }
.pvr-block-muted { display: block; margin-top: 2px; color: var(--pvr-muted); font-size: .65rem; overflow-wrap: anywhere; }
.pvr-negative { color: #ff9d9d !important; }

@media (max-width: 1120px) {
    .pvr-kpi-grid-global, .pvr-kpi-grid-global-detail { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .pvr-form-grid-global { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
    .pvr-global-last-run { align-items: stretch; flex-direction: column; }
    .pvr-kpi-grid-global, .pvr-kpi-grid-global-detail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-form-grid-global { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Release 0023: Portafoglio operativo reale */
.pvr-page-head-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
.pvr-page-head-actions p { margin: 0; }
.pvr-operational-launch,
.pvr-operational-commandbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
    padding: 10px 12px;
    border: 1px solid #31547a;
    background: #0d2139;
}
.pvr-operational-launch > div:first-child,
.pvr-operational-commandbar > div:first-child { min-width: 0; }
.pvr-operational-launch strong,
.pvr-operational-commandbar strong { display: block; color: #fff; }
.pvr-operational-launch span,
.pvr-operational-commandbar span { display: block; color: var(--pvr-muted); font-size: .75rem; }
.pvr-inline-form { display: flex; align-items: center; gap: 6px; margin: 0; }
.pvr-inline-form input { min-width: 220px; height: 31px; }
.pvr-kpi-grid-operational { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.pvr-table-operational-lays { min-width: 1460px; }
.pvr-operational-actions-cell { min-width: 330px; }
.pvr-operational-execution-form {
    display: grid;
    grid-template-columns: 76px 76px auto;
    align-items: end;
    gap: 4px;
    margin: 0 0 5px;
}
.pvr-operational-execution-form label span { display: block; color: var(--pvr-muted); font-size: .62rem; }
.pvr-operational-execution-form input { width: 100%; height: 27px; padding: 3px 5px; }
.pvr-operational-settle-form { display: grid; grid-template-columns: minmax(120px, 1fr) auto auto; gap: 4px; margin: 0; }
.pvr-operational-settle-form input { min-width: 0; height: 27px; padding: 3px 5px; }
.pvr-operational-coupon-list { display: grid; gap: 10px; }
.pvr-operational-coupon { border: 1px solid #29496c; background: #0b1b2f; }
.pvr-operational-coupon > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 10px;
    background: #102743;
}
.pvr-operational-coupon > header strong { display: block; color: #fff; }
.pvr-operational-coupon > header span:not(.pvr-status-badge) { display: block; color: var(--pvr-muted); font-size: .72rem; }
.pvr-operational-coupon-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; padding: 7px 10px; }
.pvr-operational-coupon-metrics span { color: var(--pvr-muted); font-size: .7rem; }
.pvr-operational-coupon-metrics strong { display: block; margin-top: 1px; color: #fff; font-size: .86rem; }
.pvr-operational-coupon-actions { padding: 0 10px 7px; }
.pvr-operational-coupon .pvr-table-wrap { margin: 0; border-left: 0; border-right: 0; border-bottom: 0; }
.pvr-table-sequential { width: 100%; min-width: 0; table-layout: fixed; }
.pvr-table-sequential th:nth-child(1), .pvr-table-sequential td:nth-child(1) { width: 48px; }
.pvr-table-sequential th:nth-child(3), .pvr-table-sequential td:nth-child(3) { width: 160px; }
.pvr-table-sequential th:nth-child(4), .pvr-table-sequential td:nth-child(4),
.pvr-table-sequential th:nth-child(5), .pvr-table-sequential td:nth-child(5) { width: 70px; }
.pvr-table-sequential th:nth-child(6), .pvr-table-sequential td:nth-child(6),
.pvr-table-sequential th:nth-child(7), .pvr-table-sequential td:nth-child(7) { width: 112px; }
.pvr-table-sequential th:nth-child(8), .pvr-table-sequential td:nth-child(8) { width: 115px; }
.pvr-status-prepared { border-color: #687b91; color: #d7e1ed; }
.pvr-status-played, .pvr-status-active, .pvr-status-due { border-color: #e5b84b; color: #f4c74c; }
.pvr-status-partial { border-color: #e39145; color: #ffc07a; }
.pvr-status-matched, .pvr-status-won, .pvr-status-settled { border-color: #3aa578; color: #78dfb5; }
.pvr-status-lost { border-color: #bf5454; color: #ff9d9d; }
.pvr-status-expired { border-color: #d27636; color: #ffbf76; background: #3a2416; }
.pvr-status-pending, .pvr-status-cancelled, .pvr-status-closed { border-color: #53677e; color: #aebdd0; }

@media (max-width: 1120px) {
    .pvr-kpi-grid-operational { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .pvr-table-sequential { min-width: 980px; }
    .pvr-operational-coupon .pvr-table-wrap { overflow-x: auto; }
}

@media (max-width: 700px) {
    .pvr-page-head-actions,
    .pvr-operational-launch,
    .pvr-operational-commandbar { align-items: stretch; flex-direction: column; }
    .pvr-inline-form { align-items: stretch; flex-direction: column; }
    .pvr-inline-form input { min-width: 0; width: 100%; }
    .pvr-kpi-grid-operational,
    .pvr-operational-coupon-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.pvr-table-operational-events { width: 100%; min-width: 0; table-layout: fixed; }
.pvr-table-operational-events th:nth-child(1), .pvr-table-operational-events td:nth-child(1) { width: 105px; }
.pvr-table-operational-events th:nth-child(3), .pvr-table-operational-events td:nth-child(3) { width: 130px; }
.pvr-table-operational-events th:nth-child(4), .pvr-table-operational-events td:nth-child(4) { width: 145px; }
.pvr-table-operational-events th:nth-child(5), .pvr-table-operational-events td:nth-child(5) { width: 510px; }
.pvr-operational-event-form { display: grid; grid-template-columns: repeat(4, 58px) minmax(120px, 1fr) auto; align-items: end; gap: 4px; margin: 0; }
.pvr-operational-event-form label span { display: block; color: var(--pvr-muted); font-size: .6rem; }
.pvr-operational-event-form input { width: 100%; min-width: 0; height: 27px; padding: 3px 5px; }
.pvr-alert-compact { margin-top: 8px; padding: 7px 9px; font-size: .72rem; }
.pvr-status-recorded { border-color: #4d8cbf; color: #9fd3ff; }
.pvr-status-review_required { border-color: #e39145; color: #ffc07a; }

@media (max-width: 1120px) {
    .pvr-table-operational-events { min-width: 1040px; }
    .pvr-table-operational-events + * { clear: both; }
}

/* Release 0027: dettaglio ticket bookmaker reale e stampa POS 80 mm */
.pvr-operational-ticket-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 10px 8px;
    padding: 7px 9px;
    border: 1px solid #31547a;
    background: #0d2139;
}
.pvr-operational-ticket-summary > div:first-child { min-width: 0; }
.pvr-operational-ticket-summary span,
.pvr-operational-ticket-summary small { display: block; color: var(--pvr-muted); font-size: .68rem; }
.pvr-operational-ticket-summary strong { display: block; color: #fff; overflow-wrap: anywhere; }
.pvr-ticket-form { display: grid; gap: 10px; }
.pvr-ticket-summary-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 7px; }
.pvr-ticket-comparison { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-top: 8px; }
.pvr-ticket-comparison span {
    display: block;
    padding: 6px 8px;
    border: 1px solid #263f5e;
    background: #0a192b;
    color: var(--pvr-muted);
    font-size: .7rem;
}
.pvr-ticket-comparison strong { display: block; margin-top: 2px; color: #fff; font-size: .86rem; }
.pvr-ticket-notes { margin-top: 8px; }
.pvr-ticket-notes textarea { width: 100%; resize: vertical; }
.pvr-ticket-legs-table { min-width: 1220px; }
.pvr-ticket-legs-table th:nth-child(1), .pvr-ticket-legs-table td:nth-child(1) { width: 55px; }
.pvr-ticket-legs-table th:nth-child(2), .pvr-ticket-legs-table td:nth-child(2) { width: 275px; }
.pvr-ticket-legs-table th:nth-child(3), .pvr-ticket-legs-table td:nth-child(3) { width: 210px; }
.pvr-ticket-legs-table th:nth-child(6), .pvr-ticket-legs-table td:nth-child(6) { width: 95px; }
.pvr-ticket-legs-table input { width: 100%; min-width: 0; height: 30px; }
.pvr-ticket-attachment-current {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) auto auto;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    padding: 7px 9px;
    border: 1px solid #31547a;
    background: #0d2139;
}
.pvr-ticket-attachment-current a { color: #fff; font-weight: 700; overflow-wrap: anywhere; }
.pvr-ticket-attachment-current span,
.pvr-ticket-attachment-current label { color: var(--pvr-muted); font-size: .7rem; }
.pvr-ticket-actions { justify-content: flex-end; }

@media (max-width: 1120px) {
    .pvr-ticket-summary-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .pvr-ticket-comparison { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
    .pvr-operational-ticket-summary { align-items: stretch; flex-direction: column; }
    .pvr-ticket-summary-grid,
    .pvr-ticket-comparison { grid-template-columns: 1fr; }
    .pvr-ticket-attachment-current { grid-template-columns: 1fr; }
}

/* Release 0030: storico quote OddsGrid */
.pvr-history-filter {
    display: grid;
    grid-template-columns: minmax(220px, 2fr) minmax(150px, 1fr) minmax(130px, 1fr) 110px auto;
    align-items: end;
    gap: 7px;
}
.pvr-history-filter .pvr-actions { margin: 0; }
.pvr-history-capture-form {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 8px;
    color: var(--pvr-muted);
    font-size: .72rem;
}
.pvr-kpi-grid-history { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 8px; }
.pvr-table-history { min-width: 1420px; }
.pvr-row-selected { outline: 1px solid #f0bd3c; outline-offset: -1px; }
.pvr-history-detail-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(220px, 1fr); gap: 10px; }
.pvr-history-chart-card { border: 1px solid #29496c; background: #081728; padding: 8px; }
.pvr-history-chart { display: block; width: 100%; min-height: 230px; }
.pvr-history-axis { stroke: #40556f; stroke-width: 1; }
.pvr-history-line { fill: none; stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; }
.pvr-history-line-back { stroke: #65d8a6; }
.pvr-history-line-lay { stroke: #f2bf4e; }
.pvr-history-legend { display: flex; justify-content: flex-end; gap: 14px; color: var(--pvr-muted); font-size: .7rem; }
.pvr-history-legend span { display: inline-flex; align-items: center; gap: 5px; }
.pvr-history-dot { width: 8px; height: 8px; display: inline-block; }
.pvr-history-dot-back { background: #65d8a6; }
.pvr-history-dot-lay { background: #f2bf4e; }
.pvr-history-extremes { display: grid; gap: 6px; }
.pvr-history-extremes div { padding: 8px 9px; border: 1px solid #29496c; background: #0b1b2f; }
.pvr-history-extremes span { display: block; color: var(--pvr-muted); font-size: .68rem; }
.pvr-history-extremes strong { display: block; margin-top: 2px; color: #fff; }
.pvr-history-ticks-wrap { margin-top: 10px; max-height: 380px; overflow-y: auto; }

@media (max-width: 1120px) {
    .pvr-history-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-history-detail-grid { grid-template-columns: 1fr; }
    .pvr-kpi-grid-history { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
    .pvr-history-filter { grid-template-columns: 1fr; }
    .pvr-history-capture-form { align-items: stretch; flex-direction: column; }
}

/* Release 0033: allineamento compatto righe Analizzatore */
.pvr-table-edit { min-width: 1120px; }
.pvr-table-edit tbody td { vertical-align: middle; }
.pvr-analyzer-event-cell { vertical-align: middle !important; }
.pvr-analyzer-event-line {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) max-content;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.pvr-analyzer-event-line > input,
.pvr-table-edit tbody td:nth-child(4) > input,
.pvr-table-edit tbody td:nth-child(5) > input,
.pvr-table-edit tbody td:nth-child(6) > input,
.pvr-table-edit tbody td:nth-child(7) > input {
    min-height: 30px;
    height: 30px;
    margin: 0;
}
.pvr-analyzer-event-meta {
    display: inline-block;
    margin: 0;
    color: var(--pvr-muted);
    font-size: .64rem;
    line-height: 1.15;
    white-space: nowrap;
}

@media (max-width: 1180px) {
    .pvr-analyzer-event-line { grid-template-columns: minmax(250px, 1fr) max-content; }
}

/* Release 0034: box evento unificato e dettaglio operativo full-width */
.pvr-analyzer-event-box {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) max-content;
    align-items: center;
    gap: 10px;
    min-height: 30px;
    padding: 0 7px;
    border: 1px solid var(--pvr-line-strong);
    background: #0b1628;
}
.pvr-analyzer-event-box > input {
    min-width: 0;
    height: 28px;
    min-height: 28px;
    margin: 0;
    padding: 3px 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}
.pvr-analyzer-event-box > input:focus {
    outline: none;
    box-shadow: none;
}
.pvr-analyzer-event-box .pvr-analyzer-event-meta {
    margin: 0;
    white-space: nowrap;
}
.pvr-page-operational-full {
    width: calc(100vw - 24px);
    max-width: none;
    margin-left: 50%;
    transform: translateX(-50%);
}
.pvr-page-operational-full .pvr-panel { width: 100%; }
@media (max-width: 1180px) {
    .pvr-analyzer-event-box { grid-template-columns: minmax(220px, 1fr) max-content; }
}
@media (max-width: 760px) {
    .pvr-analyzer-event-box { grid-template-columns: 1fr; gap: 1px; padding: 3px 6px; }
    .pvr-analyzer-event-box .pvr-analyzer-event-meta { white-space: normal; }
    .pvr-page-operational-full { width: 100%; margin-left: 0; transform: none; }
}

/* Release 0034: login / registrazione a doppio pannello */
.pvr-auth-stage {
    min-height: calc(100vh - 108px);
    display: grid;
    place-items: center;
    padding: 24px 12px;
}
.pvr-auth-dual {
    width: min(980px, 100%);
    min-height: 560px;
    display: grid;
    grid-template-columns: 1.08fr .92fr;
    overflow: hidden;
    border: 1px solid #304662;
    background: #eef2f7;
    box-shadow: 0 24px 60px rgba(0,0,0,.34);
    animation: pvr-auth-enter .38s ease-out both;
}
.pvr-auth-dual-register { grid-template-columns: .92fr 1.08fr; }
.pvr-auth-form-panel {
    padding: 54px 64px;
    color: #13233a;
    background: #f6f8fb;
}
.pvr-auth-register-panel { padding-top: 36px; padding-bottom: 36px; }
.pvr-auth-form-panel .pvr-eyebrow { color: #8f6500; }
.pvr-auth-form-panel h1 { margin: 5px 0 8px; font-size: clamp(2rem, 4vw, 3rem); color: #10223c; }
.pvr-auth-lead { margin: 0 0 24px; color: #5c6d82; line-height: 1.45; }
.pvr-auth-brandline { display: flex; align-items: baseline; gap: 7px; margin-bottom: 24px; font-size: 1.05rem; font-weight: 900; }
.pvr-auth-brandline span { color: #063f82; }
.pvr-auth-brandline strong { color: #c28a00; }
.pvr-auth-form { display: grid; gap: 14px; }
.pvr-auth-form .pvr-field label { color: #263a55; }
.pvr-auth-form .pvr-field input {
    min-height: 43px;
    border-color: #bac6d5;
    color: #14243a;
    background: #fff;
}
.pvr-auth-form .pvr-field input:focus { border-color: #164f8f; box-shadow: 0 0 0 2px rgba(22,79,143,.12); }
.pvr-auth-form .field-validation-error, .pvr-auth-form [data-valmsg-for] { color: #9c2222; }
.pvr-auth-remember, .pvr-auth-consent { color: #44566d; }
.pvr-auth-consent a { color: #0a4d93; }
.pvr-auth-submit { min-width: 160px; justify-self: center; margin-top: 6px; }
.pvr-auth-register-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pvr-auth-welcome-panel {
    position: relative;
    display: grid;
    place-items: center;
    padding: 54px 46px;
    color: #fff;
    text-align: center;
    background: linear-gradient(145deg, #1c3554 0%, #46607d 100%);
}
.pvr-auth-welcome-panel::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(255,255,255,.06), transparent 55%);
    pointer-events: none;
}
.pvr-auth-welcome-panel > div { position: relative; max-width: 340px; }
.pvr-auth-welcome-panel .pvr-eyebrow { color: #ffd25c; }
.pvr-auth-welcome-panel h2 { margin: 8px 0 12px; font-size: clamp(2rem, 4vw, 3.15rem); }
.pvr-auth-welcome-panel p { margin: 0 0 28px; color: #dbe6f4; line-height: 1.55; }
.pvr-auth-switch {
    display: inline-flex;
    min-width: 150px;
    justify-content: center;
    padding: 10px 18px;
    border: 1px solid rgba(255,255,255,.8);
    color: #fff;
    font-weight: 800;
    text-decoration: none;
    background: transparent;
}
.pvr-auth-switch:hover { background: rgba(255,255,255,.12); }
@keyframes pvr-auth-enter { from { opacity: 0; transform: translateX(18px); } to { opacity: 1; transform: translateX(0); } }
.pvr-auth-dual-register { animation-name: pvr-auth-enter-register; }
@keyframes pvr-auth-enter-register { from { opacity: 0; transform: translateX(-18px); } to { opacity: 1; transform: translateX(0); } }
@media (max-width: 820px) {
    .pvr-auth-stage { padding: 12px 6px; }
    .pvr-auth-dual, .pvr-auth-dual-register { grid-template-columns: 1fr; }
    .pvr-auth-dual-register .pvr-auth-welcome-panel { order: 2; }
    .pvr-auth-form-panel { padding: 34px 24px; }
    .pvr-auth-welcome-panel { padding: 34px 24px; }
}
@media (max-width: 560px) {
    .pvr-auth-register-grid { grid-template-columns: 1fr; }
    .pvr-auth-form-panel { padding: 28px 18px; }
}

/* Release 0034: Scanner con Exchange selezionabile */
.pvr-form-grid-scanner-one-line {
    grid-template-columns: minmax(170px,1.5fr) 76px 92px 118px 104px 98px 104px 76px minmax(145px,1.25fr);
}


/* Release 0035: impostazioni Exchange teoriche e compatte */
.pvr-exchange-default-field {
    max-width: 360px;
    margin-bottom: 10px;
}
.pvr-table-wrap-compact { margin-top: 8px; }
.pvr-exchange-settings-table { min-width: 1040px; }
.pvr-exchange-settings-table input:not([type="checkbox"]),
.pvr-exchange-settings-table select {
    width: 100%;
    min-width: 0;
    height: 30px;
}
.pvr-exchange-settings-table input[type="checkbox"] {
    width: 18px;
    height: 18px;
}

/* Release 0037: larghezza desktop globale, tabelle compatte e focus operativo */
.pvr-shell {
    width: calc(100% - 20px);
    max-width: none;
    padding-top: 12px;
}
.pvr-page,
.pvr-page-wide,
.pvr-page-medium,
.pvr-compact-page {
    width: 100%;
    max-width: none;
}
.pvr-auth-stage {
    width: 100%;
}

.pvr-alert {
    margin-bottom: 7px;
    padding: 6px 8px;
    font-size: .76rem;
    line-height: 1.28;
}
.pvr-alert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 7px;
    margin-bottom: 8px;
}
.pvr-alert-grid > .pvr-alert {
    height: 100%;
    margin: 0;
}

.pvr-profile-page .pvr-form-grid-compact {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
.pvr-profile-page .pvr-exchange-default-field {
    max-width: 280px;
}
.pvr-table-wrap-exchange-settings {
    overflow-x: hidden;
}
.pvr-exchange-settings-table {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}
.pvr-exchange-settings-table th,
.pvr-exchange-settings-table td {
    padding: 5px 6px;
}
.pvr-exchange-settings-table th:nth-child(1),
.pvr-exchange-settings-table td:nth-child(1) { width: 12%; }
.pvr-exchange-settings-table th:nth-child(2),
.pvr-exchange-settings-table td:nth-child(2) { width: 7%; }
.pvr-exchange-settings-table th:nth-child(3),
.pvr-exchange-settings-table td:nth-child(3) { width: 12%; }
.pvr-exchange-settings-table th:nth-child(4),
.pvr-exchange-settings-table td:nth-child(4) { width: 15%; }
.pvr-exchange-settings-table th:nth-child(5),
.pvr-exchange-settings-table td:nth-child(5) { width: 16%; }
.pvr-exchange-settings-table th:nth-child(6),
.pvr-exchange-settings-table td:nth-child(6) { width: 38%; }
.pvr-exchange-settings-table input:not([type="checkbox"]),
.pvr-exchange-settings-table select {
    height: 28px;
    min-height: 28px;
    padding: 3px 6px;
    font-size: .76rem;
}

.pvr-table-wrap-analyzer {
    overflow-x: hidden;
}
.pvr-table-wrap-analyzer .pvr-table-edit {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}
.pvr-table-edit th,
.pvr-table-edit td {
    padding-left: 4px;
    padding-right: 4px;
}
.pvr-table-edit th:nth-child(1), .pvr-table-edit td:nth-child(1) { width: 42px; }
.pvr-table-edit th:nth-child(2), .pvr-table-edit td:nth-child(2) { width: 50px; }
.pvr-table-edit th:nth-child(3), .pvr-table-edit td:nth-child(3) { width: auto; }
.pvr-table-edit th:nth-child(4), .pvr-table-edit td:nth-child(4) { width: 118px; }
.pvr-table-edit th:nth-child(5), .pvr-table-edit td:nth-child(5) { width: 108px; }
.pvr-table-edit th:nth-child(6), .pvr-table-edit td:nth-child(6) { width: 108px; }
.pvr-table-edit th:nth-child(7), .pvr-table-edit td:nth-child(7) { width: 132px; }
.pvr-table-edit input {
    min-width: 0;
}
.pvr-analyzer-event-box {
    grid-template-columns: minmax(220px, 1fr) minmax(180px, max-content);
    gap: 7px;
}
.pvr-analyzer-event-box .pvr-analyzer-event-meta {
    max-width: 420px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pvr-table-portfolio th:nth-child(1), .pvr-table-portfolio td:nth-child(1) { width: 42px; }
.pvr-table-portfolio th:nth-child(2), .pvr-table-portfolio td:nth-child(2) { width: 74px; }
.pvr-table-portfolio th:nth-child(3), .pvr-table-portfolio td:nth-child(3) { width: auto; }
.pvr-table-portfolio th:nth-child(4), .pvr-table-portfolio td:nth-child(4) { width: 92px; }
.pvr-table-portfolio th:nth-child(5), .pvr-table-portfolio td:nth-child(5) { width: 92px; }
.pvr-table-portfolio th:nth-child(6), .pvr-table-portfolio td:nth-child(6) { width: 88px; }
.pvr-table-portfolio th:nth-child(7), .pvr-table-portfolio td:nth-child(7) { width: 88px; }
.pvr-table-portfolio th:nth-child(8), .pvr-table-portfolio td:nth-child(8) { width: 88px; }
.pvr-table-portfolio th:nth-child(9), .pvr-table-portfolio td:nth-child(9) { width: 90px; }
.pvr-table-portfolio th:nth-child(10), .pvr-table-portfolio td:nth-child(10) { width: 92px; }
.pvr-table-portfolio th:nth-child(11), .pvr-table-portfolio td:nth-child(11) { width: 300px; }
.pvr-portfolio-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(54px, 1fr));
    gap: 3px;
    width: 100%;
}
.pvr-portfolio-actions form,
.pvr-portfolio-actions .pvr-btn {
    width: 100%;
    min-width: 0;
}
.pvr-portfolio-actions .pvr-btn {
    justify-content: center;
    padding-inline: 4px;
    font-size: .64rem;
}

.pvr-operational-focus {
    border-color: rgba(242, 197, 82, .82);
    box-shadow: inset 0 0 0 1px rgba(242, 197, 82, .22), 0 0 0 1px rgba(242, 197, 82, .10);
}
.pvr-operational-focus > .pvr-section-title {
    margin: -4px -4px 8px;
    padding: 7px 8px;
    background: rgba(242, 197, 82, .08);
}
.pvr-next-step {
    color: var(--pvr-gold) !important;
    font-weight: 800;
}
.pvr-current-row {
    outline: 2px solid rgba(242, 197, 82, .78);
    outline-offset: -2px;
    background: rgba(242, 197, 82, .08) !important;
}
.pvr-current-row td {
    background: rgba(242, 197, 82, .045);
}
.pvr-operational-coupon-metrics {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}
.pvr-table-operational-lays {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}
.pvr-table-operational-lays th:nth-child(1), .pvr-table-operational-lays td:nth-child(1) { width: 96px; }
.pvr-table-operational-lays th:nth-child(2), .pvr-table-operational-lays td:nth-child(2) { width: auto; }
.pvr-table-operational-lays th:nth-child(3), .pvr-table-operational-lays td:nth-child(3) { width: 105px; }
.pvr-table-operational-lays th:nth-child(n+4):nth-child(-n+7),
.pvr-table-operational-lays td:nth-child(n+4):nth-child(-n+7) { width: 92px; }
.pvr-table-operational-lays th:nth-child(8), .pvr-table-operational-lays td:nth-child(8) { width: 98px; }
.pvr-table-operational-lays th:nth-child(9), .pvr-table-operational-lays td:nth-child(9) { width: 112px; }
.pvr-table-operational-lays th:nth-child(10), .pvr-table-operational-lays td:nth-child(10) { width: 96px; }
.pvr-table-operational-lays th:nth-child(11), .pvr-table-operational-lays td:nth-child(11) { width: 280px; }
.pvr-operational-actions-cell {
    min-width: 0;
}
.pvr-operational-execution-form {
    grid-template-columns: minmax(90px, .8fr) minmax(95px, .8fr) auto;
}
.pvr-table-operational-events {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}
.pvr-table-operational-events th:nth-child(1), .pvr-table-operational-events td:nth-child(1) { width: 100px; }
.pvr-table-operational-events th:nth-child(2), .pvr-table-operational-events td:nth-child(2) { width: auto; }
.pvr-table-operational-events th:nth-child(3), .pvr-table-operational-events td:nth-child(3) { width: 125px; }
.pvr-table-operational-events th:nth-child(4), .pvr-table-operational-events td:nth-child(4) { width: 250px; }
.pvr-table-operational-events th:nth-child(5), .pvr-table-operational-events td:nth-child(5) { width: 500px; }
.pvr-event-correction > summary,
.pvr-revision-history > summary {
    cursor: pointer;
    color: #c6dfff;
    font-size: .7rem;
    font-weight: 800;
}
.pvr-event-correction[open] > summary {
    margin-bottom: 5px;
}
.pvr-revision-history {
    margin-top: 4px;
}
.pvr-revision-history > div {
    max-height: 150px;
    overflow-y: auto;
    margin-top: 4px;
    padding: 5px 7px;
    border: 1px solid var(--pvr-line);
    background: #0b1628;
}
.pvr-revision-history p {
    margin: 0 0 5px;
    color: var(--pvr-muted);
    font-size: .64rem;
    line-height: 1.3;
}
.pvr-revision-history p:last-child { margin-bottom: 0; }
.pvr-status-irrelevant,
.pvr-status-not_reached {
    color: #d5deea;
    background: #273247;
    border-color: #45536b;
}

@media (max-width: 1180px) {
    .pvr-profile-page .pvr-form-grid-compact {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .pvr-table-wrap-exchange-settings,
    .pvr-table-wrap-analyzer,
    .pvr-table-wrap-portfolio {
        overflow-x: auto;
    }
    .pvr-exchange-settings-table { min-width: 920px; }
    .pvr-table-wrap-analyzer .pvr-table-edit { min-width: 980px; }
    .pvr-table-wrap-portfolio .pvr-table-portfolio { min-width: 1120px; }
    .pvr-table-operational-lays { min-width: 1260px; }
    .pvr-table-operational-events { min-width: 1280px; }
}

@media (max-width: 760px) {
    .pvr-shell {
        width: calc(100% - 12px);
    }
    .pvr-alert-grid {
        grid-template-columns: 1fr;
    }
    .pvr-profile-page .pvr-form-grid-compact {
        grid-template-columns: 1fr;
    }
    .pvr-operational-coupon-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Release 0038: gerarchia visiva globale, righe parametri compatte e form isolati */
:root {
    --pvr-section-blue: #4f7eae;
    --pvr-section-teal: #3f8b82;
    --pvr-section-violet: #80689d;
    --pvr-section-amber: #9b7d3e;
}

/* Le pagine applicative distinguono chiaramente i blocchi principali. */
.pvr-page > section.pvr-panel {
    --pvr-section-accent: var(--pvr-section-blue);
    --pvr-section-surface: #0f1c30;
    position: relative;
    border-top: 3px solid var(--pvr-section-accent);
    background: var(--pvr-section-surface);
    box-shadow: 0 5px 14px rgba(0, 0, 0, .14);
}
.pvr-page > section.pvr-panel:nth-of-type(4n + 2) {
    --pvr-section-accent: var(--pvr-section-teal);
    --pvr-section-surface: #0d2027;
}
.pvr-page > section.pvr-panel:nth-of-type(4n + 3) {
    --pvr-section-accent: var(--pvr-section-violet);
    --pvr-section-surface: #171a2d;
}
.pvr-page > section.pvr-panel:nth-of-type(4n) {
    --pvr-section-accent: var(--pvr-section-amber);
    --pvr-section-surface: #211d25;
}
.pvr-page > section.pvr-panel + section.pvr-panel { margin-top: 20px; }
.pvr-panel > .pvr-section-title {
    margin: 10px -8px 9px;
    padding: 7px 10px;
    border-left: 4px solid var(--pvr-section-accent, var(--pvr-section-blue));
    border-bottom: 1px solid rgba(255,255,255,.10);
    background: rgba(255,255,255,.035);
}
.pvr-panel > .pvr-section-title:first-child { margin-top: -8px; }
.pvr-panel > .pvr-section-title h2 { letter-spacing: .01em; }
.pvr-panel > .pvr-section-divider { margin: 14px 0; opacity: .62; }

/* Dettaglio operativo: tre fasi riconoscibili anche senza leggere i titoli. */
.pvr-section-status {
    --pvr-section-accent: #557da8 !important;
    --pvr-section-surface: #0d1b2f !important;
}
.pvr-section-coupons {
    --pvr-section-accent: #7286c4 !important;
    --pvr-section-surface: #111b31 !important;
}
.pvr-section-lays {
    --pvr-section-accent: #3f9b8d !important;
    --pvr-section-surface: #0b2226 !important;
}
.pvr-section-results {
    --pvr-section-accent: #9a6f9e !important;
    --pvr-section-surface: #211928 !important;
}
/* Numerazione sezioni gestita globalmente da pvr-ui.js. */
.pvr-section-coupons .pvr-operational-coupon { background: #0b172a; border-color: #415987; }
.pvr-section-lays .pvr-table { background: #091b20; }
.pvr-section-results .pvr-table { background: #191522; }

/* Gruppi azione in tabella: pulsanti uguali e allineati. */
.pvr-table td > .pvr-inline-actions,
.pvr-table td .pvr-opportunity-actions,
.pvr-table td .pvr-portfolio-actions {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(72px, 1fr);
    align-items: stretch;
    gap: 4px;
    width: 100%;
}
.pvr-table td > .pvr-inline-actions > form,
.pvr-table td .pvr-opportunity-actions > form,
.pvr-table td .pvr-portfolio-actions > form {
    display: flex;
    min-width: 0;
    margin: 0;
}
.pvr-table td > .pvr-inline-actions .pvr-btn,
.pvr-table td .pvr-opportunity-actions .pvr-btn,
.pvr-table td .pvr-portfolio-actions .pvr-btn {
    width: 100%;
    min-width: 0;
    min-height: 28px;
    padding-inline: 6px;
    white-space: nowrap;
}

/* Analizzatore: tutti i parametri principali su una riga desktop. */
.pvr-analyzer-parameters-grid {
    grid-template-columns: minmax(280px, 2.1fr) minmax(120px, .9fr) 112px 112px 92px 96px 128px 128px;
    gap: 6px 8px;
    align-items: end;
}
.pvr-analyzer-parameters-grid .pvr-field label {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pvr-analyzer-parameters-grid input,
.pvr-analyzer-parameters-grid select { min-height: 32px; height: 32px; }

/* Evento + metadati: il campionato/orario segue subito il nome, non il bordo destro. */
.pvr-analyzer-event-box {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
}
.pvr-analyzer-event-box > input {
    flex: 0 1 auto;
    width: min(52%, 62ch);
    min-width: 240px;
    max-width: calc(100% - 220px);
    field-sizing: content;
}
.pvr-analyzer-event-box .pvr-analyzer-event-meta {
    flex: 0 0 auto;
    max-width: min(42%, 430px);
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: left;
}

/* Crea sistema: i sei parametri sorgente restano su una riga desktop. */
.pvr-system-parameters-grid {
    grid-template-columns: minmax(340px, 2.35fr) minmax(135px, .8fr) 132px 132px 142px minmax(220px, 1.35fr);
    gap: 6px 9px;
    align-items: end;
}
.pvr-system-parameters-grid .pvr-field > span:first-child,
.pvr-system-parameters-grid .pvr-field label { white-space: nowrap; }
.pvr-system-options-row {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
    margin-top: 7px;
}
.pvr-system-options-row .pvr-form-note { margin: 0; text-align: right; }
.pvr-system-sizes { min-width: 285px; }

/* Provider: tutti i controlli, incluso Salva, sulla stessa riga desktop. */
.pvr-provider-form-one-line {
    grid-template-columns: minmax(260px, 1.55fr) 105px 122px minmax(230px, 1.2fr) minmax(230px, 1.2fr) minmax(130px, auto);
    gap: 7px 9px;
    align-items: end;
}
.pvr-provider-form-one-line > .pvr-field,
.pvr-provider-form-one-line > .pvr-check,
.pvr-provider-form-one-line > .pvr-actions { grid-column: auto !important; }
.pvr-provider-form-one-line textarea {
    height: 36px;
    min-height: 36px;
    resize: none;
    white-space: nowrap;
    overflow-x: auto;
}
.pvr-provider-save-actions {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    margin: 0;
}
.pvr-provider-save-actions .pvr-btn { min-width: 128px; height: 36px; }

/* Profilo: tre moduli realmente separati e nessuna contaminazione visiva. */
.pvr-profile-account-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
    align-items: end;
}
.pvr-profile-password-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
    align-items: end;
}
.pvr-profile-account-grid .pvr-actions,
.pvr-profile-password-grid .pvr-actions { margin: 0; }
.pvr-exchange-toolbar {
    display: grid;
    grid-template-columns: minmax(220px, 280px) 1fr auto;
    align-items: end;
    gap: 10px;
    margin-bottom: 8px;
}
.pvr-exchange-toolbar .pvr-form-note { margin: 0 0 5px; }
.pvr-section-account { --pvr-section-accent: #557da8 !important; --pvr-section-surface: #0d1b2f !important; }
.pvr-section-exchange { --pvr-section-accent: #3f8b82 !important; --pvr-section-surface: #0c2027 !important; }
.pvr-section-password { --pvr-section-accent: #80689d !important; --pvr-section-surface: #18182b !important; }

@media (max-width: 1240px) {
    .pvr-analyzer-parameters-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .pvr-system-parameters-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1050px) {
    .pvr-analyzer-parameters-grid,
    .pvr-system-parameters-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-provider-form-one-line { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-provider-form-one-line > * { grid-column: auto !important; }
    .pvr-provider-save-actions { grid-column: 1 / -1 !important; justify-content: flex-end; }
    .pvr-profile-account-grid,
    .pvr-profile-password-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-exchange-toolbar { grid-template-columns: minmax(220px, 280px) 1fr; }
    .pvr-exchange-toolbar > .pvr-btn { grid-column: 2; justify-self: end; }
}

@media (max-width: 760px) {
    .pvr-page > section.pvr-panel { box-shadow: none; }
    .pvr-analyzer-parameters-grid,
    .pvr-system-parameters-grid,
    .pvr-provider-form-one-line,
    .pvr-profile-account-grid,
    .pvr-profile-password-grid,
    .pvr-exchange-toolbar { grid-template-columns: 1fr; }
    .pvr-system-options-row { align-items: stretch; flex-direction: column; }
    .pvr-system-options-row .pvr-form-note { text-align: left; }
    .pvr-provider-save-actions,
    .pvr-exchange-toolbar > .pvr-btn { grid-column: auto !important; justify-self: stretch; }
    .pvr-provider-save-actions .pvr-btn { flex: 1 1 0; min-width: 0; }
    .pvr-analyzer-event-box { align-items: stretch; flex-direction: column; gap: 1px; }
    .pvr-analyzer-event-box > input,
    .pvr-analyzer-event-box .pvr-analyzer-event-meta { width: 100%; min-width: 0; max-width: none; }
    .pvr-table td > .pvr-inline-actions,
    .pvr-table td .pvr-opportunity-actions,
    .pvr-table td .pvr-portfolio-actions { grid-auto-flow: row; grid-template-columns: 1fr; }
}

.pvr-opportunity-actions { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
@media (max-width: 760px) {
    .pvr-opportunity-actions { grid-template-columns: 1fr !important; }
}


/* Release 0039: larghezza completa, numerazione globale sezioni e sub-blocchi distinti */
.pvr-page-head-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; flex-wrap: wrap; }
.pvr-page-head-actions p { margin: 0; color: var(--pvr-muted); font-size: .9rem; }

.pvr-subpanel {
    margin-top: 12px;
    padding: 10px;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.025);
}
.pvr-subpanel:first-of-type { margin-top: 0; }
.pvr-subpanel-blue { border-left: 4px solid #4f7eae; background: #0d1a2d; }
.pvr-subpanel-teal { border-left: 4px solid #3f8b82; background: #0b1d23; }
.pvr-subpanel-violet { border-left: 4px solid #80689d; background: #171828; }
.pvr-subpanel-amber { border-left: 4px solid #9b7d3e; background: #211b20; }
.pvr-subpanel .pvr-section-title:first-child { margin-top: 0; }
.pvr-table-wrap-steps .pvr-table th { background: #183253; }
.pvr-table-wrap-scenarios .pvr-table th { background: #2a2442; }
.pvr-table-wrap-exchange-summary .pvr-table th { background: #153240; }
.pvr-table-wrap-portfolio-summary .pvr-table th { background: #2d2442; }

.pvr-flow-heading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.pvr-flow-badge {
    display: inline-grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border: 1px solid currentColor;
    font-size: .76rem;
    line-height: 1;
    font-weight: 900;
    flex: 0 0 auto;
}
.pvr-flow-badge-blue, .pvr-flow-heading-blue { color: #b8d4ff; }
.pvr-flow-badge-teal, .pvr-flow-heading-teal { color: #9ce3d5; }
.pvr-flow-badge-violet, .pvr-flow-heading-violet { color: #e1b9e4; }
.pvr-flow-badge-amber, .pvr-flow-heading-amber { color: #f1d492; }

.pvr-flow-block-blue { --pvr-section-accent: #4f7eae; }
.pvr-flow-block-teal { --pvr-section-accent: #3f8b82; }
.pvr-flow-block-violet { --pvr-section-accent: #80689d; }
.pvr-flow-block-amber { --pvr-section-accent: #9b7d3e; }

@media (max-width: 760px) {
    .pvr-page-head-actions { justify-content: flex-start; }
    .pvr-subpanel { padding: 8px; }
}

/* Release 0040: fix vincolante unico — ogni sezione è un blocco completo */
.pvr-section-block,
.pvr-subpanel {
    --pvr-block-accent: #4f7eae;
    --pvr-block-surface: #0d1a2d;
    --pvr-block-surface-2: #101f35;
    position: relative;
    display: block;
    width: 100%;
    margin: 14px 0;
    padding: 12px;
    border: 1px solid color-mix(in srgb, var(--pvr-block-accent) 58%, transparent);
    border-left: 5px solid var(--pvr-block-accent);
    background: linear-gradient(180deg, var(--pvr-block-surface-2) 0%, var(--pvr-block-surface) 100%);
    box-shadow: 0 7px 18px rgba(0,0,0,.18);
}
.pvr-section-block:first-child,
.pvr-subpanel:first-child { margin-top: 0; }
.pvr-section-block:last-child,
.pvr-subpanel:last-child { margin-bottom: 0; }

.pvr-section-block-blue,
.pvr-subpanel-blue {
    --pvr-block-accent: #4f7eae;
    --pvr-block-surface: #0b182b;
    --pvr-block-surface-2: #10243d;
}
.pvr-section-block-teal,
.pvr-subpanel-teal {
    --pvr-block-accent: #3f9b8d;
    --pvr-block-surface: #081c21;
    --pvr-block-surface-2: #0d2a2d;
}
.pvr-section-block-violet,
.pvr-subpanel-violet {
    --pvr-block-accent: #8a6aa8;
    --pvr-block-surface: #151526;
    --pvr-block-surface-2: #221d36;
}
.pvr-section-block-amber,
.pvr-subpanel-amber {
    --pvr-block-accent: #a98743;
    --pvr-block-surface: #21191a;
    --pvr-block-surface-2: #30251d;
}

.pvr-section-block > .pvr-section-title,
.pvr-subpanel > .pvr-section-title {
    margin: -12px -12px 11px;
    padding: 9px 12px;
    border: 0;
    border-bottom: 1px solid color-mix(in srgb, var(--pvr-block-accent) 65%, transparent);
    background: color-mix(in srgb, var(--pvr-block-accent) 19%, #091322);
}
.pvr-section-block > .pvr-section-title:first-child,
.pvr-subpanel > .pvr-section-title:first-child { margin-top: -12px; }
.pvr-section-block > .pvr-section-title h2,
.pvr-subpanel > .pvr-section-title h2 { margin: 0; color: var(--pvr-text); }
.pvr-section-block > .pvr-section-title span,
.pvr-subpanel > .pvr-section-title span { color: #c4d0e3; }

.pvr-section-block .pvr-table-wrap,
.pvr-subpanel .pvr-table-wrap {
    border-color: color-mix(in srgb, var(--pvr-block-accent) 36%, rgba(255,255,255,.10));
    background: color-mix(in srgb, var(--pvr-block-surface) 84%, #07101f);
}
.pvr-section-block .pvr-table,
.pvr-subpanel .pvr-table {
    background: color-mix(in srgb, var(--pvr-block-surface) 90%, #07101f);
}
.pvr-section-block .pvr-table th,
.pvr-subpanel .pvr-table th {
    background: color-mix(in srgb, var(--pvr-block-accent) 30%, #12213a);
    border-bottom-color: color-mix(in srgb, var(--pvr-block-accent) 45%, transparent);
}
.pvr-section-block .pvr-table tbody tr:nth-child(even),
.pvr-subpanel .pvr-table tbody tr:nth-child(even) {
    background: rgba(255,255,255,.018);
}
.pvr-section-block .pvr-kpi,
.pvr-subpanel .pvr-kpi {
    background: color-mix(in srgb, var(--pvr-block-surface-2) 82%, #07101f);
    border-color: color-mix(in srgb, var(--pvr-block-accent) 30%, rgba(255,255,255,.10));
}
.pvr-section-block .pvr-risk-limits,
.pvr-subpanel .pvr-risk-limits {
    border-top-color: color-mix(in srgb, var(--pvr-block-accent) 40%, transparent);
}

.pvr-section-title-blue { --pvr-title-accent: #4f7eae; }
.pvr-section-title-teal { --pvr-title-accent: #3f9b8d; }
.pvr-section-title-violet { --pvr-title-accent: #8a6aa8; }
.pvr-section-title-amber { --pvr-title-accent: #a98743; }
.pvr-flow-badge {
    color: #fff;
    border-color: color-mix(in srgb, var(--pvr-title-accent, currentColor) 78%, #fff);
    background: color-mix(in srgb, var(--pvr-title-accent, #4f7eae) 72%, #07101f);
    box-shadow: 0 0 0 2px rgba(0,0,0,.18);
}

/* I vecchi accenti parziali non devono prevalere sui nuovi blocchi completi. */
.pvr-page > section.pvr-panel {
    border-top-width: 1px;
    background: #0b1526;
    box-shadow: none;
}
.pvr-page > section.pvr-panel > .pvr-section-block,
.pvr-page > section.pvr-panel > .pvr-subpanel { isolation: isolate; }

/* Analyzer: metadati prima dell'evento, entrambi nello stesso box. */
.pvr-analyzer-event-box {
    display: grid;
    grid-template-columns: minmax(210px, max-content) minmax(280px, 1fr);
    align-items: center;
    gap: 8px;
}
.pvr-analyzer-event-box .pvr-analyzer-event-meta {
    order: 1;
    max-width: 420px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pvr-analyzer-event-box > input {
    order: 2;
    width: 100%;
    min-width: 0;
    max-width: none;
}

@media (max-width: 900px) {
    .pvr-section-block,
    .pvr-subpanel { padding: 9px; }
    .pvr-section-block > .pvr-section-title,
    .pvr-subpanel > .pvr-section-title { margin: -9px -9px 9px; }
    .pvr-analyzer-event-box { grid-template-columns: 1fr; gap: 2px; }
    .pvr-analyzer-event-box .pvr-analyzer-event-meta,
    .pvr-analyzer-event-box > input { width: 100%; max-width: none; }
}
.pvr-subsection-title {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 11px 0 7px;
    padding: 6px 8px;
    border-left: 3px solid color-mix(in srgb, var(--pvr-block-accent, #4f7eae) 72%, #fff);
    background: rgba(255,255,255,.028);
}
.pvr-subsection-title strong { font-size: .9rem; }
.pvr-subsection-title span { color: var(--pvr-muted); font-size: .76rem; }

/* 0043 - workflow guidato, progressive disclosure e riepilogo contabile */
.pvr-workflow-step {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin: 10px 0;
    padding: 12px 14px;
    border: 1px solid rgba(112, 160, 214, .55);
    background: rgba(24, 55, 89, .48);
}
.pvr-workflow-step-copy { display: grid; gap: 3px; min-width: 0; }
.pvr-workflow-step-copy > strong { font-size: 1rem; color: #fff; }
.pvr-workflow-step-copy > span:last-child { color: var(--pvr-muted); font-size: .8rem; }
.pvr-workflow-kicker { color: #ffd04f; font-size: .7rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.pvr-workflow-ready { border-color: rgba(255, 203, 65, .72); background: rgba(87, 67, 15, .28); }
.pvr-workflow-completed { border-color: rgba(65, 194, 145, .62); background: rgba(22, 83, 65, .28); }
.pvr-workflow-locked { opacity: .88; }
.pvr-workflow-lock-message {
    display: grid;
    place-items: center;
    gap: 5px;
    min-height: 82px;
    padding: 16px;
    text-align: center;
    border: 1px dashed rgba(150, 168, 196, .45);
    background: rgba(3, 10, 22, .36);
}
.pvr-workflow-lock-message strong { color: #fff; }
.pvr-workflow-lock-message span { color: var(--pvr-muted); font-size: .82rem; }
.pvr-workflow-stale { position: relative; opacity: .72; }
.pvr-system-stale-warning { opacity: 1; position: relative; z-index: 2; }
.pvr-next-step-banner {
    display: grid;
    justify-items: center;
    gap: 3px;
    width: min(760px, calc(100% - 24px));
    margin: 14px auto;
    padding: 12px 18px;
    text-align: center;
    border: 2px solid #ffd04f;
    background: linear-gradient(90deg, rgba(90, 61, 0, .72), rgba(26, 55, 72, .78), rgba(90, 61, 0, .72));
    box-shadow: 0 0 18px rgba(255, 208, 79, .18);
}
.pvr-next-step-banner span { color: #ffd04f; font-size: .72rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.pvr-next-step-banner strong { color: #fff; font-size: 1.08rem; }
.pvr-next-action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255,255,255,.12);
}
.pvr-next-action-row > div { display: grid; gap: 3px; }
.pvr-more-actions { position: relative; }
.pvr-more-actions > summary {
    cursor: pointer;
    color: #9fc4f2;
    font-size: .74rem;
    font-weight: 800;
    white-space: nowrap;
}
.pvr-more-actions[open] > div {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
    padding: 8px;
    border: 1px solid rgba(117, 148, 187, .45);
    background: #091426;
}
.pvr-collapsed-archive { margin-top: 10px; border: 1px solid rgba(117,148,187,.35); }
.pvr-collapsed-archive > summary { cursor: pointer; padding: 9px 11px; color: #a8c5e9; font-weight: 800; }
.pvr-collapsed-archive[open] > summary { border-bottom: 1px solid rgba(117,148,187,.35); }
.pvr-operational-list-actions { align-items: center; }
/* Release 0045: riepiloghi contabili compatti su una sola riga desktop. */
.pvr-kpi-grid-accounting {
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 6px;
}
.pvr-kpi-grid-accounting > .pvr-kpi {
    min-width: 0;
    padding: 8px 10px;
}
.pvr-kpi-grid-accounting > .pvr-kpi span {
    font-size: .7rem;
    white-space: nowrap;
}
.pvr-kpi-grid-accounting > .pvr-kpi strong {
    font-size: .9rem;
    white-space: nowrap;
}
.pvr-kpi-grid-accounting-detail { grid-template-columns: repeat(7, minmax(120px, 1fr)); }
.pvr-table-accounting small { display: block; }
.pvr-step-timeline { display: grid; gap: 10px; }
.pvr-step-card { border: 1px solid rgba(92, 149, 197, .45); background: rgba(7, 18, 35, .7); }
.pvr-step-card > header { display: flex; align-items: center; gap: 10px; padding: 9px 11px; background: rgba(55, 93, 128, .28); }
.pvr-step-card > header > div { display: grid; gap: 2px; flex: 1; min-width: 0; }
.pvr-step-card > header small { color: var(--pvr-muted); }
.pvr-step-number { display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid #ffd04f; color: #ffd04f; font-weight: 900; }
.pvr-step-accounting-grid {
    display: grid;
    grid-template-columns: .52fr .52fr 1fr 1fr 1fr .9fr .92fr 1fr 1fr 1.08fr;
    gap: 1px;
    background: rgba(100,130,160,.22);
}
.pvr-step-accounting-grid > span {
    display: grid;
    min-width: 0;
    gap: 2px;
    padding: 7px 8px;
    background: #0b1729;
    color: var(--pvr-muted);
    font-size: .67rem;
    line-height: 1.15;
    white-space: nowrap;
}
.pvr-step-accounting-grid strong {
    overflow: hidden;
    color: #fff;
    font-size: .8rem;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pvr-commission-override { display: grid; gap: 4px; }
.pvr-commission-override-row { display: flex; align-items: center; gap: 6px; }
.pvr-commission-override-row input { min-width: 0; flex: 1; }
.pvr-field-help { color: var(--pvr-muted); font-size: .7rem; line-height: 1.25; }
.pvr-mega-card-accounting { border-color: rgba(255, 208, 79, .58); }

@media (max-width: 1200px) {
    .pvr-kpi-grid-accounting, .pvr-kpi-grid-accounting-detail { grid-template-columns: repeat(3, minmax(130px, 1fr)); }
    .pvr-step-accounting-grid { grid-template-columns: repeat(3, minmax(130px, 1fr)); }
}
@media (max-width: 760px) {
    .pvr-workflow-step, .pvr-next-action-row { align-items: stretch; flex-direction: column; }
    .pvr-next-step-banner { width: 100%; }
    .pvr-kpi-grid-accounting, .pvr-kpi-grid-accounting-detail, .pvr-step-accounting-grid { grid-template-columns: 1fr; }
}

/* Release 0046: snapshot quote, tabelle Step e leggibilità Punta/Banca. */
.pvr-col-step,
.pvr-col-step-cell {
    width: 54px;
    min-width: 54px;
    padding-left: 5px !important;
    padding-right: 8px !important;
    text-align: left !important;
}
.pvr-step-index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 26px;
    padding: 0 7px;
    border-left: 4px solid #ffd04f;
    background: rgba(255, 208, 79, .12);
    color: #fff4bd;
    font-weight: 900;
    line-height: 1;
}
.pvr-col-back {
    border-bottom: 3px solid #59b7ff !important;
    background: rgba(41, 132, 199, .14) !important;
    color: #cdeaff !important;
}
.pvr-col-lay {
    border-bottom: 3px solid #54d7b0 !important;
    background: rgba(35, 151, 119, .14) !important;
    color: #c7f8e9 !important;
}
.pvr-col-back-cell,
.pvr-quote-chip-back {
    background: rgba(41, 132, 199, .075) !important;
    box-shadow: inset 2px 0 0 rgba(89, 183, 255, .42);
}
.pvr-col-lay-cell,
.pvr-quote-chip-lay {
    background: rgba(35, 151, 119, .075) !important;
    box-shadow: inset 2px 0 0 rgba(84, 215, 176, .42);
}
.pvr-col-back-cell,
.pvr-col-lay-cell,
.pvr-col-lay-stake-cell {
    padding-left: 10px !important;
    padding-right: 12px !important;
    text-align: right !important;
}
.pvr-col-lay-stake,
.pvr-col-lay-stake-cell { min-width: 112px; }
.pvr-col-exchange,
.pvr-col-exchange-cell {
    min-width: 145px;
    padding-left: 18px !important;
    white-space: nowrap;
}
.pvr-table-step-quotes th,
.pvr-table-step-quotes td,
.pvr-table-analyzer-steps th,
.pvr-table-analyzer-steps td,
.pvr-table-scenarios th,
.pvr-table-scenarios td {
    vertical-align: middle;
}
.pvr-table-analyzer-steps .pvr-col-step,
.pvr-table-analyzer-steps .pvr-col-step-cell { width: 56px !important; }
.pvr-table-analyzer-steps th:nth-child(2),
.pvr-table-analyzer-steps td:nth-child(2) { width: 48px !important; text-align: center; }
.pvr-table-analyzer-steps th:nth-child(5),
.pvr-table-analyzer-steps td:nth-child(5),
.pvr-table-analyzer-steps th:nth-child(6),
.pvr-table-analyzer-steps td:nth-child(6) { width: 118px !important; }
.pvr-table-analyzer-steps th:nth-child(7),
.pvr-table-analyzer-steps td:nth-child(7) { width: 146px !important; }
.pvr-table-scenarios .pvr-col-back,
.pvr-table-scenarios .pvr-col-lay { min-width: 88px; }
.pvr-table-scenarios .pvr-col-lay-stake { min-width: 108px; }

.pvr-system-parameters-grid {
    grid-template-columns: minmax(260px, 1.65fr) minmax(190px, .9fr) 125px 125px 145px minmax(210px, 1.2fr);
    align-items: start;
}
.pvr-field-source-exchange input[readonly] {
    border-color: rgba(84, 215, 176, .55);
    background: rgba(35, 151, 119, .10);
    color: #d8fff3;
    cursor: not-allowed;
}
.pvr-system-quote-snapshot { margin-top: 12px; }
.pvr-table-quote-refresh { min-width: 1040px; table-layout: fixed; }
.pvr-table-quote-refresh th:nth-child(2),
.pvr-table-quote-refresh td:nth-child(2) { width: auto; }
.pvr-table-quote-refresh th:nth-child(3),
.pvr-table-quote-refresh td:nth-child(3),
.pvr-table-quote-refresh th:nth-child(4),
.pvr-table-quote-refresh td:nth-child(4) { width: 155px; }
.pvr-table-quote-refresh th:nth-child(5),
.pvr-table-quote-refresh td:nth-child(5),
.pvr-table-quote-refresh th:nth-child(6),
.pvr-table-quote-refresh td:nth-child(6) { width: 112px; }
.pvr-table-quote-refresh th:nth-child(7),
.pvr-table-quote-refresh td:nth-child(7) { width: 210px; }
.pvr-quote-status {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 3px 7px;
    border: 1px solid rgba(135, 164, 200, .45);
    background: rgba(45, 65, 94, .55);
    font-size: .69rem;
    font-weight: 850;
    line-height: 1.15;
}
.pvr-quote-status-updated { color: #c7f8e9; border-color: rgba(84,215,176,.58); background: rgba(35,151,119,.16); }
.pvr-quote-status-unchanged, .pvr-quote-status-snapshot { color: #cdeaff; border-color: rgba(89,183,255,.48); background: rgba(41,132,199,.13); }
.pvr-quote-status-not_found, .pvr-quote-status-liquidity_not_found, .pvr-quote-status-liquidity_stale, .pvr-quote-status-liquidity_price_mismatch, .pvr-quote-status-liquidity_invalid_time, .pvr-quote-status-event_started, .pvr-quote-status-error { color: #ffe5a3; border-color: rgba(255,208,79,.52); background: rgba(122,83,9,.20); }
.pvr-system-builder-actions { margin-top: 18px; }

.pvr-detail-final-actions {
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    padding-top: 17px;
    border-top: 1px solid var(--pvr-line);
}
.pvr-detail-final-actions form { margin: 0; }
.pvr-detail-final-actions .pvr-btn { min-width: 176px; justify-content: center; }
.pvr-btn-system {
    border: 1px solid #54d7b0;
    background: linear-gradient(180deg, #176f63, #104c46);
    color: #effffb;
}
.pvr-btn-system:hover { filter: brightness(1.12); }

.pvr-table-portfolio-sources { width: 100%; min-width: 1080px; table-layout: fixed; }
.pvr-table-portfolio-sources th:nth-child(1), .pvr-table-portfolio-sources td:nth-child(1) { width: 42px !important; }
.pvr-table-portfolio-sources th:nth-child(2), .pvr-table-portfolio-sources td:nth-child(2) { width: 76px !important; }
.pvr-table-portfolio-sources th:nth-child(3), .pvr-table-portfolio-sources td:nth-child(3) { width: 185px !important; }
.pvr-table-portfolio-sources th:nth-child(4), .pvr-table-portfolio-sources td:nth-child(4) { width: 95px !important; }
.pvr-table-portfolio-sources th:nth-child(5), .pvr-table-portfolio-sources td:nth-child(5) { width: 90px !important; }
.pvr-table-portfolio-sources th:nth-child(n+6):nth-child(-n+9),
.pvr-table-portfolio-sources td:nth-child(n+6):nth-child(-n+9) { width: 88px !important; }
.pvr-table-portfolio-sources th:nth-child(10), .pvr-table-portfolio-sources td:nth-child(10) { width: 290px !important; }
.pvr-table-portfolio-sources .pvr-portfolio-actions { flex-wrap: nowrap; align-items: center; }
.pvr-table-portfolio-sources .pvr-portfolio-actions > form,
.pvr-table-portfolio-sources .pvr-portfolio-actions > a { flex: 0 0 auto; }
.pvr-table-portfolio-sources .pvr-btn { white-space: nowrap; }

.pvr-scanner-submit { margin-top: 28px; }
@media (min-width: 1161px) {
    .pvr-form-grid-risk-one-line {
        grid-auto-flow: initial;
        grid-template-columns: repeat(8, minmax(92px, 1fr));
        gap: 8px;
    }
    .pvr-form-grid-risk-one-line .pvr-field label { font-size: .64rem; }
}
@media (max-width: 1300px) {
    .pvr-system-parameters-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
    .pvr-detail-final-actions { align-items: stretch; flex-direction: column; }
    .pvr-detail-final-actions .pvr-btn { width: 100%; }
    .pvr-system-parameters-grid { grid-template-columns: 1fr; }
}
.pvr-quote-time-flow { line-height: 1.2; }
.pvr-quote-time-flow span,
.pvr-quote-time-flow strong { display: block; }
.pvr-quote-time-flow span { color: var(--pvr-muted); font-size: .68rem; font-weight: 600; }
.pvr-quote-time-flow strong { margin-top: 2px; color: var(--pvr-text); font-size: .72rem; }

/* Release 0047: hardening tabelle operative e prevenzione accavallamenti. */
.pvr-table .pvr-actions-cell {
    min-width: 0;
    overflow: visible;
}
.pvr-table .pvr-actions-cell > .pvr-inline-actions,
.pvr-table .pvr-actions-cell > form {
    min-width: 0;
    max-width: 100%;
}
.pvr-table .pvr-more-actions { min-width: 0; }
.pvr-table .pvr-more-actions > summary {
    box-sizing: border-box;
    min-height: 27px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #36577f;
    padding: 3px 7px;
    background: #182c4a;
    color: #c4ddff;
    cursor: pointer;
    font-size: .7rem;
    font-weight: 800;
    line-height: 1;
    list-style: none;
    white-space: nowrap;
}
.pvr-table .pvr-more-actions > summary::-webkit-details-marker { display: none; }
.pvr-table .pvr-more-actions[open] > summary { border-color: #f2c552; color: #ffe29a; }
.pvr-table .pvr-more-actions[open] > div {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
    gap: 5px;
    min-width: 0;
    margin-top: 5px;
    padding: 6px;
}

/* Portafoglio: percentuali esplicite, titolo limitato e azioni sempre leggibili. */
.pvr-table-wrap-portfolio-source-list,
.pvr-table-wrap-excluded-sources {
    overflow-x: auto !important;
}
.pvr-table-portfolio-sources {
    width: 100%;
    min-width: 1280px !important;
    table-layout: fixed;
}
.pvr-table-portfolio-sources th,
.pvr-table-portfolio-sources td { box-sizing: border-box; }
.pvr-table-portfolio-sources th:nth-child(1), .pvr-table-portfolio-sources td:nth-child(1) { width: 3% !important; }
.pvr-table-portfolio-sources th:nth-child(2), .pvr-table-portfolio-sources td:nth-child(2) { width: 6.5% !important; }
.pvr-table-portfolio-sources th:nth-child(3), .pvr-table-portfolio-sources td:nth-child(3) { width: 22% !important; }
.pvr-table-portfolio-sources th:nth-child(4), .pvr-table-portfolio-sources td:nth-child(4) { width: 8% !important; }
.pvr-table-portfolio-sources th:nth-child(5), .pvr-table-portfolio-sources td:nth-child(5) { width: 8% !important; }
.pvr-table-portfolio-sources th:nth-child(n+6):nth-child(-n+9),
.pvr-table-portfolio-sources td:nth-child(n+6):nth-child(-n+9) { width: 7% !important; }
.pvr-table-portfolio-sources th:nth-child(10), .pvr-table-portfolio-sources td:nth-child(10) { width: 24.5% !important; }
.pvr-table-portfolio-sources .pvr-source-title,
.pvr-table-portfolio-sources .pvr-source-provider,
.pvr-table-portfolio-sources .pvr-source-exchange {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pvr-table-portfolio-sources .pvr-source-title strong,
.pvr-table-excluded-sources .pvr-source-title strong {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pvr-portfolio-source-actions {
    display: grid !important;
    grid-template-columns: minmax(72px, 1fr) minmax(72px, 1fr) minmax(58px, .72fr) !important;
    grid-auto-flow: row !important;
    grid-auto-columns: auto !important;
    align-items: start !important;
    gap: 5px !important;
    width: 100%;
    min-width: 0;
}
.pvr-portfolio-source-actions > a,
.pvr-portfolio-source-actions > button,
.pvr-portfolio-source-actions > form,
.pvr-portfolio-source-actions > details { min-width: 0; width: 100%; }
.pvr-portfolio-source-actions > form { display: flex !important; }
.pvr-portfolio-source-actions > a,
.pvr-portfolio-source-actions > button,
.pvr-portfolio-source-actions > form > .pvr-btn,
.pvr-portfolio-source-actions > details > summary { width: 100%; }
.pvr-portfolio-source-actions .pvr-btn { min-width: 0; font-size: .69rem; white-space: nowrap; }
.pvr-portfolio-source-actions > .pvr-more-actions[open] { grid-column: 1 / -1; }
.pvr-table-excluded-sources { min-width: 760px; table-layout: fixed; }
.pvr-table-excluded-sources th:nth-child(1), .pvr-table-excluded-sources td:nth-child(1) { width: 100px; }
.pvr-table-excluded-sources th:nth-child(2), .pvr-table-excluded-sources td:nth-child(2) { width: auto; }
.pvr-table-excluded-sources th:nth-child(3), .pvr-table-excluded-sources td:nth-child(3),
.pvr-table-excluded-sources th:nth-child(4), .pvr-table-excluded-sources td:nth-child(4) { width: 130px; }
.pvr-table-excluded-sources th:nth-child(5), .pvr-table-excluded-sources td:nth-child(5) { width: 180px; }

/* Scanner: due sole azioni visibili, senza terza colonna fantasma. */
.pvr-table-wrap-scanner-results { overflow-x: auto !important; }
.pvr-table-wrap-scanner-results .pvr-table-scanner { min-width: 1220px !important; }
.pvr-table-scanner th:nth-child(13), .pvr-table-scanner td:nth-child(13) { width: 235px !important; }
.pvr-scanner-actions {
    display: grid !important;
    grid-template-columns: minmax(132px, 1.45fr) minmax(66px, .72fr) !important;
    grid-auto-flow: row !important;
    grid-auto-columns: auto !important;
    align-items: start !important;
    gap: 5px !important;
    min-width: 0;
}
.pvr-scanner-actions > form,
.pvr-scanner-actions > details { min-width: 0; width: 100%; }
.pvr-scanner-actions > form > .pvr-btn,
.pvr-scanner-actions > details > summary { width: 100%; }
.pvr-scanner-actions > .pvr-more-actions[open] { grid-column: 1 / -1; }

/* Archivio opportunità: titolo controllato e tre azioni senza compressione. */
.pvr-table-wrap-opportunities { overflow-x: auto !important; }
.pvr-table-wrap-opportunities .pvr-table-archive { min-width: 1320px !important; }
.pvr-table-archive th:nth-child(1), .pvr-table-archive td:nth-child(1) { width: 190px !important; }
.pvr-table-archive th:nth-child(13), .pvr-table-archive td:nth-child(13) { width: 230px !important; }
.pvr-table-archive .pvr-archive-title strong {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pvr-opportunity-actions {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    grid-auto-flow: row !important;
    grid-auto-columns: auto !important;
    gap: 5px !important;
    min-width: 0;
}
.pvr-opportunity-actions > a,
.pvr-opportunity-actions > form,
.pvr-opportunity-actions .pvr-btn { min-width: 0; width: 100%; }

/* Elenco piani operativi: prossimo passo e menu secondario separati. */
.pvr-table-wrap-operations-list { overflow-x: auto !important; }
.pvr-table-operations-list { width: 100%; min-width: 1240px !important; table-layout: fixed; }
.pvr-table-operations-list th:nth-child(1), .pvr-table-operations-list td:nth-child(1) { width: 52px; }
.pvr-table-operations-list th:nth-child(2), .pvr-table-operations-list td:nth-child(2) { width: 250px; }
.pvr-table-operations-list th:nth-child(3), .pvr-table-operations-list td:nth-child(3) { width: 112px; }
.pvr-table-operations-list th:nth-child(4), .pvr-table-operations-list td:nth-child(4),
.pvr-table-operations-list th:nth-child(5), .pvr-table-operations-list td:nth-child(5) { width: 112px; }
.pvr-table-operations-list th:nth-child(6), .pvr-table-operations-list td:nth-child(6),
.pvr-table-operations-list th:nth-child(7), .pvr-table-operations-list td:nth-child(7) { width: 72px; }
.pvr-table-operations-list th:nth-child(8), .pvr-table-operations-list td:nth-child(8) { width: 150px; }
.pvr-table-operations-list th:nth-child(9), .pvr-table-operations-list td:nth-child(9) { width: 330px; }
.pvr-operation-title strong {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pvr-operational-list-actions {
    display: grid !important;
    grid-template-columns: minmax(190px, 1fr) minmax(66px, .42fr) !important;
    grid-auto-flow: row !important;
    grid-auto-columns: auto !important;
    align-items: start !important;
    gap: 5px !important;
    min-width: 0;
}
.pvr-operational-list-actions > a,
.pvr-operational-list-actions > details { min-width: 0; width: 100%; }
.pvr-operational-list-actions > a,
.pvr-operational-list-actions > details > summary { width: 100%; }
.pvr-operational-list-actions > .pvr-more-actions[open] { grid-column: 1 / -1; }

/* Tabelle amministrative e archivi con più pulsanti. */
.pvr-table-provider-list { width: 100%; min-width: 1160px; table-layout: fixed; }
.pvr-table-provider-list th:nth-child(1), .pvr-table-provider-list td:nth-child(1) { width: 145px; }
.pvr-table-provider-list th:nth-child(2), .pvr-table-provider-list td:nth-child(2) { width: 90px; }
.pvr-table-provider-list th:nth-child(3), .pvr-table-provider-list td:nth-child(3),
.pvr-table-provider-list th:nth-child(4), .pvr-table-provider-list td:nth-child(4) { width: 210px; }
.pvr-table-provider-list th:nth-child(5), .pvr-table-provider-list td:nth-child(5) { width: 95px; }
.pvr-table-provider-list th:nth-child(6), .pvr-table-provider-list td:nth-child(6) { width: 150px; }
.pvr-table-provider-list th:nth-child(7), .pvr-table-provider-list td:nth-child(7) { width: 260px; }
.pvr-provider-row-actions {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    grid-auto-flow: row !important;
    grid-auto-columns: auto !important;
    gap: 5px !important;
    min-width: 0;
}
.pvr-provider-row-actions > a,
.pvr-provider-row-actions > form,
.pvr-provider-row-actions .pvr-btn { min-width: 0; width: 100%; }

.pvr-table-wrap-system-archive { overflow-x: auto !important; }
.pvr-table-system-archive { width: 100%; min-width: 1340px; table-layout: fixed; }
.pvr-table-system-archive th:nth-child(1), .pvr-table-system-archive td:nth-child(1) { width: 210px; }
.pvr-table-system-archive th:nth-child(2), .pvr-table-system-archive td:nth-child(2),
.pvr-table-system-archive th:nth-child(3), .pvr-table-system-archive td:nth-child(3) { width: 105px; }
.pvr-table-system-archive th:nth-child(4), .pvr-table-system-archive td:nth-child(4) { width: 95px; }
.pvr-table-system-archive th:nth-child(5), .pvr-table-system-archive td:nth-child(5) { width: 90px; }
.pvr-table-system-archive th:nth-child(6), .pvr-table-system-archive td:nth-child(6),
.pvr-table-system-archive th:nth-child(7), .pvr-table-system-archive td:nth-child(7),
.pvr-table-system-archive th:nth-child(8), .pvr-table-system-archive td:nth-child(8),
.pvr-table-system-archive th:nth-child(9), .pvr-table-system-archive td:nth-child(9) { width: 105px; }
.pvr-table-system-archive th:nth-child(10), .pvr-table-system-archive td:nth-child(10) { width: 145px; }
.pvr-table-system-archive th:nth-child(11), .pvr-table-system-archive td:nth-child(11) { width: 170px; }
.pvr-system-title strong {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pvr-system-row-actions {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-auto-flow: row !important;
    grid-auto-columns: auto !important;
    gap: 5px !important;
    min-width: 0;
}
.pvr-system-row-actions > a,
.pvr-system-row-actions > form,
.pvr-system-row-actions .pvr-btn { min-width: 0; width: 100%; }

@media (max-width: 760px) {
    .pvr-table .pvr-more-actions[open] > div { grid-template-columns: 1fr; }
}


/* Release 0048: chiusura operazioni, contabilità, Analyzer e Scanner operativo. */
.pvr-operation-closed-banner {
    display: grid;
    justify-items: center;
    gap: 6px;
    width: min(920px, calc(100% - 24px));
    margin: 10px auto 16px;
    padding: 15px 20px;
    border: 2px solid #ff6575;
    background: linear-gradient(90deg, rgba(84,20,31,.94), rgba(40,20,33,.96), rgba(84,20,31,.94));
    box-shadow: 0 0 24px rgba(255,72,96,.32), inset 0 0 18px rgba(255,255,255,.035);
    text-align: center;
}
.pvr-operation-closed-banner > span { color: #ff9dab; font-size: .74rem; font-weight: 950; letter-spacing: .12em; text-transform: uppercase; }
.pvr-operation-closed-banner > strong { color: #fff; font-size: 1.32rem; line-height: 1.15; }
.pvr-operation-closed-banner > small { color: #ffd7dc; font-size: .78rem; }
.pvr-operation-closed-banner .pvr-btn { min-width: 245px; margin-top: 3px; }

.pvr-step-card-terminal { border: 2px solid #ff6575; box-shadow: 0 0 14px rgba(255,72,96,.18); }
.pvr-step-card-disabled { position: relative; opacity: .44; filter: grayscale(.58); border-style: dashed; pointer-events: none; }
.pvr-step-card-disabled > header { background: rgba(48,56,70,.52); }
.pvr-step-disabled-note { padding: 6px 11px; border-bottom: 1px dashed rgba(180,190,205,.35); color: #d1d8e3; background: rgba(25,31,42,.78); font-size: .7rem; font-weight: 800; text-align: center; }

.pvr-kpi-realized-highlight {
    position: relative;
    border: 2px solid #55e2b1 !important;
    background: radial-gradient(circle at 50% 45%, rgba(35,181,132,.30), rgba(8,35,37,.95) 72%) !important;
    box-shadow: 0 0 22px rgba(67,229,174,.36), inset 0 0 14px rgba(67,229,174,.12);
    transform: translateZ(0);
}
.pvr-kpi-realized-highlight span { color: #dffff4 !important; font-weight: 900; letter-spacing: .02em; }
.pvr-kpi-realized-highlight strong { font-size: 1.18rem !important; text-shadow: 0 0 10px currentColor; }
.pvr-accounting-result-cell { border: 2px solid currentColor !important; background: rgba(34,166,122,.16) !important; box-shadow: inset 0 0 12px rgba(65,229,174,.14); font-size: .94rem !important; }
.pvr-accounting-result-cell strong { display: inline-block; transform: scale(1.05); transform-origin: center; text-shadow: 0 0 8px currentColor; }
.pvr-realized-negative { color: #ff7d8b !important; border-color: #ff6575 !important; background: rgba(143,31,49,.18) !important; box-shadow: 0 0 18px rgba(255,72,96,.24); }
.pvr-realized-neutral { color: #d8e2ef !important; border-color: #8393aa !important; background: rgba(83,101,126,.18) !important; }

.pvr-operational-usage-badge { display: grid; gap: 2px; min-width: 0; padding: 5px 7px; border: 1px solid; text-decoration: none; line-height: 1.15; }
.pvr-operational-usage-badge strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .72rem; }
.pvr-operational-usage-badge span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .63rem; }
.pvr-operational-usage-active { color: #c6fff0; border-color: #43d6a7; background: rgba(30,139,109,.22); box-shadow: inset 3px 0 0 #43d6a7; }
.pvr-operational-usage-active:hover { color: #fff; filter: brightness(1.12); }
.pvr-operational-usage-unused { color: #b9c5d5; border-color: #52647b; background: rgba(59,73,94,.20); }
.pvr-table-wrap-opportunities .pvr-table-archive { min-width: 1510px !important; }
.pvr-table-archive th:nth-child(1), .pvr-table-archive td:nth-child(1) { width: 180px !important; }
.pvr-table-archive th:nth-child(13), .pvr-table-archive td:nth-child(13) { width: 205px !important; }
.pvr-table-archive th:nth-child(14), .pvr-table-archive td:nth-child(14) { width: 230px !important; }

.pvr-risk-violation-summary ul { margin: 6px 0 0; padding-left: 20px; }
.pvr-risk-violation-summary li { margin: 3px 0; }
.pvr-analyzer-mode-banner { border-width: 2px; text-align: center; }
.pvr-table-analyzer-steps input.input-validation-error { border: 2px solid #ff6575 !important; background: rgba(108,25,39,.34) !important; box-shadow: 0 0 10px rgba(255,72,96,.24); }
.pvr-visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0,0,0,0) !important; white-space: nowrap !important; border: 0 !important; }

@media (min-width: 1240px) {
    .pvr-form-grid-scanner-one-line {
        display: grid !important;
        grid-template-columns: minmax(210px, 1.25fr) 72px 92px 120px 132px 94px 108px 82px minmax(145px, .88fr) !important;
        gap: 6px !important;
        align-items: end !important;
    }
    .pvr-form-grid-scanner-one-line .pvr-field { min-width: 0; }
    .pvr-form-grid-scanner-one-line .pvr-field label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .68rem; }
    .pvr-form-grid-scanner-one-line .pvr-field-provider,
    .pvr-form-grid-scanner-one-line .pvr-field-market { grid-column: auto !important; }
    .pvr-field-commission-override { position: relative; }
    .pvr-commission-override-row { gap: 4px; }
    .pvr-commission-override-row .pvr-btn { padding-inline: 5px; font-size: .64rem; }
}

.pvr-table-wrap-scanner-results .pvr-table-scanner { min-width: 1270px !important; }
.pvr-table-scanner th:nth-child(8), .pvr-table-scanner td:nth-child(8) { width: 66px !important; }
.pvr-table-scanner th:nth-child(10), .pvr-table-scanner td:nth-child(10) { width: 88px !important; }
.pvr-table-scanner th:nth-child(13), .pvr-table-scanner td:nth-child(13) { width: 292px !important; }
.pvr-scanner-actions {
    display: grid !important;
    grid-template-columns: minmax(126px, 1.35fr) minmax(70px, .76fr) minmax(82px, .9fr) !important;
    gap: 5px !important;
    align-items: stretch !important;
}
.pvr-scanner-actions > form,
.pvr-scanner-actions > button,
.pvr-scanner-actions .pvr-btn { min-width: 0; width: 100%; }
.pvr-scanner-actions .pvr-btn { min-height: 29px; padding: 3px 5px; font-size: .66rem; white-space: nowrap; }

@media (max-width: 760px) {
    .pvr-operation-closed-banner { width: 100%; }
    .pvr-operation-closed-banner .pvr-btn { width: 100%; min-width: 0; }
}


/* Release 0049: Scanner PVR test, Betfair_ItB canonico e centratura globale. */
.pvr-header {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto;
}
.pvr-brand { justify-self: center; }
.pvr-account-area { justify-self: end; }

@media (min-width: 1101px) {
    .pvr-page-head {
        position: relative;
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        align-items: end;
        min-height: 54px;
    }
    .pvr-page-head > :first-child { grid-column: 1; justify-self: start; min-width: 0; }
    .pvr-page-head > p,
    .pvr-page-head > .pvr-head-tools > p,
    .pvr-page-head > .pvr-page-head-actions > p {
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%);
        width: min(680px, 44vw);
        max-width: 44vw;
        margin: 0;
        text-align: center;
        color: var(--pvr-muted);
        line-height: 1.35;
        pointer-events: none;
    }
    .pvr-page-head > .pvr-head-tools,
    .pvr-page-head > .pvr-inline-actions,
    .pvr-page-head > .pvr-page-head-actions {
        grid-column: 2;
        justify-self: end;
        min-width: 0;
    }
}

@media (min-width: 1240px) {
    .pvr-form-grid-scanner-one-line {
        grid-template-columns: minmax(175px, .92fr) 68px 86px 112px 128px 92px 90px 102px 78px minmax(125px, .72fr) !important;
    }
}
.pvr-field-pvr-test input { text-align: center; }
.pvr-pvr-test-override {
    display: inline-block;
    padding: 2px 5px;
    border: 1px solid #ffd35a;
    background: rgba(255, 196, 54, .16);
    color: #ffe58a;
    font-weight: 900;
}
.pvr-table-scanner th:nth-child(n+8):nth-child(-n+12),
.pvr-table-scanner td:nth-child(n+8):nth-child(-n+12) {
    text-align: center !important;
}

@media (max-width: 1100px) {
    .pvr-page-head { display: flex; }
    .pvr-page-head > p,
    .pvr-page-head > .pvr-head-tools > p,
    .pvr-page-head > .pvr-page-head-actions > p {
        position: static;
        width: auto;
        max-width: none;
        transform: none;
        text-align: left;
        pointer-events: auto;
    }
}


/* Release 0050: guida contestuale operativa, header ticket compatto e allineamento bancate. */
.pvr-ticket-page-head {
    min-height: 44px !important;
    align-items: center !important;
    margin-bottom: 7px !important;
}
.pvr-ticket-page-head > :first-child { align-self: center; }
.pvr-ticket-page-head .pvr-eyebrow { margin-bottom: 1px; }
.pvr-ticket-page-head h1 { font-size: clamp(1.45rem, 2.1vw, 1.9rem); }
.pvr-ticket-head-actions {
    align-items: center;
    justify-content: flex-end;
    flex-wrap: nowrap;
    margin: 0;
}
.pvr-ticket-head-actions .pvr-quick-guide { flex: 0 0 auto; }
.pvr-ticket-actions {
    justify-content: center !important;
    align-items: center;
    margin: 4px auto 0;
    padding: 4px 72px 12px;
}
.pvr-next-step-banner-action { gap: 6px; }
.pvr-next-step-banner-action small {
    max-width: 760px;
    color: #d8e4f2;
    font-size: .78rem;
    line-height: 1.35;
}
.pvr-next-step-banner-action .pvr-btn {
    min-width: 220px;
    margin-top: 2px;
}
#pvr-coupons,
#pvr-lays,
#pvr-events { scroll-margin-top: 76px; }
.pvr-table-operational-lays th:nth-child(n+3):nth-child(-n+10),
.pvr-table-operational-lays td:nth-child(n+3):nth-child(-n+10) {
    padding-left: 6px !important;
    padding-right: 6px !important;
    text-align: center !important;
    vertical-align: middle;
}
.pvr-table-operational-lays td:nth-child(8) .pvr-status-badge {
    display: inline-flex;
    justify-content: center;
}

@media (max-width: 1100px) {
    .pvr-ticket-page-head { align-items: stretch !important; }
    .pvr-ticket-head-actions { flex-wrap: wrap; justify-content: flex-start; }
}

@media (max-width: 760px) {
    .pvr-ticket-actions { padding-inline: 0; }
    .pvr-ticket-reference-inline { min-width: 100%; margin-right: 0; }
    .pvr-ticket-actions > .pvr-btn,
    .pvr-ticket-actions > a.pvr-btn { min-width: min(260px, 100%); }
    .pvr-next-step-banner-action .pvr-btn { width: 100%; min-width: 0; }
}

/* Release 0051: abbonamenti utenti, limite provider e centratura Bancata/Spoglio. */
.pvr-provider-limit-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin: 0 0 10px;
    padding: 9px 14px;
    border: 1px solid #3d668b;
    background: rgba(25, 51, 78, .62);
    text-align: center;
}
.pvr-provider-limit-summary > span { color: var(--pvr-muted); font-size: .74rem; }
.pvr-provider-limit-summary > strong { color: #fff; font-size: 1rem; }
.pvr-provider-limit-summary > small { flex-basis: 100%; color: #d9e5f2; }
.pvr-provider-limit-reached { border-color: #d7a72e; background: rgba(102, 75, 12, .24); }
.pvr-provider-limit-exceeded { border-color: #ff6575; background: rgba(105, 29, 43, .28); }

.pvr-profile-subscription-panel { border-color: #d7a72e; }
.pvr-profile-subscription-grid {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr) auto;
    gap: 10px;
    align-items: stretch;
}
.pvr-subscription-kpi { min-height: 68px; }
.pvr-renew-button { align-self: center; min-width: 145px; text-align: center; }

.pvr-subscription-expired-shell { min-height: calc(100vh - 80px); }
.pvr-subscription-expired-card {
    max-width: 680px;
    border: 2px solid #ff6575;
    background: linear-gradient(180deg, rgba(68, 24, 35, .97), rgba(17, 31, 49, .98));
    box-shadow: 0 0 30px rgba(255, 74, 96, .22);
    text-align: center;
}
.pvr-subscription-expired-card h1 { color: #fff; }
.pvr-subscription-expired-card > p { max-width: 560px; margin-inline: auto; }
.pvr-subscription-expired-actions { margin-top: 16px; }

.pvr-admin-user-edit-grid {
    grid-template-columns: minmax(210px, .7fr) minmax(210px, .7fr) minmax(360px, 1.6fr);
    align-items: start;
}
.pvr-admin-note-field { grid-column: auto; }
.pvr-admin-user-summary { grid-template-columns: repeat(3, minmax(150px, 1fr)); }
.pvr-table-registrations th:nth-child(9),
.pvr-table-registrations td:nth-child(9),
.pvr-table-registrations th:nth-child(10),
.pvr-table-registrations td:nth-child(10) { text-align: center; }

.pvr-table-step-quotes th.pvr-col-lay-stake,
.pvr-table-step-quotes td.pvr-col-lay-stake-cell,
.pvr-table-step-quotes th:nth-last-child(2),
.pvr-table-step-quotes td:nth-last-child(2) {
    padding-left: 7px !important;
    padding-right: 7px !important;
    text-align: center !important;
    vertical-align: middle;
}

@media (max-width: 980px) {
    .pvr-profile-subscription-grid,
    .pvr-admin-user-edit-grid,
    .pvr-admin-user-summary { grid-template-columns: 1fr; }
    .pvr-renew-button { width: 100%; }
}


/* Release 0052: responsabilità pregresse cumulative esplicite e vincita potenziale ticket. */
.pvr-cumulative-liability-guide {
    display: grid;
    grid-template-columns: 52px minmax(260px, 1fr) auto;
    align-items: center;
    gap: 12px;
    margin: 0 0 8px;
    padding: 8px 12px;
    border: 1px solid rgba(145, 99, 218, .48);
    background: linear-gradient(90deg, rgba(67, 43, 111, .28), rgba(13, 25, 43, .92) 48%, rgba(13, 25, 43, .72));
}
.pvr-cumulative-liability-icon {
    position: relative;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(174, 121, 255, .62);
    border-radius: 50%;
    background: radial-gradient(circle, rgba(137, 82, 222, .38), rgba(49, 31, 82, .78));
}
.pvr-cumulative-liability-icon span {
    position: absolute;
    width: 23px;
    height: 8px;
    border: 2px solid #c4a4ff;
    border-top: 0;
    transform: rotate(0deg) skewY(-20deg);
}
.pvr-cumulative-liability-icon span:nth-child(1) { top: 10px; }
.pvr-cumulative-liability-icon span:nth-child(2) { top: 17px; }
.pvr-cumulative-liability-icon span:nth-child(3) { top: 24px; }
.pvr-cumulative-liability-copy { min-width: 0; }
.pvr-cumulative-liability-copy strong {
    display: block;
    margin-bottom: 2px;
    color: #c9a9ff;
    font-size: .82rem;
}
.pvr-cumulative-liability-copy span {
    display: block;
    color: #d9d2e8;
    font-size: .72rem;
    line-height: 1.35;
}
.pvr-cumulative-liability-legend {
    display: grid;
    gap: 3px;
    min-width: 168px;
    padding-left: 10px;
    border-left: 1px solid rgba(145, 99, 218, .28);
    color: #d8e1ef;
    font-size: .69rem;
}
.pvr-cumulative-liability-legend > span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.pvr-cumulative-dot {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    box-shadow: 0 0 8px currentColor;
}
.pvr-cumulative-dot-current { color: #5db7ff; background: currentColor; }
.pvr-cumulative-dot-prior { color: #ad79ec; background: currentColor; }
.pvr-cumulative-dot-total { color: #54d7b0; background: currentColor; }

.pvr-kpi-grid-analyzer-results {
    grid-template-columns: repeat(8, minmax(112px, 1fr));
}

.pvr-table-scenarios {
    width: 100%;
    min-width: 1460px;
    table-layout: auto;
}
.pvr-table-scenarios .pvr-scenario-col-code { width: 82px; }
.pvr-table-scenarios .pvr-scenario-col-description { width: auto; }
.pvr-table-scenarios .pvr-scenario-col-back,
.pvr-table-scenarios .pvr-scenario-col-lay { width: 92px; }
.pvr-table-scenarios .pvr-scenario-col-stake { width: 126px; }
.pvr-table-scenarios .pvr-scenario-col-current-liability { width: 126px; }
.pvr-table-scenarios .pvr-scenario-col-cumulative { width: 300px; }
.pvr-table-scenarios .pvr-scenario-col-exchange-receipt { width: 132px; }
.pvr-table-scenarios .pvr-scenario-col-pvr { width: 96px; }
.pvr-table-scenarios .pvr-scenario-col-result { width: 108px; }
.pvr-table-scenarios th:nth-child(1),
.pvr-table-scenarios td:nth-child(1) { text-align: center; }
.pvr-table-scenarios .pvr-scenario-description-heading,
.pvr-table-scenarios .pvr-scenario-description-cell {
    width: auto;
    min-width: 360px;
}
.pvr-table-scenarios .pvr-scenario-description-cell {
    max-width: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.pvr-table-scenarios .pvr-scenario-compact-value,
.pvr-table-scenarios th.pvr-center,
.pvr-table-scenarios td.pvr-center {
    text-align: center !important;
    white-space: nowrap;
}
.pvr-table-scenarios .pvr-col-back-cell,
.pvr-table-scenarios .pvr-col-lay-cell,
.pvr-table-scenarios .pvr-col-lay-stake-cell {
    padding-left: 12px !important;
    padding-right: 12px !important;
}
.pvr-table-scenarios .pvr-cumulative-liability-heading,
.pvr-table-scenarios .pvr-cumulative-liability-cell {
    width: 300px;
    min-width: 300px;
    max-width: 300px;
    text-align: center !important;
    background: rgba(78, 52, 119, .12);
    box-shadow: inset 1px 0 0 rgba(145, 99, 218, .30), inset -1px 0 0 rgba(145, 99, 218, .30);
}
.pvr-cumulative-liability-heading {
    color: #d1b4ff !important;
    border-top: 1px solid rgba(145, 99, 218, .58) !important;
}
.pvr-cumulative-liability-heading > span,
.pvr-cumulative-liability-heading > small { display: block; }
.pvr-cumulative-liability-heading > small {
    margin-top: 1px;
    color: #a99bbb;
    font-size: .59rem;
    font-weight: 600;
    letter-spacing: .01em;
}
.pvr-cumulative-liability-cell { position: relative; overflow: visible; }
.pvr-cumulative-formula {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(72px, 1fr) 14px minmax(72px, 1fr) 14px minmax(76px, 1fr);
    align-items: center;
    gap: 3px;
    width: 100%;
}
.pvr-cumulative-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 24px;
    padding: 3px 7px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: .67rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.pvr-cumulative-chip-current {
    color: #d7efff;
    border-color: rgba(93, 183, 255, .55);
    background: linear-gradient(90deg, rgba(38, 115, 171, .68), rgba(23, 78, 121, .72));
}
.pvr-cumulative-chip-prior {
    color: #f1e5ff;
    border-color: rgba(173, 121, 236, .56);
    background: linear-gradient(90deg, rgba(105, 61, 156, .72), rgba(69, 43, 105, .78));
}
.pvr-cumulative-chip-total {
    color: #d7fff3;
    border-color: rgba(84, 215, 176, .58);
    background: linear-gradient(90deg, rgba(22, 113, 84, .74), rgba(17, 82, 64, .82));
}
.pvr-cumulative-operator {
    color: #d8e1ef;
    font-size: .70rem;
    font-weight: 900;
    text-align: center;
}
.pvr-cumulative-has-prior::before {
    content: "↳";
    position: absolute;
    left: -8px;
    top: 50%;
    z-index: 2;
    transform: translateY(-50%);
    color: #ad79ec;
    font-size: 1.05rem;
    font-weight: 900;
    text-shadow: 0 0 8px rgba(173, 121, 236, .8);
}
.pvr-cumulative-final {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
}
.pvr-cumulative-final .pvr-cumulative-chip { min-width: 118px; }
.pvr-cumulative-final small {
    color: #b9aacd;
    font-size: .58rem;
    white-space: nowrap;
}

@media (max-width: 1250px) {
    .pvr-kpi-grid-analyzer-results { grid-template-columns: repeat(4, minmax(118px, 1fr)); }
}
@media (max-width: 850px) {
    .pvr-cumulative-liability-guide { grid-template-columns: 44px 1fr; }
    .pvr-cumulative-liability-legend {
        grid-column: 1 / -1;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        min-width: 0;
        padding: 7px 0 0;
        border-left: 0;
        border-top: 1px solid rgba(145, 99, 218, .28);
    }
    .pvr-kpi-grid-analyzer-results { grid-template-columns: repeat(2, minmax(118px, 1fr)); }
}
@media (max-width: 520px) {
    .pvr-cumulative-liability-guide { grid-template-columns: 1fr; text-align: center; }
    .pvr-cumulative-liability-icon { margin-inline: auto; }
    .pvr-cumulative-liability-legend { grid-template-columns: 1fr; text-align: left; }
    .pvr-kpi-grid-analyzer-results { grid-template-columns: 1fr; }
}


/* Release 0054: campi proporzionati al contenuto e spaziatura trasversale obbligatoria. */
.pvr-form-grid {
    column-gap: 14px;
    row-gap: 11px;
}
.pvr-field {
    gap: 5px;
}
.pvr-field label,
.pvr-field > span:first-child {
    display: inline-block;
    line-height: 1.24;
    margin-bottom: 2px;
}
.pvr-section-title {
    gap: 18px;
    margin-bottom: 10px;
}
.pvr-table th,
.pvr-table td {
    padding-left: 10px;
    padding-right: 10px;
}
.pvr-table th { line-height: 1.28; }
.pvr-table td { line-height: 1.26; }
.pvr-table-compact th,
.pvr-table-compact td {
    padding-left: 9px;
    padding-right: 9px;
}

/* Crea sistema: le larghezze seguono il contenuto, non lo spazio residuo. */
.pvr-system-parameters-grid {
    grid-template-columns: minmax(360px, 2fr) minmax(220px, 1fr) 124px 132px 142px 240px;
    column-gap: 14px;
    row-gap: 10px;
    align-items: start;
}
.pvr-system-parameters-grid .pvr-field > span:first-child {
    min-height: 1.35em;
    white-space: nowrap;
    overflow: visible;
    text-overflow: clip;
}
.pvr-system-field-source,
.pvr-system-field-exchange,
.pvr-system-field-stake,
.pvr-system-field-commission,
.pvr-system-field-floor,
.pvr-system-field-title {
    min-width: 0;
}
.pvr-system-field-stake,
.pvr-system-field-commission,
.pvr-system-field-floor,
.pvr-system-field-title {
    justify-self: start;
    width: 100%;
}
.pvr-system-field-stake { max-width: 124px; }
.pvr-system-field-commission { max-width: 132px; }
.pvr-system-field-floor { max-width: 142px; }
.pvr-system-field-title {
    width: 240px;
    max-width: 240px;
}
.pvr-system-field-exchange input[readonly] { color: #d8fff3; }

@media (max-width: 1450px) {
    .pvr-system-parameters-grid {
        grid-template-columns: minmax(320px, 1.7fr) minmax(210px, 1fr) 120px 128px 138px 220px;
        column-gap: 11px;
    }
    .pvr-system-field-title {
        width: 220px;
        max-width: 220px;
    }
}
@media (max-width: 1180px) {
    .pvr-system-parameters-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .pvr-system-field-title,
    .pvr-system-field-stake,
    .pvr-system-field-commission,
    .pvr-system-field-floor {
        width: 100%;
        max-width: none;
    }
}
@media (max-width: 760px) {
    .pvr-system-parameters-grid { grid-template-columns: 1fr; }
}


/* Release 0055: utile massimo Scanner, respiro cumulativo e allineamenti finali. */
.pvr-table-wrap-scanner-results {
    overflow-x: auto;
}
.pvr-table-wrap-scanner-results .pvr-table-scanner {
    width: 100%;
    min-width: 1460px;
    table-layout: fixed;
}
.pvr-table-scanner th,
.pvr-table-scanner td {
    padding-left: 7px;
    padding-right: 7px;
    text-align: center;
}
.pvr-table-scanner th:nth-child(1),
.pvr-table-scanner td:nth-child(1) { width: 118px; text-align: left; }
.pvr-table-scanner th:nth-child(2),
.pvr-table-scanner td:nth-child(2) { width: 52px; }
.pvr-table-scanner th:nth-child(3),
.pvr-table-scanner td:nth-child(3) { width: 66px; }
.pvr-table-scanner th:nth-child(4),
.pvr-table-scanner td:nth-child(4) { width: 64px; }
.pvr-table-scanner th:nth-child(5),
.pvr-table-scanner td:nth-child(5) { width: 78px; }
.pvr-table-scanner th:nth-child(6),
.pvr-table-scanner td:nth-child(6) { width: 78px; }
.pvr-table-scanner th:nth-child(7),
.pvr-table-scanner td:nth-child(7),
.pvr-table-scanner th:nth-child(8),
.pvr-table-scanner td:nth-child(8),
.pvr-table-scanner th:nth-child(9),
.pvr-table-scanner td:nth-child(9) { width: 84px; }
.pvr-table-scanner th:nth-child(10),
.pvr-table-scanner td:nth-child(10) { width: 88px; }
.pvr-table-scanner th:nth-child(11),
.pvr-table-scanner td:nth-child(11) { width: 102px; }
.pvr-table-scanner th:nth-child(12),
.pvr-table-scanner td:nth-child(12) { width: 76px; }
.pvr-table-scanner th:nth-child(13),
.pvr-table-scanner td:nth-child(13) { width: 108px; }
.pvr-table-scanner th:nth-child(14),
.pvr-table-scanner td:nth-child(14) { width: 220px; }
.pvr-table-scanner .pvr-col-max-profit {
    background: rgba(102, 214, 162, .055);
    box-shadow: inset 1px 0 0 rgba(102, 214, 162, .16), inset -1px 0 0 rgba(102, 214, 162, .16);
}

.pvr-table-scenarios .pvr-scenario-col-current-liability { width: 142px; }
.pvr-table-scenarios .pvr-scenario-col-cumulative { width: 324px; }
.pvr-table-scenarios th:nth-child(6),
.pvr-table-scenarios td:nth-child(6) {
    padding-right: 18px !important;
}
/* Recovery 0073R4: la colonna cumulativa aderisce alla tabella senza gutter di background scoperto. */
.pvr-table-scenarios .pvr-cumulative-liability-heading,
.pvr-table-scenarios .pvr-cumulative-liability-cell {
    width: 324px;
    min-width: 324px;
    max-width: 324px;
    padding-left: 22px !important;
    padding-right: 12px !important;
    border-left: 0 !important;
}
.pvr-cumulative-has-prior::before {
    left: 3px;
}
.pvr-cumulative-formula {
    width: calc(100% - 2px);
    margin-left: 2px;
    gap: 5px;
}


/* Release 0056: Scanner senza colonne fantasma e azioni sempre leggibili. */
.pvr-table-wrap-scanner-results {
    overflow-x: auto !important;
    overflow-y: visible;
}
.pvr-table-wrap-scanner-results .pvr-table-scanner {
    width: 100% !important;
    min-width: 1660px !important;
    table-layout: fixed !important;
}
.pvr-table-scanner .pvr-scanner-col-provider { width: 8.0%; }
.pvr-table-scanner .pvr-scanner-col-events { width: 3.2%; }
.pvr-table-scanner .pvr-scanner-col-pvr { width: 4.7%; }
.pvr-table-scanner .pvr-scanner-col-bonus { width: 4.5%; }
.pvr-table-scanner .pvr-scanner-col-total-odd { width: 5.4%; }
.pvr-table-scanner .pvr-scanner-col-spread { width: 5.4%; }
.pvr-table-scanner .pvr-scanner-col-spoglio { width: 6.0%; }
.pvr-table-scanner .pvr-scanner-col-delta { width: 5.2%; }
.pvr-table-scanner .pvr-scanner-col-profit { width: 5.2%; }
.pvr-table-scanner .pvr-scanner-col-max-profit { width: 7.5%; }
.pvr-table-scanner .pvr-scanner-col-liability { width: 6.5%; }
.pvr-table-scanner .pvr-scanner-col-roi { width: 5.0%; }
.pvr-table-scanner .pvr-scanner-col-start { width: 7.5%; }
.pvr-table-scanner .pvr-scanner-col-actions { width: 25.7%; }
.pvr-table-scanner th:nth-child(13),
.pvr-table-scanner td:nth-child(13),
.pvr-table-scanner th:nth-child(14),
.pvr-table-scanner td:nth-child(14) {
    width: auto !important;
    min-width: 0 !important;
}
.pvr-table-scanner .pvr-scanner-start-heading,
.pvr-table-scanner .pvr-scanner-start-cell {
    text-align: center !important;
    white-space: nowrap;
    padding-inline: 9px !important;
}
.pvr-table-scanner .pvr-scanner-actions-heading,
.pvr-table-scanner .pvr-scanner-actions-cell {
    min-width: 0 !important;
    padding-left: 8px !important;
    padding-right: 8px !important;
}
.pvr-table-scanner .pvr-scanner-actions-heading { text-align: center !important; }
.pvr-table-scanner .pvr-scanner-actions {
    display: grid !important;
    grid-template-columns: minmax(150px, 1.55fr) minmax(88px, .82fr) minmax(100px, .94fr) !important;
    gap: 7px !important;
    align-items: stretch !important;
    width: 100% !important;
    min-width: 0 !important;
}
.pvr-table-scanner .pvr-scanner-actions > form,
.pvr-table-scanner .pvr-scanner-actions > button,
.pvr-table-scanner .pvr-scanner-actions .pvr-btn {
    min-width: 0 !important;
    width: 100% !important;
}
.pvr-table-scanner .pvr-scanner-actions .pvr-btn {
    min-height: 30px;
    padding: 4px 7px !important;
    font-size: .67rem !important;
    line-height: 1.05;
    white-space: nowrap !important;
    overflow: hidden;
    text-overflow: ellipsis;
}


/* Release 0057: utile massimo realmente speculativo nello Scanner. */
.pvr-table-scanner .pvr-col-max-profit {
    white-space: nowrap;
}
.pvr-speculative-profit-value {
    color: #61e5b5;
    font-weight: 900;
    font-variant-numeric: tabular-nums;
}
.pvr-speculative-scenario {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    margin-left: 5px;
    padding: 1px 5px;
    border: 1px solid currentColor;
    border-radius: 2px;
    font-size: .58rem;
    font-weight: 900;
    line-height: 1.35;
    vertical-align: 1px;
}
.pvr-speculative-win {
    color: #75f0c5;
    background: rgba(34, 160, 116, .14);
}
.pvr-speculative-ko {
    color: #ffd06a;
    background: rgba(181, 126, 26, .14);
}


/* Release 0058: Scanner compatto e riepilogo ticket Provider comprensivo del bonus. */
.pvr-scanner-search-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-top: 10px;
    padding-top: 9px;
    border-top: 1px solid rgba(82, 132, 175, .34);
}
.pvr-scanner-search-footer .pvr-form-note {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    line-height: 1.35;
}
.pvr-scanner-search-footer .pvr-scanner-submit {
    flex: 0 0 auto;
    margin: 0;
    padding: 0;
}
.pvr-scanner-search-footer .pvr-scanner-submit .pvr-btn { white-space: nowrap; }
.pvr-page form[data-pvr-workflow-form="scanner"] .pvr-panel-tight {
    padding-bottom: 12px;
}
.pvr-page form[data-pvr-workflow-form="scanner"] .pvr-risk-limits {
    margin-top: 8px;
    padding-top: 6px;
}
.pvr-page form[data-pvr-workflow-form="scanner"] .pvr-risk-limits[open] > summary {
    margin-bottom: 5px;
}
@media (max-width: 760px) {
    .pvr-scanner-search-footer {
        align-items: stretch;
        flex-direction: column;
        gap: 9px;
    }
    .pvr-scanner-search-footer .pvr-scanner-submit,
    .pvr-scanner-search-footer .pvr-scanner-submit .pvr-btn { width: 100%; }
}


/* Release 0060: vincite potenziali bonus-incluse e tabelle economiche proporzionate. */
.pvr-ticket-return-cell {
    color: #78ebc0;
    font-weight: 900;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.pvr-table-wrap-opportunities { overflow-x: auto !important; }
.pvr-table-opportunities-0060 {
    width: 100% !important;
    min-width: 1740px !important;
    table-layout: fixed !important;
}
.pvr-table-opportunities-0060 .pvr-opp-col-title { width: 205px; }
.pvr-table-opportunities-0060 .pvr-opp-col-origin { width: 82px; }
.pvr-table-opportunities-0060 .pvr-opp-col-provider { width: 105px; }
.pvr-table-opportunities-0060 .pvr-opp-col-exchange { width: 82px; }
.pvr-table-opportunities-0060 .pvr-opp-col-events { width: 55px; }
.pvr-table-opportunities-0060 .pvr-opp-col-stake { width: 82px; }
.pvr-table-opportunities-0060 .pvr-opp-col-quote { width: 66px; }
.pvr-table-opportunities-0060 .pvr-opp-col-ticket-win { width: 112px; }
.pvr-table-opportunities-0060 .pvr-opp-col-liability { width: 105px; }
.pvr-table-opportunities-0060 .pvr-opp-col-delta,
.pvr-table-opportunities-0060 .pvr-opp-col-floor { width: 82px; }
.pvr-table-opportunities-0060 .pvr-opp-col-roi { width: 76px; }
.pvr-table-opportunities-0060 .pvr-opp-col-created { width: 126px; }
.pvr-table-opportunities-0060 .pvr-opp-col-usage { width: 215px; }
.pvr-table-opportunities-0060 .pvr-opp-col-actions { width: 245px; }
.pvr-table-opportunities-0060 th,
.pvr-table-opportunities-0060 td {
    box-sizing: border-box;
    padding-inline: 7px !important;
    vertical-align: middle;
}
.pvr-table-opportunities-0060 th:nth-child(n+5):nth-child(-n+12),
.pvr-table-opportunities-0060 td:nth-child(n+5):nth-child(-n+12) { text-align: center !important; }
.pvr-table-opportunities-0060 .pvr-opportunity-actions {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(68px, 1fr));
    gap: 6px !important;
    width: 100%;
}
.pvr-table-opportunities-0060 .pvr-opportunity-actions > * { min-width: 0; }
.pvr-table-opportunities-0060 .pvr-opportunity-actions .pvr-btn { width: 100%; white-space: nowrap; }

.pvr-table-wrap-operations-list { overflow-x: auto !important; }
.pvr-table-operations-0060 {
    width: 100% !important;
    min-width: 1390px !important;
    table-layout: fixed !important;
}
.pvr-table-operations-0060 .pvr-operation-col-id { width: 54px; }
.pvr-table-operations-0060 .pvr-operation-col-plan { width: 245px; }
.pvr-table-operations-0060 .pvr-operation-col-status { width: 112px; }
.pvr-table-operations-0060 .pvr-operation-col-profit,
.pvr-table-operations-0060 .pvr-operation-col-realized { width: 112px; }
.pvr-table-operations-0060 .pvr-operation-col-coupons,
.pvr-table-operations-0060 .pvr-operation-col-lays { width: 68px; }
.pvr-table-operations-0060 .pvr-operation-col-ticket-win { width: 132px; }
.pvr-table-operations-0060 .pvr-operation-col-created { width: 148px; }
.pvr-table-operations-0060 .pvr-operation-col-next { width: 338px; }
.pvr-table-operations-0060 th,
.pvr-table-operations-0060 td { padding-inline: 8px !important; vertical-align: middle; }
.pvr-table-operations-0060 th:nth-child(n+4):nth-child(-n+9),
.pvr-table-operations-0060 td:nth-child(n+4):nth-child(-n+9) { text-align: center !important; }

.pvr-table-portfolio-sources {
    width: 100% !important;
    min-width: 1430px !important;
    table-layout: fixed !important;
}
.pvr-table-portfolio-sources .pvr-col-source-ref { width: 48px !important; }
.pvr-table-portfolio-sources .pvr-col-source-type { width: 88px !important; }
.pvr-table-portfolio-sources .pvr-col-source-title { width: 300px !important; }
.pvr-table-portfolio-sources .pvr-col-source-provider { width: 130px !important; }
.pvr-table-portfolio-sources .pvr-col-source-exchange { width: 105px !important; }
.pvr-table-portfolio-sources .pvr-col-source-money { width: 105px !important; }
.pvr-table-portfolio-sources .pvr-col-source-ticket-win { width: 125px !important; }
.pvr-table-portfolio-sources .pvr-col-source-actions { width: 330px !important; }
.pvr-table-portfolio-sources th,
.pvr-table-portfolio-sources td { padding-inline: 8px !important; vertical-align: middle; }
.pvr-table-portfolio-sources th:nth-child(n+6):nth-child(-n+10),
.pvr-table-portfolio-sources td:nth-child(n+6):nth-child(-n+10) { text-align: center !important; }
.pvr-table-portfolio-sources .pvr-portfolio-source-actions {
    display: grid !important;
    grid-template-columns: minmax(92px, 1fr) minmax(92px, 1fr) minmax(84px, .9fr);
    gap: 7px !important;
    width: 100%;
}
.pvr-table-portfolio-sources .pvr-portfolio-source-actions > * { min-width: 0; }

@media (max-width: 900px) {
    .pvr-mega-card-operations { order: initial; }
}

/* Release 0060 override: neutralizza le vecchie larghezze nth-child, ora sostituite dai colgroup espliciti. */
.pvr-table-opportunities-0060 th,
.pvr-table-opportunities-0060 td,
.pvr-table-operations-0060 th,
.pvr-table-operations-0060 td,
.pvr-table-portfolio-sources th,
.pvr-table-portfolio-sources td {
    width: auto !important;
    min-width: 0 !important;
}
.pvr-table-opportunities-0060 col,
.pvr-table-operations-0060 col,
.pvr-table-portfolio-sources col { width: auto; }
.pvr-table-opportunities-0060 .pvr-opp-col-title { width: 205px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-origin { width: 82px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-provider { width: 105px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-exchange { width: 82px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-events { width: 55px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-stake { width: 82px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-quote { width: 66px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-ticket-win { width: 112px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-liability { width: 105px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-delta,
.pvr-table-opportunities-0060 .pvr-opp-col-floor { width: 82px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-roi { width: 76px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-created { width: 126px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-usage { width: 215px !important; }
.pvr-table-opportunities-0060 .pvr-opp-col-actions { width: 245px !important; }
.pvr-table-operations-0060 .pvr-operation-col-id { width: 54px !important; }
.pvr-table-operations-0060 .pvr-operation-col-plan { width: 245px !important; }
.pvr-table-operations-0060 .pvr-operation-col-status { width: 112px !important; }
.pvr-table-operations-0060 .pvr-operation-col-profit,
.pvr-table-operations-0060 .pvr-operation-col-realized { width: 112px !important; }
.pvr-table-operations-0060 .pvr-operation-col-coupons,
.pvr-table-operations-0060 .pvr-operation-col-lays { width: 68px !important; }
.pvr-table-operations-0060 .pvr-operation-col-ticket-win { width: 132px !important; }
.pvr-table-operations-0060 .pvr-operation-col-created { width: 148px !important; }
.pvr-table-operations-0060 .pvr-operation-col-next { width: 338px !important; }


/* Release 0061: dieci colonne riequilibrate e azioni secondarie esplicite. */
.pvr-table-operations-0060 {
    min-width: 1440px !important;
}
.pvr-table-operations-0060 .pvr-operation-col-id { width: 52px !important; }
.pvr-table-operations-0060 .pvr-operation-col-plan { width: 260px !important; }
.pvr-table-operations-0060 .pvr-operation-col-status { width: 105px !important; }
.pvr-table-operations-0060 .pvr-operation-col-profit,
.pvr-table-operations-0060 .pvr-operation-col-realized { width: 108px !important; }
.pvr-table-operations-0060 .pvr-operation-col-coupons,
.pvr-table-operations-0060 .pvr-operation-col-lays { width: 70px !important; }
.pvr-table-operations-0060 .pvr-operation-col-ticket-win { width: 128px !important; }
.pvr-table-operations-0060 .pvr-operation-col-created { width: 142px !important; }
.pvr-table-operations-0060 .pvr-operation-col-next { width: 397px !important; }
.pvr-table-operations-0060 th,
.pvr-table-operations-0060 td {
    padding-left: 9px !important;
    padding-right: 9px !important;
}
.pvr-table-operations-0060 th:nth-child(1),
.pvr-table-operations-0060 td:nth-child(1),
.pvr-table-operations-0060 th:nth-child(3),
.pvr-table-operations-0060 td:nth-child(3),
.pvr-table-operations-0060 th:nth-child(n+4):nth-child(-n+9),
.pvr-table-operations-0060 td:nth-child(n+4):nth-child(-n+9) {
    text-align: center !important;
}
.pvr-table-operations-0060 .pvr-operational-list-actions {
    display: grid !important;
    grid-template-columns: minmax(220px, 1.75fr) minmax(132px, .9fr) !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100%;
}
.pvr-table-operations-0060 .pvr-operational-list-actions > a,
.pvr-table-operations-0060 .pvr-operational-list-actions > details,
.pvr-table-operations-0060 .pvr-operational-list-actions > form {
    width: 100%;
    min-width: 0;
    margin: 0;
}
.pvr-table-operations-0060 .pvr-operational-list-actions > a,
.pvr-table-operations-0060 .pvr-operational-list-actions > details > summary,
.pvr-table-operations-0060 .pvr-operational-list-actions > form > .pvr-btn {
    width: 100%;
    min-width: 0;
    white-space: nowrap;
}
.pvr-single-secondary-action { margin: 0; }
.pvr-operational-coupon-actions > .pvr-single-secondary-action {
    display: inline-flex;
    align-items: center;
}
.pvr-operational-coupon-actions > .pvr-single-secondary-action .pvr-btn {
    width: auto;
    white-space: nowrap;
}


/* Release 0063: allineamento PVR test e dettaglio candidata su click riga. */
.pvr-form-grid-scanner-one-line .pvr-field-pvr-test {
    position: relative;
    align-self: end;
}
.pvr-form-grid-scanner-one-line .pvr-field-pvr-test input {
    height: 36px;
    min-height: 36px;
    margin: 0;
}
.pvr-form-grid-scanner-one-line .pvr-field-pvr-test > span[data-valmsg-for] {
    position: absolute;
    top: calc(100% + 3px);
    left: 0;
    z-index: 2;
    max-width: 240px;
    margin: 0;
    line-height: 1.15;
}
.pvr-form-grid-scanner-one-line .pvr-field-pvr-test > span.field-validation-valid {
    display: none;
}
.pvr-table-scanner .pvr-scanner-candidate-row {
    cursor: pointer;
}
.pvr-table-scanner .pvr-scanner-candidate-row:hover > td {
    border-top-color: rgba(84, 215, 176, .48);
    border-bottom-color: rgba(84, 215, 176, .48);
    background-color: rgba(84, 215, 176, .045);
}
.pvr-table-scanner .pvr-scanner-candidate-row:focus-visible {
    outline: 2px solid #54d7b0;
    outline-offset: -2px;
}
.pvr-table-scanner .pvr-scanner-candidate-row:focus-visible > td {
    background-color: rgba(84, 215, 176, .07);
}


/* Release 0066: fix UI cumulativi Scanner, Analyzer, Revisione, Portafoglio e System Builder. */
.pvr-dialog-candidate { width: min(1500px, calc(100vw - 24px)); max-width: 1500px; }
.pvr-dialog-candidate .pvr-dialog-body { padding: 12px; }
.pvr-dialog-candidate .pvr-table-candidate-detail { width: 100%; min-width: 1420px; table-layout: fixed; }
.pvr-table-candidate-detail th:nth-child(1), .pvr-table-candidate-detail td:nth-child(1) { width: 54px; }
.pvr-table-candidate-detail th:nth-child(2), .pvr-table-candidate-detail td:nth-child(2) { width: 96px; }
.pvr-table-candidate-detail th:nth-child(3), .pvr-table-candidate-detail td:nth-child(3) { width: 330px; }
.pvr-table-candidate-detail th:nth-child(4), .pvr-table-candidate-detail td:nth-child(4) { width: 145px; }
.pvr-table-candidate-detail th:nth-child(5), .pvr-table-candidate-detail td:nth-child(5), .pvr-table-candidate-detail th:nth-child(6), .pvr-table-candidate-detail td:nth-child(6) { width: 82px; }
.pvr-table-candidate-detail th:nth-child(7), .pvr-table-candidate-detail td:nth-child(7) { width: 112px; }
.pvr-table-candidate-detail th:nth-child(8), .pvr-table-candidate-detail td:nth-child(8) { width: 118px; }
.pvr-table-candidate-detail th:nth-child(9), .pvr-table-candidate-detail td:nth-child(9) { width: 138px; white-space: nowrap; }
.pvr-table-candidate-detail th:nth-child(10), .pvr-table-candidate-detail td:nth-child(10) { width: 102px; }
.pvr-table-candidate-detail th:nth-child(11), .pvr-table-candidate-detail td:nth-child(11), .pvr-table-candidate-detail th:nth-child(12), .pvr-table-candidate-detail td:nth-child(12) { width: 126px; }
.pvr-table-candidate-detail td:nth-child(3) { white-space: normal; overflow-wrap: anywhere; }
.pvr-analyzer-workflow { display: grid; gap: 12px; }
.pvr-workflow-accordion { margin: 0; overflow: hidden; }
.pvr-workflow-accordion-summary { display: grid; grid-template-columns: auto minmax(180px, auto) 1fr auto; align-items: center; gap: 10px; min-height: 38px; margin: -10px -10px 0; padding: 8px 10px; border-bottom: 1px solid var(--pvr-line); background: rgba(31, 58, 91, .92); cursor: pointer; list-style: none; }
.pvr-workflow-accordion-summary::-webkit-details-marker { display: none; }
.pvr-workflow-accordion-summary::after { content: "Apri"; color: var(--pvr-muted); font-size: .68rem; font-weight: 800; }
.pvr-workflow-accordion[open] > .pvr-workflow-accordion-summary::after { content: "Chiudi"; }
.pvr-workflow-accordion-summary strong { color: var(--pvr-text); font-size: .94rem; }
.pvr-workflow-accordion-summary small { color: var(--pvr-muted); text-align: right; }
.pvr-workflow-accordion-content { padding-top: 12px; }
.pvr-analyzer-save-zone { display: grid; grid-template-columns: minmax(280px, 1fr) minmax(190px, auto) minmax(150px, auto); align-items: end; gap: 12px; margin-top: 14px; padding: 14px; border: 1px solid var(--pvr-line-strong); background: linear-gradient(180deg, rgba(20, 36, 61, .94), rgba(11, 22, 40, .96)); }
.pvr-analyzer-save-zone-ready { border-color: rgba(242, 197, 82, .78); box-shadow: inset 0 0 0 1px rgba(242, 197, 82, .16); }
.pvr-analyzer-save-title { margin: 0; }
.pvr-analyzer-save-zone .pvr-btn { min-height: 34px; justify-content: center; }
.pvr-row-expired { opacity: .82; background: rgba(154, 60, 67, .13); }
.pvr-status-expired { margin-left: 8px; color: #ffd1d1; border-color: #8e4248; background: #4a2228; }
.pvr-row-expired .pvr-source-title small { margin-top: 4px; color: #ffc6c6; }
.pvr-table-quote-refresh { min-width: 1320px; table-layout: fixed; }
.pvr-table-quote-refresh th, .pvr-table-quote-refresh td { padding-inline: 12px !important; }
.pvr-table-quote-refresh th:nth-child(1), .pvr-table-quote-refresh td:nth-child(1) { width: 58px; }
.pvr-table-quote-refresh th:nth-child(2), .pvr-table-quote-refresh td:nth-child(2) { width: 285px; }
.pvr-table-quote-refresh th:nth-child(3), .pvr-table-quote-refresh td:nth-child(3), .pvr-table-quote-refresh th:nth-child(4), .pvr-table-quote-refresh td:nth-child(4) { width: 165px; }
.pvr-table-quote-refresh th:nth-child(5), .pvr-table-quote-refresh td:nth-child(5) { width: 170px; }
.pvr-table-quote-refresh th:nth-child(6), .pvr-table-quote-refresh td:nth-child(6), .pvr-table-quote-refresh th:nth-child(7), .pvr-table-quote-refresh td:nth-child(7) { width: 172px; }
.pvr-table-quote-refresh th:nth-child(8), .pvr-table-quote-refresh td:nth-child(8) { width: 128px; }
.pvr-table-quote-refresh th:nth-child(9), .pvr-table-quote-refresh td:nth-child(9) { width: 205px; }
.pvr-system-event-time { display: block; margin-top: 4px; color: #f4d57a; font-size: .67rem; font-weight: 800; white-space: nowrap; }
.pvr-kpi-grid-system-preview { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 5px; }
.pvr-kpi-grid-system-preview .pvr-kpi { min-width: 0; padding: 7px 5px; }
.pvr-kpi-grid-system-preview .pvr-kpi span { font-size: .59rem; line-height: 1.12; }
.pvr-kpi-grid-system-preview .pvr-kpi strong { font-size: .80rem; white-space: nowrap; }
@media (max-width: 1250px) { .pvr-workflow-accordion-summary { grid-template-columns: auto 1fr auto; } .pvr-workflow-accordion-summary small { grid-column: 2 / -1; text-align: left; } .pvr-analyzer-save-zone { grid-template-columns: 1fr 1fr; } .pvr-analyzer-save-title { grid-column: 1 / -1; } .pvr-kpi-grid-system-preview { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
@media (max-width: 760px) { .pvr-dialog-candidate { width: calc(100vw - 12px); } .pvr-workflow-accordion-summary { grid-template-columns: auto 1fr; } .pvr-workflow-accordion-summary::after { grid-column: 2; } .pvr-workflow-accordion-summary small { grid-column: 1 / -1; } .pvr-analyzer-save-zone { grid-template-columns: 1fr; } .pvr-analyzer-save-title { grid-column: auto; } .pvr-kpi-grid-system-preview { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Release 0069: navigazione laterale e area personale unificata sul tema dark classico. */
.pvr-app-layout {
    min-height: calc(100vh - 58px);
    display: grid;
    grid-template-columns: 236px minmax(0, 1fr);
    transition: grid-template-columns .18s ease;
}
.pvr-has-sidebar .pvr-shell {
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 16px 14px 28px;
}
.pvr-sidebar {
    position: sticky;
    top: 58px;
    height: calc(100vh - 58px);
    z-index: 18;
    display: flex;
    flex-direction: column;
    overflow: hidden auto;
    border-right: 1px solid #263d5c;
    background: linear-gradient(180deg, #081426 0%, #07111f 100%);
    box-shadow: 10px 0 26px rgba(0, 0, 0, .18);
}
.pvr-sidebar-nav { display: grid; gap: 8px; padding: 14px 10px; }
.pvr-sidebar a { text-decoration: none; }
.pvr-sidebar-home,
.pvr-nav-primary {
    min-height: 42px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border: 1px solid transparent;
    border-radius: 7px;
    color: #d8e6f4;
    font-weight: 800;
    transition: background .12s ease, border-color .12s ease, color .12s ease;
}
.pvr-sidebar-home:hover,
.pvr-nav-primary:hover,
.pvr-sidebar-home.is-active,
.pvr-nav-primary.is-active {
    color: #fff;
    border-color: #4a6f98;
    background: linear-gradient(90deg, rgba(33, 92, 137, .5), rgba(18, 54, 87, .52));
}
.pvr-nav-group.is-current { border-left: 2px solid var(--pvr-gold); padding-left: 5px; }
.pvr-nav-icon {
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    display: grid;
    place-items: center;
    border: 1px solid #385573;
    border-radius: 6px;
    background: #10233a;
    color: var(--pvr-gold);
    font-size: .94rem;
    font-weight: 900;
}
.pvr-nav-label { white-space: nowrap; }
.pvr-nav-children {
    display: grid;
    gap: 2px;
    margin: 2px 0 4px 39px;
    padding-left: 10px;
    border-left: 1px solid #2e4968;
}
.pvr-nav-children a {
    padding: 7px 8px;
    border-radius: 5px;
    color: #9fb4ca;
    font-size: .79rem;
    font-weight: 700;
}
.pvr-nav-children a:hover,
.pvr-nav-children a.is-active { color: #fff; background: #132b46; }
.pvr-sidebar-foot {
    margin-top: auto;
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 16px;
    border-top: 1px solid #223a58;
    color: #8fa8c1;
    font-size: .76rem;
}
.pvr-sidebar-status-dot { width: 8px; height: 8px; border-radius: 50%; background: #39d98a; box-shadow: 0 0 10px rgba(57, 217, 138, .65); }
.pvr-sidebar-toggle {
    min-width: 94px;
    height: 36px;
    display: inline-grid;
    grid-template-columns: 18px 1fr;
    grid-template-rows: repeat(3, 3px);
    align-content: center;
    align-items: center;
    column-gap: 8px;
    row-gap: 3px;
    padding: 7px 11px;
    border: 1px solid #304a68;
    border-radius: 7px;
    background: #0d1c30;
    color: #dce8f4;
    cursor: pointer;
}
.pvr-sidebar-toggle > span[aria-hidden="true"] { grid-column: 1; width: 18px; height: 2px; background: var(--pvr-gold); }
.pvr-sidebar-toggle-label { grid-column: 2; grid-row: 1 / 4; font-size: .75rem; font-weight: 800; }
.pvr-sidebar-scrim { display: none; }
.pvr-sidebar-collapsed .pvr-app-layout { grid-template-columns: 68px minmax(0, 1fr); }
.pvr-sidebar-collapsed .pvr-sidebar-nav { padding-inline: 8px; }
.pvr-sidebar-collapsed .pvr-sidebar-home,
.pvr-sidebar-collapsed .pvr-nav-primary { justify-content: center; padding-inline: 7px; }
.pvr-sidebar-collapsed .pvr-nav-label,
.pvr-sidebar-collapsed .pvr-nav-children { display: none; }
.pvr-sidebar-collapsed .pvr-nav-group.is-current { padding-left: 0; border-left-width: 0; }
.pvr-sidebar-collapsed .pvr-sidebar-foot { justify-content: center; padding-inline: 0; }
.pvr-account-profile-link {
    min-height: 38px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 9px 4px 5px;
    border: 1px solid transparent;
    border-radius: 7px;
}
.pvr-account-profile-link:hover,
.pvr-account-profile-link.is-active { border-color: #3b5876; background: #0f2137; }
.pvr-account-avatar {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 6px;
    background: #1a3a58;
    color: var(--pvr-gold);
    font-size: .78rem;
    font-weight: 900;
}
.pvr-account-profile-copy { display: grid; line-height: 1.05; }
.pvr-account-profile-copy strong { color: #fff; font-size: .72rem; }
.pvr-account-profile-copy small { max-width: 190px; overflow: hidden; text-overflow: ellipsis; color: #9fb2c7; font-size: .66rem; }

.pvr-home-console { display: grid; gap: 12px; }
.pvr-home-welcome {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 16px 18px;
    border: 1px solid #315273;
    border-left: 4px solid var(--pvr-gold);
    border-radius: 8px;
    background: linear-gradient(115deg, #102641 0%, #0d1d31 72%);
}
.pvr-home-welcome h1 { margin: 1px 0 4px; font-size: clamp(1.45rem, 2.2vw, 2.05rem); }
.pvr-home-welcome p:last-child { margin: 0; color: var(--pvr-muted); }
.pvr-home-kpi-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(145px, 1fr)) minmax(190px, 1.25fr);
    gap: 8px;
}
.pvr-home-kpi {
    min-width: 0;
    display: grid;
    gap: 2px;
    padding: 11px 12px;
    border: 1px solid #2a4564;
    border-radius: 7px;
    background: #0e1e32;
    text-decoration: none;
}
.pvr-home-kpi:hover { border-color: var(--pvr-gold); background: #132842; }
.pvr-home-kpi span { color: #9fb4c9; font-size: .7rem; }
.pvr-home-kpi strong { color: #fff; font-size: 1.18rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pvr-home-kpi small { color: #718ba5; font-size: .66rem; }
.pvr-home-kpi-exchange strong { font-size: .94rem; }
.pvr-home-workspace-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(340px, .8fr); gap: 12px; }
.pvr-home-workflow,
.pvr-home-recent {
    min-width: 0;
    padding: 14px;
    border: 1px solid #2a4564;
    border-radius: 8px;
    background: #0c1a2c;
}
.pvr-home-section-head { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.pvr-home-section-head h2 { margin: 0; font-size: 1.02rem; }
.pvr-home-section-head > span,
.pvr-home-section-head > a { color: #8fa8c1; font-size: .72rem; }
.pvr-home-flow-list { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.pvr-home-flow-list li { margin: 0; }
.pvr-home-flow-link {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    border: 1px solid #243f5d;
    border-radius: 6px;
    background: #102039;
    color: inherit;
    text-decoration: none;
    transition: border-color .12s ease, background .12s ease, box-shadow .12s ease;
}
.pvr-home-flow-link:hover {
    border-color: var(--pvr-gold);
    background: #142944;
    box-shadow: 0 0 0 1px rgba(255, 208, 79, .14);
}
.pvr-home-flow-link:focus-visible {
    outline: 2px solid var(--pvr-gold);
    outline-offset: 2px;
}
.pvr-home-flow-number { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 6px; background: #234668; color: var(--pvr-gold); font-weight: 900; }
.pvr-home-flow-list strong { color: #fff; }
.pvr-home-flow-list p { margin: 2px 0 0; color: #9eb1c5; font-size: .75rem; line-height: 1.25; }
.pvr-home-flow-cta { padding: 6px 10px; border: 1px solid #426384; border-radius: 5px; color: #dce8f3; font-size: .72rem; font-weight: 800; }
.pvr-home-flow-link:hover .pvr-home-flow-cta { border-color: var(--pvr-gold); color: var(--pvr-gold); }
.pvr-home-recent-list { display: grid; gap: 6px; }
.pvr-home-recent-list > a {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto 14px;
    align-items: center;
    gap: 9px;
    padding: 9px 10px;
    border: 1px solid #263f5c;
    border-radius: 6px;
    background: #102039;
    text-decoration: none;
}
.pvr-home-recent-list > a:hover { border-color: #4b6f94; background: #142944; }
.pvr-home-recent-list strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #fff; font-size: .78rem; }
.pvr-home-recent-list span { color: #8ea6bd; font-size: .67rem; }
.pvr-home-recent-values { display: grid; text-align: right; white-space: nowrap; }
.pvr-home-recent-values span:first-child { color: #5ce7a6; }
.pvr-home-recent-list b { color: var(--pvr-gold); font-size: 1.2rem; }
.pvr-home-empty { padding: 28px 12px; }

.pvr-profile-hub { max-width: 1500px; margin-inline: auto; }
.pvr-profile-head { align-items: center; }
.pvr-profile-intro { margin: 4px 0 0; color: var(--pvr-muted); }
.pvr-profile-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(150px, 1fr)) auto;
    gap: 8px;
    align-items: stretch;
    margin-bottom: 10px;
}
.pvr-profile-summary-item {
    display: grid;
    gap: 3px;
    padding: 10px 12px;
    border: 1px solid #2d4969;
    border-radius: 7px;
    background: #10213a;
}
.pvr-profile-summary-item span { color: #91a8bf; font-size: .7rem; }
.pvr-profile-summary-item strong { color: #fff; font-size: 1rem; }
.pvr-profile-summary .pvr-renew-button { min-width: 112px; align-self: stretch; display: grid; place-items: center; }
.pvr-profile-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    margin-bottom: 10px;
    padding: 6px;
    border: 1px solid #294866;
    border-radius: 8px;
    background: #091728;
}
.pvr-profile-tab {
    min-height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid transparent;
    border-radius: 6px;
    background: transparent;
    color: #a9bdd0;
    font-weight: 800;
    cursor: pointer;
}
.pvr-profile-tab span { color: #708ba5; font-size: .68rem; }
.pvr-profile-tab:hover { background: #10243c; color: #fff; }
.pvr-profile-tab.is-active { border-color: #4e7398; background: #193552; color: #fff; box-shadow: inset 0 -2px 0 var(--pvr-gold); }
.pvr-profile-tab.is-active span { color: var(--pvr-gold); }
.pvr-profile-tab-panel {
    display: none;
    padding: 14px;
    border: 1px solid #345371;
    border-radius: 8px;
    background: linear-gradient(145deg, #0e2037 0%, #0a1728 100%);
}
.pvr-profile-tab-panel.is-active { display: block; }
.pvr-profile-panel-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
    margin: 0 0 12px;
    padding: 0 0 9px;
    border-bottom: 1px solid #2c4968;
    background: transparent;
}
.pvr-profile-panel-head h2 { margin: 0; font-size: 1.08rem; }
.pvr-profile-panel-head > span { color: #91a7bd; font-size: .72rem; text-align: right; }
.pvr-profile-account-grid {
    display: grid;
    grid-template-columns: minmax(180px, 1.1fr) minmax(170px, 1fr) minmax(200px, 1.05fr) minmax(150px, .8fr) auto;
    gap: 9px;
    align-items: end;
}
.pvr-profile-password-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(180px, 1fr)) auto;
    gap: 9px;
    align-items: end;
}
.pvr-profile-provider-form {
    display: grid;
    grid-template-columns: minmax(220px, 1.15fr) 92px auto minmax(170px, 1fr) minmax(160px, .9fr) auto;
    gap: 8px;
    align-items: end;
    margin: 10px 0 12px;
    padding: 10px;
    border: 1px solid #2b4968;
    border-radius: 7px;
    background: rgba(8, 22, 38, .68);
}
.pvr-grid-full { grid-column: 1 / -1; }
.pvr-provider-active-check { min-height: 36px; align-self: end; white-space: nowrap; }
.pvr-provider-form-actions { flex-wrap: nowrap; margin: 0; }
.pvr-provider-form-actions .pvr-btn { white-space: nowrap; }
.pvr-profile-provider-list { width: 100%; overflow-x: auto; }
.pvr-profile-provider-table { width: 100%; min-width: 0; table-layout: auto; }
.pvr-profile-provider-table th:nth-child(1) { width: 15%; }
.pvr-profile-provider-table th:nth-child(2) { width: 72px; }
.pvr-profile-provider-table th:nth-child(3),
.pvr-profile-provider-table th:nth-child(4) { width: 20%; }
.pvr-profile-provider-table th:nth-child(5) { width: 90px; }
.pvr-profile-provider-table th:nth-child(6) { width: 120px; }
.pvr-profile-provider-table th:nth-child(7) { width: 245px; }
.pvr-profile-provider-row-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; flex-wrap: nowrap; }
.pvr-profile-provider-row-actions > a,
.pvr-profile-provider-row-actions > form,
.pvr-profile-provider-row-actions .pvr-btn { width: 100%; min-width: 0; }
.pvr-profile-exchange-toolbar { grid-template-columns: minmax(180px, 260px) minmax(250px, 1fr) auto; }
.pvr-profile-hub .pvr-exchange-settings-table { min-width: 880px; table-layout: auto; }

@media (max-width: 1180px) {
    .pvr-home-kpi-strip { grid-template-columns: repeat(3, minmax(150px, 1fr)); }
    .pvr-home-workspace-grid { grid-template-columns: 1fr; }
    .pvr-profile-account-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-profile-account-grid .pvr-actions { grid-column: 1 / -1; }
    .pvr-profile-provider-form { grid-template-columns: minmax(220px, 1fr) 100px auto minmax(180px, 1fr); }
    .pvr-profile-provider-form > :nth-child(6) { grid-column: 1 / 3; }
    .pvr-profile-provider-form-actions { grid-column: 3 / -1; justify-content: flex-end; }
}
@media (max-width: 900px) {
    .pvr-header { grid-template-columns: auto minmax(0, 1fr) auto; padding: 6px 10px; }
    .pvr-header-side { display: flex; grid-column: 1; }
    .pvr-brand { grid-column: 2; justify-self: center; }
    .pvr-account-area { grid-column: 3; max-width: 46vw; }
    .pvr-app-layout { display: block; }
    .pvr-sidebar {
        position: fixed;
        top: 58px;
        bottom: 0;
        left: 0;
        width: min(290px, 86vw);
        height: auto;
        transform: translateX(-102%);
        transition: transform .18s ease;
    }
    .pvr-sidebar-mobile-open .pvr-sidebar { transform: translateX(0); }
    .pvr-sidebar-scrim {
        position: fixed;
        inset: 58px 0 0;
        z-index: 17;
        display: block;
        background: rgba(1, 8, 16, .66);
        opacity: 0;
        visibility: hidden;
        transition: opacity .18s ease, visibility .18s ease;
    }
    .pvr-sidebar-mobile-open .pvr-sidebar-scrim { opacity: 1; visibility: visible; }
    .pvr-sidebar-collapsed .pvr-nav-label,
    .pvr-sidebar-collapsed .pvr-nav-children { display: initial; }
    .pvr-sidebar-collapsed .pvr-nav-children { display: grid; }
    .pvr-sidebar-collapsed .pvr-sidebar-home,
    .pvr-sidebar-collapsed .pvr-nav-primary { justify-content: flex-start; }
    .pvr-sidebar-toggle { min-width: 42px; grid-template-columns: 18px; }
    .pvr-sidebar-toggle-label { display: none; }
    .pvr-account-profile-copy small { max-width: 115px; }
    .pvr-home-kpi-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-profile-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .pvr-profile-summary .pvr-renew-button { grid-column: 1 / -1; min-height: 38px; }
    .pvr-profile-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-profile-provider-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pvr-profile-provider-form > * { grid-column: auto !important; }
    .pvr-provider-active-check { align-self: center; }
    .pvr-profile-provider-form-actions { grid-column: 1 / -1 !important; }
    .pvr-profile-password-grid { grid-template-columns: 1fr; }
    .pvr-profile-password-grid .pvr-actions { justify-content: stretch; }
    .pvr-profile-password-grid .pvr-btn { width: 100%; }
}
@media (max-width: 620px) {
    .pvr-account-profile-copy { display: none; }
    .pvr-home-welcome { align-items: stretch; flex-direction: column; }
    .pvr-home-kpi-strip { grid-template-columns: 1fr; }
    .pvr-home-flow-link { grid-template-columns: 30px minmax(0, 1fr); }
    .pvr-home-flow-cta { justify-self: start; }
    .pvr-home-recent-list > a { grid-template-columns: minmax(0, 1fr) 14px; }
    .pvr-home-recent-values { display: none; }
    .pvr-profile-summary { grid-template-columns: 1fr; }
    .pvr-profile-tabs { grid-template-columns: 1fr 1fr; }
    .pvr-profile-panel-head { align-items: flex-start; flex-direction: column; }
    .pvr-profile-panel-head > span { text-align: left; }
    .pvr-profile-account-grid,
    .pvr-profile-provider-form { grid-template-columns: 1fr; }
    .pvr-profile-provider-form-actions { display: grid; grid-template-columns: 1fr; }
}

/* Release 0070: bootstrap sidebar senza flash, step globali distinti e stato analisi opportunita. */
html.pvr-sidebar-booting *,
html.pvr-sidebar-booting *::before,
html.pvr-sidebar-booting *::after { transition: none !important; animation: none !important; }
html.pvr-sidebar-precollapsed .pvr-app-layout { grid-template-columns: 68px minmax(0, 1fr); }
html.pvr-sidebar-precollapsed .pvr-sidebar-nav { padding-inline: 8px; }
html.pvr-sidebar-precollapsed .pvr-sidebar-home,
html.pvr-sidebar-precollapsed .pvr-nav-primary { justify-content: center; padding-inline: 7px; }
html.pvr-sidebar-precollapsed .pvr-nav-label,
html.pvr-sidebar-precollapsed .pvr-nav-children { display: none; }
html.pvr-sidebar-precollapsed .pvr-nav-group.is-current { padding-left: 0; border-left-width: 0; }
html.pvr-sidebar-precollapsed .pvr-sidebar-foot { justify-content: center; padding-inline: 0; }

/* Comandamento UI: ogni step numerato deve avere una superficie completa e immediatamente distinta. */
.pvr-numbered-stage {
    --pvr-stage-accent: #4f7eae;
    --pvr-stage-bg-a: #10243d;
    --pvr-stage-bg-b: #09172a;
    border: 1px solid color-mix(in srgb, var(--pvr-stage-accent) 76%, #07101f) !important;
    border-left: 6px solid var(--pvr-stage-accent) !important;
    background: linear-gradient(145deg, var(--pvr-stage-bg-a), var(--pvr-stage-bg-b)) !important;
    box-shadow: 0 8px 22px rgba(0, 0, 0, .24), inset 0 1px 0 rgba(255,255,255,.025);
}
.pvr-numbered-stage-blue { --pvr-stage-accent: #5b91c9; --pvr-stage-bg-a: #112b48; --pvr-stage-bg-b: #0a192d; }
.pvr-numbered-stage-teal { --pvr-stage-accent: #39a897; --pvr-stage-bg-a: #0d3133; --pvr-stage-bg-b: #071d24; }
.pvr-numbered-stage-violet { --pvr-stage-accent: #9a70bd; --pvr-stage-bg-a: #29213e; --pvr-stage-bg-b: #171428; }
.pvr-numbered-stage-amber { --pvr-stage-accent: #d5a33e; --pvr-stage-bg-a: #382b1b; --pvr-stage-bg-b: #211817; }
.pvr-numbered-stage > .pvr-section-title,
.pvr-numbered-stage > summary,
.pvr-numbered-stage .pvr-analyzer-final-step-title {
    border-bottom-color: color-mix(in srgb, var(--pvr-stage-accent) 65%, transparent) !important;
    background: color-mix(in srgb, var(--pvr-stage-accent) 20%, #091322) !important;
}
.pvr-profile-tabs .pvr-profile-tab:nth-child(1) { --pvr-tab-accent: #5b91c9; }
.pvr-profile-tabs .pvr-profile-tab:nth-child(2) { --pvr-tab-accent: #39a897; }
.pvr-profile-tabs .pvr-profile-tab:nth-child(3) { --pvr-tab-accent: #9a70bd; }
.pvr-profile-tabs .pvr-profile-tab:nth-child(4) { --pvr-tab-accent: #d5a33e; }
.pvr-profile-tabs .pvr-profile-tab { border-bottom: 3px solid var(--pvr-tab-accent); background: color-mix(in srgb, var(--pvr-tab-accent) 11%, #0b1728); }
.pvr-profile-tabs .pvr-profile-tab.is-active { background: color-mix(in srgb, var(--pvr-tab-accent) 27%, #0b1728); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--pvr-tab-accent) 60%, transparent); }

.pvr-cumulative-liability-cell { padding-left: 14px !important; padding-right: 18px !important; }
.pvr-cumulative-formula { padding-left: 4px; padding-right: 10px; }

.pvr-analyzer-save-zone { grid-template-columns: minmax(260px, 1fr) auto auto; }
.pvr-analyzer-final-step-title { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; margin: -12px -12px 4px; padding: 10px 12px; }
.pvr-analyzer-final-step-title > div { display: grid; gap: 2px; }
.pvr-analyzer-final-step-title small { color: #c8d4e4; }
.pvr-analyzer-reject-reason { grid-column: 1 / -1; }

.pvr-analysis-state { display: inline-flex; align-items: center; justify-content: center; min-width: 78px; padding: 4px 8px; border: 1px solid; border-radius: 4px; font-size: .72rem; font-weight: 900; text-transform: uppercase; letter-spacing: .025em; }
.pvr-analysis-state-approved { color: #9ee5bd; border-color: #357b57; background: #0d3324; }
.pvr-analysis-state-rejected { color: #ffb4b4; border-color: #9d4444; background: #3a171c; }
.pvr-analysis-status-cell { min-width: 150px; }
.pvr-analysis-status-cell small { display: block; max-width: 230px; margin-top: 4px; color: #b8c5d6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pvr-rejected-opportunity-alert { display: grid; gap: 5px; border-left: 5px solid #d85757; }
.pvr-opp-col-status { width: 160px; }

@media (max-width: 900px) {
    html.pvr-sidebar-precollapsed .pvr-app-layout { grid-template-columns: minmax(0, 1fr); }
    html.pvr-sidebar-precollapsed .pvr-nav-label,
    html.pvr-sidebar-precollapsed .pvr-nav-children { display: initial; }
    .pvr-analyzer-save-zone { grid-template-columns: 1fr; }
    .pvr-analyzer-final-step-title,
    .pvr-analyzer-reject-reason { grid-column: 1; }
}

/* Contratto globale 0070: anche i blocchi numerati generati dal runtime devono distinguersi a colpo d'occhio. */
.pvr-section-block-blue,
.pvr-subpanel-blue {
    --pvr-block-accent: #5b91c9;
    --pvr-block-surface: #07182c;
    --pvr-block-surface-2: #153353;
}
.pvr-section-block-teal,
.pvr-subpanel-teal {
    --pvr-block-accent: #39a897;
    --pvr-block-surface: #061e25;
    --pvr-block-surface-2: #10413f;
}
.pvr-section-block-violet,
.pvr-subpanel-violet {
    --pvr-block-accent: #9a70bd;
    --pvr-block-surface: #171429;
    --pvr-block-surface-2: #33284b;
}
.pvr-section-block-amber,
.pvr-subpanel-amber {
    --pvr-block-accent: #d5a33e;
    --pvr-block-surface: #211817;
    --pvr-block-surface-2: #49351d;
}
.pvr-section-block,
.pvr-subpanel {
    border-left-width: 6px;
    box-shadow: 0 9px 24px rgba(0,0,0,.27), inset 0 1px 0 rgba(255,255,255,.025);
}


/* Release 0071: Analyzer più compatto, metadati evento completi e decisione finale su due colonne. */
.pvr-analyzer-origin-line {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 5px 10px;
    min-width: 0;
}
.pvr-analyzer-origin-line strong { display: inline; }
.pvr-analyzer-origin-line small { display: inline; margin-top: 0; }

.pvr-cumulative-liability-copy {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 3px 8px;
}
.pvr-cumulative-liability-copy strong,
.pvr-cumulative-liability-copy span { display: inline; margin: 0; }

.pvr-analyzer-result-event { min-width: 260px; }
.pvr-analyzer-result-event-meta {
    display: block;
    margin-bottom: 2px;
    color: #d8b868;
    font-size: .66rem;
    font-weight: 800;
    line-height: 1.15;
    white-space: nowrap;
}
.pvr-analyzer-result-event strong { display: block; color: #f7f9fd; font-size: .76rem; }

#analyzer-result + .pvr-analyzer-save-zone,
#analyzer-result-locked + .pvr-analyzer-save-zone { margin-top: -12px; }

.pvr-analyzer-save-zone {
    display: block;
    padding: 12px;
}
.pvr-analyzer-final-step-title > div {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 3px 10px;
}
.pvr-analyzer-final-step-title small { display: inline; }
.pvr-analyzer-decision-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
.pvr-analyzer-decision-grid-single { grid-template-columns: minmax(0, 1fr); }
.pvr-analyzer-decision-card {
    display: grid;
    grid-template-rows: auto auto;
    align-content: start;
    gap: 8px;
    min-width: 0;
    padding: 10px;
    border: 1px solid rgba(213, 163, 62, .35);
    background: rgba(8, 18, 32, .42);
}
.pvr-analyzer-decision-card .pvr-field { min-width: 0; }
.pvr-analyzer-decision-card .pvr-btn { width: 100%; min-height: 34px; justify-content: center; }
.pvr-analyzer-decision-reject { border-color: rgba(196, 72, 79, .46); background: rgba(55, 18, 25, .28); }
.pvr-analyzer-decision-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

@media (max-width: 900px) {
    .pvr-analyzer-decision-grid { grid-template-columns: 1fr; }
    .pvr-analyzer-result-event-meta { white-space: normal; }
}

/* Release 0072: sorgente unica, diagnostica liquidità esplicita, tabelle compatte e azione finale del piano. */
.pvr-portfolio-single-source .pvr-table-portfolio-sources {
    min-width: 1180px !important;
}
.pvr-portfolio-single-source .pvr-col-source-title { width: 260px !important; }
.pvr-portfolio-single-source .pvr-col-source-actions { width: 300px !important; }

.pvr-table-wrap-opportunities { overflow-x: auto !important; }
.pvr-table-opportunities-0072 {
    width: 100% !important;
    min-width: 1580px !important;
    table-layout: fixed !important;
}
.pvr-table-opportunities-0072 col { width: auto; }
.pvr-table-opportunities-0072 .pvr-opp-col-title { width: 220px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-status-origin { width: 138px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-provider { width: 104px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-exchange { width: 88px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-events { width: 50px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-stake { width: 76px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-quote { width: 60px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-ticket-win { width: 104px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-liability { width: 92px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-delta,
.pvr-table-opportunities-0072 .pvr-opp-col-floor { width: 76px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-roi { width: 66px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-created { width: 116px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-usage { width: 180px !important; }
.pvr-table-opportunities-0072 .pvr-opp-col-actions { width: 225px !important; }
.pvr-table-opportunities-0072 th,
.pvr-table-opportunities-0072 td {
    box-sizing: border-box;
    min-width: 0 !important;
    padding: 7px 6px !important;
    vertical-align: middle;
    overflow: hidden;
}
.pvr-table-opportunities-0072 th { white-space: normal; line-height: 1.15; }
.pvr-table-opportunities-0072 .pvr-archive-title strong {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    white-space: normal;
    line-height: 1.25;
    max-height: 2.5em;
}
.pvr-table-opportunities-0072 .pvr-analysis-status-cell { overflow: visible; }
.pvr-analysis-status-stack {
    display: flex;
    min-width: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    line-height: 1.15;
}
.pvr-analysis-status-stack .pvr-analysis-state { max-width: 100%; white-space: nowrap; }
.pvr-analysis-origin {
    display: block;
    max-width: 100%;
    color: #c7d8ed;
    font-size: 10px;
    font-weight: 800;
    line-height: 1.15;
    overflow-wrap: anywhere;
}
.pvr-analysis-reason {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    max-width: 100%;
    overflow: hidden;
    overflow-wrap: anywhere;
}
.pvr-table-opportunities-0072 .pvr-operational-usage-badge {
    min-height: 0;
    padding: 6px 7px;
    line-height: 1.15;
}
.pvr-table-opportunities-0072 .pvr-opportunity-actions {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(64px, 1fr));
    gap: 5px !important;
    width: 100%;
}
.pvr-table-opportunities-0072 .pvr-opportunity-actions > * { min-width: 0; }
.pvr-table-opportunities-0072 .pvr-opportunity-actions .pvr-btn { width: 100%; white-space: nowrap; }

.pvr-optimization-final-action {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 12px;
    margin-top: 18px;
    padding: 18px;
    text-align: center;
}
.pvr-optimization-final-copy {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px 12px;
}
.pvr-optimization-final-copy > span:last-child { color: #d9d3b9; }
.pvr-operational-launch-final {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    width: min(100%, 760px);
}
.pvr-operational-launch-final .pvr-inline-form {
    display: grid;
    grid-template-columns: minmax(240px, 420px) auto;
    justify-content: center;
    gap: 10px;
    width: 100%;
}
.pvr-operational-launch-final .pvr-inline-form input { min-width: 0; }
@media (max-width: 760px) {
    .pvr-operational-launch-final .pvr-inline-form { grid-template-columns: 1fr; }
    .pvr-operational-launch-final .pvr-inline-form .pvr-btn { width: 100%; }
}

.pvr-table-opportunities-0072 .pvr-analysis-status-cell { min-width: 0 !important; }
.pvr-table-opportunities-0072 .pvr-analysis-status-cell small {
    display: block;
    max-width: 100%;
    margin-top: 0;
    white-space: normal;
    overflow: hidden;
    text-overflow: clip;
}
.pvr-table-opportunities-0072 th,
.pvr-table-opportunities-0072 td { width: auto !important; }
.pvr-table-wrap-opportunities .pvr-table-opportunities-0072 { min-width: 1580px !important; }

/* Release 0073: riepiloghi leggibili, operatività preventiva e sandwich universale. */
.pvr-collapsible-section {
    position: relative;
    overflow: hidden;
    transition: box-shadow .16s ease, border-color .16s ease;
}
.pvr-collapsible-section > .pvr-accordion-title {
    cursor: pointer;
    user-select: none;
    outline: none;
    align-items: center;
    min-height: 44px;
    margin-bottom: 10px;
}
.pvr-collapsible-section > .pvr-accordion-title:hover,
.pvr-collapsible-section > .pvr-accordion-title:focus-visible {
    filter: brightness(1.08);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--pvr-title-accent, #5b91c9) 72%, transparent);
}
.pvr-accordion-state {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    min-width: 74px;
    margin-left: auto;
    padding: 4px 8px;
    border: 1px solid color-mix(in srgb, var(--pvr-title-accent, #5b91c9) 58%, transparent);
    border-radius: 4px;
    color: #ecf5ff !important;
    background: rgba(4, 13, 25, .5);
    font-size: .68rem !important;
    font-weight: 900;
    letter-spacing: .025em;
    text-transform: uppercase;
}
.pvr-collapsible-section.is-collapsed > :not(.pvr-accordion-title) { display: none !important; }
.pvr-collapsible-section.is-collapsed > .pvr-accordion-title { margin-bottom: 0 !important; border-bottom-color: transparent !important; }
.pvr-collapsible-section.is-collapsed { min-height: 0; box-shadow: 0 4px 13px rgba(0,0,0,.17); }

.pvr-opportunity-summary-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 420px);
    align-items: stretch;
    gap: 18px;
}
.pvr-opportunity-summary-title { min-width: 0; }
.pvr-opportunity-summary-title h1 { margin-bottom: 4px; }
.pvr-opportunity-summary-title .pvr-page-subtitle {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    max-width: 920px;
    margin: 0;
    overflow: hidden;
    color: #c7d7ea;
    line-height: 1.3;
}
.pvr-summary-status-card {
    display: grid;
    align-content: start;
    gap: 10px;
    min-width: 0;
    padding: 13px 15px;
    border: 1px solid #476a93;
    border-left: 5px solid #f0bd42;
    background: linear-gradient(145deg, #142943, #0b1728 72%);
    box-shadow: 0 9px 24px rgba(0,0,0,.27), inset 0 1px 0 rgba(255,255,255,.04);
}
.pvr-summary-status-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pvr-summary-status-card-head strong { color: #fff; text-transform: uppercase; letter-spacing: .035em; }
.pvr-readonly-badge {
    display: inline-flex;
    padding: 4px 8px;
    border: 1px solid #e0ad36;
    color: #ffdc7a;
    background: #392b0f;
    font-size: .68rem;
    font-weight: 900;
    text-transform: uppercase;
}
.pvr-summary-status-card dl { display: grid; gap: 6px; margin: 0; }
.pvr-summary-status-card dl > div { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 10px; padding-top: 6px; border-top: 1px solid rgba(111,145,183,.28); }
.pvr-summary-status-card dt { color: #9fb3cb; font-size: .72rem; }
.pvr-summary-status-card dd { margin: 0; color: #f4f8ff; font-weight: 800; text-align: right; }

.pvr-kpi-family-grid { display: grid; grid-template-columns: 1.22fr .92fr .82fr; gap: 14px; margin-bottom: 14px; }
.pvr-kpi-family {
    --pvr-family-accent: #5b91c9;
    --pvr-family-bg-a: #142d4b;
    --pvr-family-bg-b: #09182a;
    min-width: 0;
    overflow: hidden;
    border: 1px solid color-mix(in srgb, var(--pvr-family-accent) 68%, #06101e);
    border-top: 4px solid var(--pvr-family-accent);
    background: linear-gradient(145deg, var(--pvr-family-bg-a), var(--pvr-family-bg-b));
    box-shadow: 0 12px 28px rgba(0,0,0,.30), inset 0 1px 0 rgba(255,255,255,.04);
}
.pvr-kpi-family-ticket { --pvr-family-accent: #d8a12b; --pvr-family-bg-a: #4a3210; --pvr-family-bg-b: #1d1206; box-shadow: 0 15px 32px rgba(0,0,0,.34), 0 0 20px rgba(216,161,43,.10), inset 0 1px 0 rgba(255,255,255,.04); }
.pvr-kpi-family-exchange { --pvr-family-accent: #4aa7ff; --pvr-family-bg-a: #123b63; --pvr-family-bg-b: #08182d; transform: translateY(2px); box-shadow: 0 15px 32px rgba(0,0,0,.34), 0 0 20px rgba(74,167,255,.10), inset 0 1px 0 rgba(255,255,255,.04); }
.pvr-kpi-family-result { --pvr-family-accent: #38c172; --pvr-family-bg-a: #123d26; --pvr-family-bg-b: #071a12; box-shadow: 0 15px 32px rgba(0,0,0,.34), 0 0 20px rgba(56,193,114,.10), inset 0 1px 0 rgba(255,255,255,.04); }
.pvr-kpi-family > header { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding: 9px 11px; background: color-mix(in srgb, var(--pvr-family-accent) 17%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--pvr-family-accent) 42%, transparent); }
.pvr-kpi-family > header span { color: #fff; font-weight: 950; text-transform: uppercase; letter-spacing: .04em; }
.pvr-kpi-family > header small { color: #c5d2e2; }
.pvr-kpi-family-values { display: grid; grid-template-columns: repeat(auto-fit, minmax(105px, 1fr)); gap: 1px; background: rgba(115,151,188,.15); }
.pvr-kpi-family-values .pvr-kpi { min-height: 66px; border: 0; background: rgba(5,15,28,.48); }
.pvr-kpi-family-values .pvr-kpi strong { font-size: 1rem; overflow-wrap: anywhere; }
.pvr-summary-reading-note { margin: 0 0 14px; }
.pvr-operability-block { display: grid; gap: 5px; }
.pvr-operability-block span { line-height: 1.38; }
.pvr-opportunity-summary-actions { margin-top: 16px; padding-top: 14px; border-top: 1px solid #30445e; }
.pvr-opportunity-summary-actions > strong { display: block; margin-bottom: 8px; color: #ffd45f; text-align: center; text-transform: uppercase; letter-spacing: .04em; }

.pvr-portfolio-single-source .pvr-col-source-actions { width: 240px !important; }
.pvr-portfolio-source-actions { grid-template-columns: repeat(3, minmax(70px, 1fr)) !important; }

.pvr-section-title-verify-quote { display: grid !important; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto; }
.pvr-section-title-verify-quote h2 { justify-self: start; }
.pvr-section-title-verify-quote .pvr-section-center-note { justify-self: center; color: #fff1a9; font-weight: 950; text-transform: uppercase; letter-spacing: .04em; }
.pvr-section-title-verify-quote > span:not(.pvr-section-center-note):not(.pvr-accordion-state) { justify-self: end; text-align: right; }
.pvr-section-title-verify-quote .pvr-accordion-state { grid-column: 4; }
.pvr-ticket-save-before-receipt { margin: 12px 0 16px; padding: 11px; border: 1px solid #46678d; background: linear-gradient(145deg, #122943, #091827); box-shadow: 0 7px 18px rgba(0,0,0,.23); }
.pvr-ticket-reference-inline { min-width: min(100%, 360px); margin: 0 auto 0 0; }
.pvr-ticket-reference-inline input { min-width: 220px; }
.pvr-ticket-actions > .pvr-btn,
.pvr-ticket-actions > a.pvr-btn { align-self: end; }

.pvr-optimization-final-action { gap: 8px !important; margin-top: 14px !important; padding: 11px 14px !important; }
.pvr-optimization-final-copy { display: grid !important; gap: 2px !important; }
.pvr-optimization-final-copy strong { font-size: 1rem; }
.pvr-optimization-final-copy small { color: #d2cbb1; font-size: .72rem; line-height: 1.2; }
.pvr-operational-launch-final { width: min(100%, 680px) !important; }

@media (max-width: 1000px) {
    .pvr-opportunity-summary-head { grid-template-columns: 1fr; }
    .pvr-kpi-family-grid { grid-template-columns: 1fr; }
    .pvr-kpi-family-exchange { transform: none; }
}
@media (max-width: 760px) {
    .pvr-collapsible-section > .pvr-accordion-title { flex-direction: row !important; align-items: center !important; }
    .pvr-accordion-state { min-width: 62px; margin-left: auto; }
    .pvr-section-title-verify-quote { grid-template-columns: 1fr auto !important; }
    .pvr-section-title-verify-quote .pvr-section-center-note { grid-column: 1 / -1; grid-row: 2; justify-self: start; }
    .pvr-section-title-verify-quote .pvr-accordion-state { grid-column: 2; grid-row: 1; }
    .pvr-section-title-verify-quote > span:not(.pvr-section-center-note):not(.pvr-accordion-state) { display: none; }
}


/* Release 0073R8: Backoffice utenti senza scorrimento orizzontale. */
.pvr-table-wrap-registrations {
    width: 100%;
    overflow-x: hidden !important;
}
.pvr-table-wrap-registrations .pvr-table-registrations {
    width: 100% !important;
    min-width: 0 !important;
    table-layout: fixed !important;
}
.pvr-table-registrations th,
.pvr-table-registrations td {
    min-width: 0 !important;
    padding-left: 7px !important;
    padding-right: 7px !important;
    vertical-align: middle;
    overflow-wrap: anywhere;
    word-break: normal;
}
.pvr-table-registrations th:nth-child(1), .pvr-table-registrations td:nth-child(1) { width: 10% !important; }
.pvr-table-registrations th:nth-child(2), .pvr-table-registrations td:nth-child(2) { width: 8% !important; }
.pvr-table-registrations th:nth-child(3), .pvr-table-registrations td:nth-child(3) { width: 14% !important; }
.pvr-table-registrations th:nth-child(4), .pvr-table-registrations td:nth-child(4) { width: 8% !important; }
.pvr-table-registrations th:nth-child(5), .pvr-table-registrations td:nth-child(5) { width: 8% !important; }
.pvr-table-registrations th:nth-child(6), .pvr-table-registrations td:nth-child(6) { width: 7% !important; }
.pvr-table-registrations th:nth-child(7), .pvr-table-registrations td:nth-child(7) { width: 9% !important; }
.pvr-table-registrations th:nth-child(8), .pvr-table-registrations td:nth-child(8) { width: 8% !important; }
.pvr-table-registrations th:nth-child(9), .pvr-table-registrations td:nth-child(9) { width: 8% !important; }
.pvr-table-registrations th:nth-child(10), .pvr-table-registrations td:nth-child(10) { width: 5% !important; }
.pvr-table-registrations th:nth-child(11), .pvr-table-registrations td:nth-child(11) { width: 15% !important; }
.pvr-table-registrations .pvr-actions-col { min-width: 0 !important; }
.pvr-table-registrations .pvr-actions-cell {
    min-width: 0 !important;
    white-space: normal !important;
    overflow: hidden !important;
}
.pvr-registration-name strong,
.pvr-registration-company span,
.pvr-registration-email span {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    line-height: 1.22;
}
.pvr-registration-email span { font-size: .75rem; }
.pvr-registration-phone { white-space: normal; }
.pvr-registration-date { line-height: 1.15; }
.pvr-registration-date span,
.pvr-registration-date small { display: block; white-space: nowrap; }
.pvr-registration-date small { margin-top: 2px; color: var(--pvr-muted); }
.pvr-table-registrations .pvr-role-list { display: flex; flex-wrap: wrap; gap: 3px; }
.pvr-table-registrations .pvr-role-badge,
.pvr-table-registrations .pvr-status { max-width: 100%; font-size: .65rem; }
.pvr-registration-actions {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    align-items: stretch !important;
    gap: 4px !important;
    width: 100%;
    min-width: 0 !important;
}
.pvr-registration-actions > a,
.pvr-registration-actions > form,
.pvr-registration-actions > form:not(.pvr-registration-reject-form) {
    width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    flex: none !important;
}
.pvr-registration-actions .pvr-btn,
.pvr-registration-actions > a.pvr-btn,
.pvr-registration-actions > form:not(.pvr-registration-reject-form) .pvr-btn {
    width: 100% !important;
    min-width: 0 !important;
    padding: 5px 6px !important;
    white-space: normal !important;
    line-height: 1.15;
    font-size: .66rem;
}
.pvr-registration-reject-form {
    grid-column: 1 / -1;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 4px !important;
    min-width: 0 !important;
}
.pvr-registration-reject-form .pvr-action-input {
    width: 100% !important;
    min-width: 0 !important;
}
.pvr-registration-reject-form .pvr-btn {
    width: auto !important;
    min-width: 58px !important;
}
@media (max-width: 1120px) {
    .pvr-table-registrations th,
    .pvr-table-registrations td { padding-left: 5px !important; padding-right: 5px !important; font-size: .7rem; }
    .pvr-table-registrations th:nth-child(2),
    .pvr-table-registrations td:nth-child(2) { display: none; }
    .pvr-table-registrations th:nth-child(1), .pvr-table-registrations td:nth-child(1) { width: 12% !important; }
    .pvr-table-registrations th:nth-child(3), .pvr-table-registrations td:nth-child(3) { width: 16% !important; }
    .pvr-table-registrations th:nth-child(4), .pvr-table-registrations td:nth-child(4) { width: 9% !important; }
    .pvr-table-registrations th:nth-child(5), .pvr-table-registrations td:nth-child(5) { width: 9% !important; }
    .pvr-table-registrations th:nth-child(6), .pvr-table-registrations td:nth-child(6) { width: 8% !important; }
    .pvr-table-registrations th:nth-child(7), .pvr-table-registrations td:nth-child(7) { width: 10% !important; }
    .pvr-table-registrations th:nth-child(8), .pvr-table-registrations td:nth-child(8) { width: 9% !important; }
    .pvr-table-registrations th:nth-child(9), .pvr-table-registrations td:nth-child(9) { width: 9% !important; }
    .pvr-table-registrations th:nth-child(10), .pvr-table-registrations td:nth-child(10) { width: 6% !important; }
    .pvr-table-registrations th:nth-child(11), .pvr-table-registrations td:nth-child(11) { width: 12% !important; }
    .pvr-registration-actions { grid-template-columns: 1fr !important; }
    .pvr-registration-reject-form { grid-template-columns: 1fr !important; }
    .pvr-registration-reject-form .pvr-btn { width: 100% !important; }
}
