/**
 * King PH App - Layout Styles
 * Version: 1.0.0
 * All classes use prefix: uif5-
 * Color Palette: #EEE8AA | #141414 | #BDB76B | #FFFACD
 */

/* CSS Variables */
:root {
    --uif5-primary: #BDB76B;
    --uif5-secondary: #EEE8AA;
    --uif5-accent: #FFFACD;
    --uif5-bg: #141414;
    --uif5-bg-light: #1a1a1a;
    --uif5-text: #FFFACD;
    --uif5-text-light: #EEE8AA;
    --uif5-border: #2a2a2a;
    --uif5-gold: #BDB76B;
    --uif5-dark-gold: #8B8B4D;
    --uif5-gradient: linear-gradient(135deg, #BDB76B 0%, #EEE8AA 100%);
    --uif5-shadow: 0 4px 15px rgba(189, 183, 107, 0.3);
}

/* Reset & Base */
* {
    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;
    background-color: var(--uif5-bg);
    color: var(--uif5-text);
    line-height: 1.5rem;
    font-size: 1.4rem;
    min-height: 100vh;
}

/* Container */
.uif5-container {
    max-width: 430px;
    margin: 0 auto;
    padding: 0 1.2rem;
}

.uif5-wrapper {
    padding: 1rem 0;
}

/* Header */
.uif5-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: linear-gradient(180deg, #141414 0%, #1a1a1a 100%);
    border-bottom: 1px solid var(--uif5-border);
    padding: 0.8rem 0;
}

.uif5-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 430px;
    margin: 0 auto;
    padding: 0 1rem;
}

.uif5-logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
}

.uif5-logo img {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

.uif5-logo-text {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--uif5-gold);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.uif5-header-actions {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.uif5-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-decoration: none;
}

.uif5-btn-primary {
    background: var(--uif5-gradient);
    color: #141414;
}

.uif5-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--uif5-shadow);
}

.uif5-btn-secondary {
    background: transparent;
    color: var(--uif5-gold);
    border: 1px solid var(--uif5-gold);
}

.uif5-btn-secondary:hover {
    background: var(--uif5-gold);
    color: #141414;
}

.uif5-menu-toggle {
    background: none;
    border: none;
    color: var(--uif5-gold);
    font-size: 2rem;
    cursor: pointer;
    padding: 0.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Mobile Menu */
.uif5-mobile-menu {
    position: fixed;
    top: 0;
    right: -280px;
    width: 280px;
    height: 100vh;
    background: #0a0a0a;
    z-index: 9999;
    transition: right 0.3s ease;
    padding: 6rem 1.5rem 2rem;
    overflow-y: auto;
}

.uif5-menu-active {
    right: 0;
}

.uif5-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;
}

.uif5-overlay-active {
    opacity: 1;
    visibility: visible;
}

.uif5-nav-list {
    list-style: none;
}

.uif5-nav-item {
    margin-bottom: 0.5rem;
}

.uif5-nav-link {
    display: block;
    padding: 1rem 0.8rem;
    color: var(--uif5-text-light);
    text-decoration: none;
    font-size: 1.3rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.uif5-nav-link:hover {
    background: rgba(189, 183, 107, 0.1);
    color: var(--uif5-gold);
}

/* Main Content */
main {
    padding-top: 5.5rem;
}

@media (max-width: 768px) {
    main {
        padding-bottom: 80px;
    }
}

/* Carousel */
.uif5-carousel {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
    border-radius: 8px;
    margin: 1rem 0;
}

.uif5-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    cursor: pointer;
}

.uif5-slide-active {
    opacity: 1;
}

.uif5-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Section Title */
.uif5-section-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--uif5-gold);
    margin: 1.5rem 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--uif5-border);
}

.uif5-section-subtitle {
    font-size: 1.4rem;
    color: var(--uif5-text-light);
    margin-bottom: 1rem;
}

/* Game Grid */
.uif5-game-section {
    margin: 1.5rem 0;
}

.uif5-game-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.8rem;
}

.uif5-game-card {
    background: var(--uif5-bg-light);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid var(--uif5-border);
}

.uif5-game-card:hover {
    transform: translateY(-3px);
    border-color: var(--uif5-gold);
    box-shadow: var(--uif5-shadow);
}

.uif5-game-img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
}

.uif5-game-name {
    display: block;
    padding: 0.5rem;
    font-size: 1rem;
    color: var(--uif5-text);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background: rgba(0, 0, 0, 0.3);
}

/* Content Sections */
.uif5-content-section {
    background: var(--uif5-bg-light);
    border-radius: 10px;
    padding: 1.2rem;
    margin: 1rem 0;
    border: 1px solid var(--uif5-border);
}

.uif5-content-title {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--uif5-gold);
    margin-bottom: 0.8rem;
}

.uif5-content-text {
    font-size: 1.3rem;
    color: var(--uif5-text-light);
    line-height: 1.8;
}

.uif5-content-text p {
    margin-bottom: 0.8rem;
}

.uif5-content-text a {
    color: var(--uif5-gold);
    text-decoration: underline;
}

.uif5-content-text ul, .uif5-content-text ol {
    margin-left: 1.5rem;
    margin-bottom: 0.8rem;
}

.uif5-content-text li {
    margin-bottom: 0.4rem;
}

/* Promo Link Styles */
.uif5-promo-link {
    color: var(--uif5-gold);
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
}

.uif5-promo-btn {
    display: inline-block;
    background: var(--uif5-gradient);
    color: #141414;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    margin: 0.5rem 0;
}

.uif5-promo-btn:hover {
    transform: scale(1.05);
    box-shadow: var(--uif5-shadow);
}

/* Footer */
.uif5-footer {
    background: #0a0a0a;
    padding: 1.5rem 0;
    margin-top: 2rem;
    border-top: 1px solid var(--uif5-border);
}

.uif5-footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.8rem;
    margin-bottom: 1rem;
}

.uif5-footer-link {
    color: var(--uif5-text-light);
    text-decoration: none;
    font-size: 1.2rem;
    padding: 0.3rem 0.6rem;
}

.uif5-footer-link:hover {
    color: var(--uif5-gold);
}

.uif5-partners {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin: 1rem 0;
}

.uif5-partner-img {
    height: 24px;
    width: auto;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.uif5-partner-img:hover {
    opacity: 1;
}

.uif5-copyright {
    text-align: center;
    font-size: 1.1rem;
    color: #666;
    margin-top: 1rem;
}

/* Bottom Navigation */
.uif5-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%);
    border-top: 1px solid var(--uif5-border);
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1000;
}

@media (min-width: 769px) {
    .uif5-bottom-nav {
        display: none;
    }
}

.uif5-nav-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    min-height: 60px;
    color: var(--uif5-text-light);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    background: none;
    border: none;
}

.uif5-nav-btn:hover, .uif5-nav-btn.active {
    color: var(--uif5-gold);
}

.uif5-nav-btn i, .uif5-nav-btn .material-icons {
    font-size: 22px;
    margin-bottom: 2px;
}

.uif5-nav-btn span {
    font-size: 10px;
    font-weight: 500;
}

/* Utility Classes */
.uif5-text-center { text-align: center; }
.uif5-text-gold { color: var(--uif5-gold); }
.uif5-mt-1 { margin-top: 0.5rem; }
.uif5-mt-2 { margin-top: 1rem; }
.uif5-mb-1 { margin-bottom: 0.5rem; }
.uif5-mb-2 { margin-bottom: 1rem; }
.uif5-py-1 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.uif5-py-2 { padding-top: 1rem; padding-bottom: 1rem; }

/* H1 Title */
.uif5-h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--uif5-gold);
    text-align: center;
    margin: 1.5rem 0;
    line-height: 1.3;
}

/* FAQ Section */
.uif5-faq-item {
    background: var(--uif5-bg-light);
    border-radius: 8px;
    margin-bottom: 0.8rem;
    border: 1px solid var(--uif5-border);
    overflow: hidden;
}

.uif5-faq-question {
    padding: 1rem;
    font-weight: 600;
    color: var(--uif5-gold);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.uif5-faq-answer {
    padding: 0 1rem 1rem;
    color: var(--uif5-text-light);
    font-size: 1.3rem;
    line-height: 1.6;
}

/* Steps List */
.uif5-steps {
    counter-reset: step;
}

.uif5-step {
    position: relative;
    padding-left: 3rem;
    margin-bottom: 1rem;
}

.uif5-step::before {
    counter-increment: step;
    content: counter(step);
    position: absolute;
    left: 0;
    top: 0;
    width: 2rem;
    height: 2rem;
    background: var(--uif5-gradient);
    color: #141414;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
}

/* Responsive */
@media (max-width: 360px) {
    .uif5-game-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}
