/* MyBooze Template - Shop & Category Pages Styles */
/* Consolidating shop, category, and search page inline styles */

/* CSS Variables - same as main template */
:root {
    --primary-color: #FF6B35;
    --secondary-color: #67001b;
    --primary-hover: #e55a2b;
    --secondary-hover: #4d0014;
    --accent-color: #ff9f1a;
    --accent-hover: #e68900;
    --text-primary: #333333;
    --text-secondary: #6c757d;
    --text-light: #ffffff;
    --border-color: #e0e0e0;
    --background-color: #ffffff;
    --background-light: #f8f9fa;
    --success-color: #28a745;
    --success-hover: #218838;
    --danger-color: #dc3545;
    --danger-hover: #c82333;
    --info-color: #17a2b8;
    --warning-color: #ffc107;
}

/* Essential Bootstrap Flexbox Utilities */
.d-flex {
    display: -webkit-box !important;
    display: -ms-flexbox !important;
    display: flex !important;
}

.justify-content-center {
    -webkit-box-pack: center !important;
    -ms-flex-pack: center !important;
    justify-content: center !important;
}

.justify-content-start {
    -webkit-box-pack: start !important;
    -ms-flex-pack: start !important;
    justify-content: flex-start !important;
}

.justify-content-end {
    -webkit-box-pack: end !important;
    -ms-flex-pack: end !important;
    justify-content: flex-end !important;
}

.justify-content-between {
    -webkit-box-pack: justify !important;
    -ms-flex-pack: justify !important;
    justify-content: space-between !important;
}

.align-items-center {
    -webkit-box-align: center !important;
    -ms-flex-align: center !important;
    align-items: center !important;
}

.align-items-start {
    -webkit-box-align: start !important;
    -ms-flex-align: start !important;
    align-items: flex-start !important;
}

.align-items-end {
    -webkit-box-align: end !important;
    -ms-flex-align: end !important;
    align-items: flex-end !important;
}

/* ================== SHOP PAGE LAYOUT ================== */

.shop-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.shop-header {
    text-align: center;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid var(--border-color);
}

.shop-title {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.shop-description {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ================== FILTERS & SORTING ================== */

.filters-section {
    background: var(--background-light);
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.filters-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    align-items: end;
}

.filter-group {
    display: flex;
    flex-direction: column;
}

.filter-label {
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.filter-select,
.filter-input {
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    background-color: var(--background-color);
    transition: border-color 0.3s ease;
}

.filter-select:focus,
.filter-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.filter-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
}

.price-range {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.price-range input {
    flex: 1;
}

.price-separator {
    color: var(--text-secondary);
    font-weight: 500;
}

.filter-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.btn-filter {
    background-color: var(--primary-color);
    color: var(--text-light);
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-filter:hover {
    background-color: var(--primary-hover);
}

.btn-clear {
    background-color: transparent;
    color: var(--text-secondary);
    border: 2px solid var(--border-color);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-clear:hover {
    background-color: var(--background-light);
    color: var(--text-primary);
}

/* ================== BREADCRUMBS ================== */

.breadcrumb-nav {
    margin-bottom: 2rem;
    padding: 1rem;
    background: var(--background-light);
    border-radius: 8px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 0.95rem;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    color: var(--text-secondary);
}

.breadcrumb-item:not(:last-child)::after {
    content: '>';
    margin: 0 0.5rem;
    color: var(--text-secondary);
}

.breadcrumb-item a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-item a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

.breadcrumb-item.active {
    color: var(--text-primary);
    font-weight: 500;
}

/* ================== CATEGORY HEADER ================== */

.category-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 12px;
    color: var(--text-light);
}

.category-title {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.category-description {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.category-stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1.5rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 600;
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* ================== PRODUCT GRID ================== */

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.product-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.product-image-container {
    position: relative;
    padding-bottom: 75%; /* 4:3 aspect ratio */
    overflow: hidden;
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: var(--danger-color);
    color: var(--text-light);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    z-index: 2;
}

.product-badge.sale {
    background: var(--danger-color);
}

.product-badge.new {
    background: var(--success-color);
}

.product-badge.featured {
    background: var(--warning-color);
    color: var(--text-primary);
}

.product-actions {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    opacity: 0;
    transform: translateX(10px);
    transition: all 0.3s ease;
}

.product-card:hover .product-actions {
    opacity: 1;
    transform: translateX(0);
}

.action-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: var(--background-color);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.action-btn:hover {
    background: var(--primary-color);
    color: var(--text-light);
}

.product-info {
    padding: 1.5rem;
}

.product-category {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.product-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.product-title a:hover {
    color: var(--primary-color);
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.stars {
    display: flex;
    color: var(--warning-color);
}

.rating-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.product-pricing {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.current-price {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-color);
}

.original-price {
    font-size: 1rem;
    color: var(--text-secondary);
    text-decoration: line-through;
}

.discount-percent {
    background: var(--danger-color);
    color: var(--text-light);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
}

.product-cart-btn {
    width: 100%;
    background: var(--primary-color);
    color: var(--text-light);
    border: none;
    padding: 0.75rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.product-cart-btn:hover {
    background: var(--primary-hover);
}

.product-cart-btn:disabled {
    background: var(--text-secondary);
    cursor: not-allowed;
}

/* ================== PAGINATION ================== */

.pagination-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 3rem;
}

.pagination {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.page-item {
    display: flex;
}

.page-link {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    background: var(--background-color);
    color: var(--text-primary);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    min-width: 44px;
    text-align: center;
}

.page-link:hover {
    background: var(--primary-color);
    color: var(--text-light);
    border-color: var(--primary-color);
    text-decoration: none;
}

.page-item.active .page-link {
    background: var(--primary-color);
    color: var(--text-light);
    border-color: var(--primary-color);
}

.page-item.disabled .page-link {
    background: var(--background-light);
    color: var(--text-secondary);
    cursor: not-allowed;
}

/* ================== SEARCH RESULTS ================== */

.search-header {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--background-light);
    border-radius: 8px;
}

.search-query {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.search-results-count {
    color: var(--text-secondary);
    font-size: 1rem;
}

.search-suggestions {
    margin-top: 1rem;
}

.suggestions-title {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.suggestion-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.suggestion-tag {
    background: var(--primary-color);
    color: var(--text-light);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.suggestion-tag:hover {
    background: var(--primary-hover);
    color: var(--text-light);
    text-decoration: none;
}

.no-results {
    text-align: center;
    padding: 4rem 2rem;
}

.no-results-icon {
    font-size: 4rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.no-results-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.no-results-message {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.suggest-product-btn {
    background: var(--primary-color);
    color: var(--text-light);
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.suggest-product-btn:hover {
    background: var(--primary-hover);
    color: var(--text-light);
    text-decoration: none;
}

/* ================== STOCK NOTIFICATION ================== */

.stock-notification {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--info-color);
    color: var(--text-light);
    border-radius: 8px;
    text-align: center;
}

.notification-title {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.notification-form {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.notification-input {
    flex: 1;
    padding: 0.5rem;
    border: none;
    border-radius: 4px;
    font-size: 0.9rem;
}

.notification-btn {
    background: var(--secondary-color);
    color: var(--text-light);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.notification-btn:hover {
    background: var(--secondary-hover);
}

/* ================== RESPONSIVE DESIGN ================== */

@media (max-width: 1024px) {
    .shop-container {
        padding: 1.5rem 1rem;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1.5rem;
    }
    
    .filters-row {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

@media (max-width: 768px) {
    .shop-title {
        font-size: 2rem;
    }
    
    .category-title {
        font-size: 2rem;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 1rem;
    }
    
    .filters-section {
        padding: 1rem;
    }
    
    .filters-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .filter-actions {
        flex-direction: column;
    }
    
    .btn-filter,
    .btn-clear {
        width: 100%;
    }
    
    .category-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .product-actions {
        position: static;
        flex-direction: row;
        justify-content: center;
        opacity: 1;
        transform: none;
        margin-top: 1rem;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 0.25rem;
    }
    
    .page-link {
        padding: 0.5rem 0.75rem;
        min-width: 36px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .shop-container {
        padding: 1rem 0.5rem;
    }
    
    .shop-title {
        font-size: 1.5rem;
    }
    
    .category-title {
        font-size: 1.5rem;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
    
    .product-info {
        padding: 1rem;
    }
    
    .product-title {
        font-size: 1rem;
    }
    
    .current-price {
        font-size: 1.1rem;
    }
    
    .search-query {
        font-size: 1.2rem;
    }
    
    .no-results {
        padding: 2rem 1rem;
    }
    
    .no-results-icon {
        font-size: 3rem;
    }
    
    .no-results-title {
        font-size: 1.4rem;
    }
    
    .notification-form {
        flex-direction: column;
    }
}

/* ================== LOADING STATES ================== */

.products-loading {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.product-skeleton {
    background: var(--background-light);
    border-radius: 12px;
    overflow: hidden;
    animation: pulse 1.5s ease-in-out infinite;
}

.skeleton-image {
    height: 210px;
    background: linear-gradient(90deg, var(--background-light) 25%, var(--border-color) 50%, var(--background-light) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

.skeleton-content {
    padding: 1.5rem;
}

.skeleton-line {
    height: 1rem;
    background: linear-gradient(90deg, var(--background-light) 25%, var(--border-color) 50%, var(--background-light) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
    margin-bottom: 0.75rem;
}

.skeleton-line.short {
    width: 60%;
}

.skeleton-line.medium {
    width: 80%;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* ================== ANIMATIONS ================== */

.product-card {
    animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.filters-section {
    animation: slideInDown 0.5s ease-out;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
