/* === CORE VARIABLES & THEMING === */
:root {
    --bg-main: #ffffff;
    --text-main: #050505;
    --accent-orange: #ff6600; 
    --accent-green: #00aa44;
    --void-bg: #f4f4f9; 
    --box-bg: rgba(255, 102, 0, 0.05);

    --brand-primary: var(--accent-orange);
    --brand-secondary: var(--text-main);
    --brand-accent: var(--accent-green);
    --brand-bg: var(--bg-main);
    --brand-surface: var(--void-bg);

    --logo-filter-on-bg: brightness(0);
    --logo-filter-on-text: brightness(0) invert(1);
    --logo-filter-on-surface: brightness(0);
    --btn-on-primary: #050505;
    
    --auto-bg: linear-gradient(135deg, rgba(255, 248, 240, 0.95), rgba(255, 255, 255, 0.98));
    --auto-border: rgba(255, 102, 0, 0.3);
    --auto-text: #1a1a2e;
    
    --grid-color: rgba(0, 0, 0, 0.04);
    --scanline-color: rgba(0, 0, 0, 0.03);

    --float-block-bg: rgba(0, 0, 0, 0.06);
    --float-block-border: rgba(0, 0, 0, 0.12);
    --float-block-opacity: 0.08;
    --float-block-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

/* Default marketing palette — html.dark-theme set early by theme-early.js */
html.dark-theme:not(.brand-active),
body.dark-theme:not(.brand-active) {
    --bg-main: #050505;
    --text-main: #f0f0f0;
    --accent-orange: #ff8800; 
    --accent-green: #00ff66;
    --void-bg: #0a0a0a;
    --box-bg: rgba(255, 136, 0, 0.08);

    --brand-bg: var(--bg-main);
    --brand-surface: #141414;

    --auto-bg: linear-gradient(135deg, rgba(20, 15, 10, 0.95), rgba(10, 5, 5, 0.98));
    --auto-border: rgba(255, 136, 0, 0.3);
    --auto-text: #ffffff;

    --grid-color: rgba(255, 136, 0, 0.05);
    --scanline-color: rgba(255, 136, 0, 0.03);

    --float-block-bg: rgba(255, 136, 0, 0.12);
    --float-block-border: rgba(255, 255, 255, 0.08);
    --float-block-opacity: 0.28;
    --float-block-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);

    --logo-filter-on-bg: brightness(0) invert(1);
    --logo-filter-on-text: brightness(0);
    --logo-filter-on-surface: brightness(0) invert(1);
}

/* Logos: white PNG → black on light surfaces, white on dark surfaces */
.brand-logo,
[data-brand-logo],
.setup-logo,
.app-shell-header .header-logo img,
.login-logo {
    filter: var(--logo-filter-on-surface, var(--logo-filter-on-bg));
    transition: filter 0.35s ease;
}

.brand-logo-tenant,
[data-brand-logo].brand-logo-tenant,
.app-shell-header .header-logo img.brand-logo-tenant {
    filter: none !important;
}

.corner-banner-top img {
    filter: var(--logo-filter-on-text);
    transition: filter 0.35s ease;
}
.preview-mock-logo {
    filter: var(--logo-filter-on-surface);
    transition: filter 0.35s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-main); 
    color: var(--text-main);
    overflow-x: hidden;
    transition: background-color 0.3s, color 0.3s;
}

/* === HOLOGRAPHIC TEXTURES === */
body::before {
    content: ""; position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    background: linear-gradient(var(--grid-color) 1px, transparent 1px), linear-gradient(90deg, var(--grid-color) 1px, transparent 1px);
    background-size: 40px 40px; z-index: 0; pointer-events: none; transition: background 0.3s;
}

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-main); }
::-webkit-scrollbar-thumb { background: var(--accent-orange); }

/* === THEME TOGGLE === */
.theme-toggle {
    position: fixed; top: 20px; left: 20px; z-index: 1000;
    background: var(--bg-main); border: 2px solid var(--text-main);
    color: var(--text-main); padding: 10px 20px; font-weight: bold;
    text-transform: uppercase; cursor: pointer; transition: all 0.3s ease;
    font-size: clamp(0.7rem, 1.5vw, 1rem); /* Fluid scaling */
}
.theme-toggle:hover { background: var(--text-main); color: var(--bg-main); }

/* === HERO SECTION === */
.hero {
    position: relative; height: 100vh; display: flex; flex-direction: column;
    justify-content: center; align-items: center; text-align: center;
    background: transparent; z-index: 10; overflow: hidden; padding: 0 20px;
}

.corner-banner-top {
    position: absolute; top: -220px; right: -10px; width: 200px; height: 1000px;
    background: var(--text-main); transform: rotate(-29deg);
    z-index: 20; transition: background-color 0.3s;
}
.corner-banner-top img {
    position: absolute; bottom: 45%; left: 45%; transform: translateX(-50%) rotate(-57deg) rotate(57deg);
    width: 200%;
}
.corner-banner-left {
    position: absolute; bottom: -150px; left: -150px; width: 400px; height: 400px;
    background: var(--text-main); transform: rotate(35deg); z-index: 20; transition: background-color 0.3s;
}

/* === HERO FLOATING BLOCKS === */
.hero-floats {
    position: absolute; inset: 0; overflow: hidden; z-index: 1; pointer-events: none;
}
.float-block {
    position: absolute;
    border: 1px solid var(--float-block-border, rgba(0, 0, 0, 0.12));
    background: var(--float-block-bg, rgba(0, 0, 0, 0.06));
    box-shadow: var(--float-block-shadow, 0 8px 24px rgba(0, 0, 0, 0.06));
    opacity: var(--float-block-opacity, 0.08);
    animation: float-drift 18s ease-in-out infinite;
    transition: background 0.35s ease, border-color 0.35s ease, opacity 0.35s ease, box-shadow 0.35s ease;
}
html.dark-theme .float-block,
body.dark-theme .float-block {
    opacity: var(--float-block-opacity, 0.28);
}
.float-block.b1 { width: 72px; height: 72px; top: 12%; left: 8%; animation-duration: 16s; transform: rotate(18deg); }
.float-block.b2 { width: 110px; height: 48px; top: 22%; right: 12%; animation-duration: 19s; animation-delay: -4s; transform: rotate(-12deg); }
.float-block.b3 { width: 56px; height: 96px; bottom: 28%; left: 14%; animation-duration: 13s; animation-delay: -7s; transform: rotate(32deg); }
.float-block.b4 { width: 88px; height: 88px; bottom: 18%; right: 18%; animation-duration: 21s; animation-delay: -2s; transform: rotate(-24deg); }
.float-block.b5 { width: 40px; height: 40px; top: 48%; left: 4%; animation-duration: 11s; animation-delay: -9s; }
.float-block.b6 { width: 64px; height: 120px; top: 8%; left: 42%; animation-duration: 17s; animation-delay: -5s; opacity: 0.3; }
.float-block.b7 { width: 96px; height: 52px; bottom: 38%; right: 6%; animation-duration: 15s; animation-delay: -11s; }
@keyframes float-drift {
    0%, 100% { transform: translate(0, 0) rotate(var(--rot, 0deg)); }
    25% { transform: translate(18px, -22px) rotate(calc(var(--rot, 0deg) + 8deg)); }
    50% { transform: translate(-12px, 16px) rotate(calc(var(--rot, 0deg) - 6deg)); }
    75% { transform: translate(24px, 10px) rotate(calc(var(--rot, 0deg) + 4deg)); }
}
.float-block.b1 { --rot: 18deg; } .float-block.b2 { --rot: -12deg; } .float-block.b3 { --rot: 32deg; }
.float-block.b4 { --rot: -24deg; } .float-block.b5 { --rot: 0deg; } .float-block.b6 { --rot: 10deg; } .float-block.b7 { --rot: -8deg; }

/* === CHAOTIC GLITCH TITLE === */
.glitch-wrapper { margin-bottom: 10px; position: relative; z-index: 5; }
.glitch {
    font-size: clamp(2.5rem, 8vw, 8rem);
    font-weight: 900; text-transform: uppercase; letter-spacing: 2px;
    color: var(--text-main); position: relative; display: inline-block;
}
.glitch::before, .glitch::after {
    content: attr(data-text); position: absolute; top: 0; left: 0;
    width: 100%; height: 100%; pointer-events: none; opacity: 0.45;
}
.glitch::before {
    text-shadow: -2px 0 rgba(255, 0, 64, 0.6);
    animation: glitch-chaos-a 9s steps(1) infinite;
}
.glitch::after {
    text-shadow: 2px 0 rgba(0, 229, 255, 0.5);
    animation: glitch-chaos-b 10s steps(1) infinite;
}
.glitch.glitch-burst::before,
.glitch.glitch-burst::after { animation-duration: 0.55s; opacity: 0.65; }
@keyframes glitch-chaos-a {
    0%, 88%, 100% { clip-path: inset(0 0 0 0); transform: none; opacity: 0; }
    4%  { clip-path: inset(38% 0 48% 0); transform: translate(0.03em, 0) skewX(-2deg); opacity: 0.35; }
    8%  { clip-path: inset(72% 0 8% 0);  transform: translate(-0.04em, 0.01em) skewX(2deg); opacity: 0.25; }
    12% { clip-path: inset(12% 0 78% 0); transform: translate(0.02em, -0.01em); opacity: 0.3; }
    16% { clip-path: inset(0 0 0 0); transform: none; opacity: 0; }
    52% { clip-path: inset(55% 0 30% 0); transform: translate(-0.03em, 0.02em) skewX(-1deg); opacity: 0.28; }
    56% { clip-path: inset(20% 0 65% 0); transform: translate(0.04em, 0); opacity: 0.22; }
    60% { clip-path: inset(0 0 0 0); transform: none; opacity: 0; }
}
@keyframes glitch-chaos-b {
    0%, 90%, 100% { clip-path: inset(0 0 0 0); transform: none; opacity: 0; }
    6%  { clip-path: inset(62% 0 22% 0); transform: translate(-0.03em, 0.01em) skewX(2deg); opacity: 0.3; }
    10% { clip-path: inset(8% 0 82% 0);  transform: translate(0.03em, -0.01em); opacity: 0.25; }
    14% { clip-path: inset(0 0 0 0); transform: none; opacity: 0; }
    48% { clip-path: inset(42% 0 44% 0); transform: translate(0.02em, 0.02em) skewX(-2deg); opacity: 0.28; }
    54% { clip-path: inset(78% 0 5% 0);  transform: translate(-0.02em, 0); opacity: 0.2; }
    58% { clip-path: inset(0 0 0 0); transform: none; opacity: 0; }
}

/* === SCROLL INDICATOR === */
.scroll-indicator {
    position: absolute; bottom: 36px; left: 50%; transform: translateX(-50%);
    z-index: 25; display: flex; flex-direction: column; align-items: center; gap: 10px;
    text-decoration: none; color: var(--text-main); opacity: 0.85; transition: opacity 0.3s, color 0.3s;
}
.scroll-indicator:hover { opacity: 1; color: var(--accent-orange); }
.scroll-indicator span {
    font-size: clamp(0.65rem, 1.2vw, 0.8rem); font-weight: bold; letter-spacing: 4px;
    text-transform: uppercase;
}
.scroll-wheel {
    width: 26px; height: 42px; border: 2px solid currentColor; border-radius: 14px;
    position: relative; display: flex; justify-content: center; padding-top: 8px;
}
.scroll-wheel::after {
    content: ''; width: 4px; height: 8px; background: var(--accent-orange); border-radius: 2px;
    animation: scroll-dot 1.8s ease-in-out infinite;
}
.scroll-chevron {
    width: 14px; height: 14px; border-right: 2px solid var(--accent-orange);
    border-bottom: 2px solid var(--accent-orange); transform: rotate(45deg);
    animation: scroll-bounce 1.8s ease-in-out infinite; margin-top: -4px;
}
@keyframes scroll-dot {
    0%, 100% { transform: translateY(0); opacity: 1; }
    50% { transform: translateY(10px); opacity: 0.3; }
}
@keyframes scroll-bounce {
    0%, 100% { transform: rotate(45deg) translateY(0); opacity: 0.6; }
    50% { transform: rotate(45deg) translateY(6px); opacity: 1; }
}

.hero h2 {
    font-size: clamp(1.2rem, 3.5vw, 3rem); text-transform: uppercase; letter-spacing: 5px; 
    margin-bottom: 20px; border-bottom: 4px solid var(--text-main); padding-bottom: 10px; z-index: 5; position: relative;
}

.hero p {
    font-size: clamp(0.9rem, 2vw, 1.2rem); max-width: 800px; margin: 20px auto; 
    font-weight: bold; z-index: 5; position: relative;
}

.btn-init {
    margin-top: 40px; padding: clamp(10px, 2vw, 15px) clamp(20px, 4vw, 40px); background: var(--bg-main); 
    color: var(--text-main); border: 3px solid var(--text-main); font-size: clamp(0.9rem, 1.5vw, 1.2rem); 
    font-weight: bold; text-transform: uppercase; cursor: pointer; transition: all 0.3s ease; z-index: 5; position: relative;
}
.btn-init:hover { background: var(--text-main); color: var(--bg-main); box-shadow: 10px 10px 0px var(--accent-orange); transform: translate(-5px, -5px); }

/* === CYBER ZONE === */
.cyber-void {
    background: var(--void-bg); color: var(--text-main); position: relative;
    z-index: 5; padding-top: 100px; transition: background-color 0.3s;
}

.cyber-void::after {
    content: ""; position: absolute; top: 0; left: 0; right: 0; bottom: 0;
    background: repeating-linear-gradient(0deg, transparent, transparent 2px, var(--scanline-color) 2px, var(--scanline-color) 4px);
    pointer-events: none; z-index: 20; 
}

.void-divider {
    position: absolute; top: -100px; left: 0; width: 100%; height: 200px; background: var(--void-bg);
    clip-path: polygon(0 50%, 100% 0, 100% 100%, 0 100%); z-index: 15; transition: background-color 0.3s;
}

/* === QR SHOWCASE SECTION === */
.scroll-section-1 { height: 420vh; position: relative; }

.sticky-container {
    position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column;
    align-items: center; justify-content: center; overflow: hidden; padding: 0 20px;
}

.showcase-headline {
    position: absolute; top: 10%; left: 50%; transform: translateX(-50%);
    width: min(92%, 820px); text-align: center; z-index: 30;
    font-size: clamp(1.2rem, 3vw, 2rem); font-weight: 700; line-height: 1.45;
    letter-spacing: 0.5px; opacity: 1; transition: opacity 0.5s ease, transform 0.5s ease;
}
.showcase-headline.dim { opacity: 0.35; transform: translateX(-50%) translateY(-8px); }

.showcase-copy {
    position: absolute; left: 50%; bottom: 18%; transform: translateX(-50%);
    width: min(88%, 520px); text-align: center; z-index: 35; pointer-events: none;
    font-size: clamp(1rem, 2.2vw, 1.35rem); font-weight: 600; line-height: 1.55;
    color: var(--text-main); opacity: 0; transition: opacity 0.7s ease, transform 0.7s ease;
}
.showcase-copy.visible { opacity: 1; transform: translateX(-50%) translateY(0); }

.showcase-split {
    display: flex; width: min(94%, 1100px); height: min(58vh, 480px); align-items: center;
    justify-content: center; gap: clamp(24px, 5vw, 56px); position: relative; z-index: 25;
    margin-top: 8vh;
}
.showcase-split.split-active { justify-content: flex-start; align-items: stretch; }

.qr-demo-panel {
    flex: 0 0 auto; width: min(100%, 280px); display: flex; align-items: center; justify-content: center;
    transition: transform 0.55s cubic-bezier(0.25, 1, 0.5, 1), width 0.55s ease;
}
.showcase-split.split-active .qr-demo-panel { width: min(38%, 260px); transform: translateX(-6%); }

.product-qr-box {
    position: relative; width: 200px; height: 280px; perspective: 900px;
}
.product-qr-box.glitching { animation: box-glitch 0.35s steps(2) 3; }
@keyframes box-glitch {
    0% { filter: none; transform: translate(0); }
    25% { filter: invert(0.06) hue-rotate(90deg); transform: translate(-4px, 2px) skewX(-3deg); }
    50% { filter: none; transform: translate(3px, -2px) skewX(2deg); }
    75% { filter: invert(0.04); transform: translate(-2px, 0); }
    100% { filter: none; transform: translate(0); }
}

.qr-box-generic, .qr-box-branded {
    position: absolute; inset: 0; border-radius: 6px;
    display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
    padding: 16px; transition: opacity 0.45s ease;
}
.qr-box-generic {
    background: linear-gradient(160deg, #f5f5f5, #e8e8e8);
    border: 2px solid #050505; box-shadow: 8px 8px 0 rgba(0,0,0,0.08);
}
body.dark-theme .qr-box-generic {
    background: linear-gradient(160deg, #1a1a1a, #0d0d0d);
    border-color: #f0f0f0; box-shadow: 8px 8px 0 rgba(255,136,0,0.15);
}
.qr-box-branded {
    opacity: 0; pointer-events: none; overflow: hidden;
    background: linear-gradient(145deg, #c0392b, #922b21);
    border: 2px solid rgba(0,0,0,0.2);
    box-shadow: 0 12px 32px rgba(0,0,0,0.25);
}
.product-qr-box.branded .qr-box-generic { opacity: 0; }
.product-qr-box.branded .qr-box-branded { opacity: 1; pointer-events: auto; }

.qr-box-label {
    position: absolute; top: 14px; left: 14px;
    font-family: monospace; font-size: 0.65rem; letter-spacing: 3px; font-weight: bold;
    color: var(--accent-green); text-transform: uppercase;
}
.product-pack-img {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
}
.product-pack-fallback {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 900; font-size: 1.1rem; letter-spacing: 2px; text-transform: uppercase;
    text-shadow: 0 2px 8px rgba(0,0,0,0.4); pointer-events: none;
}
.product-pack-img.loaded + .product-pack-fallback { display: none; }

.qr-code-large {
    position: relative; width: 100px; height: 100px; flex-shrink: 0; z-index: 2;
    background:
        linear-gradient(135deg, #050505 25%, transparent 25%) -6px 0,
        linear-gradient(225deg, #050505 25%, transparent 25%) -6px 0,
        linear-gradient(315deg, #050505 25%, transparent 25%),
        linear-gradient(45deg, #050505 25%, transparent 25%);
    background-color: #fff; background-size: 12px 12px;
    border: 4px solid #fff; outline: 2px solid #050505; border-radius: 4px; overflow: hidden;
}
.qr-on-pack { margin-bottom: 12px; box-shadow: 0 4px 16px rgba(0,0,0,0.3); }

.scan-laser-h {
    position: absolute; left: 0; width: 100%; height: 3px;
    background: var(--accent-green); box-shadow: 0 0 12px var(--accent-green);
    top: -4px; opacity: 0; z-index: 5;
}
.product-qr-box.scanning .scan-laser-h { opacity: 1; animation: laser-sweep 1.4s ease-in-out infinite; }
@keyframes laser-sweep { 0% { top: -5%; } 50% { top: 105%; } 100% { top: -5%; } }

.right-canvas {
    flex: 1; min-width: 0; height: 100%; position: relative;
    opacity: 0; transform: translateX(36px); transition: opacity 0.6s ease, transform 0.6s ease;
    pointer-events: none;
}
.right-canvas.visible { opacity: 1; transform: translateX(0); pointer-events: auto; }

.mock-browser.active-panel {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    background: var(--bg-main); border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2); overflow: hidden;
    opacity: 1; transform: none; pointer-events: auto;
}
body.dark-theme .mock-browser.active-panel { border: 1px solid #333; box-shadow: 0 20px 50px rgba(0,0,0,0.6); }

.iframe-wrap { flex: 1; overflow: hidden; background: #fcf8f2; }
.iframe-wrap iframe {
    width: 100%; height: 100%; border: none; display: block; pointer-events: none;
}

/* === MOCK BROWSER FRAME === */
.mock-browser {
    position: absolute; width: 100%; height: 100%; background: var(--bg-main); border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.3); display: flex; flex-direction: column; overflow: hidden;
    opacity: 0; transform: translateX(40px); transition: opacity 0.4s ease-out, transform 0.4s ease-out; pointer-events: none;
}
body.dark-theme .mock-browser { box-shadow: 0 20px 50px rgba(0,0,0,0.8); border: 1px solid #333; }
.mock-browser.active { opacity: 1; transform: translateX(0); pointer-events: auto; }

.mock-browser-header { height: 40px; background: #e0e0e0; display: flex; align-items: center; padding: 0 15px; flex-shrink: 0; }
body.dark-theme .mock-browser-header { background: #222; }
.mock-dots { display: flex; gap: 8px; }
.mock-dot { width: 12px; height: 12px; border-radius: 50%; }
.mock-dot.red { background: #ff5f56; } .mock-dot.yellow { background: #ffbd2e; } .mock-dot.green { background: #27c93f; }
.mock-url-bar {
    flex-grow: 1; margin: 0 15px; height: 24px; background: #fff; border-radius: 4px;
    display: flex; align-items: center; padding: 0 10px; font-size: clamp(0.6rem, 1vw, 0.75rem); color: #888; font-family: monospace;
}
body.dark-theme .mock-url-bar { background: #111; color: #aaa; border: 1px solid #444; }

.mock-browser-content { flex-grow: 1; overflow-y: hidden; position: relative; }

/* --- BRIDGE OVERLAY --- */
.qr-bridge-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(10, 10, 15, 0.98);
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    color: var(--accent-green); font-family: monospace; z-index: 50; text-align: center; padding: 20px;
}
.qr-bridge-overlay::before {
    content: ''; width: 60px; height: 60px; border: 3px solid var(--accent-green);
    border-radius: 4px; margin-bottom: 20px; animation: pulse-scan 0.5s infinite alternate;
}
.qr-bridge-overlay span { font-size: clamp(0.9rem, 2vw, 1.2rem); letter-spacing: 2px; animation: glitch-text-scan 0.2s infinite; }
@keyframes pulse-scan {
    from { transform: scale(0.9); box-shadow: 0 0 10px var(--accent-green); }
    to { transform: scale(1.1); box-shadow: 0 0 30px var(--accent-green); }
}
@keyframes glitch-text-scan {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.85; transform: translateX(1px); }
}
.mock-browser.active .qr-bridge-overlay { animation: clear-overlay 0.6s forwards; animation-delay: 1.2s; }
@keyframes clear-overlay { to { opacity: 0; pointer-events: none; } }

/* --- INNER CONTENT: RICE SITE --- */
.site-rice { background-color: #fcf8f2; color: #4a3c31; font-family: 'Georgia', serif; line-height: 1.6; padding: clamp(15px, 3vw, 30px); }
.site-rice .product-card { background: #ffffff; border-radius: 16px; box-shadow: 0 4px 20px rgba(211, 84, 0, 0.08); padding: clamp(15px, 3vw, 30px); text-align: center; margin-bottom: 30px; }
.site-rice h1 { color: #d35400; font-size: clamp(1.5rem, 3vw, 2.2rem); margin-top: 0; }
.site-rice img { width: 100%; height: clamp(150px, 20vw, 250px); border-radius: 12px; object-fit: cover; box-shadow: 0 4px 10px rgba(0,0,0,0.1); margin-bottom: 20px; }
.site-rice .buy-bar { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; background: #fff9f0; padding: 20px; border-radius: 12px; border: 1px solid #f0e4d3; }
.site-rice .buy-btn { background: #e67e22; color: #fff; padding: 10px 20px; border: none; border-radius: 20px; font-weight: bold; width: 100%; cursor: pointer; }
.site-rice .recipe-block { background: #fff3e0; padding: clamp(15px, 3vw, 30px); border-radius: 16px; margin-bottom: 40px; }
.site-rice .recipe-item { background: #fff; padding: 20px; border-radius: 12px; margin-top: 15px; text-align: left; }

/* --- INNER CONTENT: GAME SITE --- */
.site-game {
    background: linear-gradient(160deg, #120a1f 0%, #1a1035 50%, #0d1528 100%);
    color: #e8e0ff; font-family: 'Segoe UI', sans-serif; padding: clamp(15px, 3vw, 28px); min-height: 100%;
}
.site-game .game-hero {
    display: flex; gap: 16px; align-items: flex-start; margin-bottom: 20px; flex-wrap: wrap;
}
.site-game .game-cover {
    width: 100px; height: 130px; flex-shrink: 0; border-radius: 8px;
    background: linear-gradient(135deg, #7c4dff, #311b92);
    box-shadow: 0 8px 24px rgba(124, 77, 255, 0.4); display: flex; align-items: center; justify-content: center;
    font-size: 2rem;
}
.site-game h1 { font-size: clamp(1.3rem, 2.5vw, 1.8rem); margin: 0 0 8px; color: #fff; }
.site-game .age-badge {
    display: inline-block; background: #ff6600; color: #fff; font-weight: bold;
    padding: 4px 12px; border-radius: 4px; font-size: 0.85rem; margin-bottom: 10px;
}
.site-game .game-meta {
    display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px;
}
.site-game .meta-chip {
    font-size: 0.75rem; padding: 4px 10px; border-radius: 4px;
    background: rgba(255,255,255,0.08); border: 1px solid rgba(179,136,255,0.3);
}
.site-game .story-block {
    background: rgba(255,255,255,0.04); border-left: 3px solid #7c4dff;
    padding: 14px 16px; margin-bottom: 16px; border-radius: 0 8px 8px 0;
}
.site-game .story-block h3 { font-size: 0.8rem; color: #b388ff; margin: 0 0 8px; letter-spacing: 1px; text-transform: uppercase; }
.site-game .story-block p { font-size: 0.85rem; line-height: 1.55; color: #c4b8dc; margin: 0; }
.site-game .related-block {
    background: rgba(255,255,255,0.05); border: 1px solid rgba(124, 77, 255, 0.35);
    border-radius: 12px; padding: 16px; margin-bottom: 16px;
}
.site-game .related-block h3 {
    font-size: 0.75rem; letter-spacing: 2px; color: #b388ff; margin: 0 0 12px; text-transform: uppercase;
}
.site-game .related-item {
    display: flex; align-items: center; gap: 12px; padding: 10px 0;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.site-game .related-item:last-child { border-bottom: none; padding-bottom: 0; }
.site-game .related-thumb {
    width: 48px; height: 48px; border-radius: 6px; flex-shrink: 0;
    background: linear-gradient(135deg, #536dfe, #304ffe);
}
.site-game .related-item:nth-child(3) .related-thumb { background: linear-gradient(135deg, #00bcd4, #00838f); }
.site-game .related-item:nth-child(4) .related-thumb { background: linear-gradient(135deg, #ff4081, #c51162); }
.site-game .related-item strong { display: block; font-size: 0.9rem; }
.site-game .related-item span { font-size: 0.75rem; color: #8a7aaa; }
.site-game .buy-btn {
    width: 100%; padding: 14px; background: linear-gradient(90deg, #7c4dff, #536dfe);
    border: none; color: #fff; font-size: 1rem; font-weight: bold; border-radius: 8px;
    cursor: pointer; text-transform: uppercase; letter-spacing: 1px;
}

.canvas-glitch { animation: hardware-snap-flash 0.2s infinite; }
@keyframes hardware-snap-flash {
    0% { filter: skewX(-8deg) brightness(1.2); transform: translate(3px, -3px); }
    50% { filter: skewX(8deg) invert(0.05); transform: translate(-3px, 3px); }
    100% { filter: skewX(0deg); transform: translate(0); }
}

/* === INVENTORY MAP SECTION === */
.scroll-section-2 { height: 520vh; position: relative; background: transparent; }
.map-camera {
    position: sticky; top: 0; height: 100vh; overflow: hidden;
    display: flex; align-items: center; justify-content: center; z-index: 25;
    perspective: 1600px;
}
.map-stage {
    position: relative; width: min(92vw, 900px); height: min(70vh, 560px);
    transform-style: preserve-3d; transition: transform 0.08s linear;
}
.map-floor {
    position: absolute; inset: 10% 5% 15% 5%;
    transform-style: preserve-3d;
    background:
        linear-gradient(rgba(0,170,68,0.12) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,170,68,0.12) 1px, transparent 1px),
        linear-gradient(135deg, rgba(255,102,0,0.04), rgba(0,170,68,0.06));
    background-size: 40px 40px, 40px 40px, 100% 100%;
    border: 2px solid rgba(0,170,68,0.35); border-radius: 8px;
    transform-origin: center center; transform-style: preserve-3d;
    box-shadow: 0 30px 80px rgba(0,0,0,0.15);
}
body.dark-theme .map-floor { border-color: rgba(0,255,102,0.35); box-shadow: 0 30px 80px rgba(0,0,0,0.5); }

.map-aisle-label {
    position: absolute; font-family: monospace; font-size: 0.65rem; letter-spacing: 2px;
    color: var(--accent-green); opacity: 0.7; text-transform: uppercase;
}
.map-aisle-label.a1 { top: 22%; left: 18%; }
.map-aisle-label.a2 { top: 22%; left: 42%; }
.map-aisle-label.a3 { top: 22%; right: 18%; }
.map-aisle-label.a4 { bottom: 28%; left: 30%; }

.map-pin {
    position: absolute; top: 58%; left: 62%; width: 20px; height: 20px;
    transform: translate(-50%, -100%); z-index: 10;
}
.map-pin::before {
    content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
    width: 3px; height: 14px; background: var(--accent-orange);
}
.map-pin::after {
    content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
    width: 16px; height: 16px; border-radius: 50% 50% 50% 0;
    background: var(--accent-orange); transform: translateX(-50%) rotate(-45deg);
    box-shadow: 0 0 20px rgba(255,102,0,0.6);
    animation: pin-pulse 1.5s ease-in-out infinite;
}
@keyframes pin-pulse {
    0%, 100% { box-shadow: 0 0 12px rgba(255,102,0,0.5); }
    50% { box-shadow: 0 0 28px rgba(255,102,0,0.9); }
}
.map-pin-label {
    position: absolute; top: -28px; left: 50%; transform: translateX(-50%);
    font-family: monospace; font-size: 0.65rem; white-space: nowrap;
    color: var(--accent-orange); letter-spacing: 1px;
}

.eagle-cam {
    position: absolute; width: 44px; height: 44px; z-index: 20;
    left: 15%; top: 20%;
    transform: translate(-50%, -50%); opacity: 0; pointer-events: none;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.3));
    transition: opacity 0.3s;
}
.eagle-cam svg { width: 100%; height: 100%; }
.eagle-cam.visible { opacity: 1; }

.aisle-3d-layer {
    position: absolute; inset: 0; opacity: 0; pointer-events: none;
    transform-style: preserve-3d;
}
.shelf-row {
    position: absolute; height: 80px; background: linear-gradient(180deg, rgba(0,170,68,0.15), rgba(0,170,68,0.05));
    border: 1px solid rgba(0,170,68,0.4); transform-style: preserve-3d;
}
.shelf-row.r1 { top: 25%; left: 10%; right: 10%; transform: translateZ(40px); }
.shelf-row.r2 { top: 45%; left: 10%; right: 10%; transform: translateZ(80px); }
.shelf-row.r3 { top: 65%; left: 10%; right: 10%; transform: translateZ(120px); }

.shelf-scene {
    position: absolute; top: 52%; left: 58%; width: 160px; height: 140px;
    transform: translate(-50%, -50%); transform-style: preserve-3d;
    opacity: 0; z-index: 25; pointer-events: none;
}
.shelf-board {
    position: absolute; bottom: 28px; left: -30px; right: -30px; height: 10px;
    background: linear-gradient(180deg, rgba(0,170,68,0.5), rgba(0,170,68,0.2));
    border: 1px solid rgba(0,170,68,0.6); transform: rotateX(12deg); transform-origin: bottom;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}
.shelf-product-wrap {
    position: absolute; bottom: 38px; left: 50%; transform: translateX(-50%);
    transform-style: preserve-3d;
}
.shelf-product-3d {
    width: 70px; height: 95px; position: relative; transform-style: preserve-3d;
    transform: rotateY(-25deg) rotateX(-8deg);
}
.shelf-box-face {
    position: absolute; border: 1px solid rgba(255,102,0,0.6);
    background: linear-gradient(145deg, rgba(192,57,43,0.9), rgba(146,43,33,0.95));
    box-shadow: inset 0 0 12px rgba(0,0,0,0.3);
    display: flex; align-items: center; justify-content: center;
    font-size: 0.45rem; font-family: monospace; color: #fff; letter-spacing: 1px;
}
.sb-front, .sb-back { width: 70px; height: 95px; }
.sb-left, .sb-right { width: 35px; height: 95px; left: 17px; }
.sb-top, .sb-bottom { width: 70px; height: 35px; top: 30px; }
.sb-front  { transform: translateZ(18px); }
.sb-back   { transform: rotateY(180deg) translateZ(18px); }
.sb-right  { transform: rotateY(90deg) translateZ(35px); }
.sb-left   { transform: rotateY(-90deg) translateZ(35px); }
.sb-top    { transform: rotateX(90deg) translateZ(48px); }
.sb-bottom { transform: rotateX(-90deg) translateZ(48px); }
.shelf-qr-mini {
    width: 22px; height: 22px;
    background:
        linear-gradient(135deg, #fff 25%, transparent 25%) -3px 0,
        linear-gradient(225deg, #fff 25%, transparent 25%) -3px 0,
        linear-gradient(315deg, #fff 25%, transparent 25%),
        linear-gradient(45deg, #fff 25%, transparent 25%);
    background-color: #fff; background-size: 6px 6px; border: 1px solid #fff;
}
.shelf-product-3d.fly-through .sb-front {
    transition: opacity 0.4s ease, transform 0.4s ease;
    opacity: 0.2; transform: translateZ(80px) scale(1.2);
}
.shelf-product-3d.fly-through .sb-right,
.shelf-product-3d.fly-through .sb-left,
.shelf-product-3d.fly-through .sb-top,
.shelf-product-3d.fly-through .sb-bottom { opacity: 0.15; }

.package-reveal {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    align-items: center; justify-content: center; text-align: center;
    opacity: 0; z-index: 35; padding: 20px; pointer-events: none;
}
.package-reveal.visible { opacity: 1; }
.package-reveal h3 {
    font-size: clamp(1.5rem, 3.5vw, 2.5rem); text-transform: uppercase;
    letter-spacing: 4px; margin-bottom: 12px;
    text-shadow: 0 0 24px var(--accent-green);
}
.package-reveal p { font-size: clamp(0.95rem, 2vw, 1.15rem); max-width: 500px; opacity: 0.85; }

.map-narrative {
    position: absolute; top: 8%; left: 50%; transform: translateX(-50%);
    text-align: center; z-index: 50; width: min(90%, 600px); opacity: 0; transition: opacity 0.4s;
}
.map-narrative.visible { opacity: 1; }
.map-narrative h2 {
    font-size: clamp(1.4rem, 3vw, 2.2rem); text-transform: uppercase;
    letter-spacing: 3px; margin-bottom: 8px;
}
.map-narrative p { font-size: clamp(0.85rem, 1.8vw, 1rem); opacity: 0.8; }

.management-reveal {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    align-items: center; justify-content: center; text-align: center;
    z-index: 60; opacity: 0; pointer-events: none; padding: 20px;
    background: radial-gradient(circle at center, rgba(255,102,0,0.08), transparent 70%);
}
.management-reveal.visible { opacity: 1; pointer-events: auto; }
.management-reveal h2 {
    font-size: clamp(2rem, 5vw, 4rem); text-transform: uppercase; letter-spacing: 4px;
    margin-bottom: 16px; border-bottom: 4px solid var(--accent-orange); padding-bottom: 12px;
}
.management-reveal p {
    font-size: clamp(1rem, 2vw, 1.25rem); max-width: 640px; line-height: 1.6; opacity: 0.9;
}

/* === RESPONSIVE MEDIA QUERIES === */
/* Tablet & Mobile Layout Adaptation */
@media (max-width: 960px) {
    .corner-banner-top { width: 100px; height: 500px; top: -100px; right: -20px; }
    .corner-banner-left { width: 250px; height: 250px; bottom: -50px; left: -50px; }
    .showcase-headline { top: 6%; font-size: 1.1rem; }
    .showcase-copy { bottom: 12%; width: 94%; }
    .showcase-split, .showcase-split.split-active {
        flex-direction: column; height: auto; min-height: 72vh; gap: 16px; margin-top: 12vh;
    }
    .qr-demo-panel, .showcase-split.split-active .qr-demo-panel {
        width: 100%; transform: none;
    }
    .right-canvas { height: 45vh; min-height: 260px; }
    .scroll-indicator { bottom: 20px; }
    .map-stage { height: 55vh; }
}

@media (max-width: 480px) {
    .qr-code-large { width: 110px; height: 110px; }
}

/* 4K / Ultra-wide TVs */
@media (min-width: 1800px) {
    .showcase-split { max-width: 1400px; }
    .site-rice, .site-game { font-size: 1.3rem; }
}
