/* ============================================================
 * melbet-apps.click — melbet-apps-layout-3cfb.css
 * Mobile-first canvas (320–430px). All classes & vars use `s3cf-` prefix.
 * Palette: #6495ED (Cornflower) / #808080 (Gray) / #0E1621 (Ink) / #8B008B (Magenta)
 * Direction: asymmetric brand header, expandable nav drawer,
 *            central lift bottom bar, containerized icon tiles.
 * ============================================================ */

:root {
    --s3cf-ink: #0E1621;
    --s3cf-ink-soft: #16202E;
    --s3cf-ink-deep: #080D14;
    --s3cf-cornflower: #6495ED;
    --s3cf-cornflower-deep: #3F6FCE;
    --s3cf-magenta: #8B008B;
    --s3cf-magenta-deep: #6A006A;
    --s3cf-gray: #808080;
    --s3cf-gray-soft: #B9C0CC;
    --s3cf-text: #EAF0FA;
    --s3cf-text-mute: #A8B2C4;
    --s3cf-line: rgba(120, 145, 180, 0.18);
    --s3cf-line-strong: rgba(120, 145, 180, 0.32);
    --s3cf-gold: #F4C95D;
    --s3cf-radius-sm: 8px;
    --s3cf-radius-md: 14px;
    --s3cf-radius-lg: 22px;
    --s3cf-shadow-card: 0 6px 18px rgba(0, 0, 0, 0.32);
    --s3cf-shadow-pop: 0 12px 32px rgba(0, 0, 0, 0.45);
    --s3cf-header-h: 62px;
    --s3cf-bottomnav-h: 76px;
    --s3cf-max-w: 480px;
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    margin: 0;
    padding: 0;
    background: var(--s3cf-ink);
    color: var(--s3cf-text);
    font-family: "Hind Siliguri", "Noto Sans Bengali", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.6;
    word-break: break-word;
    overflow-x: hidden;
}

body {
    min-height: 100vh;
    background:
        radial-gradient(1200px 480px at 50% -120px, rgba(100, 149, 237, 0.22), transparent 70%),
        radial-gradient(900px 420px at 110% 0%, rgba(139, 0, 139, 0.18), transparent 65%),
        linear-gradient(180deg, #0E1621 0%, #0B1119 60%, #080D14 100%);
    background-attachment: fixed;
}

img {
    max-width: 100%;
    display: block;
}

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

p { margin: 0 0 12px; }

h1, h2, h3, h4 {
    margin: 0 0 10px;
    line-height: 1.3;
    color: #FFFFFF;
    font-weight: 700;
}

/* Page wrap keeps the mobile canvas on wider screens */
.s3cf-page {
    max-width: var(--s3cf-max-w);
    margin: 0 auto;
    min-height: 100vh;
    position: relative;
    background: linear-gradient(180deg, rgba(22, 32, 46, 0.55), rgba(11, 17, 25, 0.85));
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.45);
}

/* Bottom padding for fixed bottom-nav clearance */
.s3cf-content {
    padding: var(--s3cf-header-h) 0 calc(var(--s3cf-bottomnav-h) + 28px);
}

.s3cf-wrap {
    padding: 0 14px;
}

/* ============================================================
 * Header — asymmetric brand header
 * ============================================================ */
.s3cf-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 60;
    max-width: var(--s3cf-max-w);
    margin: 0 auto;
    height: var(--s3cf-header-h);
    background: linear-gradient(120deg, rgba(14, 22, 33, 0.96) 0%, rgba(22, 32, 46, 0.96) 55%, rgba(40, 18, 50, 0.96) 100%);
    border-bottom: 1px solid var(--s3cf-line-strong);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.s3cf-header-inner {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 12px;
    gap: 10px;
}

.s3cf-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.s3cf-logo-tile {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(100, 149, 237, 0.32), rgba(139, 0, 139, 0.32));
    border: 1px solid var(--s3cf-line-strong);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: inset 0 0 12px rgba(100, 149, 237, 0.25);
}

.s3cf-logo-tile img {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

.s3cf-brand-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.s3cf-brand-name {
    font-size: 16px;
    font-weight: 800;
    color: #FFFFFF;
    line-height: 1.1;
    letter-spacing: 0.2px;
}

.s3cf-brand-tag {
    font-size: 10.5px;
    color: var(--s3cf-cornflower);
    line-height: 1.2;
    letter-spacing: 0.3px;
}

.s3cf-header-cta {
    display: flex;
    align-items: center;
    gap: 6px;
}

.s3cf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 13px;
    border: none;
    cursor: pointer;
    transition: transform 0.12s ease, box-shadow 0.2s ease, filter 0.2s ease;
    color: #FFFFFF;
    text-align: center;
}

.s3cf-btn-login {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--s3cf-line-strong);
    color: var(--s3cf-text);
}

.s3cf-btn-promo {
    background: linear-gradient(135deg, var(--s3cf-cornflower) 0%, var(--s3cf-magenta) 100%);
    color: #FFFFFF;
    box-shadow: 0 4px 14px rgba(100, 149, 237, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.s3cf-menu-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--s3cf-line);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #FFFFFF;
    flex-shrink: 0;
}

.s3cf-menu-btn svg { width: 20px; height: 20px; }

/* ============================================================
 * Expandable nav drawer
 * ============================================================ */
.s3cf-nav-mask {
    position: fixed;
    inset: 0;
    background: rgba(5, 8, 14, 0.65);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease;
    z-index: 70;
}

.s3cf-nav-mask.s3cf-show {
    opacity: 1;
    visibility: visible;
}

.s3cf-nav-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 82%;
    max-width: 340px;
    background: linear-gradient(180deg, #111A26 0%, #0C131C 100%);
    border-left: 1px solid var(--s3cf-line-strong);
    transform: translateX(100%);
    transition: transform 0.28s ease;
    z-index: 80;
    overflow-y: auto;
    padding: 18px 16px calc(var(--s3cf-bottomnav-h) + 20px);
}

.s3cf-nav-drawer.s3cf-open { transform: translateX(0); }

.s3cf-drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.s3cf-drawer-head h3 {
    font-size: 15px;
    color: #FFFFFF;
    margin: 0;
}

.s3cf-drawer-close {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--s3cf-line);
    color: #FFFFFF;
    cursor: pointer;
    font-size: 16px;
}

.s3cf-drawer-cta {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.s3cf-drawer-cta .s3cf-btn { flex: 1; height: 38px; font-size: 13px; }

.s3cf-drawer-section { margin-bottom: 16px; }

.s3cf-drawer-section h4 {
    font-size: 12px;
    color: var(--s3cf-gray-soft);
    margin: 0 0 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.s3cf-drawer-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 12px;
    border-radius: 10px;
    color: var(--s3cf-text);
    font-size: 14px;
    border: 1px solid transparent;
    margin-bottom: 4px;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.s3cf-drawer-link:hover, .s3cf-drawer-link:focus {
    background: rgba(100, 149, 237, 0.10);
    border-color: var(--s3cf-line-strong);
}

.s3cf-drawer-link .s3cf-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--s3cf-cornflower);
    flex-shrink: 0;
}

/* ============================================================
 * Hero / promo strip
 * ============================================================ */
.s3cf-hero {
    position: relative;
    padding: 16px 14px 6px;
}

.s3cf-hero-card {
    position: relative;
    border-radius: var(--s3cf-radius-lg);
    padding: 22px 18px;
    overflow: hidden;
    background:
        radial-gradient(220px 120px at 85% 0%, rgba(244, 201, 93, 0.22), transparent 70%),
        linear-gradient(135deg, #1B2740 0%, #2A1635 60%, #3D1240 100%);
    border: 1px solid var(--s3cf-line-strong);
    box-shadow: var(--s3cf-shadow-card);
}

.s3cf-hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(244, 201, 93, 0.18);
    color: var(--s3cf-gold);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.4px;
    margin-bottom: 10px;
}

.s3cf-hero h1 {
    font-size: 24px;
    line-height: 1.25;
    margin: 0 0 8px;
}

.s3cf-hero h1 .s3cf-grad {
    background: linear-gradient(90deg, #6495ED, #F4C95D);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.s3cf-hero p {
    font-size: 13.5px;
    color: var(--s3cf-text-mute);
    margin: 0 0 16px;
}

.s3cf-hero-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.s3cf-hero-actions .s3cf-btn { height: 42px; padding: 0 18px; font-size: 14px; }

.s3cf-hero-actions .s3cf-btn-login {
    background: rgba(255, 255, 255, 0.06);
}

/* Stats strip */
.s3cf-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin: 14px 0 4px;
}

.s3cf-stat {
    background: rgba(22, 32, 46, 0.7);
    border: 1px solid var(--s3cf-line);
    border-radius: var(--s3cf-radius-md);
    padding: 10px 8px;
    text-align: center;
}

.s3cf-stat-num {
    font-size: 18px;
    font-weight: 800;
    color: var(--s3cf-cornflower);
    line-height: 1.1;
}

.s3cf-stat-label {
    font-size: 10.5px;
    color: var(--s3cf-text-mute);
    margin-top: 2px;
}

/* ============================================================
 * Sections
 * ============================================================ */
.s3cf-section {
    padding: 16px 14px 6px;
}

.s3cf-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 12px;
    gap: 10px;
}

.s3cf-section-head h2 {
    font-size: 18px;
    margin: 0;
    position: relative;
    padding-left: 12px;
}

.s3cf-section-head h2::before {
    content: "";
    position: absolute;
    left: 0;
    top: 4px;
    bottom: 4px;
    width: 4px;
    border-radius: 2px;
    background: linear-gradient(180deg, var(--s3cf-cornflower), var(--s3cf-magenta));
}

.s3cf-section-head .s3cf-link-more {
    font-size: 12px;
    color: var(--s3cf-cornflower);
    font-weight: 600;
}

/* Category tabs */
.s3cf-cat-tabs {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding: 2px 0 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.s3cf-cat-tabs::-webkit-scrollbar { display: none; }

.s3cf-cat-tab {
    flex-shrink: 0;
    padding: 7px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--s3cf-line);
    color: var(--s3cf-text-mute);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
    white-space: nowrap;
}

.s3cf-cat-tab.s3cf-active {
    background: linear-gradient(135deg, var(--s3cf-cornflower), var(--s3cf-magenta));
    color: #FFFFFF;
    border-color: transparent;
}

/* ============================================================
 * Game grid
 * ============================================================ */
.s3cf-game-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

@media (min-width: 360px) {
    .s3cf-game-grid { gap: 10px; }
}

.s3cf-game-card {
    background: rgba(22, 32, 46, 0.7);
    border: 1px solid var(--s3cf-line);
    border-radius: var(--s3cf-radius-md);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
}

.s3cf-game-card:hover, .s3cf-game-card:focus {
    transform: translateY(-2px);
    border-color: var(--s3cf-line-strong);
    box-shadow: var(--s3cf-shadow-card);
}

.s3cf-game-thumb {
    aspect-ratio: 1 / 1;
    background: linear-gradient(135deg, #1B2740, #2A1635);
    overflow: hidden;
}

.s3cf-game-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.s3cf-game-name {
    font-size: 10.5px;
    color: var(--s3cf-text);
    text-align: center;
    padding: 5px 4px;
    line-height: 1.25;
    min-height: 28px;
    background: rgba(8, 13, 20, 0.45);
}

.s3cf-empty-note {
    display: none;
    padding: 18px;
    text-align: center;
    color: var(--s3cf-text-mute);
    font-size: 13px;
}

/* Promo card row */
.s3cf-promo-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.s3cf-card-promo {
    border-radius: var(--s3cf-radius-md);
    padding: 14px;
    cursor: pointer;
    color: #FFFFFF;
    border: 1px solid var(--s3cf-line-strong);
    position: relative;
    overflow: hidden;
    min-height: 96px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.s3cf-card-promo.s3cf-c-blue {
    background: linear-gradient(135deg, #1E3A6B, #2A1635);
}

.s3cf-card-promo.s3cf-c-magenta {
    background: linear-gradient(135deg, #3D1240, #1B2740);
}

.s3cf-card-promo h3 {
    font-size: 14px;
    margin: 0 0 4px;
    color: #FFFFFF;
}

.s3cf-card-promo p {
    font-size: 11.5px;
    color: var(--s3cf-gray-soft);
    margin: 0;
}

.s3cf-card-promo .s3cf-cta-pill {
    align-self: flex-start;
    margin-top: 10px;
    background: rgba(244, 201, 93, 0.18);
    color: var(--s3cf-gold);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 999px;
}

/* ============================================================
 * Article / SEO text blocks
 * ============================================================ */
.s3cf-article {
    background: rgba(22, 32, 46, 0.55);
    border: 1px solid var(--s3cf-line);
    border-radius: var(--s3cf-radius-lg);
    padding: 18px 16px;
    color: var(--s3cf-text);
    font-size: 14px;
    line-height: 1.75;
}

.s3cf-article h2 {
    font-size: 17px;
    margin: 18px 0 10px;
    color: #FFFFFF;
}

.s3cf-article h2:first-child { margin-top: 0; }

.s3cf-article h3 {
    font-size: 14.5px;
    margin: 14px 0 8px;
    color: var(--s3cf-cornflower);
}

.s3cf-article p { color: var(--s3cf-text); margin: 0 0 12px; }

.s3cf-article ul {
    margin: 0 0 12px;
    padding-left: 18px;
}

.s3cf-article li { margin-bottom: 6px; }

.s3cf-article a {
    color: var(--s3cf-cornflower);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.s3cf-tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.s3cf-tag {
    font-size: 11px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(100, 149, 237, 0.10);
    border: 1px solid var(--s3cf-line);
    color: var(--s3cf-cornflower);
}

/* ============================================================
 * FAQ
 * ============================================================ */
.s3cf-faq-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.s3cf-faq-item {
    background: rgba(22, 32, 46, 0.6);
    border: 1px solid var(--s3cf-line);
    border-radius: var(--s3cf-radius-md);
    overflow: hidden;
}

.s3cf-faq-q {
    width: 100%;
    text-align: left;
    background: transparent;
    border: none;
    padding: 13px 14px;
    color: #FFFFFF;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.s3cf-faq-q .s3cf-chev {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    color: var(--s3cf-cornflower);
    transition: transform 0.2s ease;
}

.s3cf-faq-item.s3cf-open .s3cf-chev { transform: rotate(180deg); }

.s3cf-faq-a {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.28s ease;
    padding: 0 14px;
    color: var(--s3cf-text-mute);
    font-size: 13px;
    line-height: 1.7;
}

.s3cf-faq-item.s3cf-open .s3cf-faq-a {
    max-height: 360px;
    padding: 0 14px 14px;
}

/* ============================================================
 * Footer
 * ============================================================ */
.s3cf-footer {
    background: linear-gradient(180deg, rgba(11, 17, 25, 0.9), rgba(8, 13, 20, 0.95));
    border-top: 1px solid var(--s3cf-line-strong);
    padding: 22px 14px calc(var(--s3cf-bottomnav-h) + 22px);
    color: var(--s3cf-text-mute);
    font-size: 12.5px;
}

.s3cf-footer-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.s3cf-footer h4 {
    font-size: 12px;
    color: var(--s3cf-gray-soft);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0 0 8px;
}

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

.s3cf-footer li { margin-bottom: 6px; }

.s3cf-footer a {
    color: var(--s3cf-text-mute);
}

.s3cf-footer a:hover { color: var(--s3cf-cornflower); }

.s3cf-footer-bottom {
    border-top: 1px solid var(--s3cf-line);
    padding-top: 14px;
    text-align: center;
    color: var(--s3cf-gray);
    font-size: 11.5px;
    line-height: 1.6;
}

.s3cf-disclaimer {
    background: rgba(139, 0, 139, 0.10);
    border: 1px solid rgba(139, 0, 139, 0.30);
    border-radius: var(--s3cf-radius-md);
    padding: 10px 12px;
    font-size: 11px;
    color: var(--s3cf-gray-soft);
    margin-bottom: 14px;
    line-height: 1.6;
}

/* ============================================================
 * Bottom navigation — central lift nav
 * ============================================================ */
.s3cf-bottomnav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 65;
    max-width: var(--s3cf-max-w);
    margin: 0 auto;
    height: var(--s3cf-bottomnav-h);
    background: linear-gradient(180deg, rgba(17, 26, 38, 0.98), rgba(8, 13, 20, 0.99));
    border-top: 1px solid var(--s3cf-line-strong);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.35);
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 6px 6px calc(env(safe-area-inset-bottom, 0px) + 6px);
}

.s3cf-nav-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    background: transparent;
    border: none;
    color: var(--s3cf-text-mute);
    cursor: pointer;
    font-size: 10px;
    font-weight: 600;
    padding: 4px 2px;
    transition: color 0.18s ease, transform 0.18s ease;
    text-decoration: none;
    height: 100%;
}

.s3cf-nav-btn:visited { color: var(--s3cf-text-mute); }

.s3cf-nav-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--s3cf-line);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease, box-shadow 0.2s ease;
    margin-bottom: 1px;
}

.s3cf-nav-icon svg {
    width: 20px;
    height: 20px;
}

.s3cf-nav-btn.s3cf-current .s3cf-nav-icon {
    background: linear-gradient(135deg, var(--s3cf-cornflower), var(--s3cf-magenta));
    border-color: transparent;
    box-shadow: 0 6px 14px rgba(100, 149, 237, 0.45);
    transform: translateY(-3px);
}

.s3cf-nav-btn.s3cf-current {
    color: #FFFFFF;
}

.s3cf-nav-btn.s3cf-promo .s3cf-nav-icon {
    background: linear-gradient(135deg, rgba(244, 201, 93, 0.20), rgba(139, 0, 139, 0.25));
    border-color: rgba(244, 201, 93, 0.4);
}

.s3cf-nav-btn.s3cf-promo { color: var(--s3cf-gold); }

/* Press feedback */
.s3cf-press {
    transform: scale(0.94);
}

.s3cf-no-scroll {
    overflow: hidden;
}

/* Utilities */
.s3cf-row { display: flex; gap: 10px; flex-wrap: wrap; }
.s3cf-mt-8 { margin-top: 8px; }
.s3cf-mt-14 { margin-top: 14px; }
.s3cf-mt-20 { margin-top: 20px; }
.s3cf-mute { color: var(--s3cf-text-mute); }
.s3cf-center { text-align: center; }

/* Long-form content spacing */
.s3cf-prose p { margin-bottom: 12px; }
