:root {
    --bg: #08111d;
    --bg-soft: #0e1b2d;
    --panel: rgba(10, 20, 35, 0.92);
    --border: rgba(180, 197, 224, 0.14);
    --text: #ebf1fb;
    --muted: #98abc4;
    --accent: #85b6ff;
    --gold: #e7c67c;
    --danger: #ff7b7b;
    --success: #7ed0a6;
    --shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: "Segoe UI", Tahoma, sans-serif;
    background:
        radial-gradient(circle at top, rgba(92, 136, 211, 0.18), transparent 32%),
        linear-gradient(180deg, #060c15 0%, #091321 50%, #091626 100%);
    color: var(--text);
}

body {
    padding: 32px 18px;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.page-shell {
    width: min(1200px, 100%);
    margin: 0 auto;
}

.hero,
.grid-layout,
.panel-copy,
.stack-form,
.field,
.card-actions,
.video-card,
.video-card-copy {
    display: flex;
}

.hero,
.card-actions {
    justify-content: space-between;
    align-items: center;
}

.hero {
    margin-bottom: 20px;
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: 26px;
    background: linear-gradient(180deg, rgba(9, 18, 31, 0.95), rgba(9, 18, 31, 0.88));
    box-shadow: var(--shadow);
}

.hero h1,
.panel-copy h2,
.video-card h3,
.hero-copy,
.eyebrow,
.alert,
.empty-state,
.field span,
.video-card p {
    margin: 0;
}

.hero h1 {
    font-size: 38px;
    margin-top: 6px;
}

.hero-copy {
    margin-top: 10px;
    color: var(--muted);
    max-width: 720px;
}

.eyebrow {
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 12px;
}

.alert {
    margin-bottom: 18px;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: rgba(8, 15, 27, 0.92);
}

.alert-success {
    border-color: rgba(126, 208, 166, 0.4);
}

.alert-error {
    border-color: rgba(255, 123, 123, 0.4);
}

.grid-layout {
    gap: 18px;
    align-items: flex-start;
}

.grid-layout > .panel:first-child {
    width: 390px;
    flex: 0 0 auto;
}

.grid-layout > .panel:last-child {
    flex: 1;
}

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

.auth-panel {
    width: min(560px, 100%);
    margin: 0 auto;
}

.panel-copy,
.stack-form,
.field,
.video-card,
.video-card-copy {
    flex-direction: column;
}

.panel-copy {
    gap: 8px;
    margin-bottom: 18px;
}

.panel-copy p {
    color: var(--muted);
}

.stack-form {
    gap: 16px;
}

.field {
    gap: 8px;
}

.field span {
    color: #f4f6fb;
    font-weight: 600;
}

.field input[type="text"],
.field input[type="password"],
.field input[type="file"] {
    width: 100%;
    padding: 14px 15px;
    border: 1px solid rgba(180, 197, 224, 0.16);
    border-radius: 14px;
    background: rgba(5, 11, 20, 0.84);
    color: var(--text);
}

.primary-button,
.ghost-button,
.danger-button {
    border: 1px solid rgba(180, 197, 224, 0.14);
    border-radius: 14px;
    padding: 12px 16px;
    cursor: pointer;
    color: var(--text);
    transition: border-color 0.16s ease, background 0.16s ease;
}

.primary-button {
    background: linear-gradient(135deg, rgba(35, 73, 127, 0.96), rgba(23, 50, 95, 0.96));
}

.ghost-button {
    background: rgba(11, 21, 37, 0.92);
}

.danger-button {
    background: rgba(78, 20, 29, 0.88);
    border-color: rgba(255, 123, 123, 0.2);
}

.primary-button:hover,
.ghost-button:hover,
.danger-button:hover {
    border-color: rgba(231, 198, 124, 0.42);
}

.video-list {
    display: grid;
    gap: 14px;
}

.video-card {
    gap: 16px;
    padding: 18px;
    border-radius: 18px;
    border: 1px solid rgba(180, 197, 224, 0.1);
    background: rgba(7, 14, 24, 0.88);
}

.video-card-copy {
    gap: 8px;
}

.video-card h3 {
    font-size: 20px;
}

.video-card p {
    color: var(--muted);
    word-break: break-word;
}

.card-actions {
    gap: 12px;
    flex-wrap: wrap;
}

.card-actions form {
    margin: 0;
}

.empty-state {
    padding: 26px;
    text-align: center;
    border-radius: 18px;
    border: 1px dashed rgba(180, 197, 224, 0.2);
    color: var(--muted);
    background: rgba(7, 14, 24, 0.6);
}

@media (max-width: 980px) {
    .grid-layout {
        flex-direction: column;
    }

    .grid-layout > .panel:first-child,
    .grid-layout > .panel:last-child {
        width: 100%;
    }

    .hero {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }
}
