body, html {
	margin: 0;
	padding: 0;
	overscroll-behavior: none;
	overflow-x: hidden;
	overflow-y: auto;
	height: 100%;
	scroll-behavior: smooth;
	background: #000000; /* Black background to prevent white edges */
}

/* Start Screen Styles */
.start-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #000000;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Inter', system-ui, sans-serif;
    opacity: 1;
    transition: opacity 0.8s ease;
}

.start-screen.fade-out {
    opacity: 0;
    pointer-events: none;
}

.start-content {
    text-align: center;
    max-width: 600px;
    padding: 2rem;
}

.logo-container {
    margin-bottom: 2rem;
}

.start-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto;
    opacity: 0;
    animation: logoFadeIn 1s ease forwards;
}

.start-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    color: #f3f4f6;
    margin-bottom: 1rem;
    line-height: 1.2;
    opacity: 0;
    animation: titleSlideUp 1s ease 0.3s forwards;
}

.start-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    color: #9ca3af;
    margin-bottom: 3rem;
    line-height: 1.6;
    opacity: 0;
    animation: subtitleSlideUp 1s ease 0.6s forwards;
}

.start-button {
    background: #2563eb;
    color: white;
    border: none;
    padding: 12px 32px;
    border-radius: 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: buttonSlideUp 1s ease 0.9s forwards;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.start-button:hover,
.start-button.touch-active {
    background: transparent;
    border: 1px solid #2563eb;
    color: #2563eb;
    transform: scale(0.98);
}

.start-button::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(45deg, #2563eb, #60a5fa);
    z-index: -1;
    transition: width 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.start-button:hover::after,
.start-button.touch-active::after {
    width: 100%;
}

.start-button:hover,
.start-button.touch-active {
    color: #ffffff;
}

/* Preloader Styles */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #000000;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Inter', system-ui, sans-serif;
    opacity: 1;
    transition: opacity 0.8s ease;
}

.preloader.fade-out {
    opacity: 0;
    pointer-events: none;
}

.preloader-content {
    text-align: center;
}

.counter {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    font-weight: 700;
    color: #2563eb;
    margin-bottom: 1rem;
    font-family: 'Courier New', monospace;
    letter-spacing: 0.1em;
}

.loading-text {
    font-size: clamp(0.9rem, 2.5vw, 1.1rem);
    color: #9ca3af;
    margin-bottom: 1rem;
    opacity: 0.8;
}

/* Loading state styles */
body.loading-active {
    overflow: hidden;
}

body.loading-active #overlay-root {
    opacity: 0;
    pointer-events: none;
}

/* Particle assembly phase - hide all UI elements, show only particles */
body.particle-assembly {
    overflow: hidden;
}

body.particle-assembly header,
body.particle-assembly .nav-dots,
body.particle-assembly .scroll-indicator,
body.particle-assembly #back-btn-container,
body.particle-assembly .content-section {
    opacity: 0;
    pointer-events: none;
}

body.particle-assembly #overlay-root {
    opacity: 0;
    pointer-events: none;
}

/* Show canvas during assembly */
body.particle-assembly canvas {
    opacity: 1;
    pointer-events: auto;
}

/* Post-assembly - reveal UI elements with staggered animations */
body.particles-ready {
    overflow: auto;
}

body.particles-ready header,
body.particles-ready .nav-dots,
body.particles-ready #back-btn-container {
    opacity: 1;
    pointer-events: auto;
    transition: opacity 1s ease;
}

/* Don't let body class control scroll indicator - we handle it manually */
body.particles-ready .scroll-indicator:not(.animate-in):not(.hidden) {
    opacity: 0;
    pointer-events: auto;
}

body.particles-ready #overlay-root {
    opacity: 1;
    pointer-events: auto;
    transition: opacity 1s ease;
}

/* Content sections should follow existing animation system, not override it */
body.particles-ready .content-section.active {
    opacity: 1;
    pointer-events: auto;
}

/* Play button should only be visible when its section is active */
body.particles-ready .content-section:not(.active) #play-btn,
body.particles-ready .content-section:not(.active) #stop-btn {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
}

/* Staggered reveal for better effect */
body.particles-ready header {
    transition-delay: 0.2s;
}

body.particles-ready .nav-dots {
    transition-delay: 0.4s;
}

/* When we have manual control, don't let body class override */
body.particles-ready .scroll-indicator.hidden {
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Let animate-in class handle the animation */
body.particles-ready .scroll-indicator.animate-in {
    opacity: 1 !important;
    transition-delay: 0s;
}

body.particles-ready #back-btn-container {
    transition-delay: 0.8s;
}

/* Animations */
@keyframes logoFadeIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes titleSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes subtitleSlideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes buttonSlideUp {
    from {
        opacity: 0;
        transform: translateY(70px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .start-content {
        padding: 1rem;
        max-width: 90vw;
    }

    .start-logo {
        width: 60px;
        height: 60px;
    }

    .start-button {
        padding: 10px 24px;
        font-size: 0.9rem;
    }

    .counter {
        font-size: clamp(1.2rem, 6vw, 2rem);
    }

    .loading-text {
        font-size: clamp(0.8rem, 3.5vw, 1rem);
    }
}

/* Hamburger Menu Responsive Breakpoint at 670px */
@media (max-width: 670px) {
    /* Hide desktop navigation links */
    .flex.flex-1.justify-center.max-sm\:hidden {
        display: none !important;
    }
    
    /* Hide desktop sound toggle */
    #sound-toggle-btn {
        display: none !important;
    }
    
    /* Show hamburger menu and ensure it stays on the right */
    #hamburger-menu {
        display: block !important;
        position: relative !important;
        z-index: 9999 !important;
        margin-left: auto; /* Force to right side */
    }
    
    /* Ensure container keeps hamburger on right */
    .flex.items-baseline.gap-7.max-sm\:justify-end.max-sm\:flex-1 {
        justify-content: flex-end !important;
        flex: 1 !important;
    }
}

@media (min-width: 671px) {
    /* Show desktop navigation links */
    .flex.flex-1.justify-center.max-sm\:hidden {
        display: flex !important;
    }
    
    /* Show desktop sound toggle */
    #sound-toggle-btn {
        display: block !important;
    }
    
    /* Hide hamburger menu */
    #hamburger-menu {
        display: none !important;
    }
}

/* Premium Hamburger Menu Styles */
#hamburger-toggle:checked ~ label .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
    background: #60a5fa;
}

#hamburger-toggle:checked ~ label .hamburger-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

#hamburger-toggle:checked ~ label .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
    background: #60a5fa;
}

/* Ensure hamburger X icon stays above overlay when menu is open */
#hamburger-toggle:checked ~ label.hamburger-icon {
    z-index: 10002 !important;
    position: relative !important;
}

/* Show overlay when hamburger is checked */
#hamburger-toggle:checked ~ .hamburger-overlay {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Animate menu content when overlay is shown */
#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-menu-content {
    transform: translateY(0) !important;
}

/* Staggered animation for menu items */
#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-nav-link {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-nav-link:nth-child(1) {
    transition-delay: 0.1s;
}

#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-nav-link:nth-child(2) {
    transition-delay: 0.15s;
}

#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-nav-link:nth-child(3) {
    transition-delay: 0.2s;
}

#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-nav-link:nth-child(4) {
    transition-delay: 0.25s;
}

#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-nav-link:nth-child(5) {
    transition-delay: 0.3s;
}

#hamburger-toggle:checked ~ .hamburger-overlay .hamburger-divider {
    opacity: 1 !important;
    transform: scaleX(1) !important;
    transition-delay: 0.35s;
}

#hamburger-toggle:checked ~ .hamburger-overlay .mobile-sound-toggle {
    opacity: 1 !important;
    transform: translateY(0) !important;
    transition-delay: 0.4s;
}

/* Hover effects for hamburger menu items */
.hamburger-nav-link:hover {
    color: #ffffff !important;
    transform: translateY(-2px) !important;
}

.hamburger-nav-link:active {
    transform: translateY(0) !important;
}

/* Mobile sound toggle hover effect */
#mobile-sound-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    transform: scale(1.05);
}

/* Hamburger button touch feedback */
.hamburger-icon:hover,
.hamburger-icon.touch-active {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

.hamburger-icon.touch-active .hamburger-line {
    background: #60a5fa !important;
}

/* Responsive adjustments for different screen sizes */
@media (max-width: 670px) {
    .hamburger-menu-content {
        gap: 2rem;
    }
    
    .hamburger-nav-link {
        font-size: clamp(1.5rem, 4vw, 2rem);
    }
}

@media (max-width: 480px) {
    .hamburger-menu-content {
        gap: 1.5rem !important;
    }
    
    .hamburger-nav-link {
        font-size: clamp(1.2rem, 5vw, 1.8rem) !important;
    }
}

@media (max-height: 600px) {
    .hamburger-menu-content {
        gap: 1.2rem !important;
    }
    
    .hamburger-nav-link {
        font-size: clamp(1rem, 4vw, 1.5rem) !important;
    }
    
    .hamburger-divider {
        margin: 0.5rem 0 !important;
    }
}

@media (max-height: 500px) {
    .hamburger-overlay {
        padding: 1rem !important;
    }

    .hamburger-menu-content {
        gap: 1rem !important;
    }

    .hamburger-nav-link {
        font-size: clamp(0.9rem, 4vw, 1.3rem) !important;
    }
}

/* Additional height-based responsive breakpoints for hamburger menu */
@media (max-height: 450px) {
    .hamburger-overlay {
        padding: 0.5rem !important;
    }

    .hamburger-menu-content {
        gap: 0.6rem !important;
    }

    .hamburger-nav-link {
        font-size: clamp(0.7rem, 4vw, 1rem) !important;
    }

    .hamburger-divider {
        margin: 0.25rem 0 !important;
        width: 50px !important;
    }

    .mobile-sound-toggle span {
        font-size: 0.85rem !important;
    }

    .mobile-sound-toggle img {
        width: 18px !important;
        height: 18px !important;
    }
}

@media (max-height: 400px) {
    .hamburger-overlay {
        padding: 0.4rem !important;
    }

    .hamburger-menu-content {
        gap: 0.5rem !important;
    }

    .hamburger-nav-link {
        font-size: clamp(0.6rem, 4vw, 0.9rem) !important;
    }

    .hamburger-divider {
        margin: 0.2rem 0 !important;
        width: 45px !important;
    }

    .mobile-sound-toggle span {
        font-size: 0.8rem !important;
    }

    .mobile-sound-toggle img {
        width: 16px !important;
        height: 16px !important;
    }
}

@media (max-height: 350px) {
    .hamburger-overlay {
        padding: 0.3rem !important;
    }

    .hamburger-menu-content {
        gap: 0.4rem !important;
    }

    .hamburger-nav-link {
        font-size: clamp(0.5rem, 4vw, 0.8rem) !important;
    }

    .hamburger-divider {
        margin: 0.15rem 0 !important;
        width: 40px !important;
    }

    .mobile-sound-toggle span {
        font-size: 0.75rem !important;
    }

    .mobile-sound-toggle img {
        width: 14px !important;
        height: 14px !important;
    }
}

@media (max-height: 300px) {
    .hamburger-overlay {
        padding: 0.25rem !important;
    }

    .hamburger-menu-content {
        gap: 0.3rem !important;
    }

    .hamburger-nav-link {
        font-size: clamp(0.45rem, 4vw, 0.7rem) !important;
    }

    .hamburger-divider {
        margin: 0.1rem 0 !important;
        width: 35px !important;
    }

    .mobile-sound-toggle span {
        font-size: 0.7rem !important;
    }

    .mobile-sound-toggle img {
        width: 12px !important;
        height: 12px !important;
    }
}

@media (max-height: 250px) {
    .hamburger-overlay {
        padding: 0.2rem !important;
    }

    .hamburger-menu-content {
        gap: 0.25rem !important;
    }

    .hamburger-nav-link {
        font-size: clamp(0.4rem, 4vw, 0.6rem) !important;
    }

    .hamburger-divider {
        margin: 0.08rem 0 !important;
        width: 30px !important;
    }

    .mobile-sound-toggle span {
        font-size: 0.65rem !important;
    }

    .mobile-sound-toggle img {
        width: 10px !important;
        height: 10px !important;
    }
}

@media (max-height: 200px) {
    .hamburger-overlay {
        padding: 0.15rem !important;
    }

    .hamburger-menu-content {
        gap: 0.2rem !important;
    }

    .hamburger-nav-link {
        font-size: clamp(0.35rem, 4vw, 0.5rem) !important;
    }

    .hamburger-divider {
        margin: 0.05rem 0 !important;
        width: 25px !important;
    }

    .mobile-sound-toggle span {
        font-size: 0.6rem !important;
    }

    .mobile-sound-toggle img {
        width: 8px !important;
        height: 8px !important;
    }
}

/* Landscape mobile specific adjustments */
@media (max-height: 500px) and (orientation: landscape) {
    .hamburger-menu-content {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        max-width: 90vw;
        gap: 1rem 2rem !important;
    }
    
    .hamburger-divider {
        width: 100%;
        height: 1px !important;
        margin: 0.5rem 0 !important;
    }
    
    .mobile-sound-toggle {
        width: 100%;
        justify-content: center !important;
    }
}

/* Prevent body scroll when hamburger menu is open */
body:has(#hamburger-toggle:checked) {
    overflow: hidden;
}

/* Fallback for browsers that don't support :has() */
.hamburger-menu-open {
    overflow: hidden !important;
}

/* Ultra-mobile adjustments */
@media (max-width: 390px) {
    .start-title {
        font-size: clamp(1.5rem, 7vw, 2.5rem);
    }

    .start-subtitle {
        font-size: clamp(0.8rem, 4vw, 1.1rem);
    }
}

/* Very short screen adjustments - Height-based breakpoints */
@media (max-height: 430px) {
    .start-content {
        padding: 1rem;
        max-width: 95vw;
    }

    .logo-container {
        margin-bottom: 1rem;
    }

    .start-logo {
        width: 60px;
        height: 60px;
    }

    .start-title {
        font-size: clamp(1.5rem, 6vw, 2.2rem);
        margin-bottom: 0.5rem;
    }

    .start-subtitle {
        font-size: clamp(0.8rem, 3.5vw, 1rem);
        margin-bottom: 1.5rem;
        line-height: 1.4;
    }

    .start-button {
        padding: 8px 20px;
        font-size: 0.9rem;
    }
}

@media (max-height: 330px) {
    .start-content {
        padding: 0.8rem;
    }

    .logo-container {
        margin-bottom: 0.8rem;
    }

    .start-logo {
        width: 50px;
        height: 50px;
    }

    .start-title {
        font-size: clamp(1.3rem, 5.5vw, 2rem);
        margin-bottom: 0.4rem;
        line-height: 1.1;
    }

    .start-subtitle {
        font-size: clamp(0.75rem, 3vw, 0.95rem);
        margin-bottom: 1.2rem;
        line-height: 1.3;
    }

    .start-button {
        padding: 6px 18px;
        font-size: 0.85rem;
    }
}

@media (max-height: 280px) {
    .start-content {
        padding: 0.6rem;
    }

    .logo-container {
        margin-bottom: 0.6rem;
    }

    .start-logo {
        width: 45px;
        height: 45px;
    }

    .start-title {
        font-size: clamp(1.2rem, 5vw, 1.8rem);
        margin-bottom: 0.3rem;
        line-height: 1.1;
    }

    .start-subtitle {
        font-size: clamp(0.7rem, 2.8vw, 0.9rem);
        margin-bottom: 1rem;
        line-height: 1.2;
    }

    .start-button {
        padding: 5px 16px;
        font-size: 0.8rem;
    }
}

@media (max-height: 250px) {
    .start-content {
        padding: 0.5rem;
        max-width: 90vw;
    }

    .logo-container {
        margin-bottom: 0.5rem;
    }

    .start-logo {
        width: 40px;
        height: 40px;
    }

    .start-title {
        font-size: clamp(1.1rem, 4.5vw, 1.6rem);
        margin-bottom: 0.2rem;
        line-height: 1.0;
    }

    .start-subtitle {
        font-size: clamp(0.65rem, 2.5vw, 0.85rem);
        margin-bottom: 0.8rem;
        line-height: 1.1;
    }

    .start-button {
        padding: 4px 14px;
        font-size: 0.75rem;
    }
}

/* Prevent white edges on all elements */
* {
	box-sizing: border-box;
}

/* Ensure any potential offscreen elements are black */
body::before,
html::before,
body::after,
html::after {
	content: '';
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: #000000;
	z-index: -9999;
	pointer-events: none;
}

/* Black background for any canvas or script elements */
canvas,
script,
style,
link {
	background: #000000;
}

/* Exact Overlay Styles from Pitch */
#overlay-root {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    pointer-events: none;
    overflow: hidden;
    font-family: 'Inter', system-ui, sans-serif;
    opacity: 0;
    transition: opacity 0.8s ease;
}

/* Hide all UI elements initially */
body.loading-active header,
body.loading-active .nav-dots,
body.loading-active .scroll-indicator,
body.loading-active #back-btn-container,
body.loading-active .content-section {
    opacity: 0;
    pointer-events: none;
}

/* Hide canvas during loading */
body.loading-active canvas {
    opacity: 0;
    pointer-events: none;
}

/* Show canvas after loading */
body:not(.loading-active) canvas {
    opacity: 1;
    transition: opacity 0.8s ease;
}

/* Enable canvas interactions for Minecraft world */
body.minecraft-world-active canvas {
    pointer-events: auto !important;
    z-index: 1001 !important; /* Above overlay layers */
}

/* Disable overlay interactions when Minecraft world is active */
body.minecraft-world-active #overlay-root,
body.minecraft-world-active #scroll-content {
    pointer-events: none !important;
}

/* Allow interaction only with specific interactive elements */
.interactive-element {
    pointer-events: auto;
}

/* Make all overlay elements transparent to events by default */
#overlay-root > * {
    pointer-events: none;
}

#overlay-root > * > * {
    pointer-events: none;
}

/* Specifically enable pointer events for navigation links and buttons */
#overlay-root a,
#overlay-root button,
#overlay-root .nav-logo,
#overlay-root [onclick],
#overlay-root [role="button"],
#overlay-root .hiw-text,
#overlay-root .section-subtitle.interactive,
#overlay-root #hamburger-menu,
#overlay-root .hamburger-icon,
#overlay-root .hamburger-overlay,
#overlay-root .hamburger-nav-link,
#overlay-root .mobile-sound-toggle {
    pointer-events: auto !important;
}

/* Exact Tailwind classes converted to CSS */
.screen-max-width {
    margin-inline-start: auto;
    margin-inline-end: auto;
    position: relative;
    max-width: 1120px;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-height {
    height: calc(100vh - 60px);
}

.btn {
    padding: 6px 16px;
    border-radius: 1.5rem;
    background: #2563eb;
    margin: 20px 0;
    text-decoration: none;
    color: white;
    font-weight: 500;
    font-size: 0.8rem;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn:hover,
.btn.touch-active {
    background: transparent;
    border: 1px solid #2563eb;
    color: #2563eb;
    transform: scale(0.98); /* Subtle scale feedback for touch */
}

.hero-title {
    text-align: center;
    font-weight: 600;
    font-size: 1.875rem;
    color: #f3f4f6;
    opacity: 0; /* Initial hidden state - will be animated by GSAP */
    margin-bottom: 2.5rem;
}

.text-gradient {
    background: linear-gradient(to right, #60a5fa, #2563eb);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

/* Hero elements start hidden - GSAP will animate them */
.hero-title {
    opacity: 0; /* Initial hidden state - will be animated by GSAP */
}

#cta {
    opacity: 0; /* Initial hidden state - will be animated by GSAP */
}

/* Scroll Content Styles */
#scroll-content {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    pointer-events: auto;
    z-index: 1000;
}

.hero-content {
    text-align: center;
    max-width: 800px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* Ensure container only expands downward */
    margin-top: -350px; /* Move content up for premium positioning on normal sections */
    min-height: 0;
    flex-shrink: 0;
    /* Text wrapping for all child elements */
    word-wrap: break-word;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
}

/* Special handling for sections with long content */
.hero-content.long-content {
    margin-top: 0;
    height: calc(100vh - 160px); /* Full page height minus navbar (60px = nav height) */
    overflow-y: auto;
    padding-top: 20px; /* Account for navbar */
    /* Hide scrollbar completely */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
    /* Add grab cursor for interactive scrolling */
    cursor: grab;
    user-select: none; /* Prevent text selection during drag */
    -webkit-user-select: none; /* Safari */
    -moz-user-select: none; /* Firefox */
    -ms-user-select: none; /* IE/Edge */
}

.hero-content.long-content::-webkit-scrollbar {
    display: none; /* WebKit browsers */
}

/* Grabbing cursor when actively dragging */
.hero-content.long-content.grabbing {
    cursor: grabbing;
}

/* Fix for short screens - prevent section-title from overlapping navbar */
@media (max-height: 700px) {
    .hero-content {
        margin-top: -250px; /* Reduce upward positioning for short screens */
    }
}

@media (max-height: 600px) {
    .hero-content {
        margin-top: -150px; /* Further reduce for very short screens */
    }
}

@media (max-height: 500px) {
    .hero-content {
        margin-top: -50px; /* Minimal upward positioning for extremely short screens */
    }

    /* Reduce text sizes for very short screens */
    .section-title {
        font-size: clamp(1.1rem, 6vw, 1.5rem) !important; /* Smaller title */
        margin-bottom: 1rem; /* Reduce spacing */
    }

    .section-subtitle {
        font-size: clamp(0.75rem, 3vw, 0.9rem) !important; /* Smaller subtitle */
        margin-bottom: 1.5rem; /* Reduce spacing */
        line-height: 1.4; /* Tighter line height */
    }

    /* Horizontal split layout for very short screens */
    .section-cta {
        position: fixed;
        right: 25%; /* Center of right half from right edge */
        bottom: 20px; /* Stick to bottom like scroll indicator */
        transform: translateX(50%); /* Center horizontally from right */
        margin-top: 0;
        opacity: 1; /* Ensure visible */
        z-index: 1001; /* Same z-index as scroll indicator */
    }

    /* Position scroll indicator on right side */
    .scroll-indicator {
        left: 75% !important; /* Center of right half - override base 50% */
        transform: translateX(-50%) !important; /* Center horizontally - override base */
        bottom: 20px !important; /* Override base 30px */
        position: fixed !important; /* Ensure fixed positioning is maintained */
    }
}

/* Additional adjustments for extremely short screens */
@media (max-height: 400px) {
    .section-title {
        font-size: clamp(0.9rem, 5vw, 1.2rem) !important; /* Even smaller title */
        margin-bottom: 0.5rem; /* Minimal spacing */
    }

    .section-subtitle {
        font-size: clamp(0.65rem, 2.5vw, 0.8rem) !important; /* Even smaller subtitle */
        margin-bottom: 1rem; /* Further reduced spacing */
        line-height: 1.3; /* Even tighter line height */
    }

    .section-cta {
        position: fixed;
        right: 25%; /* Center of right half from right edge */
        bottom: 15px; /* Stick to bottom like scroll indicator (higher for very short screens) */
        transform: translateX(50%); /* Center horizontally from right */
        margin-top: 0;
        opacity: 1; /* Ensure visible */
        z-index: 1001; /* Same z-index as scroll indicator */
    }

    /* Position scroll indicator on right side for extremely short screens */
    .scroll-indicator {
        left: 75% !important; /* Center of right half - override base 50% */
        transform: translateX(-50%) !important; /* Center horizontally - override base */
        bottom: 15px !important; /* Slightly higher for very short screens */
        position: fixed !important; /* Ensure fixed positioning is maintained */
    }
}

/* Water Ripple Effect Overlay */
.ripple-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.1); /* Very subtle dark overlay */
    z-index: 1;
    pointer-events: auto; /* Allow mouse interactions for ripple effect */
    cursor: crosshair;
}

/* Ensure content stays above ripple overlay but button remains clickable */
.content-section[data-section="6"] .hero-content {
    position: relative;
    z-index: 2;
}

.content-section[data-section="6"] .btn {
    position: relative;
    z-index: 3;
}

/* Disable scroll content when Minecraft is active */
#scroll-content.minecraft-active {
    pointer-events: none;
}

/* Ensure nav dots remain interactive even when scroll content is disabled */
.nav-dots {
    pointer-events: auto !important;
}

.content-section {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.6s ease, visibility 0.6s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.content-section.active {
    opacity: 1;
    visibility: visible;
}

.section-title {
    font-size: clamp(1.94rem, 5.36vw, 2.68rem);
    font-weight: 700;
    color: #f3f4f6;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    opacity: 0;
    transform: translateY(20px); /* Pitch-style initial position */
    /* Ensure proper flex behavior - expand downward only */
    flex-shrink: 0;
    width: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
}

.section-subtitle {
    font-size: clamp(0.98rem, 2.4vw, 1.2rem);
    color: #9ca3af;
    margin-bottom: 2.5rem;
    line-height: 1.6;
    opacity: 0;
    transform: translateY(100px); /* Pitch-style dramatic initial position */
    /* Ensure proper flex behavior - expand downward only */
    flex-shrink: 0;
    width: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
}

.section-cta {
    opacity: 0;
    transform: translateY(20px); /* Pitch-style initial position */
    /* Ensure proper flex behavior - expand downward only */
    flex-shrink: 0;
    width: 100%;
}

/* Active section animations */
.content-section.active .section-title {
    opacity: 1;
    transform: translateY(0);
}

.content-section.active .section-subtitle {
    opacity: 1;
    transform: translateY(0);
}

.content-section.active .section-cta {
    opacity: 1;
    transform: translateY(0);
}

/* Exit animations - Apple-style instant snap */
.content-section.exiting .section-title {
    opacity: 0;
    transform: translateY(-40px); /* Apple-style snappy movement */
}

.content-section.exiting .section-heading {
    opacity: 0;
    transform: translateX(-50%) translateY(-40px); /* Apple-style snappy movement */
}

.content-section.exiting .section-subtitle {
    opacity: 0;
    transform: translateY(-25px);
}

.content-section.exiting .section-cta {
    opacity: 0;
    transform: translateY(-25px);
}


/* Scroll indicator */
.scroll-indicator {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    z-index: 1001;
    opacity: 0;
    pointer-events: auto;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

/* Animation class that can be added manually */
.scroll-indicator.animate-in {
    animation: fadeInUp 1s ease forwards;
}


/* Hidden state for scroll indicator */
.scroll-indicator.hidden {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
    pointer-events: none;
}

.scroll-indicator .mouse {
    width: 24px;
    height: 40px;
    border: 1.6px solid rgba(255, 255, 255, 0.8);
    border-radius: 20px;
    position: relative;
}

.scroll-indicator .mouse::before {
    content: '';
    width: 4.8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 2.4px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll-wheel 2s infinite;
}

.scroll-indicator .scroll-text {
    font-size: 0.6rem;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes scroll-wheel {
    0% { top: 10px; opacity: 1; }
    50% { top: 20px; opacity: 0.5; }
    100% { top: 10px; opacity: 1; }
}

/* Sound toggle button */
#sound-toggle-btn {
    transition: all 0.2s ease;
    padding: 4px;
    border-radius: 4px;
}

#sound-toggle-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: scale(1.1);
}

#sound-toggle-btn.touch-active {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(0.95);
}

#sound-toggle-icon {
    transition: opacity 0.2s ease;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}


/* Credits Footer - Same positioning as hiw-text-container */
.credits-footer {
    position: fixed;
    bottom: clamp(30px, 6vh, 60px);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    z-index: 1001;
    pointer-events: auto;

    /* Mobile safe area support */
    padding-bottom: env(safe-area-inset-bottom);
}

.credits-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding-top: clamp(0.75rem, 2vw, 1.5rem);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    max-width: 600px;
}

.cosmix-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-text {
    font-size: 1.1rem;
    font-weight: 700;
    color: #f3f4f6;
    line-height: 1;
}

.copyright {
    font-size: 0.85rem;
    color: #6b7280;
    margin: 0;
    text-align: center;
    line-height: 1.4;
}


/* Navigation dots */
.nav-dots {
    position: fixed;
    right: 24px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 1001;
    pointer-events: auto;
}

.nav-dot {
    width: 9.6px;
    height: 9.6px;
    border-radius: 50%;
    border: 1.6px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.nav-dot:hover,
.nav-dot.touch-active {
    border-color: rgba(255, 255, 255, 0.8);
    transform: scale(1.1);
}

.nav-dot.active {
    background: #2563eb;
    border-color: #2563eb;
    transform: scale(1.2);
}

/* Ripple effect for active navigation dot */
.nav-dot.active::before {
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    background: inherit;
    border-radius: 50%;
    z-index: -1;
    animation: nav-ripple 2.5s ease-out;
}

@keyframes nav-ripple {
    from {
        opacity: 1;
        transform: scale(0);
    }
    to {
        opacity: 0;
        transform: scale(6);
    }
}

.nav-dot::after {
    content: attr(data-title);
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.nav-dot:hover::after,
.nav-dot.touch-active::after {
    opacity: 1;
}

/* Spacer sections for scroll height */
#spacer-sections {
    position: relative;
    width: 100%;
    pointer-events: none;
}

.scroll-spacer {
    width: 100%;
    height: 100vh;
    position: relative;
}

/* Pitch-style text classes for page 2 - left-aligned title */
.section-heading {
    position: absolute;
    top: 15%;
    left: 50%;
    transform: translateX(-50%) translateY(20px); /* Start at top with slight offset */
    font-size: clamp(1.44rem, 3.36vw, 1.9rem);
    font-weight: 700;
    color: #9ca3af;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    text-align: left;
    opacity: 0;
    width: 100%;
    max-width: 1120px; /* Same as screen-max-width */
    padding: 0 2rem;
}

/* Adjust section-heading for short screens */
@media (max-height: 700px) {
    .section-heading {
        top: 12%; /* Move down slightly for short screens */
    }
}

@media (max-height: 600px) {
    .section-heading {
        top: 10%; /* Move down further for very short screens */
    }
}

@media (max-height: 500px) {
    .section-heading {
        top: 13%; /* Move DOWN (away from nav bar) for short screens */
        font-size: clamp(1.2rem, 3vw, 1.6rem) !important; /* Decrease size for short screens */
    }
}

/* Additional adjustment for very short screens */
@media (max-height: 400px) {
    .section-heading {
        top: 16%; /* Move DOWN further for very short screens */
        font-size: clamp(1.0rem, 2.5vw, 1.4rem) !important; /* Even smaller for very short screens */
    }
}

@media (max-height: 300px) {
    .section-heading {
        top: 19%; /* Move DOWN further for very short screens */
        font-size: clamp(0.8rem, 2.0vw, 1.2rem) !important; /* Even smaller for very short screens */
    }
}

.hiw-text-container {
    position: fixed;
    bottom: 5rem;
    right: 5rem;
    width: 100%;
    max-width: 600px;
    z-index: 9999;
    pointer-events: auto !important;
}

/* Special container for section 5 PIXEL BLOCKS button - positioned higher */
.hiw-text-container-compact {
    position: fixed;
    bottom: 8rem; /* Position higher than regular hiw-text-container */
    right: 5rem;
    width: 100%;
    max-width: 600px;
    z-index: 9999;
    pointer-events: auto !important;
    text-align: right; /* Align text to the right */
}

.hiw-text-container-compact .hiw-text {
    text-align: right; /* Ensure the hiw-text element itself is right-aligned */
}

/* Ensure left button section stays above credits footer */
.left-button-section {
    z-index: 1002; /* Above credits footer (1001) */
}

.hiw-text {
    position: relative;
    color: #f3f4f6;
    font-size: clamp(1rem, 2.5vh, 1.25rem); /* Changed from vw to vh - responsive to screen height */
    font-weight: 500;
    line-height: 1.6;
    opacity: 0;
    transform: translateY(100px);
    cursor: pointer;
    text-decoration: none;
    z-index: 9999;
    transition: color 0.3s ease;
    display: inline-block;
    padding: 4px 8px;
    pointer-events: auto !important;
}

/* Back button text class - same as hiw-text but without responsive font-size */
.back-btn-text {
    position: relative;
    color: #f3f4f6;
    font-size: 0.875rem; /* Fixed size - no responsive scaling */
    font-weight: 500;
    line-height: 1.6;
    cursor: pointer;
    text-decoration: none;
    z-index: 9999;
    transition: color 0.3s ease;
    display: inline-block;
    padding: 4px 8px;
    pointer-events: auto !important;
}

.back-btn-text::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(45deg, #2563eb, #60a5fa);
    z-index: -1;
    transition: width 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.back-btn-text:hover::after,
.back-btn-text.touch-active::after {
    width: 100%;
}

.back-btn-text:hover,
.back-btn-text.touch-active {
    color: #ffffff;
}

/* Interactive scrollable subtitle for subpage */
.section-subtitle.interactive {
    cursor: pointer;
    /* Removed max-height limit to allow full height stretching */
    overflow-y: auto; /* Enable vertical scrolling */
    position: relative;
    z-index: 10;
    pointer-events: auto !important; /* Make it interactive through overlay */
    transition: color 0.3s ease;
    /* Hide scrollbar completely */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

.section-subtitle.interactive::-webkit-scrollbar {
    display: none; /* WebKit browsers */
}

.section-subtitle.interactive:hover {
    color: #ffffff; /* Subtle color change on hover */
}

/* Ensure text wrapping and hyphenation for scrollable content */
.section-subtitle.interactive {
    word-wrap: break-word;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
}

.hiw-text::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(45deg, #2563eb, #60a5fa);
    z-index: -1;
    transition: width 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hiw-text:hover::after,
.hiw-text.touch-active::after {
    width: 100%;
}

.hiw-text:hover,
.hiw-text.touch-active {
    color: #ffffff;
}

/* Disable CSS transitions for connect buttons to prevent conflicts with GSAP animations */
#twitter-btn,
#gitbook-btn,
#telegram-btn {
    transition: none !important;
}

/* Restore hover animation for connect buttons ::after pseudo-element */
#twitter-btn::after,
#gitbook-btn::after,
#telegram-btn::after {
    transition: width 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

.hiw-text2 {
    color: #9ca3af;
    font-size: clamp(0.8rem, 2.0vw, 1.0rem);
    font-weight: 500;
    line-height: 1.6;
    opacity: 0;
    transform: translateY(100px);
}

.text-white-highlight {
    color: #f3f4f6;
    font-weight: 600;
}

/* Adjust text-white-highlight for short screens - EXCEPT for back button */
@media (max-height: 400px) {
    .text-white-highlight {
        font-size: 0.9rem !important; /* Smaller font for 400px screens */
    }

    /* Override for back button specifically */
    #back-btn .text-white-highlight {
        font-size: 0.8rem !important; /* Match back-btn-text size */
    }
}

@media (max-height: 300px) {
    .text-white-highlight {
        font-size: 0.9rem !important; /* Even smaller font for 300px screens */
    }

    /* Override for back button specifically */
    #back-btn .text-white-highlight {
        font-size: 0.7rem !important; /* Match back-btn-text size */
    }
}

/* Ensure __BACK button stays consistent on short screens */
@media (max-height: 400px) {
    .back-btn-text {
        font-size: 0.7rem !important; /* Slightly smaller for 400px screens */
    }
}

@media (max-height: 300px) {
    .back-btn-text {
        font-size: 0.7rem !important; /* Even smaller for 300px screens */
    }
}

.common-padding {
    padding: 5rem 2.5rem;
    position: relative;
}

.screen-max-width {
    max-width: 1120px;
    margin: 0 auto;
    position: relative;
}

/* Full width navbar on all screens - override screen-max-width constraint */
header nav.screen-max-width {
    max-width: 100%;
    padding: 0 2rem;
}

@media (min-width: 1440px) {
    header nav.screen-max-width {
        padding: 0 4rem;
    }
}

@media (min-width: 1920px) {
    header nav.screen-max-width {
        padding: 0 6rem;
    }
}

@media (min-width: 2560px) {
    header nav.screen-max-width {
        padding: 0 8rem;
    }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .nav-dots {
        right: 12px;
        gap: 8px;
    }

    .nav-dot {
        width: 8px;
        height: 8px;
    }

    .nav-dot::after {
        right: 16px;
        font-size: 0.52rem;
    }

    .scroll-indicator {
        bottom: 20px;
    }

    .hero-content.long-content {
        padding-top: 30px !important; /* Keep consistent with desktop - pin below nav bar */
        max-height: calc(100vh - 160px);
    }

    .hero-content {
        padding: 1rem;
        max-width: 95vw;
    }

    .hiw-text-container {
        position: fixed;
        right: 1rem;
        bottom: 3rem;
        max-width: 90%;
    }

    .hiw-text-container-compact {
        position: fixed;
        right: 1rem;
        bottom: 8rem; /* Keep same height as desktop - don't lower on mobile */
        max-width: 90%;
    }

    /* Text wrapping for mobile - keep original position */
    .section-title {
        font-size: clamp(1.5rem, 6vw, 2rem);
        word-wrap: break-word;
        overflow-wrap: break-word;
        -webkit-hyphens: auto;
        -ms-hyphens: auto;
        hyphens: auto;
    }

    .section-subtitle {
        font-size: clamp(0.85rem, 3.5vw, 1rem);
        word-wrap: break-word;
        overflow-wrap: break-word;
        -webkit-hyphens: auto;
        -ms-hyphens: auto;
        hyphens: auto;
    }
}

/* Ultra-mobile (small phones) adjustments */
@media (max-width: 390px) {
    .hiw-text-container {
        position: fixed;
        right: 1rem;
        bottom: 2rem;
        max-width: 85%;
    }

    .hiw-text-container-compact {
        position: fixed;
        right: 1rem;
        bottom: 8rem; /* Keep same height as desktop - don't lower on ultra-mobile */
        max-width: 85%;
    }

    /* Smaller text for very small phones - keep original position */
    .section-title {
        font-size: clamp(1.3rem, 7vw, 1.8rem);
        word-wrap: break-word;
        overflow-wrap: break-word;
        -webkit-hyphens: auto;
        -ms-hyphens: auto;
        hyphens: auto;
    }

    .section-subtitle {
        font-size: clamp(0.75rem, 4vw, 0.95rem);
        word-wrap: break-word;
        overflow-wrap: break-word;
        -webkit-hyphens: auto;
        -ms-hyphens: auto;
        hyphens: auto;
    }
}

/* Landscape mobile orientation */
@media (max-width: 768px) and (orientation: landscape) {
    .hiw-text-container {
        position: fixed;
        bottom: 2rem;
    }
}

/* Adjust hiw-text-container for short screens */
@media (max-height: 700px) {
    .hiw-text-container {
        position: fixed;
        bottom: 4rem; /* Move up slightly for short screens */
    }

    .hiw-text-container-compact {
        position: fixed;
        bottom: 7rem; /* Move up slightly for short screens */
    }
}

@media (max-height: 600px) {
    .hiw-text-container {
        position: fixed;
        bottom: 3rem; /* Move up further for very short screens */
    }

    .hiw-text-container-compact {
        position: fixed;
        bottom: 7rem; /* Less aggressive positioning for 600px height */
    }
}

@media (max-height: 500px) {
    .hiw-text-container {
        position: fixed;
        bottom: 2rem; /* Position higher for extremely short screens */
    }

    .hiw-text-container-compact {
        position: fixed;
        bottom: 6.5rem; /* Less aggressive positioning for 500px height */
    }
}

/* Credits Footer Height-based Responsive Breakpoints */
@media (max-height: 500px) {
    .credits-footer {
        gap: 0.75rem;
    }

    .cosmix-logo img {
        width: 24px;
        height: 24px;
    }

    .logo-text {
        font-size: 1rem;
    }

    .copyright {
        font-size: 0.75rem;
    }
}

@media (max-height: 450px) {
    .credits-footer {
        gap: 0.6rem;
    }

    .cosmix-logo img {
        width: 22px;
        height: 22px;
    }

    .logo-text {
        font-size: 0.95rem;
    }

    .copyright {
        font-size: 0.7rem;
    }
}

@media (max-height: 400px) {
    .credits-footer {
        gap: 0.5rem;
    }

    .cosmix-logo img {
        width: 20px;
        height: 20px;
    }

    .logo-text {
        font-size: 0.9rem;
    }

    .copyright {
        font-size: 0.65rem;
    }
}

@media (max-height: 350px) {
    .credits-footer {
        gap: 0.4rem;
    }

    .cosmix-logo img {
        width: 18px;
        height: 18px;
    }

    .logo-text {
        font-size: 0.85rem;
    }

    .copyright {
        font-size: 0.6rem;
    }
}

@media (max-height: 300px) {
    .credits-footer {
        gap: 0.3rem;
    }

    .cosmix-logo img {
        width: 16px;
        height: 16px;
    }

    .logo-text {
        font-size: 0.8rem;
    }

    .copyright {
        font-size: 0.55rem;
    }
}

@media (max-height: 250px) {
    .credits-footer {
        gap: 0.25rem;
    }

    .cosmix-logo img {
        width: 14px;
        height: 14px;
    }

    .logo-text {
        font-size: 0.75rem;
    }

    .copyright {
        font-size: 0.5rem;
    }
}

@media (max-height: 200px) {
    .credits-footer {
        gap: 0.2rem;
    }

    .cosmix-logo img {
        width: 12px;
        height: 12px;
    }

    .logo-text {
        font-size: 0.7rem;
    }

    .copyright {
        font-size: 0.45rem;
    }
}


/* Mobile-specific white edge prevention */
@media (max-width: 768px) {
    body, html {
        background: #000000;
        -webkit-background-size: cover;
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
    }

    /* Prevent any scrollbars from showing white */
    ::-webkit-scrollbar {
        display: none;
        width: 0;
        height: 0;
    }

    html {
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE/Edge */
    }

    /* Additional overlay for mobile browsers */
    body::after {
        content: '';
        position: fixed;
        top: -100px;
        left: -100px;
        right: -100px;
        bottom: -100px;
        background: #000000;
        z-index: -9998;
        pointer-events: none;
    }
}

/* Android-specific fixes */
@media (max-width: 768px) and (min-resolution: 96dpi) {
    body, html {
        background: #000000 !important;
        -webkit-tap-highlight-color: transparent;
        -webkit-touch-callout: none;
        -webkit-user-select: none;
        user-select: none;
    }
}
