/* ═══════════════════════════════════════════
   SportCRM — Design System
   ═══════════════════════════════════════════ */

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

:root {
    --green-50: #e8f5e9; --green-100: #c8e6c9; --green-400: #66bb6a;
    --green-500: #4CAF50; --green-600: #43a047; --green-700: #388e3c;
    --green-800: #2e7d32; --green-900: #1b5e20;
    --orange-400: #ffa726; --orange-500: #ff9800; --orange-600: #fb8c00;
    --blue-400: #42a5f5; --blue-500: #2196f3;
    --red-400: #ef5350; --red-500: #f44336;
    --purple-400: #ab47bc; --purple-500: #9c27b0;

    --sidebar-bg: #25293c; --sidebar-hover: #2f3349;
    --sidebar-active: rgba(76,175,80,0.16);
    --sidebar-text: #a3a4b5; --sidebar-text-active: #e7e7e8;
    --sidebar-width: 264px;

    --bg: #f5f5f9; --card: #ffffff;
    --card-shadow: 0 2px 12px rgba(0,0,0,0.06);
    --card-shadow-hover: 0 6px 24px rgba(0,0,0,0.1);
    --card-radius: 12px; --border: #e7e7e8;
    --text-primary: #2b2c40; --text-secondary: #6e6b7b; --text-muted: #a8a8b3;
    --gap: 24px; --page-padding: 28px;
    --font: 'Plus Jakarta Sans', -apple-system, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

html { font-size: 14px; }
body { font-family: var(--font); background: var(--bg); color: var(--text-primary); display: flex; min-height: 100vh; -webkit-font-smoothing: antialiased; }

/* ── SIDEBAR ────────────────────────────── */
.sidebar { width: var(--sidebar-width); background: var(--sidebar-bg); height: 100vh; position: fixed; left: 0; top: 0; z-index: 100; display: flex; flex-direction: column; overflow-y: auto; overflow-x: hidden; scrollbar-width: none; }
.sidebar::-webkit-scrollbar { display: none; }
.sidebar-brand { padding: 20px 20px 8px; display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.sidebar-brand .logo { width: 38px; height: 38px; background: linear-gradient(135deg, var(--green-500), var(--green-800)); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 20px; color: #fff; flex-shrink: 0; box-shadow: 0 2px 8px rgba(76,175,80,0.35); }
.sidebar-brand .brand-name { font-size: 17px; font-weight: 800; color: #e7e7e8; letter-spacing: -0.3px; }
.sidebar-brand .brand-sub { font-size: 10.5px; color: var(--sidebar-text); font-weight: 500; letter-spacing: 0.5px; text-transform: uppercase; margin-top: 1px; }
.sidebar-club { margin: 16px 16px 8px; padding: 14px; background: var(--sidebar-hover); border-radius: 10px; display: flex; align-items: center; gap: 11px; flex-shrink: 0; }
.sidebar-club .club-crest { width: 36px; height: 36px; background: linear-gradient(135deg, #1a237e, #283593); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; color: #fff; font-weight: 800; flex-shrink: 0; border: 2px solid rgba(255,255,255,0.1); }
.sidebar-club .club-name { font-size: 13px; font-weight: 700; color: var(--sidebar-text-active); }
.sidebar-club .club-plan { font-size: 10.5px; color: var(--green-400); font-weight: 600; display: flex; align-items: center; gap: 4px; margin-top: 2px; }
.sidebar-club .club-plan::before { content: ''; width: 6px; height: 6px; background: var(--green-400); border-radius: 50%; }
.sidebar-section { padding: 16px 12px 6px; font-size: 10px; text-transform: uppercase; letter-spacing: 1.2px; color: #565670; font-weight: 700; flex-shrink: 0; }
.nav-item { display: block; padding: 0 12px; margin-bottom: 2px; flex-shrink: 0; }
.nav-link { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 8px; color: var(--sidebar-text); text-decoration: none; font-size: 13.5px; font-weight: 500; transition: all 0.15s; cursor: pointer; position: relative; }
.nav-link:hover { background: var(--sidebar-hover); color: var(--sidebar-text-active); }
.nav-link.active { background: var(--sidebar-active); color: var(--green-400); font-weight: 600; }
.nav-link.active::before { content: ''; position: absolute; left: -12px; top: 50%; transform: translateY(-50%); width: 4px; height: 26px; background: var(--green-500); border-radius: 0 4px 4px 0; }
.nav-link i { font-size: 20px; width: 22px; text-align: center; flex-shrink: 0; }
.nav-link .badge { margin-left: auto; background: var(--green-500); color: #fff; font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 10px; }
.nav-link .chevron { margin-left: auto; font-size: 16px; transition: transform 0.2s; }
.nav-item.open .chevron { transform: rotate(90deg); }
.nav-sub { display: none; padding: 2px 0 4px 48px; }
.nav-item.open .nav-sub { display: block; }
.nav-sub a { display: flex; align-items: center; gap: 10px; padding: 7px 14px; color: var(--sidebar-text); text-decoration: none; font-size: 12.5px; font-weight: 500; border-radius: 6px; transition: all 0.15s; }
.nav-sub a::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: 0.4; flex-shrink: 0; }
.nav-sub a:hover { color: var(--sidebar-text-active); background: var(--sidebar-hover); }

/* ── MAIN ───────────────────────────────── */
.main { margin-left: var(--sidebar-width); flex: 1; display: flex; flex-direction: column; min-height: 100vh; }

/* ── TOPBAR ─────────────────────────────── */
.topbar { height: 64px; background: var(--card); border-bottom: 1px solid var(--border); display: flex; align-items: center; padding: 0 var(--page-padding); gap: 16px; position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 4px rgba(0,0,0,0.03); }
.topbar-search { display: flex; align-items: center; gap: 10px; background: var(--bg); border-radius: 10px; padding: 9px 16px; flex: 1; max-width: 400px; border: 1px solid transparent; transition: all 0.2s; }
.topbar-search:focus-within { border-color: var(--green-400); background: #fff; box-shadow: 0 0 0 3px rgba(76,175,80,0.1); }
.topbar-search i { color: var(--text-muted); font-size: 18px; }
.topbar-search input { border: none; background: none; outline: none; font-family: var(--font); font-size: 13px; color: var(--text-primary); width: 100%; }
.topbar-search input::placeholder { color: var(--text-muted); }
.topbar-search kbd { font-family: var(--font); font-size: 10px; background: var(--card); border: 1px solid var(--border); padding: 2px 6px; border-radius: 4px; color: var(--text-muted); }
.topbar-right { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.topbar-btn { width: 38px; height: 38px; border-radius: 10px; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); cursor: pointer; transition: all 0.15s; border: none; background: none; font-size: 20px; position: relative; }
.topbar-btn:hover { background: var(--bg); color: var(--text-primary); }
.topbar-btn .dot { position: absolute; top: 4px; right: 4px; min-width: 18px; height: 18px; background: var(--red-400); border-radius: 9px; border: 2px solid var(--card); font-size: 10px; font-weight: 700; color: #fff; display: flex; align-items: center; justify-content: center; padding: 0 4px; }
.topbar-divider { width: 1px; height: 28px; background: var(--border); margin: 0 8px; }
.topbar-user { display: flex; align-items: center; gap: 10px; cursor: pointer; padding: 4px 8px 4px 4px; border-radius: 10px; transition: background 0.15s; }
.topbar-user:hover { background: var(--bg); }
.topbar-user .avatar { width: 36px; height: 36px; border-radius: 10px; background: linear-gradient(135deg, var(--green-500), var(--green-800)); display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 14px; }
.topbar-user .user-name { font-size: 13px; font-weight: 600; color: var(--text-primary); }
.topbar-user .user-role { font-size: 11px; color: var(--text-muted); }

/* ── CONTENT ────────────────────────────── */
.content { padding: var(--page-padding); flex: 1; }
.page-header { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: var(--gap); }
.page-header h1 { font-size: 22px; font-weight: 800; letter-spacing: -0.3px; }
.page-header .subtitle { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }
.header-actions { display: flex; gap: 10px; }

/* ── BUTTONS ────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 9px 18px; border-radius: 8px; font-family: var(--font); font-size: 13px; font-weight: 600; border: none; cursor: pointer; transition: all 0.15s; text-decoration: none; }
.btn-primary { background: var(--green-500); color: #fff; box-shadow: 0 2px 8px rgba(76,175,80,0.3); }
.btn-primary:hover { background: var(--green-600); box-shadow: 0 4px 14px rgba(76,175,80,0.4); transform: translateY(-1px); }
.btn-outline { background: var(--card); color: var(--text-secondary); border: 1px solid var(--border); }
.btn-outline:hover { border-color: var(--green-400); color: var(--green-600); }
.btn-danger { background: var(--red-500); color: #fff; }
.btn-full { width: 100%; justify-content: center; padding: 12px; }
.btn-sm { padding: 6px 12px; font-size: 12px; }

/* ── GRID ───────────────────────────────── */
.grid { display: grid; gap: var(--gap); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

/* ── CARDS ──────────────────────────────── */
.card { background: var(--card); border-radius: var(--card-radius); box-shadow: var(--card-shadow); transition: box-shadow 0.2s, transform 0.2s; overflow: hidden; }
.card:hover { box-shadow: var(--card-shadow-hover); transform: translateY(-2px); }
.card-header { padding: 18px 20px 0; display: flex; align-items: center; justify-content: space-between; }
.card-title { font-size: 15px; font-weight: 700; }
.card-subtitle { font-size: 11.5px; color: var(--text-muted); margin-top: 2px; }
.card-body { padding: 16px 20px 20px; }
.card-header + .card-body { padding-top: 14px; }
.card-action { font-size: 11.5px; font-weight: 600; color: var(--green-500); text-decoration: none; display: flex; align-items: center; gap: 3px; cursor: pointer; }
.card-action:hover { color: var(--green-700); }

/* ── KPI CARDS ──────────────────────────── */
.kpi-card { position: relative; overflow: hidden; }
.kpi-card .card-body { padding: 22px 20px; display: flex; flex-direction: column; gap: 4px; position: relative; z-index: 1; }
.kpi-card .kpi-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 22px; margin-bottom: 8px; }
.kpi-card .kpi-label { font-size: 12px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.4px; }
.kpi-card .kpi-value { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; line-height: 1.1; }
.kpi-card .kpi-change { display: flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; margin-top: 4px; }
.kpi-change.up { color: var(--green-600); }
.kpi-change.down { color: var(--red-400); }
.kpi-change.neutral { color: var(--text-muted); }
.kpi-card .kpi-bg { position: absolute; right: -8px; bottom: -8px; font-size: 90px; opacity: 0.04; z-index: 0; line-height: 1; }
.kpi-card.green .kpi-icon { background: rgba(76,175,80,0.12); color: var(--green-600); }
.kpi-card.orange .kpi-icon { background: rgba(255,152,0,0.12); color: var(--orange-600); }
.kpi-card.blue .kpi-icon { background: rgba(33,150,243,0.12); color: var(--blue-500); }
.kpi-card.purple .kpi-icon { background: rgba(156,39,176,0.12); color: var(--purple-400); }
.kpi-card.green { border-top: 3px solid var(--green-500); }
.kpi-card.orange { border-top: 3px solid var(--orange-500); }
.kpi-card.blue { border-top: 3px solid var(--blue-500); }
.kpi-card.purple { border-top: 3px solid var(--purple-400); }

/* ── KANBAN ─────────────────────────────── */
.kanban-preview { display: flex; gap: 10px; overflow-x: auto; }
.kanban-col { flex: 1; min-width: 0; background: var(--bg); border-radius: 8px; padding: 10px; }
.kanban-col-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.kanban-col-title { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-secondary); }
.kanban-count { font-size: 10px; font-weight: 700; width: 20px; height: 20px; border-radius: 6px; display: flex; align-items: center; justify-content: center; color: #fff; }
.kanban-col.lead .kanban-count { background: var(--text-muted); }
.kanban-col.contacted .kanban-count { background: var(--blue-500); }
.kanban-col.offer .kanban-count { background: var(--orange-500); }
.kanban-col.negotiation .kanban-count { background: var(--purple-400); }
.kanban-col.won .kanban-count { background: var(--green-500); }

/* ── LISTS ──────────────────────────────── */
.list-item { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #f4f4f5; }
.list-item:last-child { border-bottom: none; }
.list-icon { width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 17px; flex-shrink: 0; }
.list-icon.green { background: rgba(76,175,80,0.12); color: var(--green-600); }
.list-icon.orange { background: rgba(255,152,0,0.12); color: var(--orange-600); }
.list-icon.blue { background: rgba(33,150,243,0.12); color: var(--blue-500); }
.list-item-title { font-size: 13px; font-weight: 600; }
.list-item-sub { font-size: 11.5px; color: var(--text-muted); margin-top: 1px; }

/* ── ALERTS ─────────────────────────────── */
.alert { padding: 12px 16px; border-radius: 8px; font-size: 13px; font-weight: 500; margin-bottom: 16px; }
.alert-success { background: rgba(76,175,80,0.1); color: var(--green-800); border: 1px solid rgba(76,175,80,0.2); }
.alert-danger { background: rgba(244,67,54,0.1); color: #c62828; border: 1px solid rgba(244,67,54,0.2); }
.alert-warning { background: rgba(255,152,0,0.1); color: #e65100; border: 1px solid rgba(255,152,0,0.2); }

/* ── FORMS ──────────────────────────────── */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 12px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.3px; }
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 10px 14px; border: 1px solid var(--border); border-radius: 8px; font-family: var(--font); font-size: 13px; color: var(--text-primary); background: var(--card); transition: all 0.2s; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--green-400); box-shadow: 0 0 0 3px rgba(76,175,80,0.1); }
.input-with-icon { position: relative; }
.input-with-icon i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); font-size: 18px; }
.input-with-icon input { padding-left: 42px; }
.form-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.checkbox-label { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-secondary); cursor: pointer; }

/* ── LOGIN PAGE ─────────────────────────── */
.login-page { min-height: 100vh; display: flex; width: 100%; }

/* Hero side */
.login-hero { flex: 1; background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 40%, #388e3c 100%); display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; padding: 60px; }
.login-hero-content { position: relative; z-index: 2; max-width: 480px; }
.login-hero-logo { width: 64px; height: 64px; background: rgba(255,255,255,0.15); backdrop-filter: blur(10px); border-radius: 16px; display: flex; align-items: center; justify-content: center; font-size: 32px; color: #fff; margin-bottom: 24px; border: 1px solid rgba(255,255,255,0.2); }
.login-hero h1 { font-size: 38px; font-weight: 800; color: #fff; letter-spacing: -1px; line-height: 1.1; }
.login-hero-tagline { font-size: 16px; color: rgba(255,255,255,0.8); margin-top: 12px; line-height: 1.5; font-weight: 500; }
.login-hero-features { margin-top: 40px; display: flex; flex-direction: column; gap: 14px; }
.login-feature { display: flex; align-items: center; gap: 12px; color: rgba(255,255,255,0.9); font-size: 14px; font-weight: 500; }
.login-feature i { font-size: 20px; width: 40px; height: 40px; background: rgba(255,255,255,0.1); border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.login-hero-stats { margin-top: 48px; display: flex; align-items: center; gap: 24px; padding: 20px 0; border-top: 1px solid rgba(255,255,255,0.15); }
.hero-stat { text-align: center; }
.hero-stat-value { display: block; font-size: 28px; font-weight: 800; color: #fff; line-height: 1; }
.hero-stat-label { display: block; font-size: 11px; color: rgba(255,255,255,0.6); text-transform: uppercase; letter-spacing: 1px; margin-top: 4px; font-weight: 600; }
.hero-stat-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.15); }

/* Hero background circles */
.login-hero-bg { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.hero-circle { position: absolute; border-radius: 50%; border: 1px solid rgba(255,255,255,0.08); }
.hero-circle-1 { width: 500px; height: 500px; top: -150px; right: -100px; background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%); }
.hero-circle-2 { width: 300px; height: 300px; bottom: -50px; left: -80px; background: radial-gradient(circle, rgba(255,255,255,0.04) 0%, transparent 70%); }
.hero-circle-3 { width: 200px; height: 200px; top: 40%; left: 60%; background: radial-gradient(circle, rgba(255,255,255,0.03) 0%, transparent 70%); }

/* Form side */
.login-form-side { width: 520px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; background: var(--card); padding: 60px; }
.login-form-container { width: 100%; max-width: 380px; }
.login-welcome h2 { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; color: var(--text-primary); }
.login-welcome p { font-size: 14px; color: var(--text-muted); margin-top: 6px; margin-bottom: 32px; }
.form-label-row { display: flex; justify-content: space-between; align-items: center; }
.form-link { font-size: 12px; color: var(--green-500); text-decoration: none; font-weight: 600; }
.form-link:hover { color: var(--green-700); }
.login-form .form-group { margin-bottom: 20px; }
.login-form .form-group input { padding: 12px 14px 12px 44px; font-size: 14px; border-radius: 10px; }
.login-form .input-with-icon i { left: 14px; font-size: 20px; }
.login-form .form-row { margin-bottom: 24px; }
.login-form .btn-lg { padding: 13px 20px; font-size: 15px; border-radius: 10px; font-weight: 700; letter-spacing: 0.2px; }
.login-form .btn-lg i { font-size: 20px; }
.checkbox-label { position: relative; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--text-secondary); cursor: pointer; user-select: none; }
.checkbox-label input { width: 18px; height: 18px; accent-color: var(--green-500); cursor: pointer; }
.login-footer { text-align: center; margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--border); }
.login-footer p { font-size: 13px; color: var(--text-muted); }
.login-footer a { color: var(--green-500); text-decoration: none; font-weight: 600; }
.login-footer a:hover { color: var(--green-700); }

@media (max-width: 1024px) {
    .login-hero { display: none; }
    .login-form-side { width: 100%; }
}

/* ── TABLES ─────────────────────────────── */
.data-table { width: 100%; border-collapse: collapse; }
.data-table th { text-align: left; padding: 10px 16px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); border-bottom: 2px solid var(--border); }
.data-table td { padding: 12px 16px; font-size: 13px; border-bottom: 1px solid #f4f4f5; }
.data-table tbody tr { transition: background 0.1s; }
.data-table tbody tr:hover { background: #fafafa; }

/* ── STATUS BADGES ──────────────────────── */
.badge-status { font-size: 11px; font-weight: 600; padding: 3px 10px; border-radius: 6px; display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.badge-status::before { content: ''; width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.badge-active, .badge-green { background: rgba(76,175,80,0.1); color: #2e7d32; }
.badge-active::before, .badge-green::before { background: #4CAF50; }
.badge-draft, .badge-gray { background: rgba(158,158,158,0.12); color: #616161; }
.badge-draft::before, .badge-gray::before { background: #9e9e9e; }
.badge-pending, .badge-orange { background: rgba(255,152,0,0.1); color: #e65100; }
.badge-pending::before, .badge-orange::before { background: #ff9800; }
.badge-expired, .badge-red, .badge-suspended { background: rgba(244,67,54,0.1); color: #c62828; }
.badge-expired::before, .badge-red::before, .badge-suspended::before { background: #f44336; }
.badge-passive, .badge-blue { background: rgba(33,150,243,0.1); color: #1565c0; }
.badge-passive::before, .badge-blue::before { background: #2196f3; }
.badge-vip { background: rgba(76,175,80,0.1); color: #2e7d32; font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 6px; }
.badge-category { font-size: 10.5px; font-weight: 600; padding: 3px 10px; border-radius: 6px; text-transform: capitalize; }
.badge-sponsor { background: rgba(76,175,80,0.1); color: #2e7d32; }
.badge-partner { background: rgba(33,150,243,0.1); color: #1565c0; }
.badge-supplier { background: rgba(255,152,0,0.1); color: #e65100; }
.badge-media { background: rgba(156,39,176,0.1); color: #7b1fa2; }
.badge-other { background: rgba(158,158,158,0.1); color: #616161; }

/* ── TABLE ACTIONS ──────────────────────── */
.table-actions { display: flex; gap: 4px; }
.table-actions .btn-icon { width: 32px; height: 32px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--border); background: var(--card); color: var(--text-secondary); font-size: 16px; cursor: pointer; transition: all 0.15s; text-decoration: none; }
.table-actions .btn-icon:hover { border-color: var(--green-400); color: var(--green-600); background: rgba(76,175,80,0.05); }
.table-actions .btn-icon.danger:hover { border-color: var(--red-400); color: var(--red-500); background: rgba(244,67,54,0.05); }

/* ── EMPTY STATE ────────────────────────── */
.empty-state { text-align: center; padding: 60px 20px; }
.empty-state-icon { font-size: 56px; color: var(--text-muted); opacity: 0.3; margin-bottom: 16px; }
.empty-state h3 { font-size: 18px; font-weight: 700; color: var(--text-primary); margin-bottom: 6px; }
.empty-state p { font-size: 13px; color: var(--text-muted); margin-bottom: 20px; max-width: 320px; margin-left: auto; margin-right: auto; }

/* ── FORM GRID ──────────────────────────── */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; }
.form-grid .form-group.full-width { grid-column: 1 / -1; }
.form-actions { display: flex; gap: 10px; padding-top: 12px; border-top: 1px solid var(--border); margin-top: 8px; }

/* ── DETAIL VIEW ────────────────────────── */
.detail-grid { display: grid; grid-template-columns: 2fr 1fr; gap: var(--gap); }
.detail-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #f4f4f5; }
.detail-row:last-child { border-bottom: none; }
.detail-label { font-size: 12px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.3px; }
.detail-value { font-size: 14px; font-weight: 600; color: var(--text-primary); text-align: right; }
.detail-value a { color: var(--green-500); text-decoration: none; }
.detail-value a:hover { color: var(--green-700); text-decoration: underline; }

/* ── MONEY FORMAT ───────────────────────── */
.money { font-family: var(--font-mono); font-weight: 500; font-size: 13px; }

/* ── TEAM CARDS ─────────────────────────── */
.team-card { text-align: center; padding: 28px 20px; }
.team-card .team-color-bar { height: 4px; border-radius: 2px; margin-bottom: 20px; }
.team-card .team-name { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.team-card .team-sport { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; justify-content: center; gap: 6px; }
.team-card .team-short { font-size: 11px; color: var(--text-muted); margin-top: 8px; font-weight: 600; text-transform: uppercase; letter-spacing: 1px; }

/* ── PACKAGE CARDS ──────────────────────── */
.package-card { padding: 28px; position: relative; overflow: hidden; }
.package-card .package-color { position: absolute; top: 0; left: 0; right: 0; height: 4px; }
.package-card .package-name { font-size: 18px; font-weight: 800; margin-bottom: 4px; }
.package-card .package-price { font-size: 32px; font-weight: 800; color: var(--green-600); font-family: var(--font-mono); }
.package-card .package-price span { font-size: 14px; color: var(--text-muted); font-weight: 500; font-family: var(--font); }
.package-card .package-desc { font-size: 13px; color: var(--text-secondary); margin-top: 8px; line-height: 1.5; }
.package-card .package-meta { margin-top: 16px; font-size: 12px; color: var(--text-muted); }

/* ── NAV SUB ACTIVE ─────────────────────── */
.nav-sub a.active { color: var(--green-400); font-weight: 600; }
.nav-sub a.active::before { background: var(--green-400); opacity: 1; }

/* ── ONBOARDING ─────────────────────────── */
.onboarding-banner { background: linear-gradient(135deg, #1b5e20, #2e7d32); border-radius: var(--card-radius); padding: 28px 32px; color: #fff; margin-bottom: var(--gap); position: relative; overflow: hidden; }
.onboarding-close { position: absolute; top: 12px; right: 12px; width: 28px; height: 28px; border-radius: 50%; background: rgba(255,255,255,0.15); border: none; color: rgba(255,255,255,0.7); cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 16px; }
.onboarding-close:hover { background: rgba(255,255,255,0.25); }
.onboarding-icon { font-size: 32px; margin-bottom: 8px; }
.onboarding-banner h3 { font-size: 20px; font-weight: 800; margin-bottom: 6px; }
.onboarding-banner > p { font-size: 14px; opacity: 0.8; margin-bottom: 20px; }
.onboarding-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.onboarding-step { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: rgba(255,255,255,0.1); border-radius: 10px; text-decoration: none; color: #fff; transition: all 0.15s; }
.onboarding-step:hover { background: rgba(255,255,255,0.2); transform: translateY(-2px); }
.step-number { width: 28px; height: 28px; border-radius: 50%; background: rgba(255,255,255,0.2); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; flex-shrink: 0; }
.step-title { font-size: 13px; font-weight: 700; }
.step-desc { font-size: 11px; opacity: 0.7; margin-top: 2px; }
.onboarding-step > i { margin-left: auto; opacity: 0.5; }
@media (max-width: 1200px) { .onboarding-steps { grid-template-columns: repeat(2, 1fr); } }

/* ── ANIMATIONS ─────────────────────────── */
@keyframes slideUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.card { animation: slideUp 0.5s ease both; }
.grid-4 .card:nth-child(1) { animation-delay: 0.05s; }
.grid-4 .card:nth-child(2) { animation-delay: 0.1s; }
.grid-4 .card:nth-child(3) { animation-delay: 0.15s; }
.grid-4 .card:nth-child(4) { animation-delay: 0.2s; }
.grid-2 .card:nth-child(1) { animation-delay: 0.25s; }
.grid-2 .card:nth-child(2) { animation-delay: 0.3s; }
.grid-3 .card:nth-child(1) { animation-delay: 0.35s; }
.grid-3 .card:nth-child(2) { animation-delay: 0.4s; }
.grid-3 .card:nth-child(3) { animation-delay: 0.45s; }

/* ── SCROLLBAR ──────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #d0d0d0; border-radius: 3px; }

/* ── MOBILE TOGGLE ──────────────────────── */
.sidebar-toggle { display: none; width: 40px; height: 40px; border: none; background: none; color: var(--text-secondary); font-size: 24px; cursor: pointer; border-radius: 8px; align-items: center; justify-content: center; transition: all 0.15s; flex-shrink: 0; }
.sidebar-toggle:hover { background: var(--bg); color: var(--text-primary); }
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 99; opacity: 0; transition: opacity 0.3s; }
.sidebar-overlay.active { opacity: 1; }

/* ── TABLE SCROLL WRAPPER ──────────────── */
.table-responsive { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ── RESPONSIVE: TABLET ────────────────── */
@media (max-width: 1200px) {
    .grid-5 { grid-template-columns: repeat(3, 1fr); }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: 1fr; }
    .grid-2 { grid-template-columns: 1fr; }
}

/* ── RESPONSIVE: MOBILE ────────────────── */
@media (max-width: 768px) {
    :root { --page-padding: 16px; --gap: 16px; }

    /* Sidebar: Off-Canvas Drawer */
    .sidebar { transform: translateX(-100%); transition: transform 0.3s cubic-bezier(0.4,0,0.2,1); z-index: 200; }
    .sidebar.open { transform: translateX(0); box-shadow: 4px 0 24px rgba(0,0,0,0.3); }
    .sidebar-overlay { display: block; pointer-events: none; }
    .sidebar-overlay.active { pointer-events: auto; }
    .sidebar-toggle { display: flex; }

    /* Main: volle Breite */
    .main { margin-left: 0; }

    /* Topbar */
    .topbar { padding: 0 12px; gap: 8px; height: 56px; }
    .topbar-search { max-width: none; flex: 1; padding: 8px 12px; }
    .topbar-search kbd { display: none; }
    .topbar-divider { display: none; }
    .topbar-user .user-info { display: none; }
    .topbar-user .avatar { width: 32px; height: 32px; font-size: 12px; }
    .topbar-btn { width: 36px; height: 36px; font-size: 18px; }

    /* Page Header */
    .page-header { flex-direction: column; align-items: flex-start; gap: 12px; }
    .page-header h1 { font-size: 18px; }
    .header-actions { width: 100%; }
    .header-actions .btn { flex: 1; justify-content: center; font-size: 12px; padding: 8px 12px; }

    /* Grids */
    .grid-5, .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }

    /* KPI Cards kompakter */
    .kpi-card .kpi-value { font-size: 22px; }
    .kpi-card .kpi-bg { font-size: 60px; }
    .kpi-card .card-body { padding: 16px; }

    /* Cards */
    .card { border-radius: 10px; }
    .card:hover { transform: none; box-shadow: var(--card-shadow); }
    .card-header { padding: 14px 16px 0; }
    .card-body { padding: 12px 16px 16px; }

    /* Tabellen */
    .data-table { min-width: 600px; }
    .table-responsive { margin: 0 -16px; padding: 0 16px; }

    /* Detail-Grid */
    .detail-grid { grid-template-columns: 1fr; }
    .detail-row { flex-direction: column; gap: 4px; align-items: flex-start; }
    .detail-value { text-align: left; }

    /* Formulare */
    .form-grid { grid-template-columns: 1fr; }
    .form-actions { flex-wrap: wrap; }
    .form-actions .btn { flex: 1; min-width: 120px; justify-content: center; }

    /* Buttons größere Touch-Targets */
    .btn { padding: 10px 16px; min-height: 44px; }
    .btn-sm { padding: 8px 12px; min-height: 36px; }
    .table-actions .btn-icon { width: 36px; height: 36px; }

    /* Kanban: horizontal scrollen */
    .kanban-preview { flex-direction: column; }
    .kanban-col { min-width: 100%; }

    /* Task Kanban (mit Inline-Styles) */
    [style*="min-width: 260px"] { min-width: 100% !important; }

    /* Pipeline */
    .pipeline-header { flex-direction: column; gap: 8px; }

    /* Listen */
    .list-item { gap: 10px; padding: 12px 0; }

    /* Alerts */
    .alert { font-size: 12px; padding: 10px 12px; }

    /* Login */
    .login-form-side { padding: 24px; }
    .login-welcome h2 { font-size: 22px; }

    /* Onboarding */
    .onboarding-banner { padding: 20px; }
    .onboarding-steps { grid-template-columns: 1fr; }
    .onboarding-banner h3 { font-size: 16px; }

    /* Breadcrumbs */
    .breadcrumbs { font-size: 11px; margin-bottom: 8px; }

    /* Package Cards */
    .package-card .package-price { font-size: 24px; }

    /* Team Cards */
    .team-card { padding: 20px 16px; }

    /* Sponsor Portal */
    .sp-grid { grid-template-columns: 1fr !important; }
    .sp-info-grid { grid-template-columns: 1fr !important; }
    .sp-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }

    /* Chat Layout */
    .chat-layout { grid-template-columns: 1fr !important; }
    .chat-sidebar { display: none; }
    .chat-sidebar.active { display: block; position: fixed; inset: 0; z-index: 150; background: var(--card); }

    /* Kalender */
    .cal-grid-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .cal-grid { min-width: 500px; }

    /* Template Builder */
    .tb-blocks-panel, .tb-properties-panel { position: fixed; z-index: 150; }

    /* Help FAB + Chatbot FAB: nicht übereinander */
    .help-fab { bottom: 16px; right: 16px; width: 44px; height: 44px; font-size: 20px; }
    .chatbot-fab { bottom: 16px; left: 16px; width: 44px; height: 44px; font-size: 22px; }

    /* Admin SA Grid */
    .sa-detail-grid { grid-template-columns: 1fr !important; }

    /* Money Formatierung */
    .money { font-size: 12px; }

    /* Inline-Style Grid Overrides */
    [style*="grid-template-columns: 320px"] { grid-template-columns: 1fr !important; }
    [style*="grid-template-columns: 1fr 1fr"] { grid-template-columns: 1fr !important; }
    [style*="min-width: 800px"] { min-width: 100% !important; }
    [style*="min-width: 140px"] { min-width: auto !important; }
}

/* ── RESPONSIVE: SMALL MOBILE ──────────── */
@media (max-width: 400px) {
    .topbar-search { display: none; }
    .topbar-search.active { display: flex; position: absolute; left: 8px; right: 8px; top: 8px; z-index: 51; }
    .topbar-right { margin-left: auto; }
    .kpi-card .kpi-value { font-size: 18px; }
    .page-header h1 { font-size: 16px; }
    .header-actions { flex-direction: column; }
    .header-actions .btn { width: 100%; }
}

/* ── BREADCRUMBS ────────────────────── */
.breadcrumbs { display: flex; align-items: center; gap: 4px; font-size: 12px; color: var(--text-muted); margin-bottom: 12px; flex-wrap: wrap; }
.breadcrumbs a { color: var(--text-muted); text-decoration: none; transition: color 0.15s; }
.breadcrumbs a:hover { color: var(--green-500); }
.breadcrumbs .bc-sep { font-size: 14px; opacity: 0.4; }
.breadcrumbs .bc-current { color: var(--text-secondary); font-weight: 600; }

/* ── LAST MODIFIED ──────────────────── */
.last-modified { font-size: 11px; color: var(--text-muted); display: flex; align-items: center; gap: 4px; margin-top: 16px; padding-top: 12px; border-top: 1px solid #f0f0f0; }

/* ── PRINT ──────────────────────────── */
@media print {
    .sidebar, .topbar, .help-fab, .chatbot-fab, .chatbot-window, .help-panel, .help-overlay, .btn, .header-actions, .form-actions, .table-actions, .breadcrumbs { display: none !important; }
    .main { margin-left: 0 !important; }
    .content { padding: 0 !important; }
    .card { box-shadow: none !important; border: 1px solid #ddd !important; break-inside: avoid; }
    .card:hover { transform: none !important; box-shadow: none !important; }
    .kpi-card { border-top-width: 2px !important; }
    body { background: #fff !important; font-size: 12px; }
    .page-header h1 { font-size: 18px; }
    a { color: inherit !important; text-decoration: none !important; }
    .data-table { font-size: 11px; }
}
