﻿* {
    box-sizing: border-box;
}

body {
    overflow-x: hidden;
}

.featured-categories-container {
    padding: 80px;
}

.featured-categories-title {
    font-size: 2.5rem;
    font-weight: 500;
    color: #000000;
    text-align: center;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 4px;
    position: relative;
    padding-bottom: 10px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    background: linear-gradient(90deg, #000000, #333333);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
    cursor: default;
}

    .featured-categories-title:hover {
        text-shadow: 4px 4px 10px rgba(0, 0, 0, 0.4);
    }

.featured-categories {
    margin-top: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 80px;
}

    .featured-categories a {
        text-decoration: none;
        color: inherit;
        display: contents;
        width: 100%;
    }

.category-item {
    height: auto;
    padding: 0;
    box-sizing: border-box;
    width: 100%;
    max-width: calc(25% - 60px);
    position: relative;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.category-img {
    width: 100%;
    height: 0;
    padding-bottom: 133.33%;
    position: relative;
    overflow: hidden;
}

    .category-img img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        position: absolute;
        top: 0;
        left: 0;
        transition: transform 0.5s ease;
        display: block;
    }

.category-item:hover .category-img img {
    transform: scale(1.1);
}

.category-name {
    position: absolute;
    bottom: 10px;
    left: 10px;
    font-size: 16px;
    color: black;
    text-align: left;
    opacity: 0.8;
    margin-top: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 90%;
    display: inline-block;
    position: relative;
    z-index: 3;
    text-shadow: none;
}

    .category-name:hover .category-label-div {
        width: 50px;
    }


.category-label-div {
    width: 0;
    height: 2px;
    background-color: black;
    margin: auto;
    transition: width 0.5s ease;
}

@media (max-width: 768px) {
    .category-item {
        max-width: calc(50% - 60px);
    }

    .category-name {
        font-size: 14px;
    }
}

@media (max-width: 520px) {
    .category-item {
        max-width: 100%;
    }

    .featured-categories {
        margin-top: 70px;
    }

    .featured-categories-container {
        padding: 60px;
    }

    .category-name {
        font-size: 12px;
    }
}
