/* kkkk ph CSS Design System - Mobile-first gaming website */
/* All classes use gf74- prefix for namespace isolation */

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 62.5%; /* 1rem = 10px */
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    font-size: 1.6rem;
    line-height: 1.5;
    color: #AFEEEE;
    background-color: #2E4057;
    overflow-x: hidden;
}

/* CSS Variables */
:root {
    --gf74-primary: #5F9EA0;
    --gf74-secondary: #4682B4;
    --gf74-accent: #3CB371;
    --gf74-bg-dark: #2E4057;
    --gf74-bg-light: #AFEEEE;
    --gf74-text: #AFEEEE;
    --gf74-text-dark: #2E4057;
    --gf74-border: #ADB5BD;
    --gf74-gold: #FFD700;
    --gf74-danger: #FF6B6B;
    --gf74-shadow: rgba(0, 0, 0, 0.3);
}

/* Utility classes */
.gf74-container {
    max-width: 430px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.gf74-wrapper {
    min-height: 100vh;
    padding-bottom: 8rem;
}

.gf74-text-center { text-align: center; }
.gf74-text-left { text-align: left; }
.gf74-text-right { text-align: right; }
.gf74-mb-1 { margin-bottom: 1rem; }
.gf74-mb-2 { margin-bottom: 2rem; }
.gf74-mb-3 { margin-bottom: 3rem; }
.gf74-mt-1 { margin-top: 1rem; }
.gf74-mt-2 { margin-top: 2rem; }
.gf74-mt-3 { margin-top: 3rem; }

/* Header */
.gf74-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: linear-gradient(135deg, var(--gf74-bg-dark) 0%, var(--gf74-secondary) 100%);
    box-shadow: 0 2px 10px var(--gf74-shadow);
    backdrop-filter: blur(10px);
}

.gf74-header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    max-width: 430px;
    margin: 0 auto;
}

.gf74-logo {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    text-decoration: none;
    color: var(--gf74-text);
    font-weight: 700;
    font-size: 2rem;
}

.gf74-logo img {
    width: 3.2rem;
    height: 3.2rem;
    border-radius: 50%;
}

.gf74-header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.gf74-btn {
    padding: 0.8rem 1.6rem;
    border: none;
    border-radius: 0.8rem;
    font-size: 1.4rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    min-width: 8rem;
}

.gf74-btn-primary {
    background: var(--gf74-accent);
    color: white;
    box-shadow: 0 4px 12px rgba(60, 179, 113, 0.4);
}

.gf74-btn-primary:hover {
    background: #2d9d5d;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(60, 179, 113, 0.5);
}

.gf74-btn-secondary {
    background: transparent;
    color: var(--gf74-text);
    border: 2px solid var(--gf74-primary);
}

.gf74-btn-secondary:hover {
    background: var(--gf74-primary);
    color: white;
}

.gf74-menu-toggle {
    background: none;
    border: none;
    color: var(--gf74-text);
    font-size: 2.4rem;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Mobile Menu */
.gf74-mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 320px;
    height: 100vh;
    background: var(--gf74-bg-dark);
    z-index: 9999;
    transition: right 0.3s ease;
    box-shadow: -5px 0 15px var(--gf74-shadow);
}

.gf74-mobile-menu.active {
    right: 0;
}

.gf74-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.gf74-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.gf74-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid var(--gf74-border);
}

.gf74-menu-close {
    background: none;
    border: none;
    color: var(--gf74-text);
    font-size: 2.4rem;
    cursor: pointer;
}

.gf74-menu-nav {
    padding: 1.5rem;
}

.gf74-menu-item {
    display: block;
    padding: 1.2rem 0;
    color: var(--gf74-text);
    text-decoration: none;
    font-size: 1.6rem;
    border-bottom: 1px solid rgba(173, 181, 189, 0.1);
    transition: color 0.3s ease;
}

.gf74-menu-item:hover {
    color: var(--gf74-primary);
}

/* Main Content */
.gf74-main {
    padding-top: 7rem;
    min-height: 100vh;
}

/* Carousel */
.gf74-carousel {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    margin-bottom: 2rem;
}

.gf74-carousel-inner {
    display: flex;
    transition: transform 0.5s ease;
}

.gf74-carousel-item {
    min-width: 100%;
    position: relative;
}

.gf74-carousel-item img {
    width: 100%;
    height: auto;
    display: block;
}

.gf74-carousel-indicators {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
}

.gf74-carousel-indicator {
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.gf74-carousel-indicator.active {
    background: var(--gf74-gold);
    transform: scale(1.2);
}

/* Cards */
.gf74-card {
    background: rgba(95, 158, 160, 0.1);
    border: 1px solid rgba(95, 158, 160, 0.3);
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 2rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.gf74-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px var(--gf74-shadow);
    border-color: var(--gf74-primary);
}

.gf74-card-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gf74-text);
    margin-bottom: 1rem;
}

.gf74-card-text {
    color: var(--gf74-text);
    line-height: 1.6;
}

/* Game Grid */
.gf74-game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.gf74-game-item {
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.gf74-game-item:hover {
    transform: scale(1.05);
}

.gf74-game-icon {
    width: 100%;
    height: 8rem;
    object-fit: cover;
    border-radius: 1rem;
    margin-bottom: 0.5rem;
    box-shadow: 0 4px 8px var(--gf74-shadow);
}

.gf74-game-name {
    font-size: 1.2rem;
    color: var(--gf74-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Sections */
.gf74-section {
    margin-bottom: 4rem;
}

.gf74-section-title {
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--gf74-text);
    margin-bottom: 2rem;
    text-align: center;
}

/* Bottom Navigation */
.gf74-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--gf74-bg-dark) 0%, var(--gf74-secondary) 100%);
    box-shadow: 0 -2px 10px var(--gf74-shadow);
    z-index: 1000;
    display: none;
}

.gf74-bottom-nav-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    height: 6rem;
    max-width: 430px;
    margin: 0 auto;
}

.gf74-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 6rem;
    height: 100%;
    color: var(--gf74-text);
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.gf74-bottom-nav-item:hover,
.gf74-bottom-nav-item.active {
    color: var(--gf74-gold);
    transform: scale(1.1);
}

.gf74-bottom-nav-icon {
    font-size: 2.4rem;
    margin-bottom: 0.2rem;
}

.gf74-bottom-nav-text {
    font-size: 1rem;
    font-weight: 500;
}

/* Footer */
.gf74-footer {
    background: var(--gf74-bg-dark);
    border-top: 1px solid rgba(95, 158, 160, 0.3);
    padding: 3rem 0 8rem;
    margin-top: 4rem;
}

.gf74-footer-content {
    text-align: center;
}

.gf74-footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.gf74-footer-link {
    color: var(--gf74-text);
    text-decoration: none;
    font-size: 1.4rem;
    transition: color 0.3s ease;
}

.gf74-footer-link:hover {
    color: var(--gf74-primary);
}

.gf74-partners {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    margin: 2rem 0;
}

.gf74-partner {
    width: 4rem;
    height: 4rem;
    object-fit: contain;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.gf74-partner:hover {
    opacity: 1;
}

.gf74-copyright {
    color: var(--gf74-border);
    font-size: 1.2rem;
    margin-top: 2rem;
}

/* iOS Banner */
.gf74-ios-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--gf74-bg-dark);
    padding: 1rem;
    display: none;
    align-items: center;
    justify-content: space-between;
    z-index: 9999;
    box-shadow: 0 2px 10px var(--gf74-shadow);
}

.gf74-ios-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.gf74-ios-icon {
    width: 4rem;
    height: 4rem;
    border-radius: 0.8rem;
}

.gf74-ios-text {
    flex: 1;
}

.gf74-ios-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--gf74-text);
}

.gf74-ios-subtitle {
    font-size: 1.2rem;
    color: var(--gf74-border);
}

.gf74-ios-close {
    background: none;
    border: none;
    color: var(--gf74-text);
    font-size: 2rem;
    cursor: pointer;
    padding: 0.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .gf74-bottom-nav {
        display: block;
    }

    .gf74-main {
        padding-bottom: 8rem;
    }

    .gf74-game-grid {
        grid-template-columns: repeat(auto-fill, minmax(7rem, 1fr));
        gap: 1rem;
    }

    .gf74-game-icon {
        height: 7rem;
    }
}

@media (min-width: 769px) {
    .gf74-header-content {
        padding: 1rem 2rem;
    }

    .gf74-container {
        padding: 0 2rem;
    }

    .gf74-footer {
        padding-bottom: 3rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(2rem);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.gf74-fade-in {
    animation: fadeIn 0.6s ease forwards;
}

/* Utility classes for spacing and alignment */
.gf74-flex { display: flex; }
.gf74-flex-col { flex-direction: column; }
.gf74-items-center { align-items: center; }
.gf74-justify-center { justify-content: center; }
.gf74-justify-between { justify-content: space-between; }
.gf74-gap-1 { gap: 1rem; }
.gf74-gap-2 { gap: 2rem; }
.gf74-hidden { display: none; }
.gf74-block { display: block; }

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 0.6rem;
}

::-webkit-scrollbar-track {
    background: var(--gf74-bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--gf74-primary);
    border-radius: 0.3rem;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gf74-secondary);
}