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

:root {
    /* Apple Dark Mode Palette */
    --bg-body: #000000;
    --bg-card: #1C1C1E;
    --bg-secondary: #2C2C2E;
    --primary: #0A84FF; /* iOS System Blue */
    --primary-dim: rgba(10, 132, 255, 0.15);
    --text-main: #FFFFFF;
    --text-muted: #8E8E93;
    --border: #38383A;
    --danger: #FF453A;
    --success: #30D158;
    
    /* Dimensions */
    --header-height: 60px;
    --bottom-nav-height: 80px;
    --radius-lg: 18px;
    --radius-sm: 10px;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

body {
    background-color: var(--bg-body);
    color: var(--text-main);
    font-family: 'Inter', -apple-system, sans-serif;
    padding-top: var(--header-height);
    padding-bottom: var(--bottom-nav-height); /* Space for bottom nav */
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }

/* --- 1. Top Navigation (Header) --- */
.top-nav {
    position: fixed; top: 0; left: 0; width: 100%;
    height: var(--header-height);
    background: rgba(28, 28, 30, 0.85); /* Glass effect */
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    display: flex; justify-content: space-between; align-items: center;
    padding: 0 20px; z-index: 1000;
    border-bottom: 0.5px solid rgba(255,255,255,0.1);
}

.brand { font-size: 20px; font-weight: 700; letter-spacing: -0.5px; }
.brand span { color: var(--primary); }

.profile-btn-header {
    width: 36px; height: 36px;
    background: var(--bg-secondary);
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    color: var(--primary);
    cursor: pointer;
    transition: 0.2s;
}
.profile-btn-header:active { transform: scale(0.9); }

/* --- 2. Bottom Navigation --- */
.bottom-nav {
    position: fixed; bottom: 0; left: 0; width: 100%;
    height: var(--bottom-nav-height);
    background: rgba(28, 28, 30, 0.9);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    display: flex; justify-content: space-around; align-items: center;
    border-top: 0.5px solid rgba(255,255,255,0.1);
    z-index: 1000;
    padding-bottom: 15px; /* Safe area for iPhone home bar */
}

.nav-item {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    color: var(--text-muted); font-size: 11px; font-weight: 500;
    gap: 4px; width: 60px;
}
.nav-item i { font-size: 24px; transition: 0.2s; }
.nav-item.active { color: var(--primary); }
.nav-item.active i { transform: translateY(-2px); }

/* --- 3. UI Components --- */
.container { padding: 20px; max-width: 600px; margin: 0 auto; }

.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 16px;
    border: 0.5px solid rgba(255,255,255,0.05);
}

.btn {
    background: var(--primary); color: white;
    padding: 16px; border-radius: var(--radius-lg);
    border: none; font-weight: 600; font-size: 16px;
    width: 100%; cursor: pointer; display: flex; justify-content: center; align-items: center; gap: 8px;
    transition: 0.2s;
}
.btn:active { opacity: 0.8; transform: scale(0.98); }

input, select {
    background: var(--bg-secondary); border: none;
    padding: 16px; border-radius: var(--radius-sm);
    color: white; width: 100%; margin-bottom: 12px; font-size: 16px;
}
input:focus { outline: 2px solid var(--primary); }

/* --- 4. Utilities --- */
.section-title {
    font-size: 13px; text-transform: uppercase; letter-spacing: 1px;
    color: var(--text-muted); margin: 24px 0 10px 4px; font-weight: 600;
}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* Modal & Icons */
.ph { vertical-align: middle; }