/*
Theme Name: Fehérvár Rugby Club
Author: Fehérvár Rugby Club
Version: 1.0
Text Domain: frc
*/

:root {
  --navy-950: #020b1e;
  --navy-900: #03122e;
  --navy-850: #061838;
  --navy-800: #0a2047;
  --burgundy-800: #661025;
  --burgundy-700: #81152c;
  --red-600: #c5223c;
  --red-500: #e02843;
  --blue-500: #287be1;
  --paper: #f4f2ed;
  --muted: #aeb8ca;
  --line: rgba(159, 181, 216, .28);
  --shadow: 0 20px 45px rgba(0, 0, 0, .28);
  --font-display: "Barlow Condensed", Arial Narrow, sans-serif;
  --font-body: "Inter", Arial, sans-serif;
  --header-height: 76px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-height) + 18px); }
body {
  margin: 0;
  color: var(--paper);
  background: var(--navy-900) url("assets/site-texture.png") center top / 760px auto repeat;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: rgba(2, 11, 30, .84);
  pointer-events: none;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
.shell { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.skip-link { position: fixed; top: 8px; left: 8px; z-index: 999; padding: 10px 16px; color: #fff; background: var(--red-600); transform: translateY(-150%); }
.skip-link:focus { transform: none; }

h1, h2, h3, .button, .primary-nav a, .brand-copy, .social-button {
  font-family: var(--font-display);
  text-transform: uppercase;
}
h1, h2, h3, p { margin-top: 0; }
h2 {
  position: relative;
  margin-bottom: 22px;
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 700;
  line-height: .95;
  letter-spacing: .045em;
}
h2::after { content: ""; display: block; width: 54px; height: 3px; margin-top: 12px; background: var(--red-500); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-height);
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: rgba(2, 11, 30, .96);
  backdrop-filter: blur(12px);
}
.header-inner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; min-height: 100%; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 12px; min-width: max-content; }
.brand-mark, .mini-logo, .post-avatar, .leader-logo, .tax-watermark {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  border: 3px solid var(--red-500);
  background: #fff;
  color: var(--navy-900);
  font: 800 13px var(--font-display);
}
.brand-mark { width: 62px; height: 62px; }
.brand-mark img, .mini-logo img, .post-avatar img, .leader-logo img, .tax-watermark img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; z-index: 2; }
.brand-copy strong { display: block; font-size: 21px; line-height: .8; letter-spacing: .07em; }
.brand-copy small { display: block; margin-top: 7px; color: var(--red-500); font-size: 13px; font-weight: 700; letter-spacing: .12em; }
.primary-nav {
  display: flex;
  justify-content: center;
  align-self: stretch;
}

/* WordPress adds a <ul> and <li> structure around menu links. */
.primary-nav ul {
  display: flex;
  align-items: stretch;
  height: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}

.primary-nav li {
  display: flex;
  align-items: stretch;
  margin: 0;
  padding: 0;
}

.primary-nav a {
  position: relative;
  display: flex;
  align-items: center;
  padding: 0 12px;
  color: #dce2ed;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: .04em;
  white-space: nowrap;
}

.primary-nav a::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 13px;
  height: 3px;
  background: var(--red-500);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .2s ease;
}

.primary-nav a:hover,
.primary-nav a.active,
.primary-nav .current-menu-item > a,
.primary-nav .current_page_item > a,
.primary-nav .current-menu-ancestor > a,
.primary-nav .current_page_ancestor > a {
  color: #fff;
}

.primary-nav a:hover::after,
.primary-nav a.active::after,
.primary-nav .current-menu-item > a::after,
.primary-nav .current_page_item > a::after,
.primary-nav .current-menu-ancestor > a::after,
.primary-nav .current_page_ancestor > a::after {
  transform: scaleX(1);
}

/* Desktop dropdown navigation */
.primary-nav li {
  position: relative;
}

.primary-nav .menu-item-has-children > a {
  padding-right: 30px;
}

.primary-nav .menu-item-has-children > a::before {
  content: "▾";
  position: absolute;
  right: 11px;
  top: 50%;
  transform: translateY(-52%);
  color: var(--muted);
  font-size: 11px;
  line-height: 1;
  transition: transform .2s ease, color .2s ease;
}

.primary-nav .menu-item-has-children:hover > a::before,
.primary-nav .menu-item-has-children:focus-within > a::before {
  transform: translateY(-52%) rotate(180deg);
  color: #fff;
}

.primary-nav .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 250;

    display: flex;
    flex-direction: column;
    align-items: stretch;

    width: max-content;
    min-width: 0;
    height: auto;

    margin: 0;
    padding: 6px 0;

    border: 1px solid rgba(159, 181, 216, .24);
    background: rgba(2, 11, 30, .99);
    box-shadow: 0 18px 40px rgba(0, 0, 0, .38);

    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    pointer-events: none;

    transition:
        opacity .18s ease,
        transform .18s ease,
        visibility .18s ease;
}

.primary-nav .menu-item-has-children > a[href="#"] {
    cursor: default;
}

.primary-nav li:hover > .sub-menu,
.primary-nav li:focus-within > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.primary-nav .sub-menu li {
  display: block;
  width: 100%;
}

.primary-nav .sub-menu a {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 46px;
  padding: 10px 18px;
  color: #d7deea;
  font-size: 14px;
  line-height: 1.2;
  white-space: nowrap;
}

.primary-nav .sub-menu a::after {
  display: none;
}

.primary-nav .sub-menu a:hover,
.primary-nav .sub-menu .current-menu-item > a,
.primary-nav .sub-menu .current_page_item > a {
  color: #fff;
  background: rgba(224, 40, 67, .14);
}

.primary-nav .sub-menu .current-menu-item > a,
.primary-nav .sub-menu .current_page_item > a {
  box-shadow: inset 3px 0 0 var(--red-500);
}
.header-actions { display: flex; align-items: center; gap: 16px; }
.header-socials { position: absolute; top: 28px; right: max(24px, calc((100vw - 900px) / 2)); display: flex; gap: 14px; font-size: 13px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 28px; border: 1px solid rgba(255,255,255,.18); background: linear-gradient(135deg, var(--burgundy-700), var(--red-600)); color: #fff; font-weight: 700; letter-spacing: .08em; transition: transform .2s, filter .2s; }
.button:hover { transform: translateY(-2px); filter: brightness(1.12); }
.button-small { min-height: 40px; padding: 0 22px; font-size: 15px; }
.nav-toggle { display: none; width: 46px; height: 42px; padding: 10px; border: 1px solid var(--line); background: transparent; }
.nav-toggle span { display: block; height: 2px; margin: 5px 0; background: #fff; transition: .2s; }

.hero { position: relative; min-height: min(560px, 72vh); display: grid; align-items: end; overflow: hidden; background: var(--navy-950); }
.hero-collage { position: absolute; inset: 0; display: grid; grid-template-columns: 1.18fr 1.12fr 1fr 1fr .98fr; gap: 4px; transform: scale(1.03); }
.hero-panel { min-height: 100%; clip-path: polygon(12% 0,100% 0,88% 100%,0 100%); }
.hero-panel:first-child { clip-path: polygon(0 0,100% 0,88% 100%,0 100%); }
.hero-panel:last-child { clip-path: polygon(12% 0,100% 0,100% 100%,0 100%); }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(1,8,24,.04) 15%, rgba(3,18,46,.12) 36%, rgba(3,18,46,.82) 70%, rgba(108,11,34,.94) 100%); }
.hero-overlay::after { content: ""; position: absolute; inset: auto 0 0; height: 110px; opacity: .28; background: repeating-linear-gradient(165deg, transparent 0 14px, rgba(235,39,67,.7) 15px 17px); clip-path: polygon(0 45%,15% 25%,30% 66%,46% 30%,62% 70%,78% 25%,100% 58%,100% 100%,0 100%); }
.hero-content { position: relative; z-index: 2; padding-block: 130px 38px; text-align: center; }
.hero h1 { max-width: 1000px; margin: 0 auto 10px; font-size: clamp(3rem, 7vw, 6.8rem); font-weight: 700; line-height: .84; letter-spacing: .015em; text-shadow: 0 4px 20px rgba(0,0,0,.75); }
.hero p { margin-bottom: 20px; color: #e8e8ea; font-size: clamp(.95rem, 1.5vw, 1.15rem); }
.hero-buttons { display: flex; justify-content: center; gap: 16px; }
.social-button { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-width: 180px; padding: 12px 22px; font-size: 18px; font-weight: 600; letter-spacing: .08em; box-shadow: var(--shadow); }
.social-button.facebook { background: #285fa5; }
.social-button.instagram { background: linear-gradient(135deg, #a52053, #d73545); }

.section { padding-block: 44px; }
.facebook-feed { background: rgba(3,18,46,.92); border-bottom: 1px solid rgba(224,40,67,.4); }
.feed-heading { display: flex; align-items: center; justify-content: space-between; gap: 30px; margin-bottom: 20px; }
.feed-heading h2 { margin-bottom: 6px; font-size: clamp(1.8rem, 3vw, 2.55rem); }
.feed-heading h2::after { display: none; }
.feed-heading p { margin: 0; color: var(--muted); }
.page-plugin-brand { display: flex; align-items: center; gap: 12px; white-space: nowrap; }
.page-plugin-brand > i { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: #1877f2; }
.mini-logo { width: 44px; height: 44px; }
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; padding: 0; margin-block: 0; list-style: none; }
.post-card { display: flex; min-width: 0; flex-direction: column; border: 1px solid var(--line); background: linear-gradient(180deg, rgba(10,32,71,.92), rgba(3,18,46,.96)); box-shadow: 0 14px 28px rgba(0,0,0,.18); }
.post-header { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 9px; padding: 10px; }
.post-avatar { width: 36px; height: 36px; border-width: 2px; font-size: 9px; }
.post-header span:nth-child(2) { display: grid; }
.post-header strong { font-size: .78rem; }
.post-header small { color: var(--muted); font-size: .69rem; }
.post-header > i { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #1877f2; }
.post-image { aspect-ratio: 1.25; border-block: 1px solid var(--line); }
.post-body { display: flex; flex: 1; flex-direction: column; padding: 12px; }
.post-body h3 { margin-bottom: 7px; font: 600 .92rem/1.3 var(--font-body); text-transform: none; }
.post-body p { margin-bottom: 8px; color: var(--muted); font-size: .73rem; }
.post-body footer { display: flex; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 12px; color: #ccd4e2; font-size: .72rem; }
.post-actions { display: flex; align-items: center; gap: 12px; }
.post-actions i:first-child { color: #3b91ff; }

.history { background: linear-gradient(180deg, rgba(2,11,30,.18), rgba(3,18,46,.38)); }
.history-grid { display: grid; grid-template-columns: .78fr 1.55fr; gap: 30px; align-items: stretch; }
.history-copy { padding-top: 6px; }
.history-copy > p { color: #c3ccda; font-size: .96rem; }
blockquote { position: relative; margin: 26px 0 0; padding: 22px 24px 20px 54px; border: 1px solid rgba(224,40,67,.65); background: linear-gradient(135deg, var(--burgundy-800), #8e1932); box-shadow: var(--shadow); }
blockquote > i { position: absolute; top: 23px; left: 20px; color: #f26a7f; font-size: 24px; }
blockquote p { margin-bottom: 12px; }
blockquote cite { color: #f0c8cf; font-style: normal; font-size: .88rem; }
.history-photo {
    width: 100%;
    height: 430px;
    min-height: 0;
    border: 1px solid var(--line);
    overflow: hidden;
    background: #020b1e;
}

.history-photo img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: contain;
    object-position: center center;
}
.milestones { display: grid; grid-template-columns: repeat(5, 1fr); margin-top: 26px; margin-bottom: 0; padding: 0; border: 1px solid var(--line); background: rgba(3,18,46,.7); list-style: none; }
.milestone { position: relative; display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 2px 14px; min-height: 116px; padding: 18px 20px; }
.milestone:not(:last-child)::after { content: ""; position: absolute; top: 24px; right: 0; bottom: 24px; width: 2px; background: var(--red-600); }
.milestone i { grid-row: 1 / 3; color: var(--red-500); font-size: 38px; }
.milestone strong { font: 700 2.1rem/1 var(--font-display); }
.milestone span { color: #cad2df; font: 500 .85rem/1.15 var(--font-display); text-transform: uppercase; }

.training { padding-top: 0; }
.two-panel-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.panel { border: 1px solid var(--line); background: rgba(5,24,56,.78); padding: 22px 24px; }
.panel h2 { margin-bottom: 16px; font-size: 2.35rem; }
.schedule-table > div { display: grid; grid-template-columns: 28px minmax(120px, .9fr) 1.25fr auto; align-items: center; gap: 10px; min-height: 45px; border-top: 1px solid rgba(255,255,255,.12); }
.schedule-table i, .coach > i { color: #fff; text-align: center; }
.schedule-table strong { font: 600 1.05rem var(--font-display); text-transform: uppercase; letter-spacing: .03em; }
.schedule-table span, .schedule-table time { color: var(--muted); font: 500 .92rem var(--font-display); text-transform: uppercase; }
.coach-list { display: grid; }
.coach { display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 5px 10px; padding: 8px 0; border-top: 1px solid rgba(255,255,255,.11); }
.coach strong { grid-column: 2; font-size: .91rem; }
.coach > a { display: inline-flex; align-items: center; gap: 7px; color: #c1cada; font-size: .75rem; }
.coach > a i { color: var(--red-500); }
.coach > a:last-child:not(:nth-child(3)) { grid-column: 3; }

.teams { padding-top: 0; }
.teams .shell > h2 { display: flex; align-items: center; gap: 20px; margin-bottom: 18px; }
.teams .shell > h2::after { flex: 1; width: auto; height: 1px; margin: 5px 0 0; background: var(--line); }
.team-grid { display: grid; grid-template-columns: 1.55fr repeat(4, 1fr); gap: 10px; }
.team-card { display: flex; min-width: 0; flex-direction: column; border: 1px solid var(--line); background: linear-gradient(180deg, rgba(7,27,61,.95), rgba(93,11,31,.96)); overflow: hidden; }
.team-photo { aspect-ratio: 1.1; }
.team-info { flex: 1; min-height: 132px; padding: 14px; background: linear-gradient(155deg, #73132a, #9b1c35); }
.team-info h3 { margin: 0 0 8px; font-size: 1.55rem; line-height: .95; text-align: center; }
.team-info > strong { display: block; font: 600 .9rem/1.15 var(--font-display); text-align: center; text-transform: uppercase; }
.team-info p { margin: 12px 0 0; color: #f0d5da; font-size: .76rem; text-align: center; }
.results-list { padding: 0; margin: 9px 0 0; list-style: none; color: #f4dce1; font: 500 .8rem/1.35 var(--font-display); }
.results-list span { display: inline-block; width: 70px; }

.information { padding-top: 0; }
.documents ul { padding: 0; margin: 0; list-style: none; }
.documents li { border-top: 1px solid rgba(255,255,255,.1); }
.documents a { display: flex; justify-content: space-between; gap: 20px; padding: 7px 0; color: #c5cedc; font-size: .85rem; }
.documents a:hover { color: #fff; }
.documents i { color: var(--red-500); }
.tax-panel { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 22px; overflow: hidden; border: 1px solid #bd2942; padding: 24px 28px; background: radial-gradient(circle at 85% 50%, rgba(188,39,66,.25), transparent 33%), linear-gradient(135deg, #6b1026, #931a31); }
.tax-panel h2 { margin-bottom: 14px; }
.tax-panel strong { display: block; margin-bottom: 15px; font-family: var(--font-display); text-transform: uppercase; }
.tax-panel p { max-width: 400px; color: #f2d9de; }
.tax-panel small { display: block; font: 600 .8rem var(--font-display); text-transform: uppercase; }
.tax-panel div > b { display: block; font: 700 2.2rem var(--font-display); letter-spacing: .06em; }
.tax-watermark { flex: 0 0 150px; width: 150px; height: 150px; opacity: .36; }

.site-footer { padding: 28px 0 15px; border-top: 2px solid var(--red-600); background: rgba(2,11,30,.9); }
.footer-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 40px; align-items: center; }
.site-footer h2 { margin-bottom: 16px; }
.site-footer address { color: #bec8d7; font-style: normal; }
.site-footer address p { display: flex; gap: 12px; align-items: center; margin: 7px 0; }
.site-footer address i, .leader-card a i { width: 18px; color: var(--red-500); text-align: center; }
.leader-card { display: grid; grid-template-columns: 140px 1fr; gap: 24px; align-items: center; border: 1px solid var(--line); padding: 18px 24px; background: rgba(7,27,61,.65); }
.leader-logo { width: 120px; height: 120px; }
.leader-card small { color: var(--red-500); font: 700 1.05rem var(--font-display); text-transform: uppercase; letter-spacing: .05em; }
.leader-card h2 { margin: 4px 0 10px; }
.leader-card h2::after { display: none; }
.leader-card a { display: flex; gap: 10px; margin: 6px 0; color: #d5dbe5; }
.copyright { padding-top: 16px; color: #8995a8; font-size: .75rem; text-align: center; }

.media { position: relative; overflow: hidden; background: linear-gradient(135deg, rgba(14,47,96,.85), rgba(98,15,38,.9)); background-position: center; background-size: cover; }
.media::before { content: attr(data-label); position: absolute; inset: 0; display: grid; place-items: center; padding: 18px; color: rgba(255,255,255,.58); font: 700 1.15rem var(--font-display); text-transform: uppercase; letter-spacing: .08em; text-align: center; background: repeating-linear-gradient(135deg, rgba(255,255,255,.025) 0 12px, transparent 12px 24px); }
.media.loaded::before { opacity: 0; }
.media.loaded { background-image: var(--image); }

@media (max-width: 1120px) {
  :root { --header-height: 70px; }
  .primary-nav a { padding-inline: 8px; font-size: 13px; }
  .primary-nav a::after { left: 8px; right: 8px; }
  .brand-mark { width: 54px; height: 54px; }
  .brand-copy strong { font-size: 18px; }
  .header-socials { display: none; }
  .post-grid { gap: 12px; }
  .team-grid { grid-template-columns: 1.4fr repeat(2, 1fr); }
  .team-card:nth-child(4), .team-card:nth-child(5) { grid-column: span 1; }
  .milestone { padding-inline: 12px; }
}

@media (max-width: 900px) {
  .shell { width: min(100% - 32px, 760px); }
  .site-header { height: var(--header-height); }
  .header-inner { grid-template-columns: 1fr auto; gap: 14px; }
  .nav-toggle { display: block; z-index: 3; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .primary-nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    display: block;
    height: calc(100dvh - var(--header-height));
    padding: 0;
    background: rgba(2,11,30,.985);
    transform: translateX(100%);
    transition: transform .25s ease;
    overflow-y: auto;
  }

  .primary-nav.open { transform: none; }

  .primary-nav ul {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    height: auto;
    margin: 0;
    padding: 18px 20px 30px;
  }

  .primary-nav li {
    display: block;
    width: 100%;
  }

  .primary-nav a {
    display: flex;
    align-items: center;
    min-height: 54px;
    padding: 0 8px;
    border-bottom: 1px solid var(--line);
    font-size: 19px;
  }

  .primary-nav a::after {
    left: 8px;
    right: 8px;
    bottom: 0;
  }

  /* Mobile submenu */
  .primary-nav .menu-item-has-children > a {
    padding-right: 34px;
  }

  .primary-nav .menu-item-has-children > a::before {
    right: 10px;
    color: var(--red-500);
    transform: translateY(-52%);
  }

  .primary-nav .menu-item-has-children:hover > a::before,
  .primary-nav .menu-item-has-children:focus-within > a::before {
    transform: translateY(-52%);
  }

  .primary-nav .sub-menu {
    position: static;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    min-width: 0;
    height: auto;
    margin: 0;
    padding: 4px 0 10px 18px;
    border: 0;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, .025);
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    pointer-events: auto;
  }

  .primary-nav .sub-menu li {
    width: 100%;
  }

  .primary-nav .sub-menu a {
    min-height: 46px;
    padding: 0 12px;
    border-bottom: 0;
    border-left: 2px solid rgba(224, 40, 67, .45);
    color: #b9c4d5;
    font-size: 16px;
    white-space: normal;
  }

  .primary-nav .sub-menu a:hover,
  .primary-nav .sub-menu .current-menu-item > a,
  .primary-nav .sub-menu .current_page_item > a {
    color: #fff;
    background: rgba(224, 40, 67, .10);
  }

  .primary-nav .sub-menu .current-menu-item > a,
  .primary-nav .sub-menu .current_page_item > a {
    border-left-color: var(--red-500);
    box-shadow: none;
  }
  .header-actions { display: none; }
  .hero { min-height: 620px; }
  .hero-collage { grid-template-columns: repeat(6, 1fr); grid-template-rows: 1fr 1fr; transform: none; }
  .hero-panel { clip-path: none !important; grid-column: span 2; }
  .hero-panel:nth-child(1), .hero-panel:nth-child(2) { grid-column: span 3; }
  .hero-content { padding-bottom: 42px; }
  .feed-heading { align-items: flex-start; flex-direction: column; }
  .page-plugin-brand { width: 100%; flex-wrap: wrap; }
  .post-grid { display: flex; margin-inline: -16px; padding: 0 16px 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-color: var(--red-600) transparent; }
  .post-card { flex: 0 0 min(78vw, 360px); scroll-snap-align: start; }
  .history-grid, .two-panel-grid, .footer-grid { grid-template-columns: 1fr; }
  .history-photo { height: 430px; min-height: 0; }
  .milestones { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; }
  .milestone { flex: 0 0 210px; scroll-snap-align: start; }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .team-card.featured { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; }
  .tax-panel { min-height: 300px; }
  .leader-card { grid-template-columns: 110px 1fr; }
  .leader-logo { width: 96px; height: 96px; }
}

@media (max-width: 620px) {
  body { font-size: 15px; }
  .shell { width: min(100% - 24px, 520px); }
  .brand-copy strong { font-size: 16px; }
  .brand-copy small { font-size: 11px; }
  .brand-mark { width: 50px; height: 50px; }
  .hero { min-height: 650px; }
  .hero-collage { grid-template-columns: 1fr 1fr; grid-template-rows: repeat(3, 1fr); opacity: .78; }
  .hero-panel { grid-column: auto !important; }
  .hero-panel:last-child { grid-column: 1 / -1 !important; }
  .hero-content { padding-top: 200px; }
  .hero h1 { font-size: clamp(3rem, 15vw, 4.7rem); line-height: .87; }
  .hero-buttons { align-items: stretch; flex-direction: column; max-width: 280px; margin-inline: auto; }
  .section { padding-block: 34px; }
  .page-plugin-brand strong { width: calc(100% - 105px); }
  .page-plugin-brand .button { width: 100%; }
  .history-photo { height: 260px; min-height: 0; }
  .schedule-table > div { grid-template-columns: 26px 1fr auto; padding-block: 8px; }
  .schedule-table span { grid-column: 2 / 4; font-size: .78rem; }
  .schedule-table time { grid-column: 3; grid-row: 1; }
  .coach { grid-template-columns: 22px 1fr; padding: 11px 0; }
  .coach strong { grid-column: 2; }
  .coach > a, .coach > a:last-child:not(:nth-child(3)) { grid-column: 2; }
  .team-grid { grid-template-columns: 1fr; }
  .team-card.featured { display: flex; grid-column: auto; }
  .team-photo { aspect-ratio: 1.45; }
  .tax-panel { align-items: flex-start; min-height: 330px; }
  .tax-watermark { position: absolute; right: -12px; bottom: -20px; width: 160px; height: 160px; }
  .leader-card { grid-template-columns: 1fr; text-align: center; }
  .leader-logo { margin-inline: auto; }
  .leader-card a { justify-content: center; word-break: break-word; }
  .matches-year-nav {
    overflow-x: auto;
}

.matches-year-nav .shell {
    width: max-content;
    min-width: 100%;
}

.matches-year-nav ul {
    width: max-content;
    min-width: 100%;
}

.matches-year-nav a {
    min-width: 78px;
    height: 50px;
    padding-inline: 16px;
    font-size: 17px;
}
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

/* =====================================================
   MATCHES YEAR NAVIGATION
===================================================== */

.matches-year-nav {
    border-bottom: 1px solid var(--line);
    background: rgba(2, 11, 30, .96);
}

.matches-year-nav ul {
    display: flex;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
}

.matches-year-nav li {
    margin: 0;
}

.matches-year-nav a {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 90px;
    height: 54px;
    padding: 0 22px;

    color: var(--muted);

    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 700;
    letter-spacing: .06em;

    transition:
        color .2s ease,
        background .2s ease;
}

.matches-year-nav a:hover {
    color: #fff;
    background: rgba(255, 255, 255, .04);
}

.matches-year-nav a.active {
    color: #fff;
    background: rgba(224, 40, 67, .08);
}

.matches-year-nav a.active::after {
    content: "";
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 0;
    height: 3px;
    background: var(--red-500);
}

/* =====================================================
   MATCH RESULTS
===================================================== */

.matches-list {
    display: grid;
    gap: 12px;
}

.match-row {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(230px, .9fr) minmax(180px, 1fr) 58px;
    align-items: center;
    gap: 18px;

    min-height: 118px;
    padding: 18px 20px;

    border: 1px solid var(--line);
    background:
        linear-gradient(
            135deg,
            rgba(7, 27, 61, .92),
            rgba(3, 18, 46, .96)
        );

    box-shadow: 0 10px 24px rgba(0, 0, 0, .16);
}


/* Teams */

.match-team {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.match-team img {
    width: 58px;
    height: 58px;
    flex: 0 0 58px;
    object-fit: contain;
}

.match-team strong {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.05;
    text-transform: uppercase;
}

.away-team {
    flex-direction: row-reverse;
    text-align: right;
}


/* Central score */

.match-main {
    text-align: center;
}

.match-main time {
    display: block;
    margin-bottom: 5px;

    color: var(--muted);
    font-size: .78rem;
    font-weight: 600;
    text-transform: uppercase;
}

.match-score {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 9px;

    margin-bottom: 5px;

    font-family: var(--font-display);
    font-weight: 700;
}

.match-score span {
    font-size: 2.4rem;
    line-height: 1;
}

.match-score b {
    color: var(--red-500);
    font-size: 1.4rem;
}

.match-main small {
    display: block;
    color: #c2cada;
    font-size: .72rem;
}


/* PDF / match report */

.match-report {
    display: grid;
    place-items: center;

    width: 46px;
    height: 46px;

    border: 1px solid rgba(224, 40, 67, .55);
    background: rgba(224, 40, 67, .1);
    color: var(--red-500);

    font-size: 22px;

    transition:
        background .2s ease,
        color .2s ease,
        transform .2s ease;
}

.match-report:hover {
    background: var(--red-600);
    color: #fff;
    transform: translateY(-2px);
}


/* Mobile */

@media (max-width: 760px) {

    .match-row {
        grid-template-columns: 1fr auto 1fr;
        gap: 10px;
        padding: 16px 12px;
    }

    .match-main {
        grid-column: 2;
        grid-row: 1;
    }

    .home-team {
        grid-column: 1;
        grid-row: 1;
        flex-direction: column;
        text-align: center;
    }

    .away-team {
        grid-column: 3;
        grid-row: 1;
        flex-direction: column;
        text-align: center;
    }

    .match-team img {
        width: 48px;
        height: 48px;
        flex-basis: 48px;
    }

    .match-team strong {
        font-size: .9rem;
    }

    .match-score span {
        font-size: 2rem;
    }

    .match-main small {
        display: none;
    }

    .match-report {
        grid-column: 1 / -1;
        grid-row: 2;

        width: 100%;
        height: 38px;
        margin-top: 5px;
    }
}

