.af-expected{margin:24px auto;width:100%;max-width:950px;background:#16372f;border:1px solid #254c3b;border-radius:10px;overflow:hidden;font-family:Arial,Helvetica,sans-serif;color:#fff}.af-expected header{padding:14px 18px;background:#142e32}.af-expected h2{margin:0 0 10px!important;color:#fff!important;font-size:23px!important;line-height:1.2!important}.af-expected-titles{display:flex;justify-content:space-between;gap:14px;font-size:16px;font-weight:700}.af-expected-titles span{width:48%}.af-expected-titles span:last-child{text-align:right}.af-expected-pitch{position:relative;aspect-ratio:2.2;background:#20533f url('../images/expected-pitch-muted.webp') center/cover no-repeat;isolation:isolate}.af-expected-lines{position:absolute;inset:3%;border:2px solid #f4edda99;z-index:-1}.af-expected-lines i{position:absolute;display:block}.af-expected-half{left:50%;height:100%;border-left:2px solid #f4edda99}.af-expected-circle{width:16%;aspect-ratio:1;left:50%;top:50%;transform:translate(-50%,-50%);border:2px solid #f4edda99;border-radius:50%}.af-expected-box{top:20%;height:60%;width:15%;border:2px solid #f4edda99}.af-expected-box--home{left:-2px}.af-expected-box--away{right:-2px}.af-expected-player{position:absolute;transform:translate(-50%,-50%);width:9%;max-width:95px;margin:0!important;text-align:center}.af-expected-player img{display:block!important;width:clamp(25px,4.7vw,55px)!important;height:clamp(25px,4.7vw,55px)!important;object-fit:cover;object-position:center 20%;border:2px solid #eee4c9;border-radius:50%;margin:0 auto 3px!important}.af-expected-player figcaption{display:block;padding:2px;background:#092c25e8;color:#fff!important;border-radius:3px;font-size:clamp(7px,1.1vw,12px);line-height:1.15;overflow-wrap:anywhere}#af-expected-teams{display:grid;grid-template-columns:1fr 1fr;gap:18px}#af-expected-teams fieldset{border:1px solid #ccd0d4;padding:12px;min-width:0}#af-expected-teams legend{font-weight:700}#af-expected-teams select,#af-expected-teams input[type=text]{width:100%;max-width:100%;margin:4px 0}.af-expected-slot{border-top:1px solid #ddd;padding:8px 0}.af-expected-slot label{font-weight:600}.af-expected-manual{display:none}.af-expected-slot.is-manual .af-expected-manual{display:block}#af-expected-status.is-error{color:#b32d2e}#af-expected-code{max-width:100%;width:250px}@media(max-width:600px){#af-expected-teams{grid-template-columns:1fr}.af-expected header{padding:10px}.af-expected h2{font-size:18px!important}.af-expected-titles{font-size:12px}.af-expected-pitch{aspect-ratio:1.8}.af-expected-player img{border-width:1px}}
/* Scale portraits to the card, not the browser: five-player rows stay readable. */
.af-expected{container-type:inline-size}.af-expected-player img{width:clamp(25px,5.4cqw,60px)!important;height:clamp(25px,5.4cqw,60px)!important}.af-expected-player figcaption{font-size:clamp(7px,1.2cqw,13px)}@media(max-width:600px){.af-expected-pitch{aspect-ratio:1.6}}

/* Keep the same formation; rotate its coordinates, not the portraits or names. */
.af-expected-player{left:var(--af-x);top:var(--af-y)}
@media(max-width:600px){
 .af-expected-pitch{aspect-ratio:3/5}
 .af-expected-player{left:var(--af-mobile-x);top:var(--af-x);width:14%;max-width:70px}
 .af-expected-player img{width:clamp(30px,10cqw,48px)!important;height:clamp(30px,10cqw,48px)!important}
 .af-expected-player figcaption{font-size:clamp(9px,2.6cqw,12px);line-height:1.15}
 .af-expected-half{left:0;top:50%;width:100%;height:0;border-left:0;border-top:2px solid #f4edda99}
 .af-expected-circle{width:32%}
 .af-expected-box{left:20%;right:auto;top:auto;width:60%;height:15%}
 .af-expected-box--home{top:-2px}
 .af-expected-box--away{bottom:-2px}
 .af-expected-titles{font-size:12px;gap:8px}
}

/* Mobile rows grow with the full names, so text never collides with the next row. */
@media(max-width:600px){
 .af-expected-pitch{aspect-ratio:auto;display:grid;grid-template-columns:repeat(20,minmax(0,1fr));grid-template-rows:repeat(10,minmax(110px,auto));padding:16px 4px;box-sizing:border-box;align-items:center}
 .af-expected-player{position:relative;left:auto;top:auto;transform:none;grid-row:var(--af-row);grid-column:var(--af-column) / span var(--af-span);width:auto;max-width:none;min-width:0;align-self:center;padding:8px 2px;box-sizing:border-box}
 .af-expected-player figcaption{font-size:11px;line-height:1.3;white-space:normal;word-break:normal;overflow-wrap:anywhere;overflow:visible;max-height:none;height:auto;min-height:2.6em;box-sizing:content-box;padding:3px 2px}
}

/* Compact mobile lineup: short names and a calm pitch without stretched bricks. */
.af-expected-short-name{display:none}
@media(max-width:600px){
 .af-expected-pitch{grid-template-rows:repeat(10,minmax(64px,auto));padding:10px 4px;background:#294b3b;background-image:linear-gradient(90deg,rgba(255,255,255,.025) 50%,transparent 50%);background-size:20% 100%}
 .af-expected-player{padding:4px 2px}
 .af-expected-player img{width:clamp(28px,9cqw,38px)!important;height:clamp(28px,9cqw,38px)!important;margin-bottom:2px!important}
 .af-expected-player figcaption{font-size:10px;line-height:1.2;min-height:1.2em;padding:2px 1px}
 .af-expected-full-name{display:none}
 .af-expected-short-name{display:inline}
}

/* The lineup uses surnames at every screen size. */
.af-expected-full-name{display:none}.af-expected-short-name{display:inline}

@media(min-width:601px){.af-expected--352 .af-expected-pitch{aspect-ratio:2}}
