/* =============================================================================
   MSC Weser-Solling e.V. – Main Stylesheet
   ============================================================================= */

/* =============================================================================
   TOKENS
   ============================================================================= */
:root {
    --orange:          #D4872A;
    --orange-light:    #F09640;
    --orange-dark:     #A8601A;
    --orange-dim:      rgba(212, 135, 42, 0.12);
    --orange-glow:     rgba(212, 135, 42, 0.22);

    --dark-950:        #080808;
    --dark-900:        #0f0f0f;
    --dark-800:        #161616;
    --dark-700:        #1e1e1e;
    --dark-600:        #272727;

    --white:           #ffffff;
    --off-white:       #f8f8f8;
    --text-body:       #2a2a2a;
    --text-muted:      #6b6b6b;
    --border-light:    rgba(0,0,0,0.09);
    --border-dark:     rgba(255,255,255,0.07);

    --header-h:        72px;
    --header-nav-h:    52px;
    --radius:          8px;
    --radius-lg:       14px;

    --ease-out:        cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --ease-spring:     cubic-bezier(0.34, 1.56, 0.64, 1);

    --font:            -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
                       Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
}

/* =============================================================================
   RESET & BASE
   ============================================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }

body {
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.65;
    color: var(--text-body);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Dark inner pages need light base text */
body.msc-inner-page,
body.nachttrial-inner-page { color: rgba(255,255,255,0.75); }

img { max-width: 100%; height: auto; display: block; }
a   { color: inherit; }

/* =============================================================================
   LANDING PAGE
   ============================================================================= */
body.home-landing { margin: 0; padding: 0; overflow: hidden; background: #000; }

.landing-wrapper {
    position: relative;
    display: flex;
    width: 100%;
    height: 100vh;
}

/* ── Expand hovered half, compress the other ── */
.landing-wrapper:has(.landing-half--msc:hover) .landing-half--msc        { flex: 1.35; }
.landing-wrapper:has(.landing-half--msc:hover) .landing-half--nachttrial  { flex: 0.65; }
.landing-wrapper:has(.landing-half--nachttrial:hover) .landing-half--nachttrial { flex: 1.35; }
.landing-wrapper:has(.landing-half--nachttrial:hover) .landing-half--msc  { flex: 0.65; }

/* ── Half base ── */
.landing-half {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    transition: flex 0.55s var(--ease-out);
}

/* ── Scrim: brightens slightly on hover ── */
.landing-half::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.28);
    transition: background 0.4s ease;
    z-index: 0;
}
.landing-half:hover::before { background: rgba(0,0,0,0.12); }

/* ── MSC half: rich amber gradient ── */
.landing-half--msc {
    background:
        radial-gradient(ellipse 80% 60% at 50% 110%, rgba(255,180,60,0.25) 0%, transparent 70%),
        linear-gradient(160deg, #F09640 0%, #D47820 50%, #A85010 100%);
}

/* ── Nachttrial half: deep dark ── */
.landing-half--nachttrial {
    background:
        radial-gradient(ellipse 70% 50% at 50% 100%, rgba(212,135,42,0.12) 0%, transparent 70%),
        linear-gradient(160deg, #1c1c1c 0%, #090909 100%);
}

/* ── Vertical divider ── */
.landing-divider {
    position: absolute;
    left: 50%;
    top: 8%;
    bottom: 8%;
    width: 1px;
    background: linear-gradient(to bottom, transparent, rgba(255,255,255,0.35) 30%, rgba(255,255,255,0.35) 70%, transparent);
    transform: translateX(-50%);
    z-index: 10;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.landing-wrapper:has(.landing-half:hover) .landing-divider { opacity: 0.5; }

/* ── Inner content ── */
.landing-half-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 44px;
    max-width: 480px;
}

/* ── Logo: top of the card ── */
.landing-logo {
    width: 160px;
    height: 160px;
    object-fit: contain;
    margin-bottom: 28px;
    filter: drop-shadow(0 8px 24px rgba(0,0,0,0.4));
    transition: transform 0.4s var(--ease-spring), filter 0.4s ease;
}
.landing-half:hover .landing-logo {
    transform: scale(1.07) translateY(-4px);
    filter: drop-shadow(0 16px 40px rgba(0,0,0,0.55));
}

/* ── Heading ── */
.landing-half h1 {
    color: var(--white);
    font-size: clamp(1.5rem, 2.2vw, 2.6rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.035em;
    margin-bottom: 14px;
    text-shadow: 0 2px 20px rgba(0,0,0,0.35);
}

/* ── Subtitle ── */
.landing-subtitle {
    color: rgba(255,255,255,0.72);
    font-size: 0.9rem;
    font-weight: 400;
    line-height: 1.5;
    margin-bottom: 28px;
    max-width: 32ch;
}

/* ── CTA pill ── */
.landing-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 26px;
    border: 1.5px solid rgba(255,255,255,0.38);
    border-radius: 100px;
    color: rgba(255,255,255,0.9);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    background: rgba(255,255,255,0.06);
    transition: background 0.3s ease, border-color 0.3s ease,
                gap 0.3s var(--ease-spring), letter-spacing 0.3s ease;
}
.landing-half:hover .landing-cta {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.65);
    gap: 14px;
    letter-spacing: 0.12em;
}
.landing-cta svg {
    flex-shrink: 0;
    transition: transform 0.3s var(--ease-spring);
}
.landing-half:hover .landing-cta svg { transform: translateX(4px); }

/* =============================================================================
   INNER-PAGE LAYOUT
   ============================================================================= */
.page-main {
    background: var(--dark-800);
    min-height: calc(100vh - var(--header-h) - var(--header-nav-h));
    position: relative;
    z-index: 1;
}

/* ── Page hero (full-bleed, featured image) ── */
.page-hero {
    position: relative;
    width: 100%;
    height: clamp(380px, 48vw, 580px);
    overflow: hidden;
}
.page-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
/* Decorative watermark from data-section attribute */
.page-hero::before {
    content: attr(data-section);
    position: absolute;
    bottom: -0.08em;
    right: -0.03em;
    font-size: 22vw;
    font-weight: 900;
    letter-spacing: -0.05em;
    line-height: 1;
    color: rgba(255,255,255,0.035);
    pointer-events: none;
    user-select: none;
    z-index: 1;
}
.page-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
        rgba(0,0,0,0.88) 0%,
        rgba(0,0,0,0.3) 55%,
        transparent 100%);
    display: flex;
    align-items: flex-end;
    z-index: 2;
}
.page-hero-content {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 52px 64px;
}
.page-hero-title {
    font-size: clamp(2.2rem, 5.5vw, 4.2rem);
    font-weight: 900;
    letter-spacing: -0.04em;
    color: var(--white);
    line-height: 1.0;
    text-shadow: 0 4px 40px rgba(0,0,0,0.5);
    margin: 0;
}

/* ── Page title block (no featured image) ── */
.page-title-block {
    background: linear-gradient(180deg, var(--dark-900) 0%, var(--dark-800) 100%);
    border-bottom: 1px solid var(--border-dark);
    padding: 36px 0 30px;
}
.page-title-block-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 64px;
}
.page-display-title {
    font-size: clamp(2rem, 4.5vw, 3.8rem);
    font-weight: 900;
    letter-spacing: -0.04em;
    color: var(--white);
    line-height: 1.05;
}
.page-display-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--orange), transparent);
    border-radius: 2px;
    margin-top: 24px;
}

/* ── Page body ── */
.page-body {
    max-width: 1200px;
    margin: 0 auto;
    padding: 36px 64px 100px;
}

/* Editorial grid: text stays in center column; wide elements bleed out */
.entry-content {
    display: grid;
    grid-template-columns: 1fr min(68ch, 100%) 1fr;
    font-size: 1rem;
    line-height: 1.8;
    color: rgba(255,255,255,0.7);
}
.entry-content > * { grid-column: 2; }
.entry-content > .alignwide,
.entry-content > .wp-block-image.alignwide,
.entry-content > .wp-block-table,
.entry-content > figure { grid-column: 1 / -1; }

.entry-content p     { margin-bottom: 1.15em; }
.entry-content h2    {
    font-size: clamp(1.25rem, 2.2vw, 1.6rem);
    font-weight: 800;
    letter-spacing: -0.025em;
    color: var(--white);
    margin: 2em 0 0.65em;
    padding-left: 16px;
    border-left: 3px solid var(--orange);
    line-height: 1.2;
}
.entry-content h3    {
    font-size: 1.1rem;
    font-weight: 700;
    color: rgba(255,255,255,0.9);
    margin: 1.6em 0 0.55em;
}
.entry-content ul,
.entry-content ol    { margin: 0 0 1.1em 0; padding-left: 1.4em; }
.entry-content li    { margin-bottom: 0.4em; }
.entry-content ul    { list-style: none; padding-left: 1.2em; }
.entry-content ul li { position: relative; }
.entry-content ul li::before {
    content: '';
    position: absolute;
    left: -1.1em;
    top: 0.62em;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--orange);
    opacity: 0.8;
}
.entry-content ol li::marker { color: var(--orange); font-weight: 700; }
.entry-content a     { color: var(--orange-light); text-decoration: underline; text-underline-offset: 3px; }
.entry-content a:hover { color: var(--orange); }
.entry-content img   {
    border-radius: var(--radius-lg);
    box-shadow: 0 12px 48px rgba(0,0,0,0.5);
    margin: 1.5em 0;
    width: 100%;
    height: auto;
}
.entry-content blockquote {
    margin: 1.6em 0;
    padding: 20px 28px;
    background: rgba(212,135,42,0.07);
    border-left: 3px solid var(--orange);
    border-radius: 0 var(--radius) var(--radius) 0;
    font-size: 1.05rem;
    font-style: italic;
    color: rgba(255,255,255,0.6);
}
.entry-content code {
    font-family: 'SF Mono','Fira Code',monospace;
    font-size: 0.84em;
    background: rgba(255,255,255,0.07);
    color: var(--orange-light);
    padding: 2px 7px;
    border-radius: 4px;
}
.entry-content table {
    width: 100%; border-collapse: collapse; margin-bottom: 1.4em; font-size: 0.9rem;
}
.entry-content th,
.entry-content td    { padding: 10px 14px; border: 1px solid var(--border-dark); text-align: left; }
.entry-content th    { background: rgba(212,135,42,0.1); font-weight: 600; color: var(--white); }
.entry-content tr:nth-child(even) td { background: rgba(255,255,255,0.03); }

/* ── Post hero (single posts, tall with meta overlay) ── */
.post-hero {
    position: relative;
    width: 100%;
    height: clamp(420px, 52vw, 620px);
    overflow: hidden;
}
.post-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.post-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
        rgba(0,0,0,0.94) 0%,
        rgba(0,0,0,0.45) 50%,
        rgba(0,0,0,0.1) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    z-index: 2;
}
.post-hero-content {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 52px 64px;
}
.post-hero-meta {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.45);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.post-hero-sep { opacity: 0.4; }
.post-hero-title {
    color: var(--white);
    font-size: clamp(1.8rem, 4vw, 3.5rem);
    font-weight: 900;
    letter-spacing: -0.04em;
    line-height: 1.05;
    text-shadow: 0 2px 32px rgba(0,0,0,0.6);
    margin: 0;
}

/* ── Plain post header (no featured image) ── */
.post-header-plain {
    background: linear-gradient(180deg, var(--dark-900) 0%, var(--dark-800) 100%);
    border-bottom: 1px solid var(--border-dark);
    padding:36px 0 30px;
}
.post-header-plain-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 64px;
}
.post-header-plain .entry-title {
    font-size: clamp(2rem, 4.5vw, 3.8rem);
    font-weight: 900;
    letter-spacing: -0.04em;
    color: var(--white);
    line-height: 1.05;
}
.post-meta-plain {
    font-size: 0.76rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.35);
    margin-top: 16px;
}

/* ── Post body: article + sticky meta aside ── */
.page-body--post {
    display: grid;
    grid-template-columns: 1fr 240px;
    gap: 56px;
    align-items: start;
}
.post-meta-aside {
    position: sticky;
    top: calc(var(--header-h) + 24px);
}
.post-meta-aside-inner {
    background: var(--dark-700);
    border: 1px solid var(--border-dark);
    border-radius: var(--radius-lg);
    padding: 22px 20px;
}
.post-meta-label {
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.25);
    margin-bottom: 5px;
    margin-top: 18px;
}
.post-meta-label:first-child { margin-top: 0; }
.post-meta-value {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.65);
    line-height: 1.5;
}

/* ── Back link ── */
.entry-footer {
    margin-top: 56px;
    padding-top: 28px;
    border-top: 1px solid var(--border-dark);
}
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--orange);
    text-decoration: none;
    letter-spacing: 0.02em;
    transition: gap 0.25s var(--ease-spring), color 0.2s ease;
}
.back-link:hover { gap: 12px; color: var(--orange-dark); }
.back-link svg { flex-shrink: 0; transition: transform 0.25s var(--ease-spring); }
.back-link:hover svg { transform: translateX(-3px); }

/* =============================================================================
   SITE HEADERS — two-tier (bar + nav strip)
   ============================================================================= */

.msc-site-header,
.nachttrial-site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* ── Main bar ── */
.site-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 0 32px;
    height: var(--header-h);
}
.site-header-logo a  { display: block; line-height: 0; text-decoration: none; }
.site-header-logo img { height: 52px; width: auto; }
.site-header-adac img { height: 48px; width: auto; }

/* ── Language switcher ── */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 7px;
    flex-shrink: 0;
}
.lang-icon {
    color: rgba(255,255,255,0.75);
    flex-shrink: 0;
}
/* Polylang may output <ul><li> or bare <li> — normalise both */
.lang-switcher ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: contents; /* lets <li> children participate in .lang-switcher flex */
}
.lang-switcher li {
    list-style: none;
}
.lang-switcher li a {
    display: block;
    padding: 4px 9px;
    border-radius: var(--radius);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    color: rgba(255,255,255,0.85);
    border: 1px solid rgba(255,255,255,0.3);
    transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.lang-switcher li a:hover {
    color: var(--white);
    background: rgba(255,255,255,0.12);
    border-color: rgba(255,255,255,0.55);
}
/* Active language */
.lang-switcher li.current-lang a {
    color: var(--orange-light);
    border-color: rgba(212,135,42,0.7);
    background: rgba(212,135,42,0.18);
    pointer-events: none;
    cursor: default;
}

.site-header-identity {
    flex: 1;
    text-align: center;
}
.identity-name {
    display: block;
    font-size: clamp(0.95rem, 1.5vw, 1.35rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
}
.identity-sub {
    display: block;
    font-size: 0.74rem;
    font-weight: 500;
    margin-top: 3px;
    letter-spacing: 0.03em;
}

/* MSC bar */
.msc-site-header .site-header-bar {
    background: rgba(8,8,8,0.96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(212,135,42,0.3), 0 4px 24px rgba(0,0,0,0.5);
}
.msc-site-header .identity-name {
    background: linear-gradient(90deg, var(--orange-light) 0%, var(--orange) 60%, var(--orange-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.msc-site-header .identity-sub { color: rgba(212,135,42,0.55); }

/* Nachttrial bar */
.nachttrial-site-header .site-header-bar {
    background: #050505;
    box-shadow: 0 1px 0 rgba(255,255,255,0.06), 0 4px 24px rgba(0,0,0,0.65);
}
.nachttrial-site-header .identity-name { color: var(--white); }
.nachttrial-site-header .identity-sub {
    color: rgba(255,255,255,0.35);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-size: 0.65rem;
}

/* ── Nav strip ── */
.site-header-nav {
    height: var(--header-nav-h);
    overflow: hidden;
    transition: height 0.35s var(--ease-out), opacity 0.3s ease;
}
.site-header-nav.is-hidden {
    height: 0;
    opacity: 0;
    pointer-events: none;
}
.site-header-nav-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    height: var(--header-nav-h);
    gap: 4px;
}

.site-header-nav--msc {
    background: rgba(0,0,0,0.7);
    border-bottom: 1px solid rgba(212,135,42,0.12);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.site-header-nav--nachttrial {
    background: rgba(5,5,5,0.92);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    position: relative;
}
.site-header-nav--nachttrial::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212,135,42,0.4) 30%, rgba(212,135,42,0.4) 70%, transparent);
}

/* Nav list */
.header-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 2px;
    flex: 1;
}
.header-nav-list > li > a {
    display: block;
    padding: 7px 15px;
    border-radius: var(--radius);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    text-decoration: none;
    color: rgba(255,255,255,0.5);
    white-space: nowrap;
    transition: color 0.2s ease, background 0.2s ease;
}
.header-nav-list > li > a:hover {
    color: var(--white);
    background: rgba(255,255,255,0.07);
}
.header-nav-list > li.current-menu-item > a,
.header-nav-list > li.current_page_item > a {
    background: rgba(212,135,42,0.12);
    color: var(--orange);
    font-weight: 600;
}

/* Dropdown sub-menus */
.header-nav-list li { position: relative; }
.header-nav-list ul {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    background: var(--dark-800);
    border: 1px solid var(--border-dark);
    border-radius: var(--radius);
    min-width: 160px;
    padding: 6px 0;
    box-shadow: 0 8px 32px rgba(0,0,0,0.45);
    list-style: none;
    z-index: 50;
}
.header-nav-list li:hover > ul { display: block; }
.header-nav-list ul li a {
    display: block;
    padding: 7px 16px;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.55);
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.15s ease, background 0.15s ease;
}
.header-nav-list ul li a:hover {
    color: var(--white);
    background: rgba(255,255,255,0.05);
}

/* Crosslink at far right of nav strip */
.site-header-crosslink {
    margin-left: auto;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    opacity: 0.55;
    transition: opacity 0.2s ease, transform 0.25s var(--ease-spring);
    text-decoration: none;
}
.site-header-crosslink:hover { opacity: 1; transform: scale(1.05); }
.site-header-crosslink img { height: 26px; width: auto; display: block; }

/* ── Hamburger toggle (hidden on desktop, shown on mobile) ── */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    padding: 0;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--radius);
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.2s ease, border-color 0.2s ease;
}
.nav-toggle:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.2);
}
.nav-toggle-bar {
    display: block;
    width: 18px;
    height: 1.5px;
    background: rgba(255,255,255,0.75);
    border-radius: 1px;
    transition: transform 0.25s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* MSC page body */
body.msc-inner-page {
    background-color: var(--dark-800);
    background-image: url('../images/msc-bg.jpg');
    background-size: cover;
    background-position: center top;
    background-attachment: fixed;
}
body.msc-inner-page::before {
    content: '';
    position: fixed;
    inset: 0;
    background: linear-gradient(150deg,
        rgba(0,0,0,0.78) 0%,
        rgba(0,0,0,0.55) 50%,
        rgba(0,0,0,0.78) 100%);
    z-index: 0;
    pointer-events: none;
}
body.msc-inner-page .msc-site-header,
body.msc-inner-page .page-main { position: relative; z-index: 1; }

/* Nachttrial page body */
body.nachttrial-inner-page { background: #060606; }
body.nachttrial-inner-page .page-main { background: var(--dark-800); }

/* =============================================================================
   FOOTER
   ============================================================================= */
.site-footer {
    background: var(--dark-950);
    color: rgba(255,255,255,0.32);
    padding: 36px 32px 28px;
    font-size: 0.78rem;
    letter-spacing: 0.04em;
    position: relative;
    z-index: 1;
    border-top: 1px solid var(--border-dark);
}
.site-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212,135,42,0.3) 30%, rgba(212,135,42,0.3) 70%, transparent);
}
.site-footer-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.site-footer-info { display: flex; flex-direction: column; gap: 4px; }
.site-footer-copy { margin: 0; font-weight: 600; color: rgba(255,255,255,0.4); }
.site-footer-address { margin: 0; font-size: 0.72rem; color: rgba(255,255,255,0.22); }

/* Footer nav */
.footer-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 4px;
}
.footer-nav-list li a {
    display: block;
    padding: 4px 10px;
    border-radius: var(--radius);
    color: rgba(255,255,255,0.35);
    text-decoration: none;
    transition: color 0.2s ease, background 0.2s ease;
    white-space: nowrap;
}
.footer-nav-list li a:hover {
    color: var(--white);
    background: rgba(255,255,255,0.05);
}

/* =============================================================================
   MIGRATED CONTENT — Bootstrap-compatible classes from old CMS
   ============================================================================= */

/* ── Article snippets (press / activities) ── */
.entry-content .snippet {
    background: var(--dark-700);
    border: 1px solid var(--border-dark);
    border-radius: var(--radius-lg);
    padding: 32px 36px;
    margin-bottom: 28px;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.entry-content .snippet:hover {
    border-color: rgba(212,135,42,0.2);
    box-shadow: 0 4px 24px rgba(0,0,0,0.3);
}
.entry-content .snippet h2 {
    font-size: 1.15rem;
    margin: 0 0 0.4em;
    padding-left: 0;
    border-left: none;
}
.entry-content .snippet h2:first-child { margin-top: 0; }
.entry-content .snippet > p > i {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.35);
    font-style: normal;
    letter-spacing: 0.03em;
}
.entry-content .snippet hr {
    display: none;
}
.entry-content hr {
    border: none;
    height: 1px;
    background: var(--border-dark);
    margin: 2em 0;
}

/* ── Alert boxes ── */
.entry-content .alert {
    padding: 18px 24px;
    border-radius: var(--radius);
    margin: 1.5em 0;
    font-size: 0.92rem;
    line-height: 1.6;
    font-weight: 500;
}
.entry-content .alert-warning {
    background: rgba(212,135,42,0.12);
    border: 1px solid rgba(212,135,42,0.3);
    color: var(--orange-light);
}
.entry-content .alert-info {
    background: rgba(59,130,246,0.1);
    border: 1px solid rgba(59,130,246,0.25);
    color: rgba(147,197,253,0.9);
}

/* ── Panels (Bootstrap legacy) ── */
.entry-content .panel {
    background: var(--dark-700);
    border: 1px solid var(--border-dark);
    border-radius: var(--radius);
    padding: 4px;
    margin: 1em 0 1.4em;
    overflow-x: auto;
}
.entry-content .panel table { margin-bottom: 0; }

/* ── List groups ── */
.entry-content .list-group {
    list-style: none;
    padding: 0;
    margin: 0 0 1.4em;
    border: 1px solid var(--border-dark);
    border-radius: var(--radius);
    overflow: hidden;
}
.entry-content .list-group-item {
    padding: 12px 20px;
    border-bottom: 1px solid var(--border-dark);
    font-size: 0.92rem;
    transition: background 0.15s ease;
}
.entry-content .list-group-item:last-child { border-bottom: none; }
.entry-content .list-group-item:hover { background: rgba(255,255,255,0.03); }
.entry-content .list-group-item::before { display: none; } /* override ul li bullet */
.entry-content .list-group-item a {
    text-decoration: none;
    color: var(--orange-light);
    font-weight: 500;
}
.entry-content .list-group-item a:hover { color: var(--white); }

/* ── Floating images (trial rules etc.) ── */
.entry-content img.floating {
    float: right;
    margin: 0 0 1.5em 2em;
    max-width: 320px;
    width: auto;
    border-radius: var(--radius-lg);
    box-shadow: 0 8px 32px rgba(0,0,0,0.45);
}

/* ── Responsive tables ── */
.entry-content .table-dark,
.entry-content table.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

/* ── Image gallery grid (bilder pages) ── */
.entry-content .gallery,
.entry-content div > a > img,
.entry-content .d-flex {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
.entry-content .d-flex.flex-wrap img {
    border-radius: var(--radius);
    object-fit: cover;
    transition: transform 0.25s var(--ease-spring), box-shadow 0.25s ease;
}
.entry-content .d-flex.flex-wrap img:hover {
    transform: scale(1.03);
    box-shadow: 0 12px 40px rgba(0,0,0,0.6);
    z-index: 2;
    position: relative;
}

/* ── Competitor profiles (teilnehmer) ── */
.entry-content .list-group-item.d-flex {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding: 20px 24px;
    align-items: flex-start;
}
.entry-content .list-group-item.d-flex img {
    border-radius: var(--radius);
    width: 160px;
    height: auto;
    margin: 0;
    box-shadow: 0 4px 16px rgba(0,0,0,0.4);
}
.entry-content .list-group-item.d-flex h3 {
    font-size: 1.1rem;
    color: var(--white);
    margin: 0 0 0.3em;
}

/* ── Article element styling ── */
.entry-content article {
    margin: 1em 0;
    font-size: 0.95rem;
    line-height: 1.75;
}

/* ── Strong/emphasis for readability on dark bg ── */
.entry-content strong { color: rgba(255,255,255,0.92); }
.entry-content em { color: rgba(255,255,255,0.78); }

/* ── Inline images that shouldn't be full-width ── */
.entry-content p img:not(.floating) {
    display: inline-block;
    border-radius: var(--radius);
}
.entry-content p img[width] {
    width: auto;
    max-width: 100%;
}

/* =============================================================================
   INDEX FALLBACK
   ============================================================================= */
.fallback-wrapper { max-width: 800px; margin: 0 auto; padding: 52px 24px; }
.fallback-wrapper h1 { font-size: 1.9rem; font-weight: 800; letter-spacing: -0.03em; margin-bottom: 32px; color: var(--text-body); }
.fallback-post-list { list-style: none; padding: 0; }
.fallback-post-list li { padding: 15px 0; border-bottom: 1px solid var(--border-light); }
.fallback-post-list li a { color: var(--orange); text-decoration: none; font-weight: 600; font-size: 1rem; }
.fallback-post-list li a:hover { color: var(--orange-dark); }
.fallback-post-meta { font-size: 0.76rem; color: var(--text-muted); margin-top: 3px; }

/* =============================================================================
   RESPONSIVE
   ============================================================================= */
@media (max-width: 1100px) {
    .page-hero-content,
    .page-title-block-inner,
    .post-header-plain-inner,
    .page-body { padding-left: 40px; padding-right: 40px; }
    .page-hero-title { font-size: clamp(1.8rem, 4vw, 3rem); }
}

/* ── Hamburger breakpoint: nav strip → toggled panel ── */
@media (max-width: 1250px) {
    .nav-toggle { display: flex; }

    /* Replace fixed-height strip with a collapsible panel */
    .site-header-nav {
        height: auto !important;   /* override JS-driven fixed height */
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transition: max-height 0.35s var(--ease-out), opacity 0.25s ease;
    }
    /* Open state: toggled by JS */
    .site-header-nav.is-mobile-open {
        max-height: 480px;
        opacity: 1;
    }
    /* Scroll-hide only applies when the panel is closed */
    .site-header-nav.is-hidden:not(.is-mobile-open) {
        max-height: 0;
        opacity: 0;
    }
    .site-header-nav-inner {
        flex-wrap: wrap;
        height: auto;
        padding: 10px 20px 16px;
        gap: 4px;
    }
    .header-nav-list {
        flex-wrap: wrap;
        width: 100%;
    }
    .header-nav-list > li > a { padding: 8px 14px; font-size: 0.85rem; }
    .header-nav-list ul { display: none !important; }
    .site-header-crosslink { margin-left: 0; padding-top: 8px; }
}

@media (max-width: 900px) {
    /* Post body: collapse to single column */
    .page-body--post { grid-template-columns: 1fr; }
    .post-meta-aside { position: static; order: -1; }
    .post-meta-aside-inner {
        display: flex;
        flex-wrap: wrap;
        gap: 16px 28px;
        padding: 16px 20px;
    }
    .post-meta-label { margin-top: 0; }
}

@media (max-width: 768px) {
    /* Snippets */
    .entry-content .snippet { padding: 20px 22px; }
    .entry-content img.floating {
        float: none;
        margin: 1em 0;
        max-width: 100%;
    }
    .entry-content .list-group-item.d-flex { flex-direction: column; }
    .entry-content .list-group-item.d-flex img { width: 100%; max-width: 200px; }
    /* Landing stacks */
    body.home-landing { overflow: auto; }
    .landing-wrapper { flex-direction: column; height: auto; }
    .landing-wrapper:has(.landing-half--msc:hover) .landing-half--msc,
    .landing-wrapper:has(.landing-half--nachttrial:hover) .landing-half--nachttrial,
    .landing-wrapper:has(.landing-half--msc:hover) .landing-half--nachttrial,
    .landing-wrapper:has(.landing-half--nachttrial:hover) .landing-half--msc { flex: 1; }
    .landing-divider { display: none; }
    .landing-half { min-height: 55vh; }
    .landing-half h1 { font-size: clamp(1.3rem, 5vw, 2rem); }
    .landing-half--msc { border-bottom: 1px solid rgba(255,255,255,0.15); }

    /* Header bar */
    .site-header-bar { padding: 0 20px; height: 60px; gap: 12px; }
    .site-header-logo img { height: 40px; }
    .site-header-adac img { height: 36px; }
    .identity-name { font-size: 0.9rem; }
    .identity-sub { display: none; }

    /* Page content */
    .page-hero { height: 260px; }
    .page-hero::before { display: none; }
    .page-hero-content,
    .page-title-block-inner,
    .post-header-plain-inner,
    .page-body { padding-left: 24px; padding-right: 24px; }
    .page-title-block { padding: 48px 0 40px; }
    .page-body { padding-top: 48px; padding-bottom: 64px; }
    .post-hero { height: 300px; }
    .post-hero-content { padding: 32px 24px; }
}

@media (max-width: 480px) {
    .landing-half h1 { font-size: 1.2rem; }
    .landing-logo { width: 120px; height: 120px; margin-bottom: 20px; }
    .landing-cta { font-size: 0.72rem; padding: 9px 20px; }
    .site-header-bar { height: 56px; }
    .site-header-logo img { height: 34px; }
    .site-header-adac img { height: 30px; }
    .page-hero { height: 220px; }
    .page-hero-title { font-size: 1.6rem; }
    .page-body { padding-top: 36px; padding-bottom: 48px; }
}
