/* Focused GP overview and a single dialog for each preparation task. */
#gp-center .gp-selects>label[hidden]{display:none!important}
.gp-type-label{align-self:center;font-weight:750;font-size:16px;color:#fff;border:1px solid #ffffff28;border-radius:10px;padding:12px}
.gp-plan-summary{display:flex;align-items:center;justify-content:space-between;gap:16px}.gp-plan-summary h3{margin:8px 0}.gp-plan-summary p{margin:0}.gp-empty{min-height:240px;display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;background:linear-gradient(#21263055,#0b1019b0);color:#8994a2}.gp-empty>span{font-size:46px;filter:grayscale(1);opacity:.5}
.gp-overview-slots{grid-template-columns:repeat(2,minmax(0,1fr))}.gp-overview-slots .gp-slot{padding:14px}.gp-overview-slots .gp-slot>img{height:80px}.gp-overview-slots .rv-team-pair{gap:6px!important}.gp-overview-slots .rv-driver-tile img{height:88px!important}
.gp-car-preview{position:relative;padding:10px;border-radius:14px;background:linear-gradient(135deg,#42526742,#12192385);border:1px solid #ffffff20;margin:10px 0}.gp-car-preview>img{width:100%;height:110px;object-fit:contain}.gp-car-preview>strong{display:block;font-size:14px}.gp-car-preview .gp-bars{margin-top:10px}.gp-car-preview .gp-bar{font-size:11px}.gp-used-team{position:relative;margin:12px 0}.gp-tag{display:inline-block;padding:4px 8px;background:#b72d493d;border:1px solid #f16a8055;border-radius:8px;font-size:10px;color:#ffafba}
#gp-dialog[open]{display:flex;flex-direction:column;width:min(1080px,calc(100vw - 32px));max-width:1080px;max-height:calc(100dvh - 32px);padding:0;overflow:hidden;background:linear-gradient(135deg,#202938,#0e151f);border:1px solid #74849777;border-radius:22px;color:#eef2fa}
#gp-dialog>header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 20px;border-bottom:1px solid #ffffff20;flex:none;margin:0}#gp-dialog>header h3{margin:0;font-size:20px}#gp-dialog [data-gp-close]{min-width:44px;min-height:44px}
#gp-dialog-content{overflow:auto;min-height:0;padding:18px 20px}#gp-dialog-content:has(.gp-flow){padding:0;display:flex;flex:1;overflow:hidden}
.gp-flow{display:flex;flex-direction:column;min-height:0;width:100%}.gp-flow-steps{display:flex;gap:8px;padding:12px 20px;border-bottom:1px solid #ffffff18;overflow-x:auto;flex:none}.gp-flow-steps span{font-size:11px;padding:8px 10px;white-space:nowrap;border:1px solid #ffffff1c;border-radius:9px;color:#98a5b7}.gp-flow-steps .active{background:#bc294240;color:#fff;border-color:#f4798e}.gp-flow-steps .done{color:#78dbb0;border-color:#78dbb044}
.gp-flow-body{overflow:auto;padding:18px 20px;min-height:0;overscroll-behavior:contain;flex:1}.gp-flow-body>h4{font-size:23px;margin:0 0 12px}.gp-flow-body details{padding:12px;border:1px solid #ffffff25;border-radius:12px;margin:12px 0}.gp-flow-body summary{cursor:pointer;min-height:32px;line-height:1.5}.gp-flow-body p{line-height:1.5}.gp-flow-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 20px max(12px,env(safe-area-inset-bottom));background:#111a26;border-top:1px solid #ffffff24;flex:none}.gp-flow-footer>span{font-size:11px;color:#aab8c9}
#gp-dialog button{min-height:44px}#gp-dialog button[aria-pressed=true]{border-color:#fa8093!important;box-shadow:0 0 0 1px #fa8093,0 0 20px #ec486733;background:linear-gradient(135deg,#62304570,#222e40b0)!important}#gp-dialog button:focus-visible{outline:3px solid #ff9fb0;outline-offset:3px}#gp-flow-error:empty{display:none}#gp-flow-error{color:#ffabb9}
.gp-type-choices{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.gp-type-choices button{display:flex;flex-direction:column;align-items:center;gap:8px;padding:18px!important}.gp-type-choices img{height:90px;width:100%;object-fit:contain}.gp-type-choices small{color:#b3c0d2}
.gp-flow-team-list{grid-template-columns:repeat(2,minmax(0,1fr))}.gp-flow-team-list>button{border-radius:15px!important}.gp-flow-team-list>button>small{display:block;padding:8px;color:#f6b3be}
.gp-new-team{margin-top:16px;padding:16px;border:1px solid #ffffff24;border-radius:15px}.gp-driver-carousel{display:flex;gap:12px;overflow-x:auto;scroll-snap-type:x proximity;padding:12px 3px;margin:8px 0}.gp-driver-carousel>button{flex:0 0 145px;scroll-snap-align:start;padding:0!important}.gp-driver-carousel .rv-driver-tile{padding:8px!important}.gp-driver-carousel .rv-driver-tile img{height:140px!important}
.gp-flow-proposal{margin:12px 0}.gp-flow-proposal>.gp-car-card{margin-bottom:10px}.gp-flow-proposal>.gp-car-card>img{max-height:240px}.gp-flow-saved{display:flex;flex-direction:column;gap:8px}
.gp-track-positions{display:flex;gap:8px;overflow-x:auto;padding:4px 2px 12px}.gp-track-positions>button{display:grid;gap:6px;flex:0 0 115px;text-align:left}.gp-track-positions span{font-size:11px}.gp-track-select button{min-width:0}.gp-track-select .gp-focus-badges{justify-content:center}
.gp-assignment{display:grid;grid-template-columns:minmax(210px,.8fr) minmax(0,1.3fr);align-items:start;gap:18px;margin:16px 0}.gp-assignment .gp-slot{position:sticky;top:0;padding:18px}.gp-assignment .gp-slot>img{width:100%;height:160px;object-fit:contain}.gp-assignment .gp-slot>strong{font-size:23px}.gp-assignment-nav{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-top:14px}.gp-assignment-nav>strong{font-size:13px}
.gp-choice-strip{display:flex;gap:12px;overflow-x:auto;padding:3px 2px 12px;scroll-snap-type:x proximity}.gp-choice-strip>button{flex:0 0 250px;min-width:0;padding:8px!important;scroll-snap-align:start}.gp-choice-strip .rv-driver-tile img{height:100px!important}.gp-choice-strip .gp-car-preview{margin:0}.gp-choice-strip .gp-car-preview>img{height:110px}.gp-review>div{display:grid;grid-template-columns:1.2fr 1fr 1fr 30px;gap:12px;padding:12px 0;border-bottom:1px solid #ffffff18;font-size:13px}
#gp-fixed-summary{display:flex;flex-direction:column;gap:5px;padding:12px 14px;margin-bottom:16px;border:1px solid #f47c9155;border-radius:12px;background:#23304480}#gp-fixed-summary span{font-size:13px}#gp-fixed-summary small{font-size:10px;color:#b4c5db}
@media(max-width:900px){.gp-plan-summary{align-items:stretch;flex-direction:column}.gp-type-choices{grid-template-columns:repeat(2,minmax(0,1fr))}.gp-assignment{grid-template-columns:minmax(180px,.7fr) minmax(0,1fr)}}
@media(max-width:600px){#gp-dialog[open]{width:100%;max-width:100%;height:100dvh;max-height:100dvh;border:0;border-radius:0}#gp-dialog>header{padding:calc(8px + env(safe-area-inset-top)) 12px 8px}#gp-dialog>header h3{font-size:17px}.gp-flow-steps{padding:8px 12px}.gp-flow-body{padding:14px 12px}.gp-flow-footer{padding:10px 12px max(10px,env(safe-area-inset-bottom))}.gp-flow-footer>span{display:none}.gp-flow-footer>button{flex:1}.gp-flow-team-list,.gp-overview-slots,.gp-assignment{grid-template-columns:1fr}.gp-assignment .gp-slot{position:static}.gp-assignment .gp-slot>img{height:85px}.gp-review>div{grid-template-columns:1fr 24px;gap:6px}.gp-review>div>strong{grid-column:1}.gp-review>div>span:last-child{grid-column:2;grid-row:1 / 4}.gp-type-choices button{padding:10px!important}.gp-type-choices img{height:65px}.gp-selects{flex-wrap:wrap}.gp-type-label{font-size:13px;padding:9px}.gp-choice-strip>button{flex-basis:240px}}

/* Track cards summarize the assignment; detailed values live in the used-setup cards. */
.gp-overview-slots .gp-car-preview .gp-bars{display:none}
.gp-overview-slots .gp-car-preview>img{height:70px}
.gp-overview-slots .gp-car-preview>strong{font-size:12px}
.gp-overview-slots .gp-slot>img{height:60px}
.gp-overview-slots .rv-team-body{padding:6px!important}
.gp-overview-slots .rv-driver-tile{padding:5px!important}
.gp-overview-slots .rv-driver-tile img{height:56px!important}
.gp-overview-slots .rv-driver-name{font-size:11px!important}
.gp-overview-slots .rv-driver-rarity{font-size:10px!important}
.gp-overview-slots .rv-team-title{font-size:11px;margin-bottom:5px!important}

body.view-gp:has(#gp-dialog[open]){overflow:hidden}

.gp-is-empty .gp-timeline,.gp-is-empty .gp-grid>aside{opacity:.38;filter:grayscale(1)}
.gp-await-tracks{display:none!important}
/* Scroll pickers inside their column; never let their intrinsic width widen the stage. */
.gp-flow,.gp-flow-body,.gp-flow-steps,.gp-assignment,.gp-assignment>*,.gp-choice-strip{min-width:0;max-width:100%;box-sizing:border-box}
.gp-assignment .gp-slot p{white-space:normal;overflow-wrap:anywhere}

/* Overview: identical zones for planned and completed races. */
#gp-center .gp-overview-slots{align-items:stretch}
#gp-center .gp-overview-slots .gp-slot{display:grid;grid-template-rows:164px 192px 120px 24px;gap:8px;align-content:start;min-width:0;box-sizing:border-box}
.gp-slot-head{display:grid;grid-template-rows:16px 44px 36px 62px;gap:2px;align-items:center;min-width:0;text-align:center}
.gp-slot-head>img{width:100%;height:42px;object-fit:contain}
.gp-slot-head>strong{font-size:14px;line-height:1.3;overflow-wrap:anywhere}
.gp-slot-head>.gp-focus-badges{justify-content:center;align-self:start;margin:0}
.gp-slot-main{display:flex;align-items:stretch;min-width:0}
#gp-center .gp-slot-main .gp-car-preview{display:flex;flex-direction:column;justify-content:center;gap:12px;width:100%;margin:0;box-sizing:border-box}
#gp-center .gp-slot-main .gp-car-preview>img{height:100px}
#gp-center .gp-slot-main .gp-slot-result{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:6px;width:100%;padding:8px;margin:0;box-sizing:border-box;border:1px solid #ffffff20;border-radius:14px;background:linear-gradient(135deg,#42526730,#12192385)}
#gp-center .gp-slot-result>img{width:50px;height:50px;object-fit:contain}
#gp-center .gp-slot-result>small{font-size:12px;line-height:1.35;overflow-wrap:anywhere}
.gp-result-points{display:flex;gap:8px;flex-wrap:wrap;align-items:center;justify-content:center}
#gp-center .gp-result-points>b{font-size:13px}
#gp-center button.gp-points-delta{font-size:11px;line-height:1.3;padding:4px 7px;border-radius:7px;white-space:nowrap;min-height:28px;cursor:pointer}
#gp-center button.gp-points-delta.positive{color:#86e9b8;background:#15583a55;border:1px solid #62c79570}
#gp-center button.gp-points-delta.negative{color:#ffa0aa;background:#681e2b55;border:1px solid #e7778670}
#gp-center button.gp-points-delta.equal{color:#c3cfdd;background:#45516555;border:1px solid #94a5bc60}
#gp-center .gp-slot-team .rv-team-body{height:120px;margin:0;padding:6px!important;box-sizing:border-box}
#gp-center .gp-slot-team .rv-team-pair{height:100%}
#gp-center .gp-slot-team .rv-driver-tile{justify-content:center}
.gp-slot-team>p{font-size:12px;margin:0;padding:18px;border:1px dashed #ffffff25;border-radius:14px}
.gp-slot-note{font-size:11px;line-height:1.4;min-width:0}
.gp-slot-note>p{margin:0}
