/*
Theme Name: cbcv2
Theme URI: https://camdenbowlingclub.com.au/
Author: Geekheads
Author URI: https://geekheads.au/
Description: Camden Bowling Club v2. Magazine-style theme for Camden Bowling Club, in the style of the Papr news template, in bowling-green colours. Lightweight: no jQuery, Bootstrap or slider plugin.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 8.0
Text Domain: cbcv2
*/

/* ===== Brand: change these to restyle the whole site ===== */
:root {
  --font: 'Roboto', 'Helvetica Neue', Arial, sans-serif;
  --font-head: 'Poppins', 'Roboto', Arial, sans-serif;
  --bg: #ffffff;
  --ink: #111a14;
  --body: #46514a;
  --muted: #5f6b63;
  --line: #e2e8e3;
  --soft: #f4f7f4;
  --brand: #17803d;        /* bowling green */
  --brand-hover: #116331;
  --brand-ink: #ffffff;
  --accent: #f5c518;       /* jack yellow */
  --tint: #e8f5ec;
  --dark: #0d2418;         /* deep green for top bar and footer */
  --radius: 12px;
  --btn-radius: 22px;
  --wrap: 1240px;

  /* Category colours */
  --c-events: #1d4ed8;
  --c-pennants: #0369a1;
  --c-draws: #c2410c;
  --c-champions: #a16207;
  --c-membership: #6d28d9;
  --c-gallery: #be185d;
  --c-newsletters: #0f766e;
  --c-honour: #92400e;
  --c-about: #475569;
  --c-sponsors: #17803d;
}

/* ===== Base ===== */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--body); font: 16px/1.65 var(--font); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); }
a:hover { color: var(--brand-hover); }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); font-weight: 600; line-height: 1.25; letter-spacing: -0.01em; }
h1 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); margin: .2em 0 .5em; }
h2 { font-size: 1.45rem; margin: 1.6em 0 .6em; }
h3 { font-size: 1.15rem; margin: 1.4em 0 .5em; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip:focus { top: 12px; color: #fff; }
.meta { color: var(--muted); font-size: .85rem; margin: 6px 0 0; }
.meta .views::before { content: '·'; margin: 0 7px; }
.empty { padding: 30px; background: var(--soft); border-radius: var(--radius); }

/* ===== Buttons ===== */
.btn { display: inline-block; background: var(--brand); color: var(--brand-ink) !important; border: 0; border-radius: var(--btn-radius);
  padding: 11px 24px; font: 500 .95rem/1.2 var(--font-head); text-decoration: none; cursor: pointer; transition: background .2s; }
.btn:hover { background: var(--brand-hover); }

/* ===== Top bar ===== */
.topbar { background: var(--dark); color: #b9c7bd; font-size: .82rem; }
.topbar-in { display: flex; justify-content: space-between; align-items: center; gap: 8px 16px; min-height: 38px; flex-wrap: wrap; }
.topbar a { color: #dfe8e2; text-decoration: none; }
.topbar a:hover { color: #fff; text-decoration: underline; }
.topbar-links { display: flex; gap: 20px; }
.topbar-links .hi { color: var(--accent); font-weight: 500; }

/* ===== Header ===== */
.top { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 2px 8px rgb(0 0 0 / .04); }
.top-in { display: flex; align-items: center; flex-wrap: wrap; gap: 0 24px; min-height: 76px; }
.top-in > .brand { padding: 14px 0; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); flex-shrink: 0; }
.logo { display: inline-flex; flex-shrink: 0; }
.logo img { width: 52px; height: 52px; object-fit: contain; }
.pfoot .logo img { width: 44px; height: 44px; }
.brand-text { display: grid; line-height: 1.1; }
.brand-name { font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; letter-spacing: -0.02em; }
.brand-sub { font-size: .72rem; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; margin-top: 3px; }

.mainnav { display: flex; align-items: center; gap: 18px; flex: 1 1 100%; justify-content: space-between; border-top: 1px solid var(--line); }
.mainnav .menu { list-style: none; margin: 0 0 0 -9px; padding: 0; display: flex; gap: 2px; flex-wrap: wrap; }
.mainnav .menu > li { position: relative; display: flex; align-items: center; }
.mainnav .menu a { display: block; color: var(--ink); text-decoration: none; font: 500 .95rem/1.2 var(--font-head); padding: 15px 10px 13px; border-bottom: 3px solid transparent; }
.mainnav .menu > li > a:hover,
.mainnav .menu > li.current-menu-item > a,
.mainnav .menu > li.current-menu-ancestor > a { color: var(--brand); border-bottom-color: var(--brand); }
.subtoggle { width: 18px; height: 30px; margin-left: -6px; padding: 0; border: 0; background: none; cursor: pointer; color: var(--muted); }
.subtoggle::before { content: ''; display: block; width: 7px; height: 7px; margin: 0 auto; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg) translateY(-2px); transition: transform .2s; }
.sub-open > .subtoggle::before { transform: rotate(-135deg); }
.mainnav .sub-menu { list-style: none; margin: 0; padding: 8px; position: absolute; top: 100%; left: 0; min-width: 220px; background: #fff;
  border: 1px solid var(--line); border-top: 3px solid var(--brand); border-radius: 0 0 var(--radius) var(--radius); box-shadow: 0 14px 30px rgb(0 0 0 / .1);
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .15s, transform .15s, visibility .15s; z-index: 60; }
.mainnav .sub-menu a { padding: 9px 12px; border-radius: 8px; font-weight: 400; }
.mainnav .sub-menu a:hover { background: var(--tint); color: var(--brand); }
.mainnav .sub-menu .sub-menu { top: -8px; left: 100%; border-radius: var(--radius); }
.mainnav li:hover > .sub-menu, .mainnav li.sub-open > .sub-menu, .mainnav li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }

.hsearch { margin-left: auto; }
.hsearch input { width: 220px; padding: 9px 16px; border: 1px solid var(--line); border-radius: 99px; background: var(--soft); font: inherit; font-size: .9rem; color: var(--ink); }
.hsearch input:focus { outline: none; border-color: var(--brand); background: #fff; }
.navsearch { display: none; }
.navsearch input { width: 150px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 99px; background: var(--soft); font: inherit; font-size: .9rem; color: var(--ink); transition: width .2s, border-color .2s; }
.navsearch input:focus { width: 190px; outline: none; border-color: var(--brand); background: #fff; }

.navtoggle { display: none; margin-left: auto; align-items: center; gap: 8px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 99px; background: #fff; font: 500 .9rem var(--font-head); color: var(--ink); cursor: pointer; }
.navtoggle-bars, .navtoggle-bars::before, .navtoggle-bars::after { display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px; position: relative; transition: transform .2s, background .2s; }
.navtoggle-bars::before, .navtoggle-bars::after { content: ''; position: absolute; left: 0; }
.navtoggle-bars::before { top: -6px; } .navtoggle-bars::after { top: 6px; }
.navtoggle[aria-expanded="true"] .navtoggle-bars { background: transparent; }
.navtoggle[aria-expanded="true"] .navtoggle-bars::before { transform: translateY(6px) rotate(45deg); }
.navtoggle[aria-expanded="true"] .navtoggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1100px) {
  .top-in { min-height: 64px; gap: 12px; flex-wrap: nowrap; }
  .top-in > .brand { padding: 10px 0; }
  .mainnav { border-top: 0; }
  .navtoggle { display: inline-flex; }
  .mainnav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: 0 14px 30px rgb(0 0 0 / .1); flex-direction: column; align-items: stretch; padding: 8px 20px 20px; max-height: calc(100vh - 100px); overflow-y: auto; }
  .mainnav.open { display: flex; }
  .mainnav .menu { flex-direction: column; flex-wrap: nowrap; }
  .mainnav .menu > li { flex-wrap: wrap; border-bottom: 1px solid var(--line); }
  .mainnav .menu > li > a { flex: 1; padding: 14px 4px; border: 0; }
  .subtoggle { width: 44px; height: 44px; margin: 0; }
  .mainnav .sub-menu { position: static; display: none; flex-basis: 100%; min-width: 0; border: 0; box-shadow: none; opacity: 1; visibility: visible; transform: none; padding: 0 0 10px 12px; }
  .mainnav li:hover > .sub-menu, .mainnav li:focus-within > .sub-menu { display: none; }
  .mainnav li.sub-open > .sub-menu { display: block; }
  .hsearch { display: none; }
  .navsearch { display: block; }
  .navsearch input, .navsearch input:focus { width: 100%; margin-top: 14px; }
}
@media (max-width: 600px) {
  .brand-name { font-size: 1.08rem; }
  .brand-sub { font-size: .65rem; }
  .logo img { width: 40px; height: 40px; }
  .topbar-left { display: none; }
  .topbar-in { justify-content: center; }
  .topbar-links { gap: 16px; }
  .navtoggle-label { display: none; }
}

/* ===== Category pills ===== */
.pill { display: inline-block; padding: 3px 10px; border-radius: 7px; color: #fff; background: var(--brand); text-decoration: none;
  font: 600 .68rem/1.6 var(--font-head); letter-spacing: .05em; text-transform: uppercase; }
a.pill:hover { color: #fff; filter: brightness(1.1); }
.pill-events { background: var(--c-events); }
.pill-pennants { background: var(--c-pennants); }
.pill-draws-results { background: var(--c-draws); }
.pill-champions { background: var(--c-champions); }
.pill-membership { background: var(--c-membership); }
.pill-gallery { background: var(--c-gallery); }
.pill-newsletters { background: var(--c-newsletters); }
.pill-honour-boards { background: var(--c-honour); }
.pill-about { background: var(--c-about); }
.pill-sponsors, .pill-camden-bowling-club { background: var(--c-sponsors); }

/* ===== Section headings (Papr underline bar) ===== */
.msec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin: 44px 0 22px; border-bottom: 1px solid var(--line); }
.msec-title { font-size: 1.4rem; margin: 0 0 -1px; padding-bottom: 12px; border-bottom: 3px solid var(--brand); }
.msec-head a { color: var(--ink); font: 500 .9rem var(--font-head); text-decoration: none; padding-bottom: 14px; white-space: nowrap; }
.msec-head a:hover { color: var(--brand); }

/* ===== Cards ===== */
.grid { display: grid; gap: 30px 24px; }
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); }
.grid-6 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 170px), 1fr)); }
.card { position: relative; display: flex; flex-direction: column; }
.card .thumb { display: block; aspect-ratio: 4 / 3; border-radius: var(--radius); overflow: hidden; background: var(--soft); }
.card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .thumb img { transform: scale(1.05); }
.card-pill { margin-top: -14px; padding-left: 12px; position: relative; z-index: 1; min-height: 14px; }
.card h3 { font-size: 1.04rem; font-weight: 600; margin: 10px 0 0; line-height: 1.35; }
.card h3 a { color: var(--ink); text-decoration: none; transition: color .2s; }
.card h3 a::after { content: ''; position: absolute; inset: 0; }   /* whole card clickable */
.card:hover h3 a { color: var(--brand); }
.card .pill { position: relative; z-index: 2; }
.card .excerpt { margin: 6px 0 0; font-size: .9rem; color: var(--muted); }
.grid-6 .card h3 { font-size: .95rem; }

/* ===== Homepage hero ===== */
.mhero { display: grid; grid-template-columns: 1fr; gap: 28px; margin: 28px 0 0; }
@media (min-width: 900px) { .mhero { grid-template-columns: 1.75fr 1fr; } }
.mfeature { position: relative; display: block; border-radius: var(--radius); overflow: hidden; min-height: 420px; background: var(--dark); color: #fff; text-decoration: none; }
.mfeature img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.mfeature:hover img { transform: scale(1.04); }
.mfeature::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(0 0 0 / 0) 35%, rgb(5 20 12 / .88) 100%); }
.mfeature-text { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 30px; display: grid; gap: 10px; justify-items: start; }
.mfeature-text strong { font: 600 clamp(1.5rem, 3.2vw, 2.4rem)/1.2 var(--font-head); }
.mfeature-text .meta { color: #d5ded8; margin: 0; }
.mside { display: grid; align-content: start; }
.mside-title { font-size: 1.15rem; margin: 0 0 6px; padding-bottom: 10px; border-bottom: 3px solid var(--brand); justify-self: start; }
.mrow { display: grid; grid-template-columns: 96px 1fr; gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--body); align-items: center; }
.mrow-img { width: 96px; height: 74px; border-radius: 10px; overflow: hidden; background: var(--soft); }
.mrow-img img { width: 100%; height: 100%; object-fit: cover; }
.mrow-body { display: grid; gap: 4px; justify-items: start; }
.mrow strong { color: var(--ink); font: 600 .96rem/1.35 var(--font-head); transition: color .2s; }
.mrow:hover strong { color: var(--brand); }
.mrow .meta { margin: 0; font-size: .8rem; }
.see-all { color: var(--brand); font: 500 .9rem var(--font-head); text-decoration: none; margin-top: 12px; display: inline-block; }

/* ===== Call-to-action strip ===== */
.cta-strip { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); margin: 32px 0 0; }
.cta { display: grid; gap: 4px; padding: 22px 24px; border-radius: var(--radius); text-decoration: none; color: #fff; transition: transform .2s, box-shadow .2s; }
.cta:hover { color: #fff; transform: translateY(-3px); box-shadow: 0 12px 26px rgb(0 0 0 / .14); }
.cta strong { font: 600 1.3rem/1.2 var(--font-head); }
.cta strong::after { content: ' →'; }
.cta span:last-child { font-size: .92rem; }
.cta-k { font: 600 .72rem var(--font-head); letter-spacing: .08em; text-transform: uppercase; }
.cta-join { background: #146c34; }
.cta-barefoot { background: linear-gradient(120deg, #0f766e, #17803d); }
.cta-game { background: var(--dark); }
.cta-game .cta-k { color: var(--accent); opacity: 1; }

/* ===== A week at the club band ===== */
.mband { background: var(--soft); margin-top: 44px; padding: 4px 0 40px; }
.mband .msec-head { margin-top: 32px; }
.mevents { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); }
.mevent { display: grid; grid-template-columns: 62px 1fr; gap: 14px; background: #fff; padding: 16px; border-radius: var(--radius); box-shadow: 0 2px 6px rgb(0 0 0 / .05); }
.mdate { display: grid; place-items: center; align-self: start; height: 62px; background: var(--brand); color: #fff; border-radius: 10px; font-family: var(--font-head); text-transform: uppercase; }
.mdate b { font-size: 1.05rem; letter-spacing: .04em; }
.mevent-body { display: grid; gap: 3px; }
.mevent strong { color: var(--ink); font: 600 1rem/1.3 var(--font-head); }
.mevent .meta { margin: 0; }
.meta-contact { color: var(--brand); font-weight: 500; }

/* ===== Main + sidebar ===== */
.mcols { display: grid; grid-template-columns: 1fr; gap: 44px; margin-bottom: 56px; }
@media (min-width: 1000px) { .mcols { grid-template-columns: minmax(0, 1fr) 320px; } }
.maside { display: grid; gap: 24px; align-content: start; padding-top: 44px; }
.widget { display: block; background: var(--soft); border-radius: var(--radius); padding: 22px; color: var(--body); text-decoration: none; }
.widget p { margin: 0 0 14px; font-size: .94rem; }
.widget-title { display: block; font: 600 1.08rem var(--font-head); color: var(--ink); margin-bottom: 12px; }
.wjoin { background: var(--tint); border-top: 4px solid var(--brand); }
.wdark { background: var(--dark); color: #c5d2c9; border-left: 5px solid var(--accent); }
.wdark:hover { color: #c5d2c9; }
.wdark .widget-title { color: #fff; }
.wdark-big { display: block; font: 700 2rem/1.1 var(--font-head); color: #fff; }
.wdark .meta { display: block; color: #c5d2c9; margin: 8px 0 4px; }
.wdark .see-all { color: var(--accent); }
.wcats { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.wcat { display: block; padding: 11px 14px; border-radius: 10px; color: #fff; text-decoration: none; font: 500 .95rem var(--font-head); transition: transform .2s; }
.wcat:hover { color: #fff; transform: translateX(4px); }
.wcat::after { content: '→'; float: right; opacity: .7; }
.wcat-pennants { background: var(--c-pennants); }
.wcat-draws-results { background: var(--c-draws); }
.wcat-champions { background: var(--c-champions); }
.wcat-newsletters { background: var(--c-newsletters); }
.wcat-gallery { background: var(--c-gallery); }
.rotator { aspect-ratio: 6 / 5; border-radius: 10px; overflow: hidden; background: #fff; }
.rotator a { display: block; height: 100%; animation: fade .6s ease; }
.rotator a[hidden] { display: none; }
.rotator img { width: 100%; height: 100%; object-fit: contain; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.wcontact p:last-child { margin: 0; }

/* ===== Intro + FAQs ===== */
.cbc-intro p { font-size: 1.02rem; line-height: 1.75; margin: 0 0 14px; }
.cbc-faq { margin: 8px 0; }
.cbc-faq .title-section { display: flex; margin: 44px 0 14px; border-bottom: 1px solid var(--line); }
.cbc-faq .title-section h2 { font-size: 1.4rem; margin: 0 0 -1px; padding-bottom: 12px; border-bottom: 3px solid var(--brand); }
.cbc-faq details { border-bottom: 1px solid var(--line); }
.cbc-faq summary { list-style: none; cursor: pointer; position: relative; padding: 16px 40px 16px 0; font: 500 1.02rem/1.4 var(--font-head); color: var(--ink); }
.cbc-faq summary::-webkit-details-marker { display: none; }
.cbc-faq summary::after { content: '+'; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%;
  display: grid; place-items: center; background: var(--tint); color: var(--brand); font: 500 1.2rem/1 var(--font); }
.cbc-faq details[open] summary::after { content: '−'; background: var(--brand); color: #fff; }
.cbc-faq summary:hover { color: var(--brand); }
.cbc-faq-a { padding: 0 40px 18px 0; }
.cbc-faq-a p { margin: 0; }

/* ===== Featured sponsors + sponsor wall ===== */
.fsponsors { margin-bottom: 56px; }
.sponsor-wall { background: var(--soft); padding: 40px 0 48px; }
.sponsor-wall-title { text-align: center; font-size: 1.2rem; margin: 0 0 24px; }
.logos { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.logos a { display: block; background: #fff; border-radius: 10px; overflow: hidden; transition: transform .2s, box-shadow .2s; }
.logos a:hover { transform: translateY(-3px); box-shadow: 0 10px 22px rgb(0 0 0 / .1); }
.logos img { aspect-ratio: 6 / 5; object-fit: contain; width: 100%; }

/* ===== Article (posts and pages) ===== */
.article { padding-top: 32px; }
.article-head { margin-bottom: 20px; }
.article-head h1 { margin: 12px 0 6px; }
.article-head .meta { font-size: .9rem; }
.article-img { margin: 0 0 28px; }
.article-img img { width: 100%; border-radius: var(--radius); }
.article-img figcaption { color: var(--muted); font-size: .85rem; margin-top: 8px; }
.prose { font-size: 1.04rem; line-height: 1.75; color: #333d36; overflow-wrap: anywhere; }
.prose > *:first-child { margin-top: 0; }
.prose p { margin: 0 0 1.1em; }
.prose a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose img { border-radius: 10px; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin: .3em 0; }
.prose blockquote { margin: 1.4em 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--brand); font-style: italic; color: var(--ink); }
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 1.4em; font-size: .95rem; display: block; overflow-x: auto; }
.prose th, .prose td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.prose th { background: var(--soft); font-family: var(--font-head); font-weight: 600; color: var(--ink); }
.prose .wp-caption, .prose figure { max-width: 100%; margin: 0 0 1.4em; }
.prose .wp-caption-text, .prose figcaption { color: var(--muted); font-size: .85rem; margin-top: 6px; }
.prose .alignleft { float: left; margin: 4px 22px 14px 0; }
.prose .alignright { float: right; margin: 4px 0 14px 22px; }
.prose .aligncenter { margin-left: auto; margin-right: auto; }
@media (max-width: 600px) { .prose .alignleft, .prose .alignright { float: none; margin: 0 0 1em; } }
.prose iframe { max-width: 100%; border: 0; border-radius: 10px; }
.prose::after { content: ''; display: table; clear: both; }
/* Old theme external-link marker */
.prose a[target=_blank]:not(:has(img))::after { content: ''; display: inline-block; width: .75em; height: .75em; margin-left: 4px; vertical-align: baseline;
  background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M14 3h7v7h-2V6.4l-9.3 9.3-1.4-1.4L17.6 5H14V3zM5 5h6v2H7v10h10v-4h2v6H5V5z'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M14 3h7v7h-2V6.4l-9.3 9.3-1.4-1.4L17.6 5H14V3zM5 5h6v2H7v10h10v-4h2v6H5V5z'/%3E%3C/svg%3E") center/contain no-repeat; }

/* WordPress galleries */
.prose .gallery { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 160px), 1fr)); margin: 0 0 1.4em; }
.prose .gallery br { display: none; }
.prose .gallery-item { margin: 0; width: auto !important; }
.prose .gallery-icon a, .prose .gallery-icon img { display: block; }
.prose .gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; border: 0 !important; transition: opacity .2s; }
.prose .gallery a:hover img { opacity: .85; }
.prose .gallery-caption { font-size: .8rem; color: var(--muted); padding-top: 4px; }

.tags { list-style: none; margin: 28px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tags a { display: inline-block; padding: 5px 13px; border: 1px solid var(--line); border-radius: 99px; color: var(--body); text-decoration: none; font-size: .85rem; }
.tags a:hover { border-color: var(--brand); color: var(--brand); }
.related { margin-top: 12px; }

/* ===== Lists (categories, search) ===== */
.list-head { padding: 34px 0 6px; border-bottom: 1px solid var(--line); }
.list-head h1 { margin: 4px 0 10px; display: inline-block; padding-bottom: 12px; margin-bottom: -1px; border-bottom: 3px solid var(--brand); }
.list-head h1.u-events { border-color: var(--c-events); } .list-head h1.u-pennants { border-color: var(--c-pennants); }
.list-head h1.u-draws-results { border-color: var(--c-draws); } .list-head h1.u-champions { border-color: var(--c-champions); }
.list-head h1.u-membership { border-color: var(--c-membership); } .list-head h1.u-gallery { border-color: var(--c-gallery); }
.list-head h1.u-newsletters { border-color: var(--c-newsletters); } .list-head h1.u-honour-boards { border-color: var(--c-honour); }
.list-desc { color: var(--muted); max-width: 70ch; margin: 14px 0 0; }
.crumb { font: 500 .85rem var(--font-head); color: var(--muted); text-decoration: none; display: block; }
.crumb::after { content: ' /'; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 18px; }
.chip { padding: 6px 14px; border: 1px solid var(--line); border-radius: 99px; color: var(--ink); text-decoration: none; font: 500 .88rem var(--font-head); }
.chip:hover { border-color: var(--brand); color: var(--brand); }
.mmain > .grid:first-child { margin-top: 36px; }
.msearch { display: flex; gap: 10px; max-width: 640px; margin: 0 0 20px; }
.msearch input { flex: 1; min-width: 0; padding: 11px 16px; border: 1px solid var(--line); border-radius: 99px; font: inherit; }
.msearch input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--tint); }
.mmain > .meta:first-child { margin-top: 30px; }

.pager { margin: 40px 0 0; }
.pager ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.pager a, .pager span { display: inline-grid; place-items: center; min-width: 40px; height: 40px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line); text-decoration: none; color: var(--ink); font: 500 .9rem var(--font-head); }
.pager a:hover { border-color: var(--brand); color: var(--brand); }
.pager .current { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager .dots { border: 0; }

/* ===== Contact and forms ===== */
.map { margin: 0 0 28px; border-radius: var(--radius); overflow: hidden; aspect-ratio: 16 / 7; background: var(--soft); }
.map iframe { width: 100%; height: 100%; border: 0; display: block; }
@media (max-width: 600px) { .map { aspect-ratio: 4 / 3; } }
.formbox { margin-top: 8px; }
.wpcf7 label { display: block; font-weight: 500; color: var(--ink); margin: 0 0 14px; }
.wpcf7 input[type=text], .wpcf7 input[type=email], .wpcf7 input[type=tel], .wpcf7 input[type=date], .wpcf7 input[type=number], .wpcf7 select, .wpcf7 textarea {
  width: 100%; margin-top: 6px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font: inherit; color: var(--ink); }
.wpcf7 textarea { min-height: 150px; }
.wpcf7 input:focus, .wpcf7 select:focus, .wpcf7 textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--tint); }
.wpcf7 input[type=submit] { background: var(--brand); color: #fff; border: 0; border-radius: var(--btn-radius); padding: 12px 28px; font: 500 1rem var(--font-head); cursor: pointer; }
.wpcf7 input[type=submit]:hover { background: var(--brand-hover); }
.wpcf7 input:focus, .wpcf7 select:focus, .wpcf7 textarea:focus { outline: none; }
/* Fields that need fixing: red border (as on the old site), no extra text */
.wpcf7 .wpcf7-form-control[aria-invalid="true"] { border: 2px solid #dc2626; background: #fff5f5; }
.wpcf7 .wpcf7-form-control[aria-invalid="true"]:focus { box-shadow: 0 0 0 3px #fde2e2; }
/* Required fields filled in correctly: green border */
.wpcf7 .wpcf7-form-control[aria-required="true"][aria-invalid="false"]:not(:placeholder-shown) { border: 2px solid #17803d; background: #f6fff8; }
.wpcf7 .wpcf7-not-valid-tip { display: none; }
/* No yellow message box. Only show a message if the email couldn't be sent */
.wpcf7 form .wpcf7-response-output, .wpcf7 form.invalid .wpcf7-response-output { display: none; }
.wpcf7 form.failed .wpcf7-response-output, .wpcf7 form.aborted .wpcf7-response-output {
  display: block; margin: 16px 0 0; padding: 12px 14px; border: 2px solid #dc2626; border-radius: 10px; background: #fff5f5; color: #7f1d1d; }

.thanks { text-align: center; padding: 60px 20px 20px; max-width: 560px; margin: 0 auto; }
.thanks-tick { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--brand); color: #fff; font-size: 2rem; }

/* ===== Lightbox ===== */
.lightbox { position: fixed; inset: 0; z-index: 200; display: none; align-items: center; justify-content: center; background: rgb(5 15 10 / .92); padding: 50px 60px; }
.lightbox.on { display: flex; }
.lightbox figure { margin: 0; max-width: 100%; max-height: 100%; display: grid; gap: 10px; justify-items: center; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 140px); border-radius: 8px; }
.lightbox figcaption { color: #dfe8e2; font-size: .9rem; text-align: center; }
.lightbox button { position: absolute; background: rgb(255 255 255 / .12); color: #fff; border: 0; width: 48px; height: 48px; border-radius: 50%; font-size: 2rem; line-height: 1; cursor: pointer; }
.lightbox button:hover { background: rgb(255 255 255 / .25); }
.lb-close { top: 14px; right: 14px; }
.lb-prev { left: 10px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 10px; top: 50%; transform: translateY(-50%); }
body.lb-open { overflow: hidden; }
@media (max-width: 600px) { .lightbox { padding: 60px 8px; } .lb-prev, .lb-next { top: auto; bottom: 10px; transform: none; } }

/* ===== Footer ===== */
.pfoot { background: var(--dark); color: #a9b8ae; font-size: .93rem; }
.pfoot-in { display: grid; grid-template-columns: 1fr; gap: 32px; padding-block: 52px 32px; }
@media (min-width: 800px) { .pfoot-in { grid-template-columns: 2fr 1fr 1fr; } }
.pfoot-brand { display: flex; align-items: center; gap: 10px; color: #fff; font: 700 1.25rem var(--font-head); margin: 0 0 12px; }
.pfoot .logo { background: #fff; border-radius: 50%; padding: 3px; }
.pfoot-about p { max-width: 46ch; }
.pfoot-h { color: #fff; font-size: 1rem; margin: 0 0 14px; }
.pfoot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.pfoot a { color: #dfe8e2; text-decoration: none; }
.pfoot a:hover { color: var(--accent); }
.pfoot-contact a, .pfoot-base a, .pfoot-about p a { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgb(223 232 226 / .5); }
.pfoot-base { display: flex; justify-content: space-between; gap: 10px 20px; flex-wrap: wrap; border-top: 1px solid #23392c; padding-block: 18px 28px; font-size: .84rem; }

/* ===== Phones ===== */
@media (max-width: 600px) {
  .wrap { padding: 0 16px; }
  .mhero { margin-top: 18px; gap: 20px; }
  .mfeature { min-height: 300px; }
  .mfeature-text { padding: 18px; }
  .grid-3, .grid-6 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 14px; }
  .card h3, .grid-6 .card h3 { font-size: .92rem; }
  .card-pill { padding-left: 8px; }
  .card .pill { font-size: .58rem; padding: 2px 7px; }
  .card .meta { font-size: .76rem; }
  .card .meta .views { display: none; }
  .card .excerpt { display: none; }
  .msec-title { font-size: 1.2rem; }
  .msec-head { margin-top: 34px; }
  .mrow { grid-template-columns: 80px 1fr; }
  .mrow-img { width: 80px; height: 64px; }
  .logos { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .cta { padding: 18px 20px; }
}

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

@media print {
  .topbar, .top, .maside, .pfoot, .sponsor-wall, .cta-strip { display: none !important; }
}
