/* =========================================================
   MOPPEN & RAADSELS
========================================================= */

.jokes-main {
    width: min(1200px, calc(100% - 2rem));
    margin: 0 auto 4rem;
}

.jokes-hero {
    margin-bottom: 1.5rem;
    padding: 2rem;

    position: relative;
    overflow: hidden;

    border: 1px solid var(--border-strong);
    border-radius: var(--radius-xl);

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.08),
            rgba(255, 255, 255, 0.02)
        ),
        radial-gradient(
            circle at top left,
            rgba(240, 236, 7, 0.16),
            transparent 38%
        ),
        radial-gradient(
            circle at top right,
            rgba(31, 111, 235, 0.2),
            transparent 38%
        ),
        rgba(6, 16, 31, 0.92);

    box-shadow:
        var(--shadow),
        inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.jokes-hero::before {
    content: "ENTERTAINMENT DATABASE";
    position: absolute;
    top: 14px;
    right: 18px;

    color: rgba(234, 244, 255, 0.42);
    font-size: 0.62rem;
    font-weight: 900;
    letter-spacing: 0.16em;
}

.jokes-hero-content {
    max-width: 850px;
    margin: 0 auto;
    text-align: center;
}

.jokes-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 1rem;
    padding: 0.45rem 0.9rem;

    border: 1px solid rgba(240, 236, 7, 0.4);
    border-radius: 999px;

    background: rgba(240, 236, 7, 0.08);

    color: var(--yellow);
    font-size: 0.75rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.jokes-hero h2 {
    margin: 0 0 0.8rem;

    color: var(--white);
    font-size: clamp(2rem, 5vw, 3.5rem);
    line-height: 1.1;
}

.jokes-hero p {
    max-width: 720px;
    margin: 0 auto;

    color: var(--text);
    font-size: 1.05rem;
    line-height: 1.7;
}

.jokes-section {
    padding: 1.5rem;

    border: 1px solid var(--border-strong);
    border-radius: var(--radius-xl);

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.07),
            rgba(255, 255, 255, 0.02)
        ),
        rgba(5, 15, 32, 0.88);

    box-shadow:
        var(--shadow),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.jokes-section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;

    margin-bottom: 1.25rem;
}

.jokes-section-label {
    display: block;
    margin-bottom: 0.35rem;

    color: var(--cyan);
    font-size: 0.66rem;
    font-weight: 900;
    letter-spacing: 0.18em;
}

.jokes-section-header h2 {
    margin: 0 0 0.35rem;

    color: var(--white);
    font-size: clamp(1.5rem, 4vw, 2.35rem);
}

.jokes-section-header p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.jokes-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;

    margin-bottom: 1.5rem;
    padding: 0.75rem;

    border: 1px solid var(--border);
    border-radius: var(--radius-lg);

    background: rgba(2, 10, 24, 0.55);
}

.jokes-filter-btn {
    min-height: 42px;
    padding: 0.65rem 1rem;

    border: 1px solid rgba(78, 161, 255, 0.45);
    border-radius: 10px;

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.09),
            rgba(255, 255, 255, 0.02)
        ),
        rgba(17, 52, 108, 0.72);

    color: var(--text);
    font-weight: 900;
    cursor: pointer;

    transition:
        transform 0.16s ease,
        filter 0.16s ease,
        border-color 0.16s ease;
}

.jokes-filter-btn:hover {
    transform: translateY(-2px);
    filter: brightness(1.08);
    border-color: rgba(111, 187, 255, 0.95);
}

.jokes-filter-btn.active {
    border-color: rgba(240, 236, 7, 0.72);

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.12),
            rgba(255, 255, 255, 0.02)
        ),
        rgba(145, 123, 0, 0.75);

    color: #ffffff;
    box-shadow:
        0 0 20px rgba(240, 236, 7, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.jokes-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.joke-card {
    position: relative;
    overflow: hidden;

    padding: 1.3rem;

    border: 1px solid var(--border);
    border-radius: var(--radius-lg);

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.08),
            rgba(255, 255, 255, 0.02)
        ),
        rgba(7, 18, 34, 0.95);

    color: var(--text);

    box-shadow:
        0 16px 34px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);

    transition:
        transform 0.18s ease,
        border-color 0.18s ease,
        box-shadow 0.18s ease;
}

.joke-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;

    background:
        linear-gradient(
            180deg,
            var(--yellow),
            var(--blue)
        );
}

.joke-card:hover {
    transform: translateY(-3px);
    border-color: rgba(78, 161, 255, 0.55);

    box-shadow:
        0 22px 44px rgba(0, 0, 0, 0.4),
        0 0 24px rgba(31, 111, 235, 0.1);
}

.joke-card[hidden] {
    display: none;
}

.joke-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;

    margin-bottom: 1rem;
}

.joke-type-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0.25rem 0.65rem;

    border-radius: 999px;

    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.08em;
}

.joke-type-mop {
    background: rgba(240, 236, 7, 0.12);
    border: 1px solid rgba(240, 236, 7, 0.45);
    color: var(--yellow);
}

.joke-type-riddle {
    background: rgba(39, 211, 255, 0.1);
    border: 1px solid rgba(39, 211, 255, 0.4);
    color: var(--cyan);
}

.joke-card-icon {
    font-size: 1.7rem;
}

.joke-card h3 {
    margin: 0 0 0.75rem;

    color: var(--white);
    font-size: 1.2rem;
    line-height: 1.35;
}

.joke-question {
    min-height: 3.2rem;
    margin: 0 0 1rem;

    color: var(--text);
    line-height: 1.65;
}

.joke-answer-btn {
    min-height: 42px;
    padding: 0.65rem 1rem;

    border: 1px solid rgba(78, 161, 255, 0.5);
    border-radius: 10px;

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.11),
            rgba(255, 255, 255, 0.02)
        ),
        linear-gradient(
            180deg,
            #285fbe,
            #17479a
        );

    color: var(--white);
    font-weight: 900;
    cursor: pointer;

    transition:
        transform 0.16s ease,
        filter 0.16s ease;
}

.joke-answer-btn:hover {
    transform: translateY(-2px);
    filter: brightness(1.1);
}

.joke-answer {
    margin-top: 1rem;
    padding: 1rem;

    border: 1px solid rgba(240, 236, 7, 0.35);
    border-radius: 12px;

    background:
        linear-gradient(
            180deg,
            rgba(240, 236, 7, 0.09),
            rgba(240, 236, 7, 0.03)
        );

    color: #ffffff;
    font-weight: 800;
    line-height: 1.6;
}

.jokes-empty-message {
    margin: 1.5rem 0 0;
    padding: 1rem;

    border: 1px dashed var(--border-strong);
    border-radius: var(--radius-lg);

    color: var(--muted);
    text-align: center;
}

/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 760px) {
    .jokes-main {
        width: calc(100% - 1rem);
    }

    .jokes-hero,
    .jokes-section {
        padding: 1.15rem;
        border-radius: 16px;
    }

    .jokes-grid {
        grid-template-columns: 1fr;
    }

    .jokes-filter-bar {
        display: grid;
        grid-template-columns: 1fr;
    }

    .jokes-filter-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .jokes-hero::before {
        display: none;
    }

    .jokes-hero h2 {
        font-size: 1.75rem;
    }

    .joke-card {
        padding: 1rem;
    }
}