/* Custom styles for Capital Accounting & Finance */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #faf5ff;
}

::-webkit-scrollbar-thumb {
    background: #a855f7;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #9333ea;
}

/* Hero geometric animations */
@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(3deg); }
}

@keyframes floatSlow {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(-2deg); }
}

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

.hero-geo {
    animation: float 6s ease-in-out infinite;
}

.hero-geo:nth-child(2) {
    animation: floatSlow 8s ease-in-out infinite;
    animation-delay: -2s;
}

.hero-geo:nth-child(3) {
    animation: floatMedium 7s ease-in-out infinite;
    animation-delay: -1s;
}

.hero-geo:nth-child(4) {
    animation: floatSlow 5s ease-in-out infinite;
    animation-delay: -3s;
}

/* Floating cards */
@keyframes floatCard {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.floating-card {
    animation: floatCard 4s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -2s;
}

/* Reveal animations - progressive enhancement */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* Default state for scroll reveals - always visible */
.reveal[data-reveal] {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal[data-reveal] {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.6s ease, transform 0.6s ease;
    }
    
    .reveal.revealed[data-reveal] {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Service card hover effect */
.service-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.service-card:hover {
    transform: translateY(-4px);
}

/* Navbar scroll state */
nav.scrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(107, 33, 168, 0.1);
}

/* Mobile menu animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease;
    opacity: 0;
}

#mobile-menu.open {
    max-height: 500px;
    opacity: 1;
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.15);
}

/* Button hover lift */
button, a {
    transition: all 0.2s ease;
}

/* Selection color */
::selection {
    background: #c084fc;
    color: #3b0764;
}

/* Ensure all text is readable */
.bg-plum-900 *,
.bg-plum-950 * {
    color: inherit;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .hero-geo,
    .floating-card {
        animation: none;
    }
    
    html {
        scroll-behavior: auto;
    }
}
