/* ============================================
   TekkenBTB — Public Website Stylesheet
   Adapted from launcher design system (vw → rem/clamp)
   ============================================ */

/* --- Design Tokens --- */
:root {
    --accent-purple: #9C27B0;
    --accent-purple-light: #AB47BC;
    --accent-purple-dark: #7B1FA2;
    --accent-orange: #ff9800;
    --accent-red: #d32f2f;

    --bg-glass: rgba(0, 0, 0, 0.25);
    --bg-glass-border: rgba(255, 255, 255, 0.1);
    --button-outline: #fff;

    --text-primary: #f0f0f5;
    --text-secondary: #bbbbd0;
    --text-muted: #8a8aa0;

    --status-online: #4caf50;
    --status-maintenance: #f44336;

    /* REAL SMOKE VIDEO CONTROLS — edit these values to tune the live smoke
       background. There is no longer a separate fake smoke layer. */
    --smoke-video-opacity: 0.2147;
    --smoke-video-brightness: 1.08;
    --smoke-video-contrast: 1.2;
    --smoke-video-blend-mode: screen;

    --text-shadow-outside: 0 2px 8px rgba(0, 0, 0, 0.75),
                           0 0 16px rgba(0, 0, 0, 0.45);
    --text-shadow-content: 0 3px 10px rgba(0, 0, 0, 0.95),
                           0 0 18px rgba(0, 0, 0, 0.7),
                           0 0 4px rgba(0, 0, 0, 0.9);
    --text-shadow-footer: 0 2px 6px rgba(0, 0, 0, 0.85),
                          0 0 12px rgba(0, 0, 0, 0.5);

    /* Desktop layout tuning knobs. The artwork is bounded in-flow so controls
       remain visible across real browser heights. */
    --ui-scale: 1;
    --site-max-width: 105rem;
    --main-gap: clamp(2rem, 4vw, 4.5rem);
    --main-content-nudge-y: 2.3125rem;
    --left-stack-offset-x: 1.5rem;
    --left-stack-offset-y: clamp(0.25rem, 2vh, 1rem);
    --left-content-x: var(--left-stack-offset-x);
    --left-content-y: -1.125rem;
    --left-side-scale: 1.14;
    --right-content-x: -0.625rem;
    --right-content-y: 2.69rem;
    --video-content-x: 0rem;
    --video-content-y: 1.69rem;
    --footer-content-x: 0rem;
    --footer-content-y: 1rem;
    --panel-buttons-content-x: 0rem;
    --panel-buttons-content-y: 0.32rem;
    --left-media-width: 30rem;
    --right-panel-width: 40.625rem;

    /* Manual game-logo tuning. Adjust these values to move/resize each logo
       independently without touching the rest of the layout. */
    --logo-ttt2-width: min(31%, 9rem);
    --logo-ttt2-x: 1.875rem;
    --logo-ttt2-y: 3.75rem;
    --logo-ttt2-scale: 2.1;
    --logo-t6-width: min(31%, 9rem);
    --logo-t6-x: -0.6875rem;
    --logo-t6-y: 2.5rem;
    --logo-t6-scale: 2.1;
    --logo-t5dr-width: min(31%, 9rem);
    --logo-t5dr-x: -2.5rem;
    --logo-t5dr-y: 4.1875rem;
    --logo-t5dr-scale: 2.1;
    --logo-rev-width: 30rem;
    --logo-rev-x: 0rem;
    --logo-rev-y: 0.875rem;
    --logo-rev-scale: 1.13;
    --logo-rev-margin-top: -0.4rem;
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; }

body {
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: #05050a;
    color: var(--text-primary);
    min-height: 100vh;
    min-height: 100svh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--accent-purple-light);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover { color: #CE93D8; text-decoration: underline; }

/* --- Fullscreen Background ---
   Fixed layers cover the full viewport. Body background-color (#05050a)
   matches the image edges so pinch-zoom-out on mobile shows matching
   colour instead of white/black flash.
   Mobile: height locked to 100lvh (large viewport = toolbar-hidden size)
   so toolbar show/hide never triggers background-size:cover recalc. */
.bg-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100lvh;
    background-image: url('/static/images/public/Tekken_Rev2.0_BlurredBG.jpg');
    background-image: image-set(
        url('/static/images/public/Tekken_Rev2.0_BlurredBG.webp') type('image/webp'),
        url('/static/images/public/Tekken_Rev2.0_BlurredBG.jpg') type('image/jpeg')
    );
    background-size: cover;
    background-position: center;
    z-index: 0;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

/* --- Real smoke video layer --- */
.smoke-video {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100lvh;
    object-fit: cover;
    pointer-events: none;
    z-index: 1;
    opacity: var(--smoke-video-opacity);
    mix-blend-mode: var(--smoke-video-blend-mode);
    filter: brightness(var(--smoke-video-brightness)) contrast(var(--smoke-video-contrast));
    background: transparent;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

.bg-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100lvh;
    background: linear-gradient(
        135deg,
        rgba(5, 5, 10, 0.27) 0%,
        rgba(0, 0, 0, 0.34) 100%
    );
    z-index: 2;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

/* --- Hidden mode (landing_page_hidden) --- */
.hidden-mode {
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
}

.hidden-mode span {
    color: #374151;
    font-size: 0.75rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    text-shadow: var(--text-shadow-outside);
}

/* ============================================
   Header
   ============================================ */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 4.5rem;
    padding: 0.75rem 2rem;
    pointer-events: none;
}

.mobile-site-logo {
    display: block;
    width: clamp(8rem, 9vw, 10rem);
    height: auto;
    filter: drop-shadow(0 2px 12px rgba(0, 0, 0, 0.75));
}

.site-logo-link {
    display: block;
    line-height: 0;
    color: inherit;
    text-decoration: none;
    cursor: pointer;
    outline: none;
    pointer-events: auto;
}

.site-logo-link:hover,
.site-logo-link:focus-visible {
    text-decoration: none;
}

/* --- Status Badge --- */
.status-badge {
    position: absolute;
    right: 2rem;
    top: 2rem;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: var(--bg-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 0.55rem 1.35rem;
    border-radius: 0.5rem;
    border: 1px solid var(--bg-glass-border);
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    text-shadow: var(--text-shadow-outside);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: auto;
}

.status-badge.online {
    border-color: rgba(76, 175, 80, 0.25);
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.25);
}

.status-badge.maintenance {
    border-color: rgba(244, 67, 54, 0.3);
    box-shadow: 0 0 15px rgba(244, 67, 54, 0.3);
    color: #fecaca;
}

.status-dot {
    width: 0.625rem;
    height: 0.625rem;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-badge.online .status-dot {
    background: var(--status-online);
    box-shadow: 0 0 8px var(--status-online);
    animation: pulse-online 2s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

.status-badge.maintenance .status-dot {
    background: var(--status-maintenance);
    box-shadow: 0 0 8px var(--status-maintenance);
    animation: pulse-maintenance 1.5s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

@keyframes pulse-online {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(0.85); box-shadow: 0 0 14px var(--status-online); }
}

@keyframes pulse-maintenance {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); box-shadow: 0 0 18px var(--status-maintenance); }
}

/* ============================================
   Main Layout — Two Columns
   ============================================ */
.site-main {
    position: relative;
    top: var(--main-content-nudge-y);
    z-index: 3;
    display: flex;
    gap: var(--main-gap);
    max-width: var(--site-max-width);
    margin: 0 auto;
    padding: clamp(6.25rem, 10vh, 8rem) clamp(1.5rem, 3vw, 3rem) 1rem;
    height: calc(100vh - 5rem - var(--main-content-nudge-y));
    height: calc(100svh - 5rem - var(--main-content-nudge-y));
    min-height: 0;
}

/* --- Left Column --- */
.left-column {
    flex: 0 0 49%;
    max-width: 49%;
    display: flex;
    align-items: center;
    padding-top: var(--left-stack-offset-y);
    transform: translate(var(--left-content-x), var(--left-content-y));
}

.left-column-scale {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: calc(1.25rem * var(--left-side-scale));
    width: 100%;
}

.mobile-logo-stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: min(100%, calc(30rem * var(--left-side-scale)));
    margin: 0 auto 0.25rem;
    pointer-events: none;
}

.static-logo-row {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(0.35rem, 1vw, 0.75rem);
    width: min(94%, calc(30rem * var(--left-side-scale)));
    margin: 0 auto -0.25rem;
}

.static-title-logo {
    position: relative;
    height: auto;
    filter: grayscale(100%) saturate(0) contrast(1.08);
    opacity: 0.47;
    object-fit: contain;
}

.logo-ttt2 {
    width: var(--logo-ttt2-width);
    z-index: 2;
    transform: translate(var(--logo-ttt2-x), var(--logo-ttt2-y)) scale(var(--logo-ttt2-scale));
}

.logo-t6 {
    width: var(--logo-t6-width);
    z-index: 1;
    transform: translate(var(--logo-t6-x), var(--logo-t6-y)) scale(var(--logo-t6-scale));
}

.logo-t5dr {
    width: var(--logo-t5dr-width);
    z-index: 2;
    transform: translate(var(--logo-t5dr-x), var(--logo-t5dr-y)) scale(var(--logo-t5dr-scale));
}

.main-logo-wrap {
    position: relative;
    z-index: 3;
    width: 100%;
    max-width: calc(var(--logo-rev-width) * var(--left-side-scale));
    margin-top: var(--logo-rev-margin-top);
    transform: translate(var(--logo-rev-x), var(--logo-rev-y)) scale(var(--logo-rev-scale));
}

.main-logo-wrap::before,
.main-logo-wrap::after {
    content: none;
}

.mobile-main-logo {
    display: block;
    width: 100%;
    height: auto;
    animation: smoke-glow 4s ease-in-out infinite;
    will-change: filter;
}

/* --- Full-Page Logo Layer (matches launcher behavior) --- */
.logo-layer {
    display: none;
}

.site-logo-canvas,
.main-game-logo {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.site-logo-canvas {
    filter: drop-shadow(0 2px 12px rgba(0, 0, 0, 0.75));
    transform: scale(var(--header-logo-scale));
    transform-origin: center top;
}

.main-game-logo {
    animation: smoke-glow 4s ease-in-out infinite;
}

/* Tighter purple glow than launcher (user requested) */
@keyframes smoke-glow {
    0%   { filter: drop-shadow(0 0 6px rgba(156, 39, 176, 0.6))
                   drop-shadow(2px 1px 12px rgba(156, 39, 176, 0.25)); }
    25%  { filter: drop-shadow(-1px -1px 8px rgba(171, 71, 188, 0.7))
                   drop-shadow(0 0 14px rgba(123, 31, 162, 0.2)); }
    50%  { filter: drop-shadow(1px 2px 7px rgba(186, 104, 200, 0.6))
                   drop-shadow(-2px 0 12px rgba(156, 39, 176, 0.25)); }
    75%  { filter: drop-shadow(1px -1px 9px rgba(142, 36, 170, 0.65))
                   drop-shadow(1px 1px 14px rgba(171, 71, 188, 0.2)); }
    100% { filter: drop-shadow(0 0 6px rgba(156, 39, 176, 0.6))
                   drop-shadow(2px 1px 12px rgba(156, 39, 176, 0.25)); }
}

.static-logos {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: grayscale(100%) saturate(0) contrast(1.08);
    opacity: 1;
}

/* --- Download Buttons --- */
.download-buttons {
    display: flex;
    flex-direction: row;
    gap: 0.6rem;
    width: min(100%, calc(var(--left-media-width) * var(--left-side-scale)));
    justify-content: center;
    align-self: center;
    margin-inline: auto;
}

.download-buttons .btn {
    flex: 1 1 0;
    min-width: 0;
}

/* --- Glass Button (from launcher .btn) --- */
.btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: calc(clamp(0.7rem, 1.1vw, 1rem) * var(--ui-scale, 1)) calc(clamp(1rem, 1.5vw, 1.5rem) * var(--ui-scale, 1));
    border: 1px solid var(--button-outline);
    border-radius: 0.5rem;
    background: var(--bg-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
    width: 100%;
    text-decoration: none;
    color: inherit;
    font-family: inherit;
}

.btn:hover, .btn:focus-visible { text-decoration: none; color: inherit; }

.btn:hover:not(:disabled) {
    background: rgba(156, 39, 176, 0.25);
    border-color: var(--button-outline);
    box-shadow: 0 4px 24px rgba(156, 39, 176, 0.2);
    transform: translateY(-1px);
}

.btn:active:not(:disabled) {
    transform: translateY(1px);
    box-shadow: 0 1px 6px rgba(156, 39, 176, 0.2);
}

.btn:disabled,
.btn-disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.btn-text {
    font-size: calc(clamp(0.7rem, 0.82vw, 0.86rem) * var(--ui-scale, 1));
    font-weight: 700;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--text-primary);
    white-space: nowrap;
}

.btn-subtitle {
    font-size: calc(clamp(0.68rem, 0.9vw, 0.84rem) * var(--ui-scale, 1));
    font-weight: 500;
    letter-spacing: 1px;
    color: var(--text-secondary);
    margin-top: 0.15rem;
    text-align: center;
}

/* ============================================
   YouTube — Click-to-Load
   ============================================ */
.video-wrapper {
    position: relative;
    width: min(100%, calc(var(--left-media-width) * var(--left-side-scale)));
    max-width: calc(var(--left-media-width) * var(--left-side-scale));
    aspect-ratio: 16 / 9;
    border-radius: 0.4rem;
    overflow: hidden;
    border: 1px solid var(--bg-glass-border);
    background: #000;
    cursor: pointer;
    transform: translate(var(--video-content-x), var(--video-content-y));
}

.video-wrapper.playing { cursor: default; }

.yt-poster {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.3s ease;
}

.video-wrapper.playing .yt-poster,
.video-wrapper.playing .yt-play-btn {
    opacity: 0;
    pointer-events: none;
}

.yt-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: none;
    border: none;
    cursor: pointer;
    opacity: 0.85;
    transition: opacity 0.2s, transform 0.2s;
    padding: 0;
}

.yt-play-btn svg {
    width: clamp(3rem, 5vw, 4.25rem);
    height: auto;
}

.yt-play-btn:hover {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
}

.video-wrapper iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ============================================
   Right Column — Content Panels
   ============================================ */
.right-column {
    flex: 0 1 var(--right-panel-width);
    max-width: var(--right-panel-width);
    min-width: 0;
    position: relative;
    transform: translate(var(--right-content-x), var(--right-content-y));
    height: 100%;
    max-height: 100%;
    overflow: hidden;
}

.content-panel {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(0.5rem);
    transition: opacity 0.42s ease, transform 0.42s ease, visibility 0s linear 0.42s;
    display: flex;
    flex-direction: column;
    height: 100%;
    max-height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 0.35rem;
    scrollbar-width: none;
    -ms-overflow-style: none;
    pointer-events: none;
    will-change: opacity, transform;
}

.content-panel::-webkit-scrollbar { display: none; }

.content-panel.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    position: relative;
    pointer-events: auto;
    transition: opacity 0.42s ease, transform 0.42s ease, visibility 0s;
}

.panel-title {
    font-size: calc(clamp(1.6rem, 2vw, 1.9rem) * var(--ui-scale, 1));
    font-weight: 700;
	text-align: center;
    color: #fff;
    margin-bottom: 0.15rem;
    text-shadow: var(--text-shadow-content);
}

.panel-version {
    font-size: calc(clamp(1.24rem, 1.44vw, 1.27rem) * var(--ui-scale, 1));
    font-weight: 600;
	text-align: center;
    color: var(--accent-purple-light);
    margin-bottom: 1rem;
}

#panel-welcome .panel-title {
    font-size: calc(clamp(1.47rem, 2vw, 1.7rem) * var(--ui-scale, 1));
    line-height: 1.15;
    text-align: center;
}

#panel-welcome .panel-version {
    text-align: center;
}

.panel-desc {
    font-size: calc(clamp(0.95rem, 1.05vw, 1.08rem) * var(--ui-scale, 1));
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.88);
    text-shadow: var(--text-shadow-content);
}

.panel-desc a { font-weight: 600; }

.panel-thanks {
    font-size: calc(clamp(0.95rem, 1.05vw, 1.05rem) * var(--ui-scale, 1));
    color: #fff;
    text-align: center;
    margin-top: 0.75rem;
    font-weight: 600;
}

/* --- Social Icons (from launcher) --- */
.social-row {
    display: flex;
    gap: 1.25rem;
    justify-content: center;
    padding: 1.25rem 0 0.5rem;
}

.social-icon {
    color: rgba(255, 255, 255, 0.6);
    width: calc(2.25rem * var(--ui-scale, 1));
    height: calc(2.25rem * var(--ui-scale, 1));
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.social-icon:hover {
    color: var(--accent-purple-light);
    transform: translateY(-2px);
    text-decoration: none;
}

.social-icon svg { width: calc(1.7rem * var(--ui-scale, 1)); height: calc(1.7rem * var(--ui-scale, 1)); }

/* --- Disclaimer --- */
.disclaimer {
    font-size: calc(clamp(0.90rem, 0.96vw, 0.94rem) * var(--ui-scale, 1));
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.5);
    text-align: center;
    margin: 0.5rem 0 0.75rem;
}

/* --- Panel Buttons (Patch Notes / Support) --- */
#panel-welcome > .panel-buttons {
    display: flex;
    flex-direction: row;
    gap: 0.6rem;
    margin-top: 0;
    padding-top: 1.25rem;
    transform: translate(var(--panel-buttons-content-x), var(--panel-buttons-content-y));
}

/* --- Sticky panel header / Back Button --- */
.panel-sticky-header {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: flex-start;
    width: max-content;
    max-width: 100%;
    padding: 0;
    margin-bottom: 0.9rem;
    background: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    pointer-events: none;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--button-outline);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-size: calc(0.8rem * var(--ui-scale, 1));
    font-weight: 600;
    letter-spacing: 1px;
    cursor: pointer;
    text-transform: uppercase;
    padding: 0.48rem 0.85rem;
    transition: all 0.2s ease;
    align-self: flex-start;
    font-family: inherit;
    line-height: 1;
    text-decoration: none;
    margin-top: 0;
    position: relative;
    z-index: 1;
    min-height: 2rem;
    flex: 0 0 auto;
    pointer-events: auto;
}

.back-btn:hover,
.back-btn:focus-visible {
    background: rgba(156, 39, 176, 0.25);
    border-color: var(--button-outline);
    box-shadow: 0 4px 24px rgba(156, 39, 176, 0.2);
    color: var(--text-primary);
    transform: none;
}

.back-btn:active {
    transform: translateY(1px);
    box-shadow: 0 1px 6px rgba(156, 39, 176, 0.2);
}

/* --- Patch Notes List --- */
.patch-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 1rem;
}

.patch-entry {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem 1.15rem;
    background: var(--bg-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--button-outline);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    font-family: inherit;
    color: inherit;
}

.patch-entry:hover {
    background: rgba(156, 39, 176, 0.2);
    border-color: var(--button-outline);
    transform: translateY(-1px);
}

.patch-version {
    font-size: calc(0.95rem * var(--ui-scale, 1));
    font-weight: 700;
    color: var(--accent-purple-light);
    letter-spacing: 1px;
}

.patch-label {
    font-size: calc(0.8rem * var(--ui-scale, 1));
    color: var(--text-secondary);
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* --- Legal Content --- */
.legal-content {
    font-size: calc(clamp(1rem, 1.1vw, 1rem) * var(--ui-scale, 1));
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.78);
    margin-top: 1rem;
}

.legal-content h3 {
    font-size: calc(1.12rem * var(--ui-scale, 1));
    font-weight: 700;
    color: var(--text-primary);
    margin: 1.5rem 0 0.5rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.legal-content h3:first-child { margin-top: 0; }
.legal-content p { margin-bottom: 0.65rem; }
.legal-content ul { margin: 0.5rem 0 0.65rem 1.25rem; }
.legal-content li { margin-bottom: 0.3rem; }

/* --- Patch Detail Content --- */
.patch-content {
    font-size: calc(clamp(1rem, 1.1vw, 1rem) * var(--ui-scale, 1));
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 1rem;
}

.patch-content h3 {
    font-size: calc(1.12rem * var(--ui-scale, 1));
    font-weight: 700;
    color: var(--text-primary);
    margin: 1.25rem 0 0.5rem;
    letter-spacing: 1px;
}

.patch-content p { margin-bottom: 0.65rem; }
.patch-content ul { margin: 0.5rem 0 0.65rem 1.25rem; }
.patch-content ol { margin: 0.5rem 0 0.65rem 1.25rem; list-style: decimal; }
.patch-content li { margin-bottom: 0.3rem; }

/* Right-side readable copy needs its own heavy shadow because it sits directly
   over the bright blurred game background. Buttons are reset below so their
   frosted-glass treatment stays clean and launcher-like. */
.right-column :is(
    .panel-title,
    .panel-version,
    .panel-desc,
    .panel-thanks,
    .disclaimer,
    .legal-content,
    .legal-content h3,
    .legal-content p,
    .legal-content li,
    .patch-content,
    .patch-content h3,
    .patch-content p,
    .patch-content li
) {
    text-shadow: var(--text-shadow-content);
}

.right-column :is(.btn, .btn *, .patch-entry, .patch-entry *) {
    text-shadow: none;
}

/* ============================================
   Footer
   ============================================ */
.site-footer {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    padding: 1.25rem 2rem 1.5rem;
    transform: translate(var(--footer-content-x), var(--footer-content-y));
}

.footer-links {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.footer-links a {
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-muted);
    text-shadow: var(--text-shadow-footer);
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--accent-purple-light);
    text-decoration: none;
}

.footer-sep {
    color: var(--text-muted);
    opacity: 0.35;
    font-size: 0.65rem;
    text-shadow: var(--text-shadow-footer);
    user-select: none;
}

.footer-brand {
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--text-secondary);
    text-shadow: var(--text-shadow-footer);
}

/* ============================================
   Ultra-Large / 4K Displays
   ============================================ */
@media (min-width: 1921px) {
    html {
        font-size: max(16px, calc(100vw / 120));
    }
}

/* ============================================
   Accessibility / Perf
   ============================================ */
    @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .smoke-video {
        opacity: 0.24;
    }
}

@supports not (backdrop-filter: blur(1px)) {
    .btn, .status-badge, .patch-entry {
        background: rgba(0, 0, 0, 0.65);
    }
}

/* Short landscape laptops keep the desktop canvas treatment, but compress
   interactive content so the fixed footer does not sit on top of the page. */
@media (min-width: 901px) and (max-height: 850px) {
    :root {
        --main-gap: clamp(1.5rem, 3vw, 3rem);
        --left-stack-offset-x: 0.75rem;
        --left-stack-offset-y: 0;
        --left-media-width: clamp(25.625rem, 35vw, 29.375rem);
        --right-panel-width: clamp(31.25rem, 44vw, 37.5rem);
    }

    .site-main {
        padding-top: clamp(4.75rem, 9vh, 5.5rem);
        padding-bottom: 4.75rem;
    }

    .left-column { gap: 0.85rem; }

    .left-column-scale { gap: calc(0.85rem * var(--left-side-scale)); }

    .mobile-logo-stack {
        width: min(100%, calc(24rem * var(--left-side-scale)));
    }

    .static-logo-row {
        width: min(92%, 23rem);
        gap: 0.45rem;
    }

    .main-logo-wrap {
        max-width: calc(24rem * var(--left-side-scale));
    }

    .btn {
        padding: 0.62rem 0.85rem;
    }

    .panel-title {
        font-size: clamp(1.35rem, 2vw, 1.75rem);
    }

    .panel-version {
        margin-bottom: 0.55rem;
    }

    .panel-desc {
        font-size: 0.9rem;
        line-height: 1.45;
    }

    .panel-thanks { margin-top: 0.5rem; }

    .social-row {
        padding: 0.75rem 0 0.35rem;
    }

    .social-icon {
        width: 2rem;
        height: 2rem;
    }

    .social-icon svg {
        width: 1.45rem;
        height: 1.45rem;
    }

    .disclaimer {
        line-height: 1.4;
    }

    .panel-buttons { gap: 0.55rem; }
}

/* ============================================
   Mobile (≤ 900px)
   ============================================ */
@media (max-width: 900px) {
    :root {
        --header-logo-scale: 1;
        --left-stack-offset-x: 0;
        --left-stack-offset-y: 0;
        --left-content-x: 0px;
        --left-content-y: 0px;
        --left-side-scale: 1;
        --right-content-x: 0px;
        --right-content-y: 0px;
        --video-content-x: 0px;
        --video-content-y: 0px;
        --footer-content-x: 0px;
        --footer-content-y: 0px;
        --panel-buttons-content-x: 0px;
        --panel-buttons-content-y: 0px;
        --left-media-width: 100%;
        --right-panel-width: 100%;
    }

    .logo-layer {
        display: none;
    }

    .mobile-site-logo {
        display: block;
        width: clamp(7rem, 30vw, 9rem);
        height: auto;
        filter: drop-shadow(0 2px 12px rgba(0, 0, 0, 0.75));
    }

    .site-header {
        position: relative;
        top: auto;
        left: auto;
        right: auto;
        z-index: 20;
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        min-height: auto;
        gap: 0.35rem;
        padding: 1rem 1rem 0.35rem;
    }

    .status-badge {
        position: static;
        transform: none;
        margin: 0;
        padding: 0.45rem 1rem;
        gap: 0.5rem;
        font-size: 0.68rem;
        letter-spacing: 2px;
    }

    .status-dot {
        width: 0.5rem;
        height: 0.5rem;
    }

    .site-main {
        flex-direction: column;
        width: min(100%, 44rem);
        padding: 0.15rem 1rem 1rem;
        gap: 1.15rem;
        height: auto;
        min-height: auto;
    }

    .left-column {
        flex: none;
        max-width: 100%;
        align-items: center;
        transform: none;
    }

    .left-column-scale {
        width: 100%;
        transform: none;
        gap: 0.9rem;
    }

    .mobile-logo-stack {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: min(100%, 28rem);
        margin: 0 auto 0.5rem;
        pointer-events: none;
    }

    .static-logo-row {
        width: min(92%, 22rem);
        gap: 0.45rem;
        margin-bottom: -0.15rem;
    }

    .main-logo-wrap {
        width: 100%;
        max-width: 28rem;
        margin-top: -0.45rem;
    }

    .mobile-main-logo { width: 100%; }

    .main-game-logo,
    .static-logos,
    .download-buttons,
    .video-wrapper {
        max-width: 100%;
    }

    .download-buttons {
        justify-content: center;
        width: min(100%, 32rem);
        margin: 0 auto;
    }

    .video-wrapper {
        width: min(100%, 32rem);
        margin: 0 auto;
    }

    .right-column {
        position: relative;
        width: min(100%, 40rem);
        max-width: 100%;
        margin: 0 auto;
        height: auto;
        max-height: none;
        min-height: 0;
        overflow: visible;
    }

    .content-panel {
        position: absolute;
        height: 0;
        max-height: 0;
        overflow: hidden;
        padding-right: 0;
    }

    .content-panel.active {
        position: relative;
        height: auto;
        max-height: none;
        overflow: visible;
    }

    .site-footer {
        position: relative;
        left: auto;
        right: auto;
        bottom: auto;
        margin-top: 1.5rem;
    }
}

@media (max-width: 480px) {
    .social-row { gap: 0.75rem; }
    .social-icon svg { width: 1.25rem; height: 1.25rem; }
    .download-buttons,
    .panel-buttons {
        flex-direction: column;
        gap: 0.5rem;
    }

    .btn-text {
        white-space: normal;
        text-align: center;
    }
}
