/**
 * FEATURED-CONTENT.CSS - Bento Grids and Hero Sections
 * Featured store displays and promotional content layouts
 * 
 * @package StileSalentino
 * @version 2.1.0
 */

/* =============================================================
   FEATURED STORES SECTION
   ============================================================= */

.featured-stores {
    margin-bottom: var(--space-4xl, 64px);
}

.featured-stores__header {
    text-align: center;
    margin-bottom: var(--space-3xl, 48px);
}

.featured-stores__title {
    font-size: var(--font-size-4xl, 2.25rem);
    font-weight: 700;
    margin-bottom: var(--space-sm, 12px);
    color: var(--text-primary, #111827);
}

.featured-stores__subtitle {
    font-size: var(--font-size-lg, 1.125rem);
    color: var(--text-secondary, #6b7280);
    max-width: 600px;
    margin: 0 auto;
}

.featured-stores--empty {
    text-align: center;
    padding: var(--space-3xl, 48px) var(--space-md, 20px);
    background: var(--color-background, #f9fafb);
    border-radius: var(--radius-lg, 12px);
    border: 2px dashed var(--color-border, #e5e7eb);
}

.featured-stores__empty-message {
    color: var(--text-muted, #9ca3af);
    font-style: italic;
}

/* =============================================================
   BENTO GRID SYSTEM
   ============================================================= */

.bento-grid {
    display: grid;
    gap: var(--bento-gap, 16px);
    height: var(--bento-height, 450px);
    border-radius: var(--radius-lg, 16px);
    overflow: hidden;
}

/* Dynamic grid layouts based on item count */
.bento-grid--1 {
    grid-template-columns: 1fr;
}

.bento-grid--2 {
    grid-template-columns: 1.618fr 1fr; /* Golden ratio */
}

.bento-grid--3 {
    grid-template-columns: 2fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.bento-grid--4 {
    grid-template-columns: 2fr 1fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.bento-grid--5 {
    grid-template-columns: 2fr 1fr 1fr;
    grid-template-rows: 1fr 1fr;
}

/* Grid item positioning */
.bento-grid--3 .bento-item--1 { grid-column: 1; grid-row: 1 / span 2; }
.bento-grid--3 .bento-item--2 { grid-column: 2; grid-row: 1; }
.bento-grid--3 .bento-item--3 { grid-column: 2; grid-row: 2; }

.bento-grid--4 .bento-item--1 { grid-column: 1; grid-row: 1 / span 2; }
.bento-grid--4 .bento-item--2 { grid-column: 2; grid-row: 1; }
.bento-grid--4 .bento-item--3 { grid-column: 2; grid-row: 2; }
.bento-grid--4 .bento-item--4 { grid-column: 3; grid-row: 1 / span 2; }

.bento-grid--5 .bento-item--1 { grid-column: 1; grid-row: 1 / span 2; }
.bento-grid--5 .bento-item--2 { grid-column: 2; grid-row: 1; }
.bento-grid--5 .bento-item--3 { grid-column: 3; grid-row: 1; }
.bento-grid--5 .bento-item--4 { grid-column: 2; grid-row: 2; }
.bento-grid--5 .bento-item--5 { grid-column: 3; grid-row: 2; }

/* =============================================================
   BENTO GRID ITEMS
   ============================================================= */

.bento-item {
    position: relative;
    background: var(--bento-item-bg, #f3f4f6);
    border-radius: var(--bento-item-radius, 12px);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bento-item:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-lg, 0 8px 25px rgba(0, 0, 0, 0.15));
    z-index: 2;
}

.bento-item__image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.bento-item__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.bento-item:hover .bento-item__image img {
    transform: scale(1.05);
}

.bento-item__placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bento-item-bg, #f3f4f6);
    color: var(--text-muted, #9ca3af);
    font-size: 3rem;
    z-index: 1;
}

/* =============================================================
   BENTO ITEM OVERLAY
   ============================================================= */

.bento-item__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
    padding: var(--space-xl, 32px) var(--space-lg, 24px) var(--space-lg, 24px);
    color: white;
    transform: translateY(10px);
    opacity: 0;
    transition: all 0.3s ease;
}

.bento-item:hover .bento-item__overlay {
    transform: translateY(0);
    opacity: 1;
}

.bento-item--1 .bento-item__overlay {
    /* Main item always visible */
    transform: translateY(0);
    opacity: 1;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
}

.bento-item__content {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm, 8px);
}

.bento-item__title {
    margin: 0;
    font-size: var(--bento-item-title-size, 1.25rem);
    font-weight: 600;
    line-height: 1.3;
}

.bento-item--1 .bento-item__title {
    font-size: var(--font-size-2xl, 1.5rem);
    font-weight: 700;
}

.bento-item__title a {
    color: white;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.bento-item__title a:hover {
    opacity: 0.9;
}

.bento-item__category {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    padding: var(--space-xs, 4px) var(--space-sm, 10px);
    border-radius: var(--radius-pill, 16px);
    font-size: var(--font-size-sm, 0.875rem);
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.1);
    align-self: flex-start;
}

.bento-item__meta {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs, 4px);
    font-size: var(--font-size-sm, 0.875rem);
    opacity: 0.9;
}

.bento-item__rating {
    display: flex;
    align-items: center;
    gap: var(--space-xs, 4px);
}

.bento-item__rating-stars {
    color: var(--color-warning, #f59e0b);
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

.bento-item__address {
    display: flex;
    align-items: center;
    gap: var(--space-xs, 4px);
}

/* =============================================================
   HERO SECTION COMPONENT
   ============================================================= */

.hero-section {
    position: relative;
    min-height: var(--hero-min-height, 500px);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--hero-bg, linear-gradient(135deg, #667eea 0%, #764ba2 100%));
    color: white;
    text-align: center;
    margin-bottom: var(--space-4xl, 64px);
    border-radius: var(--hero-border-radius, 16px);
    overflow: hidden;
}

.hero-section__overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.hero-section__content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: var(--space-xl, 40px) var(--space-md, 20px);
}

.hero-section__title {
    font-size: var(--hero-title-size, 3.5rem);
    font-weight: 800;
    margin-bottom: var(--space-lg, 24px);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    line-height: 1.1;
}

.hero-section__subtitle {
    font-size: var(--hero-subtitle-size, 1.25rem);
    margin-bottom: var(--space-xl, 32px);
    opacity: 0.95;
    font-weight: 400;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.hero-section__actions {
    display: flex;
    gap: var(--space-md, 16px);
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

.hero-section__cta {
    font-size: var(--font-size-lg, 1.125rem);
    padding: var(--space-md, 16px) var(--space-xl, 32px);
    background: var(--color-primary, #2563eb);
    color: white;
    border: none;
    border-radius: var(--radius-lg, 8px);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.hero-section__cta:hover {
    background: var(--color-primary-dark, #1d4ed8);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.6);
    color: white;
}

/* =============================================================
   FEATURED STORE CALLOUTS
   ============================================================= */

.store-callout {
    position: relative;
    background: var(--store-callout-bg, linear-gradient(135deg, #f093fb 0%, #f5576c 100%));
    border-radius: var(--radius-xl, 20px);
    padding: var(--space-2xl, 40px);
    color: white;
    text-align: center;
    margin-bottom: var(--space-xl, 32px);
    overflow: hidden;
}

.store-callout::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
    background-size: 20px 20px;
    opacity: 0.5;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.store-callout__content {
    position: relative;
    z-index: 2;
}

.store-callout__title {
    font-size: var(--font-size-2xl, 1.5rem);
    font-weight: 700;
    margin-bottom: var(--space-md, 16px);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.store-callout__description {
    margin-bottom: var(--space-lg, 24px);
    opacity: 0.95;
}

.store-callout__actions {
    display: flex;
    gap: var(--space-md, 16px);
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

/* =============================================================
   STATS SHOWCASE
   ============================================================= */

.stats-showcase {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--space-lg, 24px);
    padding: var(--space-2xl, 40px);
    background: var(--stats-bg, linear-gradient(135deg, #667eea 0%, #764ba2 100%));
    border-radius: var(--radius-xl, 16px);
    color: white;
    margin-bottom: var(--space-xl, 32px);
}

.stat-item {
    text-align: center;
    padding: var(--space-lg, 20px);
}

.stat-item__number {
    display: block;
    font-size: var(--font-size-4xl, 2.5rem);
    font-weight: 800;
    line-height: 1;
    margin-bottom: var(--space-sm, 8px);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    background: linear-gradient(45deg, #ffffff, #e2e8f0);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-item__label {
    font-size: var(--font-size-sm, 0.875rem);
    font-weight: 500;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* =============================================================
   PROMOTIONAL BANNERS
   ============================================================= */

.promo-banner {
    position: relative;
    background: var(--promo-bg, #2563eb);
    color: white;
    padding: var(--space-xl, 32px);
    border-radius: var(--radius-lg, 12px);
    text-align: center;
    margin-bottom: var(--space-xl, 32px);
    overflow: hidden;
}

.promo-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.promo-banner__content {
    position: relative;
    z-index: 2;
}

.promo-banner__title {
    font-size: var(--font-size-xl, 1.25rem);
    font-weight: 700;
    margin-bottom: var(--space-sm, 8px);
}

.promo-banner__text {
    margin-bottom: var(--space-lg, 20px);
    opacity: 0.95;
}

.promo-banner__cta {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: var(--space-sm, 12px) var(--space-lg, 24px);
    border-radius: var(--radius-md, 8px);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.promo-banner__cta:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    color: white;
}

/* =============================================================
   CATEGORY SHOWCASE
   ============================================================= */

.category-showcase {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg, 20px);
    margin-bottom: var(--space-xl, 32px);
}

.category-card {
    position: relative;
    aspect-ratio: 4/3;
    background: var(--category-card-bg, #f3f4f6);
    border-radius: var(--radius-lg, 12px);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl, 0 12px 28px rgba(0, 0, 0, 0.15));
}

.category-card__image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.category-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.category-card__overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.3));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    z-index: 2;
}

.category-card__content {
    text-align: center;
    transform: translateY(10px);
    transition: transform 0.3s ease;
}

.category-card:hover .category-card__content {
    transform: translateY(0);
}

.category-card__title {
    font-size: var(--font-size-xl, 1.25rem);
    font-weight: 700;
    margin-bottom: var(--space-xs, 4px);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.category-card__count {
    font-size: var(--font-size-sm, 0.875rem);
    opacity: 0.9;
}

.category-card__link {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
    text-decoration: none;
}

/* =============================================================
   RESPONSIVE FEATURED CONTENT
   ============================================================= */

@media (max-width: 768px) {
    .bento-grid {
        height: auto;
        grid-template-columns: 1fr !important;
        grid-template-rows: auto !important;
        gap: var(--space-md, 16px);
    }
    
    .bento-item {
        min-height: 200px;
    }
    
    .bento-grid .bento-item--1,
    .bento-grid .bento-item--2,
    .bento-grid .bento-item--3,
    .bento-grid .bento-item--4,
    .bento-grid .bento-item--5 {
        grid-column: 1 !important;
        grid-row: auto !important;
    }
    
    .bento-item__overlay {
        /* Always visible on mobile */
        transform: translateY(0);
        opacity: 1;
        background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    }
    
    .hero-section {
        min-height: var(--hero-min-height-mobile, 400px);
    }
    
    .hero-section__title {
        font-size: var(--hero-title-size-mobile, 2.5rem);
    }
    
    .hero-section__subtitle {
        font-size: var(--hero-subtitle-size-mobile, 1.125rem);
    }
    
    .hero-section__actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .hero-section__cta {
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .stats-showcase {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-md, 16px);
        padding: var(--space-xl, 24px);
    }
    
    .stat-item {
        padding: var(--space-md, 12px);
    }
    
    .stat-item__number {
        font-size: var(--font-size-3xl, 2rem);
    }
    
    .category-showcase {
        grid-template-columns: 1fr;
        gap: var(--space-md, 16px);
    }
    
    .promo-banner {
        padding: var(--space-lg, 24px);
        margin-bottom: var(--space-lg, 24px);
    }
    
    .featured-stores__title {
        font-size: var(--font-size-3xl, 1.875rem);
    }
}

/* =============================================================
   PERFORMANCE OPTIMIZATIONS
   ============================================================= */

.bento-item,
.category-card,
.store-callout {
    will-change: transform;
    backface-visibility: hidden;
    perspective: 1000px;
}

.bento-item__image img,
.category-card__image img {
    will-change: transform;
}

/* =============================================================
   PRINT STYLES
   ============================================================= */

@media print {
    .bento-grid,
    .hero-section,
    .promo-banner,
    .stats-showcase {
        background: white !important;
        color: black !important;
        box-shadow: none !important;
    }
    
    .bento-item__overlay,
    .hero-section__overlay,
    .category-card__overlay {
        display: none !important;
    }
    
    .hero-section__actions,
    .promo-banner__cta,
    .store-callout__actions {
        display: none !important;
    }
    
    .bento-item,
    .category-card {
        break-inside: avoid;
        border: 1px solid #ccc;
    }
}
