/**
 * Table Game Website CSS
 * All classes use s438- prefix for namespace isolation
 * @version 1.0.0
 */

/* CSS Variables */
:root {
    --s438-primary: #C71585;
    --s438-secondary: #FF69B4;
    --s438-accent: #880E4F;
    --s438-bg-dark: #2E4057;
    --s438-bg-light: #E0FFFF;
    --s438-text-light: #E0FFFF;
    --s438-text-dark: #2E4057;
    --s438-gradient-start: #C71585;
    --s438-gradient-end: #880E4F;
    --s438-header-height: 60px;
    --s438-bottom-nav-height: 64px;
}

/* Base Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 62.5%;
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 1.6rem;
    line-height: 1.5;
    background: var(--s438-bg-dark);
    color: var(--s438-text-light);
    min-height: 100vh;
}

/* Container */
.s438-container {
    max-width: 430px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header Styles */
.s438-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--s438-header-height);
    background: linear-gradient(135deg, var(--s438-bg-dark) 0%, #1a2a3a 100%);
    border-bottom: 2px solid var(--s438-primary);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
}

.s438-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
}

.s438-logo img {
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.s438-logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--s438-secondary);
    text-shadow: 0 0 10px rgba(255, 105, 180, 0.5);
}

.s438-header-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.s438-btn {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1.4rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.s438-btn-primary {
    background: linear-gradient(135deg, var(--s438-primary) 0%, var(--s438-accent) 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(199, 21, 133, 0.4);
}

.s438-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(199, 21, 133, 0.6);
}

.s438-btn-secondary {
    background: transparent;
    color: var(--s438-secondary);
    border: 2px solid var(--s438-secondary);
}

.s438-btn-secondary:hover {
    background: var(--s438-secondary);
    color: var(--s438-bg-dark);
}

.s438-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    color: var(--s438-secondary);
    font-size: 2.4rem;
    cursor: pointer;
    padding: 0.5rem;
}

/* Mobile Menu */
.s438-mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: linear-gradient(180deg, var(--s438-bg-dark) 0%, #1a2a3a 100%);
    z-index: 9999;
    transition: right 0.3s ease;
    padding: 2rem;
    overflow-y: auto;
}

.site8d9-menu-active {
    right: 0;
}

.s438-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;
}

.site8d9-overlay-active {
    opacity: 1;
    visibility: visible;
}

.s438-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 105, 180, 0.3);
}

.s438-menu-close {
    background: transparent;
    border: none;
    color: var(--s438-secondary);
    font-size: 2.4rem;
    cursor: pointer;
}

.s438-menu-nav {
    list-style: none;
}

.s438-menu-nav li {
    margin-bottom: 1rem;
}

.s438-menu-nav a {
    color: var(--s438-text-light);
    text-decoration: none;
    font-size: 1.6rem;
    padding: 1rem;
    display: block;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.s438-menu-nav a:hover {
    background: rgba(199, 21, 133, 0.2);
    color: var(--s438-secondary);
}

/* Main Content */
.s438-main {
    padding-top: calc(var(--s438-header-height) + 2rem);
    padding-bottom: 2rem;
}

/* Carousel Styles */
.s438-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 2rem;
}

.s438-carousel-track {
    display: flex;
    transition: transform 0.5s ease;
}

.s438-slide {
    min-width: 100%;
    cursor: pointer;
}

.s438-slide img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
}

.s438-carousel-dots {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.8rem;
}

.s438-carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.s438-dot-active {
    background: var(--s438-secondary);
    transform: scale(1.2);
}

/* Section Styles */
.s438-section {
    margin-bottom: 3rem;
    padding: 0 1.5rem;
}

.s438-section-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--s438-secondary);
    margin-bottom: 1.5rem;
    text-align: center;
    text-shadow: 0 0 15px rgba(255, 105, 180, 0.3);
}

.s438-section-subtitle {
    font-size: 1.6rem;
    color: var(--s438-text-light);
    text-align: center;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Game Grid */
.s438-game-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.s438-game-item {
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.s438-game-item:hover {
    transform: scale(1.05);
}

.s438-game-icon {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 12px;
    object-fit: cover;
    margin-bottom: 0.5rem;
    border: 2px solid rgba(199, 21, 133, 0.3);
    transition: border-color 0.3s ease;
}

.s438-game-item:hover .s438-game-icon {
    border-color: var(--s438-secondary);
}

.s438-game-name {
    font-size: 1.2rem;
    color: var(--s438-text-light);
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Category Title */
.s438-category-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--s438-secondary);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--s438-primary);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

/* Card Styles */
.s438-card {
    background: linear-gradient(135deg, rgba(46, 64, 87, 0.8) 0%, rgba(26, 42, 58, 0.9) 100%);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(199, 21, 133, 0.2);
}

.s438-card-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--s438-secondary);
    margin-bottom: 1rem;
}

.s438-card-content {
    font-size: 1.4rem;
    line-height: 1.6;
    color: var(--s438-text-light);
}

/* Footer Styles */
.s438-footer {
    background: linear-gradient(180deg, var(--s438-bg-dark) 0%, #1a2a3a 100%);
    padding: 3rem 1.5rem;
    margin-top: 3rem;
    border-top: 2px solid var(--s438-primary);
}

.s438-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 2rem;
}

.s438-footer-link {
    color: var(--s438-secondary);
    text-decoration: none;
    font-size: 1.4rem;
    transition: color 0.3s ease;
}

.s438-footer-link:hover {
    color: var(--s438-text-light);
}

.s438-partners {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.s438-partner-logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.s438-partner-logo:hover {
    opacity: 1;
}

.s438-copyright {
    text-align: center;
    font-size: 1.2rem;
    color: rgba(224, 255, 255, 0.6);
}

/* Bottom Navigation */
.s438-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--s438-bottom-nav-height);
    background: linear-gradient(180deg, rgba(46, 64, 87, 0.98) 0%, rgba(26, 42, 58, 0.99) 100%);
    border-top: 2px solid var(--s438-primary);
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1000;
    padding: 0 0.5rem;
}

.s438-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    min-height: 60px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 12px;
}

.s438-nav-item:hover {
    background: rgba(199, 21, 133, 0.2);
    transform: scale(1.1);
}

.s438-nav-icon {
    font-size: 2.4rem;
    margin-bottom: 0.2rem;
    transition: color 0.3s ease;
}

.s438-nav-item:hover .s438-nav-icon {
    color: var(--s438-secondary);
}

.s438-nav-text {
    font-size: 1rem;
    color: var(--s438-text-light);
    transition: color 0.3s ease;
}

.s438-nav-item:hover .s438-nav-text {
    color: var(--s438-secondary);
}

.s438-nav-active .s438-nav-icon,
.s438-nav-active .s438-nav-text {
    color: var(--s438-secondary);
}

/* Promo Link Styles */
.s438-promo-link {
    color: var(--s438-secondary);
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
    transition: all 0.3s ease;
}

.s438-promo-link:hover {
    color: #fff;
    text-shadow: 0 0 10px var(--s438-secondary);
}

/* List Styles */
.s438-list {
    list-style: none;
    padding: 0;
}

.s438-list-item {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(199, 21, 133, 0.2);
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.s438-list-icon {
    color: var(--s438-secondary);
    font-size: 1.6rem;
    flex-shrink: 0;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .s438-menu-toggle {
        display: block;
    }

    .s438-header-actions .s438-btn {
        padding: 0.6rem 1rem;
        font-size: 1.2rem;
    }

    .s438-main {
        padding-bottom: calc(var(--s438-bottom-nav-height) + 2rem);
    }

    .s438-game-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 0.8rem;
    }

    .s438-game-name {
        font-size: 1.1rem;
    }
}

@media (min-width: 769px) {
    .s438-bottom-nav {
        display: none;
    }

    .s438-container {
        max-width: 1200px;
    }

    .s438-game-grid {
        grid-template-columns: repeat(8, 1fr);
    }
}

/* Animation Classes */
.s438-fade-in {
    animation: fadeIn 0.5s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Utility Classes */
.s438-text-center {
    text-align: center;
}

.s438-mb-1 {
    margin-bottom: 1rem;
}

.s438-mb-2 {
    margin-bottom: 2rem;
}

.s438-mb-3 {
    margin-bottom: 3rem;
}

.s438-highlight {
    color: var(--s438-secondary);
    font-weight: 600;
}
