/* ============================================================
   CHEAT STORE — Layout: Header, Sidebar, Content Areas
   Dark Neumorphism Theme (Green Accent: #00e676)
   ============================================================ */

/* ── App Shell ──────────────────────────────────────────── */
.app-shell {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding-bottom: var(--bottom-nav-h);
}

@media (min-width: 768px) {
    .app-shell {
        flex-direction: row;
        padding-bottom: 0;
        padding-left: var(--sidebar-w);
    }
}

/* ── Header ─────────────────────────────────────────────── */
.app-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--header-h);
    background: var(--bg-surface);
    box-shadow: var(--shadow-raised);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    padding: 0 var(--sp);
    gap: var(--sp-sm);
    z-index: 100;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

@media (min-width: 768px) {
    .app-header { left: var(--sidebar-w); }
}

.header-logo {
    display: flex;
    align-items: center;
    gap: var(--sp-sm);
    cursor: pointer;
    flex: 1;
    min-width: 0;
}

.header-logo-icon {
    width: 36px; height: 36px;
    border-radius: var(--r-sm);
    background: var(--accent-bg);
    box-shadow: var(--shadow-raised);
    display: flex; align-items: center; justify-content: center;
    color: var(--accent);
    font-size: 20px;
    flex-shrink: 0;
    transition: var(--t);
    border: 1px solid var(--border-accent);
}
.header-logo:hover .header-logo-icon {
    box-shadow: 0 0 16px var(--accent-glow), var(--shadow-raised);
    color: var(--accent-light);
}

.header-logo-text {
    font-size: var(--fs-md);
    font-weight: 800;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -0.01em;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--sp-sm);
    flex-shrink: 0;
}

.header-icon-btn {
    width: 36px; height: 36px;
    border-radius: var(--r-sm);
    background: var(--bg-raised);
    box-shadow: var(--shadow-raised);
    display: flex; align-items: center; justify-content: center;
    color: var(--text-secondary);
    font-size: 18px;
    transition: var(--t);
    cursor: pointer;
    border: 1px solid var(--border);
    position: relative;
}
.header-icon-btn:hover {
    color: var(--accent);
    box-shadow: 0 0 12px var(--accent-glow), var(--shadow-raised);
    border-color: var(--border-accent);
}
.header-icon-btn:active { box-shadow: var(--shadow-inset); }

/* ── Language Dropdown System ────────────────────────────── */
.lang-dropdown-container {
    position: relative;
}

.lang-toggle-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--bg-raised);
    box-shadow: var(--shadow-raised);
    border: 1px solid var(--border);
    border-radius: var(--r-full);
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--t);
}
.lang-toggle-btn:hover {
    color: var(--accent);
    border-color: var(--border-accent);
    box-shadow: 0 0 12px var(--accent-glow), var(--shadow-raised);
}

.lang-flag-active {
    width: 18px;
    height: 12px;
    border-radius: 2px;
    object-fit: cover;
}

.lang-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--bg-surface);
    border-radius: var(--r);
    box-shadow: var(--shadow-float);
    border: 1px solid var(--border);
    padding: 6px;
    min-width: 170px;
    display: none;
    flex-direction: column;
    gap: 2px;
    z-index: 500;
    backdrop-filter: blur(12px);
}
.lang-dropdown-menu.show { display: flex; animation: cs-fade-in 0.2s ease; }

.lang-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: var(--r-sm);
    font-size: 12.5px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--t);
}
.lang-dropdown-item:hover {
    background: var(--accent-bg);
    color: var(--accent);
}
.lang-dropdown-item.active {
    background: var(--accent-bg);
    color: var(--accent);
    font-weight: 700;
}

/* Dev console button */
.dev-console-btn {
    display: flex; align-items: center; gap: 5px;
    background: var(--bg-raised);
    box-shadow: var(--shadow-raised);
    border: 1px solid var(--border-accent);
    border-radius: var(--r-full);
    padding: 5px 12px;
    font-size: 12px;
    font-weight: 700;
    color: var(--accent);
    cursor: pointer;
    transition: var(--t);
    white-space: nowrap;
}
.dev-console-btn:hover {
    background: var(--accent-bg);
    box-shadow: 0 0 14px var(--accent-glow), var(--shadow-raised);
}

/* ── Sidebar Navigation (Desktop) ───────────────────────── */
.app-sidebar {
    position: fixed;
    top: 0; left: 0; bottom: 0;
    width: var(--sidebar-w);
    background: var(--bg-surface);
    box-shadow: var(--shadow-raised);
    border-right: 1px solid var(--border);
    display: none;
    flex-direction: column;
    align-items: center;
    padding: var(--sp) 0;
    gap: var(--sp-xs);
    z-index: 101;
    overflow-y: auto;
    overflow-x: hidden;
}
@media (min-width: 768px) { .app-sidebar { display: flex; } }

.sidebar-logo-area {
    width: 42px; height: 42px;
    border-radius: var(--r-sm);
    background: var(--accent-bg);
    box-shadow: var(--shadow-raised);
    display: flex; align-items: center; justify-content: center;
    color: var(--accent);
    font-size: 22px;
    margin-bottom: var(--sp);
    transition: var(--t);
    border: 1px solid var(--border-accent);
}
.sidebar-logo-area:hover {
    box-shadow: 0 0 18px var(--accent-glow), var(--shadow-raised);
}

/* Nav items */
.nav-item {
    width: 48px; height: 50px;
    border-radius: var(--r-sm);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    gap: 2px;
    cursor: pointer;
    transition: var(--t);
    position: relative;
    color: var(--text-muted);
    box-shadow: var(--shadow-raised);
    background: var(--bg-raised);
    border: 1px solid var(--border);
    font-size: 10px;
    font-weight: 600;
}
.nav-item .material-symbols-outlined { font-size: 20px; }
.nav-item:hover {
    color: var(--accent);
    border-color: var(--border-accent);
    box-shadow: 0 0 12px var(--accent-glow), var(--shadow-raised);
}
.nav-item.active {
    color: var(--accent);
    background: var(--accent-bg);
    box-shadow: var(--shadow-inset), 0 0 12px var(--accent-glow);
    border-color: var(--border-accent);
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: -2px; top: 50%; transform: translateY(-50%);
    width: 3.5px; height: 20px;
    background: var(--accent);
    border-radius: 0 var(--r-full) var(--r-full) 0;
    box-shadow: 0 0 8px var(--accent-glow);
}

/* ── Bottom Navigation (Mobile) ─────────────────────────── */
.bottom-nav {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: var(--bottom-nav-h);
    background: var(--bg-surface);
    box-shadow: 0 -4px 20px rgba(0,0,0,0.5), var(--shadow-raised);
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 0 var(--sp-xs);
    z-index: 100;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}
@media (min-width: 768px) { .bottom-nav { display: none; } }

.bottom-nav .nav-item {
    width: auto;
    height: auto;
    padding: 5px 12px;
    flex-direction: column;
    gap: 2px;
    border-radius: var(--r-sm);
    font-size: 9.5px;
    box-shadow: none;
    border: none;
    background: none;
}
.bottom-nav .nav-item:hover {
    box-shadow: none;
    background: var(--accent-bg);
}
.bottom-nav .nav-item.active {
    box-shadow: var(--shadow-inset-sm);
    background: var(--accent-bg);
    color: var(--accent);
}
.bottom-nav .nav-item.active::before { display: none; }

/* ── Main Content Area ───────────────────────────────────── */
.main-content {
    flex: 1;
    margin-top: var(--header-h);
    padding: var(--sp-lg) var(--sp);
    max-width: 100%;
    overflow-x: hidden;
}

@media (min-width: 768px) {
    .main-content { padding: var(--sp-xl) var(--sp-xl); }
}
@media (min-width: 1200px) {
    .main-content {
        padding: var(--sp-xl) 40px;
        max-width: var(--content-max);
        margin-left: auto; margin-right: auto;
    }
}

.section-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--sp-sm);
    gap: var(--sp-sm);
}

.section-title {
    font-size: 15px;
    font-weight: 800;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-title::before {
    content: '';
    width: 3.5px;
    height: 16px;
    background: var(--accent);
    border-radius: var(--r-full);
    box-shadow: 0 0 8px var(--accent-glow);
    flex-shrink: 0;
}

.see-more-btn {
    display: flex; align-items: center; gap: 3px;
    font-size: 11.5px;
    font-weight: 700;
    color: var(--accent);
    cursor: pointer;
    padding: 4px 10px;
    border-radius: var(--r-full);
    background: var(--accent-bg);
    border: 1px solid var(--border-accent);
    box-shadow: var(--shadow-raised);
    transition: var(--t);
    white-space: nowrap;
}
.see-more-btn:hover {
    box-shadow: 0 0 12px var(--accent-glow), var(--shadow-raised);
}

/* Announcement Notice Bar */
.announcement-notice-bar {
    position: fixed;
    bottom: calc(var(--bottom-nav-h) + 12px);
    left: 12px;
    right: 12px;
    border-radius: var(--r);
    padding: 12px 14px;
    z-index: 999;
    display: none;
    box-shadow: var(--shadow-float);
    border: 1px solid var(--border);
    transform: translateY(20px);
    opacity: 0;
    transition: transform 0.35s var(--ease-out), opacity 0.35s var(--ease-out);
    backdrop-filter: blur(10px);
}
.announcement-notice-bar.notice-visible { transform: translateY(0); opacity: 1; }
@media (min-width: 768px) {
    .announcement-notice-bar {
        bottom: 16px; left: calc(var(--sidebar-w) + 16px);
        max-width: 480px;
    }
}
.notice-type-warning { background: rgba(255,171,64,0.15); border-color: var(--amber-glow); color: var(--amber); }
.notice-type-info    { background: rgba(0,230,118,0.15); border-color: var(--accent-glow); color: var(--accent-light); }
.notice-type-success { background: rgba(0,230,118,0.15); border-color: var(--accent-glow); color: var(--accent); }
.notice-type-danger  { background: rgba(255,82,82,0.15); border-color: var(--rose-glow); color: var(--rose); }

.notice-inner { display: flex; align-items: flex-start; gap: 8px; }
.notice-text-content { flex: 1; font-size: 12.5px; font-weight: 500; line-height: 1.4; }
.notice-close-btn {
    background: none; border: none; cursor: pointer;
    color: inherit; opacity: 0.7; font-size: 16px;
    padding: 2px; flex-shrink: 0;
    transition: var(--t);
}
.notice-close-btn:hover { opacity: 1; }
