/* ═══════════════════════════════════════════════════════════════════════════
   Yacht Party Harmony — Cosmic Maritime Design System
   Luxury dark indigo · oceanic blue · stellar gold · neon cyan
   RTL Arabic-first · Mobile-first · Sticky footer
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── CSS Custom Properties (driven by site_settings theme) ── */
:root {
    --color-primary: #0a0e27;
    --color-accent: #00E5FF;
    --color-gold: #FFD700;
    --color-ocean: #1e3a8a;
    --color-bg: #0a0e27;
    --color-surface: #131a3a;
    --color-surface-light: #1a2347;
    --color-border: #1e2a5e;
    --color-text: #e0e7ff;
    --color-text-muted: #94a3b8;
    --color-text-dim: #64748b;
    --color-success: #10b981;
    --color-warning: #f59e0b;
    --color-danger: #ef4444;
    --color-info: #3b82f6;
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
    --shadow-lg: 0 8px 32px rgba(0,0,0,0.5);
    --shadow-glow: 0 0 20px rgba(0,229,255,0.15);
    --shadow-gold: 0 0 20px rgba(255,215,0,0.15);
    --gradient-cosmic: linear-gradient(135deg, #0a0e27 0%, #131a3a 50%, #1e3a8a 100%);
    --gradient-gold: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    --gradient-cyan: linear-gradient(135deg, #00E5FF 0%, #1e3a8a 100%);
    --font-ar: 'Tajawal', 'Cairo', 'Almarai', sans-serif;
    --font-en: 'Inter', 'Segoe UI', sans-serif;
}

/* ── Reset + Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
    font-family: var(--font-ar);
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* Cosmic background pattern */
body::before {
    content: '';
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(30,58,138,0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(0,229,255,0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(255,215,0,0.03) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

/* Star field */
body::after {
    content: '';
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image:
        radial-gradient(1px 1px at 25% 35%, rgba(255,255,255,0.4), transparent),
        radial-gradient(1px 1px at 50% 70%, rgba(255,215,0,0.3), transparent),
        radial-gradient(1px 1px at 75% 20%, rgba(0,229,255,0.3), transparent),
        radial-gradient(1px 1px at 10% 80%, rgba(255,255,255,0.2), transparent),
        radial-gradient(2px 2px at 90% 50%, rgba(255,215,0,0.2), transparent);
    background-size: 300px 300px;
    pointer-events: none;
    z-index: 0;
    opacity: 0.5;
}

[dir="rtl"] body { font-family: var(--font-ar); }
[dir="ltr"] body { font-family: var(--font-en); }

a { color: var(--color-accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--color-gold); }

img { max-width: 100%; height: auto; }

/* ── Layout Shell ── */
.app-shell {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.app-main {
    flex: 1 0 auto;
    padding: 1.5rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.app-main--full { max-width: 100%; }

/* ── Sticky Footer ── */
.app-footer {
    flex-shrink: 0;
    background: var(--color-surface);
    border-top: 1px solid var(--color-border);
    padding: 2rem 1.5rem 1.5rem;
    margin-top: auto;
}

.app-footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.app-footer-bottom {
    max-width: 1400px;
    margin: 1.5rem auto 0;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
    text-align: center;
    color: var(--color-text-muted);
    font-size: 0.875rem;
}

/* ── Navbar ── */
.navbar {
    background: rgba(10,14,39,0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--color-border);
    padding: 0.75rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--color-gold);
}

.navbar-brand img { height: 36px; width: auto; }

.navbar-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    list-style: none;
}

.navbar-nav a {
    color: var(--color-text-muted);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    transition: all 0.2s;
}

.navbar-nav a:hover,
.navbar-nav a.active {
    color: var(--color-accent);
    background: rgba(0,229,255,0.08);
}

/* ── Dropdown (lang/currency/notifications) ── */
.dropdown { position: relative; }
.dropdown-toggle {
    background: var(--color-surface-light);
    border: 1px solid var(--color-border);
    color: var(--color-text);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
}
.dropdown-toggle:hover { border-color: var(--color-accent); }
.dropdown-menu {
    position: absolute;
    top: 100%;
    inset-inline-end: 0;
    min-width: 200px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 0.5rem;
    display: none;
    z-index: 1100;
}
.dropdown.open .dropdown-menu { display: block; }
.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    color: var(--color-text);
    font-size: 0.875rem;
    cursor: pointer;
}
.dropdown-item:hover { background: var(--color-surface-light); }

/* Notification bell */
.notification-bell {
    position: relative;
    background: var(--color-surface-light);
    border: 1px solid var(--color-border);
    width: 40px; height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}
.notification-bell:hover { border-color: var(--color-accent); }
.notification-badge {
    position: absolute;
    top: -2px;
    inset-inline-end: -2px;
    background: var(--color-danger);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    min-width: 18px; height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* ── Sidebar ── */
.sidebar {
    background: var(--color-surface);
    border-inline-end: 1px solid var(--color-border);
    width: 260px;
    padding: 1rem;
    flex-shrink: 0;
    position: sticky;
    top: 60px;
    height: calc(100vh - 60px);
    overflow-y: auto;
}

.sidebar-section { margin-bottom: 1.5rem; }
.sidebar-title {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-text-dim);
    padding: 0 0.75rem;
    margin-bottom: 0.5rem;
}
.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 0.75rem;
    border-radius: var(--radius-sm);
    color: var(--color-text-muted);
    font-size: 0.9rem;
    transition: all 0.2s;
    margin-bottom: 2px;
}
.sidebar-link:hover { background: var(--color-surface-light); color: var(--color-text); }
.sidebar-link.active {
    background: rgba(0,229,255,0.1);
    color: var(--color-accent);
    border-inline-start: 3px solid var(--color-accent);
}
.sidebar-link svg { width: 18px; height: 18px; flex-shrink: 0; }

.app-body { display: flex; flex: 1; }

/* ── Cards ── */
.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s;
}
.card:hover { box-shadow: var(--shadow-md); border-color: rgba(0,229,255,0.2); }

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--color-border);
}
.card-title { font-size: 1.1rem; font-weight: 600; color: var(--color-gold); }

/* ── KPI Cards ── */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.kpi-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    position: relative;
    overflow: hidden;
}
.kpi-card::before {
    content: '';
    position: absolute;
    top: 0; inset-inline-start: 0;
    width: 4px; height: 100%;
    background: var(--color-accent);
}
.kpi-card--gold::before { background: var(--color-gold); }
.kpi-card--success::before { background: var(--color-success); }
.kpi-card--danger::before { background: var(--color-danger); }

.kpi-label { font-size: 0.8rem; color: var(--color-text-muted); margin-bottom: 0.5rem; }
.kpi-value { font-size: 1.75rem; font-weight: 700; color: var(--color-text); }
.kpi-value--gold { color: var(--color-gold); }
.kpi-value--cyan { color: var(--color-accent); }
.kpi-sub { font-size: 0.75rem; color: var(--color-text-dim); margin-top: 0.25rem; }

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s;
    white-space: nowrap;
    text-decoration: none;
}
.btn-primary {
    background: var(--gradient-cyan);
    color: var(--color-primary);
    border: none;
}
.btn-primary:hover { box-shadow: var(--shadow-glow); transform: translateY(-1px); }
.btn-gold {
    background: var(--gradient-gold);
    color: var(--color-primary);
    border: none;
}
.btn-gold:hover { box-shadow: var(--shadow-gold); transform: translateY(-1px); }
.btn-outline {
    background: transparent;
    border-color: var(--color-border);
    color: var(--color-text);
}
.btn-outline:hover { border-color: var(--color-accent); color: var(--color-accent); }
.btn-danger { background: var(--color-danger); color: #fff; border: none; }
.btn-danger:hover { opacity: 0.9; }
.btn-success { background: var(--color-success); color: #fff; border: none; }
.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.8rem; }
.btn-lg { padding: 0.875rem 2rem; font-size: 1rem; }
.btn-block { width: 100%; }

/* ── Forms ── */
.form-group { margin-bottom: 1rem; }
.form-label {
    display: block;
    font-size: 0.875rem;
    color: var(--color-text-muted);
    margin-bottom: 0.375rem;
    font-weight: 500;
}
.form-label .required { color: var(--color-danger); }
.form-control, .form-select, .form-textarea {
    width: 100%;
    background: var(--color-surface-light);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: 0.625rem 0.875rem;
    color: var(--color-text);
    font-size: 0.9rem;
    font-family: inherit;
    transition: all 0.2s;
}
.form-control:focus, .form-select:focus, .form-textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(0,229,255,0.1);
}
.form-textarea { resize: vertical; min-height: 100px; }
.form-hint { font-size: 0.75rem; color: var(--color-text-dim); margin-top: 0.25rem; }
.form-error { color: var(--color-danger); font-size: 0.8rem; margin-top: 0.25rem; }

/* ── Tables ── */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); }
.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}
.table th {
    text-align: start;
    padding: 0.75rem 1rem;
    background: var(--color-surface-light);
    color: var(--color-text-muted);
    font-weight: 600;
    white-space: nowrap;
    border-bottom: 1px solid var(--color-border);
}
.table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(30,42,94,0.5);
    color: var(--color-text);
}
.table tbody tr:hover { background: rgba(0,229,255,0.03); }

/* ── Badges ── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.2rem 0.625rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
}
.badge-success { background: rgba(16,185,129,0.15); color: var(--color-success); }
.badge-warning { background: rgba(245,158,11,0.15); color: var(--color-warning); }
.badge-danger { background: rgba(239,68,68,0.15); color: var(--color-danger); }
.badge-info { background: rgba(59,130,246,0.15); color: var(--color-info); }
.badge-gold { background: rgba(255,215,0,0.15); color: var(--color-gold); }
.badge-cyan { background: rgba(0,229,255,0.15); color: var(--color-accent); }

/* ── Progress Bar (gate attendance) ── */
.progress {
    height: 8px;
    background: var(--color-surface-light);
    border-radius: 999px;
    overflow: hidden;
}
.progress-bar {
    height: 100%;
    background: var(--gradient-cyan);
    border-radius: 999px;
    transition: width 0.5s ease;
}
.progress-bar--gold { background: var(--gradient-gold); }
.progress-bar--success { background: var(--color-success); }

/* ── Alerts ── */
.alert {
    padding: 0.875rem 1.25rem;
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.alert-success { background: rgba(16,185,129,0.1); border: 1px solid rgba(16,185,129,0.3); color: var(--color-success); }
.alert-danger { background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.3); color: var(--color-danger); }
.alert-warning { background: rgba(245,158,11,0.1); border: 1px solid rgba(245,158,11,0.3); color: var(--color-warning); }
.alert-info { background: rgba(59,130,246,0.1); border: 1px solid rgba(59,130,246,0.3); color: var(--color-info); }

/* ── Tabs ── */
.tabs {
    display: flex;
    gap: 0.25rem;
    border-bottom: 2px solid var(--color-border);
    margin-bottom: 1.5rem;
    overflow-x: auto;
}
.tab {
    padding: 0.75rem 1.25rem;
    color: var(--color-text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    border: none;
    background: transparent;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    white-space: nowrap;
    transition: all 0.2s;
}
.tab:hover { color: var(--color-text); }
.tab.active { color: var(--color-accent); border-bottom-color: var(--color-accent); }

/* ── Hero (landing) ── */
.hero {
    position: relative;
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 1.5rem;
    overflow: hidden;
}
.hero-content { position: relative; z-index: 2; max-width: 800px; }
.hero-title {
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 800;
    background: var(--gradient-gold);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    line-height: 1.2;
}
.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.5rem);
    color: var(--color-text);
    margin-bottom: 2rem;
    line-height: 1.6;
}
.hero-wave {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 100px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100'%3E%3Cpath fill='%230a0e27' d='M0,50 C320,100 720,0 1440,50 L1440,100 L0,100 Z'/%3E%3C/svg%3E") no-repeat bottom;
    background-size: cover;
    z-index: 1;
}

/* ── Subscription Tiers ── */
.tier-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}
.tier-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 2rem;
    position: relative;
    transition: all 0.3s;
}
.tier-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.tier-card--featured {
    border-color: var(--color-gold);
    box-shadow: var(--shadow-gold);
}
.tier-card--featured::after {
    content: 'الأكثر شيوعاً';
    position: absolute;
    top: -12px;
    inset-inline-start: 50%;
    transform: translateX(50%);
    background: var(--gradient-gold);
    color: var(--color-primary);
    padding: 0.25rem 1rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
}
[dir="rtl"] .tier-card--featured::after { transform: translateX(-50%); }
.tier-name { font-size: 1.5rem; font-weight: 700; color: var(--color-gold); margin-bottom: 0.5rem; }
.tier-price { font-size: 2.5rem; font-weight: 800; color: var(--color-text); margin-bottom: 0.25rem; }
.tier-price small { font-size: 1rem; color: var(--color-text-muted); font-weight: 400; }
.tier-features { list-style: none; margin: 1.5rem 0; }
.tier-features li {
    padding: 0.5rem 0;
    color: var(--color-text-muted);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.tier-features li::before { content: '✓'; color: var(--color-success); font-weight: 700; }

/* ── Social Feed ── */
.feed-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}
.feed-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.3s;
}
.feed-card:hover { border-color: rgba(0,229,255,0.2); }
.feed-media { width: 100%; aspect-ratio: 16/9; object-fit: cover; background: var(--color-surface-light); }
.feed-body { padding: 1rem; }
.feed-caption { font-size: 0.9rem; color: var(--color-text); line-height: 1.5; }
.feed-meta { display: flex; gap: 1rem; margin-top: 0.75rem; font-size: 0.75rem; color: var(--color-text-dim); }

/* ── Scanner UI ── */
.scanner-container {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
}
.scanner-view {
    width: 100%;
    aspect-ratio: 1;
    background: #000;
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    border: 2px solid var(--color-accent);
}
.scanner-overlay {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 70%; height: 70%;
    border: 3px solid var(--color-gold);
    border-radius: var(--radius-md);
    box-shadow: 0 0 0 9999px rgba(0,0,0,0.5);
}
.scanner-result {
    margin-top: 1.5rem;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    display: none;
}
.scanner-result.success { display: block; background: rgba(16,185,129,0.1); border: 1px solid var(--color-success); }
.scanner-result.error { display: block; background: rgba(239,68,68,0.1); border: 1px solid var(--color-danger); }

/* ── Invoice / Print ── */
.invoice {
    max-width: 800px;
    margin: 0 auto;
    background: #fff;
    color: #1a1a1a;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    font-family: var(--font-ar);
}
.invoice-header { display: flex; justify-content: space-between; margin-bottom: 2rem; }
.invoice-title { font-size: 1.5rem; font-weight: 700; color: #1e3a8a; }
.invoice-table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
.invoice-table th { background: #f1f5f9; padding: 0.75rem; text-align: start; font-size: 0.875rem; }
.invoice-table td { padding: 0.75rem; border-bottom: 1px solid #e2e8f0; font-size: 0.875rem; }
.invoice-total {
    display: flex;
    justify-content: flex-end;
    margin-top: 1.5rem;
}
.invoice-total-row {
    display: flex;
    justify-content: space-between;
    min-width: 250px;
    padding: 0.5rem 0;
    font-size: 0.9rem;
}
.invoice-total-row--grand { font-weight: 700; font-size: 1.1rem; border-top: 2px solid #1e3a8a; padding-top: 0.75rem; margin-top: 0.5rem; }
.invoice-qr { text-align: center; margin-top: 2rem; padding-top: 1.5rem; border-top: 1px dashed #cbd5e1; }
.invoice-qr img, .invoice-qr svg { max-width: 150px; }

@media print {
    body::before, body::after { display: none; }
    body { background: #fff; }
    .navbar, .app-footer, .no-print { display: none !important; }
    .invoice { box-shadow: none; border-radius: 0; }
}

/* ── Avatars ── */
.avatar {
    width: 40px; height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--color-border);
}
.avatar-lg { width: 64px; height: 64px; }
.avatar-sm { width: 28px; height: 28px; }

/* ── Pagination ── */
.pagination { display: flex; gap: 0.25rem; justify-content: center; margin-top: 1.5rem; list-style: none; }
.pagination a, .pagination span {
    padding: 0.5rem 0.875rem;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    background: var(--color-surface-light);
    color: var(--color-text-muted);
    border: 1px solid var(--color-border);
}
.pagination a:hover { border-color: var(--color-accent); color: var(--color-accent); }
.pagination .active { background: var(--color-accent); color: var(--color-primary); border-color: var(--color-accent); }

/* ── Utilities ── */
.text-gold { color: var(--color-gold) !important; }
.text-cyan { color: var(--color-accent) !important; }
.text-muted { color: var(--color-text-muted) !important; }
.text-center { text-align: center; }
.text-start { text-align: start; }
.text-end { text-align: end; }
.fw-bold { font-weight: 700; }
.d-flex { display: flex; }
.d-none { display: none; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 1rem; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.p-0 { padding: 0; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.w-full { width: 100%; }

/* ── Mobile ── */
@media (max-width: 768px) {
    .sidebar { display: none; }
    .navbar-nav { display: none; }
    .app-main { padding: 1rem; }
    .kpi-grid { grid-template-columns: repeat(2, 1fr); }
    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
    .hero { min-height: 60vh; }
    .invoice { padding: 1.5rem; }
}

@media (max-width: 480px) {
    .kpi-grid { grid-template-columns: 1fr; }
    .tier-grid { grid-template-columns: 1fr; }
}

/* ── Mobile menu toggle ── */
.mobile-menu-btn {
    display: none;
    background: var(--color-surface-light);
    border: 1px solid var(--color-border);
    color: var(--color-text);
    width: 40px; height: 40px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    align-items: center;
    justify-content: center;
}
@media (max-width: 768px) {
    .mobile-menu-btn { display: flex; }
}

/* ── Custom scrollbar ── */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--color-surface); }
::-webkit-scrollbar-thumb { background: var(--color-border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--color-ocean); }
