/* assets/css/marketplace.css - REHABACE branded marketplace */

/* ===== MARKETPLACE HERO SECTION ===== */
.marketplace-hero {
    position: relative;
    padding: 80px 0 60px;
    overflow: hidden;
    background: var(--secondary-color);
    margin-top: 70px; /* Space for fixed header */
}

.marketplace-hero .hero-content {
    text-align: center;
}

.marketplace-hero .hero-title {
    font-family: 'Merriweather', serif;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.2;
    margin-bottom: 1rem;
}

.marketplace-hero .hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto;
}

/* ===== SEARCH & FILTER SECTION ===== */
.search-filter-section {
    padding: 30px 0 20px;
    background: var(--bg-color);
    border-bottom: 1px solid var(--border-color);
}

.filter-wrapper {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

@media (min-width: 768px) {
    .filter-wrapper {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}

.search-container {
    flex: 2;
    min-width: 280px;
}

.nav__search {
    position: relative;
    width: 100%;
}

.nav__search-input {
    width: 100%;
    padding: 14px 20px 14px 50px;
    border: 2px solid var(--border-color);
    border-radius: 50px;
    background: var(--card-bg);
    color: var(--text-body);
    font-size: 1rem;
    transition: all 0.3s ease;
    outline: none;
}

.nav__search-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 150, 136, 0.1);
}

.nav__search-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1.2rem;
}

.filter-container {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    flex: 1;
}

.filter-dropdown {
    position: relative;
    min-width: 160px;
    flex: 1;
}

.filter-select {
    width: 100%;
    padding: 14px 40px 14px 20px;
    border: 2px solid var(--border-color);
    border-radius: 50px;
    background: var(--card-bg);
    color: var(--text-body);
    font-size: 0.95rem;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    outline: none;
    transition: all 0.3s ease;
}

.filter-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 150, 136, 0.1);
}

.filter-icon {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
    font-size: 1.2rem;
}

/* ===== MARKETPLACE GRID SECTION ===== */
.marketplace-grid-section {
    padding: 50px 0;
    background: var(--bg-color);
    min-height: 60vh;
}

.marketplace-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

/* Product Card - Matching home page design cards */
.marketplace-card {
    background: var(--card-bg);
    border-radius: var(--radius-card);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.marketplace-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 30px rgba(0, 150, 136, 0.15);
}

.card-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1 / 1;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.marketplace-card:hover .card-image img {
    transform: scale(1.08);
}

.card-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--primary-color);
    color: white;
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
}

.card-content {
    padding: 18px 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.card-category {
    font-size: 0.8rem;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.card-title {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-main);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-price {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-top: 4px;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.add-to-cart-btn {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.add-to-cart-btn:hover {
    background: var(--primary-color);
    color: white;
}

.add-to-cart-btn i {
    font-size: 1rem;
}

/* Empty State */
.no-items-found {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.no-items-found i {
    font-size: 4rem;
    color: var(--border-color);
    margin-bottom: 20px;
}

.no-items-found p {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.no-items-found .suggestion {
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* ===== CART ICON IN HEADER ===== */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.cart-icon-container {
    cursor: pointer;
}

.icon-circle {
    position: relative;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.icon-circle:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.icon-circle:hover i {
    color: white;
}

.icon-circle i {
    font-size: 1.3rem;
    color: var(--text-main);
    transition: color 0.3s ease;
}

.cart-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #e74c3c;
    color: white;
    font-size: 0.7rem;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    border: 2px solid var(--card-bg);
}

.auth-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.auth-btn:hover {
    background: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}

/* ===== RESPONSIVE GRID ===== */
@media (min-width: 576px) {
    .marketplace-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}

@media (min-width: 768px) {
    .marketplace-hero {
        padding: 100px 0 70px;
    }
    
    .marketplace-hero .hero-title {
        font-size: 2.8rem;
    }
    
    .marketplace-hero .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .marketplace-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 30px;
    }
}

@media (min-width: 1024px) {
    .marketplace-hero .hero-title {
        font-size: 3.2rem;
    }
    
    .marketplace-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 1200px) {
    .marketplace-grid {
        gap: 35px;
    }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.marketplace-card {
    animation: fadeInUp 0.6s ease forwards;
}

/* Stagger animation for cards */
.marketplace-card:nth-child(1) { animation-delay: 0.1s; }
.marketplace-card:nth-child(2) { animation-delay: 0.15s; }
.marketplace-card:nth-child(3) { animation-delay: 0.2s; }
.marketplace-card:nth-child(4) { animation-delay: 0.25s; }
.marketplace-card:nth-child(5) { animation-delay: 0.3s; }
.marketplace-card:nth-child(6) { animation-delay: 0.35s; }
.marketplace-card:nth-child(7) { animation-delay: 0.4s; }
.marketplace-card:nth-child(8) { animation-delay: 0.45s; }



