/* css/style.css - Premium theme design for JAIHO YONO GAMES */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
    --primary-green: #016A38;
    --primary-green-light: #028A4B;
    --primary-green-dark: #004D26;
    --accent-red: #D32F2F;
    --accent-gold: #FFC107;
    --accent-gold-dark: #FF9800;
    --accent-orange: #FF5722;
    --bg-light: #F4F6F5;
    --text-dark: #1E293B;
    --text-muted: #64748B;
    --white: #FFFFFF;
    --border-color: #E2E8F0;
    --card-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    --hover-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    --font-outfit: 'Outfit', sans-serif;
    --font-inter: 'Inter', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-light);
    color: var(--text-dark);
    font-family: var(--font-inter);
    line-height: 1.6;
}

/* 1. Header Ticker (Marquee) */
.top-ticker {
    background-color: var(--accent-red);
    color: var(--white);
    font-family: var(--font-outfit);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 8px 16px;
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.ticker-wrap {
    display: inline-block;
    padding-left: 100%;
    animation: marquee 25s linear infinite;
}

@keyframes marquee {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-100%, 0, 0); }
}

.ticker-wrap span {
    display: inline-block;
    padding-right: 2rem;
}

/* 2. Main Header */
.main-header {
    background-color: var(--primary-green-dark);
    color: var(--white);
    padding: 12px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--white);
}

.logo-img {
    width: 45px;
    height: 45px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--accent-gold), var(--accent-orange));
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--primary-green-dark);
    box-shadow: 0 0 10px rgba(255, 193, 7, 0.5);
}

.logo-text {
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 1.5rem;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.logo-text span {
    color: var(--accent-gold);
}

.telegram-btn {
    background: #0088cc;
    color: var(--white);
    border: none;
    border-radius: 30px;
    padding: 10px 20px;
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(0, 136, 204, 0.3);
    transition: all 0.3s ease;
    font-family: var(--font-outfit);
    animation: pulse 2s infinite;
}

.telegram-btn:hover {
    background: #0077b5;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 136, 204, 0.5);
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.04); }
    100% { transform: scale(1); }
}

/* 3. Category Filters Container */
.categories-container {
    background-color: var(--white);
    padding: 15px 5%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    border-bottom: 1px solid var(--border-color);
}

.categories-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scrollbar-width: none; /* Firefox */
    padding-bottom: 2px;
}

.categories-scroll::-webkit-scrollbar {
    display: none; /* Safari/Chrome */
}

.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--text-dark);
    min-width: 75px;
    text-align: center;
    transition: all 0.2s ease;
}

.category-icon {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background-color: var(--bg-light);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
    font-size: 1.4rem;
    transition: all 0.2s ease;
}

.category-card span {
    font-size: 0.8rem;
    font-weight: 600;
    font-family: var(--font-outfit);
    text-transform: uppercase;
}

.category-card.active .category-icon {
    border-color: var(--primary-green);
    background-color: var(--primary-green);
    color: var(--white);
    box-shadow: 0 4px 10px rgba(1, 106, 56, 0.2);
}

.category-card.active span {
    color: var(--primary-green);
}

.category-card:hover .category-icon {
    transform: scale(1.08);
}

/* 4. Main Section & List Layout */
.main-wrapper {
    max-width: 900px;
    margin: 30px auto;
    padding: 0 15px;
}

/* Search bar option */
.search-container {
    margin-bottom: 20px;
}

.search-input {
    width: 100%;
    padding: 14px 20px;
    border-radius: 30px;
    border: 1px solid var(--border-color);
    font-size: 1rem;
    font-family: var(--font-inter);
    outline: none;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
}

.search-input:focus {
    border-color: var(--primary-green);
    box-shadow: 0 4px 12px rgba(1, 106, 56, 0.1);
}

.section-title {
    font-family: var(--font-outfit);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-green-dark);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-left: 5px solid var(--primary-green);
    padding-left: 10px;
}

.games-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* List Row Card */
.game-row {
    background-color: var(--white);
    border-radius: 12px;
    padding: 12px 20px;
    border: 1px solid var(--border-color);
    display: grid;
    grid-template-columns: auto auto 1fr auto;
    align-items: center;
    gap: 16px;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.game-row:hover {
    transform: translateY(-2px);
    box-shadow: var(--hover-shadow);
    border-color: var(--primary-green-light);
}

.game-number {
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--text-muted);
    width: 25px;
    text-align: center;
}

/* Image styling - fallbacks dynamically managed in PHP */
.game-icon-container {
    position: relative;
    width: 60px;
    height: 60px;
}

.game-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* CSS fallback icon styling */
.game-icon-fallback {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-light));
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-outfit);
    font-weight: 700;
    font-size: 1.4rem;
    text-transform: uppercase;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.game-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.game-title {
    font-family: var(--font-outfit);
    font-weight: 700;
    font-size: 1.1rem;
    color: #0F172A;
    margin-bottom: 2px;
}

.game-subtitle {
    font-size: 0.85rem;
    color: var(--accent-red);
    font-weight: 600;
}

.category-tag {
    display: inline-block;
    align-self: flex-start;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: lowercase;
    background-color: #F1F5F9;
    color: #64748B;
    padding: 2px 8px;
    border-radius: 4px;
    margin-top: 3px;
    font-family: var(--font-inter);
}

.download-link-wrap {
    text-decoration: none;
}

.download-btn {
    background-color: var(--primary-green);
    color: var(--white);
    border: none;
    border-radius: 8px;
    padding: 10px 18px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    font-family: var(--font-outfit);
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
    border: 1px solid var(--primary-green);
}

.download-btn:hover {
    background-color: var(--accent-gold);
    color: var(--primary-green-dark);
    border-color: var(--accent-gold);
    transform: scale(1.05);
}

/* 5. Load More */
.load-more-container {
    text-align: center;
    margin: 30px 0;
}

.load-more-btn {
    background-color: var(--accent-gold);
    color: #1E293B;
    border: 1px solid #FFB300;
    border-radius: 8px;
    padding: 10px 30px;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: var(--font-outfit);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(255, 193, 7, 0.3);
}

.load-more-btn:hover {
    background-color: #FFB300;
    color: #000000;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 193, 7, 0.5);
}

/* 6. SEO Description Area */
.seo-section {
    background-color: var(--white);
    border-radius: 16px;
    padding: 30px 40px;
    margin-top: 40px;
    border: 1px solid var(--border-color);
    box-shadow: var(--card-shadow);
}

.seo-content {
    color: #334155;
    font-size: 0.95rem;
}

.seo-content h2 {
    font-family: var(--font-outfit);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-green-dark);
    margin-bottom: 16px;
    margin-top: 10px;
}

.seo-content h3 {
    font-family: var(--font-outfit);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-green);
    margin-top: 24px;
    margin-bottom: 12px;
}

.seo-content p {
    margin-bottom: 16px;
    line-height: 1.7;
}

.seo-content ul, .seo-content ol {
    margin-bottom: 20px;
    padding-left: 20px;
}

.seo-content li {
    margin-bottom: 8px;
}

.seo-content .faq-item {
    background-color: var(--bg-light);
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 12px;
    border-left: 4px solid var(--primary-green-light);
}

.seo-content .faq-item h4 {
    font-family: var(--font-outfit);
    color: var(--primary-green-dark);
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.seo-content .faq-item p {
    margin-bottom: 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* 7. Sticky Footer Banner & Footer */
.footer {
    background-color: var(--primary-green-dark);
    color: #94A3B8;
    padding: 40px 5% 80px 5%; /* bottom padding accounts for mobile sticky download button if any */
    text-align: center;
    border-top: 5px solid var(--accent-gold);
    margin-top: 60px;
}

.footer-logo {
    color: var(--white);
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.footer-logo span {
    color: var(--accent-gold);
}

.footer-desc {
    max-width: 600px;
    margin: 0 auto 25px auto;
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.footer-link {
    color: #CBD5E1;
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s ease;
    font-weight: 500;
}

.footer-link:hover {
    color: var(--accent-gold);
}

.footer-copy {
    font-size: 0.8rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
}

/* Floating Telegram on Mobile */
.mobile-telegram-floating {
    display: none;
}

@media (max-width: 768px) {
    .game-row {
        grid-template-columns: 24px 50px 1fr auto;
        gap: 10px;
        padding: 10px 12px;
        border-radius: 10px;
    }
    
    .game-number {
        font-size: 0.95rem;
        width: auto;
        text-align: center;
        color: var(--primary-green);
        font-weight: 700;
    }
    
    .game-icon-container, .game-icon, .game-icon-fallback {
        width: 50px;
        height: 50px;
        border-radius: 10px;
    }
    
    .game-info {
        padding-left: 0;
        min-width: 0;
    }
    
    .game-title {
        font-size: 0.98rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .game-subtitle {
        font-size: 0.78rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .category-tag {
        font-size: 0.65rem;
        padding: 1px 6px;
    }
    
    .download-link-wrap {
        width: auto;
        margin-top: 0;
    }
    
    .download-btn {
        padding: 8px 14px;
        font-size: 0.82rem;
        border-radius: 8px;
        white-space: nowrap;
    }
    
    .main-header {
        padding: 10px 15px;
    }
    
    .logo-text {
        font-size: 1.2rem;
    }
    
    .telegram-btn {
        padding: 7px 12px;
        font-size: 0.8rem;
        gap: 5px;
    }

    .telegram-btn svg {
        width: 14px;
        height: 14px;
    }
    
    .mobile-telegram-floating {
        display: flex;
        position: fixed;
        bottom: 20px;
        right: 20px;
        background: #0088cc;
        color: var(--white);
        border-radius: 50%;
        width: 50px;
        height: 50px;
        align-items: center;
        justify-content: center;
        font-size: 1.4rem;
        box-shadow: 0 4px 15px rgba(0, 136, 204, 0.4);
        z-index: 999;
        text-decoration: none;
        animation: pulse 2s infinite;
    }
    
    .seo-section {
        padding: 20px;
    }
}

/* 8. Top Body SEO Block */
.header-seo-block {
    background-color: var(--white);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
    border: 1px solid var(--border-color);
    box-shadow: var(--card-shadow);
    border-left: 5px solid var(--primary-green-light);
}

.header-seo-block p {
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.7;
    margin: 0;
    font-family: var(--font-inter);
}

/* 9. Game Post Page - Hero Card & Special UI */
.post-hero-card {
    background: linear-gradient(180deg, #002B13 0%, #004D26 100%);
    border: 2px solid #FFC107;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4), inset 0 0 20px rgba(255, 193, 7, 0.15);
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.post-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 193, 7, 0.25);
    padding-bottom: 16px;
    margin-bottom: 20px;
}

.post-title-group {
    display: flex;
    align-items: center;
    gap: 15px;
}

.post-game-logo {
    background: linear-gradient(135deg, #016A38, #004D26);
    border: 2px solid #FFC107;
    border-radius: 12px;
    padding: 8px 12px;
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 0.95rem;
    color: #FFC107;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    line-height: 1.2;
}

.post-game-logo span {
    color: #FFFFFF;
    display: block;
    font-size: 0.75rem;
}

.post-main-title {
    font-family: var(--font-outfit);
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--white);
    line-height: 1.2;
    margin: 0;
}

.post-main-subtitle {
    font-size: 0.9rem;
    color: #FFC107;
    font-weight: 600;
    margin: 0;
}

.secured-badge {
    border: 2px solid #FFC107;
    border-radius: 10px;
    padding: 6px 14px;
    background: rgba(0, 0, 0, 0.4);
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.secured-text {
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 1.1rem;
    color: #FFC107;
    line-height: 1;
}

.secured-sub {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--white);
    letter-spacing: 0.5px;
}

.post-hero-visual-wrapper {
    position: relative;
    width: 100%;
    margin-bottom: 24px;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,0.5);
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.post-hero-banner-img {
    width: 100%;
    height: auto;
    max-height: 420px;
    object-fit: cover;
    display: block;
}

.post-social-sidebar {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 10;
}

.social-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.2rem;
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(0,0,0,0.4);
    transition: transform 0.2s ease;
}

.social-icon:hover {
    transform: scale(1.15);
}

.social-icon.whatsapp { background-color: #25D366; }
.social-icon.telegram { background-color: #0088cc; }
.social-icon.facebook { background-color: #1877F2; }
.social-icon.support  { background-color: #FF9800; }

.post-cta-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 20px 0;
}

.bonus-ribbon {
    background: linear-gradient(180deg, #D32F2F 0%, #8E0A0A 100%);
    color: #FFD700;
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 1.05rem;
    padding: 5px 28px;
    border-radius: 30px;
    border: 1.5px solid #FFD700;
    margin-bottom: -14px;
    z-index: 5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    letter-spacing: 0.5px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.6);
}

.download-app-btn {
    background: linear-gradient(180deg, #24C83E 0%, #007A28 100%);
    color: #FFFFFF;
    border: 2.5px solid #FFD700;
    border-radius: 50px;
    padding: 13px 42px;
    font-family: var(--font-outfit);
    font-weight: 800;
    font-size: 1.4rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 8px 25px rgba(0, 200, 70, 0.45), inset 0 2px 4px rgba(255, 255, 255, 0.7);
    transition: all 0.3s ease;
    animation: pulse-cta 2s infinite;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    letter-spacing: 0.5px;
}

.download-app-btn:hover {
    transform: scale(1.04);
    box-shadow: 0 12px 30px rgba(0, 230, 80, 0.6);
    background: linear-gradient(180deg, #28E047 0%, #009431 100%);
    border-color: #FFFFFF;
}

@keyframes pulse-cta {
    0% { transform: scale(1); }
    50% { transform: scale(1.03); }
    100% { transform: scale(1); }
}

.android-icon {
    font-size: 1.6rem;
}

.download-arrow {
    font-size: 1.5rem;
}

.post-sub-section {
    margin-top: 35px;
    border-top: 1px dashed rgba(255, 193, 7, 0.3);
    padding-top: 25px;
}

.section-gold-heading {
    font-family: var(--font-outfit);
    color: #FFC107;
    font-size: 1.35rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 6px;
}

.section-gold-heading .ornament {
    color: #FFC107;
    font-size: 1rem;
    vertical-align: middle;
}

.section-subtext {
    text-align: center;
    font-size: 0.9rem;
    color: #CBD5E1;
    margin-bottom: 20px;
}

.top-games-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    justify-content: center;
}

.top-game-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.game-thumb-box {
    width: 100%;
    max-width: 74px;
    aspect-ratio: 1 / 1;
    border-radius: 14px;
    border: 2px solid #FFC107;
    background: linear-gradient(135deg, #004D26, #002B13);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
    margin: 0 auto 4px auto;
    transition: transform 0.2s ease;
    overflow: hidden;
}

.top-game-card:hover .game-thumb-box {
    transform: translateY(-4px) scale(1.05);
    border-color: #FFFFFF;
}

.top-game-card span {
    font-size: 0.78rem;
    font-weight: 700;
    color: #FFFFFF;
    font-family: var(--font-outfit);
}

.why-choose-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 15px;
}

.why-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.why-icon-circle {
    width: 65px;
    height: 65px;
    border-radius: 50%;
    border: 2px solid #FFC107;
    background: linear-gradient(135deg, #016A38, #004D26);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    margin-bottom: 8px;
}

.why-card span {
    font-size: 0.85rem;
    font-weight: 700;
    color: #FFFFFF;
    font-family: var(--font-outfit);
}

@media (max-width: 768px) {
    .post-hero-card {
        padding: 16px;
        border-radius: 16px;
    }
    
    .post-main-title {
        font-size: 1.35rem;
    }
    
    .post-main-subtitle {
        font-size: 0.8rem;
    }
    
    .post-game-logo {
        padding: 6px 10px;
        font-size: 0.85rem;
    }
    
    .download-app-btn {
        padding: 12px 25px;
        font-size: 1.15rem;
        width: 100%;
        justify-content: center;
    }
    
    .why-choose-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .top-games-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }
    
    .game-thumb-box {
        width: 60px;
        height: 60px;
        font-size: 1.6rem;
    }
}

@media (max-width: 480px) {
    .post-header-row {
        gap: 8px;
    }
    
    .post-main-title {
        font-size: 1.15rem;
    }
    
    .secured-badge {
        padding: 4px 8px;
    }
    
    .secured-text {
        font-size: 0.95rem;
    }
    
    .secured-sub {
        font-size: 0.55rem;
    }
    
    .post-social-sidebar {
        right: 6px;
        gap: 8px;
    }
    
    .social-icon {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
    
    .top-games-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 8px;
    }
}


