:root {
    color-scheme: light;
    --page-bg: #f3f4f6;
    --surface: #ffffff;
    --surface-alt: #f8fafc;
    --border: #d1d5db;
    --text: #111827;
    --muted: #4b5563;
    --accent: #2563eb;
    --accent-soft: #dbeafe;
    --shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

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

html {
    font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--page-bg);
    color: var(--text);
}

a {
    color: inherit;
    text-decoration: none;
}

img,
video {
    display: block;
    max-width: 100%;
}

.site-header {
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
}

.site-header__brand {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 1.5rem;
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: 0;
}

.page-layout {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem;
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(320px, 420px);
    gap: 1.5rem;
    align-items: start;
}

.video-stage {
    min-width: 0;
}

.video-stage__player {
    background: #000000;
    border: 1px solid #0f172a;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.video-stage__player video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.video-stage__details {
    margin-top: 1rem;
}

.video-stage__meta {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    margin-top: 0.75rem;
}

.video-stage__duration-label {
    font-size: 0.8125rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--muted);
}

.video-stage__duration {
    display: inline-flex;
    align-items: center;
    min-height: 2rem;
    padding: 0.375rem 0.75rem;
    border-radius: 999px;
    background: var(--surface-alt);
    border: 1px solid var(--border);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.video-stage__title {
    margin: 0;
    font-size: 1.625rem;
    line-height: 1.25;
    font-weight: 700;
}

.video-stage__description {
    margin: 0.625rem 0 0;
    max-width: 72ch;
    font-size: 0.975rem;
    line-height: 1.6;
    color: var(--muted);
}

.video-sidebar {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
}

.video-sidebar__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.video-sidebar__title {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
}

.video-sidebar__page-status {
    font-size: 0.875rem;
    color: var(--muted);
}

.video-sidebar__list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.video-card {
    display: grid;
    grid-template-columns: 168px minmax(0, 1fr);
    gap: 0.75rem;
    padding: 0.5rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    transition: border-color 120ms ease, box-shadow 120ms ease, transform 120ms ease;
}

.video-card:hover,
.video-card:focus-visible {
    border-color: var(--accent);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.12);
    transform: translateY(-1px);
    outline: none;
}

.video-card__thumbnail {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 6px;
    object-fit: cover;
    background: #d1d5db;
}

.video-card__body {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 0.375rem;
}

.video-card__title {
    font-size: 0.975rem;
    line-height: 1.35;
    font-weight: 700;
}

.video-card__description {
    font-size: 0.875rem;
    line-height: 1.45;
    color: var(--muted);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-sidebar__pager {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
}

.video-sidebar__page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 96px;
    padding: 0.625rem 0.875rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.video-sidebar__page-link:hover,
.video-sidebar__page-link:focus-visible {
    border-color: var(--accent);
    background: var(--accent-soft);
    outline: none;
}

.video-empty {
    grid-column: 1 / -1;
    padding: 3rem 1.5rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    text-align: center;
}

.video-empty__title {
    margin: 0;
    font-size: 1.375rem;
    font-weight: 700;
}

.video-empty__description {
    margin: 0.75rem 0 0;
    color: var(--muted);
}

@media (max-width: 1080px) {
    .page-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .video-sidebar {
        max-width: 100%;
    }
}

@media (max-width: 720px) {
    .site-header__brand,
    .page-layout {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .video-stage__title {
        font-size: 1.375rem;
    }

    .video-card {
        grid-template-columns: 136px minmax(0, 1fr);
    }
}

@media (max-width: 560px) {
    .page-layout {
        padding-top: 1rem;
        padding-bottom: 1rem;
        gap: 1rem;
    }

    .video-card {
        grid-template-columns: 1fr;
    }

    .video-card__thumbnail {
        width: 100%;
    }

    .video-sidebar__pager {
        flex-direction: column;
    }

    .video-sidebar__page-link {
        width: 100%;
    }
}
