/* Global Styles */
body { background-color: #0a0a0a; color: #f3f4f6; }
html { scroll-behavior: smooth; }

/* Custom Scrollbar - Hide default scrollbar */
::-webkit-scrollbar { 
    width: 0;
    display: none;
}
html {
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

/* Glass Effect */
.glass { 
    background: rgba(26, 26, 26, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    will-change: transform;
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #f97316 0%, #fb923c 50%, #ea580c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Card Hover Effects */
.card-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform, box-shadow;
}
.card-hover:hover {
    transform: translateY(-4px);
    border-color: #f97316;
    box-shadow: 0 8px 24px rgba(249, 115, 22, 0.2);
}

/* Draggable Car Scroll Indicator */
#scrollCar {
    cursor: grab !important;
    pointer-events: auto !important;
    user-select: none;
    transition: filter 0.2s ease;
}
#scrollCar:active,
#scrollCar.dragging {
    cursor: grabbing !important;
    filter: drop-shadow(0 4px 8px rgba(249, 115, 22, 0.5));
}

/* Flashlight Effect */
#flashlight {
    position: fixed;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(249, 115, 22, 0.08) 0%, rgba(0, 0, 0, 0) 70%);
    pointer-events: none;
    mix-blend-mode: screen;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: transform 0.1s ease-out;
    will-change: left, top;
}
.flashlight-container {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}
.flashlight {
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(249, 115, 22, 0.15) 0%, rgba(249, 115, 22, 0.05) 40%, transparent 70%);
    transform: translate(-50%, -50%);
    pointer-events: none;
    transition: opacity 0.3s;
    opacity: 0;
}
#projects:hover .flashlight, body:hover .flashlight {
    opacity: 1;
}

/* Background Effects */
#projects, #blog, #about, #contact { position: relative; overflow: hidden; }

/* Orbs */
.bg-orbs { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.15;
    animation: float 20s ease-in-out infinite;
}
.orb-1 { width: 400px; height: 400px; background: radial-gradient(circle, #f97316 0%, transparent 70%); top: -100px; left: -100px; animation-delay: 0s; }
.orb-2 { width: 300px; height: 300px; background: radial-gradient(circle, #ea580c 0%, transparent 70%); bottom: -50px; right: -50px; animation-delay: -10s; }

/* Planes */
.bg-planes { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.plane { position: absolute; font-size: 24px; animation: flyPlane 12s linear infinite; opacity: 0.6; }
.plane:nth-child(1) { top: 15%; animation-delay: 0s; }
.plane:nth-child(2) { top: 35%; animation-delay: -3s; }
.plane:nth-child(3) { top: 55%; animation-delay: -6s; }
.plane:nth-child(4) { top: 75%; animation-delay: -9s; }
.crash-plane { position: absolute; top: 45%; left: 70%; font-size: 24px; animation: crashPlane 8s ease-in-out infinite; transform-origin: center; }
.crash-scene { position: absolute; top: 65%; left: 72%; display: flex; align-items: flex-end; gap: 8px; opacity: 0; animation: showCrash 8s ease-in-out infinite; }
.person { font-size: 28px; }
.speech-bubble {
    background: #f97316;
    color: white;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: bold;
    white-space: nowrap;
    position: relative;
}
.speech-bubble::before {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 10px;
    border-width: 6px 6px 0;
    border-style: solid;
    border-color: #f97316 transparent transparent;
}

/* Animations */
@keyframes flyPlane { 0% { left: -50px; transform: scaleX(1); } 100% { left: calc(100% + 50px); transform: scaleX(1); } }
@keyframes crashPlane { 0%, 30% { transform: translateY(0) rotate(0deg); opacity: 0.6; } 40% { transform: translateY(0) rotate(0deg); opacity: 0.8; } 60% { transform: translateY(80px) rotate(45deg); opacity: 1; } 65%, 100% { transform: translateY(80px) rotate(45deg); opacity: 0; } }
@keyframes showCrash { 0%, 55% { opacity: 0; } 60%, 90% { opacity: 1; } 100% { opacity: 0; } }
@keyframes float { 0%, 100% { transform: translateY(0) translateX(0); } 25% { transform: translateY(-20px) translateX(10px); } 50% { transform: translateY(-10px) translateX(-10px); } 75% { transform: translateY(-30px) translateX(5px); } }
@keyframes pulse { 0%, 100% { opacity: 0.15; transform: translate(-50%, -50%) scale(1); } 50% { opacity: 0.25; transform: translate(-50%, -50%) scale(1.1); } }

/* Matrix Rain */
.bg-matrix { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.bg-matrix canvas { width: 100%; height: 100%; }

/* Floating Shapes */
.bg-shapes { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.shape { position: absolute; opacity: 0.05; animation: float 15s ease-in-out infinite; }
.shape-circle { width: 100px; height: 100px; border: 2px solid #f97316; border-radius: 50%; top: 10%; right: 10%; animation-delay: 0s; }
.shape-square { width: 80px; height: 80px; border: 2px solid #fb923c; transform: rotate(45deg); bottom: 20%; left: 15%; animation-delay: -7s; }
.shape-triangle { width: 0; height: 0; border-left: 50px solid transparent; border-right: 50px solid transparent; border-bottom: 86px solid #ea580c; opacity: 0.08; top: 50%; left: 5%; animation-delay: -3s; }

/* Glow Effect */
.bg-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(249, 115, 22, 0.15) 0%, transparent 70%);
    filter: blur(40px);
    animation: pulse 4s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

/* --- Project Specific --- */

/* Tech Pills */
.tech-pill { transition: all 0.2s; }
.tech-pill:hover { border-color: #f97316; background: rgba(249, 115, 22, 0.1); }

/* Filter Pills */
.filter-pill { transition: all 0.2s; }
.filter-pill:hover { transform: translateY(-1px); }
.filter-pill.active { box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3); }

/* Project Buttons */
.btn-primary {
    background: linear-gradient(135deg, #f97316, #ea580c);
    box-shadow: 0 4px 20px rgba(249, 115, 22, 0.3);
    transition: all 0.3s;
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(249, 115, 22, 0.4);
}
.btn-secondary { transition: all 0.3s; }
.btn-secondary:hover { border-color: #f97316; color: #f97316; }

/* Mobile Sticky Bar */
@media (max-width: 768px) {
    .mobile-sticky-bar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        padding: 1rem;
        background: rgba(10, 10, 10, 0.95);
        backdrop-filter: blur(12px);
        border-top: 1px solid #2a2a2a;
        z-index: 50;
    }
    .has-mobile-bar main { padding-bottom: 100px; }
    .desktop-buttons { display: none; }
}
@media (min-width: 769px) {
    .mobile-sticky-bar { display: none; }
}

/* Blog Prose Styles */
.prose { color: #e5e7eb; line-height: 1.85; font-size: 1.125rem; }
.prose h2 { font-size: 1.5rem; font-weight: 600; color: white; margin-top: 2.5rem; margin-bottom: 1rem; padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,0.1); }
.prose h3 { font-size: 1.25rem; font-weight: 600; color: white; margin-top: 2rem; margin-bottom: 0.75rem; }
.prose p { margin-bottom: 1.5rem; }
.prose a { color: #f97316; text-decoration: underline; }
.prose a:hover { color: #fb923c; }
.prose code { background: #1a1a1a; padding: 0.2em 0.5em; border-radius: 6px; font-size: 0.875em; }
.prose pre { background: #1a1a1a; padding: 1.25rem; border-radius: 12px; overflow-x: auto; margin: 2rem 0; border: 1px solid #2a2a2a; }
.prose pre code { background: none; padding: 0; }
.prose ul, .prose ol { margin: 1.5rem 0; padding-left: 1.5rem; }
.prose li { margin-bottom: 0.5rem; }
.prose blockquote { border-left: 4px solid #f97316; padding: 1rem 1.5rem; font-style: italic; color: #9ca3af; margin: 2rem 0; background: rgba(249, 115, 22, 0.05); border-radius: 0 8px 8px 0; }
.prose img { border-radius: 12px; margin: 2rem auto; max-height: 400px; object-fit: cover; }

/* Mobile FAB */
.mobile-share-fab {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f97316, #ea580c);
    box-shadow: 0 4px 20px rgba(249, 115, 22, 0.4);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 50;
    color: white;
}
@media (max-width: 768px) {
    .mobile-share-fab { display: flex; }
    .desktop-share { display: none; }
}

/* Search Input */
.search-input:focus { border-color: #f97316; box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1); }
