/* requests.css - أنماط صفحة الطلبات */

/* ---------- الشريط العلوي ---------- */
.top-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 15px;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.app-name {
    font-size: 18px;
    font-weight: bold;
}

.header-icons {
    display: flex;
    gap: 10px;
}

.icon-btn {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    color: white;
    cursor: pointer;
    transition: all 0.3s;
}

.icon-btn:hover {
    background: rgba(255,255,255,0.3);
}

/* ---------- القائمة الجانبية ---------- */
.sidebar {
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100vh;
    background: white;
    box-shadow: -2px 0 10px rgba(0,0,0,0.1);
    z-index: 1001;
    transition: right 0.3s ease;
    overflow-y: auto;
}

.sidebar.open {
    right: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.sidebar-header h3 {
    font-size: 16px;
    color: #333;
}

.sidebar-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #666;
    cursor: pointer;
}

.sidebar-menu {
    list-style: none;
    padding: 10px 0;
}

.sidebar-menu li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    color: #333;
    text-decoration: none;
    transition: background 0.3s;
}

.sidebar-menu li a:hover,
.sidebar-menu li a.active {
    background: #f5f5f5;
    color: #667eea;
}

.sidebar-menu li a i {
    width: 20px;
    text-align: center;
}

.auth-sidebar-buttons {
    padding: 15px;
    border-top: 1px solid #eee;
}

/* ---------- المحتوى الرئيسي ---------- */
.requests-main {
    padding: 80px 15px 80px;
    min-height: 100vh;
    background: #f5f7fa;
}

/* ---------- قسم إضافة طلب ---------- */
.add-request-section {
    margin-bottom: 25px;
}

.add-request-section .btn {
    padding: 15px;
    font-size: 16px;
}

/* ---------- قسم الطلبات ---------- */
.requests-section {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.section-title {
    font-size: 18px;
    color: #333;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #667eea;
}

/* ---------- الحالة الفارغة ---------- */
.empty-state {
    text-align: center;
    padding: 50px 20px;
    color: #888;
}

.empty-state i {
    font-size: 60px;
    color: #ddd;
    margin-bottom: 15px;
}

.empty-state p {
    font-size: 18px;
    margin-bottom: 10px;
    color: #666;
}

.empty-state span {
    font-size: 14px;
}

/* ---------- قائمة الطلبات ---------- */
.requests-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.request-card {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    border-right: 4px solid #667eea;
}

.request-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.request-type {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: bold;
    color: #667eea;
}

.request-type i {
    font-size: 18px;
}

.request-date {
    font-size: 12px;
    color: #888;
}

.request-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 15px;
}

.request-detail {
    display: flex;
    flex-direction: column;
}

.request-detail-label {
    font-size: 12px;
    color: #888;
}

.request-detail-value {
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

.request-notes {
    background: white;
    padding: 10px;
    border-radius: 8px;
    font-size: 13px;
    color: #666;
    margin-top: 10px;
}

/* ---------- الشريط السفلي ---------- */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: white;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 8px 12px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s;
    position: relative;
}

.nav-item.active,
.nav-item:hover {
    color: #667eea;
}

.nav-icon {
    font-size: 18px;
}

.nav-text {
    font-size: 11px;
}

.notification-badge {
    position: absolute;
    top: 0;
    right: 5px;
    width: 18px;
    height: 18px;
    background: #e74c3c;
    color: white;
    border-radius: 50%;
    font-size: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ---------- المودالات ---------- */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    overflow-y: auto;
    padding: 20px;
}

.modal-content {
    background: white;
    border-radius: 15px;
    max-width: 500px;
    margin: 20px auto;
    padding: 20px;
    position: relative;
}

.modal-title {
    font-size: 18px;
    color: #333;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #667eea;
}

.close-btn {
    position: absolute;
    top: 15px;
    left: 15px;
    background: none;
    border: none;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    z-index: 10;
}

.close-btn:hover {
    color: #333;
}

/* ---------- نموذج الطلب ---------- */
#requestForm .form-group {
    margin-bottom: 15px;
}

#requestForm label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    color: #555;
}

#requestForm input,
#requestForm select,
#requestForm textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
}

#requestForm input:focus,
#requestForm select:focus,
#requestForm textarea:focus {
    outline: none;
    border-color: #667eea;
}

/* ---------- الوضع المظلم ---------- */
body.dark-mode {
    background-color: #1a1a2e;
    color: #fff;
}

body.dark-mode .top-header {
    background: linear-gradient(135deg, #2d2d44 0%, #3d3d5c 100%);
}

body.dark-mode .sidebar,
body.dark-mode .requests-section,
body.dark-mode .modal-content,
body.dark-mode .bottom-nav {
    background: #2d2d44;
    color: #fff;
}

body.dark-mode .section-title,
body.dark-mode .modal-title {
    color: #fff;
}

body.dark-mode .request-card {
    background: #3d3d5c;
}

body.dark-mode .request-detail-value {
    color: #fff;
}

body.dark-mode .request-notes {
    background: #2d2d44;
}

body.dark-mode .empty-state p {
    color: #aaa;
}

body.dark-mode .nav-item {
    color: #aaa;
}

body.dark-mode .nav-item.active,
body.dark-mode .nav-item:hover {
    color: #667eea;
}

body.dark-mode .sidebar-menu li a {
    color: #fff;
}

body.dark-mode .sidebar-menu li a:hover,
body.dark-mode .sidebar-menu li a.active {
    background: #3d3d5c;
}

body.dark-mode #requestForm input,
body.dark-mode #requestForm select,
body.dark-mode #requestForm textarea {
    background: #3d3d5c;
    color: #fff;
    border-color: #4d4d6c;
}
