/* ==========================================================================
   Racquetball Ontario - Main Stylesheet
   ========================================================================== */

:root {
    --ro-red: #C83739;
    --ro-grey: #6D7273;
    --text-main: #333333;
    --bg-light: #F8F9FA;
}

html {
    scroll-behavior: smooth;
}

/* --- Base Resets & Typography --- */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    line-height: 1.6;
    background:
        radial-gradient(circle at 12% 8%, rgba(200, 55, 57, 0.08), transparent 28rem),
        linear-gradient(135deg, #edf4fb 0%, #e7eef6 45%, #f4f7f6 100%);
    background-attachment: fixed;
}

/* --- Header Layout --- */
.site-header {
    background-color: rgba(255,255,255,0.95);
    backdrop-filter: saturate(180%) blur(14px);
    box-shadow: 0 16px 50px rgba(0,0,0,0.16);
    border-bottom: 1px solid rgba(0,0,0,0.08);
    padding: 8px 0;
    position: sticky;
    top: 0;
    z-index: 200;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.logo img {
    height: 116px;
    width: auto;
    display: block;
}

/* --- Navigation Base --- */
.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-nav > ul {
    display: flex;
    gap: 25px;
    padding: 14px 18px 10px;
    background: #ffffff;
    border-radius: 18px;
    position: relative;
    overflow: visible;
    box-shadow: 0 12px 36px rgba(0,0,0,0.08);
}

.main-nav > ul::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: var(--ro-red);
}

.main-nav > ul > li {
    position: relative; 
    z-index: 1;
}

.nav-item-row {
    display: flex;
    align-items: center;
}

.submenu-toggle {
    display: none;
}

.main-nav a {
    text-decoration: none;
    color: var(--ro-grey);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.9rem;
    transition: color 0.3s ease;
    display: block;
    padding: 10px 0;
}

.main-nav > ul > li > a:hover,
.main-nav > ul > li > .nav-item-row > a:hover {
    color: var(--ro-red);
}

/* --- Dropdown Menus --- */
.main-nav .dropdown {
    display: none; 
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1); 
    min-width: 220px;
    z-index: 1000;
    flex-direction: column;
    gap: 0;
    border-top: 3px solid var(--ro-red); 
}

@media (min-width: 769px) {
    .main-nav .has-dropdown:hover > .dropdown,
    .main-nav .has-dropdown:focus-within > .dropdown,
    .main-nav .has-dropdown.is-open > .dropdown {
        display: flex;
    }
}

.main-nav .dropdown .has-dropdown {
    position: relative;
}

.main-nav .dropdown .dropdown {
    top: -3px;
    left: 100%;
}

.main-nav .dropdown li {
    width: 100%;
}

.main-nav .dropdown a {
    padding: 12px 20px;
    text-transform: none; 
    font-weight: 500;
    font-size: 0.95rem;
    border-bottom: 1px solid #f0f0f0;
}

.main-nav .dropdown a:hover {
    background-color: var(--bg-light);
    color: var(--ro-red);
    padding-left: 25px; 
    transition: all 0.2s ease;
}

/* --- Content Area --- */
.site-content {
    max-width: 1200px;
    margin: 28px auto 24px;
    padding: 0 20px;
    min-height: 0;
}

.site-content.page-layout {
    width: min(1200px, calc(100% - 40px));
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 44px 40px 48px;
    box-sizing: border-box;
}

.page-layout {
    background-color: #ffffff;
    padding: 44px 40px 48px;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.04);
}

.site-content h1, 
.site-content h2, 
.site-content h3 {
    color: var(--ro-grey);
    margin-bottom: 15px;
    line-height: 1.2;
}

.site-content > :first-child {
    margin-top: 0;
}

.site-content > :last-child {
    margin-bottom: 0;
}

.site-content p {
    margin-bottom: 20px;
    color: #444444;
}

.site-content ul,
.site-content ol {
    margin: 0 0 1.25rem;
    padding-left: 1.5rem;
}

.site-content li {
    margin-bottom: 0.35rem;
}

.site-content li:last-child {
    margin-bottom: 0;
}

.site-content ul ul,
.site-content ol ol,
.site-content ul ol,
.site-content ol ul {
    margin: 0.35rem 0 0.5rem;
}

.site-content .event-sessions,
.site-content .store-cart,
.site-content .coach-dates,
.site-content .coach-times,
.site-content .cal-links {
    padding-left: 0;
}

.site-content figure {
    margin: 0 0 1.5rem;
}

.site-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
}

/* --- Page Title (replaces per-page hero banner) --- */
.site-content .page-title {
    color: var(--ro-red);
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.2;
}

.site-content .page-subtitle {
    color: #666;
    font-size: 1.1rem;
    margin: -4px 0 28px 0;
    max-width: 720px;
}

/* --- Content Tables --- */
.site-content table.ro-table,
.site-content table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 24px 0;
    font-size: 0.95rem;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #dde3e8;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
}

.site-content table.ro-table th,
.site-content table.ro-table td,
.site-content table th,
.site-content table td {
    padding: 12px 16px;
    border: 0;
    border-bottom: 1px solid #dde3e8;
    border-right: 1px solid #dde3e8;
    text-align: left;
    vertical-align: top;
}

.site-content table.ro-table th,
.site-content table th {
    background: var(--ro-red);
    color: #fff;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
}

.site-content table.ro-table th:last-child,
.site-content table.ro-table td:last-child,
.site-content table th:last-child,
.site-content table td:last-child {
    border-right: 0;
}

.site-content table.ro-table tr:last-child td,
.site-content table tr:last-child td {
    border-bottom: 0;
}

.site-content table.ro-table tbody tr:nth-child(even),
.site-content table tbody tr:nth-child(even) {
    background: #f4f7f9;
}

.site-content table.ro-table tbody tr:hover,
.site-content table tbody tr:hover {
    background: #eef3f7;
}

.site-content table.ro-table caption,
.site-content table caption {
    caption-side: bottom;
    padding-top: 8px;
    color: #6D7273;
    font-size: 0.85rem;
    text-align: left;
}

/* --- Hero Banner (legacy / news pages) --- */
.hero-banner {
    background-color: var(--ro-grey); 
    color: #ffffff;
    padding: 100px 20px;
    text-align: center;
    border-radius: 24px; 
    margin-bottom: 40px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.hero-banner h1 {
    color: #ffffff; 
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: -1px;
}

.hero-banner p {
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto 30px auto;
    color: #f0f0f0;
}

/* --- Primary Buttons --- */
.btn-primary {
    display: inline-block;
    background-color: var(--ro-red);
    color: #ffffff !important;
    padding: 14px 32px;
    border-radius: 50px; 
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(200, 55, 57, 0.3); 
}

.btn-primary:hover {
    background-color: #a62b2d; 
    transform: translateY(-3px); 
    box-shadow: 0 8px 20px rgba(200, 55, 57, 0.4);
}

.btn-secondary {
    display: inline-block;
    background-color: transparent;
    color: #ffffff !important;
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none;
    letter-spacing: 0.5px;
    border: 2px solid #ffffff;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background-color: #ffffff;
    color: var(--ro-red) !important;
    transform: translateY(-3px);
}

/* --- Card Grid System --- */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

@media (min-width: 768px) {
    .card-grid {
        grid-template-columns: 1.5fr 1fr !important; /* Left column wider, rankings narrower */
    }
}

.card, .youtube-feature-section {
    background: #ffffff;
    padding: 40px 30px;
    border-radius: 20px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.04); 
    border-top: 5px solid var(--ro-red) !important; /* Branded red trim */
    transition: all 0.3s ease;
}

.card:hover, .youtube-feature-section:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
}

.card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
}

.card p {
    font-size: 0.95rem;
    color: #555555;
    margin-bottom: 20px;
}

/* --- Dynamic Rankings Box --- */
#rfi-rankings-box h2 {
    font-size: 1.4rem;
    color: var(--ro-grey);
    margin-bottom: 15px;
}

.rankings-section {
    margin-top: 15px;
}

.rankings-header-row {
    display: flex; 
    justify-content: space-between; 
    align-items: baseline; 
    margin-bottom: 8px;
    border-bottom: 1px solid #f0f0f0;
    padding-bottom: 4px;
}

.rankings-header-row h3 {
    color: #b91c1c; 
    text-transform: uppercase; 
    font-size: 1rem; 
    margin: 0; 
    font-weight: bold; 
    letter-spacing: 0.5px;
}

.view-all-link {
    font-size: 0.8rem; 
    color: #475569; 
    text-decoration: none; 
    font-weight: 600;
    transition: color 0.2s;
}

.view-all-link:hover {
    color: #b91c1c;
}

.rankings-list {
    padding-left: 20px; 
    margin: 0 0 25px 0; 
    line-height: 1.8; 
    color: #334155; 
    list-style-type: decimal;
}

.rfi-player-link {
    color: #1e40af; 
    text-decoration: none;
    transition: color 0.2s, text-decoration 0.2s;
}

.rfi-player-link:hover {
    color: #b91c1c; 
    text-decoration: underline;
}

.rfi-meta-text {
    color: #64748b; 
    font-size: 0.88em; 
    font-weight: normal;
    margin-left: 4px;
}

/* --- Featured Sponsor Strip (below hero) --- */
.featured-sponsor-strip {
    width: min(1200px, calc(100% - 40px));
    max-width: 1200px;
    margin: 0 auto 28px auto;
    border: 1px solid #e8ecef;
    border-radius: 14px;
    background: linear-gradient(180deg, #f8fafb 0%, #ffffff 100%);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.03);
    overflow: hidden;
}

.featured-sponsor-inner {
    padding: 14px 22px;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px 20px;
}

.featured-sponsor-label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #94a3b8;
}

.featured-sponsor-main {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
}

.featured-sponsor-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 48px;
    flex-shrink: 0;
    text-decoration: none;
}

.featured-sponsor-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.featured-sponsor-copy {
    min-width: 0;
    flex: 1;
}

.featured-sponsor-name {
    display: block;
    font-weight: 700;
    color: var(--ro-grey);
    text-decoration: none;
    font-size: 1rem;
    line-height: 1.3;
    overflow-wrap: break-word;
}

a.featured-sponsor-name:hover {
    color: var(--ro-red);
}

.featured-sponsor-desc {
    margin: 2px 0 0;
    font-size: 0.85rem;
    color: #64748b;
    line-height: 1.35;
}

.featured-sponsor-all {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--ro-red);
    text-decoration: none;
    white-space: nowrap;
    justify-self: end;
}

.featured-sponsor-all:hover {
    text-decoration: underline;
}

.featured-sponsor-rotator {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.featured-sponsor-viewport {
    overflow: hidden;
    width: 100%;
    min-width: 0;
}

.featured-sponsor-track {
    display: flex;
    transition: transform 0.5s ease;
    will-change: transform;
}

.featured-sponsor-slide {
    flex: 0 0 100%;
    width: 100%;
    max-width: 100%;
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
    box-sizing: border-box;
}

.featured-sponsor-dots {
    display: flex;
    gap: 6px;
    align-items: center;
}

.featured-sponsor-dots button {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #cbd5e1;
    cursor: pointer;
}

.featured-sponsor-dots button.is-active {
    background: #C83739;
    width: 18px;
    border-radius: 999px;
}

.status-badge {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    border-radius: 4px;
    padding: 2px 7px;
    margin-right: 6px;
}
.status-badge.open { background: #dcfce7; color: #166534; }
.status-badge.upcoming { background: #e0f2fe; color: #075985; }
.status-badge.live, .status-badge.now { background: #fee2e2; color: #991b1b; }
.status-badge.results { background: #ede9fe; color: #5b21b6; }
.status-badge.past { background: #f1f5f9; color: #475569; }

.home-event {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    margin-top: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid #f0f0f0;
    padding-bottom: 12px;
}
.home-event[hidden] { display: none !important; }
.card .home-events-head {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 4px;
}
.card .home-events-head h3 { margin-bottom: 0; }
.home-type-toggles {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.home-type-toggle {
    appearance: none;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #334155;
    font: inherit;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    border-radius: 999px;
    padding: 5px 10px;
    cursor: pointer;
    line-height: 1.2;
}
.home-type-toggle:hover {
    border-color: #C83739;
    color: #C83739;
}
.home-type-toggle.is-active,
.home-type-toggle.is-active:hover {
    background: #C83739;
    border-color: #C83739;
    color: #fff;
}
.home-type-toggle:focus-visible {
    outline: 2px solid #C83739;
    outline-offset: 2px;
}
.card .home-events-empty {
    margin: 12px 0 8px;
    color: #666;
    font-size: 0.95rem;
}
.home-events-empty[hidden] { display: none !important; }
.home-events-empty a {
    color: var(--ro-red);
    font-weight: 600;
    text-decoration: none;
}
.home-event-body { flex: 1; min-width: 0; }
.home-event-graphic {
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}
@media (max-width: 480px) {
    .home-event-graphic { width: 72px; height: 72px; }
}

.cal-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}
.cal-links a {
    font-size: 0.78rem;
    font-weight: 600;
    color: #334155;
    text-decoration: none;
    border: 1px solid #e2e8f0;
    background: #fff;
    border-radius: 999px;
    padding: 4px 10px;
}
.cal-links a:hover {
    border-color: #C83739;
    color: #C83739;
}

.cta-panel {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 28px 24px 32px;
    margin: 24px 0 0;
}
.cta-panel h2, .cta-panel h3 {
    margin: 0 0 10px;
    color: var(--ro-grey);
}
.cta-panel p:last-child {
    margin-bottom: 0;
}
.perk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 14px;
    margin: 20px 0 28px;
}
.perk-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}
.perk-card h3 {
    margin: 0 0 6px;
    font-size: 1rem;
    color: #1f2937;
}
.perk-card p {
    margin: 0;
    color: #64748b;
    font-size: 0.92rem;
}

.friend-form-wrap {
    position: relative;
    margin: 28px 0 8px;
    max-width: 760px;
}
.friend-form-lead {
    color: #555;
    margin: 0 0 18px;
}
.friend-form-lead a {
    color: var(--ro-red);
    font-weight: 600;
}
.friend-form-notice {
    border-radius: 10px;
    padding: 12px 14px;
    margin: 0 0 16px;
    font-size: 0.95rem;
}
.friend-form-notice--ok {
    background: #ecfdf3;
    border: 1px solid #bbf7d0;
    color: #166534;
}
.friend-form-notice--err {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}
.friend-form-notice ul {
    margin: 6px 0 0;
    padding-left: 18px;
}
.friend-form label {
    display: block;
    font-weight: 600;
    color: #1f2937;
    font-size: 0.92rem;
    margin-bottom: 14px;
}
.friend-form label span {
    font-weight: 400;
    color: #64748b;
}
.friend-form input[type="text"],
.friend-form input[type="email"],
.friend-form input[type="tel"],
.friend-form textarea {
    display: block;
    width: 100%;
    margin-top: 6px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 10px 12px;
    font: inherit;
    box-sizing: border-box;
    background: #fff;
}
.friend-form textarea {
    resize: vertical;
    min-height: 96px;
}
.friend-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 16px;
}
.friend-form fieldset {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 14px 4px;
    margin: 0 0 16px;
}
.friend-form legend {
    font-weight: 700;
    color: #1f2937;
    padding: 0 6px;
}
.friend-choice {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-weight: 500 !important;
    margin-bottom: 10px !important;
    cursor: pointer;
}
.friend-choice input {
    margin-top: 3px;
}
.friend-choice--check {
    margin-top: 4px;
}
.friend-form-note {
    color: #64748b;
    font-size: 0.88rem;
    margin: 0 0 10px;
}
.friend-form-submit {
    appearance: none;
    border: 0;
    background: #C83739;
    color: #fff;
    font: inherit;
    font-weight: 700;
    padding: 12px 18px;
    border-radius: 999px;
    cursor: pointer;
}
.friend-form-submit:hover {
    background: #a82d2f;
}
.friend-honeypot {
    position: absolute;
    left: -9999px;
    height: 0;
    overflow: hidden;
}
@media (max-width: 640px) {
    .friend-form-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 700px) {
    .featured-sponsor-inner {
        grid-template-columns: 1fr auto;
        padding: 14px 16px;
        align-items: start;
    }
    .featured-sponsor-main,
    .featured-sponsor-rotator {
        grid-column: 1 / -1;
        width: 100%;
    }
    .featured-sponsor-logo {
        width: 96px;
        height: 40px;
    }
    .featured-sponsor-strip {
        width: min(1200px, calc(100% - 32px));
        margin-bottom: 20px;
    }
}

/* --- Sponsors Page --- */
.sponsors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 22px;
    margin-bottom: 20px;
}

.sponsor-card {
    border: 1px solid #eef0f2;
    border-radius: 14px;
    background: #fff;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
}

.sponsor-card-logo {
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: #f8fafb;
    border-bottom: 1px solid #f0f0f0;
}

.sponsor-card-logo img {
    max-width: 100%;
    max-height: 84px;
    object-fit: contain;
}

.sponsor-card-placeholder {
    font-weight: 700;
    color: #94a3b8;
    text-align: center;
    padding: 10px;
}

.sponsor-card-body {
    padding: 18px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.sponsor-card-body h3 {
    margin: 0;
    font-size: 1.15rem;
    color: var(--ro-grey);
}

.sponsor-card-body h3 a {
    color: inherit;
    text-decoration: none;
}

.sponsor-card-body h3 a:hover {
    color: var(--ro-red);
}

.sponsor-contact {
    margin: 0;
    font-size: 0.85rem;
    color: #64748b;
}

.sponsor-desc {
    margin: 0;
    font-size: 0.95rem;
    color: #555;
    line-height: 1.45;
    flex: 1;
}

.sponsor-visit {
    margin-top: 6px;
    color: var(--ro-red);
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
}

.sponsor-visit:hover {
    text-decoration: underline;
}

/* --- Footer --- */
.site-footer {
    background-color: var(--ro-grey);
    color: #ffffff;
    text-align: center;
    padding: 28px 20px 24px;
    margin-top: 0;
}

.footer-admin {
    margin-top: 12px;
    font-size: 0.78rem;
    opacity: 0.65;
}

.footer-admin a {
    color: #ffffff;
    text-decoration: none;
}

.footer-admin a:hover {
    text-decoration: underline;
    opacity: 1;
}

/* --- Header Actions (Nav & Socials) --- */
.header-actions {
    display: flex;
    align-items: center; 
    gap: 30px; 
}

.social-icons {
    display: flex;
    align-items: center;
    gap: 15px;
    border-left: 2px solid #f0f0f0; 
    padding-left: 30px;
}

.social-icons a {
    color: var(--ro-red) !important; 
    text-decoration: none !important; 
    display: flex;
    align-items: center;
    transition: color 0.3s ease, transform 0.2s ease;
}

.social-icons a:hover {
    color: var(--ro-grey) !important; 
    transform: translateY(-2px); 
}

/* Mobile Navigation Button defaults to hidden */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    color: #333;
    cursor: pointer;
    padding: 5px;
    margin-left: auto;
}

/* ==================================================
   MOBILE BREAKPOINT (Screens smaller than 768px)
   ================================================== */
@media (max-width: 768px) {
    /* 1. Header & Menu Adjustments */
    .header-container {
        flex-wrap: wrap; 
    }

    .mobile-toggle {
        display: block; 
    }

    .logo img {
        height: 78px;
        transition: height 0.22s ease;
    }

    .site-header {
        max-height: none;
        overflow: visible;
        transition: padding 0.2s ease;
    }

    body.nav-open .site-header {
        max-height: 100dvh;
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .site-header.is-compact {
        padding: 4px 0;
    }

    .site-header.is-compact .logo img {
        height: 36px;
    }

    .site-header.is-compact .mobile-toggle {
        padding: 2px;
    }

    .site-header.is-compact .mobile-toggle svg {
        width: 22px;
        height: 22px;
    }

    .site-header.is-compact #header-nav-actions {
        margin-top: 8px;
        padding-top: 8px;
        padding-bottom: 12px;
    }

    body.nav-open {
        overflow: hidden;
    }

    #header-nav-actions {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        padding: 12px 0 20px;
        border-top: 1px solid #eaeaea;
        margin-top: 15px;
    }

    #header-nav-actions.nav-open {
        display: flex;
    }

    .main-nav {
        width: 100%;
    }

    .main-nav > ul {
        flex-direction: column;
        padding: 0;
        margin: 0;
        width: 100%;
        gap: 0 !important;
        overflow: visible;
    }

    .main-nav ul li {
        margin: 0;
        padding: 0;
        width: 100%;
        position: static;
    }

    .main-nav ul li a,
    .main-nav ul li > a {
        padding: 12px 48px 12px 16px;
        display: block;
        width: 100%;
        box-sizing: border-box;
    }

    .main-nav > ul > li:not(.has-dropdown) > a {
        padding-left: 16px;
        padding-right: 16px;
    }

    .nav-item-row {
        justify-content: stretch;
        position: relative;
        width: 100%;
    }

    .submenu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        right: 4px;
        top: 50%;
        transform: translateY(-50%);
        width: 44px;
        height: 44px;
        padding: 0;
        border: none;
        background: transparent;
        color: var(--ro-grey);
        cursor: pointer;
        z-index: 2;
    }

    .submenu-toggle::before {
        content: '';
        width: 8px;
        height: 8px;
        border-right: 2px solid currentColor;
        border-bottom: 2px solid currentColor;
        transform: rotate(45deg) translate(-1px, -1px);
        transition: transform 0.2s ease;
    }

    .has-dropdown.is-open > .nav-item-row > .submenu-toggle::before {
        transform: rotate(225deg) translate(-1px, -1px);
    }

    .main-nav .dropdown {
        position: static;
        display: none;
        min-width: 0;
        width: 100%;
        box-shadow: none;
        border-top: none;
        background: #f8fafc;
        border-radius: 0;
    }

    .main-nav .has-dropdown.is-open > .dropdown {
        display: flex;
        flex-direction: column;
    }

    .main-nav .dropdown .dropdown {
        top: auto;
        left: auto;
        padding: 0 0 0 12px;
        background: #f1f5f9;
    }

    .main-nav .dropdown .nav-item-row > a {
        text-align: left;
    }

    .main-nav .dropdown a {
        padding: 10px 48px 10px 16px;
    }

    .main-nav .dropdown a:hover {
        padding-left: 16px;
    }

    .social-icons {
        margin-top: 10px; 
        justify-content: center;
        border-left: none; /* Removes the divider line on mobile */
        padding-left: 0;
    }

    .page-layout {
        padding: 28px 20px 32px;
        border-radius: 16px;
    }

    .site-content {
        margin: 20px auto 20px;
        padding: 0 16px;
    }

    .site-content.page-layout {
        width: min(1200px, calc(100% - 32px));
        padding: 28px 20px 32px;
        margin-left: auto;
        margin-right: auto;
    }

    .site-content ul,
    .site-content ol {
        padding-left: 1.35rem;
        margin-bottom: 1.15rem;
    }

    .wp-block-spacer {
        height: 20px !important;
    }

    /* 2. Page title & hero adjustments */
    .site-content .page-title {
        font-size: 1.75rem;
        margin-bottom: 16px;
    }

    .site-content .page-subtitle {
        font-size: 1rem;
        margin: 0 0 22px 0;
    }

    .card, .youtube-feature-section {
        padding: 28px 20px;
    }

    .cta-panel {
        padding: 24px 18px 28px;
    }

    .card-grid {
        margin: 24px 0 8px;
        gap: 20px;
    }

    .hero-banner {
        padding: 40px 20px !important;
        text-align: center;
    }
    
    .hero-banner h1 {
        font-size: 2.2rem !important;
        line-height: 1.2 !important;
        margin-bottom: 15px;
    }
    
    .hero-banner p {
        font-size: 1.05rem !important;
        line-height: 1.5;
        padding: 0 10px;
        margin-bottom: 25px;
    }
    
    .hero-banner .btn-primary {
        display: block;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
        box-sizing: border-box;
    }
}

/* --- Events & Agenda Responsive Styles (moved from page inline) --- */
.events-controls { display:flex; gap:16px; align-items:center; justify-content:space-between; flex-wrap:wrap; }
.events-filters { display:flex; gap:14px; align-items:center; flex-wrap:wrap; }
.filter-group { display:flex; gap:8px; align-items:center; margin:0; }
.filter-group > span { color:#666; font-weight:700; font-size:0.85rem; text-transform:uppercase; letter-spacing:0.03em; }
.event-filter-select {
    appearance: none;
    -webkit-appearance: none;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236D7273' d='M1.4.6L6 5.2 10.6.6 12 2 6 8 0 2z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 10px 36px 10px 12px;
    min-width: 180px;
    font-size: 0.95rem;
    color: #334155;
    cursor: pointer;
}
.event-filter-select:focus { outline: none; border-color: #C83739; }
.events-page-head { margin-bottom: 28px; text-align: center; }
.events-page-head h1 { font-size: clamp(1.5rem, 4vw, 2.5rem); color: var(--ro-grey); font-weight: 700; text-transform: uppercase; margin-bottom: 8px; }
.events-page-head p { color: #666; max-width: 640px; margin: 0 auto; }
.events-view-toggle { display: flex; gap: 8px; flex-wrap: wrap; }
.cal-toolbar { display: flex; align-items: center; gap: 8px; margin: 12px 0; flex-wrap: wrap; }
.cal-toolbar h3 { margin: 0; white-space: nowrap; }
.cal-nav-btn { min-width: 40px; min-height: 40px; border: 1px solid #e5e7eb; background: #fff; border-radius: 8px; cursor: pointer; font-size: 1rem; }
.cal-nav-btn:disabled { opacity: 0.35; cursor: default; }
.cal-legend { display:flex; gap:8px; align-items:center; flex-wrap:wrap; margin-left:auto; }
.cal-legend-item { font-size:0.72rem; font-weight:700; letter-spacing:0.02em; text-transform:uppercase; border-radius:999px; padding:4px 8px; }
.cal-grid-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
#calendarGrid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 8px;
    min-width: 0;
}
.cal-dow { font-weight: 700; color: #6D7273; text-align: center; padding: 6px 2px; text-transform: uppercase; font-size: 0.8rem; }
.cal-dow-short { display: none; }
.cal-cell { min-height: 100px; background: #fff; border: 1px solid #f0f0f0; border-radius: 8px; padding: 8px; overflow: hidden; min-width: 0; }
.cal-cell--empty { background: #f8fafc; min-height: 100px; border-radius: 8px; }
.cal-daynum { font-weight: 600; margin-bottom: 6px; }
.cal-event-list { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cal-event {
    display: block;
    padding: 4px 6px;
    border-radius: 6px;
    background: var(--cal-bg, #f1f5f9);
    color: var(--cal-fg, #0f172a);
    font-weight: 700;
    text-decoration: none;
    border: 2px solid var(--cal-border, #6D7273);
    font-size: 0.78rem;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}
.type-filters { display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
.agenda-card { background:#f8fafc; border:1px solid #eef0f2; border-radius:12px; padding:20px; display:flex; gap:20px; align-items:flex-start; box-shadow:0 4px 12px rgba(0,0,0,0.04); min-width:0; }
.agenda-card img { width:200px; height:140px; object-fit:cover; border-radius:8px; flex-shrink:0; }
.agenda-graphic { width:200px; height:140px; border-radius:8px; flex-shrink:0; background:var(--type-color, #6D7273); color:#fff; display:flex; align-items:center; justify-content:center; }
.agenda-graphic svg { width:72px; height:72px; }
.agenda-graphic-modal { width:100%; height:200px; }
.agenda-card .card-info { flex:1; min-width:0; }
.agenda-card .card-info h3 { overflow-wrap: anywhere; }
.agenda-card .agenda-meta { color:#444; display:flex; flex-wrap:wrap; gap:8px 12px; margin-bottom:8px; font-size:0.95rem; align-items:center; }
.agenda-card .agenda-details { color:#666; margin-top:8px; line-height:1.6; max-height: 4.8em; overflow: hidden; }
.agenda-card .agenda-details p { margin-bottom: 0.35em; }
.event-sessions-heading { font-size: 1rem; margin: 14px 0 8px; color: #334155; }
.event-sessions { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.event-session { background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; padding: 8px 10px; }
.event-session-venue { font-weight: 600; color: #1e293b; font-size: 0.92rem; }
.event-session-meta { color: #475569; font-size: 0.86rem; margin-top: 2px; }
.event-session-notes { color: #64748b; font-size: 0.82rem; margin-top: 2px; }
.event-session-more { font-size: 0.82rem; font-weight: 600; color: #C83739; padding: 2px 2px 0; }
.event-sessions-home { margin: 6px 0 0; padding: 0 0 0 16px; list-style: disc; color: #555; font-size: 0.8rem; }
.event-sessions-home li { margin: 0 0 2px; }
.agenda-card .event-sessions { margin-top: 6px; }
.agenda-card .card-actions { display:flex; flex-direction:column; gap:8px; justify-content:flex-start; flex-shrink:0; }
.activity-button { padding:10px 16px; min-width:160px; }
.pager-btn { background:#fff; color:#333 !important; border:1px solid #ddd; padding:8px 12px; border-radius:8px; cursor:pointer; font-weight:600; }
.empty-events { background:#fff; padding:30px; border-radius:12px; color:#777; }
.agenda-month-nav { display:flex; align-items:center; justify-content:center; gap:12px; margin-top:4px; }
.agenda-month-heading { text-align:center; min-width: 12rem; }
.agenda-month-heading h2 { margin: 0; font-size: 1.35rem; color: #1e293b; }
.agenda-month-count { margin: 2px 0 0; font-size: 0.85rem; color: #64748b; }
@media (max-width: 900px) {
    .agenda-card { flex-direction: column; }
    .agenda-card img, .agenda-graphic { width:100%; height:140px; }
    .agenda-card .card-actions { width:100%; }
    .agenda-card .agenda-meta { flex-direction:column; align-items:flex-start; gap:4px; }
    .activity-button { width:100%; min-width:0; }
    .cal-event { font-size: 0.68rem; padding: 3px 4px; border-width: 1px; }
}
@media (max-width: 700px) {
    #calendarGrid { gap: 3px; }
    .cal-dow { font-size: 0.68rem; padding: 4px 0; }
    .cal-dow-full { display: none; }
    .cal-dow-short { display: inline; }
    .cal-cell, .cal-cell--empty { min-height: 64px; padding: 4px; border-radius: 6px; }
    .cal-daynum { font-size: 0.8rem; margin-bottom: 3px; }
    .cal-legend { margin-left: 0; width: 100%; }
    .cal-toolbar { gap: 8px; }
    .agenda-card { padding: 14px; }
    .agenda-month-heading { min-width: 0; flex: 1; }
    .agenda-month-heading h2 { font-size: 1.15rem; }
    .events-controls, .type-filters, .events-filters { width:100%; }
    .events-view-toggle { width: 100%; }
    .events-view-toggle .btn-primary { flex: 1; margin: 0 !important; }
    .events-filters { flex-direction: column; align-items: stretch; }
    .filter-group { flex-direction: column; align-items: stretch; gap: 4px; }
    .event-filter-select { width:100%; min-width:0; }
}
@media (max-width: 480px) {
    .type-filters { flex-direction:column; align-items:stretch; }
    .events-controls { flex-direction:column; align-items:stretch; }
    .cal-cell, .cal-cell--empty { min-height: 56px; padding: 3px; }
    .cal-event { font-size: 0.6rem; }
}

/* --- Shop / merchandise request --- */
.store-lead { max-width: 720px; color: #555; font-size: 1.05rem; }
.store-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    align-items: start;
}
.store-catalog {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 18px;
}
.store-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.store-card-placeholder {
    height: 160px;
    background: #C83739;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1.4rem;
    letter-spacing: 0.08em;
}
.store-gallery { background: #fff; }
.store-gallery-main {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}
.store-gallery-thumbs {
    display: flex;
    gap: 6px;
    padding: 8px;
    overflow-x: auto;
    background: #f1f5f9;
}
.store-gallery-thumbs button {
    flex: 0 0 auto;
    width: 56px;
    border: 2px solid transparent;
    border-radius: 8px;
    padding: 0;
    background: #fff;
    cursor: pointer;
    overflow: hidden;
}
.store-gallery-thumbs button.is-active { border-color: #C83739; }
.store-gallery-thumbs img {
    width: 100%;
    height: 44px;
    object-fit: cover;
    display: block;
}
.store-gallery-thumbs span {
    display: block;
    font-size: 0.65rem;
    font-weight: 700;
    color: #475569;
    padding: 3px 4px 5px;
    text-align: center;
    line-height: 1.2;
}
.store-packs {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.store-packs li {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.92rem;
    color: #334155;
}
.store-packs strong { color: var(--ro-red); font-weight: 700; }
.store-card-options label.store-opt-wide { grid-column: 1 / -1; }
.store-card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.store-card-body h2 { font-size: 1.1rem; margin: 0; color: #1f2937; }
.store-price { margin: 0; font-weight: 700; color: var(--ro-red); }
.store-desc { margin: 0; color: #64748b; font-size: 0.92rem; }
.store-card-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.store-card-options label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.store-card-options select,
.store-card-options input {
    font: inherit;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
    color: #1f2937;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 8px 10px;
    background: #fff;
}
.store-add-btn { width: 100%; margin-top: auto; text-align: center; box-sizing: border-box; }
.store-request {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 18px 16px;
    position: sticky;
    top: 110px;
}
.store-request h2 { margin: 0 0 12px; font-size: 1.15rem; }
.store-cart { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.store-cart li {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: center;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 8px 10px;
    font-size: 0.9rem;
}
.store-remove {
    border: 0;
    background: transparent;
    color: #C83739;
    font-weight: 700;
    cursor: pointer;
    font-size: 0.8rem;
}
.store-cart-empty { color: #64748b; font-size: 0.9rem; margin: 0 0 14px; }
@media (max-width: 900px) {
    .store-layout { grid-template-columns: 1fr; }
    .store-request { position: static; }
}

/* --- Private coaching booking --- */
.coach-book { max-width: 880px; margin: 8px 0 24px; }
.coach-steps {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0;
    margin: 0 0 20px;
}
.coach-steps li {
    font-size: 0.82rem;
    font-weight: 700;
    color: #94a3b8;
    padding: 6px 10px;
    border-radius: 999px;
    background: #f1f5f9;
}
.coach-steps li.is-current { background: #C83739; color: #fff; }
.coach-steps li.is-done { color: #166534; background: #dcfce7; }
.coach-panel h2 { font-size: 1.25rem; margin: 0 0 12px; }
.coach-choice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}
.coach-choice,
.coach-card-btn,
.coach-date-btn,
.coach-time-btn {
    appearance: none;
    border: 1px solid #e2e8f0;
    background: #fff;
    border-radius: 12px;
    padding: 14px;
    text-align: left;
    cursor: pointer;
    font: inherit;
    color: inherit;
}
.coach-choice strong, .coach-card-btn strong { display: block; margin-bottom: 4px; }
.coach-choice span, .coach-card-btn span { color: #64748b; font-size: 0.9rem; }
.coach-choice.is-selected,
.coach-card-btn.is-selected,
.coach-date-btn.is-selected,
.coach-time-btn.is-selected {
    border-color: #C83739;
    box-shadow: 0 0 0 2px rgba(200, 55, 57, 0.18);
}
.coach-card-btn {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}
.coach-card-btn img,
.coach-card-placeholder {
    width: 72px;
    height: 72px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
    background: #C83739;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}
.coach-card-btn p {
    margin: 8px 0 0;
    color: #64748b;
    font-size: 0.88rem;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.coach-price { display: block; color: var(--ro-red) !important; font-weight: 700; margin-top: 4px; }
.coach-price-extra, .coach-arrange-note {
    display: block;
    color: #475569;
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 2px;
}
.coach-dates, .coach-times { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.coach-date-btn, .coach-time-btn { padding: 8px 12px; border-radius: 999px; font-weight: 600; }
.coach-summary {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px 14px;
    margin: 0 0 16px;
    font-weight: 600;
}
.coach-panel-head { margin-bottom: 12px; }
.coach-panel-head h2 { margin: 10px 0 0; }
.coach-back {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: 2px solid #334155;
    background: #fff;
    color: #1f2937;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    padding: 10px 18px;
    border-radius: 999px;
    margin: 0 12px 8px 0;
}
.coach-back:hover,
.coach-back:focus {
    background: #1f2937;
    color: #fff;
    outline: none;
}
.coach-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-top: 8px;
}
.coach-actions .coach-back { margin: 0; }
.coach-form select {
    display: block;
    width: 100%;
    margin-top: 6px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 10px 12px;
    font: inherit;
    background: #fff;
    box-sizing: border-box;
}
@media (max-width: 640px) {
    .coach-card-btn { flex-direction: column; }
}

.ro-rankings-page { margin-top: 8px; }
.ro-rank-lead, .ro-rank-meta, .ro-rank-footnote { max-width: 720px; color: #555; }
.ro-rank-meta { font-size: 0.92rem; }
.ro-rank-footnote { margin-top: 28px; font-size: 0.9rem; color: #64748b; }
.ro-rank-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 20px;
    align-items: flex-end;
    margin: 22px 0 12px;
}
.ro-rank-tabs { display: flex; gap: 8px; }
.ro-rank-tab {
    background: #f1f5f9;
    color: #334155;
    border: none;
    border-radius: 999px;
    padding: 8px 16px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}
.ro-rank-tab.is-active { background: var(--ro-red); color: #fff; }
.ro-rank-filter { display: grid; gap: 4px; font-size: 0.8rem; font-weight: 600; color: #64748b; }
.ro-rank-filter select,
.ro-rank-filter input {
    font: inherit;
    font-weight: 500;
    color: #222;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 8px 10px;
    min-width: 180px;
}
.ro-rank-count { color: #64748b; font-size: 0.9rem; margin: 0 0 10px; }
.ro-rank-panel { display: none; }
.ro-rank-panel.is-active { display: block; }
.ro-rank-table-wrap { overflow-x: auto; background: #fff; border: 1px solid #e5e7eb; border-radius: 12px; }
.ro-rank-table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.ro-rank-table th {
    text-align: left;
    background: #f8fafc;
    padding: 12px 16px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #64748b;
}
.ro-rank-table td { padding: 10px 16px; border-bottom: 1px solid #f1f5f9; }
.ro-rank-table tbody tr:last-child td { border-bottom: none; }
.ro-rank-num, .ro-rank-nat { font-weight: 700; white-space: nowrap; }
.ro-rank-nat { color: #64748b; font-weight: 600; }
.ro-rank-empty { color: #64748b; }