/**
 * JLPH Login - Main Stylesheet
 * All classes use prefix: sd29-
 * Color scheme: #8470FF | #DEE2E6 | #E91E63 | #262626
 * Mobile-first responsive design
 */

/* ===== CSS Variables ===== */
:root {
    --sd29-primary: #8470FF;
    --sd29-secondary: #E91E63;
    --sd29-light: #DEE2E6;
    --sd29-dark: #262626;
    --sd29-bg-primary: #1a1a1a;
    --sd29-bg-secondary: #2d2d2d;
    --sd29-text-primary: #DEE2E6;
    --sd29-text-secondary: #b8b8b8;
    --sd29-accent-1: #FF6B9D;
    --sd29-accent-2: #9D7EFF;
    --sd29-gradient-1: linear-gradient(135deg, #8470FF 0%, #E91E63 100%);
    --sd29-gradient-2: linear-gradient(135deg, #E91E63 0%, #FF6B9D 100%);
    --sd29-shadow-sm: 0 2px 8px rgba(132, 112, 255, 0.15);
    --sd29-shadow-md: 0 4px 16px rgba(132, 112, 255, 0.25);
    --sd29-shadow-lg: 0 8px 32px rgba(132, 112, 255, 0.35);
    --sd29-border-radius: 12px;
    --sd29-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== Reset & Base ===== */
* {
    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, 'Helvetica Neue', Arial, sans-serif;
    font-size: 1.4rem;
    line-height: 1.5;
    color: var(--sd29-text-primary);
    background-color: var(--sd29-bg-primary);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--sd29-primary);
    text-decoration: none;
    transition: var(--sd29-transition);
}

a:hover {
    color: var(--sd29-secondary);
}

/* ===== Container ===== */
.sd29-container {
    max-width: 430px;
    margin: 0 auto;
    padding: 0 1.6rem;
}

.sd29-wrapper {
    width: 100%;
    min-height: 100vh;
    padding-bottom: 80px;
}

/* ===== Header ===== */
.sd29-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, var(--sd29-dark) 0%, rgba(38, 38, 38, 0.98) 100%);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.4);
    z-index: 1000;
    transition: var(--sd29-transition);
}

.sd29-header-scrolled {
    box-shadow: var(--sd29-shadow-lg);
}

.sd29-header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    padding: 0 1.6rem;
}

.sd29-logo-wrapper {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sd29-logo-img {
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.sd29-logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    background: var(--sd29-gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sd29-header-actions {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.sd29-btn {
    padding: 0.8rem 1.6rem;
    border: none;
    border-radius: 8px;
    font-size: 1.3rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--sd29-transition);
    white-space: nowrap;
    min-height: 44px;
}

.sd29-btn-primary {
    background: var(--sd29-gradient-1);
    color: white;
    box-shadow: var(--sd29-shadow-sm);
}

.sd29-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--sd29-shadow-md);
}

.sd29-btn-secondary {
    background: transparent;
    color: var(--sd29-primary);
    border: 2px solid var(--sd29-primary);
}

.sd29-btn-secondary:hover {
    background: var(--sd29-primary);
    color: white;
}

.sd29-hamburger {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 28px;
    height: 28px;
    cursor: pointer;
    padding: 4px;
}

.sd29-hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--sd29-primary);
    transition: var(--sd29-transition);
    border-radius: 2px;
}

.sd29-hamburger-active span:nth-child(1) {
    transform: rotate(45deg) translateY(8px);
}

.sd29-hamburger-active span:nth-child(2) {
    opacity: 0;
}

.sd29-hamburger-active span:nth-child(3) {
    transform: rotate(-45deg) translateY(-8px);
}

/* ===== Mobile Menu ===== */
.sd29-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    opacity: 0;
    visibility: hidden;
    transition: var(--sd29-transition);
    z-index: 9998;
}

.sd29-overlay-active {
    opacity: 1;
    visibility: visible;
}

.sd29-mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--sd29-dark);
    box-shadow: -4px 0 16px rgba(0, 0, 0, 0.5);
    transition: var(--sd29-transition);
    z-index: 9999;
    overflow-y: auto;
}

.sd29-menu-active {
    right: 0;
}

.sd29-menu-header {
    padding: 2rem 1.6rem;
    border-bottom: 1px solid rgba(132, 112, 255, 0.2);
}

.sd29-menu-title {
    font-size: 1.8rem;
    font-weight: 700;
    background: var(--sd29-gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sd29-menu-links {
    padding: 1.6rem 0;
}

.sd29-menu-link {
    display: block;
    padding: 1.2rem 2rem;
    color: var(--sd29-text-primary);
    font-size: 1.5rem;
    transition: var(--sd29-transition);
    border-left: 3px solid transparent;
}

.sd29-menu-link:hover,
.sd29-menu-link-active {
    background: rgba(132, 112, 255, 0.1);
    border-left-color: var(--sd29-primary);
    color: var(--sd29-primary);
}

/* ===== Main Content ===== */
.sd29-main {
    margin-top: 60px;
    padding: 2rem 0;
    min-height: calc(100vh - 60px - 80px);
}

/* ===== Carousel ===== */
.sd29-carousel {
    position: relative;
    width: 100%;
    max-width: 430px;
    margin: 0 auto 2rem;
    border-radius: var(--sd29-border-radius);
    overflow: hidden;
    box-shadow: var(--sd29-shadow-md);
}

.sd29-slide {
    width: 100%;
    cursor: pointer;
    display: none;
}

.sd29-slide img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.sd29-carousel-dots {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.8rem;
}

.sd29-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: var(--sd29-transition);
}

.sd29-dot-active {
    background: white;
    width: 24px;
    border-radius: 4px;
}

/* ===== Section ===== */
.sd29-section {
    margin: 3rem 0;
}

.sd29-section-header {
    margin-bottom: 2rem;
}

.sd29-section-title {
    font-size: 2.4rem;
    font-weight: 700;
    margin-bottom: 0.8rem;
    background: var(--sd29-gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sd29-section-subtitle {
    font-size: 1.4rem;
    color: var(--sd29-text-secondary);
}

/* ===== Game Grid ===== */
.sd29-game-category {
    margin-bottom: 3rem;
}

.sd29-category-title {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 1.6rem;
    padding: 1rem 1.6rem;
    background: var(--sd29-bg-secondary);
    border-left: 4px solid var(--sd29-primary);
    border-radius: 8px;
}

.sd29-game-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.2rem;
}

.sd29-game-card {
    background: var(--sd29-bg-secondary);
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: var(--sd29-transition);
    border: 2px solid transparent;
}

.sd29-game-card:hover {
    transform: translateY(-4px);
    border-color: var(--sd29-primary);
    box-shadow: var(--sd29-shadow-md);
}

.sd29-game-img {
    width: 100%;
    height: 80px;
    object-fit: cover;
}

.sd29-game-name {
    padding: 0.8rem;
    font-size: 1.1rem;
    text-align: center;
    color: var(--sd29-text-primary);
    font-weight: 500;
    line-height: 1.3;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== Content Card ===== */
.sd29-card {
    background: var(--sd29-bg-secondary);
    border-radius: var(--sd29-border-radius);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--sd29-shadow-sm);
    border: 1px solid rgba(132, 112, 255, 0.1);
}

.sd29-card-title {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 1.6rem;
    color: var(--sd29-primary);
}

.sd29-card-content {
    font-size: 1.4rem;
    line-height: 1.8;
    color: var(--sd29-text-primary);
}

.sd29-card-content p {
    margin-bottom: 1.2rem;
}

.sd29-card-content ul,
.sd29-card-content ol {
    margin-left: 2rem;
    margin-bottom: 1.2rem;
}

.sd29-card-content li {
    margin-bottom: 0.8rem;
}

/* ===== Footer ===== */
.sd29-footer {
    background: var(--sd29-dark);
    padding: 3rem 0 9rem;
    margin-top: 4rem;
    border-top: 1px solid rgba(132, 112, 255, 0.2);
}

.sd29-footer-content {
    margin-bottom: 2rem;
}

.sd29-footer-title {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 1.6rem;
    color: var(--sd29-primary);
}

.sd29-footer-text {
    font-size: 1.3rem;
    line-height: 1.8;
    color: var(--sd29-text-secondary);
    margin-bottom: 1.6rem;
}

.sd29-footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1.6rem;
    margin-bottom: 2rem;
}

.sd29-footer-link {
    font-size: 1.3rem;
    color: var(--sd29-text-secondary);
}

.sd29-footer-link:hover {
    color: var(--sd29-primary);
}

.sd29-partners {
    margin: 2rem 0;
}

.sd29-partners-title {
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 1.6rem;
    color: var(--sd29-text-secondary);
}

.sd29-partners-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.2rem;
}

.sd29-partner-img {
    width: 100%;
    height: 40px;
    object-fit: contain;
    filter: grayscale(100%) opacity(0.6);
    transition: var(--sd29-transition);
}

.sd29-partner-img:hover {
    filter: grayscale(0%) opacity(1);
}

.sd29-copyright {
    text-align: center;
    font-size: 1.2rem;
    color: var(--sd29-text-secondary);
    padding-top: 2rem;
    border-top: 1px solid rgba(132, 112, 255, 0.1);
}

/* ===== Bottom Navigation ===== */
.sd29-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(38, 38, 38, 0.95) 0%, var(--sd29-dark) 100%);
    backdrop-filter: blur(10px);
    box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.4);
    z-index: 1000;
    border-top: 1px solid rgba(132, 112, 255, 0.2);
}

.sd29-bottom-nav-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    height: 64px;
    max-width: 430px;
    margin: 0 auto;
}

.sd29-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 60px;
    min-height: 60px;
    color: var(--sd29-text-secondary);
    transition: var(--sd29-transition);
    cursor: pointer;
}

.sd29-nav-item:hover,
.sd29-nav-active {
    color: var(--sd29-primary);
}

.sd29-nav-icon {
    font-size: 2.4rem;
    margin-bottom: 0.4rem;
}

.sd29-nav-text {
    font-size: 1.1rem;
    font-weight: 500;
}

/* ===== Accordion ===== */
.sd29-accordion-item {
    background: var(--sd29-bg-secondary);
    border-radius: 8px;
    margin-bottom: 1rem;
    overflow: hidden;
}

.sd29-accordion-header {
    padding: 1.6rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--sd29-transition);
}

.sd29-accordion-header:hover {
    background: rgba(132, 112, 255, 0.1);
}

.sd29-accordion-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--sd29-text-primary);
}

.sd29-accordion-icon {
    font-size: 2rem;
    color: var(--sd29-primary);
    transition: var(--sd29-transition);
}

.sd29-accordion-active .sd29-accordion-icon {
    transform: rotate(180deg);
}

.sd29-accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.sd29-accordion-body {
    padding: 0 1.6rem 1.6rem;
    font-size: 1.4rem;
    line-height: 1.8;
    color: var(--sd29-text-secondary);
}

/* ===== Utilities ===== */
.sd29-text-center {
    text-align: center;
}

.sd29-text-gradient {
    background: var(--sd29-gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sd29-mt-1 { margin-top: 1rem; }
.sd29-mt-2 { margin-top: 2rem; }
.sd29-mt-3 { margin-top: 3rem; }
.sd29-mb-1 { margin-bottom: 1rem; }
.sd29-mb-2 { margin-bottom: 2rem; }
.sd29-mb-3 { margin-bottom: 3rem; }

/* ===== Responsive Design ===== */
@media (min-width: 769px) {
    .sd29-bottom-nav {
        display: none;
    }

    .sd29-wrapper {
        padding-bottom: 0;
    }

    .sd29-footer {
        padding-bottom: 3rem;
    }
}

@media (max-width: 768px) {
    .sd29-game-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .sd29-main {
        padding-bottom: 2rem;
    }
}

@media (max-width: 360px) {
    .sd29-game-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .sd29-btn {
        padding: 0.6rem 1.2rem;
        font-size: 1.2rem;
    }
}
