/* Shared geometry and focused refinements for the group test. */
.ms-name-count{display:block;text-align:right;font-size:10px;color:#718095;margin-top:4px}
.rs-league-header h1,.rs-league-name strong{overflow-wrap:anywhere;line-height:1.25}
#app .rs-schedule-row,#app .rs-schedule-row.is-current{height:58px;min-height:58px;border:1px solid #d9e2ed;box-sizing:border-box;outline:none;box-shadow:none}
#app .rs-schedule-row.is-current{border-color:#83a75f;background-image:none}
#app .rs-schedule-head{min-height:32px;box-sizing:border-box;padding:8px 6px;font-size:8px;line-height:1.2;align-items:center}
.ms-competition-filter{display:block;font-size:10px;color:#61748a;margin:0 0 8px}.ms-competition-filter select{font-size:16px;width:100%;height:40px;min-height:40px;margin:4px 0 0}
#app .rs-schedule-scope button{min-height:36px;font-size:10px}
#app .r13-my-week-state[data-outcome=loss]{background:#fde5eb;color:#a82c4b;border-color:#f0c1cd}
#app .r13-my-week-state[data-outcome=draw]{background:#fff0bc;color:#8a6814;border-color:#eedda1}
#app .r13-my-week-state[data-outcome=win]{background:#daf3e8;color:#237a5b;border-color:#b8dece}
#app .r13-my-week-state[data-outcome=pending]{background:#edf1f6;color:#62748b;border-color:#d4dde7}
.ms-fixture-guide>div{grid-template-columns:32px minmax(0,1fr) 28px 65px!important;gap:6px!important;min-height:38px;box-sizing:border-box}
.ms-fixture-guide>div>:last-child{text-align:center;font-weight:900}.ms-fixture-guide .ms-fixture-columns{font-size:9px}.ms-fixture-guide .upcoming{background:#ecf4db;border-left:3px solid #8aaa54;padding-left:7px}.ms-fixture-guide>div>span{white-space:nowrap;font-size:11px;overflow:hidden;text-overflow:ellipsis}
#app.r19-rivals .ms-locked-rivals>div{display:flex;align-items:center;min-height:58px;padding:8px 12px}
#app.r19-rivals .ms-rival-detail{display:flex;align-items:center;gap:8px;justify-content:space-between;min-width:0}
#app.r19-rivals .ms-rival-detail>strong{min-width:0;flex:1}
#app.r19-rivals .ms-rival-fixture{width:86px;min-width:86px;min-height:34px;box-sizing:border-box;display:flex;align-items:center;justify-content:center;text-align:center;font-size:10px;padding:5px}
.r17-heat-scroll{margin-top:10px}#app .an-section-heading:has(.r21-heat-copy){display:block;margin-bottom:10px}#app .an-section-heading .r21-heat-copy{margin:4px 0 0;font-size:9px;line-height:1.4;color:#718095}
#app .rs-match-overlay{align-items:flex-start!important;padding-top:var(--match-top,64px)!important;box-sizing:border-box}
#app .rs-match-overlay .ms-dialog{margin-top:0!important;max-height:calc(100dvh - var(--match-top,64px) - 12px)!important;animation:ms-dialog-in .16s ease-out}
@keyframes ms-dialog-in{from{opacity:0}to{opacity:1}}
.ms-v28-dialog-actions{display:grid;gap:8px;margin-top:16px}.ms-v28-dialog-actions button{width:100%;min-height:40px}.ms-guidance-dialog .ms-welcome-label{display:none}.ms-replay-tour{margin:8px 16px 0;min-height:36px;flex:none}
.wr-legend-head,.wr-weekly-legend>div{display:grid!important;grid-template-columns:minmax(0,1fr) 65px 50px!important;gap:5px;align-items:center}
.wr-legend-head{font-size:9px;color:#bfcee2}.wr-legend-head b,.wr-weekly-legend b{text-align:center}.wr-weekly-legend{grid-template-columns:1fr!important}.wr-weekly-legend>div{font-size:10px}
.wr-hist-label{display:flex;justify-content:space-between;align-items:center;font-size:9px;color:#bfcee2}.wr-hist-axis{text-align:center;font-size:9px;font-weight:800;color:#bfcee2;margin-top:-5px}
.wr-your-opponents{display:flex;justify-content:space-between;align-items:center;padding:10px;border-radius:9px;background:#c8f060;color:#172338;font-size:12px;width:100%;box-sizing:border-box}
.wr-slide[data-page=cup] .wr-slide-body{justify-content:flex-start}.wr-slide[data-page=luck] .wr-luck-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.wr-slide[data-page=luck] .wr-chip-card{min-height:65px;box-sizing:border-box}
.wr-slide[data-page=rival-verdict] .wr-review-row{border-left:3px solid #c8f060;background:linear-gradient(100deg,#ffffff12,#ffffff04)}
.ms-tour-overlay{position:fixed;inset:0;z-index:20000;isolation:isolate;overflow:hidden}.ms-tour-highlight{position:absolute;border:2px solid #c8f060;border-radius:12px;box-shadow:0 0 0 200vmax #0a142bbb;box-sizing:border-box;pointer-events:none}.ms-tour-card{position:absolute;bottom:max(16px,env(safe-area-inset-bottom));left:16px;right:16px;max-width:430px;margin:auto;background:#fff;border:1px solid #c5d2e2;border-radius:15px;padding:16px;color:#172338;box-shadow:0 10px 45px #0003}.ms-tour-card.at-top{top:16px;bottom:auto}.ms-tour-card small{font-size:10px;color:#738298}.ms-tour-card h2{font-size:18px;margin:5px 0 10px}.ms-tour-card p{font-size:13px;line-height:1.5;margin:0 0 14px}.ms-tour-card>div{display:grid;grid-template-columns:1fr 1fr;gap:8px}.ms-tour-card button{min-height:36px;font-family:inherit}.ms-tour-skip{display:block;margin:8px auto 0;border:1px solid #d3dce7;background:#f2f5f9;border-radius:8px;padding:6px 16px;color:#52637a}
@media(max-height:650px){.wr-slide[data-page=luck] .wr-chip-card{min-height:0;padding:4px;gap:3px}.wr-slide[data-page=luck] .wr-chip-card>small{font-size:5px}.wr-slide[data-page=luck] .wr-chip-card>strong{font-size:8px}.wr-slide[data-page=luck] .wr-chip-card>div{font-size:6px}.wr-slide[data-page=luck] .wr-luck-grid{gap:4px}.wr-legend-head{font-size:7px}.wr-weekly-legend>div{font-size:8px}.wr-hist-label,.wr-hist-axis{font-size:7px}.wr-your-opponents{padding:6px;font-size:9px}.ms-tour-card{padding:12px}.ms-tour-card p{font-size:12px}.wr-slide[data-page=week] .wr-histogram{height:40px}}
@media(prefers-reduced-motion:reduce){#app .rs-match-overlay .ms-dialog{animation:none}}
.ms-guidance-dialog.v25-dialog.ms-dialog{position:relative;display:flex;flex-direction:column;align-items:stretch;gap:12px;width:min(400px,calc(100% - 32px));height:auto;max-height:85dvh;box-sizing:border-box;overflow:auto;padding:20px;border-radius:14px;background:white;color:#14243e;text-align:left}
.ms-guidance-dialog.ms-dialog>h2{position:static;margin:0;padding-right:36px;font-size:18px;line-height:1.3}
.ms-guidance-dialog.ms-dialog>p{position:static;margin:0;font:inherit;font-size:13px;line-height:1.5;color:#52647b}
.ms-guidance-dialog .ms-v28-dialog-actions{position:static;margin:0;display:grid;gap:8px}
.ms-guidance-dialog button:not(.ms-modal-close){position:static;display:block;box-sizing:border-box;margin:0;width:100%;min-height:40px}
.ms-dialog .ms-modal-close:not(.r20-pin-close),.ms-tour-card>.ms-tour-x{box-sizing:border-box;display:grid;place-items:center;width:32px;height:32px;min-width:32px;min-height:32px;padding:0;border:1px solid #c7d4e3;border-radius:8px;background:#edf2f8;color:#405a78}
.ms-tour-card>.ms-tour-x{position:absolute;top:10px;right:10px}
.ms-tour-highlight{border-width:3px}
.ms-guidance-dialog:not(:has(.ms-modal-close))>h2{padding-right:0}
#app .r19-match-overlay .rs-match-heading>.r19-match-close{width:32px;min-width:32px;padding:0}
#app .rs-match-overlay>.ms-dialog{align-self:flex-start!important}
.r18-pin-overlay .ms-dialog.ms-pin-with-x{padding-top:52px}
#app.r19-rivals .ms-replay-tour{flex:none;margin:8px 16px 0}
#app .ms-competition-filter{display:block;flex:none;align-self:stretch;min-width:0;margin:0 16px 8px}
#app .ms-competition-filter>select{display:block;box-sizing:border-box;max-width:100%;min-width:0;width:100%;margin:0;height:44px;border:1px solid #cfd9e5;border-radius:10px;background-color:white;color:#14243e;padding:0 32px 0 12px;font-family:inherit;font-size:16px;font-weight:700;text-overflow:ellipsis}
.ms-saving{position:fixed;bottom:80px;left:50%;transform:translateX(-50%);z-index:21000;display:flex;align-items:center;gap:8px;padding:10px 16px;border-radius:10px;background:#14243e;color:white;font:600 13px system-ui}
.ms-saving::before{content:'';width:14px;height:14px;border:2px solid #ffffff55;border-top-color:white;border-radius:50%;animation:ms-saving-spin 1s linear infinite}
@keyframes ms-saving-spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.ms-saving::before{animation:none}}

#app .rs-match-overlay.restored-match,#app .rs-match-overlay.restored-match *{animation:none!important;transition:none!important}
#app .r13-my-week:has([data-outcome=loss]){border-color:#db3157!important}
#app .r13-my-week:has([data-outcome=draw]){border-color:#d59b22!important}
#app .r13-my-week:has([data-outcome=win]){border-color:#16a06f!important}
body .ms-modal-close:focus,body .badge-popup-close:focus,#app .r19-match-close:focus,.ms-tour-x:focus{border-color:#c7d4e3!important;box-shadow:none!important;outline:none!important}
body .ms-modal-close:focus-visible,body .badge-popup-close:focus-visible,#app .r19-match-close:focus-visible{outline:2px solid #52647b!important;outline-offset:2px}
.ms-saving{width:max-content;max-width:calc(100vw - 24px);white-space:nowrap;font-size:11px;padding:6px 10px;gap:6px;border-radius:8px}
.ms-saving::before{width:10px;height:10px}
#app .ms-competition-filter .r22-gameweek-picker,#app .ms-competition-filter .r22-gameweek-trigger{width:100%;min-width:0;box-sizing:border-box}
#app .ms-competition-filter .r22-gameweek-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#app .ms-competition-filter select[hidden]{display:none!important}
#app.ms-onboarding .ms-pin-form,.r18-pin-overlay .ms-pin-form{display:grid;gap:10px}
#app.ms-onboarding .ms-pin-form label,.r18-pin-overlay .ms-pin-form label{display:grid;gap:5px;margin:0;color:#61758d;line-height:1.4;font-family:inherit;font-size:11px;font-weight:750}
#app.ms-onboarding .ms-pin-form input,.r18-pin-overlay .ms-pin-form input{box-sizing:border-box;width:100%;min-width:0;height:44px;border:1px solid #ccd9e7;border-radius:8px;padding:8px 10px;font-size:16px}
#app.ms-onboarding .ms-pin-form button,.r18-pin-overlay .ms-pin-form button{width:100%;min-height:44px;border-radius:9px;font-size:12px;font-weight:850}

#app .rs-schedule-scroll{padding-top:9px;box-sizing:border-box}

.ms-club-fixtures-overlay .ms-fixture-guide > .ms-fixture-columns > b{font-family:inherit;font-size:inherit;font-weight:800;line-height:inherit;letter-spacing:inherit}
/* Popup buttons share a neutral keyboard focus cue. Pointer focus keeps the normal button edge. */
:is([role="dialog"],.v25-dialog,.badge-popup-card) button:focus{outline:none!important;box-shadow:none!important}
:is([role="dialog"],.v25-dialog,.badge-popup-card) button:focus-visible{outline:2px solid #52647b!important;outline-offset:2px}
