/*
 * WiVor brand layer (site specification, section 2).
 * Loaded after the template CSS. All classes use the "wv-" prefix so they never collide with template classes.
 */
:root {
    --wv-orange: #ff5722;
    --wv-orange-hover: #ff7e55;
    --wv-slate: #303841;
    --wv-light: #eeeeee;
    --wv-white: #ffffff;
    --wv-border: #d4d4d4;
    --wv-font-family: 'Alata', sans-serif;
    --wv-radius: 10px;
    --wv-content-width: 1180px;
    --wv-button-height: 48px;
}

/* Alata on the whole site. Icon fonts use <i>/<span> with their own classes, so they are not listed here. */
body,
body :is(h1, h2, h3, h4, h5, h6, p, a, li, label, input, select, textarea, button, summary, td, th) {
    font-family: var(--wv-font-family);
}

/* Layout */
.wv-container {
    width: 100%;
    max-width: var(--wv-content-width);
    margin: 0 auto;
    padding: 0 16px;
}

.wv-section {
    padding: 56px 0;
}

.wv-section--white { background: var(--wv-white); color: var(--wv-slate); }
.wv-section--light { background: var(--wv-light); color: var(--wv-slate); }
.wv-section--dark { background: var(--wv-slate); color: var(--wv-white); }
.wv-section--orange { background: var(--wv-orange); color: var(--wv-white); }

.wv-section--dark :is(h1, h2, h3, p, li),
.wv-section--orange :is(h1, h2, h3, p, li) {
    color: var(--wv-white);
}

/* Typography (mobile first) */
.wv-h1 { font-size: 34px; line-height: 1.15; color: var(--wv-slate); margin: 0 0 16px; }
.wv-h2 { font-size: 26px; line-height: 1.2; color: var(--wv-slate); margin: 0 0 24px; }
.wv-h3 { font-size: 20px; line-height: 1.3; color: var(--wv-slate); margin: 0 0 8px; }
.wv-body { font-size: 16px; line-height: 1.6; }
.wv-lead { font-size: 16px; line-height: 1.6; max-width: 720px; }
.wv-small { font-size: 14px; line-height: 1.5; margin-top: 16px; }

@media (min-width: 992px) {
    .wv-section { padding: 88px 0; }
    .wv-h1 { font-size: 52px; }
    .wv-h2 { font-size: 36px; }
    .wv-h3 { font-size: 22px; }
    .wv-body,
    .wv-lead { font-size: 17px; }
}

/* Buttons */
.wv-button-row {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 24px;
}

@media (min-width: 576px) {
    .wv-button-row { flex-direction: row; flex-wrap: wrap; }
}

.wv-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: var(--wv-button-height);
    padding: 12px 24px;
    border: 2px solid transparent;
    border-radius: var(--wv-radius);
    font-size: 16px;
    line-height: 1.2;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.wv-btn--primary { background: var(--wv-orange); border-color: var(--wv-orange); color: var(--wv-white); }
.wv-btn--primary:hover,
.wv-btn--primary:focus-visible { background: var(--wv-orange-hover); border-color: var(--wv-orange-hover); color: var(--wv-white); }

.wv-btn--outline { background: transparent; border-color: var(--wv-slate); color: var(--wv-slate); }
.wv-btn--outline:hover,
.wv-btn--outline:focus-visible { background: var(--wv-slate); color: var(--wv-white); }

.wv-section--dark .wv-btn--outline { border-color: var(--wv-white); color: var(--wv-white); }
.wv-section--dark .wv-btn--outline:hover,
.wv-section--dark .wv-btn--outline:focus-visible { background: var(--wv-white); color: var(--wv-slate); }

.wv-btn--inverse { background: var(--wv-white); border-color: var(--wv-white); color: var(--wv-orange); }
.wv-btn--inverse:hover,
.wv-btn--inverse:focus-visible { background: var(--wv-light); border-color: var(--wv-light); color: var(--wv-orange); }

/* Cards, icons, steps, links */
.wv-card {
    height: 100%;
    padding: 24px;
    background: var(--wv-white);
    border: 1px solid var(--wv-border);
    border-radius: var(--wv-radius);
    color: var(--wv-slate);
}

.wv-icon { font-size: 32px; color: var(--wv-orange); margin-bottom: 12px; }
.wv-step-number { font-size: 48px; line-height: 1; color: var(--wv-orange); margin-bottom: 8px; }

.wv-link { color: var(--wv-orange); text-decoration: none; }
.wv-link:hover,
.wv-link:focus-visible { color: var(--wv-orange); text-decoration: underline; }

/* FAQ accordion (native <details>) */
.wv-faq details {
    margin-bottom: 12px;
    background: var(--wv-white);
    border: 1px solid var(--wv-border);
    border-radius: var(--wv-radius);
}

.wv-faq summary {
    min-height: var(--wv-button-height);
    padding: 14px 20px;
    font-size: 18px;
    color: var(--wv-slate);
    cursor: pointer;
}

.wv-faq details > div { padding: 0 20px 16px; }

/* Header (spec section 3): fixed at top, white, colored logo left. */
.wv-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--wv-white);
    border-bottom: 1px solid var(--wv-border);
}

.wv-header__bar {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 72px;
}

.wv-header__logo img { height: 40px; width: auto; }

.wv-header__cta { margin-left: auto; padding: 10px 16px; }

.wv-header__toggle {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 48px;
    height: 48px;
    padding: 12px;
    background: transparent;
    border: 1px solid var(--wv-border);
    border-radius: var(--wv-radius);
}

.wv-header__toggle-bar { display: block; height: 2px; background: var(--wv-slate); }

/* Mobile: links collapse into a panel under the bar. */
.wv-header__nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    padding: 8px 16px 16px;
    background: var(--wv-white);
    border-bottom: 1px solid var(--wv-border);
}

.wv-header__nav.is-open { display: block; }

.wv-header__links,
.wv-header__utility { list-style: none; margin: 0; padding: 0; }

.wv-header__nav a {
    display: flex;
    align-items: center;
    min-height: var(--wv-button-height);
    color: var(--wv-slate);
    text-decoration: none;
}

.wv-header__nav a:hover,
.wv-header__nav a.is-current { color: var(--wv-orange); }

.wv-header__utility { display: flex; gap: 20px; border-top: 1px solid var(--wv-border); margin-top: 8px; }

.wv-header__utility a { position: relative; }

.wv-header__cart-count {
    margin-left: 4px;
    padding: 0 6px;
    border-radius: 9px;
    background: var(--wv-orange);
    color: var(--wv-white);
    font-size: 12px;
}

@media (min-width: 992px) {
    .wv-header__toggle { display: none; }

    .wv-header__nav,
    .wv-header__nav.is-open {
        display: flex;
        position: static;
        align-items: center;
        gap: 24px;
        margin-left: auto;
        padding: 0;
        border: 0;
    }

    .wv-header__links { display: flex; gap: 24px; }

    .wv-header__utility { border-top: 0; margin-top: 0; gap: 16px; }

    .wv-header__cta { margin-left: 0; padding: 12px 24px; }
}

/* Footer (spec section 3): slate background, white logo, four columns. */
.wv-footer {
    padding: 56px 0 24px;
    background: var(--wv-slate);
    color: var(--wv-white);
}

.wv-footer__logo img { height: 40px; width: auto; }

.wv-footer__title { font-size: 16px; color: var(--wv-white); margin: 0 0 12px; }

.wv-footer ul { list-style: none; margin: 0; padding: 0; }

.wv-footer nav a,
.wv-footer__social a {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    color: var(--wv-white);
    text-decoration: none;
}

.wv-footer nav a:hover,
.wv-footer__social a:hover { color: var(--wv-orange-hover); }

.wv-footer__social { display: flex; gap: 16px; margin-top: 16px !important; font-size: 22px; }

.wv-footer__copyright {
    margin: 32px 0 0;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 14px;
    color: var(--wv-white);
}

.wv-footer__credit { margin: 8px 0 0; font-size: 13px; color: rgba(255, 255, 255, 0.7); }

.wv-footer__credit a { color: var(--wv-white); text-decoration: underline; }

.wv-footer__credit a:hover { color: var(--wv-orange-hover); }

/* Keyboard focus: the template CSS removes outlines globally. */
.wv-header__nav a:focus-visible,
.wv-header__toggle:focus-visible,
.wv-footer a:focus-visible,
.wv-faq summary:focus-visible {
    outline: 2px solid var(--wv-orange);
    outline-offset: 2px;
}

/* Home photos */
.wv-hero__image {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--wv-radius);
}

.wv-card__image {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    object-position: center 30%;
    border-radius: var(--wv-radius);
    margin-bottom: 16px;
}

/* Cookie consent (spec section 12): small and out of the way. */
.wv-cookie {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    z-index: 1100;
    padding: 16px;
    background: var(--wv-slate);
    color: var(--wv-white);
    border-radius: var(--wv-radius);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.2);
}

.wv-cookie__text { margin: 0 0 12px; font-size: 14px; line-height: 1.5; color: var(--wv-white); }

.wv-cookie__text a { color: var(--wv-white); text-decoration: underline; }

.wv-cookie__actions { display: flex; gap: 8px; }

.wv-cookie__button { flex: 1; padding: 8px 16px; font-size: 14px; }

.wv-cookie__button--reject { background: transparent; border-color: var(--wv-white); color: var(--wv-white); }

.wv-cookie__button--reject:hover,
.wv-cookie__button--reject:focus-visible { background: var(--wv-white); color: var(--wv-slate); }

.wv-cookie a:focus-visible,
.wv-cookie__button:focus-visible { outline: 2px solid var(--wv-orange-hover); outline-offset: 2px; }

@media (min-width: 576px) {
    .wv-cookie { right: auto; max-width: 360px; }
    .wv-cookie__button { flex: 0 0 auto; }
}

/* Event directory: live, upcoming and past groups. */
.wv-events-group { margin-bottom: 56px; }

/* Divider: heading and count over a thin bar that starts with a short orange segment. */
.wv-events-group__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 12px;
    margin-bottom: 24px;
    background: linear-gradient(to right, var(--wv-orange) 0 56px, var(--wv-border) 56px) bottom / 100% 2px no-repeat;
}

.wv-events-group__title { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 24px; line-height: 1.2; color: var(--wv-slate); }
.wv-events-group__count { margin: 0; font-size: 14px; color: #6b7280; white-space: nowrap; }
.wv-events-group__note { margin: -12px 0 24px; font-size: 15px; }

.wv-events-grid { display: grid; gap: 24px; grid-template-columns: 1fr; }

@media (min-width: 768px) { .wv-events-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 992px) { .wv-events-grid { grid-template-columns: repeat(3, 1fr); } }

/* Live group: slate panel so it stands apart from the rest of the page. */
.wv-events-group--live {
    padding: 28px 20px;
    background: var(--wv-slate);
    border-radius: calc(var(--wv-radius) * 2);
}

.wv-events-group--live .wv-events-group__head {
    background-image: linear-gradient(to right, var(--wv-orange) 0 56px, rgba(255, 255, 255, 0.2) 56px);
}

.wv-events-group--live :is(.wv-events-group__title, .wv-events-group__note) { color: var(--wv-white); }
.wv-events-group--live .wv-events-group__count { color: rgba(255, 255, 255, 0.7); }

@media (min-width: 992px) { .wv-events-group--live { padding: 40px; } }

.wv-live-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--wv-orange);
    box-shadow: 0 0 0 0 rgba(255, 87, 34, 0.6);
    animation: wv-live-pulse 2s ease-out infinite;
}

@keyframes wv-live-pulse {
    to { box-shadow: 0 0 0 10px rgba(255, 87, 34, 0); }
}

@media (prefers-reduced-motion: reduce) { .wv-live-dot { animation: none; } }

/* Event card */
.wv-event-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    background: var(--wv-white);
    border: 1px solid var(--wv-border);
    border-radius: var(--wv-radius);
}

.wv-events-group--live .wv-event-card { border-color: transparent; }

.wv-event-card__media img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }

.wv-event-card__body { display: flex; flex-direction: column; flex: 1; padding: 20px; }
.wv-event-card__sport { margin: 0 0 6px; font-size: 14px; color: var(--wv-orange); }
.wv-event-card__title { margin: 0 0 8px; font-size: 20px; line-height: 1.3; }
.wv-event-card__title a { color: var(--wv-slate); text-decoration: none; }
.wv-event-card__title a:hover { color: var(--wv-orange); }
.wv-event-card__meta { margin: 0 0 16px; font-size: 15px; line-height: 1.5; color: #6b7280; }
.wv-event-card__status { margin: auto 0 0; font-size: 15px; color: var(--wv-slate); }
.wv-event-card__action { margin-top: auto; align-self: flex-start; }

/* Past events step back so the current ones lead. */
.wv-events-group--past .wv-event-card__media img { filter: saturate(0.6); }

.wv-event-card a:focus-visible { outline: 2px solid var(--wv-orange); outline-offset: 2px; }
