/* =========================================================
   MOBILE APP — COMPLETELY SEPARATE FROM DESKTOP
   Logical canvas: 941 × 1672 px
   ========================================================= */

.mobile-app {
    display: none;
}

@media (orientation: portrait) {
    .mobile-app {
        position: fixed;
        inset: 0;
        display: block;
        overflow: hidden;
        background: #02050b;
    }

    /* -----------------------------------------------------
       MOBILE SCENE / LAYERS
       ----------------------------------------------------- */

    .mobile-scene {
        position: absolute;
        left: 0;
        top: 0;
        width: 941px;
        height: 1672px;
        transform-origin: left top;
        isolation: isolate;
        background: #02050b;
    }

    .mobile-scene-layer {
        position: absolute;
        inset: 0;
        display: block;
        width: 941px;
        height: 1672px;
        max-width: none;
        pointer-events: none;
        user-select: none;
    }

    .mobile-layer-background { z-index: 1; }
    .mobile-layer-midground { z-index: 5; }

    .mobile-holo-group {
        position: absolute;
        inset: 0;
        z-index: 10;
        width: 941px;
        height: 1672px;
    }

    .mobile-layer-holo-base { z-index: 1; }
    .mobile-layer-projector-effects { z-index: 30; }
    .mobile-layer-foreground { z-index: 40; }

    /* -----------------------------------------------------
       MOBILE HOLO PLANE

       Safe quad estimated from Mobile-Master:
       TL 88/150 · TR 835/104 · BR 842/1095 · BL 70/1080
       ----------------------------------------------------- */

    .mobile-holo {
        position: absolute;
        left: 0;
        top: 0;
        z-index: 2;

        width: 760px;
        height: 1000px;
        padding: 0;
        overflow: hidden;

        transform: matrix3d(
             0.915795670, -0.068883565, 0, -0.000080358,
            -0.020228076,  0.895623971, 0, -0.000031830,
             0,            0,           1,  0,
            88,          150,           0,  1
        );
        transform-origin: 0 0;

        color: rgba(224, 248, 255, 0.94);
        text-shadow: 0 0 8px rgba(85, 210, 255, 0.24);
    }

    .mobile-holo::after {
        content: "";
        position: absolute;
        inset: 0;
        z-index: 90;
        pointer-events: none;
        background: repeating-linear-gradient(
            to bottom,
            rgba(160, 230, 255, 0.020) 0,
            rgba(160, 230, 255, 0.020) 1px,
            transparent 1px,
            transparent 5px
        );
    }

    /* -----------------------------------------------------
       MOBILE CONTENT
       ----------------------------------------------------- */

    .mobile-holo-content {
        position: absolute;
        inset: 0;
        z-index: 5;
        width: 100%;
        height: 100%;
        padding: 120px 46px 170px 42px;
        overflow: hidden;
        transition: opacity 180ms ease, filter 180ms ease;
    }

    .mobile-holo[data-route="home"] .mobile-holo-content {
        padding: 78px 42px 72px;
    }

    .mobile-holo .route-page,
    .mobile-holo .panel-scroll {
        width: 100%;
        height: 100%;
        min-width: 0;
    }

    .mobile-holo .panel-scroll {
        overflow-y: auto;
        overflow-x: hidden;
        padding-right: 18px;
        scrollbar-width: thin;
        scrollbar-color: rgba(145, 228, 255, 0.34) rgba(80, 170, 210, 0.08);
    }

    .mobile-holo .panel-scroll::-webkit-scrollbar {
        width: 9px;
    }

    .mobile-holo .panel-scroll::-webkit-scrollbar-track {
        background: rgba(80, 170, 210, 0.08);
    }

    .mobile-holo .panel-scroll::-webkit-scrollbar-thumb {
        background: rgba(145, 228, 255, 0.34);
        border-radius: 20px;
    }

    .mobile-holo .panel h1,
    .mobile-holo h1 {
        margin: 0 0 24px;
        padding-right: 0;
        font-size: 40px;
        line-height: 1.12;
        letter-spacing: 0.10em;
    }

    .mobile-holo .panel h2,
    .mobile-holo h2 {
        margin: 0 0 19px;
        font-size: 34px;
        line-height: 1.18;
        letter-spacing: 0.08em;
    }

    .mobile-holo .panel p,
    .mobile-holo p {
        max-width: none;
        margin: 0 0 24px;
        font-size: 29px;
        line-height: 1.48;
    }

    .mobile-holo .holo-link {
        padding-bottom: 5px;
        border-bottom-width: 2px;
    }

    /* HOME is intentionally dominated by the band logo. */
    .mobile-holo .intro-logo {
        max-width: 84%;
        max-height: 500px;
    }

    /* -----------------------------------------------------
       MOBILE HAMBURGER
       ----------------------------------------------------- */

    .mobile-menu-toggle {
        position: absolute;
        top: 24px;
        right: 22px;
        z-index: 70;

        display: flex;
        width: 98px;
        height: 90px;
        padding: 20px;

        flex-direction: column;
        justify-content: space-between;
        align-items: stretch;

        border: 1px solid rgba(160, 236, 255, 0.34);
        background: rgba(25, 119, 178, 0.12);
        box-shadow:
            inset 0 0 24px rgba(84, 210, 255, 0.08),
            0 0 22px rgba(82, 213, 255, 0.12);

        cursor: pointer;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .mobile-menu-toggle span {
        display: block;
        width: 100%;
        height: 7px;
        background: rgba(235, 252, 255, 0.98);
        box-shadow:
            0 0 9px rgba(119, 226, 255, 0.98),
            0 0 20px rgba(70, 197, 255, 0.54);
        transform-origin: center;
        transition: transform 180ms ease, opacity 150ms ease;
    }

    .mobile-holo.mobile-menu-open .mobile-menu-toggle span:nth-child(1) {
        transform: translateY(21px) rotate(45deg);
    }

    .mobile-holo.mobile-menu-open .mobile-menu-toggle span:nth-child(2) {
        opacity: 0;
    }

    .mobile-holo.mobile-menu-open .mobile-menu-toggle span:nth-child(3) {
        transform: translateY(-21px) rotate(-45deg);
    }

    /* -----------------------------------------------------
       MOBILE MENU OVERLAY
       ----------------------------------------------------- */

    .mobile-menu {
        position: absolute;
        inset: 0;
        z-index: 60;

        padding: 128px 52px 62px 50px;
        overflow-y: auto;

        background:
            linear-gradient(
                180deg,
                rgba(2, 25, 61, 0.92) 0%,
                rgba(2, 31, 72, 0.88) 52%,
                rgba(3, 32, 70, 0.93) 100%
            );
        box-shadow: inset 0 0 95px rgba(39, 175, 237, 0.15);

        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateY(-10px);
        transition: opacity 170ms ease, visibility 170ms ease, transform 190ms ease;
    }

    .mobile-holo.mobile-menu-open .mobile-menu {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    .mobile-holo.mobile-menu-open .mobile-holo-content {
        opacity: 0.12;
        filter: blur(3px);
    }

    .mobile-menu-inner {
        display: grid;
        gap: 4px;
    }

    .mobile-menu button {
        appearance: none;
        width: 100%;
        border: 0;
        background: transparent;
        color: rgba(222, 248, 255, 0.90);
        text-align: left;
        text-transform: uppercase;
        cursor: pointer;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .mobile-menu-item {
        min-height: 96px;
        padding: 18px 18px;
        border-bottom: 1px solid rgba(140, 225, 255, 0.20) !important;
        font-size: 40px;
        font-weight: 700;
        line-height: 1;
        letter-spacing: 0.14em;
        text-shadow:
            0 0 9px rgba(105, 225, 255, 0.56),
            0 0 22px rgba(70, 185, 255, 0.26);
    }

    .mobile-menu-item.active,
    .mobile-band-submenu button.active,
    .mobile-band-toggle.active {
        color: #fff;
        text-shadow:
            0 0 10px rgba(128, 235, 255, 0.98),
            0 0 26px rgba(65, 200, 255, 0.62);
    }

    .mobile-band-toggle {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .mobile-menu-chevron {
        flex: 0 0 auto;
        font-size: 49px;
        font-weight: 300;
        line-height: 1;
        transition: transform 180ms ease;
    }

    .mobile-band-toggle[aria-expanded="true"] .mobile-menu-chevron {
        transform: rotate(45deg);
    }

    .mobile-band-submenu {
        display: block;
        max-height: 0;
        overflow: hidden;
        transition: max-height 220ms ease;
    }

    .mobile-band-submenu.open {
        max-height: 360px;
    }

    .mobile-band-submenu button {
        min-height: 78px;
        padding: 14px 20px 14px 58px;
        border-bottom: 1px solid rgba(135, 220, 250, 0.11);
        font-size: 32px;
        font-weight: 600;
        line-height: 1;
        letter-spacing: 0.12em;
        color: rgba(208, 243, 252, 0.76);
    }

    /* -----------------------------------------------------
       SMALL LOGO = HOME LINK ON ALL CONTENT PAGES
       ----------------------------------------------------- */

    .mobile-home-logo {
        position: absolute;
        right: 30px;
        bottom: 32px;
        z-index: 30;

        display: block;
        width: 154px;
        height: 116px;
        padding: 8px;

        border: 0;
        background: transparent;
        cursor: pointer;
        opacity: 0.86;
        filter:
            drop-shadow(0 0 7px rgba(114, 225, 255, 0.38))
            drop-shadow(0 0 18px rgba(80, 200, 255, 0.20));
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    .mobile-home-logo img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: contain;
    }

    .mobile-holo[data-route="home"] .mobile-home-logo,
    .mobile-holo.mobile-menu-open .mobile-home-logo {
        display: none;
    }

    /* -----------------------------------------------------
       CONTENT-SPECIFIC MOBILE TUNING
       ----------------------------------------------------- */

    .mobile-holo .audio-panel { padding-top: 0; }

    .mobile-holo .audio-kicker,
    .mobile-holo .live-date,
    .mobile-holo .member span,
    .mobile-holo .press-kicker {
        font-size: 21px;
    }

    .mobile-holo .audio-player,
    .mobile-holo .live-event,
    .mobile-holo .member-rich p {
        max-width: none;
    }

    .mobile-holo .audio-player { gap: 28px; }
    .mobile-holo .audio-toggle { width: 82px; height: 82px; }
    .mobile-holo .audio-time { font-size: 21px; }

    .mobile-holo .live-links {
        gap: 18px 28px;
        margin-top: 26px;
        font-size: 27px;
    }

    .mobile-holo .member-list-rich { display: block; }

    .mobile-holo .member-rich {
        padding: 18px 0 25px;
    }

    .mobile-holo .member-rich strong {
        font-size: 31px;
        line-height: 1.2;
    }

    .mobile-holo .member-rich span {
        display: block;
        margin-top: 4px;
        font-size: 21px;
    }

    .mobile-holo .member-rich p {
        margin-top: 13px;
        font-size: 27px;
        line-height: 1.48;
    }

    .mobile-holo .press-panel,
    .mobile-holo .contact-panel {
        height: 100%;
        padding-right: 0;
    }

    .mobile-holo .press-kit-primary {
        margin-bottom: 28px;
        padding: 20px;
    }

    .mobile-holo .press-kit-primary h2,
    .mobile-holo .press-group h2 {
        font-size: 22px;
    }

    .mobile-holo .press-kit-download,
    .mobile-holo .press-download,
    .mobile-holo .download-title,
    .mobile-holo .press-photo-title {
        font-size: 26px !important;
        line-height: 1.35 !important;
    }

    .mobile-holo .press-kit-download,
    .mobile-holo .press-download {
        padding-top: 15px;
        padding-bottom: 15px;
    }

    .mobile-holo .press-files-heading { font-size: 25px; }
    .mobile-holo .press-photo-copy { display: block; }

    .mobile-holo .press-photo-ai,
    .mobile-holo .download-note,
    .mobile-holo .press-ai-note,
    .mobile-holo .site-image-note,
    .mobile-holo .privacy p,
    .mobile-holo .imprint p {
        font-size: 20px !important;
        line-height: 1.42 !important;
    }

    .mobile-holo .contact-block {
        gap: 14px;
        font-size: 29px;
    }

    .mobile-holo .imprint-title { font-size: 21px; }

    /* PHOTO: no desktop subnav; photo uses the large portrait holo. */
    .mobile-holo .band-photo-stage {
        position: relative;
        width: 100%;
        height: 100%;
        align-items: flex-end;
        justify-content: flex-start;
        overflow: hidden;
    }

    .mobile-holo .band-photo-effect {
        width: 100%;
        height: 82%;
        justify-content: flex-start;
        align-items: flex-end;
        transform: translate(-12px, 42px);
    }

    .mobile-holo .band-photo-effect::after {
        -webkit-mask-position: left bottom;
        mask-position: left bottom;
    }

    .mobile-holo .band-photo {
        object-position: left bottom;
    }

    .mobile-holo .band-photo-note {
        left: 3%;
        right: auto;
        top: auto;
        bottom: 126px;
        width: 68%;
        max-width: none;
        min-width: 0;
        transform: none;
        display: grid;
        grid-template-columns: 1fr;
        gap: 7px;
        font-size: 18px;
    }

    .mobile-holo .band-photo-note span {
        padding: 10px 0 10px 12px;
    }

    /* -----------------------------------------------------
       MOBILE GLOBAL AI NOTE
       ----------------------------------------------------- */

    .mobile-background-ai-note {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        z-index: 90;
        display: flex;
        width: 18px;
        margin: 0;
        padding: 6px 0;
        align-items: center;
        justify-content: center;
        writing-mode: vertical-rl;
        text-orientation: mixed;
        color: rgba(232, 247, 252, 0.78);
        font-size: 7px;
        line-height: 1;
        letter-spacing: 0.02em;
        white-space: nowrap;
        text-align: center;
        text-shadow: 0 1px 6px rgba(0, 0, 0, 0.95);
        background: rgba(2, 10, 18, 0.55);
        border-right: 1px solid rgba(118, 221, 248, 0.14);
        pointer-events: none;
    }
}

@media (orientation: portrait) and (prefers-reduced-motion: reduce) {
    .mobile-menu,
    .mobile-menu-toggle span,
    .mobile-holo-content,
    .mobile-menu-chevron {
        transition: none !important;
    }
}

@media (orientation: portrait) {
    .mobile-holo.switching {
        animation: holoSwitch 240ms linear;
    }
}

/* =========================================================
   MOBILE VIEWPORT FIX V3 — ANDROID / DYNAMIC BROWSER CHROME
   - The mobile app uses the browser's actual fixed viewport box.
   - No 100dvh/VisualViewport mix: both container and scene use
     exactly the same measured dimensions.
   - Scene stays pinned to the top; any crop happens at bottom/sides.
   ========================================================= */

@media (orientation: portrait) {
    .mobile-app {
        position: fixed;
        inset: 0;
        width: auto;
        height: auto;
        overflow: hidden;
        background: #02050b;
    }

    .mobile-scene {
        top: 0 !important;
        will-change: transform;
        backface-visibility: hidden;
        -webkit-backface-visibility: hidden;
    }

    .mobile-scene-layer,
    .mobile-holo-group {
        backface-visibility: hidden;
        -webkit-backface-visibility: hidden;
    }

    .mobile-holo[data-route="home"] .route-home,
    .mobile-holo[data-route="home"] .intro,
    .mobile-holo[data-route="home"] .intro-logo-wrap {
        overflow: visible;
    }
}


/* RECOVERY: mobile Holo-menu visual fit only. */
.mobile-menu {
    inset: 22px 18px 28px;
    padding: 104px 38px 34px;
    border: 1px solid rgba(150, 232, 255, 0.13);
    border-radius: 22px;
    background:
        linear-gradient(
            180deg,
            rgba(3, 34, 76, 0.50) 0%,
            rgba(4, 47, 94, 0.42) 52%,
            rgba(3, 36, 77, 0.52) 100%
        );
    box-shadow:
        inset 0 0 68px rgba(76, 208, 255, 0.09),
        0 0 12px rgba(40, 180, 232, 0.04);
    backdrop-filter: blur(0.7px);
    -webkit-backdrop-filter: blur(0.7px);
}

.mobile-menu-toggle {
    width: 80px;
    height: 72px;
    padding: 16px;
    border-radius: 15px;
}

.mobile-menu-item {
    min-height: 70px;
    padding: 11px 14px;
    font-size: 30px;
    letter-spacing: 0.11em;
}

.mobile-menu-chevron {
    font-size: 36px;
}

.mobile-band-submenu.open {
    max-height: 250px;
}

.mobile-band-submenu button {
    min-height: 52px;
    padding: 8px 14px 8px 42px;
    font-size: 23px;
    letter-spacing: 0.10em;
}

.mobile-holo.mobile-menu-open .mobile-holo-content {
    opacity: 0.38;
    filter: blur(1px);
}

/* =========================================================
   MOBILE PHOTO PAGE — PHOTO-SPECIFIC GRID ONLY
   Other mobile pages keep the existing text-container width.
   ========================================================= */

@media (orientation: portrait) {
    /* PHOTO alone may use the right rail shared by hamburger + Home logo.
       Left padding and every other mobile route remain unchanged. */
    .mobile-holo[data-route="photo"] .mobile-holo-content {
        padding-right: 22px;
    }

    .mobile-holo[data-route="photo"] .mobile-home-logo {
        right: 22px;
    }

    /* Keep the existing photo size, but align its actual right edge
       to the PHOTO page's right rail instead of floating in the middle. */
    .mobile-holo[data-route="photo"] .band-photo-effect {
        width: 100%;
        height: 82%;
        justify-content: flex-end;
        align-items: flex-end;
        transform: translate(0, 42px);
    }

    .mobile-holo[data-route="photo"] .band-photo {
        object-position: right bottom;
    }

    /* Move the KI/typewriter annotation into the intentionally empty
       upper area. It no longer sits across the band photo. */
    .mobile-holo[data-route="photo"] .band-photo-note {
        left: 0;
        right: auto;
        top: 18px;
        bottom: auto;

        width: 58%;
        max-width: none;
        min-width: 0;

        transform: none;
        gap: 5px;

        font-size: 16px;
        line-height: 1.08;
        letter-spacing: 0.015em;
        text-align: left;
    }

    .mobile-holo[data-route="photo"] .band-photo-note span {
        padding: 8px 5px 8px 9px;
    }
}



/* =========================================================
   DESKTOP BROWSER / PORTRAIT MOBILE-LAYOUT SCROLL
   Only mouse/fine-pointer desktop browsers.
   Real mobile portrait keeps the established fixed Android viewport logic.
   ========================================================= */
@media (orientation: portrait) and (hover: hover) and (pointer: fine) {
    .mobile-app.desktop-portrait-scroll {
        overflow-y: auto;
        overflow-x: hidden;
        overscroll-behavior: contain;
        touch-action: pan-y;
        -webkit-overflow-scrolling: touch;

        scrollbar-width: thin;
        scrollbar-color:
            rgba(145, 228, 255, 0.42)
            rgba(4, 35, 70, 0.08);
    }

    /* Invisible flow spacer: the scene stays absolutely positioned,
       but this gives the viewport the exact scaled height to scroll. */
    .mobile-app.desktop-portrait-scroll::after {
        content: "";
        display: block;
        width: 1px;
        height: var(--desktop-portrait-scroll-height, 100vh);
        pointer-events: none;
    }

    .mobile-app.desktop-portrait-scroll::-webkit-scrollbar {
        width: 7px;
    }

    .mobile-app.desktop-portrait-scroll::-webkit-scrollbar-track {
        background: rgba(4, 35, 70, 0.08);
    }

    .mobile-app.desktop-portrait-scroll::-webkit-scrollbar-thumb {
        background: rgba(145, 228, 255, 0.42);
        border-radius: 20px;
        border: 1px solid rgba(2, 18, 36, 0.26);
    }

    .mobile-app.desktop-portrait-scroll::-webkit-scrollbar-thumb:hover {
        background: rgba(165, 238, 255, 0.58);
    }

    .mobile-app.desktop-portrait-scroll::-webkit-scrollbar-button {
        display: none;
        width: 0;
        height: 0;
    }
}
