.logo-animation-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/grey_bg.jpg') no-repeat center center;
    background-size: cover;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
}

.logo-animation {
    width: 1100px;
    height: 850px;
    animation: logoExpand 1.5s ease-in-out forwards;
    opacity: 0;
}

@keyframes logoExpand {
    0% {
        transform: translateX(-100%) scale(0.1);
        opacity: 0;
    }
    20% {
        opacity: 1;
    }
    80% {
        transform: translateX(0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translateX(0) scale(1);
        opacity: 0;
    }
}

/* Product Button Animations */
.product-button {
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-button.animate {
    opacity: 1;
    transform: translateY(0);
}

/* Animation delays for each button */
.product-button:nth-child(1) { transition-delay: 0.2s; }
.product-button:nth-child(2) { transition-delay: 0.4s; }
.product-button:nth-child(3) { transition-delay: 0.6s; }
.product-button:nth-child(4) { transition-delay: 0.8s; }
.product-button:nth-child(5) { transition-delay: 1.0s; }
.product-button:nth-child(6) { transition-delay: 1.2s; }


.product-button:hover::before {
    transform: translateX(100%);
}

.product-button img {
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-button:hover img {
    transform: scale(1.1);
}

/* Product View Animations */
.product-view img {
    opacity: 0;
    transform: translateX(-100px);
    animation: slideInLeft 1s ease-out forwards;
}

.product-detail-container {
    opacity: 0;
    transform: translateX(100px);
    animation: slideInRight 1s ease-out forwards;
}

@keyframes slideInLeft {
    0% {
        opacity: 0;
        transform: translateX(-100px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    0% {
        opacity: 0;
        transform: translateX(100px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Letter-by-letter animation */
@keyframes letterAppear {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.products h2.animate-letters span {
    display: inline-block;
    opacity: 0;
    transform: translateX(-20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.products h2.animate-letters.animate span {
    opacity: 1;
    transform: translateX(0);
}

.products h2.animate-letters span:nth-child(1) { transition-delay: 0.1s; }
.products h2.animate-letters span:nth-child(2) { transition-delay: 0.2s; }
.products h2.animate-letters span:nth-child(3) { transition-delay: 0.3s; }
.products h2.animate-letters span:nth-child(4) { transition-delay: 0.4s; }
.products h2.animate-letters span:nth-child(5) { transition-delay: 0.5s; }
.products h2.animate-letters span:nth-child(6) { transition-delay: 0.6s; }
.products h2.animate-letters span:nth-child(7) { transition-delay: 0.7s; }
.products h2.animate-letters span:nth-child(8) { transition-delay: 0.8s; }
.products h2.animate-letters span:nth-child(9) { transition-delay: 0.9s; }
.products h2.animate-letters span:nth-child(10) { transition-delay: 1.0s; }
.products h2.animate-letters span:nth-child(11) { transition-delay: 1.1s; }
.products h2.animate-letters span:nth-child(12) { transition-delay: 1.2s; }
.products h2.animate-letters span:nth-child(13) { transition-delay: 1.3s; }

/* Main Content Fade In */
.main-content {
    opacity: 0;
    transform: translateY(20px);
    animation: mainContentFadeIn 1s ease-out forwards;
}

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

/* Parallax Effect */
.hero {
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.3));
    z-index: 1;
}

.hero img {
    transform: translateZ(-1px) scale(1.2);
    transition: transform 0.3s ease-out;
}

/* Smooth Scroll Reveal */
.about-us {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.about-us.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Title letter animation */
.animate-letters span {
    display: inline-block;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.animate-letters span.animate {
    opacity: 1;
    transform: translateY(0);
}

/* Logo Animation */
.logo {
    opacity: 0;
    transform: translateX(-100px);
    animation: slideInFromLeft 0.8s ease-out forwards;
}

@keyframes slideInFromLeft {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Navigation Links Animation */
nav ul li {
    opacity: 0;
    transform: translateX(50px);
}

nav ul li:nth-child(1) { animation: slideInFromRight 0.5s ease-out 0.2s forwards; }
nav ul li:nth-child(2) { animation: slideInFromRight 0.5s ease-out 0.4s forwards; }
nav ul li:nth-child(3) { animation: slideInFromRight 0.5s ease-out 0.6s forwards; }
nav ul li:nth-child(4) { animation: slideInFromRight 0.5s ease-out 0.8s forwards; }
nav ul li:nth-child(5) { animation: slideInFromRight 0.5s ease-out 1.0s forwards; }
nav ul li:nth-child(6) { animation: slideInFromRight 0.5s ease-out 1.2s forwards; }

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

.feature-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.feature-card-visible {
    opacity: 1;
    transform: translateY(0);
}

.feature-card:nth-child(1) {
    transition-delay: 0.1s;
}

.feature-card:nth-child(2) {
    transition-delay: 0.3s;
}

.feature-card:nth-child(3) {
    transition-delay: 0.5s;
}

/* Add delay for each letter */
.about-us-header h2 span:nth-child(1) { animation-delay: 0.05s; }
.about-us-header h2 span:nth-child(2) { animation-delay: 0.1s; }
.about-us-header h2 span:nth-child(3) { animation-delay: 0.15s; }
.about-us-header h2 span:nth-child(4) { animation-delay: 0.2s; }
.about-us-header h2 span:nth-child(5) { animation-delay: 0.25s; }
.about-us-header h2 span:nth-child(6) { animation-delay: 0.3s; }
.about-us-header h2 span:nth-child(7) { animation-delay: 0.35s; }
.about-us-header h2 span:nth-child(8) { animation-delay: 0.4s; }
.about-us-header h2 span:nth-child(9) { animation-delay: 0.45s; }
.about-us-header h2 span:nth-child(10) { animation-delay: 0.5s; }
.about-us-header h2 span:nth-child(11) { animation-delay: 0.55s; }
.about-us-header h2 span:nth-child(12) { animation-delay: 0.6s; }
.about-us-header h2 span:nth-child(13) { animation-delay: 0.65s; }
.about-us-header h2 span:nth-child(14) { animation-delay: 0.7s; }
.about-us-header h2 span:nth-child(15) { animation-delay: 0.75s; }
.about-us-header h2 span:nth-child(16) { animation-delay: 0.8s; }
.about-us-header h2 span:nth-child(17) { animation-delay: 0.85s; }
.about-us-header h2 span:nth-child(18) { animation-delay: 0.9s; }
.about-us-header h2 span:nth-child(19) { animation-delay: 0.95s; }
.about-us-header h2 span:nth-child(20) { animation-delay: 1s; }
.about-us-header h2 span:nth-child(21) { animation-delay: 1.05s; }
.about-us-header h2 span:nth-child(22) { animation-delay: 1.1s; }
.about-us-header h2 span:nth-child(23) { animation-delay: 1.15s; }
.about-us-header h2 span:nth-child(24) { animation-delay: 1.2s; }
.about-us-header h2 span:nth-child(25) { animation-delay: 1.25s; }
.about-us-header h2 span:nth-child(26) { animation-delay: 1.3s; }
.about-us-header h2 span:nth-child(27) { animation-delay: 1.35s; }
.about-us-header h2 span:nth-child(28) { animation-delay: 1.4s; }
.about-us-header h2 span:nth-child(29) { animation-delay: 1.45s; }
.about-us-header h2 span:nth-child(30) { animation-delay: 1.5s; }
.about-us-header h2 span:nth-child(31) { animation-delay: 1.55s; }
.about-us-header h2 span:nth-child(32) { animation-delay: 1.6s; }
.about-us-header h2 span:nth-child(33) { animation-delay: 1.65s; }
.about-us-header h2 span:nth-child(34) { animation-delay: 1.7s; }
.about-us-header h2 span:nth-child(35) { animation-delay: 1.75s; }
.about-us-header h2 span:nth-child(36) { animation-delay: 1.8s; }
.about-us-header h2 span:nth-child(37) { animation-delay: 1.85s; }
.about-us-header h2 span:nth-child(38) { animation-delay: 1.9s; }
.about-us-header h2 span:nth-child(39) { animation-delay: 1.95s; }
.about-us-header h2 span:nth-child(40) { animation-delay: 2s; }

.about-us-subtitle span {
    display: inline-block;
    opacity: 0;
    transform: translateX(-20px);
    animation: letterReveal 0.5s ease forwards;
}

/* Add delay for each letter in subtitle */
.about-us-subtitle span:nth-child(1) { animation-delay: 2.05s; }
.about-us-subtitle span:nth-child(2) { animation-delay: 2.1s; }
.about-us-subtitle span:nth-child(3) { animation-delay: 2.15s; }
.about-us-subtitle span:nth-child(4) { animation-delay: 2.2s; }
.about-us-subtitle span:nth-child(5) { animation-delay: 2.25s; }
.about-us-subtitle span:nth-child(6) { animation-delay: 2.3s; }
.about-us-subtitle span:nth-child(7) { animation-delay: 2.35s; }
.about-us-subtitle span:nth-child(8) { animation-delay: 2.4s; }
.about-us-subtitle span:nth-child(9) { animation-delay: 2.45s; }
.about-us-subtitle span:nth-child(10) { animation-delay: 2.5s; }
.about-us-subtitle span:nth-child(11) { animation-delay: 2.55s; }
.about-us-subtitle span:nth-child(12) { animation-delay: 2.6s; }
.about-us-subtitle span:nth-child(13) { animation-delay: 2.65s; }
.about-us-subtitle span:nth-child(14) { animation-delay: 2.7s; }
.about-us-subtitle span:nth-child(15) { animation-delay: 2.75s; }
.about-us-subtitle span:nth-child(16) { animation-delay: 2.8s; }
.about-us-subtitle span:nth-child(17) { animation-delay: 2.85s; }
.about-us-subtitle span:nth-child(18) { animation-delay: 2.9s; }
.about-us-subtitle span:nth-child(19) { animation-delay: 2.95s; }
.about-us-subtitle span:nth-child(20) { animation-delay: 3s; }
.about-us-subtitle span:nth-child(21) { animation-delay: 3.05s; }
.about-us-subtitle span:nth-child(22) { animation-delay: 3.1s; }
.about-us-subtitle span:nth-child(23) { animation-delay: 3.15s; }
.about-us-subtitle span:nth-child(24) { animation-delay: 3.2s; }
.about-us-subtitle span:nth-child(25) { animation-delay: 3.25s; }
.about-us-subtitle span:nth-child(26) { animation-delay: 3.3s; }
.about-us-subtitle span:nth-child(27) { animation-delay: 3.35s; }
.about-us-subtitle span:nth-child(28) { animation-delay: 3.4s; }
.about-us-subtitle span:nth-child(29) { animation-delay: 3.45s; }
.about-us-subtitle span:nth-child(30) { animation-delay: 3.5s; }
.about-us-subtitle span:nth-child(31) { animation-delay: 3.55s; }
.about-us-subtitle span:nth-child(32) { animation-delay: 3.6s; }
.about-us-subtitle span:nth-child(33) { animation-delay: 3.65s; }
.about-us-subtitle span:nth-child(34) { animation-delay: 3.7s; }
.about-us-subtitle span:nth-child(35) { animation-delay: 3.75s; }
.about-us-subtitle span:nth-child(36) { animation-delay: 3.8s; }
.about-us-subtitle span:nth-child(37) { animation-delay: 3.85s; }
.about-us-subtitle span:nth-child(38) { animation-delay: 3.9s; }
.about-us-subtitle span:nth-child(39) { animation-delay: 3.95s; }
.about-us-subtitle span:nth-child(40) { animation-delay: 4s; }

.company-description h2,
.company-description h3 {
    opacity: 0;
    transform: translateX(-100%);
}

.company-description h2.animate,
.company-description h3.animate {
    animation: slideInFromLeft 1.5s ease-out forwards;
}

/* First paragraph special case */
.company-description > p:first-of-type {
    opacity: 0;
    transform: translateX(-100%);
}

.company-description > p:first-of-type.animate {
    animation: slideInFromLeft 1.5s ease-out forwards;
}

.process-step:nth-child(1) { animation-delay: 0.3s; }
.process-step:nth-child(2) { animation-delay: 0.6s; }
.process-step:nth-child(3) { animation-delay: 0.9s; }
.process-step:nth-child(4) { animation-delay: 1.2s; }

#animated-title .space,
#animated-subtitle .space {
    margin-right: 0.3em;
}
