/**
 * PH777 Website CSS Module
 * All classes use s654- prefix for namespace isolation
 * @version 1.0.0
 */

/* CSS Variables */
:root {
    --s654-primary: #A9A9A9;
    --s654-secondary: #F8F8FF;
    --s654-bg: #1A1A1A;
    --s654-text: #F8F8FF;
    --s654-accent: #D4AF37;
    --s654-hover: #B8860B;
    --s654-border: #333333;
    --s654-card-bg: #252525;
    --s654-gradient-start: #1A1A1A;
    --s654-gradient-end: #2D2D2D;
}

/* Base Styles */
html {
    font-size: 62.5%;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, var(--s654-gradient-start), var(--s654-gradient-end));
    color: var(--s654-text);
    line-height: 1.5rem;
    min-height: 100vh;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    height: auto;
}

/* Container */
.s654-container {
    max-width: 430px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header */
.s654-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(26, 26, 26, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--s654-border);
}

.s654-header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 430px;
    margin: 0 auto;
}

.s654-logo {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.s654-logo img {
    width: 28px;
    height: 28px;
}

.s654-logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(90deg, var(--s654-accent), #FFD700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.s654-header-btns {
    display: flex;
    gap: 0.8rem;
}

.s654-btn {
    padding: 0.6rem 1.2rem;
    border-radius: 0.6rem;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.s654-btn-login {
    background: transparent;
    color: var(--s654-text);
    border: 1px solid var(--s654-accent);
}

.s654-btn-login:hover {
    background: var(--s654-accent);
    color: var(--s654-bg);
}

.s654-btn-register {
    background: linear-gradient(135deg, var(--s654-accent), var(--s654-hover));
    color: var(--s654-bg);
}

.s654-btn-register:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
}

/* Menu Toggle */
.s654-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--s654-text);
    font-size: 2.4rem;
    cursor: pointer;
    padding: 0.5rem;
}

/* Navigation */
.s654-nav {
    display: none;
}

.s654-nav-list {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

.s654-nav-link {
    font-size: 1.3rem;
    color: var(--s654-secondary);
    transition: color 0.3s;
}

.s654-nav-link:hover {
    color: var(--s654-accent);
}

/* Mobile Menu */
#web541-mobile-menu {
    position: fixed;
    top: 0;
    right: -280px;
    width: 280px;
    height: 100vh;
    background: var(--s654-bg);
    z-index: 9999;
    transition: right 0.3s ease;
    padding: 2rem;
    overflow-y: auto;
}

.web541-menu-active {
    right: 0 !important;
}

.s654-mobile-nav-list {
    list-style: none;
    margin-top: 3rem;
}

.s654-mobile-nav-item {
    padding: 1.2rem 0;
    border-bottom: 1px solid var(--s654-border);
}

.s654-mobile-nav-link {
    font-size: 1.4rem;
    color: var(--s654-secondary);
    transition: color 0.3s;
    display: block;
}

.s654-mobile-nav-link:hover {
    color: var(--s654-accent);
}

#web541-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;
}

.web541-overlay-active {
    opacity: 1 !important;
    visibility: visible !important;
}

.s654-menu-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    color: var(--s654-text);
    font-size: 2.4rem;
    cursor: pointer;
}

/* Main Content */
.s654-main {
    padding-top: 6rem;
    padding-bottom: 2rem;
}

@media (max-width: 768px) {
    .s654-main {
        padding-bottom: 8rem;
    }
}

/* Carousel */
.s654-carousel {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
    border-radius: 1rem;
    margin-bottom: 2rem;
}

.s654-slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    cursor: pointer;
}

.web541-slide-active {
    opacity: 1;
}

.s654-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.s654-carousel-dots {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
}

.s654-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
}

/* Section Title */
.s654-section-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--s654-accent);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.s654-section-title i {
    font-size: 2rem;
}

/* Game Grid */
.s654-game-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.s654-game-item {
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s;
}

.s654-game-item:hover {
    transform: scale(1.05);
}

.s654-game-img {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 0.8rem;
    object-fit: cover;
    border: 2px solid var(--s654-border);
    transition: border-color 0.3s;
}

.s654-game-item:hover .s654-game-img {
    border-color: var(--s654-accent);
}

.s654-game-name {
    font-size: 1rem;
    color: var(--s654-secondary);
    margin-top: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Category Label */
.s654-category-label {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--s654-accent);
    margin-bottom: 1rem;
    padding-left: 1rem;
    border-left: 3px solid var(--s654-accent);
}

/* Content Section */
.s654-content-section {
    background: var(--s654-card-bg);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--s654-border);
}

.s654-content-section h2 {
    font-size: 1.6rem;
    color: var(--s654-accent);
    margin-bottom: 1rem;
}

.s654-content-section p {
    font-size: 1.3rem;
    line-height: 1.8;
    color: var(--s654-secondary);
    margin-bottom: 1rem;
}

.s654-content-section ul {
    list-style: none;
    padding-left: 1rem;
}

.s654-content-section li {
    font-size: 1.3rem;
    color: var(--s654-secondary);
    padding: 0.5rem 0;
    position: relative;
    padding-left: 1.5rem;
}

.s654-content-section li::before {
    content: '>';
    position: absolute;
    left: 0;
    color: var(--s654-accent);
}

/* Promo Link */
.s654-promo-link {
    color: var(--s654-accent);
    font-weight: 600;
    cursor: pointer;
    transition: color 0.3s;
}

.s654-promo-link:hover {
    color: var(--s654-hover);
    text-decoration: underline;
}

.s654-promo-btn {
    display: inline-block;
    background: linear-gradient(135deg, var(--s654-accent), var(--s654-hover));
    color: var(--s654-bg);
    padding: 1rem 2rem;
    border-radius: 0.8rem;
    font-size: 1.4rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    margin: 1rem 0;
}

.s654-promo-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 20px rgba(212, 175, 55, 0.4);
}

/* Footer */
.s654-footer {
    background: var(--s654-card-bg);
    padding: 2rem 1.5rem;
    border-top: 1px solid var(--s654-border);
}

.s654-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.s654-footer-link {
    font-size: 1.2rem;
    color: var(--s654-secondary);
    transition: color 0.3s;
}

.s654-footer-link:hover {
    color: var(--s654-accent);
}

.s654-partners {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.s654-partner-img {
    width: 40px;
    height: 25px;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s;
}

.s654-partner-img:hover {
    filter: grayscale(0%);
    opacity: 1;
}

.s654-copyright {
    text-align: center;
    font-size: 1.1rem;
    color: var(--s654-primary);
}

/* Mobile Bottom Navigation */
.s654-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(180deg, #2D2D2D, #1A1A1A);
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1000;
    border-top: 1px solid var(--s654-accent);
}

.s654-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    min-height: 60px;
    cursor: pointer;
    transition: all 0.3s;
    color: var(--s654-secondary);
}

.s654-bottom-nav-item:hover,
.s654-bottom-nav-item.active {
    color: var(--s654-accent);
    transform: scale(1.1);
}

.s654-bottom-nav-item i {
    font-size: 22px;
    margin-bottom: 0.3rem;
}

.s654-bottom-nav-item span {
    font-size: 10px;
    font-weight: 500;
}

/* Desktop: hide bottom nav */
@media (min-width: 769px) {
    .s654-bottom-nav {
        display: none;
    }

    .s654-menu-toggle {
        display: block;
    }
}

/* Mobile Menu Toggle Visible */
@media (max-width: 768px) {
    .s654-menu-toggle {
        display: block;
    }

    .s654-header-btns {
        gap: 0.5rem;
    }

    .s654-btn {
        padding: 0.5rem 0.8rem;
        font-size: 1.1rem;
    }
}

/* FAQ Section */
.s654-faq-item {
    background: var(--s654-card-bg);
    border-radius: 0.8rem;
    margin-bottom: 1rem;
    border: 1px solid var(--s654-border);
    overflow: hidden;
}

.s654-faq-question {
    padding: 1rem 1.5rem;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--s654-accent);
    cursor: pointer;
}

.s654-faq-answer {
    padding: 0 1.5rem 1rem;
    font-size: 1.2rem;
    color: var(--s654-secondary);
    line-height: 1.6;
}

/* Feature List */
.s654-feature-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.s654-feature-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    background: var(--s654-card-bg);
    border-radius: 0.8rem;
    border: 1px solid var(--s654-border);
}

.s654-feature-icon {
    font-size: 2.4rem;
    color: var(--s654-accent);
    flex-shrink: 0;
}

.s654-feature-text h3 {
    font-size: 1.4rem;
    color: var(--s654-text);
    margin-bottom: 0.5rem;
}

.s654-feature-text p {
    font-size: 1.2rem;
    color: var(--s654-secondary);
    line-height: 1.5;
}

/* Promo Banner */
.s654-promo-banner {
    background: linear-gradient(135deg, var(--s654-accent), #B8860B);
    border-radius: 1rem;
    padding: 1.5rem;
    text-align: center;
    margin-bottom: 1.5rem;
}

.s654-promo-banner h3 {
    font-size: 1.6rem;
    color: var(--s654-bg);
    margin-bottom: 0.5rem;
}

.s654-promo-banner p {
    font-size: 1.2rem;
    color: var(--s654-bg);
    opacity: 0.9;
}

/* Internal Link */
.s654-internal-link {
    color: var(--s654-accent);
    text-decoration: underline;
    transition: color 0.3s;
}

.s654-internal-link:hover {
    color: var(--s654-hover);
}

/* Responsive adjustments */
@media (max-width: 380px) {
    .s654-game-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.8rem;
    }

    .s654-game-name {
        font-size: 0.9rem;
    }
}
