/* * Plugin Main Stylesheet (BST Tracker)
 * النسخة المطورة (المرحلة الثانية): شريط التقدم، التنبيهات اللحظية، والسحب والإفلات.
 */

:root {
    --bst-primary: #007cba;
    --bst-primary-dark: #006799;
    --bst-success: #2e7d32;
    --bst-error: #d32f2f;
    --bst-warning: #ffa000;
    --bst-bg: #f8f9fa;
    --bst-border: #ddd;
    --bst-radius: 8px;
    --bst-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* تنسيق عام للحاوية */
.bst-wrapper {
    width: 100%;
    max-width: 1100px;
    margin: 20px auto;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    direction: rtl;
}

/* --- [جديد] شريط تقدم الطلب (Visual Progress Bar) --- */
.bst-progress-wrapper {
    margin: 30px 0;
    padding: 20px;
    background: #fff;
    border-radius: var(--bst-radius);
    box-shadow: var(--bst-shadow);
}

.bst-progress-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin-bottom: 10px;
}

.bst-progress-steps::before {
    content: "";
    position: absolute;
    top: 15px;
    right: 0;
    left: 0;
    height: 4px;
    background: #e0e0e0;
    z-index: 1;
}

.bst-step {
    position: relative;
    z-index: 2;
    text-align: center;
    flex: 1;
}

.bst-step-icon {
    width: 35px;
    height: 35px;
    background: #fff;
    border: 3px solid #e0e0e0;
    border-radius: 50%;
    display: block;
    margin: 0 auto 10px;
    transition: 0.4s;
}

.bst-step.active .bst-step-icon {
    border-color: var(--bst-primary);
    background: var(--bst-primary);
    box-shadow: 0 0 10px rgba(0, 124, 186, 0.4);
}

.bst-step.completed .bst-step-icon {
    border-color: var(--bst-success);
    background: var(--bst-success);
}

.bst-step-label {
    font-size: 13px;
    font-weight: 600;
    color: #888;
}

.bst-step.active .bst-step-label { color: var(--bst-primary); }
.bst-step.completed .bst-step-label { color: var(--bst-success); }

/* --- [جديد] منطقة السحب والإفلات (Drag & Drop) --- */
.bst-dropzone {
    border: 2px dashed var(--bst-border);
    padding: 30px;
    text-align: center;
    border-radius: var(--bst-radius);
    background: #fafafa;
    transition: 0.3s;
    cursor: pointer;
    margin-top: 10px;
}

.bst-dropzone:hover, .bst-dropzone.dragover {
    border-color: var(--bst-primary);
    background: rgba(0, 124, 186, 0.05);
}

.bst-dropzone i { font-size: 40px; color: #ccc; display: block; margin-bottom: 10px; }

/* --- [جديد] التنبيهات اللحظية (Toast Notifications) --- */
#bst-toast-container {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 9999;
}

.bst-toast {
    background: #333;
    color: #fff;
    padding: 12px 25px;
    border-radius: 50px;
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--bst-shadow);
    animation: slideInLeft 0.3s ease-out;
}

.bst-toast.success { background: var(--bst-success); }
.bst-toast.error { background: var(--bst-error); }

@keyframes slideInLeft {
    from { transform: translateX(-100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* كروت الإحصائيات */
.bst-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.bst-stat-card {
    background: #fff;
    padding: 20px;
    border-radius: var(--bst-radius);
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    border-right: 5px solid var(--bst-primary);
    text-align: center;
}

.bst-stat-card h3 { margin: 0; color: #666; font-size: 14px; }
.bst-stat-card .bst-count { font-size: 28px; font-weight: bold; color: var(--bst-primary); display: block; margin-top: 10px; }

/* تنسيق النماذج */
.bst-form {
    background: #fff;
    padding: 30px;
    border-radius: var(--bst-radius);
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    margin-bottom: 30px;
}

.bst-field { margin-bottom: 20px; }
.bst-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

.bst-field input[type="text"],
.bst-field input[type="tel"],
.bst-field select,
.bst-field textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--bst-border);
    border-radius: 6px;
    font-size: 15px;
    transition: all 0.3s ease;
}

/* الأزرار */
.bst-button {
    background-color: var(--bst-primary);
    color: #fff;
    padding: 14px 30px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    width: 100%;
    transition: 0.3s;
}

.bst-button:hover { background-color: var(--bst-primary-dark); transform: translateY(-1px); }

/* الجداول المتطورة */
.bst-table-container { overflow-x: auto; background: #fff; border-radius: var(--bst-radius); box-shadow: 0 2px 10px rgba(0,0,0,0.05); }
.bst-table { width: 100%; border-collapse: collapse; }
.bst-table th { background: #f4f7f9; color: #444; font-weight: 600; padding: 15px; border-bottom: 2px solid #eee; text-align: right; }
.bst-table td { padding: 15px; border-bottom: 1px solid #f0f0f0; vertical-align: middle; }

/* الحالات الملونة */
.bst-status {
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 700;
    display: inline-block;
}
.bst-status-new { background: #e3f2fd; color: #1976d2; }
.bst-status-processing { background: #fff3e0; color: #ef6c00; }
.bst-status-done { background: #e8f5e9; color: #2e7d32; }
.bst-status-rejected { background: #ffebee; color: #c62828; }

/* التصميم المتجاوب للهواتف */
@media (max-width: 768px) {
    .bst-progress-steps { flex-direction: column; gap: 20px; align-items: flex-start; }
    .bst-progress-steps::before { display: none; }
    .bst-step { display: flex; align-items: center; gap: 15px; }
    .bst-step-icon { margin: 0; }
    .bst-table th:nth-child(n+4), .bst-table td:nth-child(n+4) { display: none; }
}