/* Admin Panel Styles */
/* Admin Login Modal Styles */
.admin-login-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 3000;
    align-items: center;
    justify-content: center;
}

.admin-login-content {
    background: white;
    border-radius: var(--radius);
    padding: 30px;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: var(--shadow);
}

.admin-password-input {
    width: 100%;
    padding: 12px;
    margin: 15px 0;
    border: 2px solid var(--light-gray);
    border-radius: var(--radius);
    font-size: 1rem;
}

.admin-login-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 20px;
}

.login-error {
    font-size: 0.9rem;
    font-weight: 500;
}
.admin-panel {
    position: fixed;
    top: 0;
    right: -400px;
    width: 400px;
    height: 100vh;
    background: white;
    box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    z-index: 2000;
    transition: right 0.3s ease;
    overflow-y: auto;
    padding: 20px;
}

.admin-panel.open {
    right: 0;
}

.admin-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray);
    transition: color 0.3s;
    padding: 8px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.admin-close:hover {
    color: var(--danger);
    background-color: rgba(220, 53, 69, 0.1);
}

.admin-toggle {
    position: fixed;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: var(--radius) 0 0 var(--radius);
    cursor: pointer;
    z-index: 1999;
}

.admin-tabs {
    display: flex;
    border-bottom: 1px solid var(--light-gray);
    margin-bottom: 20px;
}

.admin-tab {
    padding: 10px 15px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
}

.admin-tab.active {
    border-bottom-color: var(--primary);
    color: var(--primary);
    font-weight: 600;
}

.admin-tab-content {
    display: none;
}

.admin-tab-content.active {
    display: block;
}

.admin-form {
    margin-bottom: 20px;
}

.admin-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.admin-form input, 
.admin-form textarea, 
.admin-form select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    margin-bottom: 15px;
}

.admin-form textarea {
    min-height: 100px;
    resize: vertical;
}

.form-group {
    margin-bottom: 15px;
}

.btn {
    padding: 8px 16px;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
}

.btn-primary:hover {
    background-color: #ff5da2;
}

.btn-secondary {
    background-color: var(--secondary);
    color: white;
}

.btn-secondary:hover {
    background-color: #66b3ff;
}

.btn-success {
    background-color: var(--success);
    color: white;
}

.btn-warning {
    background-color: var(--warning);
    color: var(--dark);
}

.btn-danger {
    background-color: var(--danger);
    color: white;
}

.btn-small {
    padding: 5px 10px;
    font-size: 0.85rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: white;
    border-radius: var(--radius);
    padding: 15px;
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-card h3 {
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 8px;
}

.stat-card p {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary);
}

/* Charts */
.chart-container {
    background: white;
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.chart-title {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--dark);
}

/* Tables */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.admin-table th, 
.admin-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid var(--light-gray);
}

.admin-table th {
    background-color: var(--light);
    font-weight: 600;
}

.admin-table tr:hover {
    background-color: rgba(0,0,0,0.02);
}

/* Status badges */
.status-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-pending {
    background-color: var(--warning);
    color: var(--dark);
}

.status-processing {
    background-color: var(--secondary);
    color: white;
}

.status-completed {
    background-color: var(--success);
    color: white;
}

.status-cancelled {
    background-color: var(--danger);
    color: white;
}

@media (max-width: 768px) {
    .admin-panel {
        width: 100%;
        right: -100%;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
}


.admin-panel {
    position: fixed;
    top: 0;
    right: -50vw; 
    width: 50vw;   
    height: 100vh;
    background: white;
    box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    z-index: 2000;
    transition: right 0.3s ease;
    overflow-y: auto;
    padding: 20px;
}

.admin-close {
    position: sticky;
    top: 0;
    right: 0;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray);
    transition: color 0.3s;
    padding: 8px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: white; /* Optional: ensure it stands out on scroll */
    z-index: 10; /* Make sure it stays above other elements inside the panel */
}

