:root {
    --yellow: #e8b923;
    --yellow-dark: #c99a12;
    --yellow-soft: #fff9e8;
    --white: #ffffff;
    --off-white: #f7f7f5;
    --ink: #141414;
    --muted: #6a6a6a;
    --line: #e8e8e4;
    --shadow: 0 8px 24px rgba(20, 20, 20, 0.06);
    --radius: 10px;
    --font-display: "Syne", sans-serif;
    --font-body: "Manrope", sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-body);
    color: var(--ink);
    background: var(--off-white);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    width: min(1100px, calc(100% - 2.5rem));
    margin-inline: auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: var(--white);
    border-bottom: 1px solid var(--line);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 68px;
}

.brand {
    font-family: var(--font-display);
    font-size: clamp(1.35rem, 2.5vw, 1.65rem);
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink);
    position: relative;
    padding-bottom: 0.35rem;
}

.brand::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 36px;
    height: 3px;
    transform: translateX(-50%);
    background: var(--yellow);
    border-radius: 2px;
}

.brand:hover {
    color: var(--ink);
}

.site-main {
    padding: 2.25rem 0 4rem;
}

.section {
    padding: 1.75rem 0 2.5rem;
}

.section-alt {
    padding-top: 2.5rem;
    border-top: 1px solid var(--line);
}

.section-head {
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.section-head h2 {
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(1.35rem, 3vw, 1.7rem);
    font-weight: 700;
    letter-spacing: -0.01em;
}

.section-head p {
    margin: 0;
    color: var(--muted);
    font-size: 0.92rem;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.35rem;
}

.video-card {
    display: block;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--white);
    border: 1px solid var(--line);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.video-card:hover {
    border-color: #f0d56a;
    box-shadow: var(--shadow);
}

.video-thumb {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #1a1a1a;
}

.video-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-card:hover .video-thumb img {
    transform: scale(1.03);
}

.play-icon {
    position: absolute;
    inset: 0;
    margin: auto;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(232, 185, 35, 0.95);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.play-icon::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 54%;
    transform: translate(-50%, -50%);
    border-style: solid;
    border-width: 7px 0 7px 12px;
    border-color: transparent transparent transparent var(--ink);
}

.video-card:hover .play-icon {
    opacity: 1;
}

.video-meta {
    padding: 0.75rem 0.95rem 0.9rem;
}

.video-meta time {
    display: block;
    font-size: 0.8rem;
    color: var(--muted);
}

.empty-state {
    margin: 0;
    padding: 1.75rem 1.25rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--muted);
    text-align: center;
    font-size: 0.95rem;
}

.watch-section {
    padding: 0.5rem 0 1rem;
}

.watch-layout {
    max-width: 900px;
}

.watch-title {
    margin: 0 0 1.1rem;
    font-family: var(--font-display);
    font-size: clamp(1.4rem, 3.5vw, 1.85rem);
    font-weight: 700;
    letter-spacing: -0.01em;
}

.player-wrap {
    overflow: hidden;
    border-radius: var(--radius);
    background: #000;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    position: relative;
    aspect-ratio: 16 / 9;
}

.player-wrap .video-player,
.player-wrap .fluid_video_wrapper,
.player-wrap .fluid_video_wrapper video {
    width: 100% !important;
    height: 100% !important;
}

.player-wrap .fluid_video_wrapper {
    position: absolute !important;
    inset: 0;
}

.watch-description {
    margin: 1.15rem 0 0;
    line-height: 1.65;
    color: var(--ink);
    font-size: 0.98rem;
}

.watch-date {
    margin: 0.65rem 0 0;
    color: var(--muted);
    font-size: 0.88rem;
}

.watch-actions {
    margin-top: 1.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    min-height: 42px;
    padding: 0.65rem 1.2rem;
    border: 1px solid transparent;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.btn-primary {
    background: var(--yellow);
    color: var(--ink);
}

.btn-primary:hover {
    background: var(--yellow-dark);
    color: var(--white);
}

.btn-secondary {
    background: var(--white);
    border-color: var(--line);
    color: var(--ink);
}

.btn-secondary:hover {
    border-color: var(--yellow);
}

.btn-danger {
    background: #fff;
    border-color: #e0b4b4;
    color: #b33333;
}

.btn-danger:hover {
    background: #b33333;
    border-color: #b33333;
    color: #fff;
}

.center {
    text-align: center;
}

.site-footer {
    border-top: 1px solid var(--line);
    background: var(--white);
    padding: 1.35rem 0;
    color: var(--muted);
    font-size: 0.85rem;
}

.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.75rem 1.25rem;
    text-align: center;
}

.footer-inner p {
    margin: 0;
}

.footer-inner a {
    color: var(--ink);
    font-weight: 600;
}

.footer-inner a:hover {
    color: var(--yellow-dark);
}

.legal-section {
    padding: 0.25rem 0 1rem;
}

.legal-layout {
    max-width: 760px;
}

.legal-title {
    margin: 0 0 0.4rem;
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3.5vw, 2rem);
    font-weight: 700;
}

.legal-updated {
    margin: 0 0 1.75rem;
    color: var(--muted);
    font-size: 0.9rem;
}

.legal-content h2 {
    margin: 1.75rem 0 0.65rem;
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
}

.legal-content p,
.legal-content li {
    margin: 0 0 0.75rem;
    line-height: 1.7;
    color: #2a2a2a;
    font-size: 0.98rem;
}

.legal-content ul {
    margin: 0 0 0.75rem;
    padding-left: 1.25rem;
}

.legal-content a {
    color: var(--ink);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.legal-content a:hover {
    color: var(--yellow-dark);
}

/* Admin */
.admin-body {
    background: var(--off-white);
}

.admin-shell {
    width: min(960px, calc(100% - 2rem));
    margin: 2rem auto 3rem;
}

.admin-card {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.75rem;
}

.admin-card h1,
.admin-card h2 {
    margin-top: 0;
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.01em;
}

.admin-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-bottom: 1.25rem;
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.85rem;
    margin: 0 0 1.35rem;
}

.admin-stat {
    background: var(--yellow-soft);
    border: 1px solid #f0e1a8;
    border-radius: 8px;
    padding: 0.9rem 1rem;
}

.admin-stat-label {
    display: block;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
    font-weight: 700;
}

.admin-stat-value {
    display: block;
    margin-top: 0.25rem;
    font-family: var(--font-display);
    font-size: 1.55rem;
    font-weight: 700;
}

.form-group {
    margin-bottom: 1.1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.4rem;
    font-weight: 600;
    font-size: 0.92rem;
}

.form-group input[type="text"],
.form-group input[type="password"],
.form-group input[type="file"],
.form-group textarea {
    width: 100%;
    padding: 0.75rem 0.85rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    font: inherit;
    background: #fff;
}

.form-group textarea {
    min-height: 110px;
    resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: 2px solid rgba(232, 185, 35, 0.45);
    border-color: var(--yellow);
}

.alert {
    margin-bottom: 1rem;
    padding: 0.85rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.92rem;
}

.alert-success {
    background: #f0faf0;
    border: 1px solid #b7dfb7;
    color: #1f6b1f;
}

.alert-error {
    background: #fff5f5;
    border: 1px solid #efc0c0;
    color: #8a1f1f;
}

.admin-table-wrap {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 0.85rem 0.55rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: middle;
}

.admin-table th {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
}

.admin-thumb {
    width: 96px;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid var(--line);
}

.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.hint {
    margin-top: 0.35rem;
    font-size: 0.84rem;
    color: var(--muted);
}

@media (max-width: 640px) {
    .site-main {
        padding-top: 1.5rem;
    }

    .watch-actions .btn {
        width: 100%;
    }

    .admin-card {
        padding: 1.2rem;
    }

    .header-inner {
        min-height: 60px;
    }
}
