﻿/* --- General Styles --- */
#back_circle {
    background-image: url(../../images/Background/logo.png);
    width: 48px;
    height: 49px;
    background-size: cover;
    background-position: center;
    border-radius: 15%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
    cursor: pointer;
    margin: 8px;
}

    #back_circle:hover {
        transform: scale(1.1);
    }

.login-header {
    display: flex;
    align-items: center;
    gap: 10px; /* مسافة بين الشعار والكلمة */
}


:root {
    --bg-color: #e6f0fa; /* خلفية فاتحة زرقاء فاتحة */
    --text-color: #0d3c75; /* نص أزرق داكن */
    --card-bg: #ffffff; /* خلفية الكروت أبيض */
    --btn-color: #0d3c75; /* لون الأزرار */
    --btn-text-color: #ffffff; /* لون نص الأزرار */
}

.dark-mode {
    --bg-color: #0d3c75; /* خلفية داكنة */
    --text-color: #ffffff; /* نص أبيض */
    --card-bg: #1e1e2a; /* كروت داكنة */
    --btn-color: #1a73e8;
    --btn-text-color: #ffffff;
}

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: all 0.3s ease;
}

.container_login {
    max-width: 400px;
    margin: 5% auto;
}

.card {
    background-color: var(--card-bg);
    padding: 20px;
    border-radius: 12px;
}

.login-title {
    font-size: 28px;
    margin-bottom: 20px;
    color: var(--text-color);
}

.ssl-img {
    width: 150px;
    cursor: pointer;
    position: fixed;
    bottom: 20px; /* تحت الشاشة */
    left: 20px; /* على اليسار */
    z-index: 100;
}

#sslPopup {
    border-radius: 12px;
    padding: 20px;
    width: 250px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.25);
    background-color: var(--card-bg);
    color: var(--text-color);
}

.intro {
    text-align: center;
    margin: 20px 0;
}

.btn {
    background-color: var(--btn-color);
    color: var(--btn-text-color);
    border-radius: 8px;
    transition: all 0.3s ease;
}

    .btn:hover {
        background-color: darken(var(--btn-color), 10%);
    }

@media screen and (max-width: 600px) {
    .container_login {
        margin: 10px;
    }

    .login-title {
        font-size: 22px;
    }

    .btn {
        font-size: 14px;
    }
}

/* Responsive Modals */
@media (max-width: 500px) {
    .modal-dialog {
        width: 90%;
        margin: auto;
    }

    .modal-body h3 {
        font-size: 16px;
    }

    .modal-footer button {
        width: 45%;
        font-size: 14px;
    }
}

/* Import this file في الصفحة أو داخل head */
.custom-confirm-modal .modal-content {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    background-color: #e8f5e9; /* أخضر فاتح */
}

.custom-confirm-modal .modal-header {
    background-color: #4CAF50;
    color: white;
    border-bottom: none;
    padding: 15px 20px;
    text-align: center;
}

.custom-confirm-modal .modal-body {
    padding: 20px;
    text-align: center;
}

    .custom-confirm-modal .modal-body i {
        font-size: 50px;
        color: #4CAF50;
        margin-top: 10px;
    }

.custom-confirm-modal .modal-footer {
    border-top: none;
    justify-content: center;
    padding: 15px;
}

.custom-confirm-modal .btn-confirm {
    background-color: #4CAF50;
    color: white;
    border-radius: 8px;
    width: 100px;
}


.modal {
    background-color: #fafafa00 !important;
    overflow-y: clip !important;
}

.modal-open .modal {
    overflow-x: hidden !important;
    overflow-y: clip !important;
}


.modal {
    box-shadow: none !important;
}

.intro {
    text-align: center;
    margin: 20px 0;
}

/* Simple, small, 3D text with light shadow */
.welcome-title {
    font-family: 'Roboto', sans-serif;
    font-size: 1.5rem; /* أصغر حجم */
    font-weight: 600; /* غامق قليلاً */
    color: #0d3c75; /* لون أزرق مناسب للـ ERP */
    text-shadow: 0px 1px 0px rgba(255,255,255,0.2), /* ضوء خفيف من فوق */
    0px 2px 4px rgba(0,0,0,0.2); /* ظل خفيف يعطي عمق 3D */
    text-decoration: none; /* يلغي أي خط تحت النص */
    letter-spacing: 0.5px;
}

/* Responsive */
@media screen and (max-width: 600px) {
    .welcome-title {
        font-size: 1.2rem;
    }
}

/* تصميم جذاب لاسم المستخدم */
.user-label {
    margin-bottom: 12px;
    text-align: center;
}

.logged-user {
    display: inline-block;
    padding: 10px 20px;
    font-weight: 600;
    font-size: 16px;
    color: #ffffff;
    background: linear-gradient(145deg, #0d3c7529, #1e90ffb8);
    border-radius: 12px;
    box-shadow: 0 6px 12px rgba(0,0,0,0.3); /* ظل خفيف 3D */
    text-shadow: 0 2px 4px rgba(0,0,0,0.4); /* نص 3D */
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    text-transform: uppercase; /* جميع الحروف كبيرة */
}

    /* تأثير عند التحويم على الاسم */
    .logged-user:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 20px rgba(0,0,0,0.4);
    }






/* ================================================= */
/*          MODERN MESSAGE SYSTEM (CLEAN)            */
/* ================================================= */

/* ===== Shared ===== */
.modern-message,
.modern-toast {
    background: transparent !important;
}

/* ===== Center Top Position ===== */
.modern-dialog,
.modern-toast-dialog {
    position: fixed;
    top: 32px;
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
}

/* ================================================= */
/*          TOAST (Without Click)                    */
/* ================================================= */

.modern-toast-dialog {
    max-width: 360px;
}

.modern-toast-content {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 18px 45px rgba(0,0,0,0.25);
    animation: toastIn 0.35s ease;
}

/* Toast Icon */
.toast-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 16px;
}

    .toast-icon.success {
        background: linear-gradient(135deg, #22c55e, #16a34a);
    }

/* Toast Text */
.modern-toast-content p {
    margin: 0;
    font-size: 17px;
    font-weight: 500;
    color: #1f2937;
    font-weight: bold;
    text-align: center;
}

/* ================================================= */
/*          MODAL WITH BUTTONS                       */
/* ================================================= */

.modern-dialog {
    max-width: 420px;
}

.modern-content {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 22px 55px rgba(0,0,0,0.3);
    overflow: hidden;
}

/* Header */
.modern-header {
    padding: 18px 20px 10px;
    text-align: center;
}

.modern-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 20px;
}

    .modern-icon.success {
        background: linear-gradient(135deg, #22c55e, #16a34a);
    }

.modern-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #111827;
}

/* Body */
.modern-body {
    padding: 10px 24px 20px;
    text-align: center;
}

    .modern-body p {
        margin: 0;
        font-size: 15px;
        color: #374151;
    }

/* Footer */
.modern-footer {
    display: flex;
    gap: 10px;
    justify-content: center;
    padding: 16px 20px 22px;
}

.modern-btn {
    min-width: 100px;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    border: none;
    cursor: pointer;
}

    .modern-btn.success {
        background: #22c55e;
        color: #ffffff;
    }

    .modern-btn.cancel {
        background: #e5e7eb;
        color: #374151;
    }

/* ================================================= */
/*          Animations                               */
/* ================================================= */

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateY(-12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===================================== */
/*   TOP-CENTER PERFECT POSITION         */
/* ===================================== */

.modern-toast-dialog {
    position: fixed;
    top: 90px; /* 👈 المسافة من فوق (عدّلها براحتك) */
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    max-width: 420px;
    z-index: 9999;
}

/* أنيميشن دخول شيك */
.modern-toast.fade .modern-toast-dialog {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
    transition: all 0.4s ease;
}

.modern-toast.fade.in .modern-toast-dialog {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
/* ===================================== */
/*   TOP CENTER (FINAL FIX 😂)            */
/* ===================================== */

.modern-dialog,
.modern-toast-dialog {
    position: fixed !important;
    top: 90px !important; /* 👈 فوق شوية */
    left: 50% !important; /* 👈 نص الشاشة أفقي */
    transform: translateX(-50%) !important;
    margin: 0 !important;
    z-index: 9999;
}
.modern-toast.fade .modern-toast-dialog,
.modern-message.fade .modern-dialog {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
    transition: all 0.4s ease;
}

.modern-toast.fade.in .modern-toast-dialog,
.modern-message.fade.in .modern-dialog {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
