/* ========================================
   GENERAL CONTAINER STYLES
======================================== */
.account-sbar,
.account-frame-results,
.account-topbar,
.result-details {
    box-sizing: border-box;
    max-width: 100%;
    overflow: hidden;
}

/* ========================================
   TOP BAR & VIEW TOGGLE BUTTONS
======================================== */
.view-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
}


.search-button:hover {
    border-color: white;
    color: white;
}


.view-btn {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    transition: color 0.3s;
}

.view-btn.active {
    color:#FFC302;
}

.view-btn:hover {
    color:#FFC302;
}








  
/* ========================================
   GRID VIEW STYLING (4 items per row)
======================================== */ 
.result-details.grid-view-active {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
    padding: 20px;
    box-sizing: border-box;
}

.grid-view-active .part-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    height: 100%;
    width: 100%;
}

.grid-view-active .part-item {
    width: calc(25% - 15px);  /* 4 columns per row */
    background: #2c2c2c;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
    min-height: 280px;  /* allows 5 rows at 1080px height */
}


.grid-view-active .part-image {
    width: 100%;
    height: 150px;
    object-fit: cover;

    flex-shrink: 0;
    margin: 13px;
}

.grid-view-active .part-info {
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* distribute evenly */
    flex-grow: 1;
    padding: 12px 10px;
    text-align: center;
    width: 100%;
    max-width: 100%;
    gap: 6px;
}
.grid-view-active .part-name h3,
.grid-view-active .part-code p,
.grid-view-active .part-price h3 {
    margin: 0;


    word-wrap: break-word;
    white-space: normal;
    overflow: hidden;
    text-overflow: ellipsis;
}


.grid-view-active .part-item:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.grid-view-active .part-price h3 {
    font-weight: bold;

    font-size: 15px;
    margin-top: auto;
    color:#FFC302;;
}
.grid-view-active .part-code p {
    color:#B8B8B8
}




/* ========================================
   LIST VIEW STYLING (full width rows)
======================================== */
.result-details.list-view-active {
    box-sizing: border-box;
    max-width: 100%;
    overflow: hidden;
    gap: 15px;
}
.list-view-active .part-item {
    max-width: 100%;
    align-items: center;
    text-align: center;
    gap: 15px;
}

.list-view-active .part-card {
    
    margin-bottom: 2%;
    max-width: 100%;
    
    text-align: center;
    display: flex;
    align-items: center;         /* Center vertically in row */
    gap: 15px;
    padding: 10px;
    background: #2c2c2c;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.1s;
    flex-wrap: nowrap;            /* Force single row */
    overflow: hidden;  
}

.list-view-active .part-item:hover {
    transform: translateY(-5px);
}
.list-view-active .part-image {
    width: 140px;
    height: 140px;
    object-fit: cover;
    flex-shrink: 0;
    border-radius: 4px;
}

.list-view-active .part-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    text-align: left;
    flex-grow: 1;
}

.grid-view-active .part-code p {
    color:#B8B8B8
}

.list-view-active .part-price h3 {
    font-weight: bold;

    font-size: 15px;
    margin-top: auto;
    color:#FFC302;;
}

.part-info p {
    font-size: 13px;
    margin: 0;
    color: #ccc;
}

/* ========================================
   SIDEBAR & FILTER SECTION
======================================== */
.account-sbar {
    background: #1c1c1c;
    padding: 15px;
    border-radius: 8px;
    color: white;
	   gap: 15px;
	   text-align: left;
       margin: 3%;
}

.account-sbar h4 {
    margin-bottom: 10px;
    font-size: 18px;
    color: white;
}

.side_search,
.form-group select {
    width: 100%;
    padding: 8px;
    margin: 5px 0;
    border: 1px solid #444;
    background: #2c2c2c;
    color: white;
    border-radius: 5px;
    font-size: 14px;
    box-sizing: border-box;
}

.side_search::placeholder {
    color: #999;
}

.form-group select {
    cursor: pointer;
}

/* ========================================
   FILTERS DROPDOWN (FLOATING FILTERS PANEL)
======================================== */
.filters-dropdown {
    display: none;
    position: absolute;  /* Floats on top */
    z-index: 1000;  /* High enough to be above content */
    background: #2c2c2c;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    margin-top: 10px;
    color: white;
    width: auto;
    max-width: 240px;
    box-sizing: border-box;
	flex-direction: column;
}

.filters-dropdown.active {
    display: flex;
	gap: 10px;
	text-align: left;
	margin-left: 4px;
}

.filters-dropdown .filter-item {
    display: block;
    width: 100%;
    margin-bottom: 10px;
    text-align: left;
}

.filters-dropdown .filter-item label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    color: white;
}

.filters-dropdown .filter-item select,
.filters-dropdown .filter-item input {
    width: 100%;
    padding: 8px;
    border: 1px solid #444;
    background: #2c2c2c;
    color: white;
    border-radius: 5px;
    font-size: 14px;
    box-sizing: border-box;
}

/* ========================================
   RESPONSIVE (MOBILE UNDER 880px)
======================================== */
@media (max-width: 880px) {
    /* Force list view on mobile */
    .grid-view-active .part-item {
        width: 100%;
        display: flex;
        align-items: center;
        gap: 10px;
        flex-direction: row;
    }

    .part-image {
        width: 80px;
        height: 80px;
    }

    .part-info h3 {
        font-size: 14px;
    }

    .part-info p {
        font-size: 12px;
    }

    /* Sidebar filters go full-width on small screens */


    .side_search,
    .form-group select {
        width: 100%;
        margin-bottom: 8px;
    }

    /* Header adjustments for small screens */


}	
	










/* Add proper spacing for nested lists */
.account-sbar ul {
    list-style: none;
    padding-left: 0; /* Reset default browser padding */
}





/* Make sure links remain visible */
.account-sbar a {
    text-decoration: none;
    color: white;
	
	padding: 6%;
}

.account-sbar a:hover {
    color: #FFD700; /* Optional: Highlight on hover */
}


.account-frame-results {
    display: flex;
    flex-direction: column;
    gap: 15px;
	width: 100%;
}

/* Sidebar */
.account-topbar {
    background-color: #333;
    color: white;
    padding: 15px;
    border-radius: 8px;
	width: 100%;
	min-height: 25px;
}

@media (max-width: 880px) {
    .account-topbar {
    display: none; 
    }}