
.home-root {
    display: flex;
    flex-direction: column;
    gap: 28px;
    width: 100%;
    box-sizing: border-box;
    padding: 0 16px 24px 16px;
}

/* ---------- Greeting ---------- */

.home-greeting {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.home-greeting__text {
    font-family: var(--third-family);
    font-weight: 600;
    font-size: 24px;
    line-height: 1.2;
    color: var(--text-dark-color);
    margin: 0;
}

.home-greeting__sub {
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 14px;
    color: var(--gray-600);
    margin: 0;
}

/* ---------- Section header (title + chevron-right) ---------- */

.home-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    min-width: 0;
}

.home-section__header {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: inherit;
    align-self: flex-start;
    text-align: left;
}

    .home-section__header--static {
        cursor: default;
    }

.home-section__title {
    font-family: var(--font-family);
    font-weight: 600;
    font-size: 18px;
    line-height: 28px;
    color: var(--text-dark-color);
    margin: 0;
}

.home-section__chevron {
    display: inline-flex;
    align-items: center;
    color: var(--text-gray-color);
}

.home-section__empty {
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 14px;
    color: var(--gray-500);
    margin: 0;
    padding: 12px 0;
}

/* ---------- Horizontal scroller ---------- */

.home-scroller {
    display: flex;
    flex-direction: row;
    gap: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

    .home-scroller::-webkit-scrollbar {
        display: none;
    }

    .home-scroller > * {
        scroll-snap-align: start;
    }

/* ---------- Theme card (with gradient) ---------- */

.theme-card {
    position: relative;
    flex: 0 0 auto;
    width: 160px;
    height: 160px;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    color: #FFFFFF;
    box-shadow: 0 4px 12px rgba(22, 30, 57, .12);
    transition: transform .15s ease, box-shadow .15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    /* default background — overridden by inline style from the server gradient */
    background: #1CCD9D;
}

    .theme-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 20px rgba(22, 30, 57, .2);
    }

.theme-card--skeleton {
    background: var(--gray-300);
    cursor: default;
    box-shadow: none;
}

    .theme-card--skeleton:hover {
        transform: none;
        box-shadow: none;
    }

.theme-card__bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    opacity: .9;
}

.theme-card__title {
    position: relative;
    z-index: 1;
    font-family: var(--third-family);
    font-weight: 600;
    font-size: 18px;
    line-height: 1.2;
    color: #FFFFFF;
    text-transform: uppercase;
    text-align: center;
    padding: 12px;
    max-width: 140px;
    text-shadow: 0 2px 6px rgba(0, 0, 0, .25);
    word-break: break-word;
}

/* ---------- User card (author carousel) ---------- */

.user-card {
    flex: 0 0 auto;
    width: 96px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    transition: transform .15s ease;
}

    .user-card:hover {
        transform: translateY(-2px);
    }

.user-card--skeleton {
    cursor: default;
}

    .user-card--skeleton:hover {
        transform: none;
    }

.user-card__avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--gray-200);
}

.user-card__avatar--skeleton {
    background: var(--gray-300);
}

.user-card__name {
    width: 100%;
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 13px;
    color: var(--text-gray-dark-color);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

/* ============================================================
   Tablet / desktop overrides
   ============================================================ */

@media (min-width: 768px) {

    .home-root {
        gap: 32px;
        padding: 0 8px 24px 8px;
        height: 100%;
        max-height: 100%;
        overflow-y: auto;
        overflow-x: hidden;
        scrollbar-width: thin;
    }

        .home-root::-webkit-scrollbar { width: 6px; }
        .home-root::-webkit-scrollbar-thumb {
            background-color: rgba(135, 148, 168, .35);
            border-radius: 6px;
        }

    .home-greeting__text {
        font-size: 28px;
    }

    .home-greeting__sub {
        font-size: 15px;
    }

    .home-section__title {
        font-size: 20px;
    }

    .theme-card {
        width: 180px;
        height: 180px;
    }

    .theme-card__title {
        font-size: 20px;
        max-width: 160px;
    }
}

@media (min-width: 1024px) {

    .home-root {
        padding: 0 22px 24px 22px;
    }

    .home-greeting__text {
        font-size: 32px;
    }
}
