/* ====== ACE-IRI Enhanced Smooth Transitions & Animations ====== */

/* Smooth Link Transitions */
a, button, .nav-link, .menu-item {
    transition: all 0.3s ease-in-out;
}

/* Navigation Hover Effects */
.nav-link:hover,
.menu-item > a:hover {
    color: #0066cc;
    transform: translateY(-2px);
    text-decoration: none;
}

/* Button Hover Effects */
.main-btn, .arrow-btn, .btn-white, .bordered-btn {
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
}

.main-btn:hover,
.arrow-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 102, 204, 0.3);
}

/* Team Member Cards */
.team-item {
    transition: all 0.4s ease-in-out;
    transform: translateY(0);
}

.team-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.team-item img {
    transition: transform 0.4s ease-in-out;
}

.team-item:hover img {
    transform: scale(1.05);
}

/* Smooth Page Transitions */
body {
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Section Fade In */
section {
    animation: slideUp 0.7s ease-in-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Smooth Scroll Behavior */
html {
    scroll-behavior: smooth;
}

/* Director Profile Enhancement */
.team-details-section {
    transition: all 0.5s ease-in-out;
}

.text-wrapper {
    transition: transform 0.5s ease-in-out, opacity 0.5s ease-in-out;
}

/* Portfolio/Project Items */
.portfolio-item,
.blog-post-item {
    transition: all 0.4s ease-in-out;
}

.portfolio-item:hover,
.blog-post-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Footer Links */
.footer-nav-widget a,
.social-link a {
    transition: all 0.3s ease-in-out;
}

.footer-nav-widget a:hover,
.social-link a:hover {
    color: #0066cc;
    transform: translateX(5px);
}

/* Progress Bars Animation */
.progress-bar {
    transition: width 1.5s ease-in-out;
}

/* Breadcrumb Navigation */
.breadcrumbs-link a {
    transition: all 0.3s ease-in-out;
}

.breadcrumbs-link a:hover {
    color: #0066cc;
    text-decoration: underline;
}

/* Form Input Animations */
input, textarea, select {
    transition: all 0.3s ease-in-out;
    border: 1px solid #e0e0e0;
}

input:focus,
textarea:focus,
select:focus {
    border-color: #0066cc;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
    outline: none;
}

/* Back to Top Button */
.back-to-top {
    transition: all 0.4s ease-in-out;
}

.back-to-top:hover {
    background-color: #0052a3;
    transform: translateY(-3px);
}

/* Counter Animation */
.counter-item {
    transition: all 0.5s ease-in-out;
}

.counter-item:hover {
    transform: scale(1.05);
}

/* Modal/Overlay Transitions */
.offcanvas-panel-inner,
.nav-overlay {
    transition: all 0.4s ease-in-out;
}

/* Skill Progress Enhancement */
.single-skill {
    transition: all 0.5s ease-in-out;
}

.single-skill:hover {
    transform: translateX(5px);
}

/* CTA Section Enhancement */
.cta-area {
    transition: all 0.6s ease-in-out;
}

.cta-area:hover {
    background: linear-gradient(135deg, rgba(0, 51, 102, 0.1) 0%, rgba(0, 102, 204, 0.1) 100%);
}

/* Testimonial Cards */
.testimonial-item {
    transition: all 0.4s ease-in-out;
}

.testimonial-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

/* Header Animation */
header {
    animation: slideDown 0.5s ease-in-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hover State on Lists */
.widget-nav li,
.social-nav li {
    transition: all 0.3s ease-in-out;
}

.widget-nav li:hover,
.social-nav li:hover {
    margin-left: 5px;
}

/* Text Fade In Animation */
.wow {
    visibility: hidden;
}

.wow.fadeInUp {
    animation-name: fadeInUp;
}

.wow.fadeInLeft {
    animation-name: fadeInLeft;
}

.wow.fadeInRight {
    animation-name: fadeInRight;
}

.wow.fadeInDown {
    animation-name: fadeInDown;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Smooth Page Load */
@keyframes pageLoad {
    0% {
        opacity: 0;
        background: #f9f9f9;
    }
    100% {
        opacity: 1;
        background: transparent;
    }
}

/* Mobile Responsive Animations */
@media (max-width: 768px) {
    .team-item:hover {
        transform: translateY(-5px);
    }
    
    .main-btn:hover {
        transform: translateY(-2px);
    }
    
    section {
        animation-duration: 0.5s;
    }
}

/* ====== Counter Animation ====== */
.counter-item {
    animation: counterFadeInScale 0.6s ease-out forwards;
    opacity: 0;
}

.counter-item:nth-child(1) { animation-delay: 0.1s; }
.counter-item:nth-child(2) { animation-delay: 0.2s; }
.counter-item:nth-child(3) { animation-delay: 0.3s; }
.counter-item:nth-child(4) { animation-delay: 0.4s; }

@keyframes counterFadeInScale {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.counter-item .number {
    font-weight: 700;
    color: #0066cc;
    transition: all 0.3s ease;
}

.counter-item:hover .number {
    color: #004d99;
    transform: scale(1.08);
}

.counter-item .icon {
    font-size: 48px;
    color: #0066cc;
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.counter-item:hover .icon {
    transform: rotateY(360deg);
    filter: drop-shadow(0 8px 16px rgba(0, 102, 204, 0.3));
}

/* Improved Accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
