/* ============================================================
   home_sections.css
   Секції головної сторінки (hs = home section)
   Підключіть у <head>:
     <link rel="stylesheet" href="<?= BASE_URL ?>css/home_sections.css">
   або додайте до вашого main_page.css
   ============================================================ */

/* ── Обгортка секції ── */
.hs-section-wrapper {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto clamp(32px, 4vw, 60px);
    padding: 0 clamp(12px, 3vw, 40px);
    box-sizing: border-box;
}

.hs-section-inner {
    background: #fdf5f8;
    border-radius: 16px;
    padding: clamp(20px, 3vw, 44px);
}

/* ── Заголовок секції ── */
.hs-section-title {
    text-align: center;
    font-family: var(--font-display, serif);
    font-size: clamp(22px, 2.2vw, 34px);
    font-weight: 600;
    font-style: italic;
    color: var(--ink, #241714);
    margin-bottom: clamp(16px, 2vw, 30px);
    letter-spacing: -0.01em;
}

/* ── Сітка карток ── */
.hs-rows-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(clamp(200px, 28%, 340px), 1fr));
    gap: clamp(14px, 2vw, 28px);
    justify-content: center;
}

/* ── Картка рядка ── */
.hs-row-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(107, 45, 78, 0.08);
    display: flex;
    flex-direction: column;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.hs-row-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 28px rgba(107, 45, 78, 0.16);
}

/* ── Фото ── */
.hs-row-photo-wrap {
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #f9f0f4;
    position: relative;
}

.hs-photo-slider {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.hs-row-photo-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.32s ease;
}
.hs-row-card:hover .hs-row-photo-wrap img {
    transform: scale(1.04);
}

/* ── Текст ── */
.hs-row-text {
    padding: clamp(10px, 1.2vw, 18px) clamp(12px, 1.4vw, 20px);
    font-size: clamp(13px, 0.95vw, 16px);
    line-height: 1.5;
    color: var(--ink, #241714);
    text-align: center;
    flex: 1;
}

/* ── Адаптив ── */
@media (max-width: 700px) {
    .hs-rows-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
}
@media (max-width: 420px) {
    .hs-rows-grid {
        grid-template-columns: 1fr;
    }
    .hs-row-photo-wrap {
        aspect-ratio: 16 / 9;
    }
}
