* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: clip;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #0a0a0a;
    color: #ffffff;
    line-height: 1.6;
    overflow-x: clip;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

header {
    background: #1a1a1a;
    padding: 20px 0;
    border-bottom: 1px solid #333;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: #ffffff;
}

nav {
    display: flex;
    gap: 20px;
}

nav a {
    color: #ffffff;
    text-decoration: none;
    transition: opacity 0.3s;
}

nav a:hover {
    opacity: 0.7;
}

main {
    padding: 40px 0;
    min-height: calc(100vh - 200px);
}

h1 {
    font-size: clamp(28px, 5.5vw, 48px);
    margin-bottom: 10px;
    text-align: center;
    line-height: 1.15;
}

.tagline {
    text-align: center;
    color: #aaaaaa;
    margin-bottom: 24px;
    font-size: 18px;
}

.game-embed--portrait iframe {
    height: min(85vh, 720px);
    min-height: 520px;
}

.game-embed--landscape iframe {
    height: min(56vw, 520px);
    min-height: 360px;
}

.game-embed--responsive iframe {
    height: min(70vh, 640px);
    min-height: 480px;
}

.bb-gamezop-screenshots {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 20px;
}

.bb-gamezop-shot {
    width: 160px;
    height: auto;
    border-radius: 8px;
    border: 1px solid #333;
    object-fit: cover;
}

.bb-gamezop-hero {
    margin-bottom: 24px;
    text-align: center;
}

.bb-gamezop-hero-img {
    display: block;
    width: 100%;
    max-width: 640px;
    max-height: 360px;
    margin: 0 auto 20px;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid #333;
}

.bb-gamezop-play-btn {
    display: inline-block;
    min-width: 200px;
    font-size: 1.1rem;
    padding: 14px 32px;
}

.bb-gamezop-play-note {
    margin-top: 12px;
    font-size: 14px;
    color: #888;
}

.bb-completed-message {
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 32px;
    font-size: clamp(18px, 2.5vw, 22px);
    line-height: 1.5;
    color: #e8e8e8;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 40px;
}

.games-grid--dense,
.games-grid--home,
.collection-intro + .games-grid {
    --grid-gap: 10px;
    --grid-max-cols: 6;
    --grid-min-col: max(100px, calc((100% - (var(--grid-max-cols) - 1) * var(--grid-gap)) / var(--grid-max-cols)));
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(var(--grid-min-col), 1fr));
    gap: var(--grid-gap);
    margin-top: 24px;
    width: 100%;
}

.games-grid--dense .game-thumbnail,
.games-grid--home .game-thumbnail,
.collection-intro + .games-grid .game-thumbnail {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    object-fit: cover;
    display: block;
}

.games-grid--dense .game-info,
.games-grid--home .game-info,
.collection-intro + .games-grid .game-info {
    padding: clamp(6px, 1.5vw, 12px);
}

.games-grid--dense .game-title,
.games-grid--home .game-title,
.collection-intro + .games-grid .game-title {
    font-size: clamp(11px, 2.6vw, 14px);
    margin-bottom: 4px;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.games-grid--dense .game-category,
.games-grid--home .game-category,
.collection-intro + .games-grid .game-category {
    font-size: clamp(9px, 2vw, 12px);
    letter-spacing: 0.3px;
}

.home-games-preview {
    margin-top: 0;
    margin-bottom: 28px;
}

@media (min-width: 768px) {
    .games-grid--dense,
    .games-grid--home,
    .collection-intro + .games-grid {
        --grid-gap: 14px;
    }
}

@media (min-width: 1024px) {
    .games-grid--dense,
    .games-grid--home,
    .collection-intro + .games-grid {
        --grid-gap: 16px;
    }

    .games-grid--dense .game-title,
    .games-grid--home .game-title,
    .collection-intro + .games-grid .game-title {
        margin-bottom: 6px;
    }
}

.game-card {
    background: #1a1a1a;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid #333;
    min-width: 0;
}

.game-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.game-thumbnail {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #2a2a2a;
}

.game-info {
    padding: 16px;
}

.game-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #ffffff;
}

.game-category {
    font-size: 14px;
    color: #aaaaaa;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    color: #aaaaaa;
}

footer {
    background: #1a1a1a;
    padding: 20px 0;
    margin-top: 60px;
    border-top: 1px solid #333;
    text-align: center;
    color: #aaaaaa;
}

.footer-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 20px;
    margin-bottom: 12px;
}

.footer-nav a {
    color: #cccccc;
    text-decoration: none;
    font-size: 14px;
}

.footer-nav a:hover {
    color: #ffffff;
    text-decoration: underline;
}

/* Contact form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-width: 560px;
    margin: 12px 0 8px;
}

.contact-form label {
    font-weight: 600;
    margin-top: 8px;
}

.contact-form input,
.contact-form textarea {
    background: #1a1a1a;
    border: 1px solid #444;
    border-radius: 6px;
    color: #eee;
    padding: 10px 12px;
    font-size: 15px;
    font-family: inherit;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: #4a9eff;
}

.contact-form button {
    align-self: flex-start;
    margin-top: 12px;
    cursor: pointer;
    border: none;
}

/* Game Detail Page */
.game-detail {
    display: flex;
    gap: 30px;
    margin-top: 30px;
}

.game-main {
    flex: 1;
}

.game-embed {
    width: 100%;
    min-height: 600px;
    background: #000;
    border-radius: 8px;
    border: 1px solid #333;
    margin-bottom: 30px;
}

.game-embed iframe {
    width: 100%;
    height: 600px;
    border: none;
    border-radius: 8px;
}

.game-description {
    background: #1a1a1a;
    padding: 24px;
    border-radius: 8px;
    border: 1px solid #333;
}

.game-description h2 {
    margin-bottom: 16px;
    font-size: 24px;
}

.game-description p {
    color: #cccccc;
    line-height: 1.8;
    margin-bottom: 16px;
}

.game-description h3 {
    margin-top: 24px;
    margin-bottom: 12px;
    font-size: 18px;
    color: #ffffff;
}

.game-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.tag {
    background: #2a2a2a;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    color: #aaaaaa;
}

.sidebar {
    width: 300px;
}

.sidebar h3 {
    margin-bottom: 20px;
    font-size: 20px;
}

.recommended-games {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.recommended-game {
    display: flex;
    gap: 12px;
    background: #1a1a1a;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #333;
    cursor: pointer;
    transition: background 0.3s;
    text-decoration: none;
    color: inherit;
}

.recommended-game:hover {
    background: #252525;
}

.recommended-game img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
}

.recommended-game-info {
    flex: 1;
}

.recommended-game-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.recommended-game-category {
    font-size: 12px;
    color: #aaaaaa;
}

.back-button {
    display: inline-block;
    margin-bottom: 20px;
    padding: 10px 20px;
    background: #2a2a2a;
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    transition: background 0.3s;
}

.back-button:hover {
    background: #333;
}

/* Quizzes */
.bb-quizzes-grid {
    margin-top: 24px;
}

.bb-quizzes-desc {
    max-width: 900px;
    margin: 0 auto 10px;
    text-align: left;
}

.bb-quizzes-desc-p {
    color: #aaaaaa;
    line-height: 1.9;
    margin: 0 0 14px;
    font-size: 16px;
}

.bb-quiz-card-link {
    text-decoration: none;
    color: inherit;
}

.bb-quiz-card {
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 18px;
}

.bb-quiz-card-small .bb-quiz-title {
    font-size: 18px;
}

/* Quiz card cover image (listing) */
.bb-quiz-cover {
    margin: -18px -18px 14px;
    border-radius: 12px 12px 0 0;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: #111;
}

.bb-quiz-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Quiz player figures (hero + results image) with Pexels credit */
.bb-quiz-figure {
    margin: 0 0 18px;
}

.bb-quiz-figure img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
    border: 1px solid #333;
}

.bb-quiz-figure figcaption {
    color: #888888;
    font-size: 12px;
    margin-top: 6px;
    text-align: center;
}

.bb-quiz-figure figcaption a {
    color: #aaaaaa;
}

.bb-quiz-hero {
    max-width: 760px;
}

.bb-quiz-hero img {
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.bb-quiz-pill {
    display: inline-block;
    font-size: 12px;
    color: #aaaaaa;
    border: 1px solid #333;
    padding: 4px 10px;
    border-radius: 999px;
    margin-bottom: 10px;
    background: #141414;
}

.bb-quiz-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 10px;
}

.bb-quiz-progress {
    color: #aaaaaa;
    font-size: 13px;
    margin-bottom: 10px;
}

.bb-quiz-context {
    color: #cccccc;
    line-height: 1.8;
    margin-bottom: 14px;
}

.bb-quiz-question {
    font-size: 18px;
    font-weight: 650;
    margin-bottom: 14px;
}

.bb-quiz-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-bottom: 14px;
}

.bb-quiz-option {
    text-align: left;
    background: #141414;
    border: 1px solid #333;
    color: #ffffff;
    padding: 12px 14px;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.12s ease, background 0.2s ease, border-color 0.2s ease;
}

.bb-quiz-option:hover {
    transform: translateY(-1px);
    background: #1e1e1e;
}

.bb-quiz-option.correct {
    border-color: #2e7d32;
    background: rgba(46, 125, 50, 0.15);
}

.bb-quiz-option.wrong {
    border-color: #c62828;
    background: rgba(198, 40, 40, 0.15);
}

.bb-quiz-option.disabled {
    opacity: 0.75;
}

.bb-quiz-explanation {
    background: #141414;
    border: 1px solid #333;
    border-radius: 10px;
    padding: 14px;
    color: #cccccc;
    line-height: 1.8;
    margin-bottom: 14px;
}

.bb-quiz-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.bb-btn {
    display: inline-block;
    background: #2a2a2a;
    color: #ffffff;
    border: 1px solid #333;
    padding: 10px 14px;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s ease;
}

.bb-btn:hover {
    background: #333;
}

.bb-btn-secondary {
    background: transparent;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.category-card {
    display: block;
    background: #141414;
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    padding: 20px 16px;
    text-decoration: none;
    color: #fff;
    transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.category-card:hover {
    transform: translateY(-2px);
    border-color: #444;
    background: #1a1a1a;
}

.category-card-title {
    font-size: 18px;
    font-weight: 650;
    margin-bottom: 6px;
}

.category-card-desc {
    font-size: 13px;
    color: #999;
}

.category-card-count {
    font-size: 13px;
    color: #999;
}

.home-cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-bottom: 40px;
}

.categories-grid--compact {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.categories-grid--compact .category-card {
    padding: 14px 10px;
    text-align: center;
}

.categories-grid--compact .category-card-title {
    font-size: 15px;
    margin-bottom: 0;
}

.home-browse {
    margin-bottom: 28px;
}

.home-section-heading {
    font-size: 26px;
    font-weight: 650;
    margin-bottom: 8px;
}

.home-section-heading--center {
    text-align: center;
}

.home-section-desc {
    color: #999;
    font-size: 15px;
    margin-bottom: 16px;
}

.home-section-desc--center {
    text-align: center;
}

.home-collections {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.home-see-all {
    margin-top: 16px;
    font-size: 14px;
}

.home-see-all a {
    color: #4a9eff;
    text-decoration: none;
}

.home-see-all a:hover {
    text-decoration: underline;
}

.home-divider {
    border-top: 1px solid #2a2a2a;
    margin: 8px 0 32px;
    padding-top: 32px;
}

@media (max-width: 1024px) {
    header .container {
        flex-wrap: wrap;
        gap: 12px;
    }

    nav {
        flex-wrap: wrap;
        gap: 8px 14px;
        font-size: 14px;
    }
}

/* PubFuture sticky bottom banner */
.pf-mobile-sticky {
    display: block;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    text-align: center;
    background: #0a0a0a;
    border-top: 1px solid #333;
    padding: 10px 0 calc(14px + env(safe-area-inset-bottom, 0));
    min-height: 90px;
    max-height: 180px;
    overflow: visible;
    box-sizing: content-box;
}

.pf-mobile-sticky #pf-23203-1 {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    width: 100%;
    overflow: visible;
}

.pf-mobile-sticky--empty {
    display: none !important;
}

body.pf-mobile-sticky-active {
    padding-bottom: calc(140px + env(safe-area-inset-bottom, 0));
}

/* Gamezopp: Netpub side rails on desktop, top banner on mobile */
.gamezopp-page {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 12px;
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 12px;
}

.gamezopp-content {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
}

.gamezopp-ad-side {
    display: none;
    flex: 0 0 160px;
    width: 160px;
    min-height: 600px;
}

.gamezopp-ad-side ins,
.gamezopp-ad-top ins {
    display: block;
    margin: 0 auto;
}

.gamezopp-ad-top {
    display: none;
    justify-content: center;
    align-items: center;
    padding: 10px 12px 0;
    min-height: 60px;
}

@media (min-width: 769px) {
    .gamezopp-ad-side {
        display: block;
    }

    .gamezopp-ad-top {
        display: none !important;
    }
}

@media (max-width: 768px) {
    .gamezopp-page {
        display: block;
        padding: 0;
    }

    .gamezopp-ad-side {
        display: none !important;
    }

    .gamezopp-ad-top {
        display: flex;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .game-detail {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
    }

    h1 {
        font-size: clamp(26px, 7vw, 32px);
    }

    header .container {
        flex-wrap: wrap;
        gap: 10px;
    }

    .logo {
        font-size: 20px;
    }

    nav {
        flex-wrap: wrap;
        gap: 6px 12px;
        font-size: 13px;
        line-height: 1.3;
        width: 100%;
    }

    main {
        padding: 24px 0;
    }

    .container {
        padding: 0 12px;
    }

    .tagline {
        font-size: 16px;
    }

    .home-cta-row .bb-btn {
        padding: 8px 12px;
        font-size: 14px;
    }
}

