/* ============================================================
   RECETTES EHTYMAG — homepage.css
   Hero · À la une · Vedette · Recentes · Sidebar · CTA
   ============================================================ */

/* ============================================================
   HERO
   ============================================================ */
.hero {
    background: var(--color-cacao);
    padding: var(--spacing-xl) 0 var(--spacing-lg);
}

.hero-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 36px;
    align-items: center;
}

.hero-eyebrow {
    font-size: 10px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-turmeric);
    font-weight: 500;
    margin-bottom: 14px;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(28px, 3.5vw, 42px);
    font-weight: 700;
    color: var(--color-cream);
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.hero-title em {
    font-style: italic;
    color: var(--color-saffron);
}

.hero-sub {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.7;
    font-weight: 300;
    margin-bottom: 28px;
    max-width: 380px;
}

/* Barre de recherche hero */
.search-bar {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-pill);
    padding: 0 6px 0 18px;
    height: 48px;
    gap: 10px;
    transition: border-color 0.2s, background 0.2s;
}

.hero-search.is-focused .search-bar,
.search-bar:focus-within {
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.14);
}

.search-icon {
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.4);
}

.search-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    font-family: var(--font-body);
    font-size: 13px;
    color: var(--color-cream);
    font-weight: 300;
    min-width: 0;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.search-submit {
    background: var(--color-saffron);
    color: #fff;
    border: none;
    border-radius: var(--radius-pill);
    padding: 8px 16px;
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background 0.2s;
}

.search-submit:hover {
    background: var(--color-paprika);
}

/* Vignettes hero */
.hero-visual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 8px;
    height: 240px;
}

.hero-vignette {
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    text-decoration: none;
    transition: opacity 0.2s;
}

.hero-vignette:hover { opacity: 0.9; }

.hero-vignette--main {
    grid-row: 1 / 3;
}

.hero-vignette-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.35;
}

.hero-vignette-overlay {
    position: relative;
    padding: 14px;
    background: linear-gradient(to top, rgba(0,0,0,0.5) 0%, transparent 100%);
}

.hero-vignette-cat {
    display: block;
    font-size: 9px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    margin-bottom: 4px;
}

.hero-vignette-title {
    display: block;
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    line-height: 1.3;
}

.hero-vignette--sm .hero-vignette-title {
    font-size: 11px;
}

/* ============================================================
   SECTION À LA UNE
   ============================================================ */
.section-alune {
    padding: var(--spacing-lg) 0 0;
}

.section-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.alune-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

/* ============================================================
   HOMEPAGE BODY (contenu + sidebar)
   ============================================================ */
.homepage-body {
    padding: var(--spacing-lg) 0 0;
}

.homepage-layout {
    display: grid;
    grid-template-columns: 1fr 240px;
    gap: 28px;
    align-items: start;
}

.homepage-main {
    min-width: 0;
}

/* ============================================================
   RECETTES EN VEDETTE
   ============================================================ */
.section-vedette {
    margin-bottom: var(--spacing-lg);
}

.vedette-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: auto auto;
    gap: 12px;
}

.vedette-card--main {
    grid-row: 1 / 3;
}

.vedette-card--main .card-thumb {
    height: 200px;
    object-fit: cover;
    width: 100%;
}

.vedette-card--sm .card-thumb {
    height: 110px;
    object-fit: cover;
    width: 100%;
}

/* ============================================================
   DERNIERS ARTICLES
   ============================================================ */
.section-recentes {
    margin-bottom: var(--spacing-lg);
}

.recentes-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.recentes-grid .card-thumb {
    height: 90px;
    object-fit: cover;
    width: 100%;
}

/* ============================================================
   CTA FIGURER
   ============================================================ */
.cta-figurer {
    padding: var(--spacing-lg) 0 var(--spacing-xl);
}

.cta-figurer-inner {
    background: var(--color-sand);
    border-radius: var(--radius-lg);
    padding: 40px 44px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    border: 0.5px solid rgba(59, 32, 16, 0.1);
}

.cta-figurer-eyebrow {
    font-size: 10px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-terracotta);
    font-weight: 500;
    margin-bottom: 8px;
}

.cta-figurer-title {
    font-family: var(--font-display);
    font-size: clamp(20px, 2.5vw, 26px);
    font-weight: 700;
    color: var(--color-cacao);
    line-height: 1.2;
    margin-bottom: 0;
}

.cta-figurer-title em {
    font-style: italic;
    color: var(--color-saffron);
}

.cta-figurer-text {
    font-size: 13px;
    color: #7A5030;
    margin-top: 10px;
    font-weight: 300;
    line-height: 1.65;
    max-width: 480px;
}

.cta-figurer-btn {
    flex-shrink: 0;
    padding: 14px 28px;
    font-size: 13px;
}

/* ============================================================
   RESPONSIVE HOMEPAGE
   ============================================================ */
@media (max-width: 1024px) {
    .homepage-layout {
        grid-template-columns: 1fr;
    }

    .top-stories-sidebar {
        position: static;
    }

    .ts-block {
        max-height: none;
    }

    /* Sidebar passe en grille horizontale sur tablette */
    .ts-list {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
    }

    .ts-item:nth-child(odd) {
        border-right: 0.5px solid rgba(0, 0, 0, 0.06);
    }

    .alune-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .hero-visual {
        height: 180px;
    }

    .hero-sub { max-width: 100%; }

    .vedette-grid {
        grid-template-columns: 1fr;
    }

    .vedette-card--main {
        grid-row: auto;
    }

    .recentes-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .ts-list {
        grid-template-columns: 1fr;
    }

    .ts-item:nth-child(odd) {
        border-right: none;
    }

    .cta-figurer-inner {
        flex-direction: column;
        align-items: flex-start;
        padding: 28px 24px;
    }

    .cta-figurer-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: var(--spacing-lg) 0 var(--spacing-md);
    }

    .hero-visual {
        display: none;
    }

    .alune-grid {
        grid-template-columns: 1fr;
    }

    .recentes-grid {
        grid-template-columns: 1fr;
    }

    .search-bar {
        height: 44px;
    }
}
