/* Carousel Styles */
.carousel-container {
    position: relative;
    width: 100%;
    height: 485px;
    overflow: hidden;
    font-size: 23px;
}

.carousel-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-slides {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 1;
    transform: translateX(100%);
    transition: transform 0.5s ease-in-out;
}

.carousel-slide.active {
    transform: translateX(0);
}

.slide-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.slide-background img {
    width: 100%;
    height: 412px;
    object-fit: cover;
}

.slide-content {
    position: absolute;
    top: 54%;
    left: 210px;
    transform: translateY(-50%);
    z-index: 2;
    color: white;
    max-width: 500px;
    text-align: left;
    width: 20%;
}

.slide-title {
    font-size: 28px;
    font-weight: bold;
    margin: 0 0 15px 0;
    line-height: 1.1;
    color: white;
    font-family: Calibri;
}

.slide-description {
    font-size: 14px;
    margin: 0;
    line-height: 1.3;
    color: white;
    font-family: Calibri;
    font-weight: normal;
    text-align: left;
}

/* Carousel Navigation */
.carousel-nav {
    position: absolute;
    top: 42%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background-color: white;
    color: #007bff;
    font-size: 12px;
    cursor: pointer;
    z-index: 3;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.carousel-nav:hover {
    background-color: #f8f9fa;
    transform: translateY(-50%) scale(1.05);
}

.carousel-prev {
    left: 75px;
}

.carousel-next {
    right: 75px;
}

.carousel-nav i {
    font-size: 12px;
    font-weight: bold;
}

/* Catalog Section */
.catalog-section {
    margin: -95px 72px 0 72px;
    background-color: white;
    padding: 40px 0;
    border-radius: 20px 20px 0 0;
    position: relative;
    z-index: 2;
}

.catalog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px 30px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.catalog-title {
    flex: 1;
    min-width: 0;
}

.catalog-title h2 {
    color: #FF6B35;
    font-size: 24px;
    font-weight: bold;
    margin: 0;
    font-family: Calibri;
}

.catalog-region {
    flex-shrink: 0;
    margin-right: 10px;
}

.region-selector {
    display: flex;
    align-items: center;
    gap: 10px;
}

.region-label {
    color: #333;
    font-size: 16px;
    font-weight: 700;
    white-space: nowrap;
}

.region-dropdown-btn {
    position: relative;
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 8px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 120px;
    font-size: 16px;
    color: #333;
    width: 154px;
    height: 31px;
}

.region-dropdown-btn:hover {
    border-color: #999;
}


.region-option {
    flex: 1;
    text-align: left;
    font-size: 14px;
    color: #333333;
    font-family: Calibri;
}

.region-dropdown-btn i {
    font-size: 8px;
    color: #666;
    transition: transform 0.3s ease;
}

.region-dropdown-btn.open i {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 2px;
    background: white;
    border-top: none;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    display: none;
}

.dropdown-menu.show {
    display: block !important;
}

.dropdown-item {
    padding: 10px 12px;
    cursor: pointer;
    color: #666666;
    font-size: 16px;
    text-align: left;
    transition: background-color 0.2s ease;
    font-family: Calibri;
}

.dropdown-item:first-child {
    border-radius: 8px 8px 0 0;
}

.dropdown-item:last-child {
    border-radius: 0 0 8px 8px;
}

.dropdown-item:hover {
    background-color: #e9ecef;
}

.dropdown-item.active {
    background-color: #0057B8;
    color: white;
    font-weight: 500;
}

/* Catalog Carousel */
.catalog-carousel-container {
    overflow: hidden;
    position: relative;
    padding: 0 60px;
    max-width: 1200px;
    margin: 0 auto;
}

.catalog-carousel-wrapper {
    position: relative;
    overflow: hidden;
}

.catalog-carousel {
    display: flex;
    gap: 20px;
    padding-right: 0 20px;
    transition: transform 0.5s ease;
}

.catalog-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    border: 1px solid #BFD3DE;
    border-radius: 4px;
    background-color: white;
    color: #666;
    font-size: 14px;
    cursor: pointer;
    z-index: 3;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.catalog-nav:hover {
    background-color: #e9ecef;
    transform: translateY(-50%) scale(1.05);
}

.catalog-prev {
    left: 10px;
}

.catalog-next {
    right: 10px;
}

.catalog-nav i {
    font-size: 14px;
    font-weight: bold;
    color: #666;
}

/* Hide navigation buttons when there are less than 6 items */
.catalog-no-nav .catalog-nav {
    display: none;
}

.catalog-no-nav {
    padding: 0;
}

.catalog-card {
    flex: 0 0 220px;
    background: white;
    border: 1px solid #F0F0F0;
    border-radius: 8px;
    overflow: hidden;
    height: 470px;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.catalog-card img {
    width: 100%;
    height: 180px;
    border-radius: 12px 12px 0 0;
    object-fit: cover;
}

.catalog-card-content {
    padding: 20px;
    height: 200px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-overflow: ellipsis;
}

.catalog-card-content h3 {
    color: #0056b3;
    font-size: 18px;
    font-weight: bold;
    margin: 0 0 10px 0;
    font-family: Calibri;
    max-height: 3.6em;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    line-height: 1.8;
    line-clamp: 1;
    box-orient: vertical;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.catalog-card-content p {
    color: #333;
    font-size: 12px;
    line-height: 1.5;
    margin: 0 0 15px 0;
    font-family: Calibri;
    text-align: left;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    line-clamp: 10;
    box-orient: vertical;
    -webkit-line-clamp: 10;
    -webkit-box-orient: vertical;
    cursor: pointer;
}

.catalog-link {
    color: #0056b3;
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
    font-family: Calibri;
    text-align: right;
    margin-top: auto;
}

/* Responsive */
@media (max-width: 768px) {
    .slide-content {
        left: 20px;
        right: 20px;
        max-width: none;
        width: auto;
    }

    .slide-title {
        font-size: 24px;
    }

    .slide-description {
        font-size: 12px;
    }

    .carousel-nav {
        width: 28px;
        height: 28px;
    }

    .carousel-prev {
        left: 15px;
    }

    .carousel-next {
        right: 15px;
    }

    .catalog-header {
        flex-direction: column;
        gap: 20px;
        align-items: flex-start;
    }

    .catalog-carousel-container {
        padding: 0 20px;
    }

    .catalog-card {
        flex: 0 0 200px;
    }
}

/* Tooltip for truncated descriptions */
.catalog-tooltip {
    position: absolute;
    display: none;
    background-color: #d3d3d3;
    color: #333;
    padding: 10px;
    border-radius: 4px;
    font-size: 12px;
    line-height: 1.4;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    word-wrap: break-word;
    font-family: Calibri;
}
