


.custom-editor-container {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    display: flex;
    flex-direction: column;
}
.custom-editor-toolbar {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 8px;
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    align-items: center;
}
.custom-editor-toolbar button {
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #334155;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
}
.custom-editor-toolbar button:hover {
    background: #e2e8f0;
}
.custom-editor-toolbar button.btn-ai-assist {
    background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%);
    color: white;
    border: none;
    margin-left: auto;
    padding: 4px 12px;
    height: 30px;
}
.custom-editor-toolbar button.btn-ai-assist:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #5b21b6 100%);
}
.custom-editor-content {
    padding: 15px;
    min-height: 300px;
    max-height: 600px;
    overflow-y: auto;
    outline: none;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #334155;
}
.custom-editor-content::after { content: ""; display: table; clear: both; }
.custom-editor-content p { margin-bottom: 1em; }
.custom-editor-content h2, .custom-editor-content h3 { margin-top: 1.5em; margin-bottom: 0.5em; color: #0f172a; }
.custom-editor-content ul, .custom-editor-content ol { margin-bottom: 1em; padding-left: 20px; }
.custom-editor-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 10px; cursor: pointer; transition: outline 0.2s; }
.custom-editor-content img:hover { outline: 2px dashed #8b5cf6; }


.btn-ai-assist {
    background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%);
    color: white;
    border: none;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    box-shadow: 0 2px 10px rgba(139, 92, 246, 0.3);
}
.btn-ai-assist:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
}
.btn-ai-assist:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}


.calendar-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
}
.cal-header {
    text-align: center;
    font-weight: bold;
    padding: 10px;
    background: #f8fafc;
    border-radius: 4px;
    color: #64748b;
}
.cal-day {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    min-height: 100px;
    padding: 10px;
    position: relative;
    cursor: pointer;
    transition: all 0.2s;
}
.cal-day:hover {
    border-color: var(--color-primary);
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}
.cal-day.empty {
    background: transparent;
    border: none;
    cursor: default;
}
.cal-day.full {
    background: #fef2f2;
    border-color: #fecaca;
}
.day-num {
    font-weight: bold;
    font-size: 1.1rem;
    margin-bottom: 5px;
}
.day-stats {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    margin-bottom: 5px;
}
.stat-booked {
    background: #dbeafe;
    color: #1e40af;
    font-size: 0.75rem;
    padding: 2px 6px;
    border-radius: 4px;
}
.stat-blocked {
    background: #fee2e2;
    color: #991b1b;
    font-size: 0.75rem;
    padding: 2px 6px;
    border-radius: 4px;
}
.day-avail {
    font-size: 0.8rem;
    color: #64748b;
    position: absolute;
    bottom: 10px;
    right: 10px;
}
.cal-day.full .day-avail {
    color: #ef4444;
    font-weight: bold;
}
.mobile-day-name { display: none; }

@media (max-width: 768px) {
    .calendar-grid { display: flex; flex-direction: column; gap: 15px; }
    .cal-header { display: none; }
    .cal-day.empty { display: none; }
    .cal-day { min-height: auto; padding: 15px; display: flex; flex-direction: column; }
    .day-num { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #f1f5f9; padding-bottom: 8px; margin-bottom: 10px; }
    .mobile-day-name { display: inline-block; color: var(--color-primary); font-weight: 600; }
    .day-avail { position: static; margin-top: 10px; text-align: right; background: #f8fafc; padding: 5px 10px; border-radius: 4px; }
}


.stat-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    border: 1px solid #e2e8f0;
}
.stat-label { font-size: 0.85rem; color: #64748b; text-transform: uppercase; letter-spacing: 0.5px; font-weight: 600; }
.stat-value { font-size: 2rem; font-weight: 800; color: #0f172a; margin: 5px 0; }
.stat-trend { font-size: 0.8rem; color: #10b981; display: flex; align-items: center; gap: 4px; }
.stat-trend.trend-down { color: #ef4444; }

.package-card { margin-bottom: 20px; overflow: hidden; }
.package-header { padding: 15px 20px; background: white; border-bottom: 1px solid #f1f5f9; display: flex; justify-content: space-between; align-items: center; cursor: pointer; transition: background 0.2s; }
.package-header:hover { background: #f8fafc; }
.package-icon { width: 40px; height: 40px; background: #f1f5f9; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; }
.package-title { font-weight: 700; color: #0f172a; font-size: 1.05rem; }
.package-meta { font-size: 0.85rem; color: #64748b; margin-top: 2px; }
.package-body { padding: 0; background: #f8fafc; border-top: 1px solid #e2e8f0; }

.task-item { background: white; padding: 15px; border-bottom: 1px solid #e2e8f0; display: flex; justify-content: space-between; align-items: flex-start; gap: 15px; border-left: 4px solid transparent; transition: all 0.2s; }
.task-item:last-child { border-bottom: none; }
.task-item:hover { background: #fff; transform: translateX(5px); }
.task-done { opacity: 0.6; background: #f9fafb; }
.task-done .task-title { text-decoration: line-through; color: #94a3b8; }
.task-top-row { display: flex; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.task-title { font-weight: 600; color: #334155; margin-bottom: 4px; }
.task-desc { font-size: 0.9rem; color: #64748b; margin-bottom: 8px; line-height: 1.4; }
.time-widget { background: #f1f5f9; padding: 6px 10px; border-radius: 6px; margin-top: 8px; width: fit-content; min-width: 200px; }
.progress-bar-bg { height: 6px; background: #e2e8f0; border-radius: 3px; overflow: hidden; }
.progress-bar-fill { height: 100%; border-radius: 3px; }


.config-item-card { cursor: pointer; transition: transform 0.2s; border-radius: 16px; overflow: hidden; border: 1px solid #e2e8f0; }
.config-item-card:hover { transform: translateY(-5px); box-shadow: 0 10px 15px -3px rgba(0,0,0,0.1); }
.config-item-card.selected { border: 2px solid var(--color-accent); transform: scale(0.98); }
.config-item-card.disabled { opacity: 0.5; cursor: not-allowed; filter: grayscale(1); }
.config-item-card.unavailable { pointer-events: none; }
.config-item-card.unavailable .unavailable-overlay { display: flex; }
.config-item-card.unavailable img { filter: grayscale(1); opacity: 0.5; }
.check-overlay { position: absolute; inset: 0; background: rgba(212, 175, 55, 0.8); display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s; }
.config-item-card.selected .check-overlay { opacity: 1; }
.unavailable-overlay { position: absolute; inset: 0; background: rgba(255,255,255,0.85); z-index: 5; display: none; align-items: center; justify-content: center; flex-direction: column; text-align: center; padding: 10px; }


.gallery-grid-container { display: flex; gap: 15px; flex-wrap: wrap; margin-top: 20px; }
.gallery-item-wrapper { position: relative; width: 120px; height: 120px; box-shadow: 0 2px 4px rgba(0,0,0,0.1); border-radius: 8px; }
.gallery-img-preview { width: 100%; height: 100%; object-fit: cover; border-radius: 8px; }
.btn-delete-absolute { position: absolute; top: -8px; right: -8px; background: #ef4444; color: white; border-radius: 50%; width: 24px; height: 24px; text-align: center; line-height: 24px; font-size: 14px; text-decoration: none; box-shadow: 0 2px 4px rgba(0,0,0,0.2); }



@media (min-width: 901px) {
    .admin-sidebar .nav-link .nav-icon {
        display: block !important; 
    }
    .admin-sidebar .nav-link {
        justify-content: flex-start; 
    }
}

.admin-mobile-menu-overlay .mobile-tile-icon {
    display: block !important;
}

.inbox-toolbar {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    align-items: center;
    flex-wrap: wrap;
    background: #f8fafc;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid var(--border);
}
.inbox-table {
    table-layout: fixed;
}
.inbox-row {
    cursor: pointer;
    transition: all 0.2s ease;
}
.inbox-row:hover {
    background: #f8fafc;
    transform: translateX(2px);
}
.inbox-row.unread {
    background: #f0f9ff;
}
.inbox-row.unread td {
    color: var(--primary);
}
.inbox-row.unread .sender-name,
.inbox-row.unread .msg-subject {
    font-weight: 700;
}
.inbox-row.read {
    background: #ffffff;
}
.inbox-row.read td {
    color: var(--text-muted);
}
.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: transparent;
    margin: 0 auto;
    transition: 0.3s;
}
.inbox-row.unread .status-dot {
    background: #3b82f6;
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.6);
}
.sender-name {
    font-size: 0.95rem;
    margin-bottom: 2px;
}
.sender-email {
    font-size: 0.8rem;
    color: #94a3b8;
}
.msg-subject {
    font-size: 0.95rem;
}
.msg-snippet {
    color: #94a3b8;
    font-size: 0.9rem;
}
.msg-date {
    font-size: 0.85rem;
    color: #64748b;
}
.inbox-actions {
    text-align: right;
}
.btn-delete-icon {
    color: #ef4444;
    text-decoration: none;
    padding: 8px;
    border-radius: 6px;
    transition: 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 0.5;
}
.inbox-row:hover .btn-delete-icon {
    opacity: 1;
}
.btn-delete-icon:hover {
    background: #fee2e2;
    color: #b91c1c;
}


.msg-meta-box {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #f8fafc;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid var(--border);
}
.meta-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent) 0%, #b5952f 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    box-shadow: 0 2px 5px rgba(212, 175, 55, 0.3);
}
.meta-details {
    flex: 1;
}
.meta-sender {
    font-size: 1.05rem;
    color: var(--primary);
    margin-bottom: 3px;
}
.meta-email {
    color: #64748b;
    font-size: 0.9rem;
    text-decoration: none;
}
.meta-email:hover {
    text-decoration: underline;
}
.meta-date {
    font-size: 0.85rem;
    color: #94a3b8;
}
.msg-body-content {
    font-size: 1rem;
    line-height: 1.7;
    color: #334155;
    padding: 10px 5px;
    min-height: 150px;
}

@media (max-width: 768px) {
    .inbox-toolbar { flex-direction: column; align-items: stretch; }
    .inbox-toolbar .admin-select { width: 100% !important; }
    .inbox-table th:nth-child(4), .inbox-table td:nth-child(4) { display: none; } 
    .msg-snippet { display: none; } 
}

.admin-cropper-modal {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.85);
    z-index: 2147483647;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}
.admin-cropper-modal-content {
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    position: relative;
    z-index: 2147483647;
}
.admin-cropper-modal-header {
    padding: 15px 20px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    position: relative;
    z-index: 10;
}
.admin-cropper-modal-header h3 {
    margin: 0;
    font-size: 1.2rem;
    color: #0f172a;
}
.admin-cropper-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #64748b;
    transition: color 0.2s;
}
.admin-cropper-close:hover {
    color: #ef4444;
}
.admin-cropper-modal-body {
    padding: 20px;
    flex: 1;
    overflow: hidden;
    background: #e2e8f0;
    display: block; 
    position: relative;
}
.admin-cropper-modal-body .img-container {
    width: 100%;
    height: 60vh;
    display: block;
}
.admin-cropper-modal-body .img-container img {
    max-width: 100%;
    max-height: 100%;
    display: block;
    margin: 0 auto;
}
.admin-cropper-modal-footer {
    padding: 15px 20px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    background: #f8fafc;
    position: relative;
    z-index: 10;
}
/* Orders Table Mobile Fix */
@media (max-width: 768px) {
    .orders-table th, .orders-table td {
        white-space: normal !important;
        word-break: break-word;
    }
    .orders-table td:nth-child(3) {
        min-width: 120px;
    }
    .orders-table td:nth-child(4) {
        min-width: 140px;
    }
}