
        :root {
            --primary: #25d39b;
            --primary-dark: #1fb983;
            --bg: #091018;
            --card-bg: #111c28;
            --text-main: #eef6ff;
            --text-dim: #8da1b7;
            --border: #26384b;
            --accent-blue: #5aa8ff;
            --accent-purple: #b98aff;
            --glass: rgba(255, 255, 255, 0.03);
            --panel-2: #162332;
        }

        * {
            box-sizing: border-box;
            transition: all 0.2s ease;
        }

        body {
            font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
            background-color: var(--bg);
            color: var(--text-main);
            margin: 0;
            display: flex;
            min-height: 100vh;
            overflow-x: hidden;
            background-image: radial-gradient(circle at 15% -15%, #18344b 0, transparent 36%), radial-gradient(circle at 90% 90%, rgba(37, 211, 155, 0.04) 0%, transparent 40%);
        }

        /* Sidebar */
        aside {
            width: 260px;
            background: linear-gradient(180deg, #101b27 0%, #0a121b 100%);
            border-right: 1px solid var(--border);
            padding: 30px 20px;
            display: flex;
            flex-direction: column;
            position: fixed;
            height: 100vh;
            z-index: 100;
        }

        .logo {
            font-weight: 800;
            font-size: 20px;
            margin-bottom: 40px;
            display: flex;
            align-items: center;
            gap: 10px;
            color: var(--primary);
        }

        .logo span { color: white; }

        nav { display: flex; flex-direction: column; gap: 8px; }

        .nav-item {
            padding: 12px 16px;
            border-radius: 12px;
            cursor: pointer;
            display: flex;
            align-items: center;
            gap: 12px;
            font-weight: 500;
            color: var(--text-dim);
            text-decoration: none;
        }

        .nav-item:hover {
            background: var(--glass);
            color: white;
        }

        .nav-item.active {
            color: #eef6ff;
            background: rgba(37, 211, 155, 0.11);
            box-shadow: inset 3px 0 var(--primary);
        }

        /* Main Content */
        main {
            flex: 1;
            margin-left: 260px;
            padding: 40px;
            max-width: 1400px;
        }

        header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 40px;
        }

        .welcome h1 {
            font-size: 26px;
            margin: 0;
        }

        .welcome p { color: var(--text-dim); margin-top: 5px; }

        .status-badge {
            background: rgba(0, 255, 163, 0.1);
            color: var(--primary);
            padding: 8px 16px;
            border-radius: 100px;
            font-size: 14px;
            font-weight: 600;
            display: flex;
            align-items: center;
            gap: 8px;
            border: 1px solid rgba(0, 255, 163, 0.2);
        }

        .status-dot {
            width: 8px;
            height: 8px;
            background: var(--primary);
            border-radius: 50%;
            box-shadow: 0 0 10px var(--primary);
            animation: pulse 2s infinite;
        }

        @keyframes pulse {
            0% { opacity: 1; transform: scale(1); }
            50% { opacity: 0.5; transform: scale(1.2); }
            100% { opacity: 1; transform: scale(1); }
        }

        /* Grid */
        .grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 24px;
            margin-bottom: 40px;
        }

        .card {
            background: linear-gradient(145deg, rgba(22, 35, 50, 0.95), rgba(14, 24, 34, 0.95));
            border: 1px solid var(--border);
            border-radius: 14px;
            padding: 24px;
            position: relative;
            overflow: hidden;
        }

        .card::before {
            content: '';
            position: absolute;
            top: 0; left: 0; right: 0;
            height: 2px;
            background: linear-gradient(90deg, transparent, var(--primary), transparent);
            opacity: 0.3;
        }

        /* Encabezado de sección (estilo appbar CRM) */
        .eyebrow {
            margin: 0 0 3px;
            color: var(--text-dim);
            text-transform: uppercase;
            letter-spacing: .9px;
            font-size: 10px;
            font-weight: 700;
        }
        .eyebrow span { color: var(--primary); }

        .card h3 {
            margin: 0 0 20px 0;
            font-size: 16px;
            display: flex;
            align-items: center;
            gap: 10px;
        }

        /* Forms */
        .form-group { margin-bottom: 20px; }
        label { display: block; margin-bottom: 8px; color: var(--text-dim); font-size: 14px; }
        
        input, textarea, select {
            width: 100%;
            background: rgba(15, 23, 42, 0.5);
            border: 1px solid var(--border);
            border-radius: 12px;
            padding: 12px 16px;
            color: white;
            font-family: inherit;
            outline: none;
        }

        input:focus, textarea:focus {
            border-color: var(--primary);
            box-shadow: 0 0 0 2px rgba(0, 255, 163, 0.1);
        }

        textarea { height: 400px; resize: vertical; line-height: 1.6; }

        .btn {
            background: var(--primary);
            color: #0f172a;
            border: none;
            padding: 12px 24px;
            border-radius: 12px;
            font-weight: 700;
            cursor: pointer;
            display: inline-flex;
            align-items: center;
            gap: 8px;
        }

        .btn:hover { background: var(--primary-dark); transform: translateY(-2px); }
        .btn-secondary { background: var(--glass); color: white; }
        .btn-secondary:hover { background: rgba(255, 255, 255, 0.1); }

        /* Tables */
        table { width: 100%; border-collapse: collapse; }
        th { text-align: left; color: var(--text-dim); font-size: 12px; text-transform: uppercase; padding: 12px; border-bottom: 1px solid var(--border); }
        td { padding: 16px 12px; border-bottom: 1px solid var(--border); font-size: 14px; }
        tr:hover { background: var(--glass); }

        /* Tabs */
        .tab-content { display: none; animation: fadeIn 0.4s ease; }
        .tab-content.active { display: block; }

        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(10px); }
            to { opacity: 1; transform: translateY(0); }
        }

        /* Scrollbar */
        ::-webkit-scrollbar { width: 8px; }
        ::-webkit-scrollbar-track { background: var(--bg); }
        ::-webkit-scrollbar-thumb { background: var(--border); border-radius: 10px; }
        ::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

        /* Stats */
        .stat-val { font-size: 27px; font-weight: 800; }
        .stat-label { color: var(--text-dim); font-size: 14px; }

        /* Logs */
        .log-container {
            background: #000;
            border-radius: 12px;
            padding: 15px;
            font-family: 'Courier New', Courier, monospace;
            font-size: 13px;
            height: 300px;
            overflow-y: auto;
            border: 1px solid var(--border);
            color: #00ff88;
        }
        .log-container a {
            color: #38bdf8;
            text-decoration: underline;
            cursor: pointer;
        }
        .log-container a:hover {
            color: #fff;
        }
        .log-line { margin-bottom: 5px; opacity: 0.9; }
        .log-time { color: #888; margin-right: 10px; }

        /* Wizard Styles */
        #wizardOverlay {
            position: fixed; top: 0; left: 0; width: 100%; height: 100%;
            background: rgba(15, 23, 42, 0.95);
            z-index: 10000;
            display: flex; align-items: center; justify-content: center;
            backdrop-filter: blur(10px);
        }
        .wizard-card {
            background: #1e293b;
            border: 1px solid var(--primary);
            border-radius: 20px;
            width: 90%; max-width: 500px;
            padding: 40px;
            box-shadow: 0 20px 50px rgba(0,0,0,0.5);
            text-align: center;
            animation: scaleUp 0.3s ease;
        }
        @keyframes scaleUp { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
        .wizard-step { display: none; }
        .wizard-step.active { display: block; }
        .step-num { color: var(--primary); font-size: 14px; font-weight: 800; text-transform: uppercase; margin-bottom: 10px; display: block; }
        .wizard-title { font-size: 24px; font-weight: 700; margin-bottom: 15px; }
        .wizard-desc { color: var(--text-dim); font-size: 15px; margin-bottom: 25px; line-height: 1.6; }
        .wizard-progress { display: flex; gap: 8px; justify-content: center; margin-top: 30px; }
        .progress-dot { width: 8px; height: 8px; border-radius: 50%; background: #334155; }
        .progress-dot.active { background: var(--primary); box-shadow: 0 0 10px var(--primary); }

    