        /* Keeping original variables and general styles */
:root {
    --primary-color: #578E7E;
    --secondary-color: #F5ECD5;
    --dark-bg: #3D3D3D;
    --danger-color: #FF6F61;
    --text-light: white;
    --border-radius: 8px;
    --transition: all 0.3s ease;
    --sidebar-width: 250px;
}

/* Hide filter container on smaller screens */
@media (max-width: 1024px) {
    .filter-container {
        display: none;
    }

    .mobile-filter {
        display: block;
    }
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: Arial, sans-serif;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* Header e titulos */
.header-content {
    padding: 20px 0;
}

h1, h3 {
    margin-bottom: 0.8rem;
}

.page-title {
    color: var(--primary-color);
    font-size: 2rem;
    letter-spacing: 1px;
}

.welcome-message {
    font-weight: 500;
    color: #555;
}

.section-title {
    margin-top: 10px;
    position: relative;
    display: inline-block;
    padding-bottom: 5px;
}

.section-title:after {
    content: '';
    position: absolute;
    width: 50%;
    height: 3px;
    background-color: var(--primary-color);
    bottom: 0;
    left: 0;
}

/* Layout principal - sidebar fixa à esquerda e conteúdo à direita */
.page-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar estilizada */
.sidebar {
    background-color: var(--dark-bg);
    color: var(--text-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 30px 15px;
    transition: var(--transition);
    z-index: 100;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    width: var(--sidebar-width);
    min-width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
}

.sidebar-logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--secondary-color);
    margin-bottom: 20px;
    text-align: center;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    width: 100%;
}

.sidebar-nav {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.sidebar button {
    background-color: transparent;
    color: var(--text-light);
    border: 1px solid rgba(255,255,255,0.1);
    padding: 12px 15px;
    width: 100%;
    font-size: 16px;
    cursor: pointer;
    border-radius: var(--border-radius);
    text-align: left;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar button i {
    font-size: 18px;
    min-width: 24px;
    text-align: center;
}

.sidebar button:hover {
    background-color: var(--primary-color);
    color: var(--text-light);
    transform: translateX(5px);
}

.sidebar button.active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.sidebar button.danger {
    margin-top: auto;
    background-color: rgba(255,111,97,0.2);
    border-color: var(--danger-color);
    color: var(--danger-color);
}

.sidebar button.danger:hover {
    background-color: var(--danger-color);
    color: var(--text-light);
}

/* Sidebar close button style */
.sidebar-close-button {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--primary-color); /* change to primary color */
    border: none;
    color: var(--text-light);
    font-size: 24px;
    cursor: pointer;
    display: none;
    /* transition: right 0.5s ease-in-out;  remove animation */
    border-radius: 50%; /* make it a circle */
    width: 30px;      /* set width */
    height: 30px;     /* set height */
    display: flex;      /* enable flexbox */
    align-items: center; /* center vertically */
    justify-content: center; /* center horizontally */
}

.sidebar-close-button:hover {
    background-color: #467a6a; /* darker shade of primary color on hover */
}

/* Floating button style */
.floating-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    font-size: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.floating-button:hover {
    background-color: var(--secondary-color);
    color: var(--dark-bg);
    transform: translateY(-5px);
}


/* Área de conteúdo principal */
.main-content-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    position: relative;
    display: flex;
    flex-direction: column;
    width: calc(100% - var(--sidebar-width));
}

/* Barra de filtros - Fixa no topo, agora com fundo transparente */
.filter-container {
    position: sticky;
    top: 0;
    width: 100%;
    background-color: transparent;
    z-index: 90;
    padding: 15px;
    backdrop-filter: blur(5px);
}

.filter-bar {
    display: flex;
    gap: 20px;
    border: 2px solid var(--primary-color);
    padding: 15px 20px;
    border-radius: var(--border-radius);
    justify-content: center;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
    flex-wrap: wrap;
    background-color: rgba(249, 249, 249, 0.8);
}

.filter-bar select {
    background-color: var(--primary-color);
    color: var(--text-light);
    border: none;
    padding: 10px 15px;
    font-size: 14px;
    cursor: pointer;
    border-radius: 5px;
    transition: var(--transition);
    min-width: 120px;
}

.filter-bar select:hover {
    background-color: var(--secondary-color);
    color: var(--dark-bg);
}

.filter-bar .reset-btn {
    background-color: var(--danger-color);
    color: var(--text-light);
    border: none;
    padding: 10px 15px;
    font-size: 14px;
    cursor: pointer;
    border-radius: 5px;
    transition: var(--transition);
}

.filter-bar .reset-btn:hover {
    opacity: 0.8;
}


/* Conteúdo principal */
.content {
    padding: 20px;
    flex: 1;
    /*display: flex;  REMOVED */
    /*justify-content: center; REMOVED */
    /*align-items: center; REMOVED */
}

/* Updated Clothing Card Style */
.clothing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    justify-items: center;
    width: 100%;
}

.clothing-card {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    padding: 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 350px;
    transition: var(--transition);
    border: 1px solid #eee;
    position: relative;
    cursor: pointer;
    height: auto;
}

.clothing-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.card-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 15px;
}

.clothing-card img {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid #eee;
}

.clothing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.color-indicator {
    width: 20px;
    height: 100%;
    position: absolute;
    right: 0;
    top: 0;
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

.stars {
    display: flex;
    gap: 5px;
    justify-content: center;
    margin-top: 15px;
    width: 100%;
}

.diamond {
    width: 15px;
    height: 15px;
    background-color: transparent;
    transform: rotate(45deg);
    border: 2px solid #2c3e50;
    border-radius: 3px;
    margin: 0 2px;
}

.diamond.filled {
    background-color: gold;
}

.clothing-card .delete-button {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: transparent;
    color: var(--danger-color);
    border: 1px solid var(--danger-color);
    padding: 8px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 50%;
    transition: var(--transition);
    display: flex;
    justify-content: center;
    align-items: center;
    width: 36px;
    height: 36px;
    z-index: 10;
}

.clothing-card .delete-button:hover {
    background-color: var(--danger-color);
    color: white;
}

/* New style for clothing icon below image */
.clothing-card .clothing-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: var(--text-light);
    font-size: 1.2em;
    margin-top: 10px; /* Adjust spacing as needed */
}
/* Centralize icon below image */
.clothing-card .card-content {
    display: flex;
    flex-direction: column;
    align-items: center; /* Centralize content horizontally */
    width: 100%;
    gap: 15px;
}

/* Hamburger Menu para mobile */
.hamburger-button {
    display: none;
    position: fixed;
    top: 15px;
    left: 15px; /* CHANGED FROM RIGHT TO LEFT */
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 5px;
    width: 50px;
    height: 50px;
    font-size: 24px;
    cursor: pointer;
    z-index: 110;
    transition: var(--transition);
}

.hamburger-button:hover {
    background-color: var(--secondary-color);
    color: var(--dark-bg);
}

.mobile-filter {
    display: none;
}

.mobile-filter .filter-content {
    position: fixed;
    top: 0;
    right: -100%;
    width: 90%;
    max-width: 350px;
    height: 100vh;
    background-color: white;
    box-shadow: -5px 0 20px rgba(0,0,0,0.2);
    z-index: 100;
    overflow-y: auto;
    padding: 80px 20px 30px;
    transition: right 0.4s ease-in-out;
}

.mobile-filter.active .filter-content {
    right: 0;
}

.mobile-filter .filter-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    z-index: 99;
    display: none;
}

.mobile-filter.active .filter-overlay {
    display: block;
}

.mobile-filter .filter-title {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.mobile-filter select {
    width: 100%;
    margin-bottom: 15px;
    background-color: var(--primary-color);
    color: var(--text-light);
    border: none;
    padding: 12px 15px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
}

.mobile-filter .reset-btn {
    width: 100%;
    background-color: var(--danger-color);
    color: var(--text-light);
    border: none;
    padding: 12px 15px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    margin-top: 20px;
}

.close-filter {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 24px;
    color: var(--danger-color);
    cursor: pointer;
}

/* Updated responsive layout */
@media screen and (max-width: 1400px) {
    .clothing-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media screen and (max-width: 1200px) {
    .clothing-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 1024px) {
    :root {
        --sidebar-width: 0; /* SET SIDEBAR WIDTH TO 0 ON MOBILE */
        --sidebar-width-mobile: 250px; /* Define mobile sidebar width */
    }

    .page-container {
        flex-direction: column;
    }

    .sidebar {
        position: fixed; /* MAKE SIDEBAR FIXED AGAIN */
        top: 0;
        left: -100%; /* HIDE SIDEBAR OFF SCREEN INITIALLY */
        width: var(--sidebar-width-mobile); /* DEFAULT MOBILE SIDEBAR WIDTH */
        height: 100vh;
        flex-direction: column;
        padding: 30px 15px;
        z-index: 150; /* ENSURE IT'S ABOVE OTHER CONTENT */
        overflow-y: auto;
        transition: left 0.5s ease-in-out;
        box-shadow: 3px 0 15px rgba(0,0,0,0.3);
        background-color: var(--dark-bg); /* Ensure background color is set */
    }

    .sidebar.active {
        left: 0; /* SLIDE SIDEBAR IN WHEN ACTIVE CLASS IS ADDED */
    }

    /* Show sidebar close button on mobile and position it slightly outside sidebar */
    .sidebar.active .sidebar-close-button {
        display: block; /* SHOW CLOSE BUTTON WHEN SIDEBAR IS ACTIVE */
        position: fixed; /* Changed to fixed positioning */
        top: 15px; /* Align with hamburger button top */
        left: var(--sidebar-width-mobile); /* Position at the edge of sidebar */
        transform: translateX(-100%); /* Shift left by its own width to position right edge at sidebar edge */
        background-color: var(--primary-color); /* change to primary color */
        color: var(--text-light);
        border-radius: 50%;
        width: 30px;
        height: 30px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        z-index: 151;
        box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    }

    .sidebar-close-button:hover {
        background-color: #467a6a; /* darker shade of primary color on hover */
    }


    .sidebar-logo {
        margin-bottom: 0;
        padding-bottom: 0;
        border-bottom: none;
        width: auto;
    }

    .sidebar-nav {
        flex-direction: column; /* VERTICAL NAVIGATION ON MOBILE */
        width: 100%; /* FULL WIDTH FOR NAV ITEMS */
    }

    .sidebar button {
        width: 100%; /* FULL WIDTH BUTTONS IN SIDEBAR */
        padding: 12px 15px;
        text-align: left; /* LEFT ALIGN TEXT IN BUTTONS */
    }

    .sidebar button i {
        margin-right: 10px; /* ADD SPACE BETWEEN ICON AND TEXT */
    }

    .sidebar button:hover {
        transform: translateX(0); /* REMOVE HORIZONTAL TRANSLATE ON HOVER */
    }

    .main-content-wrapper {
        margin-left: 0;
        width: 100%;
    }

    .filter-container {
        padding: 10px; /* Reduce padding for smaller screens */
    }

    .filter-bar {
        padding: 10px; /* Reduce padding for smaller screens */
        gap: 10px; /* Reduce gap for smaller screens */
    }

    .filter-bar select,
    .filter-bar .reset-btn {
        padding: 8px 12px; /* Reduce padding for smaller screens */
        font-size: 12px; /* Reduce font size for smaller screens */
        min-width: 80px; /* Adjust min-width for smaller screens */
    }

    .hamburger-button {
        display: block; /* SHOW HAMBURGER BUTTON ON MOBILE */
    }
}

/* Styles for responsive filter bar for screens up to 1024px */
@media (max-width: 1024px) {
    .responsive-filter-container {
        padding: 10px;
        position: fixed; /* Make filter container fixed */
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(255, 255, 255, 0.95); /* White background for overlay */
        z-index: 120; /* Ensure it's above other content */
        overflow-y: auto; /* Enable scroll if filters are too many */
        display: none; /* Initially hidden on smaller screens */
        padding-top: 60px; /* Padding to avoid overlap with hamburger button */
    }

    .responsive-filter-container.active {
        display: block; /* Show filter container when active */
    }


    .responsive-filter-bar {
        flex-direction: column; /* Stack filters vertically */
        gap: 10px;
        padding: 20px; /* More padding inside the filter container */
        max-width: 90%; /* Limit width for better readability on smaller screens */
        margin: 20px auto; /* Center the filter bar in the container */
    }

    .filter-select, .responsive-reset-btn {
        width: 100%; /* Make selects and reset button full width */
        min-width: auto; /* Remove min-width to allow full width */
        margin-bottom: 10px; /* Add some space below each filter item */
        font-size: 16px; /* Adjust font size for better readability on smaller screens */
        padding: 12px 15px; /* Adjust padding for smaller screens */
    }

    .responsive-reset-btn {
        margin-bottom: 0; /* Remove bottom margin for reset button if it's the last item */
    }

    .filter-hamburger-button { /* STYLE FOR FILTER HAMBURGER BUTTON */
        display: block; /* SHOW ON SMALLER SCREENS */
        position: fixed; /* Fixed position over content */
        top: 15px;
        right: 15px; /* Position to the right of sidebar hamburger */
        background-color: var(--primary-color);
        color: white;
        border: none;
        border-radius: 5px;
        width: 50px;
        height: 50px;
        font-size: 20px;
        cursor: pointer;
        z-index: 130; /* Higher z-index than filter container */
        transition: var(--transition);
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .filter-hamburger-button:hover {
        background-color: var(--secondary-color);
        color: var(--dark-bg);
    }
}


@media screen and (max-width: 768px) {
    .combination-grid {
        grid-template-columns: 1fr;
    }

    .clothing-grid {
        grid-template-columns: 1fr;
    }

    .clothing-card {
        max-width: 90%;
    }

    /* Adjust floating button position for mobile */
    .floating-button {
    }

    .filter-container {
        display: none; /* Hide desktop filter on extra small screens */
    }

    /* Styles for responsive filter bar for screens up to 768px */
    .responsive-filter-bar {
        padding: 10px; /* Reduce padding further for smaller screens */
    }

    .filter-select, .responsive-reset-btn {
        font-size: 12px; /* Further reduce font size for very small screens */
        padding: 8px 10px; /* Reduce padding even more */
    }

    .filter-hamburger-button { /* Adjust position for even smaller screens */
    }
}

@media screen and (max-width: 480px) {
    .page-title {
        font-size: 1.5rem;
    }

    .welcome-message {
        font-size: 1rem;
    }

    .section-title {
        font-size: 1.3rem;
    }

    .sidebar button.danger {
        margin-top: auto;
        background-color: rgba(255,111,97,0.2);
        border-color: var(--danger-color);
        color: var(--danger-color);
    }

    .sidebar button.danger:hover {
        background-color: var(--danger-color);
        color: var(--text-light);
    }

    /* Styles for responsive filter bar for screens up to 480px */
    .responsive-filter-bar {
        gap: 5px; /* Reduce gap even more for very small screens */
    }

    .filter-select, .responsive-reset-btn {
        font-size: 10px; /* Even smaller font size for extremely small screens */
        padding: 5px 8px; /* Minimal padding */
    }

    .filter-hamburger-button { /* Adjust position for extremely small screens */
    }
}

/* Hide sidebar-close-button on larger screens */
@media screen and (min-width: 1025px) {
    .sidebar.active .sidebar-close-button {
        display: none;
    }

    .filter-hamburger-button { /* Hide filter hamburger button on larger screens */
        display: none;
    }
}
