/* Import Technical Fonts - Must be at the top */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700&family=Inter:wght@400;500;600;700&family=Source+Code+Pro:wght@400;500;600&display=swap');

/* 2025 AI Technical Theme - Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Technical AI Color Palette */
    --deep-navy: #0F172A;
    --dark-gray: #1E293B;
    --medium-gray: #334155;
    --light-gray: #475569;
    --electric-blue: #0EA5E9;
    --electric-blue-dark: #0284C7;
    --electric-blue-light: #38BDF8;
    --emerald-green: #10B981;
    --emerald-green-dark: #059669;
    --emerald-green-light: #34D399;
    --bright-orange: #F97316;
    --bright-orange-dark: #EA580C;
    --bright-orange-light: #FB923C;
    
    /* Technical Gradients */
    --tech-gradient: linear-gradient(135deg, var(--electric-blue) 0%, var(--emerald-green) 100%);
    --tech-gradient-dark: linear-gradient(135deg, var(--electric-blue-dark) 0%, var(--emerald-green-dark) 100%);
    --tech-gradient-orange: linear-gradient(135deg, var(--bright-orange) 0%, var(--electric-blue) 100%);
    --neural-gradient: linear-gradient(135deg, var(--electric-blue) 0%, var(--emerald-green) 50%, var(--bright-orange) 100%);
    
    /* Background & Surface Colors */
    --bg-primary: var(--deep-navy);
    --bg-secondary: var(--dark-gray);
    --bg-tertiary: var(--medium-gray);
    --surface-glass: rgba(30, 41, 59, 0.8);
    --surface-glass-light: rgba(248, 250, 252, 0.05);
    
    /* Text Colors */
    --text-primary: #FFFFFF;
    --text-secondary: #F8FAFC;
    --text-muted: #CBD5E1;
    --text-accent: var(--bright-orange);
    
    /* Border & Shadow Colors */
    --border-primary: rgba(71, 85, 105, 0.3);
    --border-accent: var(--electric-blue);
    --shadow-primary: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-accent: 0 0 20px rgba(14, 165, 233, 0.3);
    --shadow-orange: 0 0 20px rgba(249, 115, 22, 0.3);
    
    /* Animation & Transition */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* Base Typography */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-weight: 400;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    overflow-x: hidden;
    /* Account for fixed header */
    padding-top: 80px;
    /* Prevent mobile Safari bounce when menu is open */
    -webkit-overflow-scrolling: touch;
}

/* Fix mobile viewport and prevent zoom */
html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    overflow-x: hidden;
    /* Hardware acceleration for smooth mobile performance */
    -webkit-transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    -webkit-perspective: 1000;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 600;
}

code, pre {
    font-family: 'Source Code Pro', 'Fira Code', monospace;
    font-weight: 500;
}

/* Animated Grid Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(14, 165, 233, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(14, 165, 233, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: grid-move 20s linear infinite;
    pointer-events: none;
    z-index: -1;
}

@keyframes grid-move {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* Floating Particles */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: var(--electric-blue);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.particle:nth-child(2) { animation-delay: 1s; }
.particle:nth-child(3) { animation-delay: 2s; }
.particle:nth-child(4) { animation-delay: 3s; }
.particle:nth-child(5) { animation-delay: 4s; }

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); opacity: 0; }
    50% { transform: translateY(-100px) rotate(180deg); opacity: 1; }
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
    box-sizing: border-box;
}

/* Large Desktop Spacing */
@media (min-width: 1400px) {
    .container {
        max-width: 1600px;
        padding: 0 3rem;
    }
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-primary);
    z-index: 1000;
    padding: 1rem 0;
    /* Safe area for mobile devices */
    padding-top: max(1rem, env(safe-area-inset-top));
}

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

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nav-brand img {
    width: 40px;
    height: 40px;
}

.nav-brand h1 {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--tech-gradient-orange);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 20px var(--shadow-orange);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin-right: 200px; /* Prevent overlap with patent badge */
}

/* Responsive margin for smaller desktop screens */
@media (max-width: 1400px) {
    .nav-links {
        margin-right: 180px;
    }
}

@media (max-width: 1200px) {
    .nav-links {
        margin-right: 160px;
    }
}

/* Tablet - Ensure desktop nav is visible */
@media (max-width: 900px) and (min-width: 601px) {
    .nav-links {
        margin-right: 140px;
        gap: 1.5rem;
    }
    
    .nav-links a {
        font-size: 0.9rem;
    }
    
    /* Ensure hamburger is hidden on tablets */
    .hamburger-button {
        display: none !important;
    }
}

/* Ensure desktop nav is visible on larger screens */
@media (min-width: 601px) {
    .nav-links {
        display: flex !important;
    }
    
    .hamburger-button {
        display: none !important;
    }
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition-normal);
    position: relative;
}

.nav-links a:hover {
    color: var(--electric-blue);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--electric-blue);
    transition: var(--transition-normal);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Patent Pending Badge Container */
.patent-badge-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

/* Patent Badge Main Styling */
.patent-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
    color: #000000;
    padding: 10px 16px;
    border-radius: 25px;
    font-family: 'JetBrains Mono', 'Courier New', monospace;
    cursor: pointer;
    
    /* Enhanced shadow for prominence */
    box-shadow: 
        0 0 20px rgba(245, 158, 11, 0.4),
        0 4px 12px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    
    /* Smooth animations */
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* GPU acceleration for smooth animations */
    will-change: transform;
    backface-visibility: hidden;
    
    /* Subtle pulse animation */
    animation: patentPulse 3s ease-in-out infinite;
}

/* Badge Icon */
.badge-icon {
    font-size: 16px;
    color: #000000;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

/* Badge Content */
.badge-content {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.badge-main {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-number {
    font-size: 9px;
    font-weight: 500;
    opacity: 0.85;
    margin-top: 1px;
}

/* Patent Pulse Animation */
@keyframes patentPulse {
    0%, 100% { 
        box-shadow: 
            0 0 20px rgba(245, 158, 11, 0.4),
            0 4px 12px rgba(0, 0, 0, 0.3);
    }
    50% { 
        box-shadow: 
            0 0 25px rgba(245, 158, 11, 0.6),
            0 6px 16px rgba(0, 0, 0, 0.4);
    }
}

/* Hover Effects */
.patent-badge:hover {
    transform: translateY(-2px) scale(1.02) rotate(-1deg);
    box-shadow: 
        0 0 30px rgba(245, 158, 11, 0.6),
        0 8px 20px rgba(0, 0, 0, 0.4);
}

.patent-badge:active {
    transform: translateY(0) scale(1);
    transition: all 0.1s ease;
}

/* Focus for keyboard navigation */
.patent-badge:focus {
    outline: 2px solid #0EA5E9;
    outline-offset: 2px;
}

/* Tooltip removed */

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    background: linear-gradient(135deg, var(--deep-navy) 0%, var(--dark-gray) 100%);
    overflow: hidden;
    padding: 8rem 0;
}

/* Large Desktop Hero Spacing */
@media (min-width: 1400px) {
    .hero {
        padding: 10rem 0;
        min-height: 110vh;
    }
}

.hero-content {
    text-align: center;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    padding: 0 2rem;
}

/* Large Desktop Hero Content */
@media (min-width: 1400px) {
    .hero-content {
        max-width: 1400px;
        padding: 0 3rem;
    }
}

.hero h1 {
    font-size: clamp(3.5rem, 9vw, 6rem);
    font-weight: 700;
    margin-bottom: 3rem;
    background: var(--tech-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: fadeInUp 1s ease-out;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: clamp(1.5rem, 4vw, 2.25rem);
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-weight: 500;
    animation: fadeInUp 1s ease-out 0.2s both;
    line-height: 1.3;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 5rem;
    line-height: 1.8;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 1s ease-out 0.4s both;
}

/* Metrics Row */
.metrics {
    display: flex;
    justify-content: center;
    gap: 5rem;
    margin-bottom: 6rem;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease-out 0.6s both;
    padding: 0 2rem;
}

/* Large Desktop Metrics Spacing */
@media (min-width: 1400px) {
    .metrics {
        gap: 6rem;
        margin-bottom: 7rem;
        padding: 0 3rem;
    }
}

.metric {
    text-align: center;
}

.metric-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--electric-blue);
    font-family: 'JetBrains Mono', monospace;
    line-height: 1.2;
}

.metric-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1.3;
}

/* CTA Buttons */
.cta-buttons {
    display: flex;
    gap: 2.5rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease-out 0.8s both;
    margin-top: 2rem;
}

.btn-primary {
    background: var(--tech-gradient-orange);
    color: white;
    padding: 1.25rem 2.5rem;
    border: none;
    border-radius: 12px;
    font-size: 1.25rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-normal);
    text-decoration: none;
    display: inline-block;
    box-shadow: var(--shadow-orange);
    min-width: 250px;
    text-align: center;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 50px rgba(249, 115, 22, 0.5);
}

.btn-secondary {
    background: transparent;
    color: var(--electric-blue);
    padding: 1.25rem 2.5rem;
    border: 2px solid var(--electric-blue);
    border-radius: 12px;
    font-size: 1.25rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-normal);
    text-decoration: none;
    display: inline-block;
    backdrop-filter: blur(10px);
    min-width: 250px;
    text-align: center;
}

.btn-secondary:hover {
    background: var(--electric-blue);
    color: white;
    transform: translateY(-3px);
}

/* Sections */
.section {
    padding: 6rem 0;
    position: relative;
}

/* Large Desktop Section Spacing */
@media (min-width: 1400px) {
    .section {
        padding: 8rem 0;
    }
}

.section-title {
    text-align: center;
    margin-bottom: 4rem;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 700;
    background: var(--tech-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* Large Desktop Typography Spacing */
@media (min-width: 1400px) {
    .section-title {
        margin-bottom: 5rem;
        font-size: clamp(3rem, 6vw, 4rem);
    }
    
    .section-subtitle {
        margin-bottom: 6rem;
        font-size: 1.5rem;
        max-width: 800px;
    }
}

/* Features Grid - Updated 2025-01-11 18:00 */
.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2.5rem;
    margin-top: 5rem;
    width: 100%;
    min-width: 0; /* Allow grid to shrink */
    overflow-x: visible; /* Remove horizontal scroll */
    padding-bottom: 1rem; /* Space for scrollbar */
    /* Cache buster - force reload */
    content: "";
}

/* Large Desktop Features Spacing */
@media (min-width: 1400px) {
    .features-grid {
        gap: 3rem;
        margin-top: 6rem;
    }
}

.feature-card {
    background: var(--surface-glass);
    border: 1px solid var(--border-primary);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    transition: var(--transition-normal);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-primary);
    position: relative;
    overflow: hidden;
    min-width: 250px; /* Prevent cards from becoming too narrow */
    width: 100%;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(14, 165, 233, 0.1), transparent);
    transition: var(--transition-slow);
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--electric-blue);
    box-shadow: var(--shadow-accent);
}

.feature-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem;
    background: var(--tech-gradient);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-muted);
    line-height: 1.6;
}

/* API Section */
.api {
    background: var(--bg-secondary);
    padding: 5rem 0;
}

.api-demo {
    background: var(--dark-gray);
    border: 1px solid var(--border-primary);
    border-radius: 12px;
    padding: 2rem;
    margin: 2rem auto;
    overflow-x: auto;
    position: relative;
    max-width: 100%;
    text-align: center;
}

.api-demo::before {
    content: 'JavaScript';
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--electric-blue);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.api-demo pre {
    color: var(--text-primary);
    font-size: 0.875rem;
    line-height: 1.6;
    margin: 0;
    text-align: left;
    display: inline-block;
    max-width: 100%;
}

.api-demo .comment {
    color: var(--emerald-green);
}

.api-demo .keyword {
    color: var(--electric-blue);
}

.api-demo .string {
    color: var(--bright-orange);
}

.api-demo .number {
    color: var(--emerald-green);
}

/* Sports Universe */
.sports-universe {
    text-align: center;
    margin: 4rem 0;
}

.universe-container {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 0 auto;
    transform-style: preserve-3d;
    animation: rotate 20s linear infinite;
}

.universe-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: var(--tech-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-accent);
    animation: pulse 2s ease-in-out infinite;
    padding: 10px;
}

.universe-center img {
    width: 60px;
    height: 60px;
    transition: var(--transition-normal);
    filter: drop-shadow(0 0 15px rgba(14, 165, 233, 0.3));
}

.universe-center:hover img {
    transform: scale(1.1);
    filter: drop-shadow(0 0 20px rgba(14, 165, 233, 0.6));
}

.sport-icon {
    position: absolute;
    width: 40px;
    height: 40px;
    background: var(--surface-glass);
    border: 2px solid var(--electric-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-primary);
}

.sport-icon:nth-child(2) { transform: rotate(0deg) translateX(120px) rotate(0deg); }
.sport-icon:nth-child(3) { transform: rotate(45deg) translateX(120px) rotate(-45deg); }
.sport-icon:nth-child(4) { transform: rotate(90deg) translateX(120px) rotate(-90deg); }
.sport-icon:nth-child(5) { transform: rotate(135deg) translateX(120px) rotate(-135deg); }
.sport-icon:nth-child(6) { transform: rotate(180deg) translateX(120px) rotate(-180deg); }
.sport-icon:nth-child(7) { transform: rotate(225deg) translateX(120px) rotate(-225deg); }
.sport-icon:nth-child(8) { transform: rotate(270deg) translateX(120px) rotate(-270deg); }
.sport-icon:nth-child(9) { transform: rotate(315deg) translateX(120px) rotate(-315deg); }

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Contact Section */
.contact {
    background: var(--bg-secondary);
    padding: 5rem 0;
}

.contact-form {
    max-width: 500px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: var(--surface-glass);
    border: 1px solid var(--border-primary);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition-normal);
    backdrop-filter: blur(10px);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--electric-blue);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

/* Footer */
.footer {
    background: var(--deep-navy);
    padding: 3rem 0 2rem;
    border-top: 1px solid var(--border-primary);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.footer-section p,
.footer-section a {
    color: var(--text-muted);
    text-decoration: none;
    line-height: 1.6;
    transition: var(--transition-normal);
}

.footer-section a:hover {
    color: var(--electric-blue);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-primary);
    color: var(--text-muted);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Navigation Overlay - HIGHEST z-index */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.98);
    z-index: 9999; /* Higher than patent badge */
    backdrop-filter: blur(12px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-nav-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Mobile Navigation Menu */
.mobile-nav-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #0F172A;
    z-index: 10000; /* Highest priority */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-nav-menu.active {
    transform: translateX(0);
}

/* Hamburger Button - Always on top */
.hamburger-button {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10001; /* Always on top */
    background: rgba(59, 130, 246, 0.9);
    border: none;
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all 0.3s ease;
}

.hamburger-button:hover {
    background: rgba(59, 130, 246, 1);
    transform: scale(1.05);
}

/* Mobile Navigation Items */
.mobile-nav-menu .nav-item {
    font-family: 'Inter', sans-serif;
    font-size: 24px;
    font-weight: 500;
    color: white;
    text-decoration: none;
    padding: 16px 32px;
    border-radius: 12px;
    min-width: 200px;
    text-align: center;
    transition: all 0.3s ease;
}

.mobile-nav-menu .nav-item:hover,
.mobile-nav-menu .nav-item:focus {
    background: rgba(59, 130, 246, 0.1);
    color: #3B82F6;
    transform: scale(1.05);
}

/* Close Button */
.close-button {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.close-button:hover {
    color: #3B82F6;
    transform: scale(1.1);
}

/* Mobile Responsiveness - Only show hamburger on small screens */
@media (max-width: 600px) {
    /* Show hamburger button on small mobile */
    .hamburger-button {
        display: flex;
    }
    
    /* Hide desktop nav links on small mobile */
    .nav-links {
        display: none;
    }
    
    /* Header Mobile Adjustments */
    .header {
        padding: 1.5rem 0;
        padding-top: 2rem; /* Extra top padding for mobile */
    }
    
    /* Patent Badge Mobile Adjustments - Hide when menu is open */
    .patent-badge-container {
        top: 15px;
        right: 15px;
        left: auto;
        transform: scale(0.85);
        transition: all 0.3s ease;
    }
    
    .patent-badge-container.mobile-menu-open {
        opacity: 0;
        visibility: hidden;
        transform: translateX(-100px) scale(0.85);
    }
    
    .patent-badge {
        /* Larger touch target for mobile */
        min-height: 44px;
        padding: 10px 16px;
    }
    
    .badge-main { 
        font-size: 9px; 
    }
    
    .badge-number { 
        font-size: 7px; 
    }
    
    .nav {
        flex-direction: row; /* Keep horizontal on mobile */
        justify-content: space-between;
        align-items: center;
        gap: 0.5rem;
    }
    
    .nav-brand h1 {
        font-size: 1.2rem; /* Smaller on mobile */
    }
    
    /* Body mobile adjustments */
    body {
        padding-top: 120px; /* More padding on mobile for header */
    }
    
    body.mobile-menu-open {
        position: fixed;
        width: 100%;
        top: 0;
        left: 0;
        overflow: hidden;
    }
    
    .hero {
        padding: 3rem 1rem 2rem 1rem; /* Extra top padding */
        text-align: center;
        margin-top: 1rem; /* Additional margin for mobile */
    }
    
    .metrics {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
        max-width: 100%;
    }
    
    /* Performance optimization for mobile */
    .patent-badge {
        animation: none; /* Remove pulse animation on mobile for better performance */
    }
    
    /* Hardware acceleration for smooth mobile performance */
    * {
        -webkit-transform: translateZ(0);
        -webkit-backface-visibility: hidden;
        -webkit-perspective: 1000;
    }
    
    .api-demo {
        font-size: 0.75rem;
        padding: 1rem;
        margin: 1rem auto;
        text-align: center;
    }
    
    .universe-container {
        width: 250px;
        height: 250px;
    }
    
    .sport-icon:nth-child(2) { transform: rotate(0deg) translateX(100px) rotate(0deg); }
    .sport-icon:nth-child(3) { transform: rotate(45deg) translateX(100px) rotate(-45deg); }
    .sport-icon:nth-child(4) { transform: rotate(90deg) translateX(100px) rotate(-90deg); }
    .sport-icon:nth-child(5) { transform: rotate(135deg) translateX(100px) rotate(-135deg); }
    .sport-icon:nth-child(6) { transform: rotate(180deg) translateX(100px) rotate(-180deg); }
    .sport-icon:nth-child(7) { transform: rotate(225deg) translateX(100px) rotate(-225deg); }
    .sport-icon:nth-child(8) { transform: rotate(270deg) translateX(100px) rotate(-270deg); }
    .sport-icon:nth-child(9) { transform: rotate(315deg) translateX(100px) rotate(-315deg); }
}

/* Large Desktop - Keep 4 columns (1200px to 1400px) */
@media (max-width: 1400px) and (min-width: 1200px) {
    .features-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 2rem;
    }
}

/* Desktop - 3 columns (13-15" laptops) */
@media (max-width: 1200px) and (min-width: 900px) {
    .features-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
}

/* Large Tablet - 2 columns (8-10" tablets) */
@media (max-width: 900px) and (min-width: 600px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
        margin-top: 4rem;
    }
    
    .feature-card {
        min-width: 250px; /* Ensure cards don't get too narrow */
        padding: 1.75rem;
    }
}

/* Medium Mobile - 2 columns (6-7" phones) */
@media (max-width: 600px) and (min-width: 400px) {
    .container {
        padding: 0 1rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        margin-top: 3rem;
    }
    
    .feature-card {
        min-width: 180px; /* Smaller minimum width for mobile */
        padding: 1.5rem;
    }
}

/* Small Mobile - 1 column (3-5" phones) */
@media (max-width: 400px) {
    .container {
        padding: 0 0.75rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        margin-top: 2rem;
    }
    
    .feature-card {
        min-width: 100%;
        padding: 1.25rem;
        margin-bottom: 0.5rem;
    }
}

/* Extra Small Mobile - 1 column (very small phones) */
@media (max-width: 320px) {
    .container {
        padding: 0 0.5rem;
    }
    
    .features-grid {
        gap: 0.5rem;
        margin-top: 1.5rem;
    }
    
    .feature-card {
        padding: 1rem;
    }
    
    /* Header Small Mobile */
    .header {
        padding-top: 2.5rem; /* Even more top padding for small phones */
    }
    
    /* Patent Badge Small Mobile - Keep at top right */
    .patent-badge-container {
        top: 15px;
        right: 15px;
        left: auto;
        bottom: auto;
        transform: scale(0.75);
        transition: all 0.3s ease;
    }
    
    .patent-badge-container.mobile-menu-open {
        opacity: 0;
        visibility: hidden;
        transform: translateX(100px) scale(0.75);
    }
    
    /* Hamburger Button - Position next to patent badge */
    .hamburger-button {
        top: 15px;
        right: 80px; /* Position to the left of patent badge */
        width: 36px;
        height: 36px;
        font-size: 16px;
    }
    
    .patent-badge {
        /* More compact for small phones */
        padding: 8px 12px;
        border-radius: 20px;
    }
    
    .badge-main { 
        font-size: 8px; 
    }
    
    .badge-number { 
        font-size: 6px; 
    }
    
    .nav-brand h1 {
        font-size: 1rem; /* Even smaller for small phones */
    }
    
    /* Mobile menu items smaller on small phones */
    .mobile-nav-menu .nav-item {
        font-size: 20px;
        padding: 12px 24px;
        min-width: 160px;
    }
    
    /* Features grid - single column on very small screens */
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .container {
        padding: 0 0.5rem;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    /* Remove hover effects on touch devices */
    .patent-badge:hover {
        transform: none;
        box-shadow: initial;
    }
    
    .hamburger-button:hover {
        transform: none;
        background: rgba(59, 130, 246, 0.9);
    }
    
    .mobile-nav-menu .nav-item:hover {
        transform: none;
        background: transparent;
        color: white;
    }
    
    .close-button:hover {
        transform: none;
        color: white;
    }
}

/* Performance optimization for mobile - moved to main 768px breakpoint */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .btn-primary,
    .btn-secondary {
        min-width: 200px;
        width: auto;
    }
    
    /* Removed features-grid rule - handled by specific responsive breakpoints */
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .patent-badge {
        animation: none;
        transition: none;
    }
}

/* Focus styles for keyboard navigation */
button:focus,
a:focus,
input:focus,
textarea:focus {
    outline: 2px solid var(--electric-blue);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --text-primary: #FFFFFF;
        --text-secondary: #FFFFFF;
        --border-primary: #FFFFFF;
    }
}