/* Enterprise Pro - Frontend Home Premium Styles */

/* === LAYOUT FOUNDATION === */
.home-layout-wrapper {
    display: flex;
    flex-direction: column;
    gap: 4rem;
    padding-bottom: 6rem;
    background: var(--bg-body);
}

.layout-compact {
    gap: 2rem;
}

.layout-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
}

/* === HERO BANNER === */
.hero {
    position: relative;
    width: 100%;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg, #0f172a, #1e293b);
}

.hero[data-hero-type="boxed"] {
    max-width: 1400px;
    margin: 2rem auto 0;
    border-radius: 32px;
    min-height: 500px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.banner-slide {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.banner-slide::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.3));
    z-index: 1;
}

.hero-content {
    text-align: center;
    color: #fff;
    z-index: 2;
    padding: 3rem;
    max-width: 900px;
    animation: heroFadeIn 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-content h1 {
    font-size: 4rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    letter-spacing: -2px;
    text-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
    background: linear-gradient(to right, #fff, var(--accent));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-content p {
    font-size: 1.3rem;
    margin-bottom: 2.5rem;
    opacity: 0.95;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    line-height: 1.6;
}

/* === SECTION TITLES === */
.section-title {
    font-size: 2.2rem;
    font-weight: 900;
    margin-bottom: 2rem;
    text-align: center;
    position: relative;
    letter-spacing: -1px;
    color: var(--text-main);
}

.section-title.text-left {
    text-align: left;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--accent);
    border-radius: 2px;
}

.section-title.text-left::after {
    left: 0;
    transform: none;
}

/* === CATEGORY BUBBLES === */
.category-bubbles {
    padding: 4rem 0;
    background: rgba(255, 255, 255, 0.01);
}

.category-bubbles-wrapper {
    position: relative;
    overflow: hidden;
    padding: 2rem 0;
}

.category-bubbles-scroll {
    display: flex;
    gap: 2rem;
    animation: scrollCategories 40s linear infinite;
}

.category-bubbles-scroll:hover {
    animation-play-state: paused;
}

.category-bubble-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    min-width: 140px;
    text-decoration: none;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-bubble-item:hover {
    transform: translateY(-10px);
}

.category-bubble-img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: 0.3s;
    background: #ffffff;
}

.category-bubble-item:hover .category-bubble-img {
    border-color: var(--accent);
    box-shadow: 0 15px 40px rgba(var(--accent-rgb), 0.4);
}

.category-bubble-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.category-bubble-item:hover .category-bubble-img img {
    transform: scale(1.1);
}

.category-bubble-text {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-main);
    text-align: center;
}

/* === FLASH DEALS SECTION === */
.flash-deals-section {
    background: linear-gradient(135deg, #1e1b4b, #312e81);
    padding: 3rem 2rem;
    border-radius: 32px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(49, 46, 129, 0.5);
}

.flash-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.flash-badge {
    background: var(--accent);
    color: #000;
    padding: 6px 16px;
    border-radius: 50px;
    font-weight: 900;
    font-size: 0.85rem;
    letter-spacing: 1px;
    display: inline-block;
    margin-bottom: 0.5rem;
}

.countdown-timer {
    display: flex;
    gap: 1rem;
}

.timer-unit {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    padding: 1rem 1.5rem;
    border-radius: 12px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.timer-unit .val {
    display: block;
    font-size: 2rem;
    font-weight: 900;
    color: var(--accent);
    line-height: 1;
}

.timer-unit .label {
    display: block;
    font-size: 0.7rem;
    color: #94a3b8;
    margin-top: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.flash-marquee-viewport {
    overflow: hidden;
    width: 100%;
    position: relative;
    padding: 1rem 0;
}

.flash-marquee-track {
    display: flex;
    gap: 2rem;
    width: max-content;
    animation: marqueeScroll 50s linear infinite;
}

.flash-marquee-track:hover {
    animation-play-state: paused;
}

.flash-card {
    width: 300px;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    transition: 0.3s;
}

.flash-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.flash-discount-pill {
    position: absolute;
    top: 15px;
    left: 15px;
    background: #ef4444;
    color: #fff;
    padding: 6px 12px;
    border-radius: 8px;
    font-weight: 900;
    font-size: 0.85rem;
    z-index: 5;
    box-shadow: 0 6px 15px rgba(239, 68, 68, 0.4);
}

.flash-img-wrapper {
    width: 100%;
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1rem;
    background: rgba(0, 0, 0, 0.2);
}

.flash-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.flash-card:hover .flash-img-wrapper img {
    transform: scale(1.1);
}

.card-side-timer {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 8px 12px;
    display: flex;
    gap: 6px;
    font-size: 0.75rem;
    color: #fff;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.card-side-timer .val {
    font-weight: 900;
    color: var(--accent);
    font-size: 1rem;
}

.flash-price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
}

.flash-prices {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.old-price {
    text-decoration: line-through;
    color: #64748b;
    font-size: 0.9rem;
}

.new-price {
    color: var(--accent);
    font-weight: 900;
    font-size: 1.3rem;
}

/* === PRODUCT GRID === */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2.5rem;
}

.product-card {
    background: var(--bg-card);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.product-img {
    width: 100%;
    height: 240px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.1);
    position: relative;
}

.product-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

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

.ai-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 800;
    z-index: 5;
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.5);
}

.product-info {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Badges for Product Card */
.badge-featured {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #fff;
    left: 12px;
}

.badge-sale {
    background: #ef4444;
    color: #fff;
    left: 12px;
    top: 40px;
    /* If both exist, this will space them, though logic might need refine for dynamic grouping */
}

/* Generalized Badge from prev AI badge code */
.product-img .badge {
    position: absolute;
    top: 12px;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 800;
    z-index: 5;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

/* Specific position adjustments if multiple badges */
.product-img .badge.badge-sale {
    /* If it's the only one, top 12px is fine, but if featured exists we might need stacking.
       For simplicity, let's keep it clean or assume one primary badge per corner.
       Let's put Sale on Left, Featured on Right?
       AI Badge is on Right.
    */
    right: auto;
    left: 12px;
}

.product-img .badge.badge-featured {
    /* Let's put Featured on Top Left, Sale below it? */
    right: auto;
    left: 12px;
}

.product-info h3 {
    font-size: 1.1rem;
    margin: 0 0 1rem 0;
    color: var(--text-main);
    line-height: 1.4;
    font-weight: 700;
}

.product-price {
    margin-top: auto;
    margin-bottom: 1rem;
}

.product-price strong {
    font-size: 1.3rem;
    color: var(--accent);
    font-weight: 900;
}

/* === KITCHEN PLANNER CTA === */
.kitchen-planner-cta {
    background: linear-gradient(135deg, #1e1b4b, #312e81);
    border-radius: 32px;
    padding: 4rem;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 25px 60px rgba(49, 46, 129, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.cta-content {
    z-index: 2;
    max-width: 600px;
}

.cta-badge {
    background: var(--accent);
    color: #000;
    padding: 6px 14px;
    border-radius: 6px;
    font-weight: 900;
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
    display: inline-block;
}

.kitchen-planner-cta h2 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    color: #fff;
    font-weight: 900;
    letter-spacing: -1px;
}

.kitchen-planner-cta p {
    font-size: 1.2rem;
    color: #cbd5e1;
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

.planner-image img {
    max-width: 450px;
    filter: drop-shadow(0 25px 50px rgba(0, 0, 0, 0.6));
    transform: rotate(-8deg) translateY(20px);
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.kitchen-planner-cta:hover .planner-image img {
    transform: rotate(0deg) translateY(0);
}

/* === ANIMATIONS === */
@keyframes heroFadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes marqueeScroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

@keyframes scrollCategories {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .hero-content h1 {
        font-size: 3rem;
    }

    .kitchen-planner-cta {
        flex-direction: column;
        text-align: center;
    }

    .planner-image {
        display: none;
    }
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.2rem;
    }

    .flash-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .countdown-timer {
        width: 100%;
        justify-content: space-between;
    }

    .timer-unit {
        padding: 0.8rem 1rem;
    }

    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 1.5rem;
    }
}

 / *   = = =   H O R I Z O N T A L   S C R O L L   L A Y O U T   = = =   * / 
 . l a y o u t - h o r i z o n t a l - s c r o l l   { 
         d i s p l a y :   f l e x ; 
         o v e r f l o w - x :   a u t o ; 
         g a p :   1 . 5 r e m ; 
         p a d d i n g - b o t t o m :   1 . 5 r e m ; 
         s c r o l l - s n a p - t y p e :   x   m a n d a t o r y ; 
         s c r o l l b a r - w i d t h :   t h i n ;   / *   F i r e f o x   * / 
 } 
 
 . l a y o u t - h o r i z o n t a l - s c r o l l : : - w e b k i t - s c r o l l b a r   { 
         h e i g h t :   8 p x ; 
 } 
 
 . l a y o u t - h o r i z o n t a l - s c r o l l : : - w e b k i t - s c r o l l b a r - t r a c k   { 
         b a c k g r o u n d :   r g b a ( 2 5 5 ,   2 5 5 ,   2 5 5 ,   0 . 0 5 ) ; 
         b o r d e r - r a d i u s :   4 p x ; 
 } 
 
 . l a y o u t - h o r i z o n t a l - s c r o l l : : - w e b k i t - s c r o l l b a r - t h u m b   { 
         b a c k g r o u n d :   v a r ( - - a c c e n t ) ; 
         b o r d e r - r a d i u s :   4 p x ; 
 } 
 
 . l a y o u t - h o r i z o n t a l - s c r o l l   . p r o d u c t - c a r d   { 
         m i n - w i d t h :   2 8 0 p x ;   / *   A d j u s t   c a r d   w i d t h   * / 
         s c r o l l - s n a p - a l i g n :   s t a r t ; 
         f l e x - s h r i n k :   0 ;   / *   P r e v e n t   c a r d s   f r o m   s h r i n k i n g   * / 
 } 
  
 