.rdp-filters,.rdp-fields,.rdp-level-choice{display:flex;gap:14px;flex-wrap:wrap;margin:16px 0}
.rdp-filters label,.rdp-fields label,.rdp-level-choice label,.rdp-form>label{display:flex;flex-direction:column;gap:6px;flex:1;min-width:min(180px,100%);font-size:13px;color:#c4cedc}
.rdp-filters input,.rdp-filters select,.rdp-dialog input{width:100%;box-sizing:border-box;padding:11px;border:1px solid #ffffff30;border-radius:9px;color:#edf1f7;background:#101923;font-size:16px}
.rdp-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(250px,100%),1fr));gap:18px}
.rdp-card{padding:12px;border-radius:18px;background:linear-gradient(135deg,#24313b,#101721);border:1px solid #ffffff20;min-width:0}
.rdp-card>.rv-driver-tile{display:flex;flex-direction:column;align-items:center;padding:12px;border:1px solid #ffffff35;border-radius:14px;background:#18222d;min-height:262px}
.rdp-card>.rv-driver-tile>img{height:190px;width:100%;object-fit:contain}
.rdp-card .rv-driver-name{font-size:17px;font-weight:700;text-align:center}
.rdp-card .rv-driver-rarity{font-size:12px;line-height:1.4;text-align:center;margin-top:5px}
.rdp-card .rv-driver-signature{font-size:42px;top:30px}
.rdp-card>small{display:block;font-size:11px;line-height:1.5;color:#a8b7ca;min-height:34px}
.rdp-attributes{margin:14px 0;display:grid;gap:8px}
.rdp-attributes>div{display:flex;justify-content:space-between;gap:10px;font-size:13px;color:#bbc8d9}
.rdp-attributes b{color:#f1f5fa;font-variant-numeric:tabular-nums}
.rdp-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}
.rdp-actions button,.rdp-dialog button{padding:9px 11px;border-radius:9px;border:1px solid #ffffff35;background:#273747;color:#f0f4fa;font-size:12px;min-height:40px}
.rdp-dialog{background:#101823;color:#eef3fa;border:1px solid #65758a;border-radius:20px;width:min(620px,calc(100% - 24px));max-height:90dvh;overflow:auto;padding:22px}
.rdp-dialog::backdrop{background:#03080dc9}
.rdp-dialog>header{display:flex;justify-content:space-between;align-items:center;gap:14px}
.rdp-dialog h3{font-size:20px;margin:0}
.rdp-dialog p{font-size:13px;line-height:1.5;color:#aebed2}
.rdp-dialog [role=alert]{color:#ffacb7}
.rdp-level-choice{align-items:flex-end}

.rdp-race-score{padding:12px 15px;border:1px solid #c4ad6555;border-radius:12px;background:#24251b88;color:#f2d88d;font-size:16px;font-weight:700}

/* Inventory cards: override the compact race-avatar image limits explicitly. */
#rv-driver-inventory .rdp-card>.rv-driver-tile{min-height:0!important;height:auto!important;padding:28px 10px 12px;gap:4px;box-sizing:border-box}
#rv-driver-inventory .rdp-card>.rv-driver-tile>img{height:132px!important;max-height:132px!important;width:100%!important;max-width:none!important;object-fit:contain;flex:none}
#rv-driver-inventory .rdp-card .rv-driver-name{line-height:1.3}
.rdp-strengths{display:flex;justify-content:center;flex-wrap:wrap;gap:5px;position:relative;z-index:2;margin-top:8px}
.rdp-strengths>span{font-size:11px;line-height:1.4;padding:4px 7px;border-radius:7px;background:#07111bbd;border:1px solid #ffffff30;color:#e0e9f4}
.rdp-strengths b{color:#fff;margin-left:3px}
.rdp-strength-open{font-size:11px;color:#becbda;margin-top:8px;position:relative;z-index:2}
#rv-driver-inventory .rdp-attributes{margin:12px 0;gap:6px}
#rv-driver-inventory .rdp-card>small{min-height:0;margin-bottom:8px}
/* Stable inventory rows, including unknown values and tied focus attributes. */
#rv-driver-inventory .rdp-card{display:flex;flex-direction:column}
#rv-driver-inventory .rdp-card>.rv-driver-tile{display:grid;grid-template-rows:132px 44px 32px 68px;align-items:center;justify-items:center;gap:0;flex:none;padding:28px 10px 10px}
#rv-driver-inventory .rdp-card>.rv-driver-tile>img{grid-row:1;align-self:end}
#rv-driver-inventory .rdp-card .rv-driver-name{grid-row:2;display:flex;align-items:center;justify-content:center;min-height:0;max-height:44px;overflow:hidden;text-align:center;font-size:16px}
#rv-driver-inventory .rdp-card .rv-driver-rarity{grid-row:3;margin:0;font-size:11px;line-height:1.3;max-height:32px;overflow:hidden}
#rv-driver-inventory .rdp-strengths,#rv-driver-inventory .rdp-strength-open{grid-row:4;align-self:center;margin:0;max-height:68px;overflow:auto;width:100%;box-sizing:border-box;text-align:center}
#rv-driver-inventory .rdp-strengths{align-content:center;gap:4px}
#rv-driver-inventory .rdp-strengths>span{font-size:10px;padding:3px 5px}
#rv-driver-inventory .rdp-card>.rdp-attributes{flex:none}
#rv-driver-inventory .rdp-card>small{min-height:34px;box-sizing:border-box;margin:0 0 8px;line-height:17px;display:flex;align-items:center}
#rv-driver-inventory .rdp-actions{margin-top:auto;min-height:40px;align-content:flex-start}

.st-ts-badge{display:inline-flex;align-items:center;justify-content:center;gap:4px;white-space:nowrap;padding:4px 8px;border:1px solid #c9a16888;border-radius:8px;background:linear-gradient(135deg,#3a3020,#101319);box-shadow:inset 0 1px #fff2;color:#f2d493;font:700 12px/1.3 Arial,sans-serif;vertical-align:middle}
.st-lineup-dialog{width:min(820px,calc(100% - 24px));max-height:90dvh;overflow:auto;box-sizing:border-box;border:1px solid #728093;border-radius:20px;padding:22px;color:#f0f3f8;background:#101722}.st-lineup-dialog::backdrop{background:#03060bce}.st-lineup-dialog header,.st-lineup-dialog footer{display:flex;justify-content:space-between;gap:16px;align-items:center}.st-lineup-dialog header small{color:#c9a168}.st-lineup-dialog h3{margin:7px 0;font-size:23px}.st-lineup-dialog p{font-size:13px;line-height:1.6;color:#b6c4d6}.st-lineup-dialog label{display:grid;gap:8px;font-size:13px;margin:15px 0}.st-lineup-dialog select,.st-lineup-dialog input{box-sizing:border-box;width:100%;min-height:44px;padding:10px;border-radius:9px;border:1px solid #65738a;background:#0a1018;color:#f0f3f8;font-size:16px}.st-lineup-dialog button{padding:10px 14px;min-height:42px;border-radius:9px;background:#313d4e;color:#fff;border:1px solid #5b6a7f;cursor:pointer}.st-lineup-setups{display:grid;gap:8px}.st-lineup-dialog .st-lineup-setup{display:flex;align-items:center;padding:12px;background:#2631416b;border-radius:10px;margin:0}.st-lineup-setup input{width:20px;min-height:20px;flex-shrink:0}.st-lineup-priorities,.st-lineup-result{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.st-lineup-result article{min-width:0}.st-lineup-result .rv-driver-tile{display:flex;align-items:center;flex-direction:column;padding:28px 8px 10px;border-radius:14px;border:1px solid #ffffff30;min-height:205px}.st-lineup-result .rv-driver-tile>img{width:100%;height:125px!important;max-height:125px!important;object-fit:contain}.st-lineup-result .rv-driver-name{font-size:15px;text-align:center}.st-lineup-result .rv-driver-rarity{font-size:11px;text-align:center}.st-lineup-result .st-ts-badge{margin:8px 0}.st-lineup-dialog [role=alert]{color:#ff9aaa}.rv-team-title .st-ts-badge{margin-left:7px}.rg-card-name .st-ts-badge{margin-left:5px}
@media(max-width:420px){.st-lineup-dialog{padding:14px}.st-lineup-priorities{grid-template-columns:1fr}.st-lineup-result .rv-driver-tile>img{height:100px!important;max-height:100px!important}}
