.watch-history-section {
    padding: 34px 0 10px;
}

.watch-history-section[hidden] {
    display: none !important;
}

.watch-history-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.watch-history-heading h2 {
    margin: 0;
    color: #f2f3f5;
    font-size: 24px;
    line-height: 1.2;
    font-weight: 700;
}

.watch-history-heading p {
    margin: 6px 0 0;
    color: #969fa9;
    font-size: 13px;
}


.watch-history-view-all {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    color: #c9cfd6;
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
}

.watch-history-view-all:hover,
.watch-history-view-all:focus {
    color: #fff;
    outline: none;
}

.watch-history-view-all span {
    color: #e3262e;
    font-size: 17px;
    line-height: 1;
}

.watch-history-kicker {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 7px;
    color: #e3262e;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.watch-history-row-shell {
    position: relative;
}

.watch-history-row {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(142px, 172px);
    gap: 16px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 2px 2px 14px;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    scrollbar-color: #313841 transparent;
}

.watch-history-card {
    position: relative;
    min-width: 0;
    scroll-snap-align: start;
}

.watch-history-card-link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.watch-history-poster {
    position: relative;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border-radius: 10px;
    background: #151a20;
    border: 1px solid #242b33;
}

.watch-history-poster img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .2s ease, opacity .2s ease;
}

.watch-history-card-link:hover .watch-history-poster img {
    transform: scale(1.025);
    opacity: .92;
}

.watch-history-badge {
    position: absolute;
    left: 8px;
    bottom: 8px;
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 3px 7px;
    border-radius: 999px;
    background: rgba(8, 11, 15, .86);
    color: #f2f3f5;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    backdrop-filter: blur(5px);
}

.watch-history-remove {
    position: absolute;
    z-index: 3;
    top: 7px;
    right: 7px;
    width: 27px;
    height: 27px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 50%;
    background: rgba(8, 11, 15, .82);
    color: #f2f3f5;
    font-size: 20px;
    line-height: 23px;
    cursor: pointer;
    opacity: .78;
}

.watch-history-remove:hover,
.watch-history-remove:focus {
    opacity: 1;
    background: #e3262e;
    border-color: #e3262e;
    outline: none;
}

.watch-history-card-body {
    padding-top: 10px;
}

.watch-history-title {
    margin: 0;
    overflow: hidden;
    color: #f2f3f5;
    font-size: 14px;
    line-height: 1.35;
    font-weight: 650;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.watch-history-meta {
    margin-top: 5px;
    overflow: hidden;
    color: #969fa9;
    font-size: 12px;
    line-height: 1.35;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.watch-history-resume {
    margin-top: 7px;
    color: #d7dbe0;
    font-size: 11px;
    line-height: 1.35;
}

.watch-history-progress {
    height: 4px;
    margin-top: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #242b33;
}

.watch-history-progress-bar {
    display: block;
    height: 100%;
    min-width: 3px;
    border-radius: inherit;
    background: #e3262e;
}

.watch-history-continue {
    padding-top: 24px;
}

.watch-history-recent {
    padding-top: 12px;
    padding-bottom: 16px;
}

@media (max-width: 768px) {
    .watch-history-section {
        padding-top: 26px;
    }

    .watch-history-heading {
        margin-bottom: 14px;
    }

    .watch-history-heading h2 {
        font-size: 21px;
    }

    .watch-history-heading p {
        display: none;
    }

    .watch-history-row {
        grid-auto-columns: minmax(126px, 144px);
        gap: 12px;
        margin-right: -14px;
        padding-right: 14px;
    }

    .watch-history-title {
        font-size: 13px;
    }
}
