/* ==========================================================================
   GLOBAL PREMIUM STYLESHEET - HANI NURSERY & GARDENING
   ========================================================================== */

/* Google Fonts Imports */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&display=swap');

:root {
    /* Color Palette */
    --primary-color: #1b5e20;
    --primary-light: #2e7d32;
    --primary-dark: #0d3c13;
    --secondary-color: #d4af37; /* Premium Gold Accent */
    --secondary-light: #f3e5ab;
    --accent-color: #25d366; /* WhatsApp Green */
    --accent-red: #d32f2f;
    --bg-light: #f5fff7; /* Natural leafy green tint */
    --bg-white: #ffffff;
    --text-dark: #212121;
    --text-muted: #666666;
    --border-color: #e0e0e0;
    
    /* Premium Shadows */
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.03);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    
    /* Layout Variables */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base resets & styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-light);
    color: var(--text-dark);
    font-family: 'Outfit', 'Segoe UI', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Premium Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--primary-dark);
}

.serif-font {
    font-family: 'Playfair Display', Georgia, serif;
}

/* --- Premium Buttons --- */
.btn-premium {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
    color: var(--bg-white) !important;
    font-weight: 600;
    font-size: 15px;
    padding: 12px 28px;
    border-radius: var(--radius-full);
    border: none;
    cursor: pointer;
    box-shadow: 0 8px 15px rgba(27, 94, 32, 0.25);
    text-decoration: none;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.btn-premium::after {
    content: '';
    position: absolute;
    top: 0;
    left: -50%;
    width: 200%;
    height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    transition: 0.75s;
    opacity: 0;
}

.btn-premium:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 20px rgba(27, 94, 32, 0.35);
}

.btn-premium:hover::after {
    left: 125%;
    opacity: 1;
}

.btn-premium-gold {
    background: linear-gradient(135deg, var(--secondary-color), #b58915);
    box-shadow: 0 8px 15px rgba(181, 137, 21, 0.25);
}

.btn-premium-gold:hover {
    box-shadow: 0 12px 20px rgba(181, 137, 21, 0.35);
}

/* --- Premium Product Card --- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
    padding: 20px 0;
}

.product-card {
    background: var(--bg-white);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition-smooth);
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.02);
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.product-image-container {
    width: 100%;
    height: 220px;
    overflow: hidden;
    position: relative;
    background-color: #f0f4f1;
}

.product-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}

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

/* Wishlist Heart Icon Badge */
.wishlist-heart-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(5px);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    z-index: 10;
    transition: var(--transition-smooth);
    color: var(--text-muted);
    font-size: 18px;
}

.wishlist-heart-btn:hover {
    transform: scale(1.1);
    background: var(--bg-white);
    color: var(--accent-red);
}

.wishlist-heart-btn.liked {
    color: var(--accent-red);
}

/* Card Content details */
.product-details-box {
    padding: 20px;
    text-align: left;
}

.product-category-tag {
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
    color: var(--primary-light);
    margin-bottom: 5px;
}

.product-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    display: block;
}

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

.product-rating-box {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 12px;
}

.star-icon {
    color: #ffd700;
    font-size: 13px;
}

.rating-count-text {
    font-size: 12px;
    color: var(--text-muted);
}

.product-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 15px;
    border-top: 1px solid #f0f0f0;
    padding-top: 15px;
}

.product-price {
    font-size: 20px;
    font-weight: 800;
    color: var(--primary-color);
}

.btn-add-cart-icon {
    width: 42px;
    height: 42px;
    background: var(--primary-light);
    color: var(--bg-white);
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    box-shadow: 0 4px 8px rgba(46, 125, 50, 0.2);
    transition: var(--transition-smooth);
}

.btn-add-cart-icon:hover {
    background: var(--primary-color);
    transform: rotate(9deg) scale(1.05);
}

/* --- WhatsApp Sticky Floating Bubble --- */
.whatsapp-bubble-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    display: flex;
    align-items: center;
    pointer-events: none;
}

.whatsapp-bubble {
    width: 60px;
    height: 60px;
    background-color: var(--accent-color);
    color: var(--bg-white);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition-smooth);
    pointer-events: auto;
    position: relative;
}

.whatsapp-bubble:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 12px 30px rgba(37, 211, 102, 0.6);
}

.whatsapp-tooltip {
    background: var(--bg-white);
    color: var(--text-dark);
    padding: 10px 18px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    font-size: 13px;
    font-weight: 600;
    margin-right: 15px;
    white-space: nowrap;
    pointer-events: auto;
    opacity: 0;
    transform: translateX(20px);
    transition: var(--transition-smooth);
    border: 1px solid rgba(0,0,0,0.05);
}

.whatsapp-bubble-container:hover .whatsapp-tooltip {
    opacity: 1;
    transform: translateX(0);
}

/* On scroll fold logic handled via JS toggling class */
.whatsapp-bubble-container.folded .whatsapp-tooltip {
    opacity: 0 !important;
    transform: translateX(20px) !important;
}

.whatsapp-bubble-container.folded .whatsapp-bubble {
    width: 48px;
    height: 48px;
    font-size: 24px;
    opacity: 0.8;
}

.whatsapp-bubble-container.folded:hover .whatsapp-bubble {
    opacity: 1;
    width: 60px;
    height: 60px;
    font-size: 30px;
}

/* Glassmorphism Panel background utilities */
.glass-panel {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: var(--radius-md);
}

/* Premium Form Elements */
.form-input-premium {
    width: 100%;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    border: 2px solid rgba(0, 0, 0, 0.08);
    background-color: var(--bg-white);
    font-family: inherit;
    font-size: 15px;
    transition: var(--transition-smooth);
    outline: none;
}

.form-input-premium:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 4px rgba(46, 125, 50, 0.1);
}

/* Toast System */
#toast-premium {
    position: fixed;
    top: 80px;
    right: 30px;
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg-white);
    padding: 15px 25px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    border-left: 5px solid var(--primary-light);
    transform: translateX(120%);
    transition: var(--transition-smooth);
    z-index: 10000;
}

#toast-premium.show {
    transform: translateX(0);
}

#toast-premium-img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: var(--radius-sm);
}

#toast-premium-text {
    font-weight: 600;
    color: var(--text-dark);
}

/* Responsive grid adjustments */
@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }
    
    .whatsapp-bubble-container {
        bottom: 20px;
        right: 20px;
    }
}
