:root {
    --bg-top: #fff4e6;
    --bg-bottom: #ffd6a5;
    --surface: rgba(255, 255, 255, 0.8);
    --surface-strong: rgba(255, 255, 255, 0.96);
    --text: #1e1f24;
    --muted: #5f6372;
    --accent: #ef233c;
    --accent-dark: #c1121f;
    --line: rgba(30, 31, 36, 0.1);
    --shadow: 0 18px 45px rgba(30, 31, 36, 0.15);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Outfit', sans-serif;
    color: var(--text);
    min-height: 100vh;
    background:
        radial-gradient(circle at 15% 20%, rgba(255, 126, 95, 0.35), transparent 40%),
        radial-gradient(circle at 85% 0%, rgba(255, 206, 84, 0.45), transparent 35%),
        linear-gradient(145deg, var(--bg-top), var(--bg-bottom));
    background-attachment: fixed;
}

.shell {
    width: min(1080px, 92vw);
    margin: 2.5rem auto;
    display: grid;
    gap: 1.2rem;
}

.hero,
.video-card,
.panel {
    border: 1px solid var(--line);
    border-radius: 22px;
    background: var(--surface);
    backdrop-filter: blur(8px);
    box-shadow: var(--shadow);
}

.hero {
    padding: 2.25rem;
    animation: rise 0.6s ease;
}

.hero.compact {
    max-width: 680px;
    margin-inline: auto;
}

.badge {
    display: inline-block;
    margin: 0;
    background: rgba(239, 35, 60, 0.12);
    color: var(--accent-dark);
    border: 1px solid rgba(193, 18, 31, 0.2);
    border-radius: 999px;
    padding: 0.3rem 0.8rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

h1,
h2,
h3 {
    font-family: 'Space Grotesk', sans-serif;
    letter-spacing: -0.02em;
    margin-top: 0.6rem;
    margin-bottom: 0.5rem;
}

h1 {
    font-size: clamp(1.9rem, 3.4vw, 3rem);
    line-height: 1.12;
}

.lead {
    color: var(--muted);
    max-width: 70ch;
    margin-bottom: 1.5rem;
}

.search-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.row {
    display: flex;
    gap: 0.7rem;
    flex-wrap: wrap;
}

input {
    flex: 1 1 360px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--surface-strong);
    color: var(--text);
    font-size: 1rem;
    padding: 0.85rem 1rem;
}

button,
.back-link {
    border: 0;
    border-radius: 14px;
    padding: 0.85rem 1rem;
    color: #fff;
    background: linear-gradient(90deg, var(--accent), var(--accent-dark));
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

button:hover,
.back-link:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(193, 18, 31, 0.26);
}

.error {
    margin-top: 1rem;
    color: #8d1022;
    background: rgba(248, 215, 218, 0.85);
    border: 1px solid rgba(141, 16, 34, 0.25);
    border-radius: 14px;
    padding: 0.8rem 1rem;
}

.video-card {
    padding: 1rem;
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 1rem;
    align-items: center;
    animation: rise 0.8s ease;
}

.thumb-wrap {
    border-radius: 16px;
    overflow: hidden;
    min-height: 140px;
    background: #111;
}

.thumb {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-info p {
    color: var(--muted);
}

.video-info a {
    color: var(--accent-dark);
    font-weight: 600;
}

.direct-link {
    margin-top: 1rem;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 10px;
    padding: 0.55rem 0.7rem;
    overflow-wrap: anywhere;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.panel {
    padding: 1.2rem;
    animation: rise 0.95s ease;
}

.option-form {
    margin-top: 0.6rem;
}

.option-form button {
    width: 100%;
    text-align: left;
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 860px) {
    .video-card {
        grid-template-columns: 1fr;
    }

    .options-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        padding: 1.2rem;
    }
}

