/* 
   PRODUCT.CSS - RESPONSIVE
============================================== */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    font-family: "Poppins", sans-serif; 
}

html {
    overflow-x: hidden;
    width: 100%;
}

body { 
    overflow-x: hidden;
    width: 100%;
    position: relative;
    background: #111; 
    color: #fff; 
}

.secondary-navbar {
    margin-top: 60px; 
    display: flex; 
    justify-content: space-between; 
    align-items: center;
    padding: 10px 20px; 
    border-bottom: 1px solid #e0e0e0; 
    background-color: #ffffff;
    width: 100%; 
    box-sizing: border-box;
}

.nav-left, .nav-right { flex: 1; }
.nav-left { display: flex; align-items: center; gap: 20px; }
.nav-center { flex: 2; text-align: center; }
.nav-right { display: flex; justify-content: flex-end; }

.logo-title { 
    font-weight: bold; 
    font-size: 2rem; 
    margin: 0; 
    color: #000; 
    text-transform: uppercase; 
}

.dropdown { position: relative; display: inline-block; }
.dropdown-toggle { 
    background: none; 
    border: none; 
    cursor: pointer; 
    font-size: 1rem; 
    font-weight: bold; 
    display: flex; 
    align-items: center; 
    gap: 8px; 
}

.dropdown-content { 
    display: none; 
    position: absolute; 
    background-color: #f1f1f1; 
    min-width: 160px; 
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2); 
    z-index: 1; 
    border-radius: 4px; 
    overflow: hidden; 
    margin-top: 10px; 
}

.dropdown-content a { 
    color: black; 
    padding: 12px 16px; 
    text-decoration: none; 
    display: block; 
}

.dropdown-content a:hover { background-color: #ddd; }
.show { display: block; }

.cart-icon { color: #000; font-size: 1.5rem; text-decoration: none; }

.product-section { 
    padding: 20px 40px; 
    background-color: #f9f9f9; 
    min-height: 80vh; 
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 24px;
}

a.product-card-link { text-decoration: none; color: inherit; display: block; }

.product-card {
    background-color: #ffffff; 
    border: 1px solid #e9e9e9; 
    border-radius: 10px;
    padding: 30px 0; 
    text-align: center; 
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover { 
    transform: scale(1.05); 
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1); 
}

.product-image { 
    width: 200px; 
    height: 200px; 
    object-fit: cover; 
    margin-bottom: 16px; 
}

.product-info { padding: 0 8px; }

.product-title { 
    font-size: 1rem; 
    font-weight: 600; 
    color: #333; 
    margin: 0 0 8px 0; 
}

.product-price { 
    font-size: 1rem; 
    font-weight: 400; 
    color: #555; 
    margin: 0; 
}

.search-state-container {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    background-color: #fff;
    border: 2px dashed #ccc;
    border-radius: 12px;
    text-align: center;
    margin-top: 50px; 
    margin-bottom: 20px;
}

.search-state-icon { font-size: 3rem; color: #333; margin-bottom: 15px; }
.search-state-text h3 { font-size: 1.5rem; font-weight: 700; color: #333; margin-bottom: 10px; }
.search-state-text p { color: #666; margin-bottom: 20px; }

.btn-reset-search {
    padding: 10px 25px;
    background-color: #111;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    border-radius: 8px;
    transition: 0.3s;
    display: inline-block;
}

.btn-reset-search:hover { 
    background-color: #333; 
    transform: translateY(-2px); 
}

.product-header-control {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.result-count {
    color: #666;
    font-size: 0.9rem;
}

.sort-dropdown {
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
    color: #333;
    font-family: inherit;
    cursor: pointer;
    outline: none;
}

.pagination-container {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 50px;
    padding-bottom: 20px;
}

.page-btn {
    display: inline-block;
    padding: 8px 16px;
    border: 1px solid #ddd;
    background: #fff;
    color: #333;
    text-decoration: none;
    border-radius: 6px;
    transition: 0.2s;
    font-size: 0.9rem;
}

.page-btn:hover {
    background: #f0f0f0;
    border-color: #ccc;
}

.page-btn.active {
    background: #111;
    color: #fff;
    border-color: #111;
}

.page-btn.disabled {
    color: #ccc;
    border-color: #eee;
    cursor: not-allowed;
}

@media (max-width: 1024px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }
    
    .product-image {
        width: 180px;
        height: 180px;
    }
}

@media (max-width: 768px) {
    .secondary-navbar { 
        flex-direction: column; 
        gap: 15px; 
        padding: 20px; 
        height: auto; 
        margin-top: 55px;
    }
    
    .nav-center { 
        order: -1; 
        margin-bottom: 10px; 
    }
    
    .nav-left {
        width: 100%;
        justify-content: center;
    }
    
    .nav-right { 
        width: 100%; 
        justify-content: center; 
    }
    
    .logo-title {
        font-size: 1.6rem;
    }
    
    .product-section {
        padding: 20px 20px;
    }
    
    .product-grid { 
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); 
        gap: 15px; 
    }
    
    .product-card {
        padding: 20px 0;
    }
    
    .product-image { 
        width: 140px; 
        height: 140px; 
    }
    
    .product-title {
        font-size: 0.9rem;
    }
    
    .product-price {
        font-size: 0.9rem;
    }
    
    .product-header-control {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .result-count {
        text-align: center;
    }
    
    .sort-dropdown {
        width: 100%;
    }
    
    .search-state-container {
        padding: 30px 15px;
        margin-top: 30px;
    }
    
    .search-state-icon {
        font-size: 2.5rem;
    }
    
    .search-state-text h3 {
        font-size: 1.3rem;
    }
    
    .pagination-container {
        flex-wrap: wrap;
        gap: 6px;
    }
    
    .page-btn {
        padding: 7px 14px;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .logo-title {
        font-size: 1.4rem;
    }
    
    .dropdown-toggle {
        font-size: 0.9rem;
    }
    
    .cart-icon {
        font-size: 1.3rem;
    }
    
    .product-section {
        padding: 15px;
    }
    
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 12px;
    }
    
    .product-card {
        padding: 15px 0;
    }
    
    .product-image {
        width: 120px;
        height: 120px;
    }
    
    .product-title {
        font-size: 0.85rem;
    }
    
    .product-price {
        font-size: 0.85rem;
    }
    
    .search-state-container {
        padding: 25px 12px;
    }
    
    .search-state-icon {
        font-size: 2rem;
    }
    
    .search-state-text h3 {
        font-size: 1.1rem;
    }
    
    .search-state-text p {
        font-size: 0.9rem;
    }
    
    .btn-reset-search {
        padding: 8px 20px;
        font-size: 0.9rem;
    }
}

