/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    width: 100%;
    overflow: hidden;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: #000;
    color: #fff;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: 0;
}

.logo {
    position: absolute;
    top: 40px;
    left: 40px;
}

.logo a {
    display: inline-block;
}

.logo img {
    max-width: 150px;
    height: auto;
    display: block;
}

/* Carousel Container */
#slides-1 {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

/* Slides Container */
.slides-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
}

.slides-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    z-index: 1;
    transition: opacity 1.5s ease-in-out;
    will-change: opacity;
}

.slides-container img.active {
    opacity: 1;
    z-index: 3;
}

.slides-container img.prev {
    opacity: 1;
    z-index: 2;
    transition: opacity 1.5s ease-in-out;
}

/* Pattern Overlay - using overlay.png instead of solid color */
.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/carousel/overlay.png');
    background-repeat: repeat;
    z-index: 10;
    pointer-events: none;
}

/* Main Title - Centered with Flexbox */
.main-title {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
}

.title-container {
    text-align: center;
    max-width: 100%;
    width: 100vw;
    padding: 0 20px;
    overflow: visible;
}

.welcome {
    height: 20px;
    margin-bottom: 30px;
}

/* Text Rotator */
.title-container ul {
    list-style: none;
    position: relative;
    width: 100%;
    height: 130px;
    overflow: hidden;
    margin-bottom: 10px;
}

.title-container ul li {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    font-size: 100px;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    white-space: nowrap;
    opacity: 0;
    transform: translateY(100%);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.title-container ul li.t-current {
    opacity: 1;
    transform: translateY(0);
}

.title-container ul li.exit {
    opacity: 0;
    transform: translateY(-100%);
}

.spacerw {
    width: 60px;
    height: 2px;
    background-color: #fff;
    margin: 10px auto 30px auto;
}

/* Discover Button - Original Structure */
.buy-logo {
    display: inline-block;
    position: relative;
    padding: 18px 50px;
    background: transparent;
    border: 2px solid #fff;
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.4s ease;
}

.buy-logo span {
    position: relative;
    z-index: 2;
    transition: color 0.4s ease;
}

.buy-logo::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    transform: translateX(-100%);
    transition: transform 0.4s ease;
    z-index: 1;
}

.buy-logo:hover {
    color: #000 !important;
}

.buy-logo:hover span {
    color: #000 !important;
}

.buy-logo:hover::before {
    transform: translateX(0);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .title-container ul li {
        font-size: 60px;
    }
    
    .title-container ul {
        height: 80px;
    }
}

@media (max-width: 768px) {
    .logo {
        top: 30px;
        left: 30px;
    }
    
    .logo img {
        max-width: 120px;
    }
    
    .title-container ul li {
        font-size: 60px;
        letter-spacing: 2px;
    }
    
    .title-container ul {
        height: 80px;
    }
    
    .buy-logo {
        padding: 15px 40px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .logo {
        top: 20px;
        left: 20px;
    }
    
    .logo img {
        max-width: 100px;
    }
    
    .title-container {
        padding: 15px;
    }
    
    .title-container ul li {
        font-size: 40px;
        letter-spacing: 1px;
    }
    
    .title-container ul {
        height: 60px;
    }
    
    .buy-logo {
        padding: 12px 30px;
        font-size: 0.9rem;
    }
    
    .welcome {
        margin-bottom: 20px;
    }
    
    .spacerw {
        margin: 10px auto 30px auto;
    }
}

/* Performance Optimization */
@media (prefers-reduced-motion: reduce) {
    .slides-container img {
        transition: none;
    }
    
    .title-container ul li {
        transition: none;
    }
    
    .buy-logo {
        transition: none;
    }
    
    .buy-logo::before {
        transition: none;
    }
}
