/*==========================================
    GIHOC Distilleries - Animations Stylesheet
============================================*/

/*------------------------------------------
    Global Animation Properties
-------------------------------------------*/
:root {
    --transition-speed: 0.3s;
    --transition-function: ease-in-out;
    --animation-speed: 1s;
}

/*------------------------------------------
    Element Transitions
-------------------------------------------*/
/* Smooth element transition base */
.transition-all {
    transition: all var(--transition-speed) var(--transition-function);
}

/* Hover lift effect */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

/* Scale on hover */
.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

/* Fade in */
.fade-in {
    animation: fadeIn 1s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Fade in up */
.fade-in-up {
    animation: fadeInUp 1s ease forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Fade in down */
.fade-in-down {
    animation: fadeInDown 1s ease forwards;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Fade in left */
.fade-in-left {
    animation: fadeInLeft 1s ease forwards;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Fade in right */
.fade-in-right {
    animation: fadeInRight 1s ease forwards;
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Fade out */
.fade-out {
    animation: fadeOut 1s ease forwards;
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

/* Slow reveal */
.slow-reveal {
    animation: slowReveal 2s ease forwards;
}

@keyframes slowReveal {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/*------------------------------------------
    Navigation Animations
-------------------------------------------*/
/* Navbar transition to solid on scroll */
.navbar {
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

/* Navbar dropdown animation */
.dropdown-menu {
    transform-origin: top center;
    animation: dropdownReveal 0.3s ease forwards;
}

@keyframes dropdownReveal {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Hamburger to X animation for mobile menu */
.hamburger.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.hamburger.active .bar:nth-child(2) {
    opacity: 0;
}

.hamburger.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Mobile nav menu slide in */
.nav-menu.active {
    animation: slideInLeft 0.4s forwards;
}

@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

/*------------------------------------------
    Page Transitions & Scroll Animations
-------------------------------------------*/
/* Page transition on load */
.page-transition {
    animation: pageTransition 0.5s ease;
}

@keyframes pageTransition {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

/* Custom animations for AOS (Animate on Scroll) */
[data-aos="custom-fade-up"] {
    opacity: 0;
    transform: translateY(30px);
    transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1), opacity 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

[data-aos="custom-fade-up"].aos-animate {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered reveal for lists */
.stagger-reveal > * {
    opacity: 0;
}

.stagger-reveal > *:nth-child(1) {
    animation: staggerFadeIn 0.5s 0.1s forwards;
}

.stagger-reveal > *:nth-child(2) {
    animation: staggerFadeIn 0.5s 0.2s forwards;
}

.stagger-reveal > *:nth-child(3) {
    animation: staggerFadeIn 0.5s 0.3s forwards;
}

.stagger-reveal > *:nth-child(4) {
    animation: staggerFadeIn 0.5s 0.4s forwards;
}

.stagger-reveal > *:nth-child(5) {
    animation: staggerFadeIn 0.5s 0.5s forwards;
}

.stagger-reveal > *:nth-child(6) {
    animation: staggerFadeIn 0.5s 0.6s forwards;
}

@keyframes staggerFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/*------------------------------------------
    Hero & Banner Animations
-------------------------------------------*/
/* Hero text reveal */
.hero-content h1 {
    animation: heroTitleReveal 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes heroTitleReveal {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content p {
    animation: heroTextReveal 1.2s 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
    opacity: 0;
}

@keyframes heroTextReveal {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content .cta-button {
    animation: heroCTAReveal 1.2s 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
    opacity: 0;
}

@keyframes heroCTAReveal {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Video background zoom */
.hero-section .video-container {
    animation: slowZoom 30s infinite alternate;
}

@keyframes slowZoom {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.1);
    }
}

/*------------------------------------------
    Content Element Animations
-------------------------------------------*/
/* Section header animation */
.section-header h2::after {
    transition: width 0.5s ease;
    width: 0;
}

.section-header.animated h2::after,
.section-header h2:hover::after {
    width: 80px;
}

/* Card hover effects */
.info-card:hover .card-icon,
.cocktail-card:hover .cocktail-image,
.gallery-item:hover .gallery-placeholder {
    animation: gentlePulse 1s infinite alternate;
}

@keyframes gentlePulse {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.05);
    }
}

/* Product card hover animation */
.product-card:hover .product-image::before {
    animation: productShine 1.5s ease-in-out;
}

@keyframes productShine {
    0% {
        transform: translateX(-100%) rotate(45deg);
    }
    100% {
        transform: translateX(100%) rotate(45deg);
    }
}

/* News ticker animation */
.news-ticker {
    animation: tickerSlide 30s linear infinite;
}

@keyframes tickerSlide {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-100%);
    }
}

/* Pause ticker on hover */
.news-ticker:hover {
    animation-play-state: paused;
}

/* Background color shifting for sections */
.color-shift-bg {
    animation: colorShift 15s infinite alternate;
    background-size: 400% 400%;
}

@keyframes colorShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Cocktail overlay reveal */
.cocktail-card:hover .cocktail-overlay {
    animation: overlayReveal 0.4s ease forwards;
}

@keyframes overlayReveal {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Social icon hover animation */
.social-icon:hover i {
    animation: socialPulse 0.5s ease;
}

@keyframes socialPulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

/* CTA button hover animation */
.cta-button:hover {
    animation: ctaPulse 1s infinite alternate;
}

@keyframes ctaPulse {
    0% {
        transform: translateY(-3px);
    }
    100% {
        transform: translateY(-5px);
    }
}

/*------------------------------------------
    Form & Interactive Element Animations
-------------------------------------------*/
/* Form input focus animation */
.contact-form input:focus,
.contact-form textarea:focus,
.newsletter-form input:focus {
    animation: formFocus 0.3s forwards;
}

@keyframes formFocus {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 71, 171, 0.1);
    }
    100% {
        box-shadow: 0 0 0 4px rgba(0, 71, 171, 0.1);
    }
}

/* Submit button click animation */
.submit-btn:active,
.subscribe-btn:active {
    animation: buttonClick 0.2s forwards;
}

@keyframes buttonClick {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(0.97);
    }
    100% {
        transform: scale(1);
    }
}

/* Success message animation */
.success-message {
    animation: successPop 0.5s forwards;
}

@keyframes successPop {
    0% {
        opacity: 0;
        transform: scale(0.9);
    }
    70% {
        transform: scale(1.05);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Error message shake animation */
.error-message {
    animation: errorShake 0.5s forwards;
}

@keyframes errorShake {
    0%, 100% {
        transform: translateX(0);
    }
    20%, 60% {
        transform: translateX(-5px);
    }
    40%, 80% {
        transform: translateX(5px);
    }
}

/* Accordion animation */
.accordion-content {
    transition: max-height 0.5s ease, padding 0.5s ease;
}

/* Spin animation */
.spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/*------------------------------------------
    Image & Slider Animations
-------------------------------------------*/
/* Gallery image hover animation */
.gallery-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 71, 171, 0.4);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover::before {
    opacity: 1;
}

/* Slider transition */
.swiper-slide-active {
    animation: slideActive 0.5s forwards;
}

@keyframes slideActive {
    from {
        opacity: 0.7;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

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

.zoom-on-hover img {
    transition: transform 0.5s ease;
}

.zoom-on-hover:hover img {
    transform: scale(1.1);
}

/* Video play button pulse */
.video-placeholder i {
    animation: playButtonPulse 2s infinite ease-in-out;
}

@keyframes playButtonPulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/*------------------------------------------
    Page-Specific Animations
-------------------------------------------*/
/* Cocktail mixing animation */
.cocktail-mixing {
    position: relative;
    overflow: hidden;
}

.cocktail-mixing::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    animation: cocktailMix 3s infinite linear;
}

@keyframes cocktailMix {
    0% {
        transform: rotate(45deg) translateY(-100%);
    }
    100% {
        transform: rotate(45deg) translateY(100%);
    }
}

/* Band performance animation */
.band-performance {
    animation: bandPerform 3s infinite ease-in-out;
}

@keyframes bandPerform {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

/* Bottle pouring animation */
.bottle-pour {
    position: relative;
}

.bottle-pour::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 2px;
    height: 0;
    background: linear-gradient(to bottom, var(--primary-color), transparent);
    animation: bottlePour 2s infinite;
}

@keyframes bottlePour {
    0% {
        height: 0;
        opacity: 1;
    }
    100% {
        height: 30px;
        opacity: 0;
    }
}

/* Event date pulse animation */
.performance-date, .event-date {
    animation: datePulse 2s infinite alternate ease-in-out;
}

@keyframes datePulse {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 71, 171, 0.4);
    }
    100% {
        box-shadow: 0 0 0 10px rgba(0, 71, 171, 0);
    }
}

/*------------------------------------------
    Special Loading Effects
-------------------------------------------*/
/* Initial page load animation */
.site-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    animation: siteLoad 1.5s forwards;
    animation-delay: 0.5s;
}

@keyframes siteLoad {
    0% {
        opacity: 1;
        visibility: visible;
    }
    99% {
        opacity: 0;
        visibility: visible;
    }
    100% {
        opacity: 0;
        visibility: hidden;
    }
}

/* Logo reveal animation */
.logo-reveal {
    animation: logoReveal 1.5s forwards cubic-bezier(0.165, 0.84, 0.44, 1);
}

@keyframes logoReveal {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Loading spinner animation */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(0, 71, 171, 0.1);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spinnerRotate 1s infinite linear;
}

@keyframes spinnerRotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Progress bar animation - Removed as it was causing display issues */

/* Shimmer loading effect */
.shimmer-loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite linear;
}

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