/**
 * 8999 bed Gaming Platform - Theme Stylesheet
 * Color Palette: Sienna #A0522D | Dark Blue-Gray #273746 | Yellow #FFEB3B | Amber #FFAA00 | Pink #FFB6C1
 * All classes prefixed with v359- for namespace isolation
 * CSS variables prefixed with --v359-*
 */

/* === CSS Variables === */
:root {
    --v359-primary: #A0522D;
    --v359-bg-dark: #273746;
    --v359-bg-darker: #1a252f;
    --v359-bg-card: #2c3e50;
    --v359-yellow: #FFEB3B;
    --v359-amber: #FFAA00;
    --v359-pink: #FFB6C1;
    --v359-text-light: #f0f0f0;
    --v359-text-muted: #b0bec5;
    --v359-border: #3d5266;
    --v359-shadow: rgba(0,0,0,0.3);
    --v359-radius: 10px;
    --v359-transition: all 0.3s ease;
}

/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    font-family: 'Noto Sans Bengali', 'Hind Siliguri', Arial, sans-serif;
    background: var(--v359-bg-dark);
    color: var(--v359-text-light);
    line-height: 1.6;
    min-height: 100vh;
    max-width: 100%;
    overflow-x: hidden;
}
a { text-decoration: none; color: var(--v359-yellow); transition: var(--v359-transition); }
a:hover { color: var(--v359-amber); }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

/* === Header === */
.v359-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    background: linear-gradient(135deg, var(--v359-bg-darker) 0%, var(--v359-primary) 100%);
    padding: 8px 12px;
    display: flex; align-items: center; justify-content: space-between;
    box-shadow: 0 2px 12px var(--v359-shadow);
    height: 56px;
}
.v359-header-left { display: flex; align-items: center; gap: 8px; }
.v359-header-logo {
    width: 36px; height: 36px; border-radius: 8px;
    border: 2px solid var(--v359-amber);
}
.v359-header-title {
    font-size: 18px; font-weight: 700; color: var(--v359-yellow);
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}
.v359-header-right { display: flex; align-items: center; gap: 8px; }
.v359-btn-register {
    background: linear-gradient(135deg, var(--v359-amber), #ff8800);
    color: #1a1a1a; border: none; padding: 7px 16px; border-radius: 20px;
    font-weight: 700; font-size: 13px; cursor: pointer;
    transition: var(--v359-transition); font-family: inherit;
}
.v359-btn-register:hover { transform: scale(1.05); box-shadow: 0 0 12px rgba(255,170,0,0.5); }
.v359-btn-login {
    background: transparent; color: var(--v359-yellow);
    border: 1.5px solid var(--v359-yellow); padding: 6px 14px; border-radius: 20px;
    font-weight: 600; font-size: 13px; cursor: pointer;
    transition: var(--v359-transition); font-family: inherit;
}
.v359-btn-login:hover { background: rgba(255,235,59,0.1); }
.v359-hamburger {
    background: none; border: none; color: var(--v359-yellow);
    font-size: 24px; cursor: pointer; padding: 4px;
    display: flex; align-items: center; justify-content: center;
}

/* === Mobile Menu === */
.v359-menu-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,0.6); z-index: 9998;
}
.v359-mobile-menu {
    position: fixed; top: 0; right: -280px; width: 280px;
    height: 100vh; background: var(--v359-bg-darker);
    z-index: 9999; transition: right 0.3s ease;
    padding: 20px; overflow-y: auto;
}
.v359-menu-active { right: 0 !important; }
.v359-menu-hidden { right: -280px; }
.v359-menu-close {
    background: none; border: none; color: var(--v359-yellow);
    font-size: 28px; cursor: pointer; float: right; margin-bottom: 20px;
}
.v359-menu-links { clear: both; padding-top: 20px; }
.v359-menu-link {
    display: block; padding: 12px 16px; color: var(--v359-text-light);
    border-bottom: 1px solid var(--v359-border); font-size: 15px;
    transition: var(--v359-transition);
}
.v359-menu-link:hover { background: rgba(160,82,45,0.2); color: var(--v359-yellow); padding-left: 22px; }

/* === Main Content === */
.v359-main { padding-top: 56px; }
@media (max-width: 768px) { .v359-main { padding-bottom: 80px; } }

/* === Carousel === */
.v359-carousel {
    position: relative; width: 100%; max-width: 430px;
    margin: 0 auto; overflow: hidden; border-radius: 0 0 var(--v359-radius) var(--v359-radius);
}
.v359-carousel-slide {
    display: none; width: 100%; aspect-ratio: 16/9;
    object-fit: cover; cursor: pointer;
    transition: opacity 0.5s ease;
}
.v359-slide-active { display: block; }
.v359-carousel-dots {
    position: absolute; bottom: 10px; left: 50%;
    transform: translateX(-50%); display: flex; gap: 8px; z-index: 5;
}
.v359-carousel-dot {
    width: 10px; height: 10px; border-radius: 50%;
    background: rgba(255,255,255,0.4); cursor: pointer;
    transition: var(--v359-transition); border: none;
}
.v359-dot-active { background: var(--v359-amber); transform: scale(1.3); }

/* === Section Titles === */
.v359-section-title {
    font-size: 20px; font-weight: 700; color: var(--v359-yellow);
    padding: 16px 16px 8px; display: flex; align-items: center; gap: 8px;
}
.v359-section-title i { color: var(--v359-amber); font-size: 22px; }

/* === Game Category Tabs === */
.v359-category-tabs {
    display: flex; gap: 8px; padding: 8px 16px;
    overflow-x: auto; -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.v359-category-tabs::-webkit-scrollbar { display: none; }
.v359-cat-tab {
    background: var(--v359-bg-card); color: var(--v359-text-muted);
    border: 1px solid var(--v359-border); padding: 8px 16px;
    border-radius: 20px; font-size: 13px; white-space: nowrap;
    cursor: pointer; transition: var(--v359-transition); font-family: inherit;
}
.v359-cat-tab:hover, .v359-cat-tab-active {
    background: var(--v359-primary); color: var(--v359-yellow);
    border-color: var(--v359-amber);
}

/* === Game Grid === */
.v359-game-grid {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 8px; padding: 8px 16px;
}
.v359-game-item {
    text-align: center; cursor: pointer;
    transition: var(--v359-transition); border-radius: var(--v359-radius);
    padding: 6px;
}
.v359-game-item:hover { transform: translateY(-3px); background: rgba(160,82,45,0.15); }
.v359-game-img {
    width: 100%; aspect-ratio: 1; border-radius: 12px;
    border: 2px solid var(--v359-border); object-fit: cover;
    transition: var(--v359-transition);
}
.v359-game-item:hover .v359-game-img { border-color: var(--v359-amber); }
.v359-game-name {
    font-size: 11px; color: var(--v359-text-muted);
    margin-top: 4px; line-height: 1.3;
    overflow: hidden; text-overflow: ellipsis;
    white-space: nowrap;
}

/* === Promo Banner === */
.v359-promo-banner {
    background: linear-gradient(135deg, var(--v359-primary), #8B4513);
    margin: 12px 16px; padding: 16px; border-radius: var(--v359-radius);
    text-align: center; cursor: pointer;
    border: 2px solid var(--v359-amber);
    transition: var(--v359-transition);
}
.v359-promo-banner:hover { transform: scale(1.02); box-shadow: 0 4px 20px rgba(255,170,0,0.3); }
.v359-promo-title {
    font-size: 18px; font-weight: 700; color: var(--v359-yellow);
    margin-bottom: 6px;
}
.v359-promo-text { font-size: 13px; color: var(--v359-pink); }
.v359-promo-btn {
    display: inline-block; margin-top: 10px;
    background: var(--v359-amber); color: #1a1a1a;
    padding: 8px 24px; border-radius: 20px;
    font-weight: 700; font-size: 14px;
}

/* === Features Grid === */
.v359-features {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 10px; padding: 12px 16px;
}
.v359-feature-card {
    background: var(--v359-bg-card); border-radius: var(--v359-radius);
    padding: 14px 8px; text-align: center;
    border: 1px solid var(--v359-border);
    transition: var(--v359-transition);
}
.v359-feature-card:hover { border-color: var(--v359-amber); transform: translateY(-2px); }
.v359-feature-icon { font-size: 28px; margin-bottom: 6px; color: var(--v359-amber); }
.v359-feature-title { font-size: 12px; font-weight: 600; color: var(--v359-yellow); }
.v359-feature-desc { font-size: 11px; color: var(--v359-text-muted); margin-top: 3px; }

/* === Content Section === */
.v359-content-section {
    padding: 16px; margin: 0;
}
.v359-content-section h2 {
    font-size: 18px; color: var(--v359-yellow);
    margin-bottom: 10px; padding-bottom: 6px;
    border-bottom: 2px solid var(--v359-primary);
}
.v359-content-section p {
    font-size: 14px; color: var(--v359-text-muted);
    line-height: 1.7; margin-bottom: 10px;
}
.v359-content-section a { color: var(--v359-amber); text-decoration: underline; }

/* === Bottom Navigation === */
.v359-bottom-nav {
    display: none; position: fixed; bottom: 0; left: 0; right: 0;
    z-index: 1000; height: 60px;
    background: linear-gradient(180deg, var(--v359-bg-darker), #111820);
    border-top: 2px solid var(--v359-primary);
    justify-content: space-around; align-items: center;
    box-shadow: 0 -2px 12px var(--v359-shadow);
}
@media (max-width: 768px) { .v359-bottom-nav { display: flex; } }
.v359-bottom-nav-btn {
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; min-width: 60px; min-height: 54px;
    background: none; border: none; color: var(--v359-text-muted);
    cursor: pointer; transition: var(--v359-transition);
    font-family: inherit; padding: 4px; border-radius: 8px;
}
.v359-bottom-nav-btn:hover, .v359-nav-active {
    color: var(--v359-amber);
    background: rgba(160,82,45,0.2);
}
.v359-bottom-nav-btn i, .v359-bottom-nav-btn .material-icons {
    font-size: 24px; margin-bottom: 2px;
}
.v359-bottom-nav-btn span {
    font-size: 10px; font-weight: 500;
}

/* === Scroll to Top === */
.v359-scroll-top {
    position: fixed; bottom: 72px; right: 16px; z-index: 999;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--v359-primary); color: var(--v359-yellow);
    border: 2px solid var(--v359-amber); cursor: pointer;
    display: none; align-items: center; justify-content: center;
    font-size: 20px; box-shadow: 0 2px 10px var(--v359-shadow);
    transition: var(--v359-transition); opacity: 0;
}
.v359-scroll-top:hover { transform: scale(1.1); background: var(--v359-amber); color: #1a1a1a; }

/* === Footer === */
.v359-footer {
    background: var(--v359-bg-darker); padding: 24px 16px;
    border-top: 2px solid var(--v359-primary);
}
.v359-footer-brand { text-align: center; margin-bottom: 16px; }
.v359-footer-brand h3 { font-size: 18px; color: var(--v359-yellow); margin-bottom: 6px; }
.v359-footer-brand p { font-size: 13px; color: var(--v359-text-muted); line-height: 1.5; }
.v359-footer-links {
    display: grid; grid-template-columns: repeat(2, 1fr);
    gap: 8px; margin: 16px 0;
}
.v359-footer-link {
    display: block; padding: 6px 0; color: var(--v359-text-muted);
    font-size: 13px; transition: var(--v359-transition);
}
.v359-footer-link:hover { color: var(--v359-yellow); padding-left: 4px; }
.v359-footer-partners {
    display: flex; flex-wrap: wrap; justify-content: center;
    gap: 12px; margin: 16px 0; padding: 12px 0;
    border-top: 1px solid var(--v359-border); border-bottom: 1px solid var(--v359-border);
}
.v359-footer-partner {
    font-size: 11px; color: var(--v359-text-muted);
    background: var(--v359-bg-card); padding: 4px 10px;
    border-radius: 4px; border: 1px solid var(--v359-border);
}
.v359-footer-copy {
    text-align: center; font-size: 12px;
    color: var(--v359-text-muted); margin-top: 12px;
}

/* === Help Page Styles === */
.v359-help-section { padding: 16px; margin-bottom: 12px; }
.v359-help-section h2 {
    font-size: 18px; color: var(--v359-yellow);
    margin-bottom: 10px; padding-bottom: 6px;
    border-bottom: 2px solid var(--v359-primary);
}
.v359-help-section h3 {
    font-size: 15px; color: var(--v359-amber);
    margin: 12px 0 6px;
}
.v359-help-section p, .v359-help-section li {
    font-size: 14px; color: var(--v359-text-muted);
    line-height: 1.7; margin-bottom: 8px;
}
.v359-help-section ol { padding-left: 20px; list-style: decimal; }
.v359-help-section ul { padding-left: 20px; list-style: disc; }
.v359-cta-box {
    background: linear-gradient(135deg, var(--v359-primary), #8B4513);
    border: 2px solid var(--v359-amber); border-radius: var(--v359-radius);
    padding: 20px; text-align: center; margin: 16px;
}
.v359-cta-box h3 { font-size: 16px; color: var(--v359-yellow); margin-bottom: 8px; }
.v359-cta-box p { font-size: 14px; color: var(--v359-pink); margin-bottom: 12px; }
.v359-cta-btn {
    display: inline-block; background: var(--v359-amber);
    color: #1a1a1a; padding: 10px 28px; border-radius: 24px;
    font-weight: 700; font-size: 15px; cursor: pointer;
    transition: var(--v359-transition);
}
.v359-cta-btn:hover { transform: scale(1.05); box-shadow: 0 0 15px rgba(255,170,0,0.4); }

/* === Utility === */
.v359-container { max-width: 430px; margin: 0 auto; }
.v359-text-center { text-align: center; }
.v359-mt-1 { margin-top: 8px; }
.v359-mb-1 { margin-bottom: 8px; }
.v359-hidden { display: none !important; }

/* === Desktop Overrides === */
@media (min-width: 769px) {
    .v359-bottom-nav { display: none !important; }
    .v359-container { max-width: 800px; }
    .v359-game-grid { grid-template-columns: repeat(6, 1fr); }
    .v359-features { grid-template-columns: repeat(4, 1fr); }
    .v359-footer-links { grid-template-columns: repeat(3, 1fr); }
}
