        .jiminin-boot-splash {
            position: fixed;
            inset: 0;
            z-index: 24000;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-direction: column;
            gap: 18px;
            padding: 24px;
            background: #000;
            background-size: 100% 100%;
            background-position: center;
            background-repeat: no-repeat;
            color: #fff;
            font-family: 'M PLUS Rounded 1c', 'Zen Kaku Gothic New', sans-serif;
            text-align: center;
            pointer-events: none;
            opacity: 1;
            animation: jimininBootSplashFade 6s ease-in-out forwards, bootScreenShake 0.4s cubic-bezier(.36,.07,.19,.97) 3.5s forwards;
        }

        .jiminin-boot-splash.is-hidden {
            display: none;
        }

        .jiminin-boot-mascot {
            width: min(54vw, 300px);
            max-height: 42vh;
            object-fit: contain;
            opacity: 0;
            transform: translateY(10px) scale(0.88);
            filter: drop-shadow(0 0 28px rgba(103, 255, 48, 0.42));
            animation: jimininBootMascotFade 2.05s 1.7s ease-in-out forwards;
        }

        .jiminin-boot-presenter {
            position: absolute;
            left: 50%;
            top: 50%;
            transform: translate(-50%, -50%);
            color: rgba(255, 255, 255, 0.94);
            font-size: clamp(22px, 5vw, 48px);
            font-weight: 900;
            letter-spacing: 0.14em;
            line-height: 1.45;
            opacity: 0;
            white-space: nowrap;
            text-shadow: 0 0 16px rgba(103, 255, 48, 0.55), 0 4px 0 rgba(0,0,0,0.42);
            animation: jimininBootPresenterFade 1.75s 0.08s ease-in-out forwards;
        }

        .jiminin-boot-presenter span {
            display: block;
            color: rgba(178, 255, 142, 0.96);
            font-size: clamp(12px, 2.4vw, 18px);
            letter-spacing: 0.24em;
        }

        .jiminin-boot-title {
            display: none;
        }

        .jiminin-boot-loading {
            position: absolute;
            left: 50%;
            bottom: clamp(34px, 8vh, 72px);
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 9px 16px;
            border: 2px solid rgba(102, 199, 160, 0.72);
            border-radius: 999px;
            background: rgba(1, 8, 18, 0.72);
            color: #baffdf;
            font-size: clamp(12px, 3vw, 18px);
            font-weight: 900;
            letter-spacing: 0.1em;
            opacity: 1;
            transform: translateX(-50%);
            box-shadow: 0 0 18px rgba(0, 243, 255, 0.3), inset 0 0 18px rgba(0, 230, 118, 0.14);
            animation: jimininBootLoadingFade 5s ease-in-out forwards;
        }

        .jiminin-boot-loading::after {
            content: '...';
            width: 1.4em;
            overflow: hidden;
            animation: jimininLoadingDots 0.9s steps(4, end) infinite;
        }

        .jiminin-mascot-card {
            display: flex;
            align-items: center;
            gap: 14px;
            margin: 0 0 18px;
            padding: 12px 14px;
            border: 2px solid rgba(102, 199, 160, 0.36);
            border-radius: 22px;
            background: rgba(255, 255, 255, 0.62);
            text-align: left;
            box-shadow: inset 0 0 0 1px rgba(255,255,255,0.5), 0 12px 20px rgba(105, 127, 83, 0.12);
        }

        .jiminin-mascot-card img {
            width: clamp(76px, 20vw, 128px);
            flex: 0 0 auto;
            filter: drop-shadow(0 10px 12px rgba(105, 127, 83, 0.2));
        }

        .jiminin-mascot-card strong {
            display: block;
            color: #4c8f63;
            font-size: 16px;
            margin-bottom: 4px;
        }

        .jiminin-mascot-card span {
            display: block;
            color: #5b5536;
            font-size: 13px;
            line-height: 1.6;
            font-family: 'M PLUS Rounded 1c', 'Zen Kaku Gothic New', sans-serif;
        }


        .jiminin-boot-shuriken {
            position: absolute;
            left: 50%;
            top: 50%;
            width: 120px;
            height: 120px;
            margin-left: -60px;
            margin-top: -60px;
            opacity: 0;
            background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M50 0 L60 40 L100 50 L60 60 L50 100 L40 60 L0 50 L40 40 Z" fill="%230a192f" stroke="%2300e676" stroke-width="4" stroke-linejoin="round"/><circle cx="50" cy="50" r="10" fill="%23000" stroke="%2300e676" stroke-width="2"/></svg>');
            background-size: contain;
            background-repeat: no-repeat;
            background-position: center;
            filter: drop-shadow(0 0 20px rgba(0, 230, 118, 0.8));
            animation: shurikenStrike 0.8s cubic-bezier(0.1, 0.8, 0.3, 1) 3.1s forwards;
            z-index: 10;
        }

        @keyframes shurikenStrike {
            0% { opacity: 0; transform: scale(8) rotate(0deg) translateZ(500px); }
            50% { opacity: 1; }
            80% { opacity: 1; transform: scale(0.6) rotate(1440deg); }
            90% { opacity: 1; transform: scale(1.3) rotate(1440deg); }
            100% { opacity: 1; transform: scale(1) rotate(1440deg); }
        }

        @keyframes bootScreenShake {
            0%, 100% { transform: translate3d(0, 0, 0); }
            10%, 30%, 50%, 70%, 90% { transform: translate3d(-10px, 8px, 0); }
            20%, 40%, 60%, 80% { transform: translate3d(10px, -8px, 0); }
        }

        @keyframes jimininBootSplashFade {
            0%, 88% { opacity: 1; }
            100% { opacity: 0; visibility: hidden; }
        }

        @keyframes jimininBootPresenterFade {
            0% { opacity: 0; transform: translate(-50%, calc(-50% + 10px)) scale(0.96); }
            24%, 62% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
            100% { opacity: 0; transform: translate(-50%, calc(-50% - 8px)) scale(1.02); }
        }

        @keyframes jimininBootMascotFade {
            0% { opacity: 0; transform: translateY(12px) scale(0.86); }
            28%, 70% { opacity: 1; transform: translateY(0) scale(0.92); }
            100% { opacity: 0; transform: translateY(-8px) scale(0.94); }
        }

        @keyframes jimininBootLoadingFade {
            0%, 88% { opacity: 1; }
            100% { opacity: 0; }
        }

        @keyframes jimininLoadingDots {
            from { width: 0; }
            to { width: 1.4em; }
        }

        @media (max-width: 560px) {
            .jiminin-mascot-card {
                flex-direction: column;
                text-align: center;
            }
        }

        @media (prefers-reduced-motion: reduce) {
            .jiminin-boot-splash,
            .jiminin-boot-mascot,
            .jiminin-boot-loading::after {
                animation-duration: 0.01ms !important;
                animation-iteration-count: 1 !important;
            }
        }

        .system-hidden-wrapper {
            display: none !important;
            opacity: 0;
            z-index: -9999;
            position: absolute;
        }


        .seo-intro {
            position: absolute;
            width: 1px;
            height: 1px;
            margin: -1px;
            padding: 0;
            border: 0;
            overflow: hidden;
            clip: rect(0 0 0 0);
            clip-path: inset(50%);
            white-space: nowrap;
        }

        :root {
            --neon-cyan: #66c7a0;
            --neon-blue: #7bbfdf;
            --island-mint: #66c7a0;
            --island-leaf: #8dcf73;
            --island-sand: #f7e7b7;
            --island-cream: #fff8dc;
            --island-wood: #b88755;
            --island-coral: #ff9f80;
            --island-sky: #9ddff0;
            --glass-bg: rgba(255, 248, 220, 0.78);
            --glass-border: rgba(112, 151, 99, 0.34);
            --pixel-font: 'Press Start 2P', cursive;
            --flash-opacity: 0.02;
            --speed-bg: 0s;
            --speed-news: 30s;
            --speed-bar-fast: 8s;
            --speed-bar-slow: 16s;
        }

        /* === アプリモード (mode-app): ほぼ全て非表示・停止 === */
        /* これにより描画負荷をゼロにし、メモリをアプリに集中させます */
        body.mode-app * {
            animation-play-state: paused !important;
        }

        body.mode-app .bg-layer,
        body.mode-app .scanline-overlay,
        body.mode-app #trailCanvas,
        body.mode-app .cyber-panel,
        body.mode-app .news-ticker-container,
        body.mode-app .system-hud .brand-logo {
            display: none !important;
        }

        body.mode-app .system-hud {
            background: transparent;
            pointer-events: none;
        }

        /* === ゲームモード (mode-game): ゲーム以外の背景演出を停止 === */
        body.mode-game *,
        body.mode-game .status-bar,
        body.mode-game .news-scroller,
        body.mode-game .blink-led,
        body.mode-game .bg-grid {
            animation-play-state: paused !important;
        }

        body.mode-game #trailCanvas {
            display: none !important;
        }

        /* === ポーズモード (mode-paused): 表示したまま停止 === */
        body.mode-paused *,
        body.mode-paused .status-bar,
        body.mode-paused .news-scroller,
        body.mode-paused .blink-led,
        body.mode-paused .bg-grid {
            animation-play-state: paused !important;
            transition: none !important;
        }

        * {
            box-sizing: border-box;
            user-select: none;
            -webkit-tap-highlight-color: transparent;
        }

        html,
        body {
            margin: 0;
            padding: 0;
            width: 100%;
            height: 100%;
            overflow: hidden;
            background: #9ddff0;
            font-family: var(--pixel-font);
            color: #3f4a2f;
        }

        #trailCanvas {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            pointer-events: none;
            z-index: 9999;
            display: none;
        }

        #flashOverlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            pointer-events: none;
            z-index: 9998;
            background: transparent;
        }

        .flash-active {
            animation: crystalPulse 0.5s ease-out forwards;
        }

        @keyframes crystalPulse {
            0% {
                background: rgba(200, 255, 255, var(--flash-opacity));
            }

            100% {
                background: transparent;
            }
        }

        .bg-layer {
            position: fixed;
            inset: 0;
            background:
                radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.7) 0 7%, transparent 16%),
                radial-gradient(circle at 82% 12%, rgba(255, 248, 220, 0.9) 0 9%, transparent 18%),
                linear-gradient(180deg, #9ddff0 0%, #bdeec8 50%, #f7e7b7 100%);
            z-index: -10;
            pointer-events: none;
        }

        .bg-grid {
            display: none;
            position: absolute;
            width: 200%;
            height: 200%;
            top: -50%;
            left: -50%;
            background-image:
                radial-gradient(ellipse at center, rgba(255,255,255,0.45) 0 16%, transparent 18%),
                linear-gradient(rgba(102, 199, 160, 0.14) 1px, transparent 1px),
                linear-gradient(90deg, rgba(102, 199, 160, 0.12) 1px, transparent 1px);
            background-size: 120px 80px, 44px 44px, 44px 44px;
            transform: perspective(500px) rotateX(58deg);
            animation: islandDrift 28s ease-in-out infinite alternate;
        }

        .scanline-overlay {
            display: none;
            position: fixed;
            inset: 0;
            background:
                radial-gradient(circle at 20% 30%, rgba(255,255,255,0.22) 0 2px, transparent 3px),
                radial-gradient(circle at 70% 70%, rgba(255,248,220,0.24) 0 2px, transparent 3px);
            background-size: 90px 90px, 130px 130px;
            pointer-events: none;
            z-index: 9999;
            opacity: 0.35;
            animation: sparkleFloat 18s ease-in-out infinite alternate;
        }

        .system-hud {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 60px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 0 20px;
            background: linear-gradient(to bottom, rgba(255, 248, 220, 0.85), rgba(255, 248, 220, 0));
            z-index: 100;
            pointer-events: none;
        }

        .system-hud>* {
            pointer-events: auto;
        }

        .brand-logo {
            display: flex;
            align-items: center;
            gap: 10px;
            font-size: 18px;
            color: #3f4a2f;
            text-shadow: 0 2px 0 rgba(255, 255, 255, 0.85);
            letter-spacing: 2px;
        }

        .logo-icon svg {
            width: 24px;
            height: 24px;
            filter: drop-shadow(0 0 5px var(--neon-cyan));
        }

        .news-ticker-container {
            flex: 1;
            margin: 0 20px;
            overflow: hidden;
            height: 20px;
            mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
        }

        .news-scroller {
            white-space: nowrap;
            animation: ticker var(--speed-news) linear infinite;
            color: #fff;
            font-size: 12px;
            will-change: transform;
        }

        @keyframes ticker {
            0% {
                transform: translateX(100%);
            }

            100% {
                transform: translateX(-100%);
            }
        }

        .cyber-panel {
            position: absolute;
            top: 60px;
            bottom: 0;
            width: 60px;
            background: rgba(255, 248, 220, 0.62);
            border: 1px solid rgba(255, 255, 255, 0.05);
            display: flex;
            flex-direction: column;
            align-items: center;
            padding: 20px 0;
            z-index: 50;
            pointer-events: none;
            backdrop-filter: blur(2px);
        }

        .cyber-panel.left {
            left: 0;
            border-right: 1px solid rgba(102, 199, 160, 0.35);
        }

        .cyber-panel.right {
            right: 0;
            border-left: 1px solid rgba(102, 199, 160, 0.35);
        }

        .panel-label {
            writing-mode: vertical-rl;
            text-orientation: mixed;
            font-size: 12px;
            letter-spacing: 2px;
            color: rgba(255, 255, 255, 0.4);
            margin-bottom: 20px;
            font-family: 'Share Tech Mono', monospace;
            text-shadow: 0 0 5px var(--neon-cyan);
        }

        .status-bar-group {
            display: flex;
            flex-direction: column;
            gap: 5px;
            width: 10px;
            flex: 1;
            justify-content: center;
        }

        .status-bar {
            width: 100%;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 2px;
            will-change: opacity, width, box-shadow;
        }

        .left .status-bar {
            animation: cyberHeartbeat var(--speed-bar-fast) infinite steps(24);
            background: var(--neon-cyan);
            opacity: 0.3;
            transform-origin: center;
        }

        .left .status-bar:nth-child(even) {
            height: 16px;
            animation-duration: var(--speed-bar-slow);
        }

        .left .status-bar:nth-child(odd) {
            height: 6px;
            animation-duration: var(--speed-bar-fast);
        }

        @keyframes cyberHeartbeat {

            0%,
            100% {
                opacity: 0.2;
                background: var(--neon-cyan);
                box-shadow: 0 0 2px var(--neon-cyan);
                transform: scaleX(0.9);
            }

            50% {
                opacity: 1.0;
                background: #ffffff;
                box-shadow: 0 0 15px #ffffff, 0 0 30px var(--neon-cyan);
                transform: scaleX(1.1);
            }
        }

        .right .status-bar {
            height: 4px;
            margin-bottom: 4px;
            background: var(--neon-blue);
            animation: dataBurst 1.5s infinite alternate steps(48);
        }

        @keyframes dataBurst {
            0% {
                width: 15%;
                opacity: 0.4;
                background: var(--neon-blue);
                box-shadow: none;
            }

            50% {
                background: var(--neon-cyan);
            }

            100% {
                width: 100%;
                opacity: 1;
                background: #ffffff;
                box-shadow: 0 0 10px #ffffff, 0 0 20px var(--neon-cyan);
            }
        }

        .right .status-bar:nth-child(1) {
            animation-duration: 3.5s;
            animation-delay: 0.2s;
        }

        .right .status-bar:nth-child(2) {
            animation-duration: 4.2s;
            animation-delay: 0.8s;
        }

        .right .status-bar:nth-child(3) {
            animation-duration: 2.9s;
            animation-delay: 0.0s;
        }

        .right .status-bar:nth-child(4) {
            animation-duration: 3.8s;
            animation-delay: 0.5s;
        }

        .right .status-bar:nth-child(5) {
            animation-duration: 3.1s;
            animation-delay: 1.2s;
        }

        .right .status-bar:nth-child(6) {
            animation-duration: 4.5s;
            animation-delay: 0.3s;
        }

        .panel-deco-icon {
            margin-top: auto;
            font-size: 24px;
            opacity: 0.6;
            cursor: pointer;
            pointer-events: auto;
            transition: 0.2s;
        }

        .panel-deco-icon:hover {
            opacity: 1;
            transform: scale(1.2);
            text-shadow: 0 0 10px #fff;
        }

        .panel-deco-icon:active {
            transform: scale(0.9);
        }

        .console-stage {
            position: absolute;
            top: 60px;
            bottom: 100px;
            left: 60px;
            right: 60px;
            width: auto;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            perspective: 1200px;
            z-index: 10;
            pointer-events: none;
            gap: 20px;
        }

        .console-stage>* {
            pointer-events: auto;
        }

        .cassette-card {
            position: relative;
            width: 640px;
            height: 420px;
            max-width: 100%;
            max-height: 50vh;
            background: var(--glass-bg);
            border: 2px solid var(--glass-border);
            border-radius: 24px;
            box-shadow: 0 18px 35px rgba(105, 127, 83, 0.28), inset 0 0 0 4px rgba(255,255,255,0.28);
            animation: islandFloat 7s ease-in-out infinite;
            backdrop-filter: blur(10px);
            display: flex;
            flex-direction: column;
            transition: 0.4s;
            transform-style: preserve-3d;
        }

        .card-header {
            height: 30px;
            background: rgba(184, 135, 85, 0.28);
            border-bottom: 1px dashed rgba(112, 151, 99, 0.38);
            border-radius: 22px 22px 0 0;
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 0 10px;
        }

        .image-port {
            flex: 1;
            position: relative;
            overflow: hidden;
            display: flex;
            justify-content: center;
            align-items: center;
            background: rgba(0, 0, 0, 0.2);
        }

        #tvScreen {
            position: absolute;
            inset: 0;
            z-index: 15;
            display: flex;
            justify-content: center;
            align-items: center;
            flex-direction: column;
            background: #000;
            overflow: hidden;
            opacity: 1 !important;
            visibility: visible !important;
            cursor: pointer;
            container-type: size;
        }


        .tv-boot-sequence {
            width: 100%;
            height: 100%;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            gap: 1.6cqh;
            padding: 6cqh 6cqw;
            box-sizing: border-box;
            color: #f8fff8;
            font-family: 'Share Tech Mono', 'Zen Kaku Gothic New', monospace;
            text-align: center;
            background:
                radial-gradient(circle at 50% 35%, rgba(0, 243, 255, 0.18), transparent 35%),
                linear-gradient(rgba(255,255,255,0.04) 50%, rgba(0,0,0,0.12) 50%),
                #020605;
            background-size: auto, 100% 0.8cqh, auto;
            position: relative;
            overflow: hidden;
            text-shadow: 0 0 0.9cqh rgba(0, 243, 255, 0.75);
        }

        .tv-boot-sequence::before {
            content: '';
            position: absolute;
            inset: 0;
            pointer-events: none;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.08), transparent);
            transform: translateX(-120%);
            animation: tvScanSweep 3.8s linear infinite;
        }

        .tv-boot-title {
            font-size: clamp(14px, 9cqmin, 34px);
            letter-spacing: 0.12em;
            color: #00f3ff;
            font-weight: 900;
        }

        .tv-boot-subtitle {
            color: #00e676;
            font-size: clamp(10px, 4cqmin, 18px);
            letter-spacing: 0.08em;
        }

        .tv-boot-panel {
            width: min(92%, 86cqw);
            max-height: 68cqh;
            overflow: auto;
            border: 0.55cqh solid #f8fff8;
            border-radius: 1.6cqh;
            background: rgba(0, 0, 0, 0.78);
            box-shadow: inset 0 0 2cqh rgba(0, 243, 255, 0.18), 0 0 2.4cqh rgba(0, 243, 255, 0.35);
            padding: clamp(10px, 4cqh, 22px);
            box-sizing: border-box;
            font-family: 'Zen Kaku Gothic New', 'Share Tech Mono', sans-serif;
            font-size: clamp(13px, 4.2cqmin, 20px);
            line-height: 1.75;
            text-align: left;
            white-space: pre-wrap;
            position: relative;
            z-index: 1;
        }

        .tv-boot-actions {
            display: flex;
            gap: 2cqw;
            justify-content: center;
            flex-wrap: wrap;
            position: relative;
            z-index: 1;
        }

        .tv-boot-button {
            background: #00e676;
            color: #00150a;
            border: 0.35cqh solid #f8fff8;
            border-radius: 999px;
            padding: 1.4cqh 4cqw;
            font-weight: 900;
            font-size: clamp(12px, 3.8cqmin, 18px);
            cursor: pointer;
            box-shadow: 0 0 1.8cqh rgba(0, 230, 118, 0.65);
        }

        .tv-boot-button.tv-boot-next {
            background: linear-gradient(135deg, #00f3ff, #00e676);
            font-size: clamp(16px, 5cqmin, 28px);
            min-width: min(62cqw, 260px);
            animation: disclaimerNextPulse 1.1s ease-in-out infinite;
        }

        .tv-boot-button.is-hidden {
            display: none;
        }

        .tv-boot-hint {
            color: #ffeb3b;
            font-size: clamp(11px, 3.2cqmin, 15px);
            animation: blink 1.2s infinite;
            position: relative;
            z-index: 1;
        }

        @keyframes tvScanSweep {
            100% { transform: translateX(120%); }
        }

        .slide-in {
            animation: slideUp 0.5s ease-out;
        }

        @keyframes slideUp {
            from {
                opacity: 0;
                transform: translateY(20px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .monitor-clock {
            text-align: center;
            color: #fff;
            font-family: 'Share Tech Mono', monospace;
        }

        #mTime {
            font-weight: bold;
            text-shadow: 0 0 15px currentColor;
            margin-bottom: 5px;
        }

        #mDate {
            opacity: 0.7;
            letter-spacing: 2px;
        }

        .blink-text {
            font-size: 10px;
            color: #4c8f63;
            animation: blink 2s infinite;
            margin-top: 10px;
            letter-spacing: 1px;
        }

        @keyframes blink {

            0%,
            100% {
                opacity: 1;
            }

            50% {
                opacity: 0.5;
            }
        }

        .monitor-ad {
            text-align: center;
            border: 2px solid;
            padding: 20px;
            border-radius: 10px;
            max-width: 80%;
            background: rgba(0, 0, 0, 0.7);
        }

        .ad-icon {
            font-size: 40px;
            margin-bottom: 10px;
        }

        .ad-title {
            font-size: 18px;
            font-weight: bold;
            margin-bottom: 10px;
        }

        .ad-text {
            font-size: 12px;
            color: #ccc;
            line-height: 1.5;
            font-family: sans-serif;
        }

        #gameContainer {
            width: 100%;
            height: 100%;
            position: absolute;
            inset: 0;
        }

        .demo-overlay {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            color: #fff;
            text-align: center;
            font-size: 20px;
            text-shadow: 0 0 10px #000;
            pointer-events: none;
            animation: blinkText 1s infinite;
        }

        #imagePreview {
            max-width: 100%;
            max-height: 100%;
            object-fit: contain;
            display: none;
            filter: drop-shadow(0 0 10px rgba(0, 0, 0, 0.5));
            z-index: 5;
        }

        #imageLoadingOverlay {
            position: absolute;
            inset: 0;
            background: rgba(0, 0, 0, 0.8);
            display: none;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            z-index: 20;
            color: #0ff;
            font-size: 10px;
        }

        .loading-spinner {
            width: 30px;
            height: 30px;
            border: 2px solid rgba(0, 243, 255, 0.2);
            border-top: 2px solid var(--neon-cyan);
            border-radius: 50%;
            animation: spin 1s linear infinite;
            margin-bottom: 10px;
        }

        @keyframes spin {
            0% {
                transform: rotate(0deg);
            }

            100% {
                transform: rotate(360deg);
            }
        }

        #imageErrorPlaceholder {
            display: none;
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            width: 80%;
            padding: 20px;
            background: rgba(255, 0, 0, 0.2);
            border: 1px solid red;
            color: red;
            text-align: center;
            backdrop-filter: blur(5px);
            border-radius: 8px;
            font-size: 12px;
            z-index: 20;
        }

        .card-footer {
            height: 30px;
            background: rgba(255, 248, 220, 0.78);
            border-top: 1px dashed rgba(112, 151, 99, 0.38);
            border-radius: 0 0 22px 22px;
            display: flex;
            align-items: center;
            padding: 0 10px;
            font-size: 10px;
            color: var(--neon-cyan);
        }

        .meta-info {
            display: flex;
            justify-content: space-between;
            width: 100%;
        }

        .quick-launch-bar {
            position: fixed;
            bottom: 10px;
            left: 0;
            width: 100%;
            height: 60px;
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 10px;
            z-index: 90;
            pointer-events: none;
            opacity: 0;
            transition: opacity 0.5s;
            padding: 0 10px;
            overflow-x: auto;
        }

        .quick-launch-bar.visible {
            opacity: 1;
            pointer-events: auto;
        }

        .quick-slot {
            width: 48px;
            height: 48px;
            background: rgba(0, 0, 0, 0.6);
            border: 1px solid #444;
            flex-shrink: 0;
            border-radius: 6px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: 0.2s;
            overflow: hidden;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
        }

        .quick-slot:active {
            transform: scale(0.9);
            border-color: var(--neon-cyan);
        }

        .quick-slot img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }

        .action-dock {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 10px;
            width: 100%;
            max-width: 640px;
        }

        .btn-execute {
            width: 220px;
            max-width: 70%;
            padding: 15px;
            border-radius: 50px;
            font-size: 0;
            border: 2px solid rgba(255, 255, 255, 0.2);
            color: #fff;
            cursor: pointer;
            font-family: var(--pixel-font);
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            transition: 0.2s;
        }

        .btn-execute:not([style*="background"]) {
            background: linear-gradient(135deg, #00c6ff, #0072ff);
        }

        .btn-execute:hover {
            transform: scale(1.02);
            filter: brightness(1.2);
        }

        .btn-execute:active {
            transform: scale(0.98);
        }

        .btn-execute span {
            font-size: 16px;
            line-height: 1;
        }

        .btn-execute span:first-child {
            font-size: 20px;
        }

        .deck-btn.btn-menu {
            width: 160px;
            max-width: 60%;
            padding: 12px;
            border-radius: 30px;
            background: rgba(30, 40, 50, 0.8);
            border: 1px solid #555;
            color: #aaa;
            font-size: 0;
            cursor: pointer;
            font-family: var(--pixel-font);
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            transition: 0.2s;
        }

        .deck-btn.btn-menu:hover {
            background: rgba(50, 60, 70, 0.9);
            color: #fff;
            border-color: var(--neon-cyan);
        }

        .deck-btn.btn-menu:active {
            transform: scale(0.98);
        }

        .deck-btn.btn-menu span {
            font-size: 14px;
            line-height: 1;
        }

        .deck-btn.btn-menu span:first-child {
            font-size: 18px;
        }

        #dashboardEmbed {
            display: none;
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.95);
            z-index: 5000;
            backdrop-filter: blur(5px);
        }

        #dashboardEmbedExit {
            position: absolute;
            top: 15px;
            right: 15px;
            color: #fff;
            font-size: 30px;
            padding: 10px;
            cursor: pointer;
            z-index: 5001;
            font-family: sans-serif !important;
            font-weight: bold;
        }

        #dashboardEmbedFrame {
            width: 100%;
            height: 100%;
            border: none;
        }

        .side-dock {
            position: fixed;
            top: 50%;
            right: 0;
            transform: translateY(-50%) translateX(0);
            display: flex;
            flex-direction: column;
            gap: 15px;
            padding: 20px 10px 20px 20px;
            background: rgba(0, 0, 0, 0.6);
            backdrop-filter: blur(10px);
            border-radius: 20px 0 0 20px;
            border: 1px solid rgba(255, 255, 255, 0.1);
            border-right: none;
            transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s;
            z-index: 20000;
        }

        .side-dock.dock-hidden {
            transform: translateY(-50%) translateX(100%);
            opacity: 0;
            pointer-events: none;
        }

        .side-dock-trigger {
            position: fixed;
            top: 50%;
            right: 0;
            transform: translateY(-50%) translateX(100%);
            width: 8px;
            height: 80px;
            background: #00f3ff;
            box-shadow: 0 0 10px #00f3ff, 0 0 20px #00f3ff, inset 0 0 5px #fff;
            border-radius: 5px 0 0 5px;
            cursor: pointer;
            z-index: 20001;
            transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s, box-shadow 0.2s, background 0.2s;
            opacity: 0;
            pointer-events: none;
        }

        .side-dock-trigger.trigger-visible {
            transform: translateY(-50%) translateX(0);
            opacity: 1;
            pointer-events: auto;
        }

        .side-dock-trigger:hover {
            box-shadow: 0 0 15px #00f3ff, 0 0 30px #00f3ff, inset 0 0 8px #fff;
            background: #affbff;
        }

        /* --- Left Side Dock --- */
        .left-side-dock {
            position: fixed;
            top: 50%;
            left: 0;
            transform: translateY(-50%) translateX(0);
            display: flex;
            flex-direction: column;
            gap: 15px;
            padding: 20px 20px 20px 10px;
            background: rgba(0, 0, 0, 0.6);
            backdrop-filter: blur(10px);
            border-radius: 0 20px 20px 0;
            border: 1px solid rgba(255, 255, 255, 0.1);
            border-left: none;
            transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s;
            z-index: 20000;
        }

        .left-side-dock.dock-hidden {
            transform: translateY(-50%) translateX(-100%);
            opacity: 0;
            pointer-events: none;
        }

        .left-side-dock-trigger {
            position: fixed;
            top: 50%;
            left: 0;
            transform: translateY(-50%) translateX(-100%);
            width: 8px;
            height: 80px;
            background: #ff003c;
            box-shadow: 0 0 10px #ff003c, 0 0 20px #ff003c, inset 0 0 5px #fff;
            border-radius: 0 5px 5px 0;
            cursor: pointer;
            z-index: 20001;
            transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s, box-shadow 0.2s, background 0.2s;
            opacity: 0;
            pointer-events: none;
        }

        .left-side-dock-trigger.trigger-visible {
            transform: translateY(-50%) translateX(0);
            opacity: 1;
            pointer-events: auto;
        }

        .left-side-dock-trigger:hover {
            box-shadow: 0 0 15px #ff003c, 0 0 30px #ff003c, inset 0 0 8px #fff;
            background: #ff4d79;
        }

        .dock-icon-btn {
            width: 44px;
            height: 44px;
            border-radius: 50%;
            background: rgba(255, 255, 255, 0.1);
            border: 1px solid rgba(255, 255, 255, 0.2);
            color: #fff;
            font-size: 20px;
            cursor: pointer;
            display: flex;
            justify-content: center;
            align-items: center;
            transition: 0.2s;
            pointer-events: auto;
        }

        .dock-icon-btn:hover {
            background: var(--neon-cyan);
            color: #000;
            box-shadow: 0 0 15px var(--neon-cyan);
            transform: scale(1.1);
        }

        .left-side-dock .dock-icon-btn:hover {
            background: #ff003c;
            color: #fff;
            box-shadow: 0 0 15px #ff003c;
        }

        .calc-btn {
            background: rgba(20, 25, 30, 0.8);
            border: 1px solid rgba(255,0,60,0.3);
            color: #fff;
            border-radius: 4px;
            font-family: 'Share Tech Mono', monospace;
            font-size: 16px;
            cursor: pointer;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 0;
        }

        .calc-btn:hover {
            background: rgba(255,0,60,0.2);
            border-color: #ff003c;
            box-shadow: 0 0 10px rgba(255,0,60,0.4);
        }

        .calc-btn:active {
            transform: scale(0.95);
        }

        .calc-btn-op {
            color: #ff003c;
            border-color: rgba(255,0,60,0.5);
            background: rgba(255,0,60,0.1);
        }

        .calc-btn-eq {
            background: #ff003c;
            color: #000;
            font-weight: bold;
            box-shadow: 0 0 10px rgba(255,0,60,0.5);
        }

        .calc-btn-eq:hover {
            background: #ff4d79;
            box-shadow: 0 0 15px rgba(255,0,60,0.8);
            border-color: #fff;
        }

        .modal-overlay {
            position: fixed;
            inset: 0;
            width: 100%;
            height: 100%;
            max-width: none;
            max-height: none;
            margin: 0;
            padding: 0;
            border: 0;
            background: rgba(0, 0, 0, 0.8);
            z-index: 21000;
            display: flex;
            justify-content: center;
            align-items: center;
            opacity: 0;
            visibility: hidden;
            transition: 0.3s;
        }

        dialog.modal-overlay:not([open]) {
            display: none;
        }

        dialog.modal-overlay::backdrop {
            background: transparent;
        }

        body.jiminy-critical-top-layer-active #promoOverlay,
        body.jiminy-critical-top-layer-active #fullscreenOverlay,
        body.jiminy-critical-top-layer-active #imageLoadingOverlay,
        body.jiminy-critical-top-layer-active #gateModalOverlay {
            z-index: 1000 !important;
        }

        .modal-overlay.active {
            opacity: 1;
            visibility: visible;
            pointer-events: auto;
        }

        #disclaimerModal.active {
            z-index: 31000;
            overflow: hidden;
        }

        #disclaimerModal.active::before {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 0;
            pointer-events: none;
            background:
                radial-gradient(ellipse at 50% 105%, rgba(100, 205, 116, 0.95) 0 18%, rgba(28, 130, 74, 0.78) 19% 31%, transparent 32%),
                radial-gradient(ellipse at 18% 82%, rgba(102, 199, 160, 0.55) 0 12%, transparent 13%),
                radial-gradient(ellipse at 83% 78%, rgba(102, 199, 160, 0.5) 0 11%, transparent 12%),
                linear-gradient(180deg, rgba(90, 205, 255, 0.2) 0 44%, rgba(0, 32, 42, 0.2) 45% 100%),
                linear-gradient(180deg, #071526, #01050c 62%, #000);
            opacity: 1;
        }

        #disclaimerModal .island-disclaimer-panel {
            position: relative;
            z-index: 1;
        }

        #rpgIntroModal.active {
            z-index: 31001;
        }

        body.jiminy-first-run-lock #executeCodeButton,
        body.jiminy-first-run-lock #toggleButton,
        body.jiminy-first-run-lock .quick-launch-bar,
        body.jiminy-first-run-lock .left-side-dock,
        body.jiminy-first-run-lock .side-dock-trigger,
        body.jiminy-first-run-lock .panel-deco-icon {
            pointer-events: none !important;
            filter: grayscale(0.8) brightness(0.58);
        }

        body.jiminy-first-run-lock #tvScreen {
            position: absolute;
            inset: 0;
            z-index: 32000;
            pointer-events: auto;
        }

        body.jiminy-first-run-lock #disclaimerModal.active,
        body.jiminy-first-run-lock #rpgIntroModal.active {
            z-index: 33000;
            pointer-events: auto;
        }

        #settings-modal {
            padding: max(16px, env(safe-area-inset-top)) 16px max(16px, env(safe-area-inset-bottom));
            box-sizing: border-box;
            align-items: flex-start;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }

        #settings-modal .settings-panel {
            max-height: calc(100dvh - 32px);
            overflow-y: auto;
            overscroll-behavior: contain;
        }

        @keyframes rpg-blink {
            0%, 100% { opacity: 1; }
            50% { opacity: 0; }
        }

        @keyframes float-indicator {
            0% { transform: translateY(0px); box-shadow: 0 0 5px #0f0; }
            50% { transform: translateY(-3px); box-shadow: 0 0 15px #0f0; }
            100% { transform: translateY(0px); box-shadow: 0 0 5px #0f0; }
        }

        .settings-panel {
            width: 90%;
            max-width: 500px;
            background: rgba(10, 15, 20, 0.95);
            border: 1px solid var(--neon-cyan);
            padding: 25px;
            border-radius: 12px;
            color: #eee;
            font-family: sans-serif;
        }

        .close-button-common {
            width: 100%;
            padding: 10px;
            margin-top: 20px;
            background: #444;
            border: none;
            color: #fff;
            cursor: pointer;
            border-radius: 4px;
        }

        .config-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 12px;
            font-size: 14px;
            color: #ccc;
            border-bottom: 1px solid #333;
            padding-bottom: 8px;
        }

        .toggle-switch {
            position: relative;
            width: 40px;
            height: 20px;
        }

        .toggle-switch input {
            opacity: 0;
            width: 0;
            height: 0;
        }

        .slider {
            position: absolute;
            cursor: pointer;
            inset: 0;
            background-color: #444;
            transition: .4s;
            border-radius: 20px;
        }

        .slider:before {
            position: absolute;
            content: "";
            height: 16px;
            width: 16px;
            left: 2px;
            bottom: 2px;
            background-color: white;
            transition: .4s;
            border-radius: 50%;
        }

        input:checked+.slider {
            background-color: var(--neon-cyan);
        }

        input:checked+.slider:before {
            transform: translateX(20px);
        }

        #seedInputArea {
            position: fixed;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            background: rgba(0, 0, 0, 0.95);
            border: 1px solid var(--neon-cyan);
            box-shadow: 0 0 20px rgba(0, 243, 255, 0.3);
            padding: 25px;
            z-index: 25000;
            display: none;
            text-align: center;
            border-radius: 12px;
            width: 320px;
        }

        /* Seed Input UI */
        #seedInputContainer {
            margin: 20px 0;
            position: relative;
        }

        #seedModalInput {
            width: 100%;
            padding: 15px;
            background: rgba(0, 0, 0, 0.5) !important;
            border: 2px solid #444 !important;
            color: var(--neon-cyan) !important;
            text-align: center;
            font-size: 24px;
            font-family: var(--pixel-font);
            border-radius: 8px;
            outline: none;
            transition: all 0.3s ease;
            box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.8);
            letter-spacing: 5px;
            text-transform: uppercase;
        }

        #seedModalInput:focus {
            border-color: var(--neon-cyan) !important;
            box-shadow: inset 0 0 15px rgba(0, 243, 255, 0.2), 0 0 15px rgba(0, 243, 255, 0.4);
            animation: pulseGlow 1.5s infinite alternate;
        }

        @keyframes pulseGlow {
            0% { box-shadow: inset 0 0 10px rgba(0, 243, 255, 0.2); }
            100% { box-shadow: inset 0 0 20px rgba(0, 243, 255, 0.6), 0 0 10px rgba(0, 243, 255, 0.4); }
        }

        #seedModalInput::placeholder {
            color: rgba(0, 243, 255, 0.2);
            font-size: 16px;
            letter-spacing: 2px;
            animation: blinkPlaceholder 2s infinite;
        }

        @keyframes blinkPlaceholder {
            0%, 100% { opacity: 1; }
            50% { opacity: 0.3; }
        }

        .shake-error {
            animation: shake 0.5s cubic-bezier(.36,.07,.19,.97) both;
        }

        @keyframes shake {
            10%, 90% { transform: translate3d(-1px, 0, 0); }
            20%, 80% { transform: translate3d(2px, 0, 0); }
            30%, 50%, 70% { transform: translate3d(-4px, 0, 0); }
            40%, 60% { transform: translate3d(4px, 0, 0); }
        }

        .success-flash {
            animation: successFlash 1s ease-out forwards;
        }

        @keyframes successFlash {
            0% { background: rgba(0, 255, 0, 0.5); box-shadow: 0 0 30px #0f0; border-color: #0f0; }
            100% { background: rgba(0, 0, 0, 0.95); box-shadow: 0 0 20px rgba(0, 243, 255, 0.3); border-color: var(--neon-cyan); }
        }

        .seed-btn-group {
            display: flex;
            gap: 10px;
            margin-top: 15px;
        }

        .seed-btn {
            flex: 1;
            padding: 12px 0;
            height: auto;
            min-height: 44px;
            border: none;
            border-radius: 4px;
            font-family: var(--pixel-font);
            font-size: 12px;
            color: #fff;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: 0.2s;
        }

        .seed-btn-ok {
            background: linear-gradient(135deg, #00c6ff, #0072ff);
            box-shadow: 0 0 10px rgba(0, 198, 255, 0.5);
        }

        .seed-btn-ok:hover { filter: brightness(1.2); }

        .seed-btn-cancel {
            background: #444;
            border: 1px solid #666;
        }

        .seed-btn-cancel:hover { background: #555; }

        #seedModeToggleBtn {
            margin-top: 15px;
            background: transparent;
            border: none;
            color: #aaa;
            font-size: 11px;
            cursor: pointer;
            text-decoration: underline;
            display: none;
        }

        #fullscreenOverlay {
            display: none;
            position: fixed;
            inset: 0;
            background: #000;
            z-index: 10000;
            flex-direction: column;
        }

        #iframeContainer {
            flex: 1;
            width: 100%;
            position: relative;
        }

        #popupFrame {
            width: 100%;
            height: 100%;
            border: none;
        }

        #exitBar {
            height: 40px;
            background: #111;
            display: flex;
            border-bottom: 1px solid #333;
        }

        .exitSegment {
            flex: 1;
            display: flex;
            justify-content: center;
            align-items: center;
            color: #aaa;
            cursor: pointer;
            font-size: 10px;
        }

        #segExit {
            color: #ff5f56;
        }

        #customModalOverlay {
            display: none;
            position: fixed;
            inset: 0;
            z-index: 99999;
            justify-content: center;
            align-items: center;
            background: rgba(0, 0, 0, 0.8);
            backdrop-filter: blur(4px);
        }

        #customModalContent {
            background: rgba(20, 25, 30, 0.95);
            border: 1px solid var(--neon-cyan);
            color: #fff;
            padding: 20px;
            border-radius: 12px;
            text-align: center;
            max-width: 85%;
            width: 300px;
            font-size: 14px;
        }

        .small-control-button {
            border-radius: 4px;
            padding: 8px 20px;
            font-family: var(--pixel-font);
            border: none;
            color: white;
            cursor: pointer;
            margin: 0 5px;
            font-size: 12px;
        }


        @keyframes islandDrift {
            0% { transform: perspective(500px) rotateX(58deg) translate3d(-12px, -8px, 0); }
            100% { transform: perspective(500px) rotateX(58deg) translate3d(16px, 10px, 0); }
        }

        @keyframes sparkleFloat {
            0% { background-position: 0 0, 0 0; }
            100% { background-position: 30px -24px, -45px 36px; }
        }

        @keyframes islandFloat {
            0%, 100% { transform: translateY(0) rotate(-0.4deg); }
            50% { transform: translateY(-8px) rotate(0.4deg); }
        }

        @keyframes leafPopIn {
            0% { opacity: 0; transform: translateY(18px) scale(0.96); }
            60% { opacity: 1; transform: translateY(-4px) scale(1.02); }
            100% { opacity: 1; transform: translateY(0) scale(1); }
        }

        @keyframes islandButtonBounce {
            0%, 100% { transform: translateY(0) scale(1); }
            50% { transform: translateY(-3px) scale(1.015); }
        }

        .side-dock,
        .left-side-dock {
            background: rgba(255, 248, 220, 0.82);
            border-color: rgba(112, 151, 99, 0.28);
            box-shadow: 0 10px 24px rgba(105, 127, 83, 0.18);
        }

        .dock-icon-btn,
        .quick-slot,
        .deck-btn.btn-menu,
        .btn-execute {
            border-radius: 999px;
            box-shadow: 0 5px 0 rgba(119, 91, 55, 0.2), 0 12px 20px rgba(105, 127, 83, 0.18);
        }

        .dock-icon-btn {
            background: #fff8dc;
            border-color: rgba(102, 199, 160, 0.45);
            color: #4c8f63;
        }

        .dock-icon-btn:hover,
        .left-side-dock .dock-icon-btn:hover {
            background: var(--island-leaf);
            color: #fff8dc;
            box-shadow: 0 7px 0 rgba(76, 143, 99, 0.24), 0 16px 24px rgba(105, 127, 83, 0.24);
        }

        .btn-execute:not([style*="background"]) {
            background: linear-gradient(135deg, var(--island-leaf), var(--island-mint));
        }

        .btn-execute:hover,
        .deck-btn.btn-menu:hover,
        .dock-icon-btn:hover {
            animation: islandButtonBounce 0.65s ease-in-out infinite;
            filter: none;
        }

        .deck-btn.btn-menu {
            background: rgba(255, 248, 220, 0.88);
            border-color: rgba(184, 135, 85, 0.45);
            color: #6c5a2f;
        }

        .deck-btn.btn-menu:hover {
            background: #f7e7b7;
            color: #4c8f63;
            border-color: var(--island-leaf);
        }

        #disclaimerModal.active .settings-panel,
        #welcomeHelpModal.active .settings-panel,
        #settings-modal.active .settings-panel,
        #newsContainer.active .settings-panel {
            animation: leafPopIn 0.52s cubic-bezier(0.2, 0.9, 0.25, 1.15) both;
        }

        .island-disclaimer-panel {
            background:
                radial-gradient(circle at 12% 10%, rgba(255,255,255,0.7) 0 8%, transparent 18%),
                linear-gradient(180deg, rgba(255, 248, 220, 0.98), rgba(247, 231, 183, 0.96)) !important;
            border: 3px solid rgba(102, 199, 160, 0.7) !important;
            border-radius: 28px !important;
            box-shadow: 0 16px 0 rgba(184, 135, 85, 0.18), 0 26px 42px rgba(105, 127, 83, 0.26) !important;
            color: #4b4428 !important;
        }

        .settings-panel {
            background: rgba(255, 248, 220, 0.92);
            border-color: rgba(102, 199, 160, 0.65);
            border-radius: 24px;
            color: #4b4428;
            box-shadow: 0 16px 34px rgba(105, 127, 83, 0.24);
        }

        .settings-panel h2,
        .island-disclaimer-panel h2 {
            color: #4c8f63 !important;
            text-shadow: 0 2px 0 rgba(255, 255, 255, 0.85) !important;
        }

        .close-button-common {
            background: linear-gradient(135deg, var(--island-leaf), var(--island-mint)) !important;
            color: #fff8dc !important;
            border-radius: 999px !important;
            box-shadow: 0 6px 0 rgba(76, 143, 99, 0.65), 0 14px 22px rgba(105, 127, 83, 0.22) !important;
        }


        .island-note {
            color: #4b4428 !important;
            background: rgba(255, 255, 255, 0.54) !important;
            border-left: 6px solid var(--island-leaf) !important;
            border-radius: 18px !important;
            box-shadow: inset 0 0 0 1px rgba(102, 199, 160, 0.18);
        }

        .island-warning {
            background: rgba(255, 159, 128, 0.16) !important;
            border: 2px dashed rgba(184, 135, 85, 0.7) !important;
            border-radius: 18px !important;
            color: #6c4f2b !important;
        }

        .island-start-button {
            background: linear-gradient(135deg, var(--island-leaf), var(--island-mint)) !important;
            color: #fff8dc !important;
            border: 3px solid rgba(255,255,255,0.75) !important;
            box-shadow: 0 7px 0 #4c8f63, 0 15px 24px rgba(105, 127, 83, 0.28) !important;
            transition: transform 0.18s ease, box-shadow 0.18s ease !important;
        }

        .island-start-button:hover {
            transform: translateY(-3px) scale(1.02);
            box-shadow: 0 10px 0 #4c8f63, 0 18px 28px rgba(105, 127, 83, 0.32) !important;
        }

        .island-start-button:active {
            transform: translateY(3px) scale(0.99);
            box-shadow: 0 3px 0 #4c8f63, 0 9px 16px rgba(105, 127, 83, 0.24) !important;
        }

        .disclaimer-scroll-next {
            width: min(220px, 78%);
            margin: 12px auto 6px;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            background: linear-gradient(135deg, #00f3ff, #00e676);
            color: #08351f;
            border: 3px solid rgba(255,255,255,0.86);
            border-radius: 999px;
            padding: 12px 18px;
            font-size: 18px;
            font-weight: 900;
            cursor: pointer;
            box-shadow: 0 8px 0 rgba(76, 143, 99, 0.72), 0 16px 24px rgba(105, 127, 83, 0.28);
            animation: disclaimerNextPulse 1.1s ease-in-out infinite;
        }

        .disclaimer-scroll-next .arrow {
            font-size: 30px;
            line-height: 0.8;
        }

        .disclaimer-scroll-next.is-hidden,
        .disclaimer-start-area.is-hidden {
            display: none !important;
        }

        .disclaimer-start-area {
            animation: leafPopIn 0.4s cubic-bezier(0.2, 0.9, 0.25, 1.15) both;
        }

        .catalog-action-modal {
            position: fixed;
            inset: 0;
            z-index: 16000;
            display: none;
            align-items: center;
            justify-content: center;
            padding: 18px;
            background: rgba(0, 0, 0, 0.72);
            backdrop-filter: blur(6px);
        }

        .catalog-action-modal.active {
            display: flex;
        }

        .catalog-action-panel {
            width: min(420px, 94vw);
            background:
                radial-gradient(circle at 12% 10%, rgba(255,255,255,0.8) 0 8%, transparent 18%),
                linear-gradient(180deg, rgba(255, 248, 220, 0.98), rgba(247, 231, 183, 0.96));
            border: 3px solid rgba(102, 199, 160, 0.75);
            border-radius: 26px;
            box-shadow: 0 16px 0 rgba(184, 135, 85, 0.18), 0 28px 50px rgba(0,0,0,0.32);
            color: #4b4428;
            padding: 18px;
            text-align: center;
            font-family: 'Zen Kaku Gothic New', sans-serif;
        }

        .catalog-action-thumb {
            width: 100%;
            height: 180px;
            border-radius: 18px;
            border: 2px solid rgba(76, 143, 99, 0.36);
            object-fit: contain;
            background: rgba(255,255,255,0.56);
            margin-bottom: 12px;
        }

        .catalog-action-buttons {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            margin-top: 16px;
        }

        .catalog-action-buttons button {
            border: 0;
            border-radius: 999px;
            padding: 12px 10px;
            font-weight: 900;
            cursor: pointer;
            box-shadow: 0 6px 0 rgba(76, 143, 99, 0.55);
        }

        .catalog-register-btn {
            background: #fff8dc;
            color: #4c8f63;
            border: 2px solid rgba(76, 143, 99, 0.38) !important;
        }

        .catalog-primary-btn {
            background: linear-gradient(135deg, #00e676, #00f3ff);
            color: #08351f;
            border: 2px solid rgba(255,255,255,0.85) !important;
        }

        @keyframes disclaimerNextPulse {
            0%, 100% { transform: translateY(0); }
            50% { transform: translateY(5px); }
        }

        @keyframes questBackgroundLines {
            from { transform: translateY(0); }
            to { transform: translateY(42px); }
        }



        /* Quest-style onboarding: keep disclaimer/help visually connected to the RPG opening. */
        #disclaimerModal .island-disclaimer-panel,
        #welcomeHelpModal .settings-panel {
            position: relative;
            isolation: isolate;
            overflow: hidden;
            background:
                repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.035) 0 2px, transparent 2px 7px),
                linear-gradient(180deg, rgba(0, 0, 0, 0.98), rgba(1, 5, 8, 0.98) 58%, rgba(0, 0, 0, 0.99)) !important;
            background-size: 100% 9px, 100% 100% !important;
            border: 4px solid rgba(255, 255, 255, 0.96) !important;
            border-radius: 14px !important;
            color: #fff !important;
            box-shadow:
                0 0 0 2px rgba(0, 243, 255, 0.5),
                0 0 0 8px rgba(0, 0, 0, 0.76),
                0 24px 70px rgba(0, 0, 0, 0.72),
                0 0 32px rgba(0, 243, 255, 0.26),
                inset 0 0 28px rgba(0, 243, 255, 0.08) !important;
            font-family: 'Zen Kaku Gothic New', 'Press Start 2P', sans-serif !important;
        }

        #disclaimerModal .island-disclaimer-panel::after,
        #welcomeHelpModal .settings-panel::after {
            content: "";
            position: absolute;
            inset: 10px;
            z-index: -1;
            pointer-events: none;
            border-radius: 14px;
            background:
                linear-gradient(rgba(0, 243, 255, 0.055) 1px, transparent 1px),
                linear-gradient(90deg, rgba(0, 243, 255, 0.035) 1px, transparent 1px),
                radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.09), transparent 35%);
            background-size: 22px 22px, 22px 22px, 100% 100%;
            border: 1px solid rgba(0, 243, 255, 0.18);
            opacity: 0.9;
        }

        #disclaimerModal .island-disclaimer-panel::before,
        #welcomeHelpModal .settings-panel::before {
            content: 'JIMI忍 QUEST';
            display: block;
            width: fit-content;
            padding: 6px 12px;
            color: #001015;
            background: linear-gradient(135deg, #00f3ff, #00e676);
            border: 2px solid rgba(255, 255, 255, 0.9);
            border-radius: 999px;
            font-family: 'Share Tech Mono', 'Press Start 2P', monospace;
            font-size: 12px;
            font-weight: 900;
            letter-spacing: 0.16em;
            margin-bottom: 14px;
            text-align: left;
            box-shadow: 0 0 18px rgba(0, 243, 255, 0.48), 0 7px 0 rgba(0, 0, 0, 0.32);
        }

        #disclaimerModal .jiminin-mascot-card,
        #welcomeHelpModal .jiminin-mascot-card {
            position: relative;
            align-items: center;
            gap: 18px;
            overflow: visible;
            min-height: 150px;
            margin: 6px 0 22px !important;
            padding: 16px 18px 16px clamp(130px, 28vw, 188px) !important;
            background: linear-gradient(135deg, rgba(0, 20, 30, 0.9), rgba(0, 40, 30, 0.8)) !important;
            border: 2px solid rgba(0, 230, 118, 0.6) !important;
            border-radius: 18px !important;
            box-shadow:
                inset 0 0 22px rgba(0, 243, 255, 0.1),
                0 0 0 2px rgba(0, 230, 118, 0.2),
                0 18px 34px rgba(0, 0, 0, 0.5) !important;
        }

        #disclaimerModal .jiminin-mascot-card::before,
        #welcomeHelpModal .jiminin-mascot-card::before {
            content: "";
            position: absolute;
            left: 18px;
            top: 50%;
            width: clamp(94px, 22vw, 138px);
            height: clamp(94px, 22vw, 138px);
            transform: translateY(-50%);
            border-radius: 999px;
            background:
                radial-gradient(circle, rgba(255, 255, 255, 0.92), rgba(0, 243, 255, 0.2) 58%, transparent 70%);
            filter: blur(0.2px);
            box-shadow: 0 0 28px rgba(0, 243, 255, 0.38), inset 0 0 22px rgba(255, 255, 255, 0.38);
        }

        #disclaimerModal .jiminin-mascot-card img,
        #welcomeHelpModal .jiminin-mascot-card img {
            position: absolute;
            left: 4px;
            bottom: -8px;
            z-index: 1;
            width: clamp(126px, 30vw, 178px) !important;
            max-height: 190px;
            object-fit: contain;
            transform: rotate(-3deg);
            filter:
                drop-shadow(0 12px 12px rgba(0, 0, 0, 0.42))
                drop-shadow(0 0 20px rgba(0, 243, 255, 0.42)) !important;
            animation: jimininMascotPop 0.7s cubic-bezier(.2, 1.4, .35, 1) both, jimininMascotFloat 3.2s ease-in-out 0.75s infinite;
        }

        #disclaimerModal .jiminin-mascot-card strong,
        #welcomeHelpModal .jiminin-mascot-card strong,
        #disclaimerModal .island-disclaimer-panel h2,
        #welcomeHelpModal #welcomeHelpTitle {
            color: #9cffd3 !important;
            text-shadow: 0 0 10px rgba(0, 230, 118, 0.72), 0 2px 0 rgba(0, 0, 0, 0.55) !important;
        }

        #disclaimerModal .jiminin-mascot-card strong,
        #welcomeHelpModal .jiminin-mascot-card strong {
            font-size: clamp(16px, 3.3vw, 20px) !important;
        }

        #disclaimerModal .jiminin-mascot-card span,
        #welcomeHelpModal .jiminin-mascot-card span,
        #disclaimerModal .island-disclaimer-panel p,
        #disclaimerModal .island-disclaimer-panel div,
        #welcomeHelpModal .settings-panel p,
        #welcomeHelpModal .settings-panel li {
            color: rgba(255, 255, 255, 0.96) !important;
            font-family: 'Zen Kaku Gothic New', sans-serif !important;
        }

        #disclaimerModal .island-disclaimer-panel > p,
        #disclaimerModal .island-disclaimer-panel > h3,
        #disclaimerModal .island-disclaimer-panel > ul {
            background: rgba(0, 0, 0, 0.6);
            padding: 8px 12px;
            border-radius: 8px;
            box-shadow: inset 0 0 0 1px rgba(0, 243, 255, 0.1);
        }

        #disclaimerModal .island-note,
        #disclaimerModal .island-warning {
            background: rgba(0, 243, 255, 0.1) !important;
            border: 2px solid rgba(0, 243, 255, 0.65) !important;
            border-left: 6px solid #00e676 !important;
            border-radius: 12px !important;
            color: #fff !important;
            box-shadow: inset 0 0 20px rgba(0, 243, 255, 0.1), 0 10px 22px rgba(0, 0, 0, 0.22) !important;
        }

        #welcomeHelpModal .settings-panel h3 {
            color: #00e676 !important;
            border-bottom-color: rgba(255, 255, 255, 0.65) !important;
            text-shadow: 0 0 8px rgba(0, 230, 118, 0.55) !important;
        }

        #disclaimerModal .disclaimer-scroll-next,
        #disclaimerModal .island-start-button,
        #welcomeHelpModal .close-button-common {
            background: linear-gradient(135deg, #001015, #032a23) !important;
            color: #baffdf !important;
            border: 3px solid #fff !important;
            border-radius: 12px !important;
            box-shadow: 0 0 0 2px rgba(0, 230, 118, 0.55), 0 0 18px rgba(0, 230, 118, 0.38), 0 9px 0 rgba(0,0,0,0.38) !important;
            font-family: 'Zen Kaku Gothic New', 'Press Start 2P', sans-serif !important;
        }

        @keyframes jimininMascotPop {
            from { opacity: 0; transform: translateY(16px) scale(0.82) rotate(-8deg); }
            to { opacity: 1; transform: translateY(0) scale(1) rotate(-3deg); }
        }

        @keyframes jimininMascotFloat {
            0%, 100% { transform: translateY(0) rotate(-3deg); }
            50% { transform: translateY(-7px) rotate(2deg); }
        }

        @media (max-width: 560px) {
            #disclaimerModal .jiminin-mascot-card,
            #welcomeHelpModal .jiminin-mascot-card {
                min-height: 0;
                padding: 138px 14px 14px !important;
                text-align: center;
            }

            #disclaimerModal .jiminin-mascot-card::before,
            #welcomeHelpModal .jiminin-mascot-card::before {
                left: 50%;
                top: 14px;
                transform: translateX(-50%);
            }

            #disclaimerModal .jiminin-mascot-card img,
            #welcomeHelpModal .jiminin-mascot-card img {
                left: 50%;
                bottom: auto;
                top: -2px;
                transform: translateX(-50%) rotate(-3deg);
                width: 150px !important;
                animation: none;
            }
        }

        /* Keep the post-disclaimer RPG intro independent from the active main skin. */
        #rpgIntroModal {
            background: #000 !important;
            backdrop-filter: none !important;
        }

        #rpgIntroModal.active::before {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 0;
            pointer-events: none;
            background:
                radial-gradient(ellipse at 50% 105%, rgba(100, 205, 116, 0.95) 0 18%, rgba(28, 130, 74, 0.78) 19% 31%, transparent 32%),
                radial-gradient(ellipse at 18% 82%, rgba(102, 199, 160, 0.55) 0 12%, transparent 13%),
                radial-gradient(ellipse at 83% 78%, rgba(102, 199, 160, 0.5) 0 11%, transparent 12%),
                linear-gradient(180deg, rgba(90, 205, 255, 0.2) 0 44%, rgba(0, 32, 42, 0.2) 45% 100%),
                linear-gradient(180deg, #071526, #01050c 62%, #000);
            opacity: 1;
        }

        #rpgIntroModal #rpgTextBox {
            background: rgba(10, 15, 20, 0.95) !important;
            border: 1px solid var(--neon-cyan) !important;
            border-radius: 12px !important;
            color: rgba(255, 255, 255, 0.96) !important;
            box-shadow:
                0 0 32px rgba(0, 243, 255, 0.26),
                inset 0 0 28px rgba(0, 243, 255, 0.08) !important;
            animation: islandFloat 4.8s ease-in-out infinite !important;
            position: relative;
            z-index: 1;
        }

        #rpgIntroModal #rpgTextBox::before {
            content: 'JIMI忍 QUEST';
            display: block;
            width: fit-content;
            padding: 6px 12px;
            background: linear-gradient(135deg, rgba(0, 243, 255, 0.15), rgba(0, 230, 118, 0.15));
            border: 1px solid rgba(0, 243, 255, 0.4);
            border-radius: 8px;
            color: #fff;
            font-size: 11px;
            letter-spacing: 0.1em;
            margin-bottom: 14px;
            text-align: left;
            box-shadow: 0 0 18px rgba(0, 243, 255, 0.48), 0 7px 0 rgba(0, 0, 0, 0.32);
        }

        #rpgIntroModal #rpgTextBox::after {
            content: "";
            position: absolute;
            inset: 10px;
            z-index: -1;
            background-image:
                linear-gradient(rgba(0, 243, 255, 0.06) 1px, transparent 1px),
                linear-gradient(90deg, rgba(0, 243, 255, 0.06) 1px, transparent 1px),
                radial-gradient(circle at center, rgba(0, 230, 118, 0.08) 0%, transparent 60%);
            background-size: 22px 22px, 22px 22px, 100% 100%;
            border: 1px solid rgba(0, 243, 255, 0.18);
            opacity: 0.9;
        }

        #rpgIntroModal #rpgTextContent {
            position: relative;
            z-index: 1;
            background: rgba(0, 0, 0, 0.4);
            border-radius: 8px;
            padding: clamp(10px, 2vw, 16px);
            box-shadow: inset 0 0 0 1px rgba(0, 243, 255, 0.1);
        }

        #rpgIntroModal #rpgCursor {
            color: var(--neon-cyan) !important;
            text-shadow: 0 0 8px rgba(0, 243, 255, 0.8);
        }

        @media (max-width: 768px) {
            .cyber-panel {
                display: none;
            }

            .console-stage {
                left: 0;
                right: 0;
            }

            .cassette-card {
                width: 92%;
                height: 45vh;
            }

            .news-ticker-container {
                display: none;
            }

            .quick-launch-bar {
                bottom: 10px;
            }

            @media (orientation: landscape) {
                .console-stage {
                    top: 10px;
                    bottom: 80px;
                }

                .cassette-card {
                    height: 70vh;
                }

                .quick-launch-bar {
                    bottom: 10px;
                    right: 10px;
                    left: auto;
                    width: auto;
                    flex-direction: column;
                    height: auto;
                }
            }
        }
