/**
 * ABC Management - Enhanced Styles
 * Contains dark mode, animations, and enhanced interactive effects
 */

/* ==========================================
   DARK MODE COLORS
   ========================================== */

:root {
    /* Light mode (default) */
    --bg-primary: #ffffff;
    --bg-secondary: #f9fafb;
    --bg-tertiary: #111827;
    --text-primary: #111827;
    --text-secondary: #6b7280;
    --text-inverse: #ffffff;
    --border-color: #e5e7eb;
    --shadow: rgba(0, 0, 0, 0.1);
}

.dark {
    /* Dark mode */
    --bg-primary: #111827;
    --bg-secondary: #1f2937;
    --bg-tertiary: #ffffff;
    --text-primary: #f9fafb;
    --text-secondary: #d1d5db;
    --text-inverse: #111827;
    --border-color: #374151;
    --shadow: rgba(0, 0, 0, 0.3);
}

/* Apply dark mode colors */
.dark body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

.dark nav {
    background-color: rgba(17, 24, 39, 0.95) !important;
}

.dark .bg-white {
    background-color: var(--bg-primary);
}

.dark .bg-gray-50 {
    background-color: var(--bg-secondary);
}

.dark .bg-gray-900 {
    background-color: var(--bg-tertiary);
}

.dark .text-gray-900 {
    color: var(--text-primary);
}

.dark .text-gray-600,
.dark .text-gray-500,
.dark .text-gray-400 {
    color: var(--text-secondary);
}

.dark .text-white {
    color: var(--text-inverse);
}

.dark .border-gray-200,
.dark .border-gray-300 {
    border-color: var(--border-color);
}

.dark .shadow-lg,
.dark .shadow-xl {
    box-shadow: 0 10px 15px -3px var(--shadow);
}

.dark footer {
    background-color: #0f1419 !important;
}

/* Dark mode button styles */
.dark .btn-primary {
    background-color: var(--bg-tertiary);
    color: var(--text-inverse);
}

.dark .btn-primary:hover {
    background-color: #e5e7eb;
}

/* Transition for dark mode */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Disable transition for elements that shouldn't animate */
.no-transition,
img,
video {
    transition: none !important;
}


/* ==========================================
   SCROLL ANIMATIONS
   ========================================== */

/* Initial state - hidden */
.fade-in-up,
.fade-in,
.fade-in-left,
.fade-in-right {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-left {
    transform: translateX(-30px) translateY(0);
}

.fade-in-right {
    transform: translateX(30px) translateY(0);
}

.fade-in {
    transform: translateY(0);
}

/* Animated state - visible */
.fade-in-up.animate-in,
.fade-in.animate-in,
.fade-in-left.animate-in,
.fade-in-right.animate-in {
    opacity: 1;
    transform: translate(0, 0);
}

/* Staggered animation delays */
.fade-in-up:nth-child(1) { transition-delay: 0.1s; }
.fade-in-up:nth-child(2) { transition-delay: 0.2s; }
.fade-in-up:nth-child(3) { transition-delay: 0.3s; }
.fade-in-up:nth-child(4) { transition-delay: 0.4s; }
.fade-in-up:nth-child(5) { transition-delay: 0.5s; }
.fade-in-up:nth-child(6) { transition-delay: 0.6s; }


/* ==========================================
   HERO CAROUSEL
   ========================================== */

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
}

.carousel-slide.active {
    opacity: 1;
    position: relative;
}

.carousel-slide.hidden {
    display: none;
}

/* Carousel navigation dots */
.carousel-dot {
    transition: all 0.3s ease;
}

.carousel-dot:hover {
    transform: scale(1.3);
}

.carousel-dot.bg-white {
    width: 2.5rem;
    border-radius: 0.5rem;
}

/* Carousel arrows */
.carousel-arrow {
    opacity: 0;
    transition: all 0.3s ease;
}

#heroCarousel:hover .carousel-arrow {
    opacity: 1;
}

.carousel-arrow:hover {
    transform: translateY(-50%) scale(1.1);
}


/* ==========================================
   ENHANCED HOVER EFFECTS
   ========================================== */

/* Navigation link underline animation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: currentColor;
    transition: width 0.3s ease;
}

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

/* Card hover effects with subtle tilt */
.card-hover,
.team-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    transform-style: preserve-3d;
}

.card-hover:hover,
.team-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px -5px rgba(0, 0, 0, 0.15);
}

/* Button glow effect */
.btn-primary {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-primary:hover::before {
    width: 300px;
    height: 300px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.2);
}

/* Image zoom on hover */
.image-zoom-hover {
    overflow: hidden;
}

.image-zoom-hover img,
.image-zoom-hover > div {
    transition: transform 0.5s ease;
}

.image-zoom-hover:hover img,
.image-zoom-hover:hover > div {
    transform: scale(1.1);
}


/* ==========================================
   NAVIGATION SCROLL EFFECT
   ========================================== */

nav {
    transition: all 0.3s ease;
}

nav.scrolled {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    background-color: rgba(255, 255, 255, 0.98) !important;
}

.dark nav.scrolled {
    background-color: rgba(17, 24, 39, 0.98) !important;
}


/* ==========================================
   BACK TO TOP BUTTON
   ========================================== */

#backToTop {
    transition: all 0.3s ease;
}

#backToTop:hover {
    box-shadow: 0 15px 30px -5px rgba(0, 0, 0, 0.3);
}


/* ==========================================
   LOADING ANIMATION (optional)
   ========================================== */

@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.skeleton {
    animation: shimmer 2s infinite linear;
    background: linear-gradient(
        to right,
        #f6f7f8 0%,
        #edeef1 20%,
        #f6f7f8 40%,
        #f6f7f8 100%
    );
    background-size: 1000px 100%;
}


/* ==========================================
   RESPONSIVE ADJUSTMENTS
   ========================================== */

@media (max-width: 768px) {
    .fade-in-up,
    .fade-in,
    .fade-in-left,
    .fade-in-right {
        /* Simpler animations on mobile */
        transform: translateY(20px);
    }

    .carousel-arrow {
        /* Always show arrows on mobile */
        opacity: 1;
    }
}


/* ==========================================
   ACCESSIBILITY
   ========================================== */

/* Focus styles for keyboard navigation */
*:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

.dark *:focus-visible {
    outline-color: #60a5fa;
}

/* Reduced motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}


/* ==========================================
   UTILITY CLASSES
   ========================================== */

.blur-in {
    filter: blur(10px);
    opacity: 0;
    transition: filter 0.6s ease, opacity 0.6s ease;
}

.blur-in.animate-in {
    filter: blur(0);
    opacity: 1;
}

.slide-in-bottom {
    transform: translateY(100px);
    opacity: 0;
    transition: transform 0.6s ease, opacity 0.6s ease;
}

.slide-in-bottom.animate-in {
    transform: translateY(0);
    opacity: 1;
}

/* Gradient text */
.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Glass morphism effect */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.dark .glass {
    background: rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.1);
}
