/* ═══════════════════════════════════════════════════════════
   Oakham Villa — club theme (loaded after style.css)

   Claret #670E36 is the club colour, Villa sky blue the accent.
   Flat and solid: block colour, plain borders, no glows. Headings
   use Archivo (--font-display); change that one variable to try a
   different heading font.
   ═══════════════════════════════════════════════════════════ */

:root {
    --claret:       #670E36;
    --claret-dark:  #4a0a27;
    --claret-light: #7d1645;
    --villa-sky:    #95BFE5;
    --font-display: 'Archivo', 'Inter', system-ui, sans-serif;

    --bg:          #0c0d10;
    --bg-card:     #14161a;
    --bg-elevated: #1b1e23;
    --bg-hover:    #20232a;
    --border:      #262a31;
    --border-light:#333842;
    --accent:      #a3245c;
    --accent-bright: #b8306c;
    --accent-text: #e88fb5;
    --accent-dim:  rgba(163,36,92,.16);
    --accent-solid: var(--claret);
    --accent-solid-hover: var(--claret-light);
    --sky:         var(--villa-sky);
    --sky-dim:     rgba(149,191,229,.13);
    --glow:        transparent;
    --nav-bg:      var(--claret);
}
:root[data-theme="light"] {
    --bg:          #f4f4f5;
    --bg-card:     #ffffff;
    --bg-elevated: #f0f0f2;
    --bg-hover:    #e9e9ec;
    --border:      #e1e2e6;
    --border-light:#cfd1d7;
    --accent:      var(--claret);
    --accent-bright: var(--claret-light);
    --accent-text: var(--claret);
    --accent-dim:  rgba(103,14,54,.07);
    --sky:         #2a6aa3;
    --sky-dim:     rgba(42,106,163,.09);
    --nav-bg:      var(--claret);
}

/* ── Type ── */
h1, h2, h3, .page-title, .vhero-name, .card-head h2, .ov-card-header h3, .pdetail-name, .section-title,
.ovm-team strong, .ghost-post-title, .vh-article-big-title, .topbar-brand, .site-footer-brand, .pcard-name {
    font-family: var(--font-display);
    letter-spacing: -.01em;
}
.mc-score, .mc-time, .fxc-score, .ovm-digits, .ovm-kickoff, .stat-tile-val, .scorer-val, .pcard-stat b,
.pdetail-stat b, .ovs-card-stats b, .pcard-num {
    font-family: var(--font-display);
    font-variant-numeric: tabular-nums;
}
/* Small labels in capitals; everything else in normal case */
.matchcard-label, .stt th, .pcard-stat span, .stat-tile-label, .ovm-state, .ovm-period {
    text-transform: uppercase; letter-spacing: .08em;
}
.nav-glow { display: none; }

/* ── Navigation: solid claret ── */
.topbar {
    --text: #fff;
    --text-secondary: rgba(255,255,255,.82);
    --text-muted: rgba(255,255,255,.62);
    --bg-elevated: rgba(255,255,255,.1);
    --bg-hover: rgba(255,255,255,.15);
    --border: rgba(255,255,255,.2);
    --border-light: rgba(255,255,255,.32);
    background: var(--claret);
    border-bottom: 3px solid var(--villa-sky);
    -webkit-backdrop-filter: none; backdrop-filter: none;
}
.topbar-brand { font-size: 1.12rem; font-weight: 800; color: #fff; }
.topbar-brand img { width: 32px; height: 32px; }
.topbar-link { font-weight: 600; font-size: .9rem; color: rgba(255,255,255,.8); border-radius: 6px; }
.topbar-link:hover { background: rgba(255,255,255,.1); color: #fff; }
.topbar-link.active { background: rgba(0,0,0,.2); color: #fff; }
.topbar .btn-outline { color: #fff; border-color: rgba(255,255,255,.35); background: transparent; }
.topbar .btn-outline:hover { background: rgba(255,255,255,.12); }
/* The account dropdown keeps the page's own colours */
.topbar .topbar-dd-menu { --text: #eef1f5; --text-secondary: #b7bec9; --text-muted: #8a92a0; --bg-elevated: #1b1e23; --bg-hover: #20232a; --border: #262a31; --border-light: #333842; }
:root[data-theme="light"] .topbar .topbar-dd-menu { --text: #0f1318; --text-secondary: #3d4654; --text-muted: #667085; --bg-elevated: #f0f0f2; --bg-hover: #e9e9ec; --border: #e1e2e6; --border-light: #cfd1d7; }

/* ── Home hero: claret block with faint rink lines ── */
.vhero {
    border: 0; border-radius: 12px; padding: 2.1rem 2rem;
    background:
        linear-gradient(90deg, transparent calc(50% - 1px), rgba(255,255,255,.08) calc(50% - 1px) calc(50% + 1px), transparent calc(50% + 1px)),
        radial-gradient(circle at 50% 50%, transparent 0 70px, rgba(255,255,255,.07) 70px 72px, transparent 72px),
        var(--claret);
}
.vhero::before { display: none; }
.vhero-badge { width: 104px; height: 104px; filter: none; }
.vhero-name { font-size: clamp(2rem, 5vw, 3.1rem); font-weight: 800; letter-spacing: -.02em; line-height: 1; }
.vhero-motto { color: rgba(255,255,255,.8); }
.vhero .chip { background: rgba(0,0,0,.2); border-color: transparent; color: #fff; backdrop-filter: none; }
.vhero .chip-hl { background: var(--villa-sky); color: var(--claret-dark); font-weight: 700; }
.vhero-sponsor { background: rgba(0,0,0,.2); border-color: transparent; backdrop-filter: none; }

/* ── Page banners: plain claret strip ── */
.page-head {
    padding: 1.25rem 1.4rem; border-radius: 12px; color: #fff;
    background: var(--claret);
}
.page-head .page-title { font-size: clamp(1.6rem, 3.5vw, 2.1rem); font-weight: 800; line-height: 1.05; }
.page-head .page-sub { color: rgba(255,255,255,.75); }
.page-head .page-sub a { color: #fff; text-decoration: underline; text-underline-offset: 2px; }
.page-head .page-head-badge { width: 56px; height: 56px; }
.page-head .btn-outline { color: #fff; border-color: rgba(255,255,255,.4); background: transparent; }
.page-head .btn-outline:hover { background: rgba(255,255,255,.12); }

/* ── Cards ── */
.card-head h2 { font-size: 1.12rem; font-weight: 700; }
.card-head .more { font-weight: 600; font-size: .8rem; }

/* ── Buttons ── */
.btn { font-weight: 600; }
.btn-primary { background: var(--claret); border-color: var(--claret); }
.btn-primary:hover { background: var(--claret-light); border-color: var(--claret-light); }

/* ── Match cards ── */
.matchcard::after { display: none; }
.matchcard-label { font-size: .72rem; color: var(--text-muted); font-weight: 700; }
.mc-score, .mc-time {
    display: inline-flex; align-items: center; justify-content: center; gap: .25rem; min-width: 104px;
    padding: .2rem .7rem; border-radius: 8px; font-size: 2.1rem; font-weight: 800; line-height: 1.15;
    background: var(--bg-elevated); color: var(--text);
}
.mc-time { font-size: 1.6rem; }
.mc-score .sep { color: var(--text-muted); }
.mc-team span { font-weight: 700; white-space: normal; text-align: center; line-height: 1.2; }

/* ── Fixture rows ── */
a.fxc:hover { border-color: var(--border-light); }
.fxc-team.is-club .fxc-name { color: var(--accent-text); font-weight: 700; }

/* ── League table ── */
.stt th { font-weight: 700; font-size: .68rem; }
.stt tr.is-club { background: var(--accent-dim); }
.stt tr.is-club td:first-child { box-shadow: inset 3px 0 0 var(--claret); }

/* ── Squad cards ── */
.pgrid { gap: .9rem; }
.pcard { overflow: hidden; padding: 1rem 1rem .85rem; gap: .9rem; border-radius: 12px; }
.pcard::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--claret); }
.pcard:hover { border-color: var(--border-light); transform: none; background: var(--bg-hover); }
.pcard.active { border-color: var(--claret); background: var(--accent-dim); }
.pcard.active::before { background: var(--villa-sky); }
.pcard-top { gap: .85rem; }
.pcard-face { position: relative; flex-shrink: 0; display: block; width: 52px; height: 52px; }
.pcard-face .head-img { width: 52px !important; height: 52px !important; border-radius: 8px; }
.pcard-jersey {
    position: absolute; right: -7px; bottom: -6px; min-width: 24px; height: 20px; padding: 0 5px; border-radius: 5px;
    display: flex; align-items: center; justify-content: center;
    background: var(--claret); color: #fff; border: 2px solid var(--bg-card);
    font: 700 .72rem/1 var(--font-display); font-variant-numeric: tabular-nums;
}
.pcard.active .pcard-jersey { border-color: var(--bg-card); background: var(--villa-sky); color: var(--claret-dark); }
.pcard-name { font-size: 1.02rem; font-weight: 700; }
.pcard-pos { margin-top: .1rem; }
.pcard-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid var(--border); padding-top: .65rem; }
.pcard-stats-4 { grid-template-columns: repeat(4, 1fr); }
.pcard-stat, .pcard.active .pcard-stat, .pcard:hover .pcard-stat { background: none; border-radius: 0; padding: 0; }
.pcard-stat + .pcard-stat { border-left: 1px solid var(--border); }
.pcard-stat b { font-size: 1.15rem; font-weight: 800; }
.pcard-stat span { font-size: .6rem; }
.pcard-num { display: none; }
.villa-cap-badge { background: var(--villa-sky); color: var(--claret-dark); }
.pdetail-name { font-size: 1.75rem; font-weight: 800; }
.pdetail-skin { background: var(--bg-elevated); }

/* ── Home bits ── */
.scorer-val { color: var(--text); }
.vh-article-big-title { font-weight: 800 !important; letter-spacing: -.015em; }

/* ── Match centre ── */
.ovm-board { background: var(--bg-card) !important; }
.ovm-board::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, var(--home) 50%, var(--away) 50%); }
.ovm-digits { font-size: 3.2rem; font-weight: 800; }
.ovm-team strong { font-weight: 800; }
.ovm-period { font-size: .7rem; font-weight: 700; color: var(--text-muted); }

/* ── Footer ── */
.site-footer {
    --text: #fff; --text-secondary: rgba(255,255,255,.8); --text-muted: rgba(255,255,255,.6);
    --bg-elevated: rgba(255,255,255,.1); --bg-hover: rgba(255,255,255,.15); --border: rgba(255,255,255,.2);
    background: var(--claret-dark); border-top: 3px solid var(--villa-sky); color: #fff;
}
.site-footer-brand { font-weight: 800; }

@media (max-width: 560px) {
    .vhero { padding: 1.5rem 1.15rem; }
    .vhero-badge { width: 72px; height: 72px; }
    .page-head { padding: 1rem; }
    .mc-score, .mc-time { min-width: 0; font-size: 1.6rem; padding: .2rem .5rem; }
    .ovm-digits { font-size: 2.3rem; }
}

/* ═══ Match page (pages/villa_match.php), laid out like the CivDB match page ═══ */
.mx { display: flex; flex-direction: column; gap: 1.4rem; }
.mx-board { position: relative; overflow: hidden; padding: 1.3rem 1.4rem 1.2rem; border-radius: 14px; border: 1px solid var(--border); background: var(--bg-card); }
.mx-board::before { content: ""; position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; background: rgba(226,59,59,.25); }
.mx-board::after { content: ""; position: absolute; left: 50%; top: 50%; width: 220px; height: 220px; margin: -110px 0 0 -110px; border-radius: 50%; border: 2px solid var(--border); pointer-events: none; }
.mx-board > * { position: relative; z-index: 1; }
.mx-board-line { display: flex; justify-content: center; flex-wrap: wrap; gap: .4rem; font-size: .72rem; font-weight: 700; letter-spacing: .08em; color: var(--text-muted); margin-bottom: 1rem; }
.mx-board-main { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; }
.mx-side { display: flex; flex-direction: column; align-items: center; gap: .45rem; text-align: center; min-width: 0; }
.mx-side-tag { font-size: .66rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); }
.mx-side strong { font-family: var(--font-display); font-size: 1.4rem; font-weight: 800; line-height: 1.1; }
.mx-side.is-club strong { color: var(--accent-text); }
.mx-record { font-size: .8rem; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.mx-centre { display: flex; flex-direction: column; align-items: center; gap: .55rem; }
.mx-status { padding: .15rem .6rem; border-radius: 6px; border: 1px solid var(--border-light); font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--text-secondary); background: var(--bg-elevated); }
.mx-status.is-live { color: #fff; background: var(--red); border-color: var(--red); }
.mx-led { display: flex; align-items: center; gap: .1rem; padding: .3rem .9rem; border-radius: 10px; background: #0b0b0d; border: 1px solid #2a2d33; font: 800 3rem/1 var(--font-display); color: #f2c14e; font-variant-numeric: tabular-nums; }
.mx-led i { font-style: normal; color: #8a6b20; padding: 0 .15rem; }
.mx-led-time { font-size: 2rem; color: var(--text); }
.mx-periods { border-collapse: collapse; font-size: .8rem; background: var(--bg-elevated); border-radius: 8px; overflow: hidden; }
.mx-periods th { font-size: .62rem; font-weight: 700; color: var(--text-muted); padding: .3rem .55rem; text-align: center; }
.mx-periods td { padding: .3rem .55rem; text-align: center; font-variant-numeric: tabular-nums; border-top: 1px solid var(--border); }
.mx-periods td:first-child { text-align: left; font-weight: 700; }
.mx-periods td:first-child i { width: 7px; height: 7px; border-radius: 2px; display: inline-block; margin-right: .35rem; }
.mx-periods td:last-child, .mx-periods th:last-child { font-weight: 800; color: var(--text); background: rgba(255,255,255,.03); }
.mx-scorers { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; margin-top: .9rem; font-size: .84rem; }
.mx-scorers ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .2rem; }
.mx-scorers ul.home { align-items: flex-end; }
.mx-scorers li { display: flex; align-items: center; gap: .4rem; }
.mx-scorers li i { width: 6px; height: 6px; border-radius: 50%; background: var(--red); }
.mx-scorers small { color: var(--text-muted); }
.mx-board-links { display: flex; justify-content: center; flex-wrap: wrap; gap: .45rem; margin-top: 1rem; }
.mx-stale { margin: .6rem 0 0; text-align: center; font-size: .74rem; color: var(--amber); }

.mx-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 1.4rem; align-items: start; }
.mx-main, .mx-side-col { display: flex; flex-direction: column; gap: 1.4rem; min-width: 0; }
.mx-sec h2 { font-size: 1.05rem; font-weight: 800; margin: 0 0 .6rem; padding-bottom: .45rem; border-bottom: 1px solid var(--border); }
.mx-sec h2 small { font-family: 'Inter', sans-serif; font-size: .74rem; font-weight: 500; color: var(--text-muted); }
.mx-sec .card { margin-bottom: 0; }
.muted { color: var(--text-muted); }
.mx-note { font-size: .74rem; color: var(--text-muted); margin: .6rem 0 0; }

.mx-rink-card { padding: .8rem; }
.mx-rink { width: 100%; height: auto; display: block; }
.rk-ice { fill: var(--bg-elevated); stroke: var(--border-light); stroke-width: 3; }
.rk-red { stroke: rgba(226,59,59,.55); stroke-width: 3; }
.rk-blue { stroke: rgba(80,140,220,.5); stroke-width: 4; }
.rk-circle { fill: none; stroke: var(--border-light); stroke-width: 2; }
.rk-dot { fill: rgba(80,140,220,.6); }
.rk-goal { stroke: rgba(226,59,59,.35); stroke-width: 2; }
.rk-crease { fill: rgba(80,140,220,.12); stroke: rgba(80,140,220,.35); stroke-width: 2; }
.rk-player circle { fill: var(--bg-card); stroke-width: 3; }
.rk-tag { fill: var(--text-muted); font-size: 11px; font-weight: 700; letter-spacing: .08em; }
.rk-name { fill: var(--text); font-size: 13px; font-weight: 600; }
.mx-bench { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: .6rem; font-size: .8rem; color: var(--text-secondary); }
.mx-bench div:last-child { text-align: right; }

.mx-ratings { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.mx-rate h3 { display: flex; align-items: center; gap: .45rem; font-size: .92rem; margin: 0 0 .5rem; }
.mx-rate.is-club h3 { color: var(--accent-text); }
.mx-rate-row { display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: .6rem; padding: .4rem .3rem; border-radius: 8px; color: var(--text); text-decoration: none; }
.mx-rate-row + .mx-rate-row { border-top: 1px solid var(--border); }
.mx-rate-row:hover { background: var(--bg-hover); }
.mx-rate-row img { border-radius: 5px; image-rendering: pixelated; }
.mx-rate-name { font-weight: 600; font-size: .86rem; min-width: 0; }
.mx-rate-name small { display: block; font-weight: 500; font-size: .7rem; color: var(--text-muted); }
.mx-potm { color: #f2c14e; }
.mx-rating { display: inline-block; min-width: 2.6em; text-align: center; padding: .18rem .35rem; border-radius: 6px; font-weight: 800; font-size: .82rem; font-variant-numeric: tabular-nums; background: var(--bg-elevated); border: 1px solid var(--border); }
.mx-rating.good { background: var(--green-dim); color: var(--green-text); border-color: transparent; }
.mx-rating.poor { background: var(--red-dim); color: var(--red-text); border-color: transparent; }

.mx-timeline { padding: .7rem .9rem; }
.mx-tl-period { margin: .7rem 0 .35rem; font-size: .68rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); }
.mx-tl-period:first-child { margin-top: 0; }
.mx-tl-ev { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: center; gap: .55rem; padding: .45rem .5rem; border-radius: 8px; }
.mx-tl-ev.away { background: rgba(255,255,255,.02); }
.mx-tl-ev.is-club { background: var(--accent-dim); }
.mx-tl-icon { text-align: center; font-size: .78rem; }
.k-goal .mx-tl-icon { color: var(--green); }
.k-penalty .mx-tl-icon { color: var(--amber); }
.k-sub .mx-tl-icon { color: var(--sky); }
.mx-tl-body { display: flex; flex-wrap: wrap; align-items: center; gap: .1rem .45rem; font-size: .86rem; min-width: 0; }
.mx-tl-body img { border-radius: 4px; image-rendering: pixelated; }
.mx-tl-body small { flex-basis: 100%; padding-left: 30px; font-size: .72rem; color: var(--text-muted); }
.k-sub .mx-tl-body small { padding-left: 0; }
.mx-tl-body em { font-style: normal; font-size: .72rem; color: var(--red-text); }
.mx-tag { font-size: .62rem; font-weight: 700; padding: .05rem .4rem; border-radius: 999px; background: var(--sky-dim); color: var(--sky); }
.mx-tl-score { font-weight: 800; font-variant-numeric: tabular-nums; }

.mx-bars { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: .85rem 1.6rem; }
.mx-bar { display: grid; grid-template-columns: auto 1fr auto; gap: .2rem .6rem; align-items: center; font-size: .82rem; }
.mx-bar label { text-align: center; font-size: .72rem; color: var(--text-muted); }
.mx-bar span { font-weight: 800; font-variant-numeric: tabular-nums; }
.mx-bar div { grid-column: 1 / -1; display: flex; gap: 3px; height: 6px; }
.mx-bar i { display: block; border-radius: 3px; min-width: 3px; }
.mx-ptable-wrap { overflow-x: auto; margin-top: .8rem; }
.mx-ptable { width: 100%; border-collapse: collapse; font-size: .8rem; white-space: nowrap; }
.mx-ptable th { font-size: .64rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--text-muted); padding: .55rem .6rem; text-align: right; border-bottom: 1px solid var(--border); }
.mx-ptable td { padding: .45rem .6rem; text-align: right; border-bottom: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.mx-ptable th:first-child, .mx-ptable td:first-child { text-align: left; }
.mx-ptable td:first-child img { vertical-align: middle; margin-right: .4rem; border-radius: 4px; }
.mx-ptable tr.is-club td { background: var(--accent-dim); }

.mx-cmp-head { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: .8rem; }
.mx-cmp-team { display: flex; gap: .6rem; align-items: flex-start; }
.mx-cmp-team.away { flex-direction: row-reverse; text-align: right; }
.mx-cmp-team.away .form-strip { justify-content: flex-end; }
.mx-cmp-team b { display: block; }
.mx-cmp-team small { display: block; font-size: .74rem; color: var(--text-muted); margin-bottom: .35rem; }
.mx-cmp-row { display: grid; grid-template-columns: 70px 1fr 70px; align-items: center; padding: .5rem 0; border-top: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.mx-cmp-row label { text-align: center; font-size: .78rem; color: var(--text-secondary); }
.mx-cmp-row label small { display: block; font-size: .64rem; color: var(--text-muted); }
.mx-cmp-row span { font-weight: 700; }
.mx-cmp-row span:last-child { text-align: right; }
.mx-cmp-row span.lead { color: var(--green-text); }

.mx-h2h-top { display: grid; grid-template-columns: 1fr auto 1fr; gap: 1rem; text-align: center; padding-bottom: .9rem; border-bottom: 1px solid var(--border); }
.mx-h2h-top strong { display: block; font: 800 2rem/1 var(--font-display); }
.mx-h2h-top span { font-size: .74rem; color: var(--text-muted); }
.mx-h2h-top .mid small { display: block; font-size: .68rem; color: var(--text-muted); margin-top: .2rem; }
.mx-h2h-list a { display: grid; grid-template-columns: 90px 1fr auto; gap: .6rem; align-items: center; padding: .5rem .2rem; border-bottom: 1px solid var(--border); color: var(--text); text-decoration: none; font-size: .84rem; }
.mx-h2h-list a:last-child { border-bottom: 0; }
.mx-h2h-list a:hover { background: var(--bg-hover); }
.mx-h2h-list span, .mx-h2h-list small { font-size: .72rem; color: var(--text-muted); }

.mx-report { display: block; color: var(--text); text-decoration: none; padding: .3rem 0; }
.mx-report + .mx-report { border-top: 1px solid var(--border); margin-top: .5rem; padding-top: .8rem; }
.mx-report-img { display: block; height: 130px; border-radius: 8px; margin-bottom: .55rem; background: center / cover no-repeat var(--bg-elevated); }
.mx-report b { display: block; line-height: 1.3; }
.mx-report small { display: block; color: var(--text-muted); font-size: .78rem; margin-top: .25rem; }
.mx-potm-card { display: flex; align-items: center; gap: .9rem; color: var(--text); text-decoration: none; }
.mx-potm-card img { width: 70px; height: auto; image-rendering: pixelated; }
.mx-potm-card b { display: block; font-size: 1.05rem; }
.mx-potm-card small { display: block; color: var(--text-muted); font-size: .76rem; margin-bottom: .35rem; }
.mx-list { padding: .4rem .7rem; }
.mx-list a { display: flex; align-items: center; gap: .6rem; padding: .5rem 0; color: var(--text); text-decoration: none; }
.mx-list a + a { border-top: 1px solid var(--border); }
.mx-list img { border-radius: 5px; image-rendering: pixelated; }
.mx-list b { display: block; font-size: .88rem; }
.mx-list small { color: var(--text-muted); font-size: .74rem; }
.mx-info div { display: flex; justify-content: space-between; gap: 1rem; padding: .45rem 0; font-size: .82rem; }
.mx-info div + div { border-top: 1px solid var(--border); }
.mx-info span { color: var(--text-muted); }
.mx-info b { text-align: right; font-weight: 600; }

@media (max-width: 960px) {
    .mx-layout { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
    .mx-board { padding: 1rem .7rem; }
    .mx-board-main { gap: .4rem; }
    .mx-side .crest { width: 52px !important; height: 52px !important; }
    .mx-side strong { font-size: .95rem; }
    .mx-led { font-size: 2.1rem; padding: .25rem .55rem; }
    .mx-ratings, .mx-cmp-head { grid-template-columns: 1fr; }
    .mx-cmp-team.away { flex-direction: row; text-align: left; }
    .mx-cmp-team.away .form-strip { justify-content: flex-start; }
    .mx-h2h-list a { grid-template-columns: 1fr; gap: .1rem; }
    .rk-name { font-size: 16px; }
}

/* ═══ Player stats from CivDB (playerstats.php) ═══ */
.ps { display: flex; flex-direction: column; gap: 1rem; margin-top: 1.25rem; }
.ps .card { margin-bottom: 0; }
.ps-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: .4rem 1rem; padding-bottom: .5rem; border-bottom: 1px solid var(--border); }
.ps-head h2 { margin: 0; font-size: 1.35rem; font-weight: 800; }
.ps-head span { font-size: .78rem; color: var(--text-muted); }
.ps h3 { font-size: .95rem; font-weight: 800; margin: 0 0 .7rem; }
.ps h3 small { font-family: 'Inter', sans-serif; font-weight: 500; font-size: .72rem; color: var(--text-muted); margin-left: .3rem; }
.ps-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .6rem; }
.ps-tile { padding: .75rem .7rem; border-radius: 10px; background: var(--bg-card); border: 1px solid var(--border); text-align: center; }
.ps-tile b { display: block; font: 800 1.55rem/1.1 var(--font-display); font-variant-numeric: tabular-nums; }
.ps-tile span { display: block; margin-top: .2rem; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); }
.ps-tile small { display: block; font-size: .7rem; color: var(--text-muted); margin-top: .1rem; }
.ps-tiles .ps-tile:nth-child(-n+4) { border-top: 3px solid var(--claret); }
.ps-groups { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.ps-group div { display: flex; justify-content: space-between; gap: .8rem; padding: .42rem 0; font-size: .84rem; }
.ps-group div + div { border-top: 1px solid var(--border); }
.ps-group span { color: var(--text-secondary); }
.ps-group b { font-variant-numeric: tabular-nums; }
.ps-two { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 1rem; }
.ps-cols { display: flex; align-items: flex-end; gap: 4px; height: 130px; }
.ps-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; text-decoration: none; min-width: 0; }
.ps-col-bar { flex: 1; width: 100%; max-width: 22px; display: flex; flex-direction: column-reverse; gap: 2px; border-radius: 4px 4px 0 0; }
.ps-col-bar i { display: block; width: 100%; border-radius: 3px; }
.ps-col-bar i.g, .ps-key i.g { background: var(--claret); }
.ps-col-bar i.a, .ps-key i.a { background: var(--villa-sky); }
.ps-col:hover .ps-col-bar { background: var(--bg-hover); }
.ps-col em { font-style: normal; font-size: .6rem; font-weight: 800; width: 100%; max-width: 22px; text-align: center; border-radius: 3px; padding: 1px 0; color: #fff; background: #4b5160; }
.ps-col.r-W em { background: var(--green); }
.ps-col.r-L em { background: var(--red); }
.ps-key { display: flex; flex-wrap: wrap; gap: .3rem 1rem; margin-top: .6rem; font-size: .7rem; color: var(--text-muted); }
.ps-key i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: .3rem; vertical-align: -1px; }
.ps-key i.potm { border-radius: 50%; background: #f2c14e; }
.ps-spark { width: 100%; height: auto; display: block; }
.ps-spark-mid { stroke: var(--border-light); stroke-dasharray: 4 4; }
.ps-spark-line { fill: none; stroke: var(--villa-sky); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.ps-spark-dot { fill: var(--bg-card); stroke: var(--villa-sky); stroke-width: 2; }
.ps-spark-dot.potm { fill: #f2c14e; stroke: #f2c14e; }
.ps-streaks { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; }
.ps-streaks .ps-tile { background: var(--bg-elevated); border: 0; }
.ps-next { margin-bottom: .65rem; }
.ps-next div { display: flex; justify-content: space-between; font-size: .82rem; margin-bottom: .3rem; }
.ps-next b { font-variant-numeric: tabular-nums; color: var(--text-secondary); }
.ps-next i { display: block; height: 6px; border-radius: 3px; background: var(--bg-elevated); overflow: hidden; }
.ps-next s { display: block; height: 100%; background: var(--claret); border-radius: 3px; }
.ps-done { list-style: none; margin: .8rem 0 0; padding: .6rem 0 0; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: .35rem; }
.ps-done li { display: flex; justify-content: space-between; gap: .6rem; font-size: .8rem; }
.ps-done a { color: var(--text); text-decoration: none; font-weight: 600; }
.ps-done small { color: var(--text-muted); }
.ps-table-wrap { overflow-x: auto; }
.ps-table-title { padding: 1rem 1.1rem .2rem; }
.ps-table { width: 100%; border-collapse: collapse; font-size: .82rem; white-space: nowrap; }
.ps-table th { font-size: .64rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); padding: .55rem .7rem; text-align: right; border-bottom: 1px solid var(--border); }
.ps-table td { padding: .5rem .7rem; text-align: right; border-bottom: 1px solid var(--border); font-variant-numeric: tabular-nums; }
.ps-table th:nth-child(-n+2), .ps-table td:nth-child(-n+2) { text-align: left; }
.ps-log th:nth-child(3), .ps-log td:nth-child(3) { text-align: left; }
.ps-table tr:last-child td { border-bottom: 0; }
.ps-table tbody tr:hover td { background: var(--bg-hover); }
.ps-table a { color: var(--text); text-decoration: none; font-weight: 600; }
.ps-team img { width: 18px; height: 18px; object-fit: contain; vertical-align: -4px; margin: 0 .35rem 0 .2rem; }
.ps-res { display: inline-block; width: 1.5em; text-align: center; border-radius: 4px; font-weight: 800; font-size: .7rem; color: #fff; background: #4b5160; }
.ps-res.r-W { background: var(--green); }
.ps-res.r-L { background: var(--red); }
.ps-table td.pos { color: var(--green-text); }
.ps-table td.neg { color: var(--red-text); }
.ps-honours { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .5rem; }
.ps-honours li { padding: .6rem .75rem; border-radius: 8px; background: var(--bg-elevated); border-left: 3px solid #f2c14e; }
.ps-honours b { display: block; font-size: .86rem; }
.ps-honours small { color: var(--text-muted); font-size: .72rem; }
.ps-tracked { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: .5rem; }
.ps-tracked .ps-tile { background: var(--bg-elevated); border: 0; }
@media (max-width: 860px) {
    .ps-groups, .ps-two { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
    .ps-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ps-tile b { font-size: 1.3rem; }
    .ps-streaks { grid-template-columns: 1fr 1fr 1fr; gap: .4rem; }
}
