:root {
    --bg: #f6f8fc;
    --panel: #ffffff;
    --panel-2: #eef2f9;
    --text: #1f2937;
    --muted: #6b7280;
    --accent: #f59e0b;
    --ok: #22c55e;
    --danger: #ef4444;
    --border: rgba(15, 23, 42, .08);
    --shadow: 0 10px 30px rgba(15, 23, 42, .08);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: linear-gradient(180deg, #f9fbff, #f3f6fb 40%, #eef3f9);
    color: var(--text);
}

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

.wrap {
    width: min(100% - 100px, 1400px);
    margin: 0 auto;
}

.topbar {
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    background: rgba(255,255,255,.88);
    backdrop-filter: blur(8px);
    z-index: 10;
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
}

.brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
}

.nav {
    display: flex;
    gap: 16px;
}

    .nav a {
        color: var(--muted);
    }

        .nav a:hover {
            color: #111827;
        }

.main-shell {
    padding: 24px 0 40px;
}

.grid {
    display: grid;
    gap: 18px;
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 18px;
    box-shadow: var(--shadow);
}

    .card h2,
    .card h3 {
        margin-top: 0;
        color: #111827;
    }

.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 16px;
}

    .tabs a {
        background: var(--panel);
        border: 1px solid var(--border);
        padding: 10px 14px;
        border-radius: 999px;
        color: var(--muted);
        transition: .2s ease;
    }

        .tabs a:hover {
            background: #fff7e6;
            color: #111827;
            border-color: rgba(245, 158, 11, .25);
        }

        .tabs a.active {
            background: var(--accent);
            color: #161616;
            font-weight: 700;
            border-color: transparent;
        }

.btn,
button,
input[type=submit] {
    background: var(--accent);
    color: #1f1f1f;
    border: 0;
    padding: 10px 14px;
    border-radius: 10px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 6px 14px rgba(245, 158, 11, .18);
}

.btn-secondary {
    background: var(--panel-2);
    color: #111827;
    border: 1px solid var(--border);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-ok {
    background: var(--ok);
    color: white;
}

input,
textarea,
select {
    width: 100%;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(15, 23, 42, .12);
    background: #ffffff;
    color: #111827;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, .03);
}

    input::placeholder,
    textarea::placeholder {
        color: #9ca3af;
    }

    input:focus,
    textarea:focus,
    select:focus {
        outline: none;
        border-color: rgba(245, 158, 11, .55);
        box-shadow: 0 0 0 4px rgba(245, 158, 11, .12);
    }

label {
    display: block;
    font-size: .95rem;
    margin-bottom: 6px;
    color: var(--muted);
}

.form-row {
    display: grid;
    gap: 12px;
    margin-bottom: 14px;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

    .table th,
    .table td {
        padding: 10px 8px;
        border-bottom: 1px solid rgba(15, 23, 42, .08);
        vertical-align: top;
    }

    .table th {
        text-align: left;
        color: var(--muted);
        font-weight: 600;
    }

    .table tr:hover td {
        background: rgba(245, 158, 11, .04);
    }

    .table img {
        display: block;
        border-radius: 8px;
    }

.notice {
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(245, 158, 11, .12);
    color: #8a5a00;
    border: 1px solid rgba(245, 158, 11, .25);
}

.ok {
    background: rgba(34,197,94,.12);
    border-color: rgba(34,197,94,.22);
    color: #166534;
}

.error {
    background: rgba(239,68,68,.10);
    border-color: rgba(239,68,68,.22);
    color: #991b1b;
}

.hero {
    padding: 24px;
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(245,158,11,.18), rgba(255,255,255,.85));
    border: 1px solid rgba(15, 23, 42, .08);
}

    .hero h1 {
        margin: 0 0 6px;
        color: #111827;
    }

.muted {
    color: var(--muted);
}

.tag {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    background: #f3f4f6;
    color: #4b5563;
    font-size: .85rem;
    border: 1px solid rgba(15, 23, 42, .06);
}

.actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.list {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .list li {
        padding: 8px 0;
        border-bottom: 1px solid rgba(15, 23, 42, .08);
    }

.player-frame {
    max-width: 2000px;
}

    .player-frame iframe,
    .player-frame #yt-player iframe {
        width: 100% !important;
        min-height: 800px;
        border: none;
        border-radius: 14px;
        box-shadow: var(--shadow);
    }

@media (max-width: 700px) {
    .topbar-inner {
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }

    .wrap {
        width: min(100% - 32px, 1400px);
    }

    .player-frame iframe,
    .player-frame #yt-player iframe {
        min-height: 260px;
    }
}

.play-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent);
    color: #1f1f1f;
    font-weight: bold;
    text-decoration: none;
    transition: .2s ease;
}

    .play-btn:hover {
        transform: scale(1.1);
        box-shadow: 0 6px 14px rgba(245, 158, 11, .3);
    }

.actions-inline {
    display: flex;
    align-items: center;
    gap: 8px;
}

.input-inline {
    flex: 1;
}

.actions-inline button {
    padding: 6px 10px;
    font-size: 0.9rem;
}

.col-center {
    text-align: center;
}

    .col-center form,
    .col-center a {
        display: inline-flex;
        justify-content: center;
        align-items: center;
    }

.table th.col-center,
.table td.col-center {
    text-align: center;
    vertical-align: middle;
}