/* ==========================================================================
   Matchday Preview Redesign — light "match centre" layout
   Loaded after matchday-cobalt.css / matchday-polish.css and overrides them
   for the elements it re-styles. Scoped to #screenMatchday throughout so it
   never touches any other screen.
   ========================================================================== */

#screenMatchday.md2{--md2-bg:#eef2f7;--md2-surface:#ffffff;--md2-surface-2:#f7f9fc;--md2-line:#e0e5eb;--md2-ink:#101826;--md2-ink-2:#4a5568;--md2-muted:#8792a1;--md2-blue:#1348d6;--md2-blue-ink:#0d2f9e;--md2-green:#1f9d55;--md2-green-bg:#e8f7ee;--md2-red:#d23b3b;--md2-red-bg:#fbeaea;--md2-amber:#b8791a;--md2-amber-bg:#fbf1de;color:var(--md2-ink)}

/* ---- utility ---- */
#screenMatchday.md2 .md2-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}

/* ---- top meta (competition line, tucked into the existing light topbar) ---- */
#screenMatchday.md2 .md2-utilities{display:flex!important;align-items:center!important;gap:.85cqw!important}
#screenMatchday.md2 .md2-meta{font:700 .62cqw/1.3 Arial,sans-serif;letter-spacing:.03em;color:var(--md2-ink-2);text-align:right;white-space:nowrap}
#screenMatchday.md2 .md2-date-chip{display:flex!important;flex-direction:column;align-items:flex-end;line-height:1.1}
#screenMatchday.md2 .md2-date-chip span{font:700 .42cqw Arial,sans-serif;letter-spacing:.12em;color:var(--md2-muted)}
#screenMatchday.md2 .md2-date-chip strong{font:800 .68cqw Arial,sans-serif;color:var(--md2-ink)}

/* Matchday header containment.
   The utility cluster includes a dynamic Quick Access button as well as the
   competition, date and three utility controls. The shared 17.5% utility
   track was too small and allowed that cluster to draw over the Office tab. */
#screenMatchday.md2 .matchday-topbar{grid-template-columns:minmax(9cqw,14%) minmax(0,1fr) minmax(34cqw,38%)!important;gap:.6cqw!important;overflow:hidden!important}
#screenMatchday.md2 .career-brand,#screenMatchday.md2 .career-tabs,#screenMatchday.md2 .md2-utilities{min-width:0!important}
#screenMatchday.md2 .md2-utilities{width:100%!important;overflow:hidden!important}
#screenMatchday.md2 .md2-meta{flex:1 1 0;min-width:0;overflow:hidden;text-overflow:ellipsis}
#screenMatchday.md2 .md2-date-chip,#screenMatchday.md2 .md2-utilities>.career-util-btn{flex:0 0 auto}

/* ---- restored reference composition below the shared top bar ---- */
#screenMatchday.md2 .matchday-shell-v2.md2-shell {
  --md2-bg:#f7f5f2;--md2-line:#dedbd6;--md2-ink:#171717;--md2-muted:#737373;--md2-green:#9cc600;--md2-red:#ff6b62;
  position:relative!important;inset:auto!important;flex:1 1 auto!important;
  width:100%!important;max-width:100%!important;height:auto!important;min-height:0!important;
  margin:0!important;padding:0!important;display:grid!important;
  grid-template-columns:minmax(0,1fr) minmax(285px,23.6%)!important;
  grid-template-rows:minmax(430px,calc(100dvh - 280px)) auto auto auto!important;
  grid-template-areas:'hero side' 'teams teams' 'footer footer' 'detail detail'!important;
  gap:0!important;align-content:start!important;overflow:auto!important;scrollbar-width:none;
  background:var(--md2-bg)!important;border:0!important;
}
#screenMatchday.md2 .matchday-shell-v2.md2-shell::-webkit-scrollbar{width:0;height:0}
#screenMatchday.md2 .md2-shell > * {min-width:0!important}
#screenMatchday.md2 .md2-hero {grid-area:hero!important;position:relative!important;inset:auto!important;min-width:0!important;min-height:0!important;width:100%!important;height:100%!important;max-height:none!important;overflow:hidden!important;border:0!important;border-radius:0!important;box-shadow:none!important;background:#f6f4ef!important}
#screenMatchday.md2 .md2-hero-bg {position:absolute;inset:0;background:var(--matchday-arena,url('assets/matchday-presentation/backdrops/velmora-matchday-neutral.png')) center/cover no-repeat;opacity:.23;filter:grayscale(.85)}
#screenMatchday.md2 .md2-hero-streaks {position:absolute;inset:0;background:linear-gradient(180deg,#f8f6f0ba,transparent 40%,#f8f6f066),linear-gradient(104deg,transparent 27%,#a9cb2266 27.08%,transparent 27.2%,transparent 74%,#a9cb2255 74.08%,transparent 74.2%);pointer-events:none}
#screenMatchday.md2 .md2-hero-top {position:absolute;z-index:4;top:5.5%;left:25%;width:50%;display:flex;flex-direction:column;align-items:center;gap:2.1vh;padding:0}
#screenMatchday.md2 .md2-hero-kicker {display:flex;flex-direction:column;gap:5px;align-items:center;width:100%;margin:0;text-align:center;text-wrap:balance}
#screenMatchday.md2 #matchdayHeroCompetition {font:500 clamp(12px,1vw,17px)/1.3 Arial,sans-serif!important;color:#171717!important}
#screenMatchday.md2 #matchdayRoundLabel {font:400 13px Arial,sans-serif!important;color:#444!important}
#screenMatchday.md2 .md2-hero-badges {display:flex;align-items:center;justify-content:center;gap:24px}
#screenMatchday.md2 .matchday-badge.md2-badge {position:relative!important;inset:auto!important;width:clamp(56px,5.2vw,90px)!important;height:clamp(62px,8.8vh,95px)!important;background:none!important;border:0!important;border-radius:0!important;box-shadow:none!important;padding:0!important;overflow:hidden!important}
#screenMatchday.md2 .md2-badge-rule {width:1px;height:70px;background:#aaa}
#screenMatchday.md2 .matchday-badge img {object-fit:contain!important;transform:scale(1.8)!important;filter:none!important}
/* V73.1: 94% was sized as a ceiling for the tallest/narrowest outlier sprites, but
   once every sprite was normalized to reach that same height (the V73 fix above),
   ordinary/wider-built characters ballooned along with it — the box itself needed
   to come down, not just the consistency fix. 58% keeps both sides visually
   consistent (that's the point of the fix) without either side dominating the hero. */
#screenMatchday.md2 .matchday-featured.md2-portrait {position:absolute!important;top:auto!important;bottom:0!important;height:58%!important;max-height:none!important;width:31%!important;max-width:none!important;min-width:0!important;overflow:visible!important;z-index:2!important;pointer-events:none;opacity:1!important}
#screenMatchday.md2 .matchday-featured.md2-portrait.home {left:-3%!important;right:auto!important}
#screenMatchday.md2 .matchday-featured.md2-portrait.away {right:-1%!important;left:auto!important}
#screenMatchday.md2 .md2-portrait .matchday-ghost-crest {display:none!important}
/* V73 fix: standing sprites in assets/quidditch-engine/standing/ are auto-trimmed
   tightly to each character's silhouette, but their source canvases vary wildly in
   pixel size and aspect ratio between characters/species. The old rule stretched the
   <img> to 100%/100% of the box and used object-fit:contain, so whichever axis
   happened to be the "tighter" fit against the box's own shape decided the render
   size — a sprite whose raw aspect ratio was narrower than the box filled the full
   box height (looked huge), while a differently-proportioned sprite was
   width-limited and rendered far shorter (looked tiny), even though neither
   difference had anything to do with the characters' intended relative size.
   Fixing this by anchoring every sprite to the SAME height (100% of the box,
   identical for home and away) and letting width follow the sprite's own aspect
   ratio freely — the parent already declares overflow:visible for exactly this. */
#screenMatchday.md2 .matchday-featured.md2-portrait img {position:absolute!important;left:50%!important;right:auto!important;top:auto!important;bottom:0!important;width:auto!important;height:100%!important;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;object-fit:contain!important;object-position:center bottom!important;transform:translateX(-50%) scale(1.13)!important;transform-origin:center bottom!important;filter:drop-shadow(0 4px 2px #0002)!important;image-rendering:pixelated}
#screenMatchday.md2 .matchday-featured.md2-portrait.home img {transform:translateX(-50%) scale(-1.13,1.13)!important}
#screenMatchday.md2 .md2-portrait[hidden],#screenMatchday.md2 .md2-portrait img[hidden] {display:none!important}
#screenMatchday.md2 .md2-hero-body {position:absolute;z-index:3;left:27%;right:27%;top:32%;bottom:10%;padding:0;margin:0;text-align:center;display:flex;flex-direction:column;justify-content:center}
#screenMatchday.md2 .md2-hero-title {display:flex;flex-direction:column;align-items:center;gap:0;margin:0;line-height:1}
#screenMatchday.md2 .md2-hero-title .matchday-name {position:static!important;display:block!important;width:100%!important;margin:0!important;padding:0!important;color:#111!important;font-family:'Matchday Condensed','Arial Narrow',Arial,sans-serif!important;font-size:clamp(45px,min(7.6vw,13.2vh),145px)!important;font-weight:900!important;line-height:.95!important;letter-spacing:-.025em!important;text-align:center!important;text-transform:uppercase;white-space:nowrap!important;text-shadow:none!important}
#screenMatchday.md2 .md2-hero-title .matchday-name.is-long-name {font-size:clamp(32px,min(5.5vw,9vh),100px)!important}
#screenMatchday.md2 .md2-hero-title .matchday-name-word {display:block!important;width:max-content;min-width:100%;transform:scaleX(var(--md-name-scale,1))!important;transform-origin:left center!important}
#screenMatchday.md2 .md2-hero-x {font:700 30px/1 Arial,sans-serif;color:var(--md2-green);margin:6px 0}
#screenMatchday.md2 #matchdayVenueRibbon {margin-top:26px!important;color:#333!important;font:500 clamp(10px,.8vw,14px)/1.5 Arial,sans-serif!important;letter-spacing:0!important}
#screenMatchday.md2 .md2-hero-standings {display:flex;align-items:center;justify-content:center;gap:12px;margin-top:10px;color:#555;font:400 clamp(10px,.8vw,14px)/1.4 Arial,sans-serif}
#screenMatchday.md2 .md2-hero-standings-rule {width:1px;height:14px;background:var(--md2-red);flex:none}
#screenMatchday.md2 .md2-side {grid-area:side!important;display:flex;flex-direction:column;gap:0!important;min-height:0!important;padding:24px clamp(20px,2.3vw,42px) 16px;background:#faf9f6;border-left:1px solid var(--md2-line)}
#screenMatchday.md2 .md2-card {flex:1 1 0;min-height:0;background:none;border:0;border-radius:0;padding:12px 0 18px;box-shadow:none}
#screenMatchday.md2 .md2-card + .md2-card {border-top:1px solid var(--md2-line);padding-top:22px}
#screenMatchday.md2 .md2-card-label {display:block;font:600 11px/1.3 Arial,sans-serif;letter-spacing:.13em;color:#252525;margin-bottom:18px}
#screenMatchday.md2 .md2-card-row {display:flex;align-items:center;justify-content:space-between;gap:10px}
#screenMatchday.md2 .md2-card-row strong {font:800 clamp(24px,2vw,36px)/1 'Matchday Condensed','Arial Narrow',Arial,sans-serif;color:var(--md2-green)}
#screenMatchday.md2 .md2-status-card .md2-card-row strong {font-size:clamp(32px,2.6vw,44px)}
#screenMatchday.md2 .md2-card p {margin:10px 0 0;max-width:260px;font:400 clamp(12px,.85vw,15px)/1.45 Arial,sans-serif;color:#505050}
#screenMatchday.md2 .md2-intel-card .md2-card-row strong {color:var(--md2-red)}
#screenMatchday.md2 .md2-intel-card.is-scouted .md2-card-row strong {color:var(--md2-green)}
#screenMatchday.md2 .md2-status-card.is-warning .md2-card-row strong,#screenMatchday.md2 .md2-intel-card.is-partial .md2-card-row strong {color:#b78012}
#screenMatchday.md2 .md2-card-icon {display:grid;place-items:center;width:40px;height:40px;flex:none;color:var(--md2-green);font:32px/1 Arial,sans-serif}
#screenMatchday.md2 .md2-icon-check {border:1px solid currentColor;border-radius:50%}
#screenMatchday.md2 .md2-icon-check:after {content:'✓'}
#screenMatchday.md2 .md2-icon-scout {color:var(--md2-red)}
#screenMatchday.md2 .md2-icon-scout:after {content:'◎'}
#screenMatchday.md2 .md2-icon-tactic:after {content:'⤴'}
#screenMatchday.md2 .md2-btn {position:static!important;display:flex!important;align-items:center;justify-content:space-between;gap:16px;flex:none;width:100%!important;min-height:56px!important;height:auto!important;box-sizing:border-box;margin:10px 0 0!important;padding:16px 18px!important;border-radius:5px!important;font:700 clamp(14px,.9vw,17px)/1.2 Arial,sans-serif!important;letter-spacing:.055em!important;cursor:pointer;box-shadow:none!important;transition:background-color .15s,border-color .15s,color .15s}
#screenMatchday.md2 .md2-btn svg,#screenMatchday.md2 .md2-report-icon {width:22px;height:22px;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
#screenMatchday.md2 .md2-btn-primary {background:#252922!important;color:#faf9f6!important;border:1px solid #252922!important;border-left:3px solid var(--md2-green)!important}
#screenMatchday.md2 .md2-btn-primary svg {color:#b8df35}
#screenMatchday.md2 .md2-btn-secondary {background:#f0f1e9!important;color:#292d23!important;border:1px solid #9bA18b!important}
#screenMatchday.md2 .md2-btn-secondary svg {color:#667632}
#screenMatchday.md2 .md2-btn.md2-btn-edit {min-height:46px!important;padding:12px 4px!important;gap:12px;background:transparent!important;color:#56594e!important;border:1px solid transparent!important;border-bottom:1px solid var(--md2-line)!important;border-radius:0!important;font:500 12px/1.4 Arial,sans-serif!important;letter-spacing:0!important;text-align:left;text-transform:none!important;white-space:normal!important}
#screenMatchday.md2 .md2-btn-edit span {flex:1;min-width:0}
#screenMatchday.md2 .md2-btn-edit svg {width:19px;height:19px}
#screenMatchday.md2 .md2-btn-primary:not(:disabled):hover {background:#383f2c!important;border-color:#383f2c!important;border-left-color:#b8df35!important}
#screenMatchday.md2 .md2-btn-secondary:not(:disabled):hover {background:#e7ebd9!important;border-color:#6f7c4d!important}
#screenMatchday.md2 .md2-btn-edit:not(:disabled):hover {background:#eeeee6!important;color:#252922!important;border-bottom-color:#87946a!important}
#screenMatchday.md2 .md2-btn:focus-visible,#screenMatchday.md2 .md2-report > summary:focus-visible {outline:2px solid #657839;outline-offset:3px}
#screenMatchday.md2 .md2-btn:disabled {opacity:.45;cursor:not-allowed}
#screenMatchday.md2 .md2-action-status {display:none!important}
#screenMatchday.md2 .md2-teams {grid-area:teams!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:16px;min-height:0!important;margin:16px 2.1% 0}
#screenMatchday.md2 .matchday-lineup-panel.md2-team-card {position:static!important;inset:auto!important;width:auto!important;min-width:0!important;height:auto!important;min-height:146px!important;max-height:none!important;display:flex!important;flex-direction:column!important;padding:0 14px 10px!important;border:1px solid var(--md2-line)!important;border-top:3px solid var(--md2-green)!important;border-radius:9px!important;box-shadow:none!important;overflow:visible!important;background:#faf9f6!important}
#screenMatchday.md2 .matchday-lineup-panel.away.md2-team-card {border-top-color:var(--md2-red)!important}
#screenMatchday.md2 .md2-team-card:before,#screenMatchday.md2 .matchday-panel-kicker:before {display:none!important}
#screenMatchday.md2 .md2-team-head {display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:42px;border-bottom:1px solid var(--md2-line);padding:4px 0}
#screenMatchday.md2 .md2-team-identity {display:flex;align-items:center;gap:10px;min-width:0}
#screenMatchday.md2 .matchday-badge.md2-team-badge {position:relative!important;inset:auto!important;flex:none;width:30px!important;height:32px!important;overflow:hidden!important;padding:0!important;border:0!important;background:none!important;box-shadow:none!important}
#screenMatchday.md2 .matchday-panel-kicker {position:static!important;display:block!important;min-height:0!important;padding:0!important;border:0!important;background:none!important;font:400 11px/1.4 Arial,sans-serif!important;color:#333!important;letter-spacing:.04em!important}
#screenMatchday.md2 .matchday-panel-kicker strong {font-size:14px;letter-spacing:.03em;text-transform:uppercase}
#screenMatchday.md2 .md2-edit-btn.matchday-edit-team {position:static!important;flex:none;width:auto!important;height:auto!important;min-height:0!important;margin:0!important;padding:4px 0!important;background:none!important;border:0!important;font:500 9px Arial,sans-serif!important;color:#555!important;cursor:pointer;text-decoration:underline}
#screenMatchday.md2 .md2-edit-btn[hidden] {display:none!important}
#screenMatchday.md2 .md2-lineup.matchday-lineup {position:static!important;inset:auto!important;display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;grid-template-rows:auto!important;flex:1!important;width:100%!important;height:auto!important;min-height:0!important;margin:0!important;padding:10px 0 0!important;gap:0!important;overflow:visible!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player {position:relative!important;display:flex!important;align-items:center!important;width:auto!important;height:auto!important;min-height:76px!important;min-width:0!important;padding:0 8px!important;gap:7px!important;border:0!important;border-right:1px solid var(--md2-line)!important;border-radius:0!important;background:none!important;box-shadow:none!important;overflow:visible!important;transform:none!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player:last-child {border-right:0!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player:before,#screenMatchday.md2 .md2-lineup .match-lineup-player:after {display:none!important;content:none!important}
#screenMatchday.md2 .md2-lineup .matchday-lineup-number {position:static!important;display:block!important;align-self:flex-start!important;flex:none;width:18px!important;margin-top:5px;color:#999!important;font:600 17px/1 'Matchday Condensed',Arial,sans-serif!important}
#screenMatchday.md2 .md2-lineup .matchday-lineup-portrait {position:relative!important;align-self:center!important;flex:0 0 42px!important;width:42px!important;height:70px!important;min-height:0!important;margin:0!important;padding:0!important;overflow:visible!important;background:none!important;border:0!important;border-radius:0!important;box-shadow:none!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player img.matchday-lineup-avatar {position:static!important;inset:auto!important;width:100%!important;height:100%!important;object-fit:contain!important;object-position:center bottom!important;background:none!important;transform:none!important;filter:none!important;border:0!important;border-radius:0!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player > div {display:flex!important;flex:1 1 0!important;flex-direction:column!important;align-self:center!important;align-items:flex-start!important;text-align:left!important;gap:5px!important;min-width:0!important;padding:0!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player strong {font:500 clamp(11px,.86vw,15px)/1.2 Arial,sans-serif!important;color:#171717!important;white-space:normal!important;overflow-wrap:anywhere;text-overflow:clip!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player .matchday-player-role {display:block!important;width:auto!important;margin:0!important;padding:0!important;background:none!important;border:0!important;border-radius:0!important;color:#88a900!important;font:500 10px/1.2 Arial,sans-serif!important;letter-spacing:0!important}
#screenMatchday.md2 .away .md2-lineup .match-lineup-player .matchday-player-role {color:var(--md2-red)!important}
#screenMatchday.md2 .md2-lineup .matchday-player-meta {display:flex!important;flex-wrap:wrap!important;justify-content:flex-start!important;gap:3px!important;margin:0!important;padding:0!important;color:#555!important;font:400 10px/1.3 Arial,sans-serif!important}
#screenMatchday.md2 .md2-lineup .matchday-player-meta b {color:inherit!important;font:inherit!important}
#screenMatchday.md2 .md2-lineup .matchday-player-meta span:before {content:'·';width:auto;height:auto;margin:0 4px 0 0;background:none}
#screenMatchday.md2 .md2-lineup .matchday-availability {color:#bd453c;font:600 10px/1.2 Arial,sans-serif}
#screenMatchday.md2 .md2-lineup .is-unavailable {background:#fff0ed!important}
#screenMatchday.md2 .md2-lineup .v48-lineup-traits {display:none!important}
#screenMatchday.md2 .md2-footer {grid-area:footer!important;display:flex;align-items:center;flex-wrap:wrap;gap:24px;min-height:44px;margin:6px 2.1% 0;padding:6px 0;background:none;border:0}
#screenMatchday.md2 .md2-footer-stat {display:flex;align-items:center;gap:12px;font:400 10px/1.4 Arial,sans-serif;color:#777}
#screenMatchday.md2 .md2-footer-stat strong {font:500 11px Arial,sans-serif;color:#333}
#screenMatchday.md2 .md2-footer-stat .is-w {color:#87a500}
#screenMatchday.md2 .md2-footer-stat .is-l {color:#ee655d}
#screenMatchday.md2 .md2-footer-settings {margin-left:auto;border:0;background:none;color:#555;cursor:pointer}
#screenMatchday.md2 .md2-footer-settings small {font:400 12px Arial,sans-serif;margin-left:6px}
#screenMatchday.md2 .md2-report {grid-area:detail;margin:0 2.1% 14px;min-width:0}
#screenMatchday.md2 .md2-report > summary {display:flex;align-items:center;gap:16px;min-height:68px;box-sizing:border-box;cursor:pointer;list-style:none;color:#30352a;padding:14px 18px;background:#f0f1e9;border:1px solid #d4d8c8;border-left:3px solid #91a44f;border-radius:5px;transition:background-color .15s,border-color .15s}
#screenMatchday.md2 .md2-report > summary::-webkit-details-marker {display:none}
#screenMatchday.md2 .md2-report-icon {color:#69784a}
#screenMatchday.md2 .md2-report-copy {display:flex;flex:1;min-width:0;flex-direction:column;gap:5px}
#screenMatchday.md2 .md2-report-copy strong {font:700 12px/1.4 Arial,sans-serif;letter-spacing:.055em}
#screenMatchday.md2 .md2-report-copy small {font:400 12px/1.4 Arial,sans-serif;color:#686d5e;letter-spacing:0}
#screenMatchday.md2 .md2-report-toggle {display:grid;place-items:center;flex:none;width:30px;height:30px;border:1px solid #cbd1bb;border-radius:50%;color:#56653a;background:#fafbf5}
#screenMatchday.md2 .md2-report-toggle::after {content:'';width:7px;height:7px;margin-top:-4px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:rotate(45deg)}
#screenMatchday.md2 .md2-report > summary:hover {background:#e9edde;border-color:#a7b48b}
#screenMatchday.md2 .md2-report[open] > summary {margin-bottom:12px;background:#e9edde}
#screenMatchday.md2 .md2-report[open] .md2-report-toggle::after {transform:rotate(225deg);margin-top:4px}
#screenMatchday.md2 .matchday-summary.md2-detail {position:static!important;inset:auto!important;width:100%!important;min-width:0!important;height:auto!important;min-height:180px!important;overflow:visible!important}
@media (max-width:1200px) {
  #screenMatchday.md2 .md2-hero-body {left:24%;right:24%}
  #screenMatchday.md2 .md2-lineup .matchday-lineup-number {display:none!important}
  #screenMatchday.md2 .md2-lineup .matchday-lineup-portrait {flex-basis:32px!important;width:32px!important}
  #screenMatchday.md2 .matchday-panel-kicker span {font-size:9px}
  #screenMatchday.md2 .md2-edit-btn.matchday-edit-team {max-width:70px!important;text-align:right}
}
@media (max-width:800px) {
  #screenMatchday.md2 .matchday-shell-v2.md2-shell {grid-template-columns:minmax(0,1fr)!important;grid-template-rows:460px auto auto auto auto!important;grid-template-areas:'hero' 'side' 'teams' 'footer' 'detail'!important}
  #screenMatchday.md2 .md2-side {padding:16px 24px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px!important;border-top:1px solid var(--md2-line)}
  #screenMatchday.md2 .md2-card {padding:0!important;border:0!important}
  #screenMatchday.md2 .md2-card-icon {display:none}
  #screenMatchday.md2 .md2-card-label {font-size:9px;margin-bottom:12px}
  #screenMatchday.md2 .md2-card-row strong,#screenMatchday.md2 .md2-status-card .md2-card-row strong {font-size:25px}
  #screenMatchday.md2 .md2-action-status {grid-column:1/-1}
  #screenMatchday.md2 .md2-side > .md2-btn {grid-column:1/-1}
  #screenMatchday.md2 .md2-teams {grid-template-columns:minmax(0,1fr)!important}
  #screenMatchday.md2 .md2-hero-title .matchday-name {font-size:70px!important}
  #screenMatchday.md2 .md2-hero-title .matchday-name.is-long-name {font-size:42px!important}
  #screenMatchday.md2 .md2-lineup .matchday-lineup-number {display:block!important}
  #screenMatchday.md2 .md2-lineup .matchday-lineup-portrait {width:38px!important;flex-basis:38px!important}
  #screenMatchday.md2 .md2-hero-top {top:5%;left:25%;width:50%}
  #screenMatchday.md2 .md2-hero-kicker {margin:0;align-self:center}
  #screenMatchday.md2 .md2-hero-badges {gap:16px}
  #screenMatchday.md2 .md2-badge-rule {height:50px}
  #screenMatchday.md2 .matchday-summary.md2-detail {display:flex!important;flex-direction:column!important;gap:12px!important}
}
@media (max-width:480px) {
  #screenMatchday.md2 .md2-teams {margin-inline:12px}
  #screenMatchday.md2 .md2-lineup.matchday-lineup {grid-template-columns:minmax(0,1fr)!important}
  #screenMatchday.md2 .md2-lineup .match-lineup-player {border-right:0!important;border-bottom:1px solid var(--md2-line)!important}
  #screenMatchday.md2 .md2-side {grid-template-columns:minmax(0,1fr)!important}
  #screenMatchday.md2 .md2-card {padding:8px 0!important}
  #screenMatchday.md2 .md2-hero-title .matchday-name {font-size:54px!important}
}
/* Intrinsic rows must never shrink below the complete team sheets. */
#screenMatchday.md2 .matchday-shell-v2.md2-shell {grid-template-rows:minmax(400px,calc(100dvh - 310px)) max-content max-content max-content!important}
#screenMatchday.md2 .md2-teams {min-height:min-content!important}
#screenMatchday.md2 .md2-hero-body {top:35%;bottom:8%}
#screenMatchday.md2 .md2-card {min-height:min-content;flex:1 0 auto}
#screenMatchday.md2 .md2-card-label {margin-bottom:12px}
#screenMatchday.md2 .md2-card {padding:8px 0 14px}
#screenMatchday.md2 .md2-card + .md2-card {padding-top:16px}
@media (max-height:800px) and (min-width:801px) {
  #screenMatchday.md2 .md2-side {padding-top:12px;padding-bottom:10px}
  #screenMatchday.md2 .md2-card {flex:1 1 auto;padding:7px 0!important;min-height:min-content}
  #screenMatchday.md2 .md2-card-label {font-size:10px;margin-bottom:7px}
  #screenMatchday.md2 .md2-card-row strong,#screenMatchday.md2 .md2-status-card .md2-card-row strong {font-size:27px}
  #screenMatchday.md2 .md2-card p {font-size:11px;line-height:1.3;margin-top:5px}
  #screenMatchday.md2 .md2-card-icon {width:28px;height:28px;font-size:24px}
  #screenMatchday.md2 .md2-btn {height:auto!important;min-height:50px!important;padding:12px 16px!important;font-size:14px!important;margin-top:8px!important}
  #screenMatchday.md2 .md2-action-status {font-size:9px;margin-top:6px}
  #screenMatchday.md2 .md2-hero-top {gap:12px;top:5%}
  #screenMatchday.md2 .md2-hero-title .matchday-name {font-size:clamp(45px,min(7vw,11vh),100px)!important}
  #screenMatchday.md2 #matchdayVenueRibbon {margin-top:16px!important}
}
@media (max-width:800px) {
  #screenMatchday.md2 .matchday-shell-v2.md2-shell {grid-template-rows:460px max-content max-content max-content max-content!important}
}
@font-face {font-family:'Matchday Display';src:url('assets/matchday-cobalt/fonts/Anton-Regular.ttf') format('truetype');font-weight:400;font-style:normal;font-display:swap}
#screenMatchday.md2 .md2-hero-title .matchday-name {font-family:'Matchday Display','Matchday Condensed',sans-serif!important;font-weight:400!important;letter-spacing:0!important}
#screenMatchday.md2 .md2-card-row strong {font-family:'Matchday Display','Matchday Condensed',sans-serif;font-weight:400}
#screenMatchday.md2 .matchday-badge img {transform:scale(2.3)!important}
#screenMatchday.md2 .md2-lineup .match-lineup-player img.matchday-lineup-avatar {object-fit:cover!important;object-position:center bottom!important}
#screenMatchday.md2 .md2-footer-settings {margin-right:230px}
@media (max-width:800px) {#screenMatchday.md2 .md2-footer-settings {margin-right:0}}
#screenMatchday.md2 .matchday-badge img {transform:scale(2.05)!important}
#screenMatchday.md2 .matchday-badge.md2-badge,#screenMatchday.md2 .matchday-badge.md2-team-badge,#screenMatchday.md2 .matchday-badge .fitted-shield,#screenMatchday.md2 .matchday-badge .fitted-shield-media {overflow:visible!important}
#screenMatchday.md2 .matchday-lineup-panel.md2-team-card {grid-area:auto!important;grid-column:auto!important;grid-row:auto!important}

/* Image 1 proportions: preserve the shared header, then let the presentation
   occupy the same visual depth as the reference. Secondary detail remains
   available by scrolling below the flat footer. */
@media (min-width:801px){
  #screenMatchday.md2 .matchday-shell-v2.md2-shell{grid-template-rows:max(560px,min(38.4cqw,calc(100dvh - var(--md-nav-height) - 175px))) max-content max-content max-content!important}
  #screenMatchday.md2 .matchday-lineup-panel.md2-team-card{min-height:132px!important}
  #screenMatchday.md2 .md2-lineup .match-lineup-player{min-height:62px!important}
  #screenMatchday.md2 .md2-lineup .matchday-lineup-portrait{height:60px!important}
}
#screenMatchday.md2 .md2-edit-btn.matchday-edit-team{display:none!important}
