/* Enhanced Store Products Design */
/* Modern, clean product cards for the store page */

/* Products Grid Container */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    padding: 20px 0;
    width: 100%;
    max-width: 100%;
}

/* Individual Product Card */
.product-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #f1f5f9;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
    border-color: #e2e8f0;
}

/* Product Image Container */
.product-image {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid #f1f5f9;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 20px;
}

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

/* Product Placeholder for Missing Images */
.product-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed #e2e8f0;
    border-radius: 8px;
    position: relative;
}

.placeholder-text {
    font-size: 16px;
    font-weight: 600;
    color: #64748b;
    text-align: center;
    padding: 20px;
    line-height: 1.4;
    word-break: break-word;
    max-width: 90%;
}

.product-placeholder::before {
    content: "📦";
    font-size: 48px;
    opacity: 0.3;
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.product-placeholder .placeholder-text {
    margin-top: 60px;
}

/* Legacy No Image Placeholder - Simple White */
.no-image-placeholder {
    width: 100%;
    height: 100%;
    display: block;
    background: #ffffff;
    border: none;
}

/* Product Badges */
.product-badges {
    position: absolute;
    top: 12px;
    left: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    z-index: 2;
}

.product-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1;
    color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(4px);
}

.product-badge.sale {
    background: linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
    animation: pulse 2s infinite;
}

.product-badge.new {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.product-badge.hot {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.product-badge.limited {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

/* Stock Badge */
.stock-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
}

.stock-badge.in-stock {
    background: rgba(16, 185, 129, 0.9);
    color: white;
}

.stock-badge.out-of-stock {
    background: rgba(239, 68, 68, 0.9);
    color: white;
}

/* Product Actions Overlay */
.product-actions-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 3;
}

.product-card:hover .product-actions-overlay {
    opacity: 1;
}

.action-btn {
    background: white;
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.action-btn:hover {
    transform: scale(1.1);
    background: #f8fafc;
}

.action-btn i {
    font-size: 18px;
    color: #374151;
}

.action-btn.wishlist:hover i {
    color: #ef4444;
}

.action-btn.quick-view:hover i {
    color: #3b82f6;
}

.action-btn.share:hover i {
    color: #10b981;
}

/* Product Action Bar */
.product-action-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    padding: 20px 16px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.product-card:hover .product-action-bar {
    opacity: 1;
}

.stock-indicator {
    color: white;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.add-to-cart-text {
    color: white;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.add-to-cart-text:hover {
    color: #fbbf24;
}

/* Product Content */
.product-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-category {
    font-size: 12px;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    font-weight: 500;
}

.product-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin: 0 0 12px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    cursor: pointer;
    transition: color 0.3s ease;
}

.product-title:hover {
    color: #3b82f6;
}

.product-description {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
    margin: 0 0 16px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Stock Status */
.stock-status {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 16px;
}

.checkmark {
    color: #10b981;
    font-size: 14px;
}

.status-text {
    font-size: 12px;
    color: #10b981;
    font-weight: 500;
}

/* Product Meta (Price) */
.product-meta {
    margin-top: auto;
}

.product-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 16px;
}

.current-price {
    font-size: 20px;
    font-weight: 700;
    color: #1f2937;
}

.original-price {
    font-size: 14px;
    color: #9ca3af;
    text-decoration: line-through;
}

.discount-percentage {
    background: #fef3c7;
    color: #92400e;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

/* Product Actions */
.product-actions {
    display: flex;
    gap: 8px;
}

.btn-primary, .btn-secondary {
    flex: 1;
    padding: 12px 16px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: #3b82f6;
    color: white;
}

.btn-primary:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.btn-primary:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
}

.btn-secondary {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.btn-secondary:hover {
    background: #e5e7eb;
    transform: translateY(-1px);
}

/* Animations */
@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Responsive Design */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 16px;
        padding: 16px 0;
    }
    
    .product-image {
        height: 200px;
    }
    
    .product-content {
        padding: 16px;
    }
    
    .product-title {
        font-size: 15px;
    }
    
    .current-price {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .product-image {
        height: 180px;
    }
    
    .product-content {
        padding: 12px;
    }
}

/* Loading State */
.products-grid.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    color: #6b7280;
    font-size: 16px;
}

/* Empty State */
.products-grid.empty {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    color: #6b7280;
    font-size: 16px;
    text-align: center;
}
