/**
 * 6Jl Ph Layout Stylesheet
 * Class prefix: sbbb-
 * Colors: #8B0000 (dark red), #9966CC (purple), #141414 (dark)
 */

/* CSS Variables */
:root {
    --sbbb-primary: #8B0000;
    --sbbb-secondary: #9966CC;
    --sbbb-bg-dark: #141414;
    --sbbb-bg-card: #1a1a1a;
    --sbbb-text-light: #ffffff;
    --sbbb-text-muted: #b0b0b0;
    --sbbb-accent: #9966CC;
    --sbbb-gradient: linear-gradient(135deg, #8B0000 0%, #9966CC 100%);
    --sbbb-shadow: 0 4px 20px rgba(139, 0, 0, 0.3);
    --sbbb-radius: 8px;
    --sbbb-radius-lg: 16px;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 62.5%;
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--sbbb-bg-dark);
    color: var(--sbbb-text-light);
    line-height: 1.5;
    font-size: 1.4rem;
    max-width: 430px;
    margin: 0 auto;
    overflow-x: hidden;
}

/* Container */
.sbbb-container {
    width: 100%;
    padding: 0 12px;
    margin: 0 auto;
}

.sbbb-wrapper {
    max-width: 430px;
    margin: 0 auto;
}

/* Header */
.sbbb-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: linear-gradient(180deg, rgba(20, 20, 20, 0.98) 0%, rgba(20, 20, 20, 0.95) 100%);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(139, 0, 0, 0.3);
    max-width: 430px;
    margin: 0 auto;
}

.sbbb-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    min-height: 56px;
}

.sbbb-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.sbbb-logo img {
    width: 28px;
    height: 28px;
    border-radius: 6px;
}

.sbbb-logo-text {
    font-size: 1.6rem;
    font-weight: 700;
    background: var(--sbbb-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sbbb-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sbbb-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: var(--sbbb-radius);
    font-size: 1.3rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
    text-decoration: none;
    min-height: 36px;
}

.sbbb-btn-primary {
    background: var(--sbbb-gradient);
    color: var(--sbbb-text-light);
    box-shadow: var(--sbbb-shadow);
}

.sbbb-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(139, 0, 0, 0.4);
}

.sbbb-btn-outline {
    background: transparent;
    color: var(--sbbb-secondary);
    border: 2px solid var(--sbbb-secondary);
}

.sbbb-btn-outline:hover {
    background: var(--sbbb-secondary);
    color: var(--sbbb-text-light);
}

.sbbb-menu-toggle {
    background: none;
    border: none;
    color: var(--sbbb-text-light);
    font-size: 2rem;
    cursor: pointer;
    padding: 4px 8px;
}

/* Mobile Menu */
.sbbb-mobile-menu {
    position: fixed;
    top: 0;
    right: -280px;
    width: 280px;
    height: 100vh;
    background: var(--sbbb-bg-dark);
    z-index: 9999;
    transition: right 0.3s ease;
    padding: 60px 20px 20px;
    overflow-y: auto;
    border-left: 1px solid rgba(139, 0, 0, 0.3);
}

.sbbb-menu-active {
    right: 0;
}

.sbbb-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.sbbb-overlay-active {
    opacity: 1;
    visibility: visible;
}

.sbbb-menu-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    color: var(--sbbb-text-light);
    font-size: 2.4rem;
    cursor: pointer;
}

.sbbb-menu-list {
    list-style: none;
}

.sbbb-menu-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sbbb-menu-link {
    display: block;
    padding: 14px 0;
    color: var(--sbbb-text-light);
    text-decoration: none;
    font-size: 1.4rem;
    transition: color 0.3s ease;
}

.sbbb-menu-link:hover {
    color: var(--sbbb-secondary);
}

/* Main Content */
.sbbb-main {
    padding-top: 56px;
    padding-bottom: 80px;
}

/* Carousel */
.sbbb-carousel {
    position: relative;
    overflow: hidden;
    border-radius: 0 0 var(--sbbb-radius-lg) var(--sbbb-radius-lg);
}

.sbbb-slides {
    position: relative;
}

.sbbb-slide {
    display: none;
    cursor: pointer;
    transition: opacity 0.5s ease;
}

.sbbb-slide-active {
    display: block;
}

.sbbb-slide img {
    width: 100%;
    height: auto;
    display: block;
}

.sbbb-dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}

.sbbb-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.sbbb-dot-active {
    background: var(--sbbb-secondary);
    width: 24px;
    border-radius: 4px;
}

/* Section Titles */
.sbbb-section {
    padding: 20px 12px;
}

.sbbb-section-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 16px;
    background: var(--sbbb-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sbbb-subtitle {
    font-size: 1.4rem;
    color: var(--sbbb-text-muted);
    margin-bottom: 12px;
}

/* Game Grid */
.sbbb-game-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.sbbb-game-item {
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.sbbb-game-item:hover {
    transform: scale(1.05);
}

.sbbb-game-img {
    width: 100%;
    aspect-ratio: 1;
    border-radius: var(--sbbb-radius);
    object-fit: cover;
    margin-bottom: 6px;
    border: 2px solid transparent;
    transition: border-color 0.3s ease;
}

.sbbb-game-item:hover .sbbb-game-img {
    border-color: var(--sbbb-secondary);
}

.sbbb-game-name {
    font-size: 1.1rem;
    color: var(--sbbb-text-light);
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Category Section */
.sbbb-category-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 20px 0 12px;
    padding-left: 8px;
    border-left: 3px solid var(--sbbb-primary);
    color: var(--sbbb-text-light);
}

/* Cards */
.sbbb-card {
    background: var(--sbbb-bg-card);
    border-radius: var(--sbbb-radius-lg);
    padding: 16px;
    margin-bottom: 16px;
    border: 1px solid rgba(139, 0, 0, 0.2);
}

.sbbb-card-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--sbbb-secondary);
}

.sbbb-card-text {
    font-size: 1.3rem;
    color: var(--sbbb-text-muted);
    line-height: 1.6;
}

/* Features List */
.sbbb-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.sbbb-feature-item {
    background: var(--sbbb-bg-card);
    padding: 12px;
    border-radius: var(--sbbb-radius);
    text-align: center;
    border: 1px solid rgba(153, 102, 204, 0.2);
}

.sbbb-feature-icon {
    font-size: 2.4rem;
    margin-bottom: 8px;
    color: var(--sbbb-secondary);
}

.sbbb-feature-text {
    font-size: 1.2rem;
    color: var(--sbbb-text-light);
}

/* Promo Banner */
.sbbb-promo-banner {
    background: var(--sbbb-gradient);
    border-radius: var(--sbbb-radius-lg);
    padding: 20px;
    text-align: center;
    margin: 16px 12px;
}

.sbbb-promo-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.sbbb-promo-text {
    font-size: 1.3rem;
    margin-bottom: 12px;
    opacity: 0.9;
}

/* Bottom Navigation */
.sbbb-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: linear-gradient(180deg, rgba(20, 20, 20, 0.98) 0%, rgba(20, 20, 20, 1) 100%);
    border-top: 1px solid rgba(139, 0, 0, 0.3);
    max-width: 430px;
    margin: 0 auto;
}

.sbbb-nav-items {
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 8px 0;
    min-height: 60px;
}

.sbbb-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    min-height: 48px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: var(--sbbb-text-muted);
}

.sbbb-nav-item:hover,
.sbbb-nav-item-active {
    color: var(--sbbb-secondary);
}

.sbbb-nav-item:hover .sbbb-nav-icon {
    transform: scale(1.1);
}

.sbbb-nav-icon {
    font-size: 2.2rem;
    margin-bottom: 4px;
    transition: transform 0.3s ease;
}

.sbbb-nav-text {
    font-size: 1rem;
    font-weight: 500;
}

/* Footer */
.sbbb-footer {
    background: var(--sbbb-bg-card);
    padding: 24px 12px;
    border-top: 1px solid rgba(139, 0, 0, 0.2);
}

.sbbb-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    justify-content: center;
}

.sbbb-footer-link {
    color: var(--sbbb-text-muted);
    text-decoration: none;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.sbbb-footer-link:hover {
    color: var(--sbbb-secondary);
}

.sbbb-partners {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-bottom: 16px;
}

.sbbb-partner-img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.sbbb-partner-img:hover {
    opacity: 1;
}

.sbbb-copyright {
    text-align: center;
    font-size: 1.1rem;
    color: var(--sbbb-text-muted);
}

/* Responsive */
@media (min-width: 769px) {
    .sbbb-bottom-nav {
        display: none;
    }

    .sbbb-main {
        padding-bottom: 20px;
    }
}

/* Utility Classes */
.sbbb-text-center { text-align: center; }
.sbbb-text-primary { color: var(--sbbb-primary); }
.sbbb-text-secondary { color: var(--sbbb-secondary); }
.sbbb-mt-10 { margin-top: 10px; }
.sbbb-mb-10 { margin-bottom: 10px; }
.sbbb-mb-20 { margin-bottom: 20px; }
.sbbb-p-10 { padding: 10px; }
.sbbb-hidden { display: none; }

/* Animation */
@keyframes sbbb-fade-in {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.sbbb-animate {
    animation: sbbb-fade-in 0.5s ease forwards;
}
