/**
 * jillitt Theme Stylesheet
 * All classes use pgdb- prefix for namespace isolation
 * Color Palette: #E5E5E5, #808080, #BDC3C7, #1A1A1A
 */

/* CSS Variables */
:root {
    --pgdb-primary: #808080;
    --pgdb-secondary: #BDC3C7;
    --pgdb-accent: #E5E5E5;
    --pgdb-dark: #1A1A1A;
    --pgdb-light: #E5E5E5;
    --pgdb-text: #1A1A1A;
    --pgdb-text-light: #808080;
    --pgdb-border: #BDC3C7;
    --pgdb-success: #6B8E23;
    --pgdb-warning: #DAA520;
    --pgdb-danger: #B22222;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 62.5%;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 1.6rem;
    line-height: 1.5;
    color: var(--pgdb-text);
    background-color: var(--pgdb-light);
    min-width: 320px;
    max-width: 430px;
    margin: 0 auto;
    overflow-x: hidden;
}

/* Container */
.pgdb-container {
    width: 100%;
    max-width: 430px;
    margin: 0 auto;
    padding: 0 1rem;
}

.pgdb-wrapper {
    padding-bottom: 80px;
}

@media (min-width: 769px) {
    .pgdb-wrapper {
        padding-bottom: 0;
    }
}

/* Header Styles */
.pgdb-header {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 430px;
    background-color: var(--pgdb-dark);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.pgdb-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.8rem 1rem;
    min-height: 60px;
}

.pgdb-logo {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    text-decoration: none;
}

.pgdb-logo-icon {
    width: 32px;
    height: 32px;
    border-radius: 4px;
}

.pgdb-logo-text {
    color: var(--pgdb-secondary);
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.pgdb-header-buttons {
    display: flex;
    gap: 0.8rem;
}

.pgdb-btn {
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 6px;
    font-size: 1.4rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.pgdb-btn-primary {
    background: linear-gradient(135deg, var(--pgdb-primary) 0%, #6B6B6B 100%);
    color: var(--pgdb-light);
}

.pgdb-btn-secondary {
    background: transparent;
    border: 2px solid var(--pgdb-secondary);
    color: var(--pgdb-secondary);
}

.pgdb-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Mobile Menu Toggle */
.pgdb-menu-toggle {
    display: flex;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    padding: 0.5rem;
    background: none;
    border: none;
}

.pgdb-menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--pgdb-secondary);
    transition: all 0.3s ease;
}

@media (min-width: 769px) {
    .pgdb-menu-toggle {
        display: none;
    }
}

/* Mobile Menu */
.pgdb-mobile-menu {
    position: fixed;
    top: 60px;
    left: 0;
    width: 100%;
    max-width: 430px;
    background-color: var(--pgdb-dark);
    padding: 1rem 0;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    margin: 0 auto;
    left: 50%;
    transform: translateX(-50%) translateY(-100%);
}

.pgdb-mobile-menu.pgdb-active {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    visibility: visible;
}

.pgdb-mobile-menu-link {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--pgdb-secondary);
    text-decoration: none;
    font-size: 1.5rem;
    border-left: 3px solid transparent;
    transition: all 0.3s ease;
}

.pgdb-mobile-menu-link:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-left-color: var(--pgdb-primary);
    padding-left: 2rem;
}

/* Main Content */
.pgdb-main {
    margin-top: 60px;
    padding: 1.5rem 0;
}

/* Carousel */
.pgdb-carousel {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 2rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.pgdb-carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.pgdb-carousel-slide.pgdb-active {
    opacity: 1;
}

.pgdb-carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pgdb-carousel-dots {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
}

.pgdb-carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.pgdb-carousel-dot.pgdb-active {
    background-color: var(--pgdb-secondary);
    width: 24px;
    border-radius: 4px;
}

/* Section Styles */
.pgdb-section {
    margin-bottom: 2.5rem;
    padding: 1.5rem;
    background-color: #FFFFFF;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.pgdb-section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--pgdb-dark);
    margin-bottom: 1.2rem;
    position: relative;
    padding-bottom: 0.8rem;
}

.pgdb-section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--pgdb-primary), var(--pgdb-secondary));
}

/* Game Grid */
.pgdb-game-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.8rem;
    margin-bottom: 2rem;
}

.pgdb-game-item {
    background-color: #FAFAFA;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.pgdb-game-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.pgdb-game-icon {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
}

.pgdb-game-name {
    padding: 0.6rem 0.4rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--pgdb-dark);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Category Tabs */
.pgdb-category-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--pgdb-dark);
    margin: 2rem 0 1.2rem 0;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.pgdb-category-icon {
    width: 24px;
    height: 24px;
    color: var(--pgdb-primary);
}

/* Card Styles */
.pgdb-card {
    background-color: #FAFAFA;
    border-radius: 10px;
    padding: 1.2rem;
    margin-bottom: 1rem;
    border-left: 4px solid var(--pgdb-primary);
    transition: all 0.3s ease;
}

.pgdb-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateX(4px);
}

.pgdb-card-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--pgdb-dark);
    margin-bottom: 0.8rem;
}

.pgdb-card-content {
    font-size: 1.4rem;
    color: var(--pgdb-text-light);
    line-height: 1.6;
}

/* Link Styles */
.pgdb-link {
    color: var(--pgdb-primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border-bottom: 2px solid transparent;
}

.pgdb-link:hover {
    color: var(--pgdb-dark);
    border-bottom-color: var(--pgdb-primary);
}

/* List Styles */
.pgdb-list {
    list-style: none;
    padding: 0;
}

.pgdb-list-item {
    padding: 0.8rem 0;
    border-bottom: 1px solid #E8E8E8;
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
}

.pgdb-list-item:last-child {
    border-bottom: none;
}

.pgdb-list-icon {
    color: var(--pgdb-primary);
    flex-shrink: 0;
    margin-top: 0.2rem;
}

/* Bottom Navigation */
.pgdb-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 430px;
    background: linear-gradient(180deg, var(--pgdb-dark) 0%, #2A2A2A 100%);
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0.5rem 0;
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
}

@media (min-width: 769px) {
    .pgdb-bottom-nav {
        display: none;
    }
}

.pgdb-bottom-nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--pgdb-secondary);
    min-width: 60px;
    min-height: 60px;
    padding: 0.4rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
}

.pgdb-bottom-nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

.pgdb-bottom-nav-link.pgdb-active {
    color: var(--pgdb-accent);
}

.pgdb-bottom-nav-icon {
    font-size: 24px;
    margin-bottom: 0.3rem;
}

.pgdb-bottom-nav-text {
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
}

/* Footer */
.pgdb-footer {
    background-color: var(--pgdb-dark);
    color: var(--pgdb-secondary);
    padding: 2rem 1rem 6rem 1rem;
    margin-top: 2rem;
}

.pgdb-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
    justify-content: center;
}

.pgdb-footer-link {
    color: var(--pgdb-secondary);
    text-decoration: none;
    font-size: 1.3rem;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.pgdb-footer-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--pgdb-accent);
}

.pgdb-partners {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.pgdb-partner-icon {
    width: 40px;
    height: 40px;
    object-fit: contain;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.pgdb-partner-icon:hover {
    opacity: 1;
    transform: scale(1.1);
}

.pgdb-copyright {
    text-align: center;
    font-size: 1.2rem;
    color: var(--pgdb-text-light);
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* H1 and Typography */
h1 {
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--pgdb-dark);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--pgdb-dark);
    margin-bottom: 1.2rem;
}

h3 {
    font-size: 1.7rem;
    font-weight: 600;
    color: var(--pgdb-dark);
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1rem;
    font-size: 1.5rem;
    color: var(--pgdb-text);
    line-height: 1.6;
}

/* Animation Classes */
.pgdb-fade-in {
    opacity: 0;
    transition: opacity 0.6s ease;
}

.pgdb-fade-in.pgdb-visible {
    opacity: 1;
}

.pgdb-slide-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.pgdb-slide-up.pgdb-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Utilities */
@media (max-width: 768px) {
    .pgdb-main {
        padding-bottom: 80px;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--pgdb-light);
}

::-webkit-scrollbar-thumb {
    background: var(--pgdb-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--pgdb-dark);
}
