/* =========================================================
   Wreck to Reef — Sun Diving
   Moonlight palette · single-page interactive build
   ========================================================= */

/* ---------- Webfonts ---------- */
@font-face {
    font-family: "Dahlia";
    src: url("../fonts/Dahlia-Medium.otf") format("opentype");
    font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
    font-family: "Rework Display";
    src: url("../fonts/ReworkDisplay-Bold.woff") format("woff");
    font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
    font-family: "Good Sans";
    src: url("../fonts/GoodSans-ExtraLight.otf") format("opentype");
    font-weight: 200; font-style: normal; font-display: swap;
}

/* ---------- Moonlight palette ---------- */
:root {
    --wr-cream:        #DFCEBA;   /* primary background */
    --wr-offwhite:     #F8F6F9;   /* card / surface */
    --wr-slate:        #4F6074;   /* secondary accent */
    --wr-slate-soft:   #7A8898;
    --wr-navy:         #192D50;   /* primary ink + accent */
    --wr-midnight:     #030B16;   /* deepest tone */
    --wr-cream-warm:   #D1C1AC;
    --wr-cream-cool:   #BFB09B;

    --wr-body:         #1A2230;
    --wr-rule:         rgba(25, 45, 80, 0.18);
    --wr-rule-soft:    rgba(25, 45, 80, 0.08);

    --ff-display: "Dahlia", "Playfair Display", "Times New Roman", serif;
    --ff-label:   "Rework Display", "Helvetica Neue", Arial, sans-serif;
    --ff-body:    "Good Sans", "Helvetica Neue", Arial, sans-serif;

    --wr-max: 1180px;
    --wr-gutter: clamp(20px, 4vw, 48px);
    --wr-header-h: 72px;

    /* Interactive easing */
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: var(--wr-header-h);
}
body {
    margin: 0;
    font-family: var(--ff-body);
    font-weight: 200;
    color: var(--wr-body);
    background: var(--wr-cream);
    line-height: 1.6;
    font-size: 17px;
    letter-spacing: 0.01em;
    overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--wr-navy); text-decoration: none; transition: color .2s var(--ease-out); }
a:hover, a:focus { color: var(--wr-slate); }

/* ---------- Container ---------- */
.wr-container {
    width: 100%;
    max-width: var(--wr-max);
    margin-inline: auto;
    padding-inline: var(--wr-gutter);
}

/* ---------- Top rule / section chrome ---------- */
.wr-chrome {
    border-top: 0.8px solid var(--wr-navy);
    padding-top: 14px;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    font-family: var(--ff-label);
    font-weight: 700;
    font-size: 10px;
    letter-spacing: 0.36em;
    text-transform: uppercase;
    color: var(--wr-navy);
}
.wr-chrome .wr-chrome-right { color: var(--wr-slate); letter-spacing: 0.40em; }

/* =========================================================
   HEADER — sticky, legible, scroll-spy aware
   ========================================================= */
.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 200;
    min-height: var(--wr-header-h);
    display: flex; align-items: center;
    background: transparent;
    transition: background .28s var(--ease-out),
                box-shadow .28s var(--ease-out),
                backdrop-filter .28s var(--ease-out);
}
.site-header .wr-container { width: 100%; }

/* When the hero is in view, header sits on the dark wash — cream text */
.site-header {
    color: var(--wr-offwhite);
}
.site-header.is-scrolled {
    background: rgba(223, 206, 186, 0.92);
    backdrop-filter: saturate(180%) blur(10px);
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    box-shadow: 0 1px 0 var(--wr-rule);
    color: var(--wr-navy);
}

.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
}
.site-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    color: currentColor;
    text-decoration: none;
}
.site-brand img { height: 26px; width: auto; filter: brightness(0) invert(1); transition: filter .28s var(--ease-out); }
.site-header.is-scrolled .site-brand img { filter: none; }

/* Text-only wordmark (shown when no custom logo is set) */
.site-brand-wordmark {
    font-family: var(--ff-label);
    font-weight: 700;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    font-size: 13px;
    line-height: 1;
    color: currentColor;
}
@media (max-width: 560px) {
    .site-brand-wordmark { font-size: 11px; letter-spacing: 0.22em; }
}

.main-nav ul {
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
    list-style: none;
    padding: 0; margin: 0;
}
.main-nav a {
    font-family: var(--ff-label);
    font-weight: 700;
    font-size: 10px;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: currentColor;
    padding: 8px 0;
    border-bottom: 1px solid transparent;
    transition: color .2s var(--ease-out), border-color .2s var(--ease-out);
}
.main-nav a:hover {
    color: var(--wr-cream);
    border-bottom-color: var(--wr-cream);
}
.site-header.is-scrolled .main-nav a:hover {
    color: var(--wr-slate);
    border-bottom-color: var(--wr-slate);
}
.main-nav a.is-active {
    border-bottom-color: var(--wr-cream);
}
.site-header.is-scrolled .main-nav a.is-active {
    color: var(--wr-navy);
    border-bottom-color: var(--wr-navy);
}

.nav-toggle {
    display: none;
    background: none;
    border: 1px solid currentColor;
    font-family: var(--ff-label);
    font-size: 11px;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: currentColor;
    cursor: pointer;
    padding: 8px 14px;
}
@media (max-width: 900px) {
    .nav-toggle { display: inline-flex; align-items: center; gap: 10px; }
    .main-nav {
        display: none;
        width: 100%;
        padding: 20px 0 8px;
    }
    .main-nav.is-open { display: block; }
    .site-header.is-open {
        background: var(--wr-cream);
        color: var(--wr-navy);
    }
    .site-header-inner { flex-wrap: wrap; }
    .main-nav ul { flex-direction: column; gap: 14px; }
}

/* =========================================================
   Typography
   ========================================================= */
.wr-eyebrow {
    font-family: var(--ff-label);
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.40em;
    text-transform: uppercase;
    color: var(--wr-navy);
    margin: 0 0 10px;
}
.wr-eyebrow.is-slate { color: var(--wr-slate); }

.wr-display {
    font-family: var(--ff-display);
    font-weight: 500;
    color: var(--wr-navy);
    font-size: clamp(46px, 7vw, 96px);
    line-height: 0.95;
    letter-spacing: -0.01em;
    margin: 0 0 18px;
}
.wr-display .accent { color: var(--wr-slate); }
.wr-display .accent-cream { color: var(--wr-cream); }

.wr-title {
    font-family: var(--ff-display);
    font-weight: 500;
    font-size: clamp(34px, 4.5vw, 58px);
    line-height: 1;
    margin: 0 0 18px;
    color: var(--wr-navy);
}
.wr-lead {
    font-family: var(--ff-body);
    font-size: clamp(16px, 1.2vw, 18px);
    color: var(--wr-body);
    max-width: 58ch;
    margin: 0 0 22px;
    line-height: 1.6;
}
.wr-body p { margin: 0 0 1em; }
.wr-kicker-rule {
    width: 64px; height: 1px;
    background: var(--wr-navy);
    margin: 0 0 14px;
    display: block;
}

/* =========================================================
   Hero — slider + parallax
   ========================================================= */
.wr-hero {
    position: relative;
    min-height: 100vh;
    color: var(--wr-offwhite);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 160px 20px 180px;
    isolation: isolate;
    overflow: hidden;
    background: var(--wr-midnight);
}
.wr-hero-slider {
    position: absolute;
    inset: -12% 0 -12% 0;
    z-index: -2;
    will-change: transform;
    transform: translate3d(0, 0, 0);
}
.wr-hero-slide {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: 0;
    transform: scale(1.06);
    transition: opacity 1.2s var(--ease-out), transform 8s var(--ease-out);
}
.wr-hero-slide.is-active {
    opacity: 1;
    transform: scale(1);
}
.wr-hero::before {
    content: "";
    position: absolute; inset: 0;
    background: linear-gradient(180deg,
        rgba(25, 45, 80, 0.58) 0%,
        rgba(3, 11, 22, 0.68) 55%,
        rgba(3, 11, 22, 0.92) 100%);
    z-index: -1;
}

.wr-hero-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}
.wr-hero-eyebrow {
    display: inline-block;
    font-family: var(--ff-label);
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.38em;
    text-transform: uppercase;
    color: var(--wr-cream);
    padding: 10px 22px;
    border: 1px solid rgba(223, 206, 186, 0.55);
    border-radius: 999px;
    margin: 0 0 44px;
}
.wr-hero-title {
    font-family: var(--ff-display);
    font-size: clamp(68px, 12vw, 180px);
    line-height: 0.88;
    margin: 0;
    color: var(--wr-offwhite);
    font-weight: 500;
    letter-spacing: -0.01em;
}
.wr-hero-title .reef { color: var(--wr-cream); }
.wr-hero-tagline {
    font-family: var(--ff-label);
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.30em;
    text-transform: uppercase;
    color: var(--wr-cream);
    margin: 30px 0 0;
    max-width: 46ch;
}
.wr-hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 18px;
    justify-content: center;
    align-items: center;
    margin-top: 22px;
    font-family: var(--ff-label);
    font-size: 11px;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--wr-cream);
    opacity: 0.92;
}
.wr-hero-meta .dot {
    display: inline-block;
    width: 4px; height: 4px;
    border-radius: 50%;
    background: var(--wr-cream);
    opacity: 0.7;
}

/* Slider controls */
.wr-hero-controls {
    position: absolute;
    left: 50%;
    bottom: 78px;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    z-index: 2;
}
.wr-hero-caption {
    font-family: var(--ff-label);
    font-weight: 700;
    font-size: 10px;
    letter-spacing: 0.40em;
    text-transform: uppercase;
    color: var(--wr-cream);
    opacity: 0.8;
    transition: opacity .4s var(--ease-out);
    min-height: 12px;
    min-width: 200px;
}
.wr-hero-dots {
    display: flex;
    gap: 10px;
}
.wr-hero-dot {
    width: 34px; height: 2px;
    background: rgba(223, 206, 186, 0.35);
    border: 0; padding: 0;
    cursor: pointer;
    transition: background .3s var(--ease-out), width .3s var(--ease-out);
}
.wr-hero-dot:hover { background: rgba(223, 206, 186, 0.65); }
.wr-hero-dot.is-active {
    background: var(--wr-cream);
    width: 52px;
}

.wr-hero-scroll {
    position: absolute;
    bottom: 22px; left: 50%;
    transform: translateX(-50%);
    font-family: var(--ff-label);
    font-size: 10px;
    letter-spacing: 0.36em;
    text-transform: uppercase;
    color: var(--wr-cream);
    opacity: 0.65;
    animation: wr-bob 2.6s ease-in-out infinite;
    z-index: 2;
}
@keyframes wr-bob {
    0%, 100% { transform: translate(-50%, 0); }
    50%      { transform: translate(-50%, 8px); }
}
@media (max-width: 640px) {
    .wr-hero-controls { bottom: 64px; }
    .wr-hero-scroll { display: none; }
    .wr-hero-tagline { font-size: 10px; letter-spacing: 0.26em; }
}

/* =========================================================
   Sections
   ========================================================= */
.wr-section {
    padding: clamp(64px, 9vw, 130px) 0;
    position: relative;
    scroll-margin-top: var(--wr-header-h);
}
.wr-section + .wr-section { border-top: 1px solid var(--wr-rule); }
.wr-section.is-dark {
    color: var(--wr-offwhite);
    background-color: var(--wr-midnight);
    background-image:
        linear-gradient(180deg, rgba(25,45,80,0.82), rgba(3,11,22,0.92)),
        url("../images/wreck/wreck-interior.jpg");
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}
.wr-section.is-dark .wr-display,
.wr-section.is-dark .wr-title { color: var(--wr-offwhite); }
.wr-section.is-dark .wr-display .accent { color: var(--wr-cream); }
.wr-section.is-dark .wr-eyebrow { color: var(--wr-cream); }
.wr-section.is-dark .wr-kicker-rule { background: var(--wr-cream); }
.wr-section.is-dark .wr-lead { color: var(--wr-cream); }

/* Reveal animation */
.wr-reveal {
    opacity: 0;
    transform: translate3d(0, 28px, 0);
    transition: opacity .9s var(--ease-out), transform .9s var(--ease-out);
    will-change: opacity, transform;
}
.wr-reveal.is-visible {
    opacity: 1;
    transform: translate3d(0, 0, 0);
}
.wr-reveal.delay-1 { transition-delay: .08s; }
.wr-reveal.delay-2 { transition-delay: .16s; }
.wr-reveal.delay-3 { transition-delay: .24s; }
.wr-reveal.delay-4 { transition-delay: .32s; }
@media (prefers-reduced-motion: reduce) {
    .wr-reveal { opacity: 1; transform: none; transition: none; }
    .wr-hero-scroll { animation: none; }
    html { scroll-behavior: auto; }
}

/* =========================================================
   Layout primitives (split, fact grid, toc)
   ========================================================= */
.wr-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(28px, 5vw, 64px);
    align-items: center;
}
.wr-split .wr-split-copy { max-width: 42em; }
.wr-split figure { margin: 0; overflow: hidden; position: relative; }
.wr-split figure img { aspect-ratio: 4/5; object-fit: cover; width: 100%; transition: transform .9s var(--ease-out); }
.wr-split figure:hover img { transform: scale(1.03); }
.wr-split figure figcaption {
    position: absolute;
    top: 12px; left: 12px;
    background: var(--wr-cream);
    color: var(--wr-navy);
    font-family: var(--ff-label);
    font-size: 9px; letter-spacing: 0.38em; text-transform: uppercase;
    padding: 8px 14px; font-weight: 700;
}
@media (max-width: 780px) { .wr-split { grid-template-columns: 1fr; } }

.wr-fact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px; margin-top: 32px;
}
.wr-fact { border-top: 1px solid var(--wr-rule); padding-top: 18px; }
.wr-fact .wr-fact-label {
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.36em; text-transform: uppercase;
    color: var(--wr-slate); font-weight: 700; margin: 0 0 10px;
}
.wr-fact .wr-fact-value {
    font-family: var(--ff-display); font-size: 26px; line-height: 1.05;
    color: var(--wr-navy); margin: 0 0 8px;
}
.wr-fact .wr-fact-note { font-size: 14px; color: var(--wr-slate); margin: 0; }

.wr-toc { list-style: none; padding: 0; margin: 16px 0 0; border-top: 1px solid var(--wr-rule); }
.wr-toc li {
    display: flex; justify-content: space-between; align-items: baseline;
    gap: 24px; padding: 14px 0; border-bottom: 1px dotted var(--wr-rule);
}
.wr-toc .toc-title { font-family: var(--ff-display); font-size: 22px; color: var(--wr-navy); }
.wr-toc .toc-num {
    font-family: var(--ff-label); font-weight: 700; font-size: 12px;
    letter-spacing: 0.22em; color: var(--wr-slate);
}
.wr-toc-group-label {
    font-family: var(--ff-label); font-weight: 700; font-size: 10px;
    letter-spacing: 0.36em; color: var(--wr-navy);
    text-transform: uppercase; padding: 24px 0 6px;
}
.wr-toc-group-label.is-slate { color: var(--wr-slate); }

/* =========================================================
   Day itinerary — now with tabs
   ========================================================= */
.wr-day-tabs {
    display: flex;
    gap: 0;
    margin: 0 0 28px;
    border-bottom: 1px solid var(--wr-rule);
    flex-wrap: wrap;
}
.wr-day-tab {
    flex: 1 1 0;
    min-width: 140px;
    padding: 16px 18px;
    background: transparent;
    border: 0;
    border-bottom: 2px solid transparent;
    text-align: left;
    cursor: pointer;
    font-family: var(--ff-label);
    font-size: 10px;
    letter-spacing: 0.30em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--wr-slate);
    transition: color .25s var(--ease-out), border-color .25s var(--ease-out), background .25s var(--ease-out);
}
.wr-day-tab .tab-n {
    display: block;
    font-family: var(--ff-display);
    font-size: 28px;
    letter-spacing: -0.01em;
    color: var(--wr-slate);
    margin-bottom: 4px;
    transition: color .25s var(--ease-out);
}
.wr-day-tab:hover { color: var(--wr-navy); }
.wr-day-tab:hover .tab-n { color: var(--wr-navy); }
.wr-day-tab.is-active {
    color: var(--wr-navy);
    border-bottom-color: var(--wr-navy);
}
.wr-day-tab.is-active .tab-n { color: var(--wr-navy); }

.wr-day-panels { position: relative; }
.wr-day-panel {
    display: none;
    animation: wr-fade-in .45s var(--ease-out);
}
.wr-day-panel.is-active { display: block; }
@keyframes wr-fade-in {
    from { opacity: 0; transform: translate3d(0, 12px, 0); }
    to   { opacity: 1; transform: translate3d(0, 0, 0); }
}

.wr-day {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 40px;
    align-items: flex-start;
}
.wr-day-tile {
    background: var(--wr-navy);
    color: var(--wr-cream);
    padding: 28px 32px;
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.wr-day-tile .day-label {
    font-family: var(--ff-label);
    font-size: 11px; letter-spacing: 0.40em; font-weight: 700;
    text-transform: uppercase; margin: 0;
}
.wr-day-tile .day-number {
    font-family: var(--ff-display);
    font-size: 120px; line-height: 0.9; margin: 10px 0 0;
    color: var(--wr-cream);
}
.wr-day-tile .day-date {
    font-family: var(--ff-label);
    font-size: 11px; letter-spacing: 0.38em; text-transform: uppercase;
    font-weight: 700; margin: 0;
}
.wr-day-tile.tint-stewardship { background: var(--wr-slate); }

.wr-events { list-style: none; padding: 0; margin: 0; }
.wr-events li {
    display: grid; grid-template-columns: 90px 1fr; gap: 20px;
    padding: 18px 0; border-bottom: 1px solid var(--wr-rule);
}
.wr-events li:last-child { border-bottom: none; }
.wr-event-time {
    display: inline-block;
    background: var(--wr-navy);
    color: var(--wr-cream);
    font-family: var(--ff-label);
    font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase;
    font-weight: 700; padding: 7px 12px; text-align: center;
    align-self: flex-start;
}
.wr-event-title {
    font-family: var(--ff-display);
    font-size: 22px; line-height: 1.15; margin: 0 0 4px;
    color: var(--wr-navy);
}
.wr-event-tag {
    display: inline-block;
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.32em; text-transform: uppercase;
    color: var(--wr-slate); font-weight: 700; margin: 0 0 8px;
}
.wr-event-desc { margin: 0 0 6px; color: var(--wr-body); }
.wr-event-loc {
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase;
    color: var(--wr-slate); font-weight: 700;
}
.wr-day-photos {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 36px;
}
.wr-day-photos img { aspect-ratio: 4/3; object-fit: cover; width: 100%; }
@media (max-width: 780px) {
    .wr-day { grid-template-columns: 1fr; }
    .wr-day-tile { min-height: 220px; }
    .wr-day-tile .day-number { font-size: 90px; }
}

/* =========================================================
   Profile cards (Moonlight)
   ========================================================= */
.wr-profile-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-top: 28px;
}
/* 4 columns on desktop for photo-cards */
@media (min-width: 1100px) { .wr-profile-grid { grid-template-columns: repeat(4, 1fr); gap: 22px; } }
/* 3 columns on medium */
@media (min-width: 820px) and (max-width: 1099px) { .wr-profile-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; } }
@media (max-width: 540px) { .wr-profile-grid { grid-template-columns: 1fr; } }

.wr-profile {
    background: var(--wr-offwhite);
    border: 1px solid var(--wr-rule);
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out);
}
.wr-profile:hover {
    transform: translateY(-4px);
    box-shadow: 0 22px 50px -20px rgba(25, 45, 80, 0.22);
}

/* Photo variant */
.wr-profile .profile-photo {
    position: relative;
    overflow: hidden;
    background: var(--wr-midnight);
}
.wr-profile .profile-photo img {
    display: block;
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
    object-position: center top;
    transition: transform .9s var(--ease-out);
}
.wr-profile:hover .profile-photo img { transform: scale(1.04); }
.wr-profile .profile-discipline-tag {
    position: absolute;
    left: 12px; top: 12px;
    background: var(--wr-navy);
    color: var(--wr-cream);
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.26em; text-transform: uppercase;
    font-weight: 700;
    padding: 6px 10px;
    border-radius: 2px;
}

/* Chip variant (no photo) */
.wr-profile .profile-chip {
    background: var(--wr-navy);
    color: var(--wr-cream);
    padding: 10px 16px;
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.30em; text-transform: uppercase;
    font-weight: 700;
    display: flex; justify-content: space-between; align-items: center; gap: 8px;
}
.wr-profile .profile-chip .discipline {
    color: var(--wr-offwhite);
    letter-spacing: 0.36em; font-size: 9px;
}

/* Body (shared) */
.wr-profile .profile-body {
    display: flex;
    flex-direction: column;
    flex: 1;
}
.wr-profile .profile-name {
    font-family: var(--ff-display);
    font-size: 24px; line-height: 1.05;
    margin: 16px 16px 4px; color: var(--wr-navy);
}
.wr-profile .profile-role {
    margin: 0 16px 4px;
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.26em; text-transform: uppercase;
    color: var(--wr-slate); font-weight: 700;
}
.wr-profile .profile-origin { margin: 2px 16px 12px; font-size: 12px; color: var(--wr-slate); }
.wr-profile .profile-bio {
    margin: 0 16px 14px;
    font-size: 13.5px; line-height: 1.55;
    color: var(--wr-body);
    flex: 1;
}
.wr-profile .profile-footer {
    border-top: 1px solid var(--wr-rule);
    padding: 12px 16px;
    display: flex; justify-content: space-between; align-items: center;
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.24em;
    color: var(--wr-slate); text-transform: uppercase; font-weight: 700;
    gap: 8px;
}
.wr-profile .profile-handle { color: var(--wr-navy); }

/* Breathing room when cards widen on 2-up / 1-up layouts */
@media (max-width: 819px) {
    .wr-profile-grid { gap: 18px; margin-top: 22px; }
    .wr-profile .profile-photo img { aspect-ratio: 1/1; }      /* square on small tablet */
    .wr-profile .profile-name { font-size: 26px; margin: 18px 18px 4px; }
    .wr-profile .profile-role { margin: 0 18px 4px; }
    .wr-profile .profile-origin { margin: 2px 18px 14px; font-size: 13px; }
    .wr-profile .profile-bio { margin: 0 18px 14px; font-size: 14px; }
    .wr-profile .profile-footer { padding: 14px 18px; font-size: 10px; }
    .wr-profile .profile-discipline-tag { font-size: 10px; padding: 7px 11px; }
}

/* Single-column phone — photo shorter so card doesn't feel endless */
@media (max-width: 540px) {
    .wr-profile-grid { gap: 20px; }
    .wr-profile .profile-photo img { aspect-ratio: 4/3; object-position: center 20%; }
    .wr-profile .profile-name { font-size: 24px; margin: 16px 16px 4px; }
    .wr-profile .profile-role,
    .wr-profile .profile-footer { font-size: 10px; letter-spacing: 0.22em; }
    .wr-profile .profile-bio { font-size: 13.5px; line-height: 1.55; margin: 0 16px 14px; }
    .wr-profile .profile-origin { margin: 2px 16px 12px; font-size: 12.5px; }
    .wr-profile .profile-footer {
        flex-wrap: wrap; gap: 6px; padding: 12px 16px;
    }
    /* Hide the hover lift on touch to avoid sticky states */
    .wr-profile:hover { transform: none; box-shadow: none; }
    .wr-profile:hover .profile-photo img { transform: none; }
}

/* Very narrow phones */
@media (max-width: 380px) {
    .wr-profile .profile-name { font-size: 22px; }
    .wr-profile .profile-photo img { aspect-ratio: 3/2; }
}

/* =========================================================
   Dive team
   ========================================================= */
.wr-team-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 28px;
}
/* 3-up on medium tablets */
@media (max-width: 1100px) { .wr-team-grid { grid-template-columns: repeat(3, 1fr); gap: 18px; } }
/* 2-up on small tablets / large phones */
@media (max-width: 820px)  { .wr-team-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; } }
/* 1-up on narrow phones */
@media (max-width: 420px)  { .wr-team-grid { grid-template-columns: 1fr; gap: 18px; } }

.wr-team {
    background: var(--wr-offwhite);
    border: 1px solid var(--wr-rule);
    display: flex; flex-direction: column;
    overflow: hidden;
    border-radius: 4px;
    transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out);
}
.wr-team:hover { transform: translateY(-4px); box-shadow: 0 22px 50px -20px rgba(25, 45, 80, 0.22); }
.wr-team img {
    aspect-ratio: 4/5;
    object-fit: cover;
    object-position: center top;
    width: 100%;
    display: block;
    transition: transform 1s var(--ease-out);
}
.wr-team:hover img { transform: scale(1.04); }

/* Text sizes scale with card width — tighter for 4-col, bigger on 2-col */
.wr-team .team-role {
    margin: 14px 14px 0;
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.24em; text-transform: uppercase;
    color: var(--wr-slate); font-weight: 700;
}
.wr-team .team-name {
    margin: 4px 14px 0;
    font-family: var(--ff-display);
    font-size: 22px;
    line-height: 1.1;
    color: var(--wr-navy);
}
.wr-team .team-meta {
    margin: 6px 14px 14px;
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.24em; text-transform: uppercase;
    color: var(--wr-slate);
}
.wr-team-underline { border-top: 1px solid var(--wr-rule); padding: 0; margin: 0 14px; }

/* Breathing room per breakpoint */
@media (max-width: 1100px) {
    .wr-team .team-name { font-size: 24px; }
    .wr-team .team-role,
    .wr-team .team-meta { font-size: 10px; letter-spacing: 0.26em; }
    .wr-team .team-role { margin-top: 16px; }
    .wr-team .team-meta { margin-bottom: 16px; }
}
@media (max-width: 820px) {
    .wr-team img { aspect-ratio: 1/1; }
    .wr-team .team-name { font-size: 26px; }
    .wr-team .team-role  { margin: 18px 16px 0; }
    .wr-team .team-name  { margin: 4px 16px 0; }
    .wr-team .team-meta  { margin: 6px 16px 18px; }
    .wr-team-underline   { margin: 0 16px; }
}
@media (max-width: 420px) {
    .wr-team img { aspect-ratio: 4/3; }
    .wr-team .team-name { font-size: 28px; }
}

/* =========================================================
   Dive map
   ========================================================= */
.wr-map {
    background: var(--wr-offwhite);
    border: 1px solid var(--wr-rule);
    padding: 18px;
}
.wr-map .wr-map-label {
    font-family: var(--ff-label); font-weight: 700;
    font-size: 11px; letter-spacing: 0.36em; text-transform: uppercase;
    color: var(--wr-slate); margin: 0 0 12px;
}
.wr-map img { width: 100%; }

/* =========================================================
   Partner grid
   ========================================================= */
.wr-partner-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px; margin-top: 28px;
}
.wr-partner {
    background: var(--wr-offwhite);
    border: 1px solid var(--wr-rule);
    padding: 28px 22px;
    display: flex; flex-direction: column;
    justify-content: space-between;
    gap: 14px; min-height: 220px;
    transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out);
}
.wr-partner:hover { transform: translateY(-3px); box-shadow: 0 18px 38px -18px rgba(25, 45, 80, 0.22); }
.wr-partner .partner-logo {
    height: 72px;
    display: flex; align-items: center; justify-content: flex-start;
}
.wr-partner .partner-logo img { max-height: 72px; max-width: 100%; object-fit: contain; }
.wr-partner .partner-eyebrow {
    font-family: var(--ff-label); font-weight: 700;
    font-size: 9px; letter-spacing: 0.34em;
    color: var(--wr-slate); text-transform: uppercase;
}
.wr-partner .partner-name {
    font-family: var(--ff-display);
    font-size: 22px; margin: 0;
    color: var(--wr-navy);
}
.wr-partner .partner-bio { font-size: 13.5px; color: var(--wr-slate); margin: 0; }

/* =========================================================
   Badges
   ========================================================= */
.wr-badge-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 20px; margin-top: 28px;
}
.wr-badge {
    text-align: center;
    padding: 18px;
    background: var(--wr-offwhite);
    border: 1px solid var(--wr-rule);
    transition: transform .35s var(--ease-out);
}
.wr-badge:hover { transform: translateY(-3px); }
.wr-badge img { height: 90px; width: auto; margin: 0 auto 14px; }
.wr-badge .badge-label {
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.26em; text-transform: uppercase;
    font-weight: 700; color: var(--wr-navy);
}

/* =========================================================
   Musicians
   ========================================================= */
.wr-musician-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px; margin-top: 28px;
}
@media (max-width: 680px) { .wr-musician-grid { grid-template-columns: 1fr; } }
.wr-musician {
    position: relative;
    overflow: hidden;
    min-height: 320px;
    background: var(--wr-midnight);
    color: var(--wr-offwhite);
    transition: transform .4s var(--ease-out);
}
.wr-musician:hover { transform: translateY(-4px); }
.wr-musician img {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover; opacity: 0.6;
    transition: transform 1.2s var(--ease-out), opacity .5s var(--ease-out);
}
.wr-musician:hover img { transform: scale(1.05); opacity: 0.7; }
.wr-musician::after {
    content: "";
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(25,45,80,0.35), rgba(3,11,22,0.92));
}
.wr-musician-body {
    position: relative;
    z-index: 2;
    padding: 28px;
    display: flex; flex-direction: column; justify-content: flex-end;
    height: 100%; min-height: 320px;
}
.wr-musician .slot {
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.36em; text-transform: uppercase;
    color: var(--wr-cream); font-weight: 700; margin: 0 0 10px;
}
.wr-musician .name {
    font-family: var(--ff-display);
    font-size: 42px; line-height: 1; margin: 0 0 8px;
}
.wr-musician .role {
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.3em; text-transform: uppercase;
    font-weight: 700; color: var(--wr-cream); margin: 0;
}
.wr-musician .followers {
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase;
    color: var(--wr-cream); opacity: 0.75;
    margin-top: 14px;
    border-top: 1px solid rgba(255,255,255,.18);
    padding-top: 12px;
}

/* =========================================================
   Closing / CTA
   ========================================================= */
.wr-closing {
    position: relative;
    color: var(--wr-offwhite);
    text-align: center;
    padding: clamp(80px, 14vw, 170px) 22px;
    background: var(--wr-midnight);
    overflow: hidden;
}
.wr-closing::before {
    content: "";
    position: absolute; inset: 0;
    background:
        linear-gradient(180deg, rgba(25,45,80,0.78), rgba(3,11,22,0.94)),
        url("../images/wreck/wreck-portrait.jpg") center/cover no-repeat;
    background-attachment: fixed;
    z-index: 0;
}
.wr-closing > * { position: relative; z-index: 1; }
.wr-closing .kicker {
    font-family: var(--ff-label);
    font-size: 12px; letter-spacing: 0.42em; text-transform: uppercase;
    color: var(--wr-cream); margin: 0 0 22px; font-weight: 700;
}
.wr-closing .thank {
    font-family: var(--ff-display);
    font-size: clamp(48px, 7vw, 96px);
    line-height: 1.02; margin: 0 0 30px;
    color: var(--wr-cream);
}
.wr-closing p { max-width: 640px; margin: 0 auto; color: var(--wr-offwhite); }

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
    background: var(--wr-midnight);
    color: var(--wr-cream);
    padding: 50px 0 32px;
    font-family: var(--ff-label);
    font-size: 11px; letter-spacing: 0.30em; text-transform: uppercase;
}
.site-footer .footer-row {
    display: flex; justify-content: space-between; gap: 24px;
    flex-wrap: wrap; align-items: center;
    border-top: 1px solid rgba(255,255,255,.15);
    padding-top: 22px;
}
.site-footer a { color: var(--wr-cream); }
.site-footer .footer-wordmark {
    font-family: var(--ff-display);
    font-size: 28px; letter-spacing: -0.01em;
    text-transform: none; color: var(--wr-cream);
    margin-bottom: 18px;
}

/* =========================================================
   Progress bar (scroll progress)
   ========================================================= */
.wr-progress {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: transparent;
    z-index: 210;
    pointer-events: none;
}
.wr-progress-fill {
    height: 100%;
    width: 0%;
    background: var(--wr-navy);
    transition: width .05s linear;
}

/* =========================================================
   Utilities
   ========================================================= */
.wr-rule { height: 1px; background: var(--wr-rule); margin: 36px 0; border: 0; }
.wr-space-xl { height: 64px; }
.wr-space-lg { height: 40px; }
.wr-center { text-align: center; }
.wr-hide { display: none !important; }

/* =========================================================
   Top Dive Sites — 2x2 map grid (replaces single .wr-map)
   ========================================================= */
.wr-dive-sites {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
    margin-top: 40px;
}
.wr-site-card {
    background: var(--wr-offwhite);
    border: 1px solid var(--wr-rule);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 0 rgba(25, 45, 80, 0.04);
    transition: transform .35s ease, box-shadow .35s ease;
    display: flex;
    flex-direction: column;
}
.wr-site-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 38px rgba(3, 11, 22, 0.12);
}
.wr-site-map {
    position: relative;
    background: var(--wr-cream);
    overflow: hidden;
}
.wr-site-map img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center;
    transition: transform .9s ease;
}
.wr-site-card:hover .wr-site-map img {
    transform: scale(1.03);
}
.wr-site-level {
    position: absolute;
    top: 14px;
    left: 14px;
    background: var(--wr-navy);
    color: var(--wr-cream);
    font-family: var(--ff-label);
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    padding: 6px 10px;
    border-radius: 2px;
}
.wr-site-body {
    padding: 22px 24px 26px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.wr-site-name {
    font-family: var(--ff-display);
    font-size: 28px;
    line-height: 1.1;
    letter-spacing: -0.01em;
    color: var(--wr-midnight);
    margin: 0;
}
.wr-site-depth {
    font-family: var(--ff-label);
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--wr-slate);
}
.wr-site-desc {
    font-family: var(--ff-body);
    font-size: 15px;
    line-height: 1.55;
    color: var(--wr-midnight);
    margin: 8px 0 0;
}
@media (max-width: 720px) {
    .wr-dive-sites {
        grid-template-columns: 1fr;
        gap: 22px;
    }
    .wr-site-name { font-size: 24px; }
}


/* =========================================================
   Courses (SSI) — grouped grid of compact cards
   ========================================================= */
.wr-course-group { margin-top: 48px; }
.wr-course-group + .wr-course-group { margin-top: 64px; }
.wr-course-group-header {
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 16px; flex-wrap: wrap;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--wr-rule);
}
.wr-course-group-eyebrow {
    font-family: var(--ff-label);
    font-size: 10px; letter-spacing: 0.3em; text-transform: uppercase;
    font-weight: 700;
    color: var(--wr-slate);
}
.wr-course-group-title {
    font-family: var(--ff-display);
    font-size: 40px; line-height: 1;
    margin: 0;
    color: var(--wr-navy);
}
.wr-course-group-title .accent { color: var(--wr-cream); }

.wr-course-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}
@media (max-width: 1100px) { .wr-course-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .wr-course-grid { grid-template-columns: 1fr; } }

.wr-course-card {
    position: relative;
    background: var(--wr-offwhite);
    border: 1px solid var(--wr-rule);
    border-radius: 4px;
    padding: 20px 20px 22px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out), border-color .35s var(--ease-out);
    overflow: hidden;
}
.wr-course-card::before {
    content: "";
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    background: var(--wr-cream);
    transform: scaleY(0.2);
    transform-origin: top center;
    transition: transform .35s var(--ease-out), background .35s var(--ease-out);
}
.wr-course-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 38px -18px rgba(25, 45, 80, 0.25);
    border-color: var(--wr-navy);
}
.wr-course-card:hover::before {
    transform: scaleY(1);
    background: var(--wr-navy);
}
.wr-course-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}
.wr-course-level {
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.26em; text-transform: uppercase;
    font-weight: 700;
    color: var(--wr-cream);
    background: var(--wr-navy);
    padding: 5px 9px;
    border-radius: 2px;
}
.wr-course-duration {
    font-family: var(--ff-label);
    font-size: 9.5px; letter-spacing: 0.24em; text-transform: uppercase;
    font-weight: 700;
    color: var(--wr-slate);
}
.wr-course-name {
    font-family: var(--ff-display);
    font-size: 22px; line-height: 1.1;
    margin: 4px 0 2px;
    color: var(--wr-navy);
}
.wr-course-desc {
    font-family: var(--ff-body);
    font-size: 13.5px; line-height: 1.55;
    color: var(--wr-body);
    margin: 0;
    flex: 1;
}
.wr-course-arrow {
    display: inline-block;
    margin-top: 10px;
    font-family: var(--ff-label);
    font-size: 12px;
    color: var(--wr-slate);
    letter-spacing: 0.1em;
    transition: transform .35s var(--ease-out), color .35s var(--ease-out);
}
.wr-course-card:hover .wr-course-arrow {
    color: var(--wr-navy);
    transform: translateX(6px);
}
.wr-course-foot {
    margin-top: 40px;
    font-family: var(--ff-label);
    font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--wr-slate);
    text-align: center;
}

@media (max-width: 820px) {
    .wr-course-group-title { font-size: 32px; }
    .wr-course-card { padding: 18px 18px 20px; }
    .wr-course-name { font-size: 20px; }
    .wr-course-desc { font-size: 13px; }
    .wr-course-card:hover { transform: none; box-shadow: none; border-color: var(--wr-rule); }
    .wr-course-card:hover::before { transform: scaleY(0.2); background: var(--wr-cream); }
    .wr-course-card:hover .wr-course-arrow { transform: none; color: var(--wr-slate); }
}

/* =========================================================
   Course CTA + primary button
   ========================================================= */
.wr-course-cta {
    margin-top: 56px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 22px;
    text-align: center;
}
.wr-course-cta .wr-course-foot {
    max-width: 58ch;
    margin: 0;
}

.wr-btn {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 16px 28px;
    font-family: var(--ff-label);
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 2px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background .28s var(--ease-out),
                color .28s var(--ease-out),
                border-color .28s var(--ease-out),
                transform .28s var(--ease-out),
                box-shadow .28s var(--ease-out);
    user-select: none;
    white-space: nowrap;
}
.wr-btn-primary {
    background: var(--wr-navy);
    color: var(--wr-cream);
    border-color: var(--wr-navy);
}
.wr-btn-primary:hover,
.wr-btn-primary:focus-visible {
    background: var(--wr-midnight);
    color: var(--wr-offwhite);
    border-color: var(--wr-midnight);
    transform: translateY(-2px);
    box-shadow: 0 18px 38px -18px rgba(3, 11, 22, 0.35);
}
.wr-btn-ghost {
    background: transparent;
    color: var(--wr-navy);
    border-color: var(--wr-navy);
}
.wr-btn-ghost:hover,
.wr-btn-ghost:focus-visible {
    background: var(--wr-navy);
    color: var(--wr-cream);
}
.wr-btn .wr-btn-arrow {
    transition: transform .28s var(--ease-out);
    font-size: 14px;
}
.wr-btn:hover .wr-btn-arrow,
.wr-btn:focus-visible .wr-btn-arrow {
    transform: translateX(4px);
}

@media (max-width: 540px) {
    .wr-btn { padding: 14px 22px; font-size: 11px; letter-spacing: 0.22em; gap: 10px; }
    .wr-course-cta { margin-top: 40px; gap: 18px; }
}

/* The old grouped course header (kept for compatibility but no longer rendered) */
.wr-course-group { margin-top: 0; }
