/* ============================================================
   Nuhu Dolorosa Charity Run – Public site design layer
   Loaded after style.css on public pages only (body.site).
   Admin pages keep using style.css on its own.

   Art direction: a dawn trail start in the Crocker foothills —
   deep dusk ink, brand plum/violet, and a sunrise gold.
   ============================================================ */

.site {
    /* Colour */
    --ink:        #160d2b;
    --ink-2:      #211440;
    --ink-3:      #2d1c56;
    --plum:       #6B21A8;
    --violet:     #7C3AED;
    --violet-l:   #B79CFF;
    --violet-bg:  #F3EEFF;
    --gold:       #F5B014;
    --gold-d:     #A86F00;   /* gold for text on light backgrounds (AA large) */
    --gold-bg:    #FFF6DD;
    --gold-ink:   #231700;
    --paper:      #FAF7F2;
    --surface:    #ffffff;
    --line:       #E9E3F2;
    --line-2:     #D9CFEA;
    --text:       #2A2340;
    --muted:      #5F5876;
    --on-dark:    rgba(255,255,255,.78);
    --green:      #15803d;
    --green-bg:   #ECFDF3;

    /* Type */
    --font-body:    'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-display: 'Barlow Condensed', 'Arial Narrow', sans-serif;

    /* Shape & depth */
    --r-sm:   10px;
    --r-md:   16px;
    --r-lg:   24px;
    --r-pill: 999px;
    --sh-1:   0 1px 2px rgba(22,13,43,.06), 0 2px 10px rgba(22,13,43,.05);
    --sh-2:   0 10px 30px rgba(22,13,43,.10);
    --sh-3:   0 24px 60px rgba(22,13,43,.20);

    /* Rhythm & motion */
    --section-y: clamp(64px, 9vw, 112px);
    --ease:      cubic-bezier(.2,.7,.2,1);

    /* Re-point the shared style.css variables so inner pages pick up the new look */
    --primary:   var(--plum);
    --primary-m: var(--violet);
    --gold-l:    #FFC94A;
    --dark:      var(--ink);
    --font-main: var(--font-body);
    --font-head: var(--font-display);

    font-family: var(--font-body);
    color: var(--text);
    background: var(--surface);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

html { scroll-padding-top: 84px; }
.site h1, .site h2, .site h3 { font-family: var(--font-display); color: var(--ink); letter-spacing: .01em; }
.site h4, .site h5, .site h6 { font-family: var(--font-body); color: var(--ink); font-weight: 700; letter-spacing: -.01em; }
.site a { color: var(--violet); }
.site a:hover { color: var(--plum); }
.site img { height: auto; }
.site .text-primary { color: var(--violet) !important; }
.site .text-warning { color: var(--gold-d) !important; }
.site ::selection { background: var(--gold); color: var(--gold-ink); }

/* Focus: one clear, consistent ring everywhere */
.site :focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
    border-radius: 6px;
}
.site .form-control:focus-visible,
.site .form-select:focus-visible { outline: none; }

.skip-link {
    position: absolute;
    left: 16px; top: -60px;
    z-index: 2000;
    background: var(--gold);
    color: var(--gold-ink) !important;
    font-weight: 700;
    padding: 10px 18px;
    border-radius: var(--r-pill);
    transition: top .2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ============================================================
   NAVBAR
   ============================================================ */
.site #mainNav {
    background: rgba(22,13,43,.86);
    -webkit-backdrop-filter: saturate(160%) blur(14px);
    backdrop-filter: saturate(160%) blur(14px);
    border-bottom: 1px solid rgba(255,255,255,.08);
    box-shadow: none;
    padding: 10px 0;
}
.site #mainNav.scrolled {
    background: rgba(22,13,43,.96);
    box-shadow: 0 8px 30px rgba(0,0,0,.25);
    padding: 6px 0;
}
.site .brand-logo-img {
    width: 42px; height: 42px;
    padding: 2px;
    background: #fff;
    box-shadow: 0 0 0 2px rgba(245,176,20,.5);
}
.site .brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.site .brand-name {
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 800;
    letter-spacing: .02em;
    text-transform: uppercase;
    color: #fff;
}
.site .brand-sub {
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: .14em;
    color: var(--gold);
}
.site .navbar-nav { gap: 2px; }
.site .navbar-nav .nav-link {
    position: relative;
    color: rgba(255,255,255,.82) !important;
    font-weight: 500;
    font-size: 15px;
    padding: 8px 14px !important;
    border-radius: var(--r-sm);
}
.site .navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    left: 14px; right: 14px; bottom: 4px;
    height: 2px;
    background: var(--gold);
    border-radius: 2px;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .25s var(--ease);
}
.site .navbar-nav .nav-link:hover { color: #fff !important; background: transparent; }
.site .navbar-nav .nav-link:hover::after { transform: scaleX(1); }

.site .nav-social { display: flex; align-items: center; gap: 2px; margin-left: 6px; }
.site .nav-icon {
    width: 36px; height: 36px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    color: rgba(255,255,255,.75);
    font-size: 15px;
}
.site .nav-icon:hover { color: var(--gold); background: rgba(255,255,255,.08); }
.site .nav-actions { display: flex; align-items: center; gap: 10px; margin-left: 10px; }

.site .btn-lang-toggle {
    background: transparent;
    border: 1px solid rgba(255,255,255,.28);
    color: #fff;
    padding: 7px 14px;
    font-size: 13px;
}
.site .btn-lang-toggle:hover { background: rgba(255,255,255,.1); color: #fff; transform: none; }

.site .btn-register {
    background: var(--gold);
    color: var(--gold-ink) !important;
    border-radius: var(--r-pill);
    font-weight: 700;
    font-size: 14px;
    padding: 9px 20px !important;
    transition: background .2s, transform .2s var(--ease), box-shadow .2s;
}
.site .btn-register:hover { background: #FFC94A; transform: translateY(-1px); box-shadow: 0 8px 24px rgba(245,176,20,.35); }

/* Burger → X */
.site .navbar-toggler {
    border: 1px solid rgba(255,255,255,.22);
    border-radius: var(--r-sm);
    padding: 10px 10px;
}
.site .navbar-toggler:focus { box-shadow: none; }
.nav-burger { display: grid; gap: 5px; width: 22px; }
.nav-burger span {
    display: block; height: 2px; border-radius: 2px;
    background: #fff;
    transition: transform .25s var(--ease), opacity .2s;
}
.navbar-toggler[aria-expanded="true"] .nav-burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.navbar-toggler[aria-expanded="true"] .nav-burger span:nth-child(2) { opacity: 0; }
.navbar-toggler[aria-expanded="true"] .nav-burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 991.98px) {
    .site #navMenu .navbar-nav {
        padding: 14px 0 18px;
        margin-top: 10px;
        border-top: 1px solid rgba(255,255,255,.1);
        align-items: stretch !important;
    }
    .site .navbar-nav .nav-link { font-size: 17px; padding: 12px 4px !important; }
    .site .navbar-nav .nav-link::after { left: 4px; right: auto; width: 28px; }
    .site .nav-social { margin: 6px 0 0; }
    .site .nav-actions { margin: 14px 0 0; }
    .site .nav-actions .btn-register { flex: 1; text-align: center; padding: 12px 20px !important; }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.site .btn {
    font-family: var(--font-body);
    font-weight: 700;
    letter-spacing: .005em;
    transition: background .2s, color .2s, border-color .2s, transform .2s var(--ease), box-shadow .2s;
}
.site .btn:active { transform: translateY(1px) scale(.99); }

.site .btn-hero-primary,
.site .btn-cta {
    background: var(--gold);
    color: var(--gold-ink);
    border: none;
    border-radius: var(--r-pill);
    padding: 15px 30px;
    font-size: 16px;
    box-shadow: 0 10px 30px rgba(245,176,20,.28);
}
.site .btn-hero-primary:hover,
.site .btn-cta:hover {
    background: #FFC94A;
    color: var(--gold-ink);
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(245,176,20,.4);
}
.site .btn-hero-outline {
    background: rgba(255,255,255,.04);
    color: #fff;
    border: 1.5px solid rgba(255,255,255,.4);
    border-radius: var(--r-pill);
    padding: 14px 28px;
    font-size: 16px;
}
.site .btn-hero-outline:hover { background: rgba(255,255,255,.12); border-color: #fff; color: #fff; }
.site .btn-hero-secondary { border-radius: var(--r-pill); }

.site .btn-primary-custom {
    background: var(--ink);
    color: #fff;
    border: none;
    border-radius: var(--r-pill);
    padding: 14px 28px;
    display: inline-flex;
    align-items: center;
}
.site .btn-primary-custom:hover {
    background: var(--plum);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(107,33,168,.3);
}

.btn-copy {
    display: inline-flex; align-items: center;
    margin-left: 10px;
    padding: 4px 12px;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--ink);
    background: #fff;
    border: 1px solid var(--line-2);
    border-radius: var(--r-pill);
    cursor: pointer;
    transition: background .2s, border-color .2s;
}
.btn-copy:hover { background: var(--violet-bg); border-color: var(--violet-l); }
.btn-copy-light {
    margin: 18px 0 0;
    background: rgba(255,255,255,.1);
    color: #fff;
    border-color: rgba(255,255,255,.3);
    padding: 8px 16px;
    font-size: 13px;
}
.btn-copy-light:hover { background: rgba(255,255,255,.2); border-color: #fff; }

.round-btn {
    width: 48px; height: 48px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,.3);
    background: transparent;
    color: #fff;
    cursor: pointer;
    transition: background .2s, border-color .2s, color .2s;
}
.round-btn:hover { background: var(--gold); border-color: var(--gold); color: var(--gold-ink); }

/* ============================================================
   SECTION SCAFFOLDING
   ============================================================ */
.section { padding: var(--section-y) 0; position: relative; }
.section-head { margin-bottom: clamp(36px, 5vw, 56px); }
.section-head.text-center { max-width: 760px; margin-left: auto; margin-right: auto; }
.section-head-split {
    display: flex; align-items: flex-end; justify-content: space-between; gap: 24px;
}

.site .section-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: none;
    padding: 0;
    border-radius: 0;
    color: var(--violet);
    font-family: var(--font-body);
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
    margin-bottom: 14px;
}
.site .section-label::before {
    content: '';
    width: 28px; height: 2px;
    background: currentColor;
    border-radius: 2px;
}
.site .section-label-dark { color: var(--gold); }

.site .section-title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5.4vw, 3.9rem);
    font-weight: 800;
    line-height: .95;
    text-transform: uppercase;
    letter-spacing: .005em;
    margin-bottom: 16px;
    text-wrap: balance;
}
.site .section-title.text-white .text-warning,
.site .categories-section .section-title .text-warning,
.site .gallery-section .section-title .text-warning { color: var(--gold) !important; }

.section-sub { font-size: 1.075rem; color: var(--on-dark); margin: 0; max-width: 620px; }
.section-head.text-center .section-sub { margin: 0 auto; }
.section-sub-muted { color: var(--muted); }

.prose p, p.prose { font-size: 1.04rem; color: var(--muted); line-height: 1.8; }
.prose .lead-p { font-size: 1.15rem; color: var(--text); }
.prose strong, p.prose strong { color: var(--text); }

/* Scroll reveal (only active once html.reveal-ready is set) */
.reveal-ready .reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.reveal-ready .reveal.is-in { opacity: 1; transform: none; }
.reveal-ready .stats-grid > .reveal:nth-child(2),
.reveal-ready .steps > .reveal:nth-child(2),
.reveal-ready .row > :nth-child(2) > .reveal { transition-delay: .08s; }
.reveal-ready .stats-grid > .reveal:nth-child(3),
.reveal-ready .steps > .reveal:nth-child(3),
.reveal-ready .row > :nth-child(3) > .reveal { transition-delay: .16s; }
.reveal-ready .stats-grid > .reveal:nth-child(4),
.reveal-ready .steps > .reveal:nth-child(4),
.reveal-ready .row > :nth-child(4) > .reveal { transition-delay: .24s; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
    position: relative;
    overflow: hidden;
    background: var(--ink);
    color: #fff;
    min-height: min(92vh, 880px);
    display: flex;
    align-items: center;
    padding: 72px 0 150px;
    isolation: isolate;
}
.hero-bg {
    position: absolute;
    inset: -4%;
    z-index: -2;
    background:
        linear-gradient(90deg, rgba(22,13,43,.97) 0%, rgba(22,13,43,.9) 38%, rgba(22,13,43,.55) 62%, rgba(22,13,43,.3) 100%),
        linear-gradient(0deg, var(--ink) 0%, rgba(22,13,43,0) 35%),
        url('../images/hero-bg.jpeg') center 35% / cover no-repeat;
    animation: hero-drift 30s ease-in-out infinite alternate;
    will-change: transform;
}
@keyframes hero-drift {
    from { transform: scale(1); }
    to   { transform: scale(1.06) translate(-1%, -1%); }
}
.site #hero-canvas {
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: .7;
    pointer-events: none;
    cursor: default;
}
.hero-inner { position: relative; }

.site .hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(245,176,20,.14);
    border: 1px solid rgba(245,176,20,.55);
    color: var(--gold);
    padding: 7px 16px;
    border-radius: var(--r-pill);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .04em;
    margin-bottom: 22px;
}
.site .hero-title {
    font-family: var(--font-display);
    font-size: clamp(4.2rem, 11.5vw, 9rem);
    font-weight: 800;
    line-height: .84;
    text-transform: uppercase;
    letter-spacing: -.005em;
    color: #fff;
    text-shadow: 0 4px 30px rgba(0,0,0,.35);
    margin-bottom: 22px;
}
.hero-title-accent {
    display: inline-block;
    color: var(--gold);
    background: linear-gradient(100deg, #FFD36B 0%, var(--gold) 45%, #FF9F2E 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.site .hero-event-name {
    font-size: clamp(1.1rem, 2.2vw, 1.35rem);
    font-weight: 600;
    color: #fff;
    margin-bottom: 22px;
    text-shadow: none;
}
.hero-distances {
    display: block;
    margin-top: 4px;
    font-family: var(--font-display);
    font-size: 1.05em;
    font-weight: 700;
    letter-spacing: .12em;
    color: var(--violet-l);
}
.hero-meta {
    list-style: none;
    padding: 0;
    margin: 0 0 30px;
    display: flex; flex-wrap: wrap; gap: 10px;
}
.site .meta-chip {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.18);
    color: #fff;
    padding: 8px 14px;
    border-radius: var(--r-pill);
    font-size: 13.5px;
    font-weight: 500;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}
.site .meta-chip i { color: var(--gold); }
.site .meta-chip-link { color: #fff; }
.site .meta-chip-link:hover { color: #fff; background: rgba(255,255,255,.16); border-color: rgba(255,255,255,.4); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Hero entrance — runs once */
.site .hero-badge, .site .hero-title, .site .hero-event-name, .hero-meta, .hero-actions {
    animation: hero-rise .8s var(--ease) both;
}
.site .hero-title      { animation-delay: .08s; }
.site .hero-event-name { animation-delay: .16s; }
.hero-meta             { animation-delay: .22s; }
.hero-actions          { animation-delay: .28s; }
@keyframes hero-rise {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: none; }
}

/* Race bib countdown — a wide bib below the hero photo (never covers it) */
.race-bib {
    position: relative;
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 2fr;
    margin: 0 0 36px;
    background: #FBF8F1;
    color: var(--ink);
    border-radius: 18px;
    box-shadow: var(--sh-3);
    overflow: hidden;
}
.race-bib::before, .race-bib::after {   /* safety pins */
    content: "";
    position: absolute;
    top: 14px;
    width: 12px; height: 12px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #fff, #b9b3c7 60%, #8d86a0);
    box-shadow: 0 1px 2px rgba(0,0,0,.3);
    z-index: 1;
}
.race-bib::before { left: 14px; }
.race-bib::after  { right: 14px; }
.race-bib-info {
    display: flex; align-items: center; gap: 14px;
    padding: 22px 28px 22px 36px;
    background: linear-gradient(120deg, var(--plum), var(--violet));
    color: #fff;
}
.race-bib-info img { border-radius: 50%; background: #fff; padding: 2px; flex-shrink: 0; }
.race-bib-event {
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    line-height: 1.05;
}
.race-bib-meta { font-size: 13px; font-weight: 500; color: rgba(255,255,255,.85); margin-top: 2px; }
.site .race-bib .countdown-box {
    animation: none;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    align-items: center;
    gap: 0;
    padding: 20px 36px 18px 24px;
}
.site .race-bib .countdown-unit {
    background: none;
    border: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    border-radius: 0;
    padding: 0 4px;
    min-width: 0;
    text-align: center;
}
.site .race-bib .countdown-unit + .countdown-unit { border-left: 1px dashed var(--line-2); }
.site .race-bib .count-num {
    font-family: var(--font-display);
    font-size: clamp(2.4rem, 5vw, 3.4rem);
    font-weight: 800;
    color: var(--ink);
    line-height: 1;
    font-variant-numeric: tabular-nums;
}
.site .race-bib .count-label {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .14em;
    margin-top: 6px;
}
.raceday-msg {
    grid-column: 1 / -1;
    margin: 0;
    text-align: center;
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--plum);
}
.hero-photo-btn {
    position: absolute;
    right: 24px; bottom: 112px;
    z-index: 2;
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(0,0,0,.35);
    color: rgba(255,255,255,.9);
    border: 1px solid rgba(255,255,255,.25);
    border-radius: var(--r-pill);
    padding: 8px 16px;
    font-size: 12.5px;
    font-weight: 500;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    cursor: zoom-in;
    transition: background .2s, border-color .2s;
}
.hero-photo-btn:hover { background: rgba(0,0,0,.55); border-color: rgba(255,255,255,.5); }

/* Ridgeline divider */
.hero-ridge {
    position: absolute;
    left: 0; right: 0; bottom: -1px;
    width: 100%;
    height: clamp(70px, 9vw, 130px);
    z-index: 1;
    pointer-events: none;
}
.ridge-back  { fill: #24164a; opacity: .85; }
.ridge-front { fill: var(--ink); }
.ridge-trail {
    fill: none;
    stroke: var(--gold);
    stroke-width: 2;
    stroke-dasharray: 2 10;
    stroke-linecap: round;
    opacity: .9;
    vector-effect: non-scaling-stroke;
    animation: trail-march 2.4s linear infinite;
}
@keyframes trail-march { to { stroke-dashoffset: -48; } }

/* ============================================================
   STATS BAND
   ============================================================ */
.stats-band { background: var(--ink); color: #fff; padding: 8px 0 56px; }
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border-top: 1px solid rgba(255,255,255,.1);
    border-bottom: 1px solid rgba(255,255,255,.1);
}
.stat-tile {
    display: flex; align-items: center; gap: 16px;
    padding: 26px 22px;
}
.stat-tile + .stat-tile { border-left: 1px solid rgba(255,255,255,.1); }
.stat-tile > i {
    flex-shrink: 0;
    width: 46px; height: 46px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 12px;
    background: rgba(245,176,20,.12);
    color: var(--gold);
    font-size: 18px;
}
.site .stat-value {
    font-family: var(--font-display);
    font-size: clamp(1.9rem, 3.2vw, 2.5rem);
    font-weight: 800;
    color: #fff;
    line-height: 1;
}
.site .stat-label { font-size: 13px; color: var(--on-dark); margin-top: 4px; font-weight: 500; }

/* ============================================================
   ABOUT
   ============================================================ */
.site .about-section { background: var(--paper); }
.about-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-2);
    padding: 36px 28px 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.about-card::before {
    content: '';
    position: absolute;
    inset: 0 0 auto 0;
    height: 6px;
    background: linear-gradient(90deg, var(--plum), var(--violet), var(--gold));
}
.about-logo { width: 132px; height: 132px; object-fit: contain; margin-bottom: 14px; }
.site .about-card-title {
    font-size: 2.2rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 4px;
}
.about-card-meta { color: var(--muted); font-size: 14px; margin-bottom: 22px; }
.about-distances {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid var(--line);
    padding-top: 20px;
}
.about-distances > div + div { border-left: 1px solid var(--line); }
.about-distances span {
    display: block;
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 800;
    color: var(--plum);
    line-height: 1;
}
.about-distances small { color: var(--muted); font-size: 12.5px; font-weight: 500; }

.note-card {
    display: flex; gap: 16px; align-items: flex-start;
    border-radius: var(--r-md);
    padding: 20px 22px;
    margin: 24px 0;
    border: 1px solid transparent;
}
.note-violet { background: var(--violet-bg); border-color: #E2D6FF; }
.note-gold   { background: var(--gold-bg);   border-color: #F6DE9A; }
.note-icon {
    flex-shrink: 0;
    width: 42px; height: 42px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 12px;
    background: #fff;
    font-size: 16px;
}
.note-violet .note-icon { color: var(--violet); }
.note-gold .note-icon   { color: var(--gold-d); }
.site .note-title { font-family: var(--font-body); font-size: 1rem; font-weight: 700; margin-bottom: 6px; }
.note-card p { color: var(--text); font-size: 14.5px; line-height: 1.7; }

.bank-dl {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 6px 18px;
    margin: 0;
    font-size: 14.5px;
}
.bank-dl dt { font-weight: 500; color: var(--muted); }
.bank-dl dd { margin: 0; font-weight: 700; color: var(--ink); display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.acc-num {
    font-family: var(--font-display);
    font-size: 1.35rem;
    letter-spacing: .06em;
    color: var(--plum);
}

.feature-grid {
    list-style: none;
    padding: 0;
    margin: 0 0 32px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px 24px;
}
.site .feature-item {
    display: flex; align-items: flex-start; gap: 12px;
    padding: 0;
    font-weight: 500;
    color: var(--text);
    font-size: 15px;
}
.site .feature-item i {
    flex-shrink: 0;
    width: 24px; height: 24px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: var(--ink);
    color: var(--gold);
    font-size: 11px;
    margin-top: 1px;
}

/* ============================================================
   CATEGORIES
   ============================================================ */
.site .categories-section {
    background:
        radial-gradient(1000px 500px at 50% -10%, rgba(124,58,237,.35), transparent 60%),
        radial-gradient(700px 400px at 100% 100%, rgba(245,176,20,.10), transparent 60%),
        var(--ink);
    color: #fff;
}
.site .category-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    text-align: left;
    color: #fff;
    background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
    border: 1px solid rgba(255,255,255,.12);
    border-radius: var(--r-lg);
    padding: 30px 28px 26px;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    transition: transform .35s var(--ease), border-color .35s, box-shadow .35s, background .35s;
}
.site .category-card:hover {
    transform: translateY(-6px);
    background: linear-gradient(180deg, rgba(255,255,255,.09), rgba(255,255,255,.03));
    border-color: rgba(255,255,255,.25);
    box-shadow: 0 30px 60px rgba(0,0,0,.35);
}
.site .category-card.featured {
    background: linear-gradient(180deg, rgba(245,176,20,.16), rgba(124,58,237,.10));
    border-color: rgba(245,176,20,.7);
    box-shadow: 0 0 0 1px rgba(245,176,20,.25), 0 30px 70px rgba(245,176,20,.12);
}
.site .category-badge-top {
    top: -13px; left: 28px;
    transform: none;
    background: var(--gold);
    color: var(--gold-ink);
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    padding: 5px 14px;
}
.category-head { display: flex; justify-content: space-between; align-items: flex-start; }
.site .category-km {
    font-family: var(--font-display);
    font-size: clamp(3.8rem, 6vw, 4.8rem);
    font-weight: 800;
    line-height: .85;
    color: #fff;
    letter-spacing: -.01em;
}
.site .featured .category-km { color: var(--gold); }
.site .category-icon {
    width: 48px; height: 48px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 14px;
    background: rgba(255,255,255,.08);
    color: var(--gold);
    font-size: 20px;
    margin: 0;
}
.site .category-name {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #fff;
    margin: 16px 0 6px;
}
.site .category-desc { font-size: 14px; color: var(--on-dark); margin-bottom: 18px; }
.site .category-price {
    margin: 0 0 18px;
    padding-bottom: 18px;
    border-bottom: 1px dashed rgba(255,255,255,.18);
}
.site .price-currency { font-size: 1rem; font-weight: 600; color: var(--on-dark); margin: 6px 4px 0 0; }
.site .price-amount {
    font-family: var(--font-display);
    font-size: 3.4rem;
    font-weight: 800;
    color: #fff;
}
.site .category-perks { margin: 0 0 24px; }
.site .category-perks li { font-size: 14.5px; color: rgba(255,255,255,.88); gap: 10px; padding: 5px 0; }
.site .category-perks li i { color: var(--gold); }
.category-foot { margin-top: auto; }
.site .btn-category-register {
    background: #fff;
    color: var(--ink);
    border-radius: var(--r-pill);
    padding: 13px 22px;
    font-size: 15px;
}
.site .btn-category-register:hover { background: var(--gold); color: var(--gold-ink); }
.site .featured .btn-category-register { background: var(--gold); color: var(--gold-ink); }
.site .featured .btn-category-register:hover { background: #FFC94A; }
.site .btn-category-register.disabled { background: rgba(255,255,255,.15); color: rgba(255,255,255,.7); }
.site .slot-bar { margin-top: 16px; }
.site .slot-bar small { color: var(--on-dark); font-size: 12.5px; }
.slot-track {
    height: 6px;
    margin-top: 6px;
    background: rgba(255,255,255,.12);
    border-radius: var(--r-pill);
    overflow: hidden;
}
.slot-fill { height: 100%; background: linear-gradient(90deg, var(--gold), #FF9F2E); border-radius: inherit; }

.site .shirt-note {
    display: flex; align-items: flex-start; gap: 12px;
    max-width: 860px;
    margin: 40px auto 0;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.14);
    color: rgba(255,255,255,.88);
    border-radius: var(--r-md);
    padding: 16px 22px;
    font-size: 14.5px;
}
.site .shirt-note i { color: var(--gold); margin-top: 4px; }

/* ============================================================
   FINISHER REWARDS (medal & finisher T-shirt)
   ============================================================ */
.rewards-section { background: var(--paper); }
.reward-card { display: flex; flex-direction: column; gap: 20px; height: 100%; }
.panel.reward-card-dark {
    background:
        radial-gradient(500px 260px at 100% 0%, rgba(220,38,38,.28), transparent 60%),
        var(--ink);
    border-color: rgba(255,255,255,.08);
    color: #fff;
}
.site .reward-card-dark .panel-title { color: #fff; }
.reward-card-dark .panel-kicker { color: #FF8A80; }
.reward-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.reward-icon {
    flex-shrink: 0;
    width: 48px; height: 48px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 14px;
    background: var(--gold-bg);
    color: var(--gold-d);
    font-size: 20px;
}
.reward-card-dark .reward-icon { background: rgba(255,255,255,.08); color: var(--gold); }
.reward-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.reward-photo {
    position: relative;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    background: #fff;
    cursor: zoom-in;
    overflow: hidden;
    transition: transform .3s var(--ease), box-shadow .3s;
}
.reward-photo:hover { transform: translateY(-3px); box-shadow: var(--sh-2); }
.reward-photo img {
    display: block;
    width: 100%;
    aspect-ratio: 7 / 8;
    object-fit: contain;
    transition: transform .5s var(--ease);
}
.reward-photo:hover img { transform: scale(1.04); }
.reward-tag {
    position: absolute;
    top: 8px; left: 8px;
    z-index: 1;
    padding: 3px 9px;
    border-radius: 999px;
    background: var(--ink);
    color: #fff;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.reward-card-dark .reward-tag { background: var(--gold); color: var(--ink); }

/* Finisher T-shirt thumbnails on the registration form */
.shirt-preview { display: flex; align-items: center; gap: 8px; margin: 10px 0 12px; }
.shirt-preview-btn {
    padding: 4px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    cursor: zoom-in;
    transition: transform .2s var(--ease), box-shadow .2s;
}
.shirt-preview-btn:hover { transform: translateY(-2px); box-shadow: var(--sh-2); }
.shirt-preview-btn img { display: block; width: 56px; height: 64px; object-fit: contain; }
.shirt-preview-text { font-size: .8rem; color: var(--muted); }
.spec-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin: 0;
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    overflow: hidden;
}
.spec-list > div { padding: 12px 14px; }
.spec-list > div + div { border-left: 1px solid var(--line); }
.spec-list dt { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.spec-list dd {
    margin: 2px 0 0;
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--ink);
    line-height: 1.1;
}
.reward-size-btn { align-self: flex-start; margin: -4px 0 0; padding: 8px 16px; font-size: 13.5px; }
.reward-points { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.reward-points li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; color: rgba(255,255,255,.88); }
.reward-points i { color: var(--gold); margin-top: 4px; width: 16px; }
.reward-points strong { color: var(--gold); }
.reward-card-dark .btn-hero-primary { margin-top: auto; }

/* ============================================================
   SHIRT SHOWCASE
   ============================================================ */
.shirt-section { background: var(--surface); }
/* Column widths follow each photo's own shape (1080×736 and 925×1280) so neither is cropped */
.shirt-photos {
    display: grid;
    grid-template-columns: 2.03fr 1fr;
    gap: 14px;
    align-items: start;
}
.shirt-photo-wide { aspect-ratio: 1080 / 736; }
.shirt-photo:not(.shirt-photo-wide) { aspect-ratio: 925 / 1280; }
.shirt-photo {
    padding: 0;
    border: 0;
    border-radius: var(--r-lg);
    overflow: hidden;
    background: var(--violet-bg);
    cursor: zoom-in;
    box-shadow: var(--sh-1);
}
.shirt-photo img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform .6s var(--ease);
}
.shirt-photo:hover img { transform: scale(1.04); }
.shirt-placeholder {
    background: var(--violet-bg);
    border-radius: var(--r-lg);
    padding: 60px;
    text-align: center;
    color: var(--muted);
}
.shirt-placeholder i { font-size: 4rem; color: var(--violet-l); }
.zoom-hint { text-align: center; color: var(--muted); font-size: 13px; margin: 14px 0 0; }

.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-2);
    padding: 32px;
}
.site .panel-title { font-size: 1.9rem; font-weight: 800; text-transform: uppercase; margin-bottom: 2px; }
.panel-kicker { color: var(--violet); font-weight: 600; margin-bottom: 20px; }
.icon-list { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 12px; }
.icon-list li { display: flex; align-items: center; gap: 12px; font-size: 14.5px; color: var(--text); }
.icon-dot {
    flex-shrink: 0;
    width: 32px; height: 32px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: var(--violet-bg);
    color: var(--violet);
    font-size: 13px;
}
.price-row {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    border-radius: var(--r-md);
    padding: 14px 16px;
    margin-bottom: 10px;
    border: 1px solid transparent;
}
.price-row-green  { background: var(--green-bg); border-color: #A7EBC0; }
.price-row-violet { background: var(--violet-bg); border-color: #E2D6FF; }
.price-row-gold   { background: var(--gold-bg); border-color: #F6DE9A; }
.price-row-title { font-weight: 700; font-size: 14.5px; color: var(--ink); }
.price-row-green .price-row-title { color: var(--green); }
.price-row-note { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.price-row-amount {
    flex-shrink: 0;
    font-family: var(--font-display);
    font-size: 1.7rem;
    font-weight: 800;
    color: var(--plum);
}
.price-row-gold .price-row-amount { color: var(--gold-d); }
.pill {
    flex-shrink: 0;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .06em;
    padding: 5px 12px;
    border-radius: var(--r-pill);
}
.pill-green { background: var(--green); color: #fff; }
.info-note {
    display: flex; align-items: flex-start;
    background: #EEF4FF;
    border: 1px solid #CFE0FF;
    color: #1E40AF;
    border-radius: var(--r-sm);
    padding: 12px 14px;
    font-size: 13.5px;
    margin: 16px 0 20px;
}
.info-note i { margin-top: 3px; }

/* ============================================================
   SIZE CHART
   ============================================================ */
.size-section { background: var(--paper); }
.size-chart-btn {
    display: inline-block;
    padding: 0;
    border: 0;
    background: #fff;
    border-radius: var(--r-lg);
    overflow: hidden;
    box-shadow: var(--sh-2);
    cursor: zoom-in;
    max-width: 720px;
    width: 100%;
    transition: transform .35s var(--ease), box-shadow .35s;
}
.size-chart-btn:hover { transform: translateY(-4px); box-shadow: var(--sh-3); }
.size-chart-btn img { display: block; width: 100%; }

/* ============================================================
   GALLERY
   ============================================================ */
.gallery-section {
    background: linear-gradient(180deg, var(--ink-2), var(--ink));
    color: #fff;
    overflow: hidden;
}
.gallery-controls { display: flex; gap: 10px; flex-shrink: 0; }
.gallery-track {
    list-style: none;
    margin: 0;
    display: flex;
    gap: 16px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    /* line the first card up with the container edge */
    padding: 4px max(16px, calc((100vw - 1320px) / 2 + 12px)) 20px;
    scroll-padding-inline: max(16px, calc((100vw - 1320px) / 2 + 12px));
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.25) transparent;
}
.gallery-track::-webkit-scrollbar { height: 6px; }
.gallery-track::-webkit-scrollbar-thumb { background: rgba(255,255,255,.25); border-radius: 6px; }
.gallery-item {
    flex: 0 0 clamp(270px, 34vw, 460px);
    scroll-snap-align: start;
}
.gallery-btn {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    padding: 0;
    border: 0;
    border-radius: var(--r-lg);
    overflow: hidden;
    background: var(--ink-3);
    cursor: zoom-in;
}
.gallery-btn img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform .7s var(--ease), filter .4s;
}
.gallery-btn:hover img { transform: scale(1.05); }
.gallery-cap {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    padding: 40px 18px 16px;
    background: linear-gradient(0deg, rgba(22,13,43,.9), rgba(22,13,43,0));
    color: #fff;
    font-size: 13.5px;
    font-weight: 600;
    text-align: left;
    line-height: 1.4;
}
.gallery-hint { color: var(--on-dark); font-size: 13px; margin: 6px auto 0; }

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.site .how-section { background: var(--surface); }
.steps {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 28px;
    position: relative;
}
.steps::before {   /* the trail that connects the steps */
    content: '';
    position: absolute;
    top: 27px;
    left: 12.5%; right: 12.5%;
    border-top: 2px dashed var(--line-2);
}
.step { position: relative; text-align: center; padding: 0 6px; }
.step-marker {
    position: relative;
    width: 56px; height: 56px;
    margin: 0 auto 18px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: var(--ink);
    box-shadow: 0 0 0 8px var(--surface);
}
.step-marker span {
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--gold);
}
.site .step-icon { font-size: 1.4rem; color: var(--violet); margin-bottom: 10px; }
.site .step-title { font-family: var(--font-display); font-size: 1.45rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; margin-bottom: 8px; }
.site .step-desc { color: var(--muted); font-size: 14.5px; line-height: 1.65; margin: 0; }

/* ============================================================
   PAYMENT
   ============================================================ */
.site .payment-section { background: var(--paper); }
.bank-card {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(400px 200px at 110% -20%, rgba(245,176,20,.35), transparent 60%),
        linear-gradient(135deg, var(--ink) 0%, var(--ink-3) 55%, var(--plum) 100%);
    color: #fff;
    border-radius: var(--r-lg);
    padding: 28px 28px 24px;
    box-shadow: var(--sh-3);
    height: calc(100% - 70px);
}
.bank-card-head {
    display: flex; align-items: center; gap: 12px;
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    margin-bottom: 20px;
}
.bank-card-head i { color: var(--gold); }
.bank-card-row {
    display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
    padding: 12px 0;
    border-top: 1px solid rgba(255,255,255,.14);
    font-size: 14.5px;
}
.bank-card-row span { color: var(--on-dark); }
.bank-card-row strong { text-align: right; }
.bank-card-num {
    font-family: var(--font-display);
    font-size: 1.9rem;
    letter-spacing: .08em;
    color: var(--gold);
    line-height: 1;
}
.qr-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-2);
    padding: 22px;
    text-align: center;
    height: 100%;
}
.qr-title {
    color: #C2185B;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 14px;
}
.qr-btn { padding: 8px; border: 2px solid #FCE7F3; border-radius: var(--r-md); background: #fff; cursor: zoom-in; }
.qr-btn img { display: block; width: 200px; height: 200px; object-fit: contain; }
.qr-name { margin-top: 12px; font-size: 11.5px; font-weight: 700; color: var(--text); letter-spacing: .04em; }
.qr-sub  { font-size: 11px; color: var(--muted); }

/* ============================================================
   CONTACT
   ============================================================ */
.site .contact-section { background: var(--surface); }
.site .contact-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    height: 100%;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    padding: 26px 24px;
    box-shadow: var(--sh-1);
    color: var(--text);
    text-align: left;
    transition: transform .3s var(--ease), box-shadow .3s, border-color .3s;
}
.site .contact-card:hover { transform: translateY(-4px); box-shadow: var(--sh-2); border-color: var(--violet-l); color: var(--text); }
.site .contact-icon {
    width: 48px; height: 48px;
    margin: 0 0 18px;
    border-radius: 14px;
    background: var(--ink);
    color: var(--gold);
    font-size: 1.05rem;
    display: inline-flex; align-items: center; justify-content: center;
}
.contact-title { font-weight: 700; font-size: 1.05rem; color: var(--ink); }
.contact-sub   { color: var(--muted); font-size: 14px; margin: 2px 0 14px; }
.site .contact-link {
    margin-top: auto;
    display: inline-flex; align-items: center; gap: 8px;
    color: var(--violet);
    font-weight: 600;
    font-size: 14.5px;
    word-break: break-word;
}
.site .contact-link i { font-size: 12px; transition: transform .25s var(--ease); }
.site .contact-card:hover .contact-link i { transform: translateX(4px); }

/* ============================================================
   CTA
   ============================================================ */
.site .cta-section { background: var(--surface); padding: 0 0 var(--section-y); }
.cta-panel {
    position: relative;
    overflow: hidden;
    display: flex; align-items: center; justify-content: space-between; gap: 24px;
    flex-wrap: wrap;
    padding: clamp(32px, 5vw, 56px);
    border-radius: 28px;
    background:
        radial-gradient(500px 260px at 100% 0%, rgba(245,176,20,.35), transparent 60%),
        linear-gradient(120deg, var(--ink) 0%, var(--ink-3) 50%, var(--plum) 100%);
    box-shadow: var(--sh-3);
}
.site .cta-title {
    font-family: var(--font-display);
    font-size: clamp(2.2rem, 4.5vw, 3.4rem);
    font-weight: 800;
    line-height: .95;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 8px;
}
.site .cta-sub { color: var(--on-dark); font-size: 1.05rem; margin: 0; }

/* ============================================================
   FOOTER
   ============================================================ */
.site .site-footer {
    background: var(--ink);
    color: var(--on-dark);
    padding: 72px 0 28px;
}
.footer-logo { width: 52px; height: 52px; }
.footer-brand {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #fff;
    line-height: 1.05;
}
.footer-brand-sub { color: var(--gold); font-weight: 600; font-size: 14px; }
.footer-tagline { color: var(--on-dark); font-size: 14.5px; max-width: 340px; }
.site .footer-heading {
    font-family: var(--font-body);
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 18px;
}
.site .footer-links li { margin-bottom: 10px; font-size: 14.5px; }
.site .footer-links a { color: var(--on-dark); font-size: 14.5px; }
.site .footer-links a:hover { color: #fff; padding-left: 0; }
.footer-info li { display: flex; gap: 12px; align-items: flex-start; }
.footer-info i { color: var(--gold); width: 16px; margin-top: 5px; flex-shrink: 0; }
.site .social-btn {
    width: 40px; height: 40px;
    background: rgba(255,255,255,.08);
    color: #fff;
}
.site .social-btn:hover { background: var(--gold); color: var(--gold-ink); }
.footer-bottom {
    display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid rgba(255,255,255,.1);
    font-size: 13px;
    color: rgba(255,255,255,.55);
}
.site .footer-admin { color: rgba(255,255,255,.55); }
.site .footer-admin:hover { color: #fff; }

/* ============================================================
   FLOATING CONTROLS, LIGHTBOX, TOAST
   ============================================================ */
.site .back-to-top {
    background: var(--ink);
    border: 1.5px solid rgba(245,176,20,.7);
    color: var(--gold);
}
.site .music-fab { box-shadow: 0 6px 20px rgba(0,0,0,.35); }

.lightbox {
    width: 100vw; height: 100vh;
    max-width: none; max-height: none;
    margin: 0;
    padding: 24px 72px;
    border: 0;
    background: rgba(10,6,20,.94);
    color: #fff;
}
.lightbox[open] { display: flex; align-items: center; justify-content: center; }
.lightbox::backdrop { background: rgba(10,6,20,.6); }
.lightbox-figure { margin: 0; text-align: center; max-width: 100%; }
.lightbox-figure img {
    max-width: 100%;
    max-height: calc(100vh - 110px);
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 30px 80px rgba(0,0,0,.5);
}
.lightbox-figure figcaption { margin-top: 14px; font-size: 14px; color: rgba(255,255,255,.8); }
.lightbox-close, .lightbox-nav {
    position: absolute;
    width: 48px; height: 48px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,.25);
    background: rgba(255,255,255,.08);
    color: #fff;
    font-size: 18px;
    cursor: pointer;
    transition: background .2s;
}
.lightbox-close:hover, .lightbox-nav:hover { background: rgba(255,255,255,.2); }
.lightbox-close { top: 18px; right: 18px; }
.lightbox-prev  { left: 14px;  top: 50%; transform: translateY(-50%); }
.lightbox-next  { right: 14px; top: 50%; transform: translateY(-50%); }
.lightbox-nav[hidden] { display: none; }

.site-toast {
    position: fixed;
    left: 50%; bottom: 28px;
    z-index: 2100;
    transform: translate(-50%, 20px);
    opacity: 0;
    pointer-events: none;
    background: var(--ink);
    color: #fff;
    border: 1px solid rgba(245,176,20,.45);
    border-radius: var(--r-pill);
    padding: 11px 20px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: var(--sh-3);
    transition: opacity .25s var(--ease), transform .25s var(--ease);
}
.site-toast i { color: var(--gold); }
.site-toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ============================================================
   INNER PAGES (register, payment, success, failed, receipt)
   ============================================================ */
.site .page-hero-sm {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(700px 300px at 85% -40%, rgba(245,176,20,.25), transparent 60%),
        radial-gradient(800px 360px at 0% 120%, rgba(124,58,237,.45), transparent 60%),
        var(--ink);
    padding: clamp(48px, 7vw, 80px) 0;
}
.site .page-hero-title {
    color: #fff;
    font-family: var(--font-display);
    font-size: clamp(2.4rem, 6vw, 3.8rem);
    font-weight: 800;
    text-transform: uppercase;
    line-height: .95;
}
.site .page-hero-title i { color: var(--gold); font-size: .7em; vertical-align: .1em; }
.site .page-hero-sub { color: var(--on-dark); font-size: 1.05rem; margin-top: 12px; }

/* Forms */
.site .form-card {
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-1);
}
.site .form-card:focus-within { border-color: var(--violet-l); box-shadow: 0 0 0 4px rgba(124,58,237,.08), var(--sh-2); }
.site .form-card-header {
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 20px 26px;
}
.site .form-card-header h5 { font-size: 1.05rem; }
.site .form-step-num {
    width: 40px; height: 40px;
    background: var(--ink);
    color: var(--gold);
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 800;
}
.site .form-card-body { padding: 26px; }
.site .form-label { color: var(--text); font-weight: 600; font-size: 14px; }
.site .form-text { color: var(--muted); }
.site .form-control, .site .form-select {
    min-height: 48px;
    border: 1.5px solid var(--line-2);
    border-radius: var(--r-sm);
    font-size: 15px;   /* ≥15px avoids iOS zoom-on-focus jank */
    color: var(--text);
}
.site .form-select-sm { min-height: 48px; font-size: 15px; padding-top: 10px; padding-bottom: 10px; }
.site textarea.form-control { min-height: 96px; }
.site .form-control:hover, .site .form-select:hover { border-color: #C4B5E8; }
.site .form-control:focus, .site .form-select:focus {
    border-color: var(--violet);
    box-shadow: 0 0 0 4px rgba(124,58,237,.15);
}
.site .form-control[readonly] { background: var(--paper); }
.site .form-control.is-invalid, .site .form-select.is-invalid { border-color: #dc3545; }
/* The narrow date-of-birth dropdowns have no room for the error icon */
.site .form-select-sm.is-invalid { --bs-form-select-bg-icon: none; padding-right: 2rem; }
.site .form-check-input:checked { background-color: var(--violet); border-color: var(--violet); }
.site .form-check-input:focus { box-shadow: 0 0 0 4px rgba(124,58,237,.18); border-color: var(--violet); }

.site .category-radio-card {
    border: 2px solid var(--line-2);
    border-radius: var(--r-md);
    padding: 18px 14px;
    background: #fff;
    transition: border-color .2s, background .2s, box-shadow .2s, transform .2s var(--ease);
}
.site .category-radio-card .fs-5 {
    font-family: var(--font-display);
    font-size: 2rem !important;
    font-weight: 800;
    line-height: 1;
    color: var(--plum) !important;
}
.site .category-radio-card:hover { border-color: var(--violet-l); background: #FCFAFF; transform: translateY(-2px); }
.site .category-radio-label input:checked + .category-radio-card,
.site .category-radio-card.selected {
    border-color: var(--violet);
    background: var(--violet-bg);
    box-shadow: 0 0 0 4px rgba(124,58,237,.12);
}
.site .category-radio-label input:focus-visible + .category-radio-card { outline: 3px solid var(--gold); outline-offset: 3px; }
.site .runner-cat-option {
    border-radius: var(--r-md) !important;
    border: 1.5px solid var(--line-2) !important;
    transition: border-color .2s, background .2s;
}
.site .runner-cat-option:hover { border-color: var(--violet-l) !important; }
.site .runner-cat-option.border-primary { border-color: var(--violet) !important; background: var(--violet-bg) !important; }

.site .declaration-box { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-md); }
.site .fee-summary-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-1);
    padding: 22px 26px;
}
.site .total-amount { font-family: var(--font-display); font-size: 2rem; color: var(--plum); }
.site .fee-final-box {
    background: linear-gradient(120deg, var(--ink), var(--ink-3) 60%, var(--plum));
    border-radius: var(--r-lg);
    padding: 22px 36px;
}
.site .fee-final-amount { font-family: var(--font-display); font-size: 3rem; color: var(--gold); line-height: 1; }
.site .btn-submit-register, .site .btn-pay-now {
    background: var(--gold);
    color: var(--gold-ink);
    border-radius: var(--r-pill);
    padding: 16px 44px;
    box-shadow: 0 10px 30px rgba(245,176,20,.3);
}
.site .btn-submit-register:hover, .site .btn-pay-now:hover { background: #FFC94A; color: var(--gold-ink); }

/* Live form validation */
.site .field-error { display: block; color: #b42318; font-size: 13px; font-weight: 500; margin-top: 6px; }
.site .group-invalid { border-radius: var(--r-md); box-shadow: 0 0 0 2px #f1a8a0; }

/* Mobile total bar on the registration form */
.reg-total-bar {
    position: fixed;
    left: 12px; right: 12px; bottom: 12px;
    z-index: 1040;
    display: none;
    align-items: center; justify-content: space-between; gap: 12px;
    background: rgba(22,13,43,.96);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    color: #fff;
    border-radius: var(--r-md);
    padding: 10px 10px 10px 18px;
    box-shadow: var(--sh-3);
    transform: translateY(140%);
    transition: transform .3s var(--ease);
}
.reg-total-bar.show { transform: none; }
.reg-total-bar small { display: block; color: var(--on-dark); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; }
.reg-total-bar strong { font-family: var(--font-display); font-size: 1.7rem; color: var(--gold); line-height: 1; }
.reg-total-bar .btn { background: var(--gold); color: var(--gold-ink); border-radius: var(--r-pill); padding: 10px 18px; font-size: 14px; }
@media (max-width: 767.98px) {
    .reg-total-bar { display: flex; }
    body.has-total-bar .back-to-top,
    body.has-total-bar .music-fab { bottom: 92px; }
}

/* Payment confirm / success / failed */
.site .summary-card, .site .success-details-card, .site .next-steps-card,
.site .failed-info-card, .site .failed-options-card {
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--sh-1);
}
.site .summary-header, .site .success-card-header { background: var(--paper); border-color: var(--line); }
.site .ref-display, .site .ref-highlight-box {
    background: linear-gradient(120deg, var(--ink), var(--ink-3) 60%, var(--plum));
}
.site .ref-value, .site .ref-highlight-value { font-family: var(--font-display); color: var(--gold); letter-spacing: .08em; }
.site .total-row { background: var(--paper); border-color: var(--line); }
.site .total-value { font-family: var(--font-display); color: var(--plum); }
.site .event-reminder-card { background: var(--violet-bg); border-color: #E2D6FF; border-radius: var(--r-lg); }
.site .success-title, .site .failed-title { font-family: var(--font-display); text-transform: uppercase; font-size: clamp(2.2rem, 5vw, 3.2rem); line-height: .95; }
.site .option-card { background: var(--paper); border-radius: var(--r-md); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 991.98px) {
    .hero { min-height: 0; padding: 48px 0 140px; }
    /* Text sits over the whole photo on narrow screens, so darken it evenly */
    .hero-bg {
        background:
            linear-gradient(180deg, rgba(22,13,43,.9) 0%, rgba(22,13,43,.78) 55%, var(--ink) 100%),
            url('../images/hero-bg.jpeg') center 35% / cover no-repeat;
    }
    .hero-photo-btn { bottom: 96px; right: 16px; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .race-bib { grid-template-columns: 1fr; }
    .stat-tile:nth-child(3) { border-left: 0; }
    .stat-tile:nth-child(n+3) { border-top: 1px solid rgba(255,255,255,.1); }
    .steps { grid-template-columns: repeat(2, 1fr); row-gap: 40px; }
    .steps::before { display: none; }
    .bank-card { height: auto; }

}
@media (max-width: 767.98px) {
    .section-head-split { flex-direction: column; align-items: flex-start; }
    .feature-grid { grid-template-columns: 1fr; }
    .shirt-photos { grid-template-columns: 1fr; }
    .cta-panel { flex-direction: column; align-items: flex-start; }
    .footer-bottom { flex-direction: column; align-items: flex-start; }
    .lightbox { padding: 64px 12px 24px; }
    .lightbox-nav { top: auto; bottom: 18px; transform: none; }
    .lightbox-prev { left: calc(50% - 60px); }
    .lightbox-next { right: calc(50% - 60px); }
    .lightbox-figure img { max-height: calc(100vh - 190px); }
}
@media (max-width: 575.98px) {
    .site .hero-title { font-size: 4.4rem; }
    .hero-actions .btn { flex: 1 1 100%; text-align: center; }
    .site .race-bib .countdown-box { padding: 18px 12px 16px; }
    .site .race-bib .count-num { font-size: 2.4rem; }
    .site .race-bib .count-label { font-size: 9.5px; letter-spacing: .1em; }
    .race-bib-info { padding: 16px 20px 16px 34px; }
    .race-bib-event { font-size: 1.35rem; }
    .stat-tile { padding: 20px 12px; gap: 12px; flex-direction: column; align-items: flex-start; }
    .steps { grid-template-columns: 1fr; }
    .step { display: grid; grid-template-columns: 56px 1fr; column-gap: 18px; text-align: left; }
    .step-marker { grid-row: span 3; margin: 0; }
    .site .step-icon { display: none; }
    .panel { padding: 24px 20px; }
    /* Measurements stack as rows on phones */
    .spec-list { grid-template-columns: 1fr; }
    .spec-list > div { display: flex; justify-content: space-between; align-items: baseline; padding: 10px 14px; }
    .spec-list > div + div { border-left: 0; border-top: 1px solid var(--line); }
    .spec-list dd { font-size: 1.35rem; margin: 0; }
    .bank-card-row { flex-direction: column; gap: 2px; }
    .bank-card-row strong { text-align: left; }
    .site .form-card-body { padding: 20px 16px; }
    .site .form-card-header { padding: 16px; }
    .site .fee-final-box { min-width: 0; width: 100%; }
}

/* ============================================================
   REDUCED MOTION — keep the page calm
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    .site *, .site *::before, .site *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
    html { scroll-behavior: auto; }
    .hero-bg { animation: none; }
}
