/* File: assets/css/style.css
   Poppins everywhere. Light mode only. Flat, thin borders, no shadows. Compact. */

:root {
    --green: #16A34A;
    --green-dark: #15803D;
    --green-soft: #ECFDF3;
    --ink: #0F172A;
    --ink-soft: #64748B;
    --line: #E2E8F0;
    --line-strong: #CBD5E1;
    --bg: #F8FAFC;
    --white: #FFFFFF;
    --won: #16A34A;
    --lost: #DC2626;
    --pending: #64748B;
    --radius: 10px;
    --radius-sm: 8px;
    --ring: inset 0 0 0 1px var(--green);
    color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body, button, input, select, textarea { font-family: 'Poppins', sans-serif; }
body { margin: 0; background: var(--bg); color: var(--ink); font-size: 14px; line-height: 1.55; }

img { max-width: 100%; height: auto; }
a { color: var(--green-dark); text-underline-offset: 2px; }
a:hover { color: var(--green); }
h1, h2, h3, h4 { line-height: 1.3; margin: 0 0 .4em; letter-spacing: -.01em; }
h1 { font-size: 1.4rem; font-weight: 700; }
h2 { font-size: 1.1rem; font-weight: 600; }
h3 { font-size: 1rem; font-weight: 600; }
p { margin: 0 0 .8em; }
small { font-size: .8em; }

.container { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 14px; }
.skip-link { position: absolute; left: -9999px; top: 0; background: var(--ink); color: #fff; padding: 8px 14px; z-index: 1000; }
.skip-link:focus { left: 8px; top: 8px; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

/* ---- Header ---- */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; padding-top: env(safe-area-inset-top); }
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 52px; gap: 10px; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 30px; height: 30px; border-radius: 8px; background: var(--green); color: #fff; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; font-size: .9rem; }
.brand-name { font-weight: 700; font-size: 1rem; }
.main-nav { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.main-nav::-webkit-scrollbar { display: none; }
.main-nav a { text-decoration: none; color: var(--ink-soft); font-weight: 500; padding: 6px 11px; border-radius: 999px; white-space: nowrap; font-size: .85rem; }
.main-nav a:hover { background: var(--bg); color: var(--ink); }
.main-nav a[aria-current="page"], .main-nav a.active { background: var(--green-soft); color: var(--green-dark); font-weight: 600; }

.site-main { padding: 16px 0 32px; min-height: 60vh; }
.page-wrap { padding: 0; }
.page-header, .page-head { margin-bottom: 12px; }
.page-title { font-size: 1.4rem; font-weight: 700; margin: 0 0 4px; }
.page-sub { color: var(--ink-soft); margin: 0 0 12px; font-size: .88rem; }

/* ---- Components ---- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    background: var(--green); color: #fff; border: 1px solid var(--green); border-radius: var(--radius-sm);
    padding: 8px 14px; font-weight: 600; font-size: .85rem; line-height: 1.2; cursor: pointer; text-decoration: none;
}
.btn:hover { background: var(--green-dark); border-color: var(--green-dark); color: #fff; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-ghost, .btn-outline { background: var(--white); color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover, .btn-outline:hover { background: var(--bg); color: var(--ink); border-color: var(--ink-soft); }
.btn-primary { background: var(--green); }
.btn-danger { background: var(--white); color: var(--lost); border-color: var(--lost); }
.btn-danger:hover { background: var(--lost); border-color: var(--lost); color: #fff; }
.btn-sm, .btn-xs { padding: 5px 10px; font-size: .76rem; border-radius: 7px; }
.btn-line, .btn-row, .modal-btns { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.badge { display: inline-block; padding: 1px 9px; border-radius: 999px; font-size: .72rem; font-weight: 600; background: var(--bg); color: var(--ink-soft); border: 1px solid var(--line); }
.badge-won { background: #F0FDF4; color: var(--won); border-color: #BBF7D0; }
.badge-lost { background: #FEF2F2; color: var(--lost); border-color: #FECACA; }
.badge-pending { background: var(--bg); color: var(--pending); }
.badge-void { background: #FFFBEB; color: #B45309; border-color: #FDE68A; }

.breadcrumbs { font-size: .78rem; color: var(--ink-soft); margin-bottom: 10px; }
.breadcrumbs a { color: var(--ink-soft); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }
.breadcrumbs span[aria-hidden] { margin: 0 5px; }
.empty-state { text-align: center; padding: 24px 14px; color: var(--ink-soft); }
.empty-state p { margin: 0; }
.lead { color: var(--ink-soft); margin: -2px 0 12px; font-size: .9rem; }
.small-note { color: var(--ink-soft); font-size: .76rem; margin: 10px 0 0; }

/* ---- Footer ---- */
.site-footer { background: var(--white); border-top: 1px solid var(--line); padding: 20px 0 calc(18px + env(safe-area-inset-bottom)); font-size: .84rem; color: var(--ink-soft); }
.footer-top { display: flex; flex-direction: column; gap: 12px; margin-bottom: 14px; }
.footer-about p { margin: 2px 0 0; }
.footer-links { display: flex; gap: 14px; flex-wrap: wrap; }
.footer-links a { color: var(--ink-soft); text-decoration: none; font-weight: 500; }
.footer-links a:hover { color: var(--green-dark); }
.footer-partners { display: flex; flex-wrap: wrap; gap: 18px; padding: 12px 0; border-top: 1px solid var(--line); }
.footer-heading { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); margin-bottom: 6px; }
.footer-partner-group ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 14px; }
.footer-partner-group a { color: var(--ink-soft); }
.footer-note { font-size: .76rem; border-top: 1px solid var(--line); padding-top: 10px; margin: 6px 0; }
.footer-copy { font-size: .76rem; margin: 0; }

/* ---- Home / match cards ---- */
.date-nav { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin: 0 0 14px; }
.league-block { margin-bottom: 18px; }
.league-title { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; padding-bottom: 6px; border-bottom: 1px solid var(--line-strong); margin-bottom: 10px; font-size: 1rem; }
.league-country { font-size: .76rem; font-weight: 500; color: var(--ink-soft); }
.match-grid { display: grid; grid-template-columns: 1fr; gap: 8px; }
.match-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.match-card:hover { border-color: var(--line-strong); }
.match-top { display: flex; justify-content: space-between; align-items: center; }
.match-time { font-weight: 600; font-size: .8rem; color: var(--ink-soft); }
.match-score { font-weight: 700; font-size: .85rem; background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 0 8px; }
.match-teams { font-size: .95rem; margin: 0; font-weight: 600; }
.match-teams a { color: var(--ink); text-decoration: none; }
.match-teams a:hover { color: var(--green-dark); }
.match-teams .vs { color: var(--ink-soft); font-weight: 500; font-size: .8em; margin: 0 2px; }
.pick-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.pick-main { background: var(--green-soft); border: 1px solid #BBF7D0; border-radius: var(--radius-sm); padding: 8px 10px; }
.pick-info { display: flex; flex-direction: column; min-width: 0; }
.pick-cat { font-size: .66rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-soft); font-weight: 600; }
.pick-text { font-size: .88rem; font-weight: 500; overflow-wrap: anywhere; }
.pick-meta { font-size: .74rem; color: var(--ink-soft); }
.odds-row { display: flex; gap: 6px; flex-wrap: wrap; }
.odds-chip, .odd-chip { background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 0 8px; font-size: .76rem; }
.odds-chip b { color: var(--green-dark); }
.market-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.market-list .pick-row { border-top: 1px solid var(--line); padding-top: 6px; }
.match-more { font-size: .78rem; font-weight: 600; text-decoration: none; margin-top: auto; }
.match-more:hover { text-decoration: underline; }
@media (min-width: 700px)  { .match-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .match-grid { grid-template-columns: repeat(3, 1fr); } }

/* ---- Match cards: desktop row layout. Replaces the earlier match-row-add snippet.
   Append at the very END of assets/css/style.css (and delete the previous "Horizontal match cards" block). ---- */

/* Quieter status + labels inside cards (all sizes) */
.match-card .pick-cat { text-transform: none; letter-spacing: 0; font-size: .72rem; font-weight: 500; }
.match-card .badge { font-size: .68rem; padding: 0 8px; }
.match-card .badge-pending { background: transparent; border-color: transparent; padding: 0; color: #94A3B8; font-weight: 500; }
.match-card .match-time { color: var(--ink); font-weight: 700; font-size: .95rem; font-variant-numeric: tabular-nums; }
.match-card .odds-chip { background: var(--white); font-variant-numeric: tabular-nums; }

@media (min-width: 900px) {
    .match-grid { grid-template-columns: 1fr; gap: 8px; }
    .match-grid .match-card {
        display: grid;
        grid-template-columns: 48px minmax(150px, .9fr) minmax(200px, .9fr) minmax(360px, 1.6fr);
        grid-template-areas:
            "time teams main  markets"
            "time teams odds  markets"
            "more more  more  more";
        column-gap: 20px; row-gap: 8px;
        align-items: center; align-content: start;
        padding: 14px 16px 0;
    }
    .match-grid .match-card:hover { border-color: var(--line-strong); }

    .match-card .match-top   { grid-area: time; flex-direction: column; align-items: flex-start; gap: 6px; align-self: center; }
    .match-card .match-teams { grid-area: teams; font-size: .95rem; line-height: 1.35; align-self: center; }
    .match-card .match-teams a { display: block; }
    .match-card .match-teams .vs { display: block; font-size: .72rem; font-weight: 500; margin: 1px 0; }
    .match-card .pick-main   { grid-area: main; align-self: end; }
    .match-card .odds-row    { grid-area: odds; align-self: start; flex-wrap: nowrap; white-space: nowrap; }

    /* extra markets: quiet list in its own column, divided from the main pick by a thin rule */
    .match-card .market-list { grid-area: markets; align-self: stretch; gap: 0; padding-left: 20px; border-left: 1px solid var(--line); justify-content: center; }
    .match-card .market-list > li { padding: 6px 0; border-top: 1px solid var(--line); }
    .match-card .market-list > li:first-child { border-top: 0; padding-top: 0; }
    .match-card .market-list > li:last-child { padding-bottom: 0; }
    .match-card .market-list .pick-row { border-top: 0; padding-top: 0; align-items: center; }
    .match-card .market-list .pick-info { flex: 1; display: grid; grid-template-columns: 1fr auto; column-gap: 12px; align-items: baseline; }
    .match-card .market-list .pick-cat  { grid-column: 1; }
    .match-card .market-list .pick-text { grid-column: 1; font-size: .86rem; font-weight: 500; }
    .match-card .market-list .pick-meta { grid-column: 2; grid-row: 1 / span 2; align-self: center; text-align: right; font-size: .72rem; font-variant-numeric: tabular-nums; }

    /* footer strip */
    .match-card .match-more {
        grid-area: more; margin: 6px -16px 0; padding: 8px 16px; border-top: 1px solid var(--line);
        background: var(--bg); border-radius: 0 0 var(--radius) var(--radius); font-size: .76rem;
    }
}

/* ---- Keyword pages / prose ---- */
.keyword-matches { margin-bottom: 16px; }
.prose { padding: 16px; margin-bottom: 16px; overflow-wrap: anywhere; }
.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }
.prose h2 { margin-top: 1.4em; padding-bottom: .25em; border-bottom: 1px solid var(--line); }
.prose h3 { margin-top: 1.2em; }
.prose p, .prose li { line-height: 1.7; }
.prose p, .prose-inline p { margin: 0 0 .9em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose a, .prose-inline a { color: var(--green-dark); text-decoration: underline; }
.prose blockquote { margin: 1em 0; padding: 2px 14px; border-left: 3px solid var(--green); color: var(--ink-soft); }
.prose .table-scroll, .prose-inline .table-scroll { overflow-x: auto; margin: 1em 0; border: 1px solid var(--line); border-radius: var(--radius-sm); -webkit-overflow-scrolling: touch; }
.prose table, .prose-inline table { display: table; width: 100%; min-width: 440px; border-collapse: collapse; font-size: .88rem; }
.prose th, .prose td, .prose-inline th, .prose-inline td { border: 0; border-bottom: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.prose th, .prose-inline th { background: var(--bg); color: var(--ink); font-weight: 600; }
.prose tr:last-child td, .prose tr:last-child th, .prose-inline tr:last-child td, .prose-inline tr:last-child th { border-bottom: 0; }
.prose caption, .prose-inline caption { caption-side: top; text-align: left; font-weight: 600; padding: 8px 10px; }
.prose-inline p:last-child { margin-bottom: 0; }
.related-guides ul, .related-list { list-style: none; margin: 8px 0 14px; padding: 0; display: grid; gap: 6px; }
.related-guides a, .related-list a { display: flex; flex-direction: column; gap: 2px; padding: 9px 12px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); text-decoration: none; font-weight: 500; color: var(--ink); }
.related-guides a:hover, .related-list a:hover { border-color: var(--green); color: var(--green-dark); }
.related-list span { font-size: .76rem; color: var(--ink-soft); font-weight: 400; }
@media (min-width: 700px) {
    .related-guides ul, .related-list { grid-template-columns: repeat(2, 1fr); }
    .prose { padding: 22px; }
}

/* ---- Match page ---- */
.mp-head { margin-bottom: 12px; }
.mp-league { margin: 0 0 2px; font-size: .74rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--green-dark); }
.mp-head h1 { margin-bottom: 4px; }
.mp-score { display: inline-block; margin: 4px 0 0; font-size: 1.5rem; font-weight: 700; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 2px 14px; }
.mp-section { margin-bottom: 12px; }
.mp-section h3 { margin-top: 14px; font-size: .9rem; }
.facts { margin: 10px 0 0; display: grid; grid-template-columns: 1fr; gap: 0; }
.facts > div { display: flex; justify-content: space-between; gap: 14px; padding: 7px 0; border-top: 1px solid var(--line); }
.facts dt { color: var(--ink-soft); font-size: .8rem; }
.facts dd { margin: 0; font-weight: 600; text-align: right; overflow-wrap: anywhere; font-size: .86rem; }
.mp-explain { color: var(--ink-soft); font-size: .84rem; margin: 8px 0 0; }
.explainers { margin: 6px 0 0; padding-left: 18px; font-size: .84rem; color: var(--ink-soft); }
.explainers li { margin-bottom: 3px; }
@media (min-width: 700px) { .facts { grid-template-columns: 1fr 1fr; column-gap: 28px; } }

/* ---- Partners page ---- */
.partners-grid { display: grid; grid-template-columns: 1fr; gap: 8px; margin-bottom: 16px; }
.partner-card { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 11px 14px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); }
.partner-card:hover { border-color: var(--green); color: var(--ink); }
.partner-anchor { font-weight: 600; font-size: .88rem; line-height: 1.4; overflow-wrap: anywhere; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.partner-arrow { color: var(--green); flex-shrink: 0; }
.partners-note h2 { font-size: .95rem; }
.partners-note p { margin: 0 0 6px; color: var(--ink-soft); font-size: .84rem; }
.partners-note p:last-child { margin-bottom: 0; }
@media (min-width: 600px) { .partners-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .partners-grid { grid-template-columns: repeat(3, 1fr); } }

/* ---- VIP ---- */
.vip-section { margin: 16px 0; }
.stat-grid, .stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; margin: 10px 0; }
.stat { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px; text-align: center; }
.stat b { display: block; font-size: 1.3rem; font-weight: 700; line-height: 1.2; }
.stat span { font-size: .74rem; color: var(--ink-soft); }
.teaser-list { list-style: none; margin: 8px 0; padding: 0; }
.teaser-list li { padding: 7px 0; border-bottom: 1px solid var(--line); font-size: .88rem; }
.teaser-list li:last-child { border-bottom: 0; }
.teaser-list li span { color: var(--ink-soft); margin-right: 6px; }
.teaser-list li em { color: var(--ink-soft); font-style: normal; font-size: .8rem; }
.day-h { margin: 14px 0 6px; font-size: .92rem; }

/* ---- Forms (public + admin) ---- */
label { display: block; font-weight: 600; font-size: .8rem; margin: 0 0 4px; color: var(--ink); }
input[type=text], input[type=url], input[type=email], input[type=password], input[type=number],
input[type=search], input[type=date], input[type=time], input[type=tel], input:not([type]),
select, textarea {
    display: block; width: 100%; padding: 8px 10px; font-size: .88rem; line-height: 1.4; color: var(--ink);
    background: var(--white); border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
    appearance: none; -webkit-appearance: none; box-shadow: none;
}
select {
    padding-right: 28px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%2364748B' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 10px center;
}
textarea { min-height: 80px; resize: vertical; }
input::placeholder, textarea::placeholder { color: #94A3B8; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--green); box-shadow: var(--ring); }
input[type=checkbox], input[type=radio] { width: 16px; height: 16px; accent-color: var(--green); flex-shrink: 0; margin: 0; }
input:disabled, select:disabled, textarea:disabled { background: var(--bg); color: var(--ink-soft); cursor: not-allowed; }
input[type=number] { width: auto; min-width: 64px; }
.field, .form-row { margin-bottom: 10px; }
.field-hint { margin: 3px 0 0; font-size: .74rem; color: var(--ink-soft); font-weight: 400; }
.form-grid, .grid2 { display: grid; grid-template-columns: 1fr; gap: 10px; }
.span-all { grid-column: 1 / -1; }
@media (min-width: 700px) { .form-grid, .grid2 { grid-template-columns: 1fr 1fr; } }
.admin-form, .form-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; display: grid; gap: 10px; }
.form-card { padding: 0; gap: 0; }
.form-head { padding: 10px 14px; border-bottom: 1px solid var(--line); font-weight: 600; }
.form-body { padding: 14px; display: grid; gap: 10px; }
.visibility { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; margin: 2px 0; background: var(--bg); }
.visibility legend { font-weight: 600; font-size: .8rem; padding: 0 6px; }
.visibility small { display: block; color: var(--ink-soft); margin-top: 4px; }
.check-row { display: flex; align-items: center; gap: 8px; padding: 4px 0; font-weight: 500; font-size: .86rem; cursor: pointer; margin: 0; }
.check-row input { width: 16px; height: 16px; }

/* ---- Admin ---- */
.admin-nav { display: flex; gap: 4px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.admin-nav a { text-decoration: none; padding: 6px 12px; border-radius: 999px; background: var(--white); border: 1px solid var(--line); color: var(--ink-soft); font-weight: 600; font-size: .8rem; }
.admin-nav a:hover { border-color: var(--green); color: var(--green-dark); }
.admin-nav a[aria-current="page"], .admin-nav a.active { background: var(--green); border-color: var(--green); color: #fff; }
.nav-logout { margin: 0 0 0 auto; }
.admin-note, .alert { padding: 8px 12px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--bg); font-size: .85rem; margin: 0 0 10px; }
.admin-note.ok, .alert-ok, .alert.success { background: #F0FDF4; border-color: #BBF7D0; color: #166534; }
.admin-note.bad, .alert-err, .alert.error { background: #FEF2F2; border-color: #FECACA; color: #991B1B; }

.filter-line, .filter-bar, .search-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin: 10px 0; }
.filter-line input[type=search], .filter-bar input[type=search], .search-form input { flex: 1; min-width: 170px; max-width: 320px; width: auto; }
.filter-line select, .filter-bar select { width: auto; }
.filter-count { color: var(--ink-soft); font-size: .8rem; }

.tbl-wrap { overflow-x: auto; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.admin-table { width: 100%; border-collapse: collapse; font-size: .82rem; }
.admin-table th { background: var(--bg); text-align: left; font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-soft); padding: 8px 10px; white-space: nowrap; border-bottom: 1px solid var(--line); }
.admin-table td { padding: 8px 10px; border-top: 1px solid var(--line); vertical-align: middle; }
.admin-table thead + tbody tr:first-child td { border-top: 0; }
.admin-table tbody tr:hover { background: var(--bg); }
.admin-table input[type=number], .admin-table input[type=text] { padding: 5px 8px; font-size: .82rem; }
.id-cell, .date-cell { color: var(--ink-soft); white-space: nowrap; }
.link-cell, .anchor-cell, .url-cell { display: block; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-soft); }
.row-actions, .actions { display: flex; gap: 5px; flex-wrap: nowrap; align-items: center; }
.row-actions form, .actions form { margin: 0; }
.status-pill { display: inline-flex; align-items: center; gap: 5px; padding: 1px 9px; border-radius: 999px; font-size: .72rem; font-weight: 600; border: 1px solid var(--line); background: var(--bg); color: var(--ink-soft); }
.status-dot, .dot, .dot2 { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-soft); display: inline-block; }
.s-on, .s-active { background: #F0FDF4; color: var(--won); border-color: #BBF7D0; }
.s-on .status-dot, .s-active .status-dot { background: var(--won); }
.s-off, .s-inactive { background: var(--bg); color: var(--ink-soft); }
.delete-line { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.rule-row, .seo-row { display: grid; gap: 8px; padding: 10px 0; border-top: 1px solid var(--line); }
.rule-row:first-child, .seo-row:first-child { border-top: 0; }
.rule-fields, .seo-fields, .seo-grid { display: grid; grid-template-columns: 1fr; gap: 8px; }
.rule-title { font-weight: 600; font-size: .9rem; }
@media (min-width: 700px) { .rule-fields, .seo-fields, .seo-grid { grid-template-columns: repeat(2, 1fr); } }
.seo-tabs { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 10px; }
.seo-tabs a { text-decoration: none; padding: 5px 12px; border: 1px solid var(--line); border-radius: 999px; font-size: .8rem; font-weight: 600; color: var(--ink-soft); background: var(--white); }
.seo-tabs a.active, .seo-tabs a[aria-current] { background: var(--green); border-color: var(--green); color: #fff; }

/* Keyword editor */
#kw-form { padding: 14px; gap: 4px; }
#kw-form > label { margin-top: 10px; }
#kw-form > label:first-of-type { margin-top: 0; }
#kw-form textarea { min-height: 80px; }
#kw-form fieldset.visibility { margin-top: 12px; }
#kw-form .btn-line { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.jodit-container:not(.jodit_inline) { border: 1px solid var(--line-strong) !important; border-radius: var(--radius-sm); overflow: hidden; box-shadow: none !important; }
.jodit-wysiwyg, .jodit-container .jodit-workplace { font-family: 'Poppins', sans-serif; font-size: 14px; line-height: 1.7; }
.jodit-wysiwyg h2 { font-size: 1.2rem; } .jodit-wysiwyg h3 { font-size: 1.05rem; } .jodit-wysiwyg h4 { font-size: .95rem; }
.jodit-wysiwyg table { border-collapse: collapse; width: 100%; }
.jodit-wysiwyg th, .jodit-wysiwyg td { border: 1px solid var(--line-strong); padding: 5px 8px; }

/* Login / setup */
.auth-wrap, .login-wrap, .shell, .standalone { max-width: 380px; margin: 40px auto; padding: 0 14px; }
.auth-wrap .card, .login-wrap .card, .shell .card, .standalone .card { padding: 18px; }

/* ---- PWA: install banner, update notice, offline bar ---- */
.kbt-install {
    position: fixed; z-index: 90; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom));
    background: var(--white); border: 1px solid var(--line-strong); border-radius: 12px; padding: 12px;
    display: grid; grid-template-columns: 40px 1fr auto; gap: 4px 10px; align-items: start;
    transform: translateY(24px); opacity: 0; transition: transform .25s ease, opacity .25s ease;
}
.kbt-install[hidden] { display: none; }
.kbt-install.is-open { transform: none; opacity: 1; }
.kbt-install-icon { width: 40px; height: 40px; border-radius: 9px; }
.kbt-install-title { font-weight: 700; font-size: .9rem; line-height: 1.3; }
.kbt-install-text { margin: 2px 0 0; font-size: .8rem; color: var(--ink-soft); line-height: 1.5; }
.kbt-install-steps { margin: 8px 0 0; padding-left: 1.2em; font-size: .8rem; color: var(--ink); }
.kbt-install-steps li { margin-bottom: 3px; }
.kbt-install-actions { grid-column: 2 / 4; display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.kbt-install-close { background: none; border: 0; font-size: 1.4rem; line-height: 1; color: var(--ink-soft); min-width: 34px; min-height: 34px; border-radius: 8px; cursor: pointer; }
.kbt-install-close:hover { background: var(--bg); color: var(--ink); }
body.kbt-banner-open { padding-bottom: 140px; }
.kbt-offline-bar { position: fixed; top: 0; left: 0; right: 0; z-index: 120; padding: calc(5px + env(safe-area-inset-top)) 12px 5px; background: var(--ink); color: #fff; font-size: .78rem; text-align: center; }
.kbt-offline-bar[hidden] { display: none; }

/* ---- Desktop ---- */
@media (min-width: 768px) {
    h1 { font-size: 1.75rem; }
    .site-main { padding: 22px 0 44px; }
    .footer-top { flex-direction: row; justify-content: space-between; align-items: flex-start; }
    .kbt-install { left: auto; right: 18px; bottom: 18px; width: 360px; }
    body.kbt-banner-open { padding-bottom: 0; }
}
@media (prefers-reduced-motion: reduce) { .kbt-install { transition: none; transform: none; } }

/* ---- Footer additions: append to assets/css/style.css ---- */
.footer-top { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 14px; margin-bottom: 14px; }
.footer-about { grid-column: 1 / -1; }
.footer-col .footer-heading { margin-bottom: 6px; }
.footer-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.footer-list a { color: var(--ink-soft); text-decoration: none; font-size: .84rem; }
.footer-list a:hover { color: var(--green-dark); text-decoration: underline; }
.footer-contact { display: flex; flex-wrap: wrap; gap: 4px 18px; padding: 10px 0; border-top: 1px solid var(--line); font-size: .82rem; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; border-top: 1px solid var(--line); padding-top: 10px; margin-top: 8px; }
.footer-bottom p { margin: 0; }
@media (min-width: 768px) {
    .footer-top { grid-template-columns: 1.4fr 1fr 1.2fr 1fr; }
    .footer-about { grid-column: auto; }match
}
.container.page-narrow { max-width: 760px; }

/* ---- Header: logo, search, mobile menu. Append at the END of assets/css/style.css ---- */
.site-header { position: sticky; }
.header-inner { position: relative; }
.brand-mark { display: none; }
.brand-logo { width: 32px; height: 32px; border-radius: 8px; display: block; }
.header-actions { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.main-nav { overflow: visible; margin-left: 16px; }
.icon-btn {
    display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px;
    background: transparent; color: var(--ink-soft); border: 1px solid transparent; border-radius: var(--radius-sm); cursor: pointer; padding: 0;
}
.icon-btn:hover { background: var(--bg); color: var(--ink); }
.icon-btn[aria-expanded="true"] { background: var(--green-soft); color: var(--green-dark); }
.menu-btn .ico-close { display: none; }
.site-header.menu-open .menu-btn .ico-open { display: none; }
.site-header.menu-open .menu-btn .ico-close { display: block; }
.menu-btn { display: none; }

/* search panel */
.search-panel { border-top: 1px solid var(--line); background: var(--white); padding: 10px 0 12px; }
.search-panel[hidden] { display: none; }
.search-box { display: flex; align-items: center; gap: 8px; background: var(--white); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 0 4px 0 12px; color: var(--ink-soft); }
.search-box:focus-within { border-color: var(--green); box-shadow: var(--ring); }
.search-box input[type=search] { border: 0 !important; box-shadow: none !important; background: transparent; padding: 10px 4px; flex: 1; min-width: 0; font-size: 16px; }
.search-box input[type=search]::-webkit-search-cancel-button { display: none; }
.search-close { width: 32px; height: 32px; }
.search-results { max-height: min(60vh, 440px); overflow-y: auto; margin-top: 8px; }
.search-results:empty { display: none; }
.sr-group { margin: 8px 0 4px; font-size: .74rem; font-weight: 600; color: var(--ink-soft); }
.sr-note { margin: 6px 0; font-size: .86rem; color: var(--ink-soft); }
.sr-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.sr-list li + li { border-top: 1px solid var(--line); }
.sr-item { display: flex; flex-direction: column; gap: 1px; padding: 9px 12px; text-decoration: none; color: var(--ink); }
.sr-item:hover, .sr-item.is-active { background: var(--green-soft); color: var(--ink); }
.sr-title { font-weight: 600; font-size: .9rem; }
.sr-meta { font-size: .76rem; color: var(--ink-soft); }

/* mobile: nav becomes a dropdown */
@media (max-width: 767px) {
    .menu-btn { display: inline-flex; }
    .main-nav {
        display: none; position: absolute; left: 0; right: 0; top: 100%; margin: 0;
        flex-direction: column; gap: 0; background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line-strong);
        padding: 6px 14px 10px;
    }
    .site-header.menu-open .main-nav { display: flex; }
    .main-nav a { padding: 11px 4px; border-radius: 0; border-bottom: 1px solid var(--line); font-size: .95rem; }
    .main-nav a:last-child { border-bottom: 0; }
    .main-nav a[aria-current="page"], .main-nav a.active { background: transparent; color: var(--green-dark); }
}

/* ---- Match page: scoreboard, preview, statistics. Append at the END of assets/css/style.css ---- */
.mp-h1 { font-size: 1.05rem; font-weight: 600; color: var(--ink-soft); margin: 0 0 10px; letter-spacing: 0; }

/* Scoreboard */
.sb { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 16px 14px 14px; margin-bottom: 10px; text-align: center; }
.sb-league { margin: 0 0 12px; font-size: .78rem; font-weight: 600; color: var(--green-dark); }
.sb-main { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; }
.sb-team { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 0; }
.sb-crest { width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: .95rem; letter-spacing: .02em; }
.sb-name { font-weight: 700; font-size: .95rem; line-height: 1.25; overflow-wrap: anywhere; }
.sb-centre { display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 120px; }
.sb-score { display: inline-flex; align-items: center; gap: 8px; background: var(--ink); color: #fff; border-radius: 12px; padding: 6px 16px; font-variant-numeric: tabular-nums; }
.sb-score span { font-size: 2rem; font-weight: 700; line-height: 1.1; }
.sb-score i { font-style: normal; color: #64748B; font-weight: 500; }
.sb-time { font-size: 1.9rem; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; }
.sb-status { font-size: .74rem; font-weight: 600; color: var(--ink-soft); }
.sb-status.is-ft { color: var(--green-dark); background: var(--green-soft); border: 1px solid #BBF7D0; border-radius: 999px; padding: 0 10px; }
.sb-ht { font-size: .74rem; color: var(--ink-soft); }
.sb-foot { margin: 12px 0 0; font-size: .78rem; color: var(--ink-soft); }
.sb-foot:empty { display: none; }
.sb-odds { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
@media (min-width: 700px) {
    .sb { padding: 20px 24px 16px; }
    .sb-crest { width: 60px; height: 60px; font-size: 1.1rem; }
    .sb-name { font-size: 1.15rem; }
    .sb-centre { min-width: 190px; }
    .sb-score span { font-size: 2.8rem; }
    .sb-time { font-size: 2.6rem; }
}

/* Jump links */
.mp-jump { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 12px; }
.mp-jump a { text-decoration: none; font-size: .8rem; font-weight: 600; color: var(--ink-soft); background: var(--white); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; }
.mp-jump a:hover { border-color: var(--green); color: var(--green-dark); }
.match-page .mp-section { scroll-margin-top: 70px; }

/* Preview / report */
.mp-write p { max-width: 68ch; line-height: 1.75; }
.mp-standfirst { font-size: 1.02rem; font-weight: 600; line-height: 1.5 !important; color: var(--ink); }

/* Statistics */
.st-h { margin: 18px 0 8px; font-size: .9rem; }
.st-h:first-of-type { margin-top: 6px; }
.st-chance { display: flex; height: 12px; border-radius: 999px; overflow: hidden; border: 1px solid var(--line); background: var(--bg); }
.st-chance .seg { display: block; height: 100%; }
.seg-h, .dot-h { background: var(--green); }
.seg-d, .dot-d { background: #CBD5E1; }
.seg-a, .dot-a { background: var(--ink); }
.st-chance .seg + .seg { border-left: 2px solid var(--white); }
.st-legend { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 8px; font-size: .82rem; }
.st-legend i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }
.st-legend b { font-variant-numeric: tabular-nums; margin-right: 4px; }

.st-vs { display: grid; gap: 10px; }
.st-row { display: grid; grid-template-columns: 28px 1fr 28px; align-items: center; gap: 10px; }
.st-val { font-size: 1.05rem; font-variant-numeric: tabular-nums; }
.st-val:last-child { text-align: right; }
.st-mid { display: flex; flex-direction: column; gap: 4px; }
.st-label { text-align: center; font-size: .76rem; font-weight: 600; color: var(--ink-soft); }
.st-bar { display: flex; height: 8px; gap: 3px; }
.st-bar i { display: block; height: 100%; border-radius: 999px; min-width: 0; }
.st-bar .bar-h { background: var(--green); }
.st-bar .bar-a { background: var(--ink); }
.st-bar.is-empty i { background: var(--line); }

.st-markets { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.st-mk-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: .88rem; }
.st-mk-top small { color: var(--ink-soft); margin-left: 4px; }
.st-mk-nums { color: var(--ink-soft); font-size: .8rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.st-mk-nums b { color: var(--ink); font-size: .9rem; margin-left: 4px; }
.st-meter { display: block; height: 6px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); margin-top: 5px; overflow: hidden; }
.st-meter i { display: block; height: 100%; background: #94A3B8; }
.st-meter i.m-won { background: var(--won); }
.st-meter i.m-lost { background: var(--lost); }
.st-meter i.m-void { background: #D97706; }
.st-meter i.m-pending { background: #94A3B8; }

@media (min-width: 960px) {
    .mp-cols { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 10px; align-items: start; }
}