/* Homepage Sections - Category Showcase and Team Members */

:root {
    --primary-color: rgb(1,62,82);
    --secondary-color: #044458ef;
    --accent-color: #33b40c;
    --text-light: #fff;
    --text-dark: #333;
    --gradient-primary: linear-gradient(243deg, rgb(6, 63, 73) 0%, rgba(12,39,91,1) 50%, rgb(0, 13, 15) 86%);
    --box-shadow: 0 4px 8px rgba(238, 236, 236, 0.3);
    --header-height: 60px; /* Define consistent header height */
    --sidebar-width: 280px; /* Added from dashboard.css */
}


/* Category Showcase Styles */
.category-showcase-container {
    padding: 8px 0;
    position: relative;
    overflow: hidden;
    margin: 0 auto;
    width: 78%;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    margin-bottom: 20px;
}


.category-showcase-container::before {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: rgba(51, 180, 12, 0.05);
    border-radius: 50%;
    top: -150px;
    left: -150px;
    z-index: 0;
}

.category-showcase-container::after {
    content: '';
    position: absolute;
    width: 250px;
    height: 250px;
    background: rgba(1, 62, 82, 0.05);
    border-radius: 50%;
    bottom: -100px;
    right: -100px;
    z-index: 0;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 15px;
    position: relative;
    z-index: 1;
    padding: 0;
    margin: 0 auto;
    max-width: 100%;
}

@media (max-width: 1200px) {
    .category-grid {
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(4, 1fr);
    }
}

@media (max-width: 768px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(5, 1fr);
    }
}

@media (max-width: 576px) {
    .category-grid {
        grid-template-columns: 1fr;
    }
}

/* Section Headers */
.section-header {
    text-align: center;
    margin-bottom: 15px;
    position: relative;
    z-index: 1;
    padding-top: 10px;
}

.section-header::after {
    content: "";
    display: table;
    clear: both;
}

.section-header h2 {
    color: #ffffff;
    font-size: 2.2rem;
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    width: 60px;
    height: 3px;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

.section-header p {
    font-size: 1.1rem;
    max-width: 700px;
    margin: 15px 0 0 auto;
    color: var(--accent-color);
    text-align: right;
    display: block;
    float: right;
    clear: right;
}


/* Category Card Styles - Improved for better visibility */
.category-card {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    perspective: 1000px;
    height: 180px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    opacity: 1; 
    transform: translateY(0); 
    margin-bottom: 0;
}

.category-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.category-card:hover .category-card-inner {
    transform: rotateY(180deg);
}

.category-card-front, .category-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
}

.category-card-front {
    color: var(--text-dark);
}

.category-card-back {
    background-color: var(--primary-color);
    color: white;
    transform: rotateY(180deg);
    justify-content: center;
    align-items: center;
    padding: 20px;
    text-align: center;
}

.category-image {
    height: 110px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 0;
}

.category-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.5s ease;
    max-height: 110px;
    display: block;
}

.category-card:hover .category-image img {
    transform: scale(1.05);
}

.category-info {
    padding: 5px 10px;
    background: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 70px;
    margin: 0;
}

.category-info h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--primary-color);
    line-height: 1.2;
}

.post-count {
    display: block;
    font-size: 0.8rem;
    color: #666;
    margin-top: 3px;
}

.category-link {
    display: inline-block;
    margin-top: 15px;
    padding: 8px 15px;
    background-color: var(--accent-color);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.category-link:hover {
    background-color: var(--accent-hover);
}

/* Team Members Section */
.team-members-container {
    padding: 10px 0;
    background-color: var(--secondary-color);
    position: relative;
    overflow: hidden;
    width: 78%;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    margin: 0 auto;
}

.team-slider-wrapper {
    position: relative;
    padding: 0 40px;
    max-width: 1200px;
    margin: 0 auto;
    overflow: hidden;
}

.team-slider {
    overflow: hidden;
    position: relative;
}

.team-members {
    display: flex;
    transition: transform 0.5s ease;
    padding: 10px 0;
}

.team-member {
    flex: 0 0 auto;
    padding: 0 10px;
    text-align: center;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.member-photo {
    width: 140px;
    height: 140px;
    margin: 0 auto 15px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.member-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.team-member:hover .member-photo img {
    transform: scale(1.1);
}

.member-info h3 {
    margin: 0 0 5px;
    color: white;
    font-size: 1.2rem;
}

.position {
    display: block;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background-color: white;
    color: var(--primary-color);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.social-icon:hover {
    background-color: var(--accent-color);
    color: white;
    transform: translateY(-3px);
}

.no-social-links {
    display: inline-block;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    font-style: italic;
    padding: 3px 8px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
}

/* Navigation Buttons */
.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background-color: white;
    border: none;
    border-radius: 50%;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    z-index: 10;
    font-size: 1.2rem;
    color: var(--primary-color);
    transition: all 0.3s ease;
}

.slider-nav:hover {
    background-color: var(--accent-color);
    color: white;
}

.prev-button {
    left: 0;
}

.next-button {
    right: 0;
}

.slider-nav:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .team-member {
        min-width: calc(100% / 4);
    }
}

@media (max-width: 992px) {
    .team-member {
        min-width: calc(100% / 3);
    }
}

@media (max-width: 768px) {
    .team-member {
        min-width: calc(100% / 2);
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .team-member {
        min-width: 100%;
    }
    
    .slider-nav {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
}

.container {
    padding: 0 15px;
    max-width: 1200px;
    margin: 0 auto;
}
