.cm-home-reels {
    margin: 48px auto;
}

.cm-home-reels-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 16px;
    margin: 0;
    padding: 6px 3px 10px;
    list-style: none;
}

.cm-home-reel {
    position: relative;
    min-width: 0;
}

.cm-home-reel-link {
    display: block;
    color: #172438;
    text-decoration: none;
}

.cm-home-reel-cover {
    position: relative;
    display: grid;
    place-items: center;
    aspect-ratio: 9 / 16;
    overflow: hidden;
    border-radius: 8px;
    background: #253448;
}

.cm-home-reel-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cm-home-reel-play {
    position: relative;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid #ffffff;
    border-radius: 50%;
    background: #101a28cc;
    color: #fff;
}

.cm-home-reel-link:is(:hover, :focus-visible) .cm-home-reel-play {
    background: #b20c17;
}

.cm-home-reel-link:focus-visible {
    outline: 2px solid #b20c17;
    outline-offset: 2px;
}

.cm-home-reel-title {
    display: block;
    margin-top: 8px;
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.cm-home-reels-editor,
.cm-home-reels-edit-slot {
    position: relative;
    margin-bottom: 12px;
}

.cm-home-reels-edit-slot {
    min-height: 72px;
    padding-top: 48px;
}

.cm-home-reels-player {
    box-sizing: border-box;
    width: min(460px, calc(100% - 24px));
    max-height: calc(100dvh - 24px);
    padding: 14px;
    border: 0;
    border-radius: 10px;
    background: #fff;
    color: #172438;
}

.cm-home-reels-player::backdrop {
    background: #101a28c9;
}

.cm-home-reels-player-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.cm-home-reels-player-head h3 {
    margin: 0;
    font-size: 1rem;
    overflow-wrap: anywhere;
}

.cm-home-reels-player-head button {
    flex: 0 0 44px;
    height: 44px;
    border: 1px solid #dfe4eb;
    border-radius: 6px;
    background: #fff;
    color: #172438;
    cursor: pointer;
}

.cm-home-reels-player iframe {
    display: block;
    width: 100%;
    height: min(650px, 68dvh);
    border: 0;
}

.cm-home-reels-external {
    display: inline-block;
    margin-top: 10px;
}

@media (max-width: 767px) {
    .cm-home-reels {
        margin: 32px auto;
    }

    .cm-home-reels-grid {
        grid-template-columns: none;
        grid-auto-flow: column;
        grid-auto-columns: min(45%, 180px);
        gap: 12px;
        overflow-x: auto;
        scroll-snap-type: x proximity;
    }

    .cm-home-reel {
        scroll-snap-align: start;
    }
}
