/* =============================================================
   KINETIC ATHLETE — styles.css
   Shared styles loaded by every page on the site.

   Per-creator colour overrides (in each creator's <style> tag):
     :root {
       --accent:        #00b894;           (teal  — Everyday Fitness)
       --accent-glow:   rgba(0,184,148,0.18);
       --accent-dim:    rgba(0,184,148,0.08);
       --accent-subtle: rgba(0,184,148,0.06);
     }
     .hero-info-panel::after { content: 'E'; }

   Category accent colours:
     Everyday Fitness  → #00b894  teal
     Powerlifting      → #e8222a  red  (site brand default)
     Bodybuilding      → #ff6b00  orange
     Yoga & Mobility   → #7b61ff  purple
     Calisthenics      → #0984e3  blue
============================================================= */

/* ============================================================
   RESET
============================================================ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

/* ============================================================
   CSS VARIABLES
   Default values are site brand red (powerlifting / index).
   Creator pages override accent variables in their <style> block.
============================================================ */
:root {
    /* Surfaces */
    --bg:            #080808;
    --surface:       #111111;
    --surface-2:     #181818;
    --surface-3:     #222222;

    /* Accent — overridden per creator */
    --accent:        #e8222a;
    --accent-glow:   rgba(232, 34, 42, 0.18);
    --accent-dim:    rgba(232, 34, 42, 0.08);
    --accent-subtle: rgba(232, 34, 42, 0.07);

    /* Text */
    --text:          #f2f2f2;
    --text-muted:    #888888;
    --text-dim:      #555555;

    /* Borders */
    --border:        #242424;
    --border-light:  #303030;

    /* Typography */
    --font-display:  'Bebas Neue', sans-serif;
    --font-body:     'Barlow', sans-serif;
    --font-cond:     'Barlow Condensed', sans-serif;

    /* Misc */
    --radius-sm:     4px;
    --radius-md:     6px;
    --ease:          cubic-bezier(0.4, 0, 0.2, 1);
    --header-h:      64px;
}

/* ============================================================
   BASE
============================================================ */
html { scroll-behavior: smooth; }

body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 32px;
}

/* ============================================================
   HEADER
============================================================ */
.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    height: var(--header-h);
    background: rgba(8, 8, 8, 0.88);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    transition: border-color 0.3s var(--ease);
}

.site-header.scrolled { border-bottom-color: var(--border-light); }

.header-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 32px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-family: var(--font-display);
    font-size: 28px;
    letter-spacing: 0.05em;
    color: var(--text);
    text-decoration: none;
}

/* Logo accent is always site brand red, regardless of page accent */
.logo-accent { color: #e8222a; }

.site-nav {
    display: flex;
    align-items: center;
    gap: 40px;
}

.site-nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-family: var(--font-cond);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    transition: color 0.2s;
}

.site-nav a:hover { color: var(--text); }

/* ============================================================
   FOOTER
============================================================ */
.site-footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 44px 0;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 24px;
}

.footer-logo {
    font-family: var(--font-display);
    font-size: 22px;
    letter-spacing: 0.05em;
}

.footer-links {
    display: flex;
    gap: 28px;
    flex-wrap: wrap;
}

.footer-links a {
    font-family: var(--font-cond);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover { color: var(--text); }

.footer-copy { font-size: 12.5px; color: var(--text-dim); }

/* ============================================================
   ANIMATIONS
============================================================ */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(22px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes cardIn {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   CREATOR PAGES — hero (split-panel layout)
============================================================ */
.creator-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
    padding-top: var(--header-h);
}

/* ——— Left: image panel ——— */
.hero-img-panel {
    position: relative;
    overflow: hidden;
    background: var(--surface-2);
}

.hero-img-panel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    display: block;
    filter: grayscale(15%) brightness(0.72);
}

/* Fade image into the info panel on the right */
.hero-img-panel::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to right, transparent 55%, var(--bg) 100%),
        linear-gradient(to top, rgba(0,0,0,0.55) 0%, transparent 45%);
    pointer-events: none;
}

/* Accent vertical bar on left edge */
.hero-img-panel::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom,
        transparent 0%,
        var(--accent) 20%,
        var(--accent) 80%,
        transparent 100%);
    z-index: 2;
}

.hero-category-badge {
    position: absolute;
    bottom: 32px;
    left: 32px;
    z-index: 3;
    font-family: var(--font-cond);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #fff;
    background: var(--accent);
    padding: 6px 16px;
    border-radius: var(--radius-sm);
}

/* ——— Right: info panel ——— */
.hero-info-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 80px 72px 80px 60px;
    background: var(--bg);
    position: relative;
    overflow: hidden;
}

/* Ambient accent glow — uses --accent-subtle, set per creator */
.hero-info-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 550px 450px at 85% 55%,
        var(--accent-subtle) 0%, transparent 70%);
    pointer-events: none;
}

/* Large watermark letter — content overridden per creator */
.hero-info-panel::after {
    content: '';
    position: absolute;
    right: -20px;
    bottom: -40px;
    font-family: var(--font-display);
    font-size: 360px;
    line-height: 1;
    color: rgba(255,255,255,0.018);
    pointer-events: none;
    user-select: none;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-cond);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    text-decoration: none;
    margin-bottom: 44px;
    transition: color 0.2s;
    position: relative;
    z-index: 1;
}

.back-link:hover { color: var(--accent); }

.back-link svg {
    width: 14px; height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Scoped to .hero-info-panel to avoid conflict with index hero eyebrow */
.hero-info-panel .hero-eyebrow {
    font-family: var(--font-cond);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 14px;
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-info-panel .hero-eyebrow::before {
    content: '';
    display: block;
    width: 28px;
    height: 2px;
    background: var(--accent);
    flex-shrink: 0;
}

.hero-name {
    font-family: var(--font-display);
    font-size: clamp(88px, 11vw, 152px);
    line-height: 0.87;
    letter-spacing: 0.01em;
    color: var(--text);
    margin-bottom: 28px;
    position: relative;
    z-index: 1;
}

.hero-tagline {
    font-size: 17px;
    font-weight: 400;
    color: var(--text-muted);
    line-height: 1.75;
    max-width: 400px;
    margin-bottom: 48px;
    position: relative;
    z-index: 1;
}

.hero-meta {
    display: flex;
    gap: 44px;
    margin-bottom: 52px;
    position: relative;
    z-index: 1;
}

.meta-item { display: flex; flex-direction: column; gap: 3px; }

.meta-val {
    font-family: var(--font-display);
    font-size: 40px;
    line-height: 1;
    color: var(--text);
}

.meta-lbl {
    font-family: var(--font-cond);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-dim);
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-cond);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-decoration: none;
    background: var(--accent);
    color: #fff;
    padding: 15px 30px;
    border-radius: var(--radius-sm);
    transition: box-shadow 0.25s var(--ease), transform 0.25s var(--ease);
    position: relative;
    z-index: 1;
    width: fit-content;
}

.hero-cta:hover {
    box-shadow: 0 0 40px var(--accent-glow);
    transform: translateY(-2px);
}

/* Hero entrance animations */
.hero-info-panel .back-link    { animation: fadeUp 0.5s var(--ease) 0.05s both; }
.hero-info-panel .hero-eyebrow { animation: fadeUp 0.5s var(--ease) 0.15s both; }
.hero-info-panel .hero-name    { animation: fadeUp 0.5s var(--ease) 0.25s both; }
.hero-info-panel .hero-tagline { animation: fadeUp 0.5s var(--ease) 0.35s both; }
.hero-info-panel .hero-meta    { animation: fadeUp 0.5s var(--ease) 0.45s both; }
.hero-info-panel .hero-cta     { animation: fadeUp 0.5s var(--ease) 0.55s both; }

/* ============================================================
   CREATOR PAGES — about section
============================================================ */
.creator-about {
    padding: 108px 0;
    border-top: 1px solid var(--border);
}

.about-inner {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 88px;
    align-items: start;
}

.about-img-wrap {
    position: relative;
    flex-shrink: 0;
}

.about-img-wrap img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: center top;
    border-radius: var(--radius-md);
    filter: grayscale(10%) brightness(0.82);
    display: block;
}

/* Accent corner brackets */
.about-img-wrap::before {
    content: '';
    position: absolute;
    bottom: -14px; left: -14px;
    width: 60px; height: 60px;
    border-left: 2px solid var(--accent);
    border-bottom: 2px solid var(--accent);
}

.about-img-wrap::after {
    content: '';
    position: absolute;
    top: -14px; right: -14px;
    width: 60px; height: 60px;
    border-right: 2px solid var(--accent);
    border-top: 2px solid var(--accent);
}

.about-content { padding-top: 6px; }

/* Creator-page eyebrow (accent line + span).
   Index page overrides this with its own HR-based variant. */
.section-eyebrow {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
}

.section-eyebrow::before {
    content: '';
    display: block;
    width: 28px;
    height: 2px;
    background: var(--accent);
    flex-shrink: 0;
}

.section-eyebrow span {
    font-family: var(--font-cond);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--accent);
}

.about-title {
    font-family: var(--font-display);
    font-size: clamp(40px, 4.5vw, 60px);
    letter-spacing: 0.02em;
    line-height: 0.93;
    margin-bottom: 36px;
}

.about-text p {
    font-size: 15.5px;
    line-height: 1.88;
    color: var(--text-muted);
    margin-bottom: 22px;
}

.about-text p:last-child { margin-bottom: 0; }
.about-text strong { color: var(--text); font-weight: 600; }

/* ============================================================
   CREATOR PAGES — programme section
============================================================ */
.programme {
    padding: 108px 0;
    border-top: 1px solid var(--border);
}

.programme-header { margin-bottom: 52px; }

.section-title {
    font-family: var(--font-display);
    font-size: clamp(40px, 5vw, 64px);
    letter-spacing: 0.02em;
    line-height: 1;
    margin-bottom: 14px;
}

.section-subtitle {
    font-size: 15px;
    color: var(--text-muted);
    max-width: 580px;
    line-height: 1.75;
}

.level-tabs {
    display: flex;
    border-bottom: 1px solid var(--border);
    margin-bottom: 44px;
}

.level-tab {
    font-family: var(--font-cond);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 14px 32px;
    border: none;
    background: transparent;
    color: var(--text-dim);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: color 0.2s, border-color 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
}

.level-tab:hover { color: var(--text-muted); }

.level-tab.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
}

.tab-dot {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: var(--border-light);
    transition: background 0.2s;
    flex-shrink: 0;
}

.level-tab.active .tab-dot { background: var(--accent); }

.playlist-panel        { display: none; }
.playlist-panel.active { display: block; }

.level-intro {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    padding: 24px 32px;
    margin-bottom: 28px;
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.level-num {
    font-family: var(--font-display);
    font-size: 44px;
    line-height: 1;
    color: var(--accent);
    flex-shrink: 0;
    opacity: 0.6;
}

.level-intro-text {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.72;
    padding-top: 4px;
}

.level-intro-text strong { color: var(--text); font-weight: 600; }

.playlists-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.playlist-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 28px 24px 22px;
    position: relative;
    overflow: hidden;
    transition: border-color 0.25s var(--ease),
                transform 0.25s var(--ease),
                box-shadow 0.25s var(--ease);
    cursor: pointer;
}

.playlist-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(0,0,0,0.45), 0 0 40px var(--accent-glow);
}

.playlist-card-num {
    position: absolute;
    top: -18px; right: 14px;
    font-family: var(--font-display);
    font-size: 110px;
    line-height: 1;
    color: rgba(255,255,255,0.028);
    user-select: none;
    pointer-events: none;
}

.playlist-icon-wrap {
    width: 38px; height: 38px;
    background: var(--accent-dim);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
}

.playlist-icon-wrap svg {
    width: 17px; height: 17px;
    fill: var(--accent);
}

.playlist-title {
    font-family: var(--font-display);
    font-size: 23px;
    letter-spacing: 0.03em;
    line-height: 1.05;
    color: var(--text);
    margin-bottom: 10px;
}

.playlist-desc {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 22px;
}

.playlist-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--border);
    padding-top: 14px;
}

.playlist-meta { display: flex; gap: 14px; }

.playlist-meta span {
    font-family: var(--font-cond);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-dim);
}

.playlist-cta {
    font-family: var(--font-cond);
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--accent);
    transition: letter-spacing 0.2s;
}

.playlist-cta:hover { letter-spacing: 0.16em; }

/* ============================================================
   CREATOR PAGES — nutrition section
============================================================ */
.nutrition {
    padding: 108px 0;
    border-top: 1px solid var(--border);
}

.nutrition-header { margin-bottom: 56px; }

.nutrition-intro {
    margin-top: 16px;
    font-size: 15.5px;
    color: var(--text-muted);
    line-height: 1.82;
    max-width: 700px;
}

.nutrition-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.nutrition-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 36px;
    transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.nutrition-card:hover {
    border-color: var(--border-light);
    box-shadow: 0 8px 40px rgba(0,0,0,0.3);
}

.nutrition-icon-wrap {
    width: 46px; height: 46px;
    background: var(--accent-dim);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 22px;
}

.nutrition-icon-wrap svg {
    width: 22px; height: 22px;
    stroke: var(--accent);
    fill: none;
    stroke-width: 1.75;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.nutrition-title {
    font-family: var(--font-display);
    font-size: 26px;
    letter-spacing: 0.03em;
    line-height: 1;
    color: var(--text);
    margin-bottom: 14px;
}

.nutrition-text {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.8;
}

.nutrition-text strong { color: var(--text); font-weight: 600; }

/* ============================================================
   CREATOR PAGES — responsive
============================================================ */
@media (max-width: 1080px) {
    .creator-hero    { grid-template-columns: 1fr; min-height: auto; }
    .hero-img-panel  { height: 55vh; min-height: 360px; }
    .hero-info-panel { padding: 60px 40px; }
    .hero-info-panel::after { font-size: 220px; }
    .about-inner     { grid-template-columns: 1fr; }
    .about-img-wrap  { max-width: 360px; }
    .playlists-grid  { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .container        { padding: 0 20px; }
    .header-inner     { padding: 0 20px; }
    .site-nav         { display: none; }
    .hero-info-panel  { padding: 48px 20px; }
    .hero-meta        { gap: 28px; flex-wrap: wrap; }
    .playlists-grid   { grid-template-columns: 1fr; }
    .nutrition-grid   { grid-template-columns: 1fr; }
    .level-tabs       { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .level-tab        { white-space: nowrap; padding: 12px 22px; }
    .creator-about,
    .programme,
    .nutrition        { padding: 72px 0; }
}

/* ============================================================
   MOBILE HAMBURGER MENU
   Hamburger button visible only below 768px.
   Toggling .nav-open on <body> reveals the mobile nav panel.
============================================================ */

/* Button — hidden on desktop */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 17px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
    z-index: 110;
}

.hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-muted);
    border-radius: 2px;
    transition: transform 0.3s var(--ease),
                opacity 0.3s var(--ease),
                background 0.2s;
}

.hamburger:hover span { background: var(--text); }

/* X state when nav is open */
body.nav-open .hamburger span:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
    background: var(--text);
}
body.nav-open .hamburger span:nth-child(2) {
    opacity: 0;
}
body.nav-open .hamburger span:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
    background: var(--text);
}

/* Mobile nav panel — slides down from header */
.mobile-nav {
    display: none;
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    z-index: 99;
    background: rgba(8, 8, 8, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-light);
    padding: 8px 0 16px;
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}

body.nav-open .mobile-nav {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.mobile-nav a {
    display: block;
    font-family: var(--font-display);
    font-size: 36px;
    letter-spacing: 0.04em;
    line-height: 1;
    color: var(--text-muted);
    text-decoration: none;
    padding: 14px 32px;
    border-bottom: 1px solid var(--border);
    transition: color 0.2s, padding-left 0.2s;
}

.mobile-nav a:last-child { border-bottom: none; }

.mobile-nav a:hover,
.mobile-nav a.active {
    color: var(--text);
    padding-left: 40px;
}

/* Show hamburger + panel only on mobile */
@media (max-width: 768px) {
    .hamburger   { display: flex; }
    .mobile-nav  { display: block; }
    /* site-nav already hidden at 768px via per-page styles */
}
