/* ========================================
   TrackSide Cafe — Custom Styles
   ======================================== */

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    font-family: 'Outfit', sans-serif;
    background-color: #0B1D3A;
    color: white;
    overflow-x: hidden;
}

/* ========================================
   Geometric Background Shapes
   ======================================== */
.geo-circle {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}

.circle-1 {
    width: 500px;
    height: 500px;
    background: rgba(52, 211, 153, 0.04);
    top: -100px;
    right: -100px;
    animation: float-slow 20s ease-in-out infinite;
}

.circle-2 {
    width: 300px;
    height: 300px;
    background: rgba(52, 211, 153, 0.03);
    bottom: 20%;
    left: -50px;
    animation: float-slow 15s ease-in-out infinite reverse;
}

.geo-square {
    position: fixed;
    pointer-events: none;
    z-index: 0;
}

.square-1 {
    width: 120px;
    height: 120px;
    background: rgba(52, 211, 153, 0.05);
    top: 40%;
    right: 5%;
    transform: rotate(45deg);
    animation: spin-slow 25s linear infinite;
}

.geo-triangle {
    position: fixed;
    pointer-events: none;
    z-index: 0;
}

.triangle-1 {
    width: 0;
    height: 0;
    border-left: 80px solid transparent;
    border-right: 80px solid transparent;
    border-bottom: 140px solid rgba(52, 211, 153, 0.04);
    top: 60%;
    left: 3%;
    animation: float-slow 18s ease-in-out infinite;
}

.geo-rect {
    position: fixed;
    pointer-events: none;
    z-index: 0;
}

.rect-1 {
    width: 200px;
    height: 60px;
    background: rgba(52, 211, 153, 0.03);
    border-radius: 30px;
    top: 75%;
    right: 10%;
    transform: rotate(-15deg);
    animation: float-slow 22s ease-in-out infinite reverse;
}

/* ========================================
   Animations
   ======================================== */
@keyframes float-slow {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-20px) rotate(2deg); }
    66% { transform: translateY(10px) rotate(-1deg); }
}

@keyframes spin-slow {
    from { transform: rotate(45deg); }
    to { transform: rotate(405deg); }
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
}

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px) rotate(45deg); }
    50% { transform: translateY(-10px) rotate(48deg); }
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

.animate-float-delayed {
    animation: float-delayed 5s ease-in-out infinite;
}

/* ========================================
   Reveal on Scroll
   ======================================== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal.visible:nth-child(2) { transition-delay: 100ms; }
.reveal.visible:nth-child(3) { transition-delay: 200ms; }
.reveal.visible:nth-child(4) { transition-delay: 300ms; }

/* ========================================
   Navbar Scroll State
   ======================================== */
nav.scrolled {
    background: rgba(7, 18, 38, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* ========================================
   Mobile Menu
   ======================================== */
.mobile-link {
    position: relative;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: #34D399;
    transition: width 0.3s ease;
}

.mobile-link:hover::after {
    width: 100%;
}

#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

/* ========================================
   Smooth Image Loading
   ======================================== */
img {
    background-color: rgba(255, 255, 255, 0.03);
}

/* ========================================
   Selection Color
   ======================================== */
::selection {
    background: rgba(52, 211, 153, 0.3);
    color: white;
}

/* ========================================
   Scrollbar
   ======================================== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #0B1D3A;
}

::-webkit-scrollbar-thumb {
    background: rgba(52, 211, 153, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(52, 211, 153, 0.5);
}

/* ========================================
   Responsive Adjustments
   ======================================== */
@media (max-width: 768px) {
    .circle-1 {
        width: 250px;
        height: 250px;
    }
    
    .circle-2 {
        width: 150px;
        height: 150px;
    }
    
    .square-1 {
        width: 60px;
        height: 60px;
    }
    
    .triangle-1 {
        border-left-width: 40px;
        border-right-width: 40px;
        border-bottom-width: 70px;
    }
    
    .rect-1 {
        width: 100px;
        height: 30px;
    }
}

@media (max-width: 640px) {
    h1 {
        font-size: 2.75rem !important;
    }
    
    h2 {
        font-size: 2.25rem !important;
    }
}
