.tvn-shorts {
    --tvn-bg: #0b0c20;
    --tvn-text: #ffffff;
    --tvn-accent: #8f003d;
    --tvn-accent-border: #e5b8ee;
    width: 100%;
    background: var(--tvn-bg);
    color: var(--tvn-text);
    padding: 24px 0 28px;
    box-sizing: border-box;
}

.tvn-shorts *,
.tvn-shorts *::before,
.tvn-shorts *::after {
    box-sizing: border-box;
}

.tvn-shorts__inner {
    width: min(100%, 1420px);
    margin: 0 auto;
    padding: 0 40px;
}

.tvn-shorts__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.tvn-shorts__card {
    position: relative;
    min-width: 0;
    margin: 0;
    overflow: hidden;
    background: #141527;
    aspect-ratio: 16 / 9;
}

.tvn-shorts__link {
    position: absolute;
    inset: 0;
    display: block;
    color: #fff !important;
    text-decoration: none !important;
    overflow: hidden;
}

.tvn-shorts__image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center;
    transform: scale(1.001);
    transition: transform .35s ease, filter .35s ease;
}

.tvn-shorts__shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(3, 4, 15, .02) 15%, rgba(3, 4, 15, .25) 52%, rgba(3, 4, 15, .92) 100%);
    transition: background .25s ease;
}

.tvn-shorts__play {
    position: absolute;
    top: 45%;
    left: 50%;
    width: clamp(52px, 5vw, 64px);
    height: clamp(52px, 5vw, 64px);
    transform: translate(-50%, -50%);
    filter: drop-shadow(0 3px 16px rgba(0, 0, 0, .38));
    transition: transform .22s ease;
}

.tvn-shorts__play svg {
    width: 100%;
    height: 100%;
    display: block;
}

.tvn-shorts__play circle {
    fill: rgba(0, 0, 0, .08);
    stroke: #fff;
    stroke-width: 4;
}

.tvn-shorts__play path {
    fill: #fff;
}

.tvn-shorts__content {
    position: absolute;
    right: 20px;
    bottom: 18px;
    left: 20px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    z-index: 2;
}

.tvn-shorts__video-title {
    display: -webkit-box;
    overflow: hidden;
    color: #fff;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(15px, 1.2vw, 18px);
    font-weight: 700;
    line-height: 1.08;
    text-shadow: 0 2px 10px rgba(0, 0, 0, .55);
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.tvn-shorts__meta {
    overflow: hidden;
    color: rgba(255, 255, 255, .92);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tvn-shorts__link:hover .tvn-shorts__image,
.tvn-shorts__link:focus-visible .tvn-shorts__image {
    transform: scale(1.045);
    filter: brightness(.9);
}

.tvn-shorts__link:hover .tvn-shorts__play,
.tvn-shorts__link:focus-visible .tvn-shorts__play {
    transform: translate(-50%, -50%) scale(1.08);
}

.tvn-shorts__link:focus-visible,
.tvn-shorts-modal__close:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 3px;
}

.tvn-shorts-modal[hidden] {
    display: none;
}

.tvn-shorts-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: grid;
    place-items: center;
    padding: 20px;
}

.tvn-shorts-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .84);
    backdrop-filter: blur(4px);
}

.tvn-shorts-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(92vw, 430px);
    max-height: 92vh;
}

.tvn-shorts-modal__frame-wrap {
    width: 100%;
    overflow: hidden;
    border-radius: 10px;
    background: #000;
    aspect-ratio: 9 / 16;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .55);
}

.tvn-shorts-modal__frame {
    width: 100%;
    height: 100%;
    display: block;
    border: 0;
}

.tvn-shorts-modal__close {
    position: absolute;
    top: -46px;
    right: -4px;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #fff;
    font: 300 38px/40px Arial, sans-serif;
    cursor: pointer;
}

body.tvn-shorts-modal-open {
    overflow: hidden;
}

.tvn-shorts-admin-error {
    margin: 12px 0;
    padding: 12px 14px;
    border-left: 4px solid #d63638;
    background: #fff;
    color: #1d2327;
}

@media (max-width: 1100px) {
    .tvn-shorts__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }
}

@media (max-width: 680px) {
    .tvn-shorts {
        padding: 22px 0 24px;
    }

    .tvn-shorts__inner {
        padding: 0 16px;
    }


    .tvn-shorts__grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .tvn-shorts__content {
        right: 16px;
        bottom: 14px;
        left: 16px;
    }

    .tvn-shorts__video-title {
        font-size: 17px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tvn-shorts *,
    .tvn-shorts *::before,
    .tvn-shorts *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}
