/* Anchors Layout Styles */

/* 1. Top Navigation (Anchors) */
.wpb-anchors-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    margin-bottom: 60px;
    list-style: none !important; /* Force remove bullets */
    padding: 0;
}

.wpb-anchor-item {
    text-align: center;
    max-width: none; /* Remove max-width */
    list-style: none !important; /* Force remove bullets */
    flex: 0 1 15%; /* Flex updated */
}

.wpb-anchor-link {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #333;
    /* transition: transform 0.3s ease; removed translate transition */
}

.wpb-anchor-link:hover {
    transform: none; /* removed translate */
}

.wpb-anchor-circle {
    width: 90px;
    height: 90px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    margin-bottom: 15px;
    position: relative;
    overflow: hidden;
    transition: background 0.3s ease;
}

.wpb-anchor-icon-mask {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #014576 0%, #26949D 100%);
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    transition: background 0.3s ease;
}

/* Hover Effect: Circle Gradient, Icon White */
.wpb-anchor-link:hover .wpb-anchor-circle {
    background: linear-gradient(135deg, #014576 0%, #26949D 100%);
}

.wpb-anchor-link:hover .wpb-anchor-icon-mask {
    background: #fff;
}

.wpb-anchor-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    color: #fff; /* Updated to white */
}

/* 2. Sector Section */
.wpb-sector-section {
    background-color: #E5F0EB;
    padding: 60px 0;
    margin-bottom: 50px; /* Space between sections */
    width: 100%;
}

.wpb-sector-inner {
    max-width: none; /* Remove max-width constraint */
    margin: 0 auto;
    padding: 0 80px; /* 80px side padding */
}

/* Section Header */
.wpb-sector-header {
    display: flex;
    align-items: center;
    margin-bottom: 40px;
    gap: 30px;
}

.wpb-sector-header-icon {
    flex-shrink: 0;
}

.wpb-sector-header-text h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 32px;
    color: #024576;
    margin: 0 0 10px 0;
    line-height: 1.2;
}

.wpb-sector-header-text h3 {
    font-family: inherit;
    font-size: 18px;
    color: #024576; /* Updated color */
    font-weight: 400;
    margin: 0;
}

/* Subcategories Container */
.wpb-subcats-container {
    width: 100%;
    position: relative;
}

/* Grid Mode (<= 5 items) */
.wpb-subcats-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: flex-start; /* Start align */
    align-items: stretch; /* Ensure all items in a row stretch to match the tallest */
}

.wpb-subcats-grid .wpb-subcat-card {
    flex: 0 1 calc(20% - 16px); /* 5 columns */
    width: calc(20% - 16px);
    display: flex; /* Ensure card is a flex container */
    flex-direction: column; /* Content stacks vertically */
    height: 100%; /* Fill the height provided by align-items: stretch */
}

/* Swiper Mode (> 5 items) */
.wpb-subcats-carousel {
    padding-bottom: 40px; /* Space for pagination if needed */
    overflow: hidden;
}

.wpb-subcats-carousel .swiper-wrapper {
    display: flex; /* Swiper wrapper is already flex, but confirm it */
    align-items: stretch; /* Ensure slides stretch */
}

.wpb-subcats-carousel .swiper-slide {
    height: auto;
    display: flex; /* Flex to stretch content */
    height: 100%; /* Force full height in slide */
}

/* Subcategory Card Style */
.wpb-subcat-card {
    background: #fff;
    padding: 30px;
    border-radius: 0;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    height: 100%; /* Ensure full height */
    min-height: 200px; /* Min height fallback */
    width: 100%; /* Ensure width fill in slide */
    box-sizing: border-box;
}

.wpb-subcat-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: #024576;
    margin: 0 0 15px 0;
    text-transform: uppercase;
}

.wpb-subcat-divider {
    width: 100%;
    height: 2px;
    border: none;
    background: linear-gradient(135deg, #014576 0%, #26949D 100%);
    margin: 0 0 15px 0;
}

.wpb-subcat-desc {
    font-size: 14px;
    color: #024576; /* Updated color */
    line-height: 1.5;
    margin: 0;
    flex-grow: 1; /* Push bottom if needed, or just fill */
}

/* Responsive */
@media (max-width: 1024px) {
    .wpb-subcats-grid .wpb-subcat-card {
        flex: 0 1 calc(33.333% - 14px); /* 3 cols */
        width: calc(33.333% - 14px);
    }
    
    .wpb-sector-inner {
        padding: 0 30px;
    }

    .wpb-sector-header-text h2 {
        font-size: 25px;
    }

    .wpb-sector-section {
        padding: 30px 0;
    }

    .wpb-sector-header {
        margin-bottom: 20px;
        gap: 20px;
    }

    .wpb-anchors-nav {
        margin-left: 0;
        gap: 10px; /* Adjust gap for 2 cols */
    }

    .wpb-anchor-item {
        flex: 0 1 calc(50% - 10px); /* 2 items per row */
        max-width: calc(50% - 10px);
    }
}

@media (max-width: 768px) {
    .wpb-sector-header {
        flex-direction: column;
        text-align: center;
    }
    
    .wpb-subcats-grid .wpb-subcat-card {
        flex: 0 1 calc(50% - 10px); /* 2 cols */
        width: calc(50% - 10px);
    }
}

@media (max-width: 480px) {
    .wpb-subcats-grid .wpb-subcat-card {
        flex: 0 1 100%;
        width: 100%;
    }
}
