/* ===== BASE: Variables, Reset, Layout, Navigation ===== */

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

:root {
    /* Brand Colors (New) */
    --brand-pink: #E91E63;   /* Protecting Beauty */
    --brand-blue: #2196F3;   /* Empowering Safety */
    --brand-gold: #FFC107;   /* Wealth */
    
    /* Base Overrides */
    --primary: var(--brand-pink);       /* 버튼 등 주요 액션 */
    --primary-light: #F48FB1;
    --bg: #050505;                      /* 더 깊은 검정 */
    --bg-card: rgba(30, 30, 40, 0.7);   /* Glassmorphism 준비 */
    --text: #ffffff;
    --border: rgba(255, 255, 255, 0.1);
    
    /* Legacy Compat (기존 코드 깨짐 방지) */
    --gold: var(--brand-gold);
    --accent: var(--brand-gold);

    --primary-legacy: #1a1a2e; /* Original primary kept for backup */
    --gold-dark: #B8860B;
    --cream: #FFF8F0;
    --cream-dark: #F5E6D3;
    --bg-card-alt: #1e1e3a;
    --text-light: #aaa;
    --text-muted: #888;
    --white: #1a1a2e;
    --card-bg: #1a1a2e;
    --success: #4CAF50;
    --warning: #ff9800;
    --error: #ff4444;
    --danger: #ff4444;
    --info: #2196f3;

    /* Legacy aliases */
    --dark-bg: #0a0a1a;
    --dark-card: #1a1a2e;
    --dark-card-alt: #1e1e3a;
    --dark-border: #2a2a3e;
    --dark-text: #f0f0f0;
    --dark-muted: #888;
    --dark-gold: #D4AF37;
    --dark-cream: #FFF8F0;
}


/* Landing Specific Styles */
#landing-page {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100vh;
    background: linear-gradient(135deg, #000000 0%, #1a0510 100%);
    z-index: 9999; /* 최상단 노출 */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.hidden { display: none !important; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
}


/* Auth Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 12px;
    max-width: 400px;
    width: 90%;
    border: 1px solid var(--border);
    color: var(--text);
}

.modal-content h2 {
    text-align: center;
    margin-bottom: 1.5rem;
}

.auth-form h3 {
    margin-bottom: 1rem;
}

.auth-form .input {
    width: 100%;
    margin-bottom: 1rem;
}

.auth-form p {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.9rem;
}

.auth-form a {
    color: var(--text);
    text-decoration: underline;
}

.user-info {
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1rem;
}

.user-info p {
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-logout {
    padding: 0.5rem 1rem;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
}


/* Mobile Menu Toggle */
.menu-toggle {
    display: block;
    position: fixed;
    top: 0.5rem;
    left: 0.5rem;
    z-index: 1001;
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 0.5rem 0.7rem;
    border-radius: 8px;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    color: var(--text);
}


/* Sidebar */
.sidebar {
    width: 220px;
    background: var(--primary);
    color: #e0e0e0;
    border-right: none;
    padding: 1rem 0;
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform 0.3s;
    z-index: 1000;
}

.sidebar.active {
    transform: translateX(0);
}

.logo {
    padding: 0 1rem 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 0.5rem;
    cursor: pointer;
}

.logo h1 {
    font-size: 1.5rem;
    letter-spacing: 2px;
    margin-bottom: 0.25rem;
    color: var(--gold);
}

.logo p {
    font-size: 0.8rem;
    color: var(--gold-dark);
    letter-spacing: 1px;
}

.nav {
    display: flex;
    flex-direction: column;
}

.nav-sub {
    display: block;
    font-size: 0.6rem;
    opacity: 0.5;
    font-weight: 400;
    margin-top: 1px;
    letter-spacing: 0;
}
html[lang="en"] .nav-sub { display: none; }

.nav-item {
    display: block;
    padding: 0.5rem 1rem;
    text-decoration: none;
    color: rgba(255,255,255,0.75);
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    transition: all 0.2s;
}

.nav-item:hover {
    background: rgba(255,255,255,0.08);
    color: var(--gold);
}

.nav-item.active {
    background: rgba(255,215,0,0.1);
    border-left: 3px solid var(--gold);
    color: var(--gold);
    font-weight: 600;
}

.sidebar .nav-divider {
    border: none;
    border-top: 1px solid rgba(255,255,255,0.08);
    margin: 0.4rem 1rem;
}

.sidebar .nav-group-label {
    padding: 0.5rem 1rem 0.2rem;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: rgba(255,255,255,0.3);
    font-weight: 700;
}

/* Main Content */
.content {
    margin-left: 0;
    padding: 1.5rem;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.page {
    display: none;
}

.page.active {
    display: block;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    letter-spacing: 1px;
}


/* Buttons */
.btn-primary {
    background: var(--gold);
    color: #000;
    border: none;
    padding: 1rem 2rem;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-primary:hover {
    background: #e6c040;
    color: #000;
}

.btn-buy {
    background: var(--text);
    color: var(--white);
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    width: 100%;
    font-weight: 600;
    transition: opacity 0.2s;
}

.btn-buy:hover {
    opacity: 0.9;
}


