    :root {
        --primary: #4361ee;
        --primary-light: #4895ef;
        --success: #06d6a0;
        --danger: #ef476f;
        --warning: #ffd166;
        --dark: #121826;
        --light: #f8f9fa;
        --gray-800: #343a40;
    }

    body {
        font-family: 'Cairo', sans-serif;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        min-height: 100vh;
        transition: all 0.3s ease;
    }

    body.light-mode {
        background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
        color: #e2e8f0;
    }

    .navbar {
        background: rgba(0,0,0,0.15) !important;
        backdrop-filter: blur(10px);
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }

    .main-container {
        margin-top: 80px;
    }

    .card {
        background: rgba(255, 255, 255, 0.15);
        backdrop-filter: blur(16px);
        border: 1px solid rgba(255, 255, 255, 0.2);
        border-radius: 1.5rem;
        box-shadow: 0 20px 40px rgba(0,0,0,0.1);
        overflow: hidden;
    }

    body.light-mode .card {
        background: rgba(30, 41, 59, 0.85);
        backdrop-filter: blur(16px);
        border: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 20px 40px rgba(0,0,0,0.3);
        color: #e2e8f0;
    }

    .nav-tabs .nav-link {
        border: none;
        border-radius: 12px 12px 0 0;
        padding: 1rem 2rem;
        font-weight: 600;
        color: #fff;
    }

    body.light-mode .nav-tabs .nav-link {
        color: #e2e8f0;
        background: rgba(30, 41, 59, 0.5);
        text-shadow: 0 1px 2px rgba(0,0,0,0.3);
    }

    .nav-tabs .nav-link.active {
        background: var(--primary) !important;
        color: white !important;
    }

    /* ===== شكل الـ inputs والـ selects داخل الـ input-group ===== */

    .input-group-text,
    .input-group .form-control,
    .input-group .form-select {
        height: 52px;
        border-radius: 999px;
        background: rgba(255,255,255,0.12);
        border: 1px solid rgba(255,255,255,0.35);
        color: #fff;
        font-size: 0.95rem;
    }

    /* padding مناسب جوّه الليبل والإنبوت */
    .input-group-text {
        padding-inline: 1rem 1.25rem;
        display: flex;
        align-items: center;
        gap: 0.4rem; /* مسافة بين الأيقونة والنص */
        background: rgba(255,255,255,0.18);
        border-inline-end: none; /* علشان seam بين الليبل والإنبوت يبقى ناعم */
    }

    .input-group .form-control,
    .input-group .form-select {
        padding-inline: 1.25rem;
        border-inline-start: none;
    }

    /* في الوضع الفاتح */
    body.light-mode .input-group-text,
    body.light-mode .input-group .form-control,
    body.light-mode .input-group .form-select {
        background: rgba(30, 41, 59, 0.8);
        color: #e2e8f0;
        border-color: rgba(255,255,255,0.15);
        font-weight: 500;
    }

    body.light-mode .input-group-text {
        background: rgba(51, 65, 85, 0.8);
    }

    /* مسافة زيادة بين الأيقونة والنص */
    .input-group-text i {
        margin-left: 0.35rem;
        font-size: 0.95rem;
    }

    body.light-mode .input-group-text i {
        color: #94a3b8;
    }

    /* placeholder */
    .form-control::placeholder {
        color: rgba(255,255,255,0.7);
    }
    body.light-mode .form-control::placeholder {
        color: rgba(203, 213, 225, 0.7);
    }

    /* لما الـ input يكون disabled بس لونه يبقى شيك */
    .form-control:disabled,
    .form-select:disabled,
    .disabled-input {
        background: rgba(0,0,0,0.25) !important;
        color: rgba(255,255,255,0.65) !important;
        border-color: rgba(255,255,255,0.25) !important;
        cursor: not-allowed;
    }

    body.light-mode .form-control:disabled,
    body.light-mode .form-select:disabled,
    body.light-mode .disabled-input {
        background: rgba(15, 23, 42, 0.5) !important;
        color: rgba(203, 213, 225, 0.5) !important;
        border-color: rgba(255,255,255,0.1) !important;
    }

    #scriptContent {
        background: #1e1e1e;
        color: #d4d4d4;
        border-radius: 12px;
        font-family: 'Courier New', monospace;
        direction: ltr;
        text-align: left;
    }

    body.light-mode #scriptContent {
        background: #0f172a;
        color: #cbd5e1;
        border: 1px solid rgba(255,255,255,0.1);
    }

    .btn-primary {
        background: var(--primary);
        border: none;
        border-radius: 50px;
        padding: 0.75rem 2rem;
        font-weight: 600;
    }

    .sidebar-tool {
        background: rgba(255,255,255,0.1);
        border-radius: 16px;
        padding: 1.5rem;
        transition: all 0.3s ease;
        cursor: pointer;
    }

    .sidebar-tool:hover {
        transform: translateY(-5px);
        background: rgba(255,255,255,0.2);
    }

    body.light-mode .sidebar-tool {
        background: rgba(30, 41, 59, 0.7);
        border: 1px solid rgba(255,255,255,0.1);
        color: #e2e8f0;
    }

    body.light-mode .sidebar-tool:hover {
        background: rgba(51, 65, 85, 0.8);
        border-color: rgba(255,255,255,0.2);
    }

    .theme-toggle {
        width: 60px;
        height: 30px;
        background: #333;
        border-radius: 50px;
        position: relative;
        cursor: pointer;
    }

    .theme-toggle::after {
        content: '';
        position: absolute;
        top: 3px;
        right: 3px;
        width: 24px;
        height: 24px;
        background: white;
        border-radius: 50%;
        transition: 0.3s;
    }

    body.light-mode .theme-toggle {
        background: #334155;
        border: 1px solid rgba(255,255,255,0.1);
    }

    body.light-mode .theme-toggle::after {
        background: #cbd5e1;
        right: auto;
        left: 3px;
    }

		/* توحيد ارتفاع / شكل خانات الفورم */
		.input-group .input-group-text,
		.input-group .form-control,
		.input-group .form-select {
			height: 52px;
			align-items: center;
	}

		/* تأكيد إن خانات أسماء الواي فاي تاخد نفس العرض */
		#wifiRow .input-group {
			width: 100%;
	}

    /* عشان الـ options متبقاش أبيض على أبيض */
    select.form-select option {
        color: #333;
        background: #ffffff;
    }

    body.light-mode select.form-select option {
        color: #f1f5f9;
        background: #1e293b;
    }

    @media (max-width: 768px) {
        .main-container {
            margin-top: 20px;
        }
        .sidebar {
            margin-top: 2rem;
        }
    }
	
/* أزرار موحّدة للواجهة */
.btn-mikro {
    border-radius: 999px;
    font-weight: 600;
    padding: 0.85rem 2.6rem;
    font-size: 1.1rem;
    border-width: 1.5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem; /* مسافة بين الأيقونة والنص */
    transition: all 0.2s ease-in-out;
}

/* زر إنشاء السكربت (أزرق) */
.btn-mikro-primary {
    background: #2563eb;
    border-color: #2563eb;
    color: #ffffff;
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.35);
}
.btn-mikro-primary:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;
    transform: translateY(-1px);
}

/* زر إعادة تعيين (محدد فقط) */
.btn-mikro-outline-light {
    background: transparent;
    border-color: rgba(255,255,255,0.9);
    color: #ffffff;
}
.btn-mikro-outline-light:hover {
    background: rgba(255,255,255,0.12);
    transform: translateY(-1px);
}

/* زر تحميل RSC (أخضر) */
.btn-mikro-success {
    background: #16a34a;
    border-color: #16a34a;
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(22, 163, 74, 0.35);
}
.btn-mikro-success:hover {
    background: #15803d;
    border-color: #15803d;
    transform: translateY(-1px);
}

/* زر نسخ السكربت (إطار أزرق فاتح) */
.btn-mikro-outline-blue {
    background: transparent;
    border-color: #2563eb;
    color: #2563eb;
}
.btn-mikro-outline-blue:hover {
    background: rgba(37,99,235,0.12);
    transform: translateY(-1px);
}

/* علشان الأزرار اللي تحت تكون أصغر سنة من اللي فوق */
.btn-mikro-sm {
    padding: 0.55rem 1.8rem;
    font-size: 1rem;
}

/* دعم اللايت مود للأزرار */
body.light-mode .btn-mikro-outline-light {
    border-color: rgba(226, 232, 240, 0.8);
    color: #e2e8f0;
}
body.light-mode .btn-mikro-outline-light:hover {
    background: rgba(226, 232, 240, 0.15);
}

body.light-mode .btn-mikro-outline-blue {
    border-color: #60a5fa;
    color: #60a5fa;
    background: transparent;
}
body.light-mode .btn-mikro-outline-blue:hover {
    background: rgba(96, 165, 250, 0.15);
}
/* نفس الشكل للإتنين */
/* الشكل العام للسكريبت في الوضع الداكن (الافتراضي) */
.script-box {
  background: #050b12;              /* نفس اللون اللي عاجبك في توزيع */
  color: #f8fafc;
  font-family: "JetBrains Mono", "Cairo", monospace;
  font-size: 14px;
  line-height: 1.6;
  direction: ltr;
  white-space: pre;
  overflow-x: auto;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

html, body {
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* مهم جداً */
}

/* الحاوية الأساسية لكل المحتوى ماعدا الفوتر */
.page-wrapper {
    flex: 1; /* يمد الصفحة لتحت */
    display: flex;
    flex-direction: column;
}
.main-container {
    padding-bottom: 40px; /* مسافة خفيفة تحت */
}

.dark-mode .script-box {
    background: #0f1624;
    color: #d7e2ff;
    border: 1px solid rgba(255,255,255,0.08);
}

.light-mode .script-box {
    background: #f4f6fb;
    color: #1a1a1a;
    border: 1px solid #d3d9e5;
}
.script-box {
    background: #0b1220 !important;
    color: #e2e8f0 !important;
    border: none !important;
    box-shadow: none !important;
	border-radius: 12px;
}

