/* Shared shell for every page: brand tokens, top bar and site footer.
   Scoped to .topbar / .foot so it cannot collide with the Bootstrap pages. */

:root {
  --bg: #F1F4F0;
  --card: #FFFFFF;
  --ink: #0D1B16;
  --muted: #5F7168;
  --faint: #637569;

  --line: #E3E9E4;
  --line-2: #EEF2EE;

  --green-900: #06301F;
  --green-800: #0A4029;
  --green-700: #0C5C3C;
  --green-600: #10875A;
  --green-100: #E2F3E9;
  --green-50: #F1F9F4;

  --display: "Outfit", "Segoe UI", system-ui, sans-serif;
  --text: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --max: 1280px;
  --page-px: clamp(16px, 3.5vw, 36px);
  --accent: #C7F04B;
  --accent-ink: #0F2E1C;
}

html {
  max-width: 100%;
  overflow-x: clip;
}

body,
body.modricpredict-theme {
  background-color: #F1F4F0;
  margin: 0 !important;
  padding-top: 0 !important;
  max-width: 100%;
  overflow-x: clip;
}

.bm-layout-wrapper,
.bm-page-body {
  max-width: 100%;
}

/* ---------- top bar ---------- */

.topbar {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #06301F;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  width: 100%;
}

.topbar-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--page-px);
  height: 72px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.topbar .brand {
  font-family: var(--display);
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.01em;
  color: #fff;
  text-decoration: none;
}

.topbar .nav-links {
  display: flex;
  gap: 4px;
  margin-left: auto;
  margin-right: 0;
  align-items: center;
}

.topbar .nav-links a,
.topbar .nav-trigger {
  font-family: var(--text);
  font-size: 13.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.68);
  padding: 8px 12px;
  border-radius: 999px;
  text-decoration: none;
  transition: color 140ms ease, background-color 140ms ease;
}

.topbar .nav-trigger {
  border: 0;
  background: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.topbar .nav-links a:hover,
.topbar .nav-trigger:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.topbar .nav-links a.is-active {
  color: #06301F;
  background: #D8F0E2;
}

/* VIP Navbar Item with Gold Accent & Crown */
.topbar .nav-links a.nav-vip-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  color: #FBBF24;
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.28);
  padding: 6.5px 12px;
  border-radius: 999px;
  transition: all 140ms ease;
}

.topbar .nav-links a.nav-vip-link:hover {
  color: #FFFFFF;
  background: rgba(251, 191, 36, 0.22);
  border-color: rgba(251, 191, 36, 0.5);
}

.topbar .nav-links a.nav-vip-link.is-active {
  color: #06301F;
  background: #FBBF24;
  border-color: #FBBF24;
}

.topbar .nav-links a.nav-vip-link.is-active .vip-crown-icon {
  fill: #06301F !important;
  stroke: #06301F !important;
}

@media (min-width: 1025px) and (max-width: 1220px) {
  .topbar-inner {
    gap: 12px;
  }
  .topbar .nav-links {
    gap: 2px;
  }
  .topbar .nav-links a,
  .topbar .nav-trigger {
    font-size: 13px;
    padding: 7px 9px;
  }
}

.topbar .nav-item { position: relative; display: flex; align-items: center; }

.topbar .nav-item.is-open .nav-trigger {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.topbar .caret { font-size: 9px; line-height: 1; opacity: 0.75; }

.topbar .nav-drop {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 70;
  min-width: 214px;
  max-height: 82vh;
  overflow-y: auto;
  scrollbar-width: thin;
  padding: 6px;
  background: #fff;
  border: 1px solid var(--line, #E3E9E4);
  border-radius: 14px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.14);
  display: none;
  flex-direction: column;
  gap: 2px;
}

/* Invisible bridge so mouse hover is never lost when moving between trigger and menu */
.topbar .nav-drop::before {
  content: '';
  position: absolute;
  top: -12px;
  left: 0;
  right: 0;
  height: 12px;
  background: transparent;
}

.topbar .nav-item:hover .nav-drop,
.topbar .nav-item:focus-within .nav-drop,
.topbar .nav-item.is-open .nav-drop { display: flex; }

.topbar .nav-drop a {
  display: block;
  padding: 8px 10px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 600;
  color: #0D1B16;
  background: none;
  white-space: nowrap;
  text-decoration: none;
}

.topbar .nav-drop a:hover { color: #0A4029; background: #F1F9F4; }

.topbar-divider {
  width: 1px;
  height: 22px;
  background: rgba(255, 255, 255, 0.18);
  margin: 0 4px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Theme Toggle Button */
.theme-toggle-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #C7F04B;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.theme-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(199, 240, 75, 0.4);
  transform: translateY(-1px);
}

.theme-toggle-btn:active {
  transform: scale(0.94);
}

.theme-toggle-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s ease;
}

/* Light mode (default): show moon (action: switch to dark) */
html:not([data-theme="dark"]) .theme-icon-sun {
  display: none !important;
}
html:not([data-theme="dark"]) .theme-icon-moon {
  display: inline-flex !important;
  color: #C7F04B;
}

/* Dark mode: show sun (action: switch to light) */
html[data-theme="dark"] .theme-icon-moon {
  display: none !important;
}
html[data-theme="dark"] .theme-icon-sun {
  display: inline-flex !important;
  color: #C7F04B;
}

.mobile-nav-theme-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  margin-top: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
}

.mobile-nav-theme-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--text, "Manrope", sans-serif);
  font-weight: 600;
  font-size: 14px;
  color: #FFFFFF;
}

/* Mobile Auth Actions in Drawer */
.mobile-nav-auth {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 0 6px;
  margin-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.mobile-auth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 44px;
  border-radius: 10px;
  font-family: var(--text, "Manrope", sans-serif);
  font-size: 14.5px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: all 140ms ease;
  box-sizing: border-box;
}

.mobile-auth-btn-solid {
  background: var(--accent, #C7F04B);
  color: var(--green-900, #06301F);
  border: 1.5px solid var(--accent, #C7F04B);
  box-shadow: 0 2px 10px rgba(199, 240, 75, 0.28);
}

.mobile-auth-btn-solid:hover {
  background: #b8e43a;
  border-color: #b8e43a;
  color: #06301F;
}

.mobile-auth-btn-outline {
  background: transparent;
  color: #FFFFFF;
  border: 1.5px solid rgba(255, 255, 255, 0.24);
}

.mobile-auth-btn-outline:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.4);
  color: #FFFFFF;
}

.topbar-auth {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-auth .nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  padding: 0 20px;
  font-family: var(--text, "Manrope", sans-serif);
  font-size: 13.5px;
  font-weight: 700;
  border-radius: 10px;
  text-decoration: none;
  cursor: pointer;
  transition: all 140ms ease;
  white-space: nowrap;
}

.topbar-auth .nav-btn-outline {
  background: transparent;
  color: #FFFFFF;
  border: 1.5px solid var(--accent, #C7F04B);
}

.topbar-auth .nav-btn-outline:hover {
  background: rgba(199, 240, 75, 0.12);
  border-color: var(--accent, #C7F04B);
  color: var(--accent, #C7F04B);
}

.topbar-auth .nav-btn-solid {
  background: var(--accent, #C7F04B);
  color: var(--green-900, #06301F);
  border: 1.5px solid var(--accent, #C7F04B);
  box-shadow: 0 2px 10px rgba(199, 240, 75, 0.28);
  font-weight: 800;
}

.topbar-auth .nav-btn-solid:hover {
  background: #b8e43a;
  border-color: #b8e43a;
  color: #06301F;
  transform: translateY(-1px);
}

/* Mobile nav toggle button */
.nav-toggle {
  display: none;
  width: 38px;
  height: 38px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 9px;
  padding: 0;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  transition: all 140ms ease;
}

.nav-toggle:hover {
  background: rgba(255, 255, 255, 0.16);
}

.nav-toggle .bar {
  display: block;
  width: 18px;
  height: 2px;
  background: #FFFFFF;
  border-radius: 2px;
  transition: transform 200ms ease, opacity 200ms ease;
}

.nav-toggle.is-open .bar-1 {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle.is-open .bar-2 {
  opacity: 0;
}

.nav-toggle.is-open .bar-3 {
  transform: translateY(-6px) rotate(-45deg);
}

.mobile-nav {
  display: none;
}

.mobile-nav-backdrop {
  display: none;
}

.market[aria-selected="true"] {
  background: #06301F !important;
  color: #C7F04B !important;
  font-weight: 700;
}

/* ---------- footer ---------- */

.foot {
  margin-top: 44px;
  background: #06301F;
  color: rgba(255, 255, 255, 0.72);
  font-family: var(--text);
}

.foot-main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 40px var(--page-px) 26px;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 34px 30px;
  align-items: start;
}

.foot-about { grid-column: 1; grid-row: 1 / span 2; }
.foot-matches { grid-column: 2 / span 2; grid-row: 1; }
.foot-articles { grid-column: 4; grid-row: 1; }
.foot-competitions { grid-column: 2; grid-row: 2; }
.foot-navigation { grid-column: 3; grid-row: 2; }
.foot-categories { grid-column: 4; grid-row: 2; }

.foot h2 {
  margin: 0 0 14px;
  font-family: var(--display);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent);
}

.foot-about h2:not(:first-child) { margin-top: 26px; }

.foot-about p {
  margin: 0;
  max-width: 46ch;
  font-size: 12.5px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.62);
}

.foot-inline { display: flex; flex-wrap: wrap; align-items: center; }

.foot-inline a,
.foot-mail {
  font-size: 12.5px;
  line-height: 24px;
  color: rgba(255, 255, 255, 0.62);
  text-decoration: none;
}

.foot-inline a:hover,
.foot-mail:hover { color: #fff; }

.foot-dot { color: rgba(255, 255, 255, 0.28); margin: 0 8px; }

.foot-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }

.foot-col a {
  font-size: 12px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.64);
  text-decoration: none;
}

.foot-col a:hover { color: #fff; }

.foot-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 26px; }

.foot-middle {
  max-width: var(--max);
  margin: 0 auto;
  padding: 24px var(--page-px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.foot-logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }

.foot-logo-mark {
  width: 26px;
  height: 26px;
  border-radius: 9px;
  border: 2px solid #7FE3B0;
}

.foot-logo-text {
  font-family: var(--display);
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.01em;
  color: #fff;
}

.foot-social {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
}

.foot-social:hover { background: rgba(255, 255, 255, 0.18); }
.foot-social svg { width: 18px; height: 18px; }

.foot-bottom { border-top: 1px solid rgba(255, 255, 255, 0.1); }

.foot-bottom-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 16px var(--page-px) 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.foot-copy {
  margin: 0;
  font-size: 11.5px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.55);
}

.foot-legal { display: flex; gap: 18px; flex-wrap: wrap; }
.foot-legal a { font-size: 11.5px; color: rgba(255, 255, 255, 0.66); text-decoration: none; }
.foot-legal a:hover { color: #fff; }

@media (max-width: 1060px) {
  .foot-main { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .foot-about { grid-column: 1 / -1; grid-row: auto; }
  .foot-matches { grid-column: 1 / -1; grid-row: auto; }
  .foot-articles,
  .foot-competitions,
  .foot-navigation,
  .foot-categories { grid-column: auto; grid-row: auto; }
}

@media (max-width: 1024px) {
  .topbar-inner {
    height: 64px !important;
    padding: 0 16px !important;
    justify-content: space-between !important;
    flex-wrap: nowrap !important;
  }

  .topbar .brand { order: 1; }
  .topbar-divider { display: none !important; }
  .topbar .nav-links { display: none !important; }
  .nav-toggle { display: inline-flex !important; }

  .topbar-actions {
    order: 2;
    margin-left: auto;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
  }

  /* Auth buttons move inside the mobile drawer to prevent topbar overflow */
  .topbar-auth {
    display: none !important;
  }

  /* Mobile Navigation Drawer */
  .mobile-nav {
    display: block;
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    max-height: calc(100vh - 64px);
    overflow-y: auto;
    background: #06301F;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
    transform: translateY(-10px);
    opacity: 0;
    pointer-events: none;
    transition: transform 220ms cubic-bezier(0.16, 1, 0.3, 1), opacity 200ms ease;
    z-index: 999;
  }

  .mobile-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-nav-inner {
    padding: 16px 20px 24px;
    display: flex;
    flex-direction: column;
    gap: 4px;
  }

  .mobile-nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    font-family: var(--text, "Manrope", sans-serif);
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.88);
    text-decoration: none;
    border-radius: 10px;
    transition: background-color 140ms ease, color 140ms ease;
  }

  .mobile-nav-link:hover,
  .mobile-nav-link.is-active {
    background: rgba(255, 255, 255, 0.08);
    color: var(--accent, #C7F04B);
  }

  .mobile-nav-vip {
    color: #FBBF24 !important;
  }

  .mobile-nav-vip:hover,
  .mobile-nav-vip.is-active {
    background: rgba(251, 191, 36, 0.14) !important;
    color: #FDE047 !important;
  }

  .mobile-nav-accordion {
    border-radius: 10px;
    overflow: hidden;
  }

  .mobile-accordion-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    background: none;
    border: none;
    font-family: var(--text, "Manrope", sans-serif);
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.88);
    cursor: pointer;
    border-radius: 10px;
    text-align: left;
    transition: background-color 140ms ease, color 140ms ease;
  }

  .mobile-accordion-trigger:hover,
  .mobile-nav-accordion.is-open .mobile-accordion-trigger {
    background: rgba(255, 255, 255, 0.08);
    color: #FFFFFF;
  }

  .mobile-accordion-trigger .acc-chevron {
    font-size: 12px;
    transition: transform 200ms ease;
    opacity: 0.75;
  }

  .mobile-nav-accordion.is-open .acc-chevron {
    transform: rotate(180deg);
  }

  .mobile-accordion-content {
    display: none;
    flex-direction: column;
    padding: 4px 0 8px 16px;
    gap: 2px;
  }

  .mobile-nav-accordion.is-open .mobile-accordion-content {
    display: flex;
  }

  .mobile-accordion-content a {
    display: block;
    padding: 9px 14px;
    font-family: var(--text, "Manrope", sans-serif);
    font-size: 13.5px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.72);
    text-decoration: none;
    border-radius: 8px;
    transition: color 120ms ease, background-color 120ms ease;
  }

  .mobile-accordion-content a:hover {
    color: var(--accent, #C7F04B);
    background: rgba(255, 255, 255, 0.05);
  }

  .mobile-nav-backdrop {
    display: block;
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(2px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 200ms ease;
    z-index: 998;
  }

  .mobile-nav-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
  }

  body.mobile-nav-active {
    overflow: hidden;
  }
}

/* Match Card Responsive Layout for Mobile & Medium Screens (<= 860px) */
@media (max-width: 860px) {
  .board-card {
    padding: 14px 12px !important;
    border-radius: 16px !important;
  }

  .board-head {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
  }

  .dates {
    display: flex !important;
    overflow-x: auto !important;
    scrollbar-width: none !important;
    -webkit-overflow-scrolling: touch !important;
    gap: 6px !important;
    padding-bottom: 2px !important;
    max-width: 100% !important;
  }
  .dates::-webkit-scrollbar { display: none !important; }

  .date {
    flex-shrink: 0 !important;
    padding: 8px 12px !important;
    min-width: 58px !important;
    text-align: center !important;
  }

  .markets {
    display: flex !important;
    overflow-x: auto !important;
    scrollbar-width: none !important;
    -webkit-overflow-scrolling: touch !important;
    flex-wrap: nowrap !important;
    gap: 6px !important;
    padding-bottom: 4px !important;
    max-width: 100% !important;
  }
  .markets::-webkit-scrollbar { display: none !important; }
  .market { flex-shrink: 0 !important; padding: 6px 14px !important; font-size: 12px !important; }

  .leagues {
    display: flex !important;
    overflow-x: auto !important;
    scrollbar-width: none !important;
    -webkit-overflow-scrolling: touch !important;
    flex-wrap: nowrap !important;
    gap: 14px !important;
    padding-bottom: 6px !important;
    max-width: 100% !important;
  }
  .leagues::-webkit-scrollbar { display: none !important; }
  .league { flex-shrink: 0 !important; }

  /* Table structure */
  .table-wrap {
    overflow-x: visible !important;
    min-width: 0 !important;
    width: 100% !important;
    margin-top: 10px !important;
  }

  .table-head {
    display: none !important;
  }

  .prob-desktop { display: none !important; }
  .prob-mobile { display: inline !important; }

  .matches {
    min-width: 0 !important;
    width: 100% !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }

  /* Match Row Card */
  .match:not(.rw-card) {
    display: grid !important;
    grid-template-columns: auto 1fr 58px 48px 62px !important;
    grid-template-rows: auto auto !important;
    row-gap: 6px !important;
    column-gap: 6px !important;
    align-items: center !important;
    padding: 12px 12px !important;
    border-radius: 8px !important;
    margin: 2px 0 !important;
    min-width: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
    border-bottom: 1px solid rgba(229, 231, 235, 0.6) !important;
  }

  .match:not(.rw-card):nth-child(odd) { background: #FFFFFF !important; }
  .match:not(.rw-card):nth-child(even) { background: #F4F6F8 !important; }

  /* Row 1: Time & League */
  .match:not(.rw-card) .m-time {
    grid-row: 1 !important;
    grid-column: 1 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    color: #374151 !important;
    white-space: nowrap !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 4px !important;
  }

  .match .m-date,
  .match .m-date-val {
    display: inline !important;
    font-size: 11px !important;
    color: #6B7280 !important;
  }

  .match .m-league {
    grid-row: 1 !important;
    grid-column: 2 / -1 !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #4B5563 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    text-align: left !important;
    padding-left: 4px !important;
  }

  /* Row 2: Teams on Left */
  .match .m-fixture {
    grid-row: 2 !important;
    grid-column: 1 / 3 !important;
    width: 100% !important;
    display: block !important;
    min-width: 0 !important;
  }

  .match .m-fixture-link {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    width: 100% !important;
    text-decoration: none !important;
  }

  .match .m-fixture-side {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 7px !important;
    width: 100% !important;
    justify-content: flex-start !important;
  }

  .match .m-fixture-home .crest {
    order: 1 !important;
    flex-shrink: 0 !important;
  }

  .match .m-fixture-home .m-team {
    order: 2 !important;
    text-align: left !important;
  }

  .match .m-fixture-away .crest {
    order: 1 !important;
    flex-shrink: 0 !important;
  }

  .match .m-fixture-away .m-team {
    order: 2 !important;
    text-align: left !important;
  }

  .match .m-vs {
    display: none !important;
  }

  .match .m-score-box {
    display: none !important;
  }

  .match .m-team {
    font-size: 13.5px !important;
    font-weight: 600 !important;
    color: #111827 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    max-width: calc(100vw - 230px) !important;
  }

  .match .crest {
    width: 19px !important;
    height: 19px !important;
    min-width: 19px !important;
    font-size: 9px !important;
  }

  .match .crest img {
    width: 17px !important;
    height: 17px !important;
    object-fit: contain !important;
  }

  /* Row 2: Tip, Odds, Prob on Right */
  .match .m-tip {
    grid-row: 2 !important;
    grid-column: 3 !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #111827 !important;
    text-align: center !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .match .m-odds {
    grid-row: 2 !important;
    grid-column: 4 !important;
    font-size: 13.5px !important;
    font-weight: 700 !important;
    color: #10875A !important;
    text-align: center !important;
  }

  .match .m-prob {
    grid-row: 2 !important;
    grid-column: 5 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
  }

  .match .confidence-badge {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 3px 8px !important;
    border-radius: 999px !important;
    background: #D1FAE5 !important;
    color: #065F46 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    letter-spacing: -0.01em !important;
  }

  .match .m-action {
    grid-row: 1 !important;
    grid-column: 5 !important;
    justify-self: end !important;
    display: block !important;
  }

  .match .m-action .m-status {
    padding: 2px 6px !important;
    font-size: 11px !important;
    border-radius: 6px !important;
  }
}

@media (max-width: 560px) {
  .foot-main { grid-template-columns: minmax(0, 1fr); padding: 28px var(--page-px) 20px; }
  .foot-two { grid-template-columns: minmax(0, 1fr); }
  .foot-middle { padding: 20px var(--page-px); }
  .foot-bottom-inner { padding: 14px var(--page-px) 20px; }
}

/* the site now runs on the homepage's light surface by default */
body.modricpredict-theme.light-theme {
  --lt-bg: #F1F4F0;
  background-color: #F1F4F0 !important;
}

/* admin-uploaded logo */
.topbar .brand-img { height: 34px; width: auto; display: block; }
.foot-logo-img { height: 36px; width: auto; display: block; }

/* Universal Page Body & Content Container matching homepage margins */
.bm-page-body {
  width: 100%;
}

.bm-content-body {
  max-width: var(--max) !important;
  margin: 0 auto !important;
  padding: 14px var(--page-px) 40px !important;
  box-sizing: border-box !important;
  width: 100% !important;
  background-color: transparent !important;
}

.bm-page-header {
  width: 100%;
  padding: 0 !important;
  margin: 0 !important;
}

.bm-page-header > :not(.category-hero-clean):not(.rw-hero) {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
  padding: 14px var(--page-px) 0;
  box-sizing: border-box;
}

@media (max-width: 560px) {
  .bm-content-body {
    padding: 14px 14px 30px !important;
  }
}

/* Universal Typography: Manrope */
body, html, input, button, select, textarea, p, span, a, li, td, th {
  font-family: var(--text) !important;
}

h1, h2, h3, h4, h5, h6, .brand, .m-team {
  font-family: var(--display) !important;
}

/* Global Match Row & Crest Guarantee */
:root {
  --row: 70px 190px minmax(260px, 1fr) 90px 70px 100px 88px;
}

.crest {
  width: 22px !important;
  height: 22px !important;
  max-width: 22px !important;
  max-height: 22px !important;
  border-radius: 50% !important;
  display: inline-grid !important;
  place-items: center !important;
  font-family: var(--display) !important;
  font-size: 9px !important;
  font-weight: 800 !important;
  letter-spacing: 0.02em !important;
  background: var(--club, #06301F) !important;
  color: var(--crest-ink, #FFFFFF) !important;
  flex: none !important;
  overflow: hidden !important;
}

.crest img {
  width: 100% !important;
  height: 100% !important;
  max-width: 22px !important;
  max-height: 22px !important;
  object-fit: contain !important;
  display: block !important;
}

.crest.crest-logo {
  background: transparent !important;
}

.m-date-val {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  white-space: nowrap;
}

.m-score-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1.15;
  gap: 1px;
  flex: none;
  padding: 0 4px;
}

.m-score-tag {
  font-size: 9px;
  font-weight: 700;
  color: #9CA3AF;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.m-score-text {
  font-size: 12.5px;
  font-weight: 800;
  color: #111827;
  white-space: nowrap;
  letter-spacing: 0.02em;
}

/* footer content never wider than the page gutter */
.foot-about,
.foot-col { min-width: 0; }

.foot-about p,
.foot-col a,
.foot-inline a,
.foot-mail,
.foot-copy { overflow-wrap: anywhere; }

/* footer gutters follow the page content gutters on the older pages */
@media (max-width: 991px) {
  .foot-main { padding: 28px var(--page-px) 20px; }
  .foot-middle { padding: 20px var(--page-px); }
  .foot-bottom-inner { padding: 14px var(--page-px) 20px; }
}

/* ---------- blog index cards: 4-up, square, brand button ---------- */

.light-theme .blog-container .bm-article-card,
.blog-container .bm-article-card {
  display: flex;
  flex-direction: column;
  aspect-ratio: 1 / 1;
  height: auto;
  border-radius: 20px;
  overflow: hidden;
  background: #fff;
  border: 1px solid #E3E9E4;
}

.blog-container .bm-article-card:hover {
  transform: translateY(-3px);
  border-color: #CFE6D9;
}

.blog-container .bm-article-img-wrapper {
  flex: 0 0 50%;
  min-height: 0;
  overflow: hidden;
}

.blog-container .bm-article-img {
  height: 100%;
  background-size: cover;
  background-position: center;
}

.blog-container .bm-article-body {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 11px 13px 13px;
}

.blog-container .bm-article-date { font-size: 9px; margin-bottom: 4px; }

.blog-container .bm-article-title {
  font-size: 13px;
  line-height: 1.32;
  margin-bottom: 5px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-container .bm-article-excerpt {
  font-size: 11px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-container .bm-btn-readmore {
  margin-top: auto;
  align-self: flex-start;
  background: #06301F;
  color: #fff;
  font-size: 9.5px;
  letter-spacing: 0.04em;
  padding: 5px 11px;
  border-radius: 999px;
}

.blog-container .bm-btn-readmore:hover {
  background: #0A4029;
  color: #fff;
}

/* ---------- blog index: hero, chips, card grid, sidebar ---------- */

.blog-hero {
  margin: 0;
  width: 100%;
  border-radius: 0;
  padding: 46px 32px 42px;
  text-align: center;
  color: #fff;
  background:
    linear-gradient(180deg, rgba(4, 34, 22, 0.92), rgba(5, 42, 27, 0.88)),
    url('/images/stadium-night.jpg') center/cover no-repeat;
}

.blog-hero-eyebrow {
  margin: 0 0 8px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
}

.blog-hero-title {
  margin: 0;
  font-family: "Outfit", "Segoe UI", system-ui, sans-serif;
  font-size: clamp(26px, 3.6vw, 42px);
  font-weight: 800;
  letter-spacing: -0.015em;
  line-height: 1.1;
  color: #fff;
}

.blog-hero-title span { color: var(--accent); }

.blog-hero-sub {
  max-width: 620px;
  margin: 12px auto 0;
  font-size: 13px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.72);
}

.blog-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 20px; }

.blog-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 999px;
  background: #06301F;
  color: #fff;
  font-size: 11.5px;
  font-weight: 700;
  text-decoration: none;
}

.blog-chip b { font-size: 10px; font-weight: 700; color: var(--accent); }
.blog-chip:hover { color: #fff; opacity: 0.92; }
.blog-chip--all { background: var(--accent); color: var(--accent-ink); }
.blog-chip.is-active { box-shadow: inset 0 0 0 2px var(--accent); }

.blog-search-note { margin: 0 0 16px; font-size: 12.5px; color: #5F7168; }

.blog-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 22px;
  align-items: start;
}

.blog-main {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.blog-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #E3E9E4;
  border-radius: 14px;
  overflow: hidden;
}

/* portrait cards, like the reference: image ~half, copy below */
.blog-card:not(.blog-card--featured) { aspect-ratio: 2 / 3; }

.blog-card-img {
  display: block;
  height: 190px;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  position: relative;
}

.blog-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(6, 48, 31, 0.92);
  color: #fff;
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.blog-card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  padding: 16px;
}

.blog-meta { font-size: 11px; color: #93A49B; }

.blog-card-title {
  margin: 0;
  font-family: "Outfit", "Segoe UI", system-ui, sans-serif;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.32;
}

.blog-card-title a { color: #0D1B16; text-decoration: none; }
.blog-card-title a:hover { color: #06301F; }

.blog-card-excerpt {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.55;
  color: #5F7168;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-card-more {
  margin-top: auto;
  font-size: 12.5px;
  font-weight: 700;
  color: #06301F;
  text-decoration: none;
}

.blog-card-more:hover { color: #0A4029; }

.blog-card--featured { grid-column: span 2; }

.blog-feature {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 340px;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  text-decoration: none;
}

.blog-feature::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(3, 24, 15, 0.15) 35%, rgba(3, 24, 15, 0.92) 100%);
}

.blog-feature-body {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 22px;
  color: #fff;
}

.blog-feature .blog-meta { color: rgba(255, 255, 255, 0.72); }

.blog-feature-title {
  font-family: "Outfit", "Segoe UI", system-ui, sans-serif;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
}

.blog-feature-excerpt { font-size: 12px; line-height: 1.55; color: rgba(255, 255, 255, 0.78); }

.blog-feature-btn {
  align-self: flex-start;
  margin-top: 8px;
  padding: 7px 14px;
  border-radius: 8px;
  background: var(--accent);
  color: #06301F;
  font-size: 11px;
  font-weight: 800;
}

.blog-side { display: flex; flex-direction: column; gap: 18px; }

.blog-search { padding: 16px; border-radius: 14px; background: #06301F; }
.blog-search h3 { margin: 0 0 10px; font-size: 13px; font-weight: 700; color: #fff; }

.blog-search-row { display: flex; border-radius: 8px; overflow: hidden; background: #fff; }

.blog-search-row input {
  flex: 1;
  min-width: 0;
  border: 0;
  padding: 9px 12px;
  font-size: 12px;
  color: #0D1B16;
  outline: none;
}

.blog-search-row button {
  border: 0;
  padding: 0 13px;
  background: var(--accent);
  color: #06301F;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.blog-search-row svg { width: 15px; height: 15px; }

.blog-box { padding: 16px; border-radius: 14px; background: #fff; border: 1px solid #E3E9E4; }
.blog-box h3 { margin: 0 0 12px; font-size: 13px; font-weight: 800; color: #0D1B16; }

.blog-cats { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }

.blog-cats a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 8px;
  background: #06301F;
  color: #fff;
  font-size: 11.5px;
  font-weight: 600;
  text-decoration: none;
}

.blog-cats a:hover { background: #0A4029; color: #fff; }
.blog-cats b { font-size: 11px; font-weight: 700; color: var(--accent); }
.blog-cats a.is-active { box-shadow: inset 0 0 0 2px var(--accent); }

.blog-pop { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.blog-pop a { display: flex; gap: 10px; text-decoration: none; }
.blog-pop img { width: 52px; height: 52px; flex: none; border-radius: 8px; object-fit: cover; }

.blog-pop b {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.35;
  color: #0D1B16;
}

.blog-pop small { display: block; margin-top: 3px; font-size: 9.5px; color: #93A49B; }

.blog-empty { grid-column: 1 / -1; padding: 40px 0; text-align: center; color: #5F7168; font-size: 13px; }
.blog-empty a { color: #06301F; font-weight: 700; }

.blog-pager { display: flex; justify-content: center; margin-top: 26px; }
.blog-pager .pagination { display: flex; gap: 8px; margin: 0; padding: 0; list-style: none; }

.blog-pager .page-item .page-link {
  width: 34px;
  height: 34px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid #E3E9E4;
  border-radius: 50%;
  background: #fff;
  color: #0D1B16;
  font-size: 12px;
  font-weight: 600;
}

.blog-pager .page-item.active .page-link { background: #06301F; border-color: #06301F; color: #fff; }

@media (max-width: 1100px) {
  .blog-layout { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 860px) {
  .blog-main { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .blog-hero { padding: 34px 20px; }
}

@media (max-width: 560px) {
  .blog-main { grid-template-columns: minmax(0, 1fr); }
  .blog-card--featured { grid-column: auto; }
  .blog-feature { min-height: 260px; }
}

/* ---------- article page (SEO structure) ---------- */

.post-intro {
  max-width: 72ch;
  margin: 12px 0 14px;
  font-size: 15.5px;
  line-height: 1.65;
  color: #4B5D54;
}

.post-updated,
.post-read {
  font-size: 11.5px;
  color: #93A49B;
}

.post-figure { margin: 18px 0 24px; }
.post-figure img { width: 100%; height: auto; border-radius: 14px; display: block; }

.post-sources {
  margin: 26px 0 0;
  padding: 18px 20px;
  border: 1px solid #E3E9E4;
  border-radius: 14px;
  background: #FAFCFA;
}

.post-sources h2 { margin: 0 0 10px; font-size: 15px; font-weight: 800; color: #0D1B16; }
.post-sources ol { margin: 0; padding-left: 18px; }
.post-sources li { font-size: 12.5px; line-height: 1.6; color: #5F7168; margin-bottom: 6px; overflow-wrap: anywhere; }
.post-sources a { color: #06301F; text-decoration: underline; text-underline-offset: 2px; }

.post-author-box {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin: 26px 0 0;
  padding: 18px 20px;
  border: 1px solid #E3E9E4;
  border-radius: 14px;
  background: #fff;
}

.post-author-avatar {
  width: 46px;
  height: 46px;
  flex: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #06301F;
  color: #C7F04B;
  font-family: "Outfit", "Segoe UI", system-ui, sans-serif;
  font-size: 18px;
  font-weight: 800;
}

.post-author-name { margin: 0 0 4px; font-size: 13.5px; font-weight: 800; color: #0D1B16; }
.post-author-bio { margin: 0; font-size: 12.5px; line-height: 1.6; color: #5F7168; }

.post-cats { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; }

.post-cats a {
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid #E3E9E4;
  background: #fff;
  font-size: 11.5px;
  font-weight: 600;
  color: #0D1B16;
  text-decoration: none;
}

.post-cats a:hover { background: #F1F9F4; border-color: #CFE6D9; }
.post-cats a.is-active { background: #06301F; border-color: #06301F; color: #fff; }

/* footer: single column when there are only a few popular matches */
.foot-two--single { grid-template-columns: minmax(0, 1fr); }
