/* shop_style.css – Premium Agriculture E-Commerce Styles */

:root {
    /* Core palette */
    --primary-green: #1B5E20;
    --secondary-green: #2E7D32;
    --accent-green: #4CAF50;
    --earth-dark: #5D4037;
    --earth-light: #A1887F;
    --white: #FFFFFF;
    --off-white: #FDFDFD;
    --gray-bg: #F4F7F6;
    --gray-light: #F0F2F1;
    --gray-medium: #9E9E9E;
    --gray-dark: #424242;
    --text-dark: #212121;
    --text-muted: #616161;

    /* Shadows & transitions */
    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    --card-shadow-hover: 0 16px 32px rgba(0, 0, 0, 0.12);
    --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1.2);
    --border-radius-card: 16px;
    --border-radius-input: 10px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--gray-bg);
    color: var(--text-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* ===== Hero Banner ===== */
.shop-hero {
    background: linear-gradient(135deg, var(--primary-green) 0%, #143D16 100%);
    padding: 80px 24px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.shop-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 70%, rgba(255,255,255,0.05) 0%, transparent 50%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    max-width: 720px;
    margin: 0 auto;
}

.hero-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--white);
    letter-spacing: -0.5px;
    margin-bottom: 16px;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.2rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    max-width: 560px;
    margin: 0 auto;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* ===== Filter & Sort Bar ===== */
.filter-bar {
    padding: 24px 24px 0;
    max-width: 1400px;
    margin: 0 auto 8px;
}

.filter-bar-inner {
    background: var(--white);
    border-radius: var(--border-radius-input);
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.sort-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sort-label {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--gray-dark);
    white-space: nowrap;
}

.custom-select-wrapper {
    position: relative;
    min-width: 180px;
}

.sort-select {
    appearance: none;
    -webkit-appearance: none;
    width: 100%;
    padding: 10px 40px 10px 16px;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: var(--text-dark);
    background-color: var(--gray-light);
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23424242' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 12px;
}

.sort-select:hover {
    border-color: var(--secondary-green);
}

.sort-select:focus {
    outline: none;
    border-color: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(27, 94, 32, 0.15);
}

.search-group {
    position: relative;
    flex: 1;
    min-width: 220px;
    max-width: 340px;
}

.search-input {
    width: 100%;
    padding: 10px 44px 10px 16px;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: var(--text-dark);
    background: var(--gray-light);
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 8px;
    transition: var(--transition-smooth);
}

.search-input::placeholder {
    color: var(--gray-medium);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(27, 94, 32, 0.15);
}

.search-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-medium);
    pointer-events: none;
}

/* ===== Product Grid ===== */
.products-section {
    max-width: 1400px;
    margin: 24px auto 60px;
    padding: 0 24px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 28px;
}

/* Empty state */
.empty-products {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 24px;
    color: var(--text-muted);
    font-size: 1.1rem;
    background: var(--white);
    border-radius: var(--border-radius-card);
    box-shadow: var(--card-shadow);
}

/* Product card */
.product-card {
    background: var(--white);
    border-radius: var(--border-radius-card);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--card-shadow-hover);
}

.card-image {
    width: 100%;
    padding-top: 75%; /* 4:3 aspect ratio */
    position: relative;
    overflow: hidden;
    background: #F1F8E9; /* light green tint */
}

.card-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .card-image img {
    transform: scale(1.05);
}

.card-details {
    padding: 20px 18px 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 8px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--secondary-green);
    margin: 8px 0 16px;
    letter-spacing: -0.3px;
}

.btn-view-product {
    display: inline-block;
    margin-top: auto;
    text-align: center;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    color: var(--white);
    background-color: var(--primary-green);
    padding: 12px 20px;
    border-radius: 10px;
    transition: var(--transition-smooth);
    border: 2px solid transparent;
    letter-spacing: 0.2px;
}

.btn-view-product:hover {
    background-color: var(--secondary-green);
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(27, 94, 32, 0.3);
}

.btn-view-product:active {
    transform: scale(0.98);
}

/* ===== Responsive Breakpoints ===== */
@media screen and (max-width: 1199px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
}

@media screen and (max-width: 991px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .hero-title {
        font-size: 2.4rem;
    }
    
    .shop-hero {
        padding: 60px 20px;
    }
    
    .filter-bar-inner {
        flex-direction: column;
        align-items: stretch;
    }
    
    .search-group {
        max-width: 100%;
    }
}

@media screen and (max-width: 600px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .sort-group {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }
    
    .custom-select-wrapper {
        width: 100%;
    }
    
    .search-group {
        width: 100%;
    }
}