body {
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Fallbacks for custom Tailwind colors (in case config isn't applied) */
.bg-primary-50 { background-color: #fff7ed; }
.bg-primary-100 { background-color: #ffedd5; }
.bg-primary-200 { background-color: #fed7aa; }
.bg-primary-300 { background-color: #fdba74; }
.bg-primary-400 { background-color: #fb923c; }
.bg-primary-500 { background-color: #f97316; }
.bg-primary-600 { background-color: #ea580c; }
.bg-primary-700 { background-color: #c2410c; }
.bg-primary-800 { background-color: #9a3412; }
.bg-primary-900 { background-color: #7c2d12; }
.text-primary-50 { color: #fff7ed; }
.text-primary-100 { color: #ffedd5; }
.text-primary-200 { color: #fed7aa; }
.text-primary-300 { color: #fdba74; }
.text-primary-400 { color: #fb923c; }
.text-primary-500 { color: #f97316; }
.text-primary-600 { color: #ea580c; }
.text-primary-700 { color: #c2410c; }
.text-primary-800 { color: #9a3412; }
.text-primary-900 { color: #7c2d12; }
.border-primary-500 { border-color: #f97316; }
.border-primary-600 { border-color: #ea580c; }
.bg-secondary-800 { background-color: #1e293b; }
.bg-secondary-900 { background-color: #0f172a; }
.text-secondary-800 { color: #1e293b; }
.text-secondary-900 { color: #0f172a; }
.bg-secondary-900\/90 { background-color: rgba(15, 23, 42, 0.9); }
.bg-secondary-900\/40 { background-color: rgba(15, 23, 42, 0.4); }
.bg-accent-500 { background-color: #10b981; }
.text-accent-500 { color: #10b981; }

.bg-gradient-to-r {
    background-image: linear-gradient(to right, var(--tw-gradient-stops));
}
.from-primary-600 {
    --tw-gradient-from: #ea580c;
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, rgba(234, 88, 12, 0));
}
.to-primary-500 {
    --tw-gradient-to: #f97316;
}
.hover\:from-primary-700:hover {
    --tw-gradient-from: #c2410c;
    --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, rgba(194, 65, 12, 0));
}
.hover\:to-primary-600:hover {
    --tw-gradient-to: #ea580c;
}

/* Hero Textures */
.hero-section {
    background: linear-gradient(135deg, rgba(234, 88, 12, 0.92), rgba(15, 23, 42, 0.85)), url('https://images.unsplash.com/photo-1532629345422-7515f3d16bb6?ixlib=rb-1.2.1&auto=format&fit=crop&w=1950&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.glass-nav {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.3);
}

/* Hover Effects */
.card-hoverable {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.card-hoverable:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 30px -5px rgba(0, 0, 0, 0.15);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: #f1f1f1; 
}
::-webkit-scrollbar-thumb {
    background: #ea580c; 
    border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
    background: #c2410c; 
}

/* Accordion Transition */
.accordion-content {
    transition: max-height 0.3s ease-out, padding 0.3s ease;
    max-height: 0;
    overflow: hidden;
}
.accordion-input:checked ~ .accordion-content {
    max-height: 200px;
}
.accordion-icon {
    transition: transform 0.3s ease;
}
.accordion-input:checked ~ label .accordion-icon {
    transform: rotate(180deg);
}

/* Animated Background Utilities */
.section-animated-bg {
    position: relative;
    overflow: hidden;
}
.bg-grid {
    background-image: radial-gradient(rgba(15, 23, 42, 0.08) 1px, transparent 1px);
    background-size: 26px 26px;
    pointer-events: none;
}
.glow-orb {
    filter: blur(48px);
    opacity: 0.8;
    pointer-events: none;
}

.hero-section::before,
.hero-section::after {
    content: "";
    position: absolute;
    inset: -20%;
    pointer-events: none;
}
.hero-section::before {
    background: radial-gradient(circle at 20% 20%, rgba(234, 88, 12, 0.45), transparent 45%),
                radial-gradient(circle at 80% 30%, rgba(16, 185, 129, 0.35), transparent 50%),
                radial-gradient(circle at 50% 80%, rgba(255, 255, 255, 0.15), transparent 45%);
    mix-blend-mode: screen;
    animation: aurora 22s ease-in-out infinite;
}
.hero-section::after {
    background: radial-gradient(circle at 70% 60%, rgba(255, 196, 0, 0.35), transparent 45%);
    animation: drift 18s ease-in-out infinite;
    opacity: 0.6;
}

.no-aos [data-aos] {
    opacity: 1 !important;
    transform: none !important;
}

@keyframes aurora {
    0% { transform: translate3d(-5%, -5%, 0) scale(1); }
    50% { transform: translate3d(5%, 4%, 0) scale(1.05); }
    100% { transform: translate3d(-5%, -5%, 0) scale(1); }
}

.marquee {
    overflow: hidden;
    position: relative;
}
.marquee-track {
    display: flex;
    gap: 0;
    width: max-content;
    will-change: transform;
}

#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, #ea580c, #f59e0b, #10b981);
    z-index: 9999;
}
#back-to-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    opacity: 0;
    pointer-events: none;
    transform: translateY(12px);
    transition: all 0.3s ease;
    z-index: 9998;
}
#back-to-top.is-visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

@media (max-width: 768px) {
    .hero-section {
        background-attachment: scroll;
    }
    #impact {
        background-attachment: scroll;
    }
}

@media (prefers-reduced-motion: reduce) {
    .animate-float,
    .animate-float-delayed,
    .animate-float-x,
    .animate-drift,
    .animate-aurora,
    .animate-marquee,
    .animate-pulse-glow,
    .animate-spin-slow {
        animation: none !important;
    }
    .hero-section {
        background-attachment: scroll;
    }
}
