/* ======================================
   MANGO DIAMOND STORE - ADMIN STYLES
   Centralized CSS for all admin pages
   ====================================== */

:root {
    --primary-color: var(--primary, #6366f1);
    --accent-color: var(--accent, #10b981);
    --danger-color: #ff6b6b;
    --border-radius: var(--radius-xl, 1rem);
    --spacing-xxl: var(--spacing-2xl, 3rem);
}

body.admin-page {
    min-height: 100vh;
}

.admin-page .main-wrapper {
    padding-bottom: var(--spacing-2xl);
}

.admin-page .main-content {
    padding: var(--spacing-xl) 0 var(--spacing-2xl);
}

/* ======================================
   BASE ADMIN STYLES
   ====================================== */

/* Admin Container */
.admin-container {
    min-height: 100vh;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    color: white;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Generic Admin Card */
.admin-card {
    background: rgb(20, 20, 35);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    border: 1px solid rgba(99, 102, 241, 0.5);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

/* ======================================
   LOGIN PAGE STYLES
   ====================================== */

.login-container {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-xl) var(--spacing-md);
}

.login-card {
    width: 100%;
    max-width: 450px;
    padding: var(--spacing-xxl);
    text-align: left;
}

.login-header {
    margin-bottom: var(--spacing-xl);
    text-align: center;
}

.login-logo {
    margin-bottom: var(--spacing-lg);
}

.admin-icon {
    font-size: 4rem;
    display: inline-block;
    animation: float 3s ease-in-out infinite;
}

.login-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: var(--spacing-sm);
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.login-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin: 0;
}

.login-subtitle + .form-group {
    margin-top: var(--spacing-xl);
}

/* ======================================
   ALERT STYLES
   ====================================== */

.alert {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    margin-bottom: var(--spacing-lg);
    font-weight: 500;
    animation: slideIn 0.3s ease;
}

.alert-error {
    background: rgba(255, 107, 107, 0.1);
    border: 1px solid rgba(255, 107, 107, 0.3);
    color: #ff6b6b;
}

.alert-success {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #4CAF50;
}

.alert-warning {
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    color: #ffc107;
}

.alert-info {
    background: rgba(33, 150, 243, 0.1);
    border: 1px solid rgba(33, 150, 243, 0.3);
    color: #2196f3;
}

/* ======================================
   FORM STYLES
   ====================================== */

.login-form,
.setup-form,
.admin-form {
    text-align: left;
    margin-bottom: var(--spacing-xl);
}

.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-label {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--text-primary);
}

.label-icon {
    font-size: 1.1rem;
}

.form-input {
    width: 100%;
    padding: var(--spacing-md);
    border: 2px solid rgba(99, 102, 241, 0.5);
    border-radius: var(--border-radius);
    background: rgb(15, 15, 30);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgb(25, 25, 45);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.4);
}

.form-input::placeholder {
    color: var(--text-muted);
}

/* Password Field */
.password-field {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: var(--spacing-md);
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1.2rem;
    padding: var(--spacing-xs);
    transition: color 0.3s ease;
}

.password-toggle:hover {
    color: var(--text-primary);
}

/* ======================================
   BUTTON STYLES
   ====================================== */

.btn {
    padding: var(--spacing-md) var(--spacing-lg);
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: 0.9rem;
    justify-content: center;
}

.btn-lg {
    padding: var(--spacing-md) var(--spacing-lg);
    font-size: 1.1rem;
}

.btn-sm {
    padding: var(--spacing-xs) var(--spacing-sm);
    font-size: 0.8rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(78, 205, 196, 0.3);
}

.btn-secondary {
    background: rgba(99, 102, 241, 0.5);
    color: var(--text-primary, #ffffff);
    border: 1px solid rgba(99, 102, 241, 0.7);
}

.btn-secondary:hover {
    background: rgba(99, 102, 241, 0.7);
    border-color: rgba(99, 102, 241, 0.9);
    transform: translateY(-1px);
}

.btn-danger {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.3);
}

.btn-success {
    background: linear-gradient(135deg, #4CAF50, #45a049);
    color: white;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(76, 175, 80, 0.3);
}

/* Special Buttons */
.login-btn,
.setup-btn {
    width: 100%;
    padding: var(--spacing-md) var(--spacing-lg);
    font-size: 1.1rem;
    font-weight: 600;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border: none;
    border-radius: var(--border-radius);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
}

.login-btn:hover,
.setup-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(78, 205, 196, 0.3);
}

.login-btn:active,
.setup-btn:active {
    transform: translateY(0);
}

/* ======================================
   ADMIN DASHBOARD STYLES
   ====================================== */

.admin-header {
    margin-bottom: var(--spacing-xl);
}

.admin-welcome {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-xl);
    gap: var(--spacing-lg);
}

.welcome-content {
    flex: 1;
}

.welcome-title {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 800;
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    color: var(--text-primary);
}

.admin-icon {
    font-size: 1.2em;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.welcome-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: var(--spacing-md);
}

.session-info {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    color: var(--text-muted);
    font-size: 0.9rem;
}

.session-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.session-divider {
    opacity: 0.5;
}

.admin-actions {
    display: flex;
    gap: var(--spacing-md);
}

/* Quick Actions */
.quick-actions {
    margin-bottom: var(--spacing-xl);
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-lg);
}

.action-card {
    padding: var(--spacing-xl);
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s ease;
    border: 1px solid rgba(99, 102, 241, 0.5);
    text-align: center;
    background: rgb(20, 20, 35);
}

.action-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(78, 205, 196, 0.15);
    border-color: rgba(78, 205, 196, 0.3);
}

.action-icon {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
    display: block;
}

.action-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
    color: var(--primary-color);
}

.action-description {
    color: var(--text-secondary);
    margin: 0;
}

/* ======================================
   SECTION STYLES
   ====================================== */

.price-management,
.recent-activity,
.create-admin-section,
.sql-section,
.complete-section {
    margin-bottom: var(--spacing-xl);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-xl) var(--spacing-xl) var(--spacing-lg);
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}

.section-description {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.packages-container,
.activity-list {
    padding: var(--spacing-lg);
}

/* ======================================
   SETUP PAGE STYLES
   ====================================== */

.setup-container {
    max-width: 800px;
    margin: 0 auto;
    padding: var(--spacing-xl) var(--spacing-md);
}

.setup-card {
    padding: var(--spacing-xxl);
}

.setup-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.setup-icon {
    font-size: 4rem;
    display: inline-block;
    animation: rotate 4s linear infinite;
}

.setup-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin: var(--spacing-lg) 0 var(--spacing-sm);
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.setup-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin: 0;
}

/* SQL Section */
.sql-block {
    margin-bottom: var(--spacing-lg);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.sql-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-md);
    background: rgba(20, 20, 35, 0.9);
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.sql-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
    color: var(--primary-color);
}

.copy-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: var(--accent-color);
    transform: translateY(-1px);
}

.sql-code {
    background: rgba(0, 0, 0, 0.2);
    color: #f8f8f2;
    padding: var(--spacing-lg);
    margin: 0;
    overflow-x: auto;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
}

.sql-actions {
    text-align: center;
    margin-top: var(--spacing-lg);
}

/* Complete Section */
.complete-section {
    text-align: center;
    padding: var(--spacing-xl);
}

.complete-icon {
    font-size: 4rem;
    margin-bottom: var(--spacing-lg);
    animation: bounce 2s infinite;
}

.complete-title {
    font-size: 2rem;
    font-weight: 700;
    color: #4CAF50;
    margin-bottom: var(--spacing-md);
}

.complete-description {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-xl);
    font-size: 1.1rem;
}

.complete-actions {
    display: flex;
    gap: var(--spacing-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* ======================================
   LOADING & EMPTY STATES
   ====================================== */

.loading-state {
    text-align: center;
    padding: var(--spacing-xxl);
    color: var(--text-secondary);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(78, 205, 196, 0.1);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto var(--spacing-md);
}

.empty-state {
    text-align: center;
    padding: var(--spacing-xxl);
    color: var(--text-secondary);
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
    opacity: 0.5;
}

/* ======================================
   FOOTER STYLES
   ====================================== */

.login-footer,
.setup-footer {
    border-top: 1px solid rgba(99, 102, 241, 0.2);
    padding-top: var(--spacing-lg);
    text-align: center;
    margin-top: var(--spacing-lg);
}

.security-notice {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: var(--spacing-md);
}

.back-links {
    display: flex;
    gap: var(--spacing-lg);
    justify-content: center;
    flex-wrap: wrap;
}

.back-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: var(--accent-color);
}

/* ======================================
   CREATE ADMIN STYLES
   ====================================== */

.create-admin-container {
    background: rgb(20, 20, 35);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    max-width: 500px;
    width: 100%;
    border: 1px solid rgba(99, 102, 241, 0.5);
    margin: 0 auto;
}

.create-admin-title {
    text-align: center;
    margin-bottom: 30px;
    color: #4ecdc4;
}

.create-admin-form {
    margin-bottom: 20px;
}

.create-admin-group {
    margin-bottom: 20px;
}

.create-admin-label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

.create-admin-input {
    width: 100%;
    padding: 12px;
    border: 2px solid rgba(99, 102, 241, 0.5);
    border-radius: 8px;
    background: rgb(15, 15, 30);
    color: white;
    font-size: 16px;
    box-sizing: border-box;
}

.create-admin-input:focus {
    outline: none;
    border-color: #4ecdc4;
    background: rgb(25, 25, 45);
}

.create-admin-button {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #4ecdc4, #44a08d);
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.create-admin-button:hover {
    transform: translateY(-2px);
}

.create-admin-links {
    text-align: center;
    margin-top: 20px;
}

.create-admin-links a {
    color: #4ecdc4;
    text-decoration: none;
    margin: 0 10px;
}

.sql-section {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    font-family: monospace;
    font-size: 12px;
    overflow-x: auto;
}

.sql-title {
    color: #4ecdc4;
    margin-bottom: 10px;
    font-family: inherit;
}

/* ======================================
   ANIMATIONS
   ====================================== */

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-30px); }
    60% { transform: translateY(-15px); }
}

/* ======================================
   RESPONSIVE DESIGN
   ====================================== */

@media (max-width: 768px) {
    .login-container,
    .setup-container {
        padding: var(--spacing-lg) var(--spacing-sm);
    }
    
    .login-card,
    .setup-card {
        padding: var(--spacing-xl);
    }
    
    .login-title,
    .setup-title {
        font-size: 2rem;
    }
    
    .admin-welcome {
        flex-direction: column;
        text-align: center;
        gap: var(--spacing-md);
    }
    
    .session-info {
        flex-direction: column;
        gap: var(--spacing-xs);
    }
    
    .session-divider {
        display: none;
    }
    
    .actions-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        gap: var(--spacing-md);
        text-align: center;
    }
    
    .complete-actions,
    .back-links {
        flex-direction: column;
    }
    
    .sql-header {
        flex-direction: column;
        gap: var(--spacing-sm);
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .form-input,
    .create-admin-input {
        font-size: 16px; /* Prevent zoom on mobile */
    }
}

/* ======================================
   ORDER STATUS UI STYLES
   ====================================== */

.order-status-container {
    max-width: 600px;
    margin: 0 auto;
    animation: fadeInUp 0.8s ease-out;
}

.order-status-form {
    margin-bottom: var(--spacing-lg);
}

.order-status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.status-option {
    background: rgba(20, 20, 35, 0.9);
    border-radius: 15px;
    padding: 20px 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.status-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.3), transparent);
    transition: left 0.5s;
}

.status-option:hover::before {
    left: 100%;
}

.status-option:hover {
    transform: translateY(-3px) scale(1.05);
    border-color: rgba(99, 102, 241, 0.5);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.status-option.selected {
    border-color: var(--primary-color);
    background: rgba(78, 205, 196, 0.2);
    transform: scale(1.05);
}

.status-icon {
    font-size: 2rem;
    margin-bottom: 10px;
}

.status-label {
    font-size: 1rem;
    font-weight: 600;
}

.order-status-submit {
    width: 100%;
    padding: 18px;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    border: none;
    border-radius: 15px;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.order-status-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, var(--accent-color), var(--primary-color));
    transition: left 0.3s ease;
    z-index: -1;
}

.order-status-submit:hover::before {
    left: 0;
}

.order-status-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(68, 160, 141, 0.4);
}

.order-status-submit:active {
    transform: translateY(0);
}

.order-details {
    background: rgba(20, 20, 35, 0.9);
    border-radius: 15px;
    padding: 20px;
    margin-top: 20px;
    display: none;
}

.order-details.show {
    display: block;
    animation: fadeInUp 0.5s ease-out;
}

.order-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.order-detail-row:last-child {
    border-bottom: none;
}

.order-detail-label {
    font-weight: 600;
    opacity: 0.8;
}

.order-detail-value {
    font-weight: 500;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    max-width: 350px;
}

.toast {
    background: rgb(20, 20, 35);
    backdrop-filter: blur(15px);
    border-radius: 15px;
    border: 1px solid rgba(99, 102, 241, 0.6);
    padding: 15px 20px;
    margin-bottom: 10px;
    color: #ffffff;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
    transform: translateX(400px);
    animation: slideIn 0.3s ease-out forwards;
    position: relative;
    overflow: hidden;
}

.toast::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
}
.brand-section {
    margin-bottom: var(--spacing-2xl);
    text-align: center;
}

.brand-logo {
    max-width: 500px;
    margin: 0 auto;
}

.logo-image {
    width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .brand-logo {
        max-width: 400px;
    }
}

@media (max-width: 480px) {
    .brand-logo {
        max-width: 300px;
    }
}
.toast.success::before {
    background: linear-gradient(45deg, #4CAF50, #45a049);
}

.toast.error::before {
    background: linear-gradient(45deg, #ff6b6b, #e74c3c);
}

.toast.warning::before {
    background: linear-gradient(45deg, #ffc107, #ff9800);
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toast-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

.toast-message {
    flex: 1;
    font-size: 0.9rem;
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.toast-close:hover {
    background: rgba(99, 102, 241, 0.2);
    color: #ffffff;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

.toast.removing {
    animation: slideOut 0.3s ease-in forwards;
}

/* ======================================
   RECENT ACTIVITY TABLE STYLES
   ====================================== */

.recent-activity {
    margin-top: 2rem;
}

.activity-list {
    max-height: 500px;
    overflow-y: auto;
}

.table-container {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    overflow-x: auto; /* Allow horizontal scroll on very small screens */
}

/* Ensure parent containers take full width */
.orders-section,
.orders-section .glass-card,
.container {
    width: 100%;
    max-width: none;
}

.main-content {
    width: 100%;
}

.main-content .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md, 1rem);
}

/* Specific styles for orders table section */
.orders-section {
    margin-bottom: var(--spacing-xl, 2rem);
}

.orders-section .glass-card {
    background: rgba(20, 20, 35, 0.9);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.activity-table {
    width: 100%;
    border-collapse: collapse;
    background: rgb(20, 20, 35);
    backdrop-filter: blur(10px);
}

.activity-table thead {
    background: rgba(99, 102, 241, 0.15);
    border-bottom: 2px solid rgba(99, 102, 241, 0.3);
}

.activity-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.activity-table tbody tr {
    border-bottom: 1px solid rgba(99, 102, 241, 0.3);
    transition: all 0.3s ease;
    background: rgb(20, 20, 35);
}

.activity-table tbody tr:hover {
    background: rgba(99, 102, 241, 0.15);
    transform: translateY(-1px);
}

.activity-table td {
    padding: 1rem;
    vertical-align: middle;
}

.admin-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.admin-icon {
    font-size: 1.2rem;
}

.admin-name {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

.action-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    background: rgba(139, 69, 19, 0.2);
    color: var(--primary-color);
    border: 1px solid rgba(139, 69, 19, 0.3);
}

.action-badge.action-login {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border-color: rgba(34, 197, 94, 0.3);
}

.action-badge.action-logout {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.3);
}

.action-badge.action-admin_panel_access {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
    border-color: rgba(59, 130, 246, 0.3);
}

.action-badge.action-order_status_update {
    background: rgba(168, 85, 247, 0.2);
    color: #a855f7;
    border-color: rgba(168, 85, 247, 0.3);
}

.details-text {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    max-width: 200px;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.time-text {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
    font-family: 'Courier New', monospace;
}

.ip-text {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    font-family: 'Courier New', monospace;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
}

/* Column widths */
.col-admin { width: 15%; }
.col-action { width: 20%; }
.col-details { width: 30%; }
.col-time { width: 20%; }
.col-ip { width: 15%; }

/* Responsive design for activity table */
@media (max-width: 768px) {
    .activity-table {
        font-size: 0.8rem;
    }
    
    .activity-table th,
    .activity-table td {
        padding: 0.5rem;
    }
    
    .col-details { 
        width: 25%; 
    }
    
    .details-text {
        max-width: 120px;
    }
    
    .admin-name {
        display: none;
    }
    
    .time-text,
    .ip-text {
        font-size: 0.75rem;
    }
}

/* ======================================
   MODAL STYLES
   ====================================== */

.modal {
    display: none !important;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: flex !important;
}

.modal-content {
    background: linear-gradient(135deg, rgb(20, 20, 35), rgb(25, 25, 45));
    border-radius: 15px;
    border: 1px solid rgba(99, 102, 241, 0.6);
    backdrop-filter: blur(20px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideInScale 0.3s ease;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.modal-header h3 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.3rem;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(99, 102, 241, 0.2);
    color: white;
}

.modal-form {
    padding: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.modal-form .form-group {
    margin-bottom: 1rem;
}

.modal-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

.modal-form input[type="text"],
.modal-form input[type="number"] {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid rgba(99, 102, 241, 0.5);
    border-radius: 8px;
    background: rgb(15, 15, 30);
    color: white;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.modal-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.1);
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    position: relative;
}

.checkbox-label input[type="checkbox"] {
    opacity: 0;
    position: absolute;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(99, 102, 241, 0.4);
    border-radius: 4px;
    position: relative;
    transition: all 0.3s ease;
    background: rgba(15, 15, 30, 0.9);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 0.9rem;
    font-weight: bold;
}

.checkbox-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    user-select: none;
    cursor: pointer;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    padding-top: 1rem;
    border-top: 1px solid rgba(99, 102, 241, 0.2);
    margin-top: 1rem;
}

.delete-modal .modal-content {
    max-width: 450px;
}

.modal-body {
    padding: 1.5rem;
}

.modal-body p {
    margin: 0 0 1rem 0;
    color: rgba(255, 255, 255, 0.9);
}

.warning-text {
    color: #ff6b6b !important;
    font-weight: 500;
    text-align: center;
}

.package-info {
    background: rgba(20, 20, 35, 0.9);
    border-radius: 8px;
    padding: 1rem;
    margin: 1rem 0;
}

.package-preview {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
}

.package-preview strong {
    font-size: 1.1rem;
    color: var(--primary-color);
}

.promo-badge {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Package Card Improvements */
.package-card {
    background: rgb(20, 20, 35);
    border: 1px solid rgba(99, 102, 241, 0.5);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.package-card:hover {
    background: rgba(30, 30, 50, 0.95);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    border-color: rgba(99, 102, 241, 0.4);
}

.package-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.package-header h3 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.package-price {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--accent-color);
}

.package-details {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-sm) 0;
    border-bottom: 1px solid rgba(99, 102, 241, 0.1);
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-item .detail-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.detail-item .detail-value {
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1rem;
}

.detail-item .detail-value.highlight {
    color: var(--accent-color);
    font-size: 1.1rem;
}

.package-actions {
    display: flex;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-md);
    border-top: 1px solid rgba(99, 102, 241, 0.2);
}

.promo-label {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

.package-status {
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

.package-status.active {
    background: rgba(76, 175, 80, 0.2);
    color: #4CAF50;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.package-status.inactive {
    background: rgba(158, 158, 158, 0.2);
    color: #9e9e9e;
    border: 1px solid rgba(158, 158, 158, 0.3);
}

.package-actions {
    display: flex;
    gap: 0.5rem;
}

/* Order Cards Grid Layout */
.orders-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 1.5rem;
    padding: 1rem;
}

.order-card {
    background: rgb(20, 20, 35);
    border: 1px solid rgba(99, 102, 241, 0.5);
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.order-card:hover {
    background: rgba(30, 30, 50, 0.95);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    border-color: rgba(99, 102, 241, 0.4);
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.order-header h4 {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.order-status {
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: capitalize;
}

.status-pending {
    background: rgba(255, 193, 7, 0.2);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.status-processing {
    background: rgba(33, 150, 243, 0.2);
    color: #2196f3;
    border: 1px solid rgba(33, 150, 243, 0.3);
}

.status-completed {
    background: rgba(76, 175, 80, 0.2);
    color: #4CAF50;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.status-cancelled {
    background: rgba(244, 67, 54, 0.2);
    color: #f44336;
    border: 1px solid rgba(244, 67, 54, 0.3);
}

.order-details {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.order-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.order-detail-label {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.order-detail-value {
    color: white;
    font-weight: 500;
}

/* Pagination Styles */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.pagination-btn {
    background: rgba(20, 20, 35, 0.9);
    border: 1px solid rgba(99, 102, 241, 0.2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pagination-btn:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: rgba(99, 102, 241, 0.4);
    transform: translateY(-1px);
}

.pagination-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

/* Orders Table Styles */
.orders-table {
    width: 100%;
    border-collapse: collapse;
    background: rgb(20, 20, 35);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.orders-table thead {
    background: rgba(99, 102, 241, 0.15);
    border-bottom: 2px solid rgba(99, 102, 241, 0.3);
}

.orders-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.orders-table tbody tr {
    border-bottom: 1px solid rgba(99, 102, 241, 0.3);
    transition: background-color 0.3s ease;
    background: rgb(20, 20, 35); /* Dark background for rows */
}

.orders-table tbody tr:nth-child(even) {
    background: rgb(25, 25, 45); /* Alternating darker rows */
}

.orders-table tbody tr:hover {
    background: rgba(99, 102, 241, 0.2); /* Highlight on hover */
}

.orders-table td {
    padding: 1rem;
    vertical-align: middle;
}

.order-id-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.order-icon {
    font-size: 1.1rem;
}

.order-number {
    font-family: monospace;
    font-weight: 700;
    color: var(--primary-color);
}

.customer-text, .game-id-text {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.diamonds-text {
    color: var(--accent-color);
    font-weight: 600;
}

.amount-text {
    color: #4CAF50;
    font-weight: 600;
    font-size: 1.05rem;
}

.order-status-badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: capitalize;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.order-status-badge.status-pending {
    background: rgba(255, 193, 7, 0.2);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.3);
}

.order-status-badge.status-processing {
    background: rgba(33, 150, 243, 0.2);
    color: #2196f3;
    border: 1px solid rgba(33, 150, 243, 0.3);
}

.order-status-badge.status-completed {
    background: rgba(76, 175, 80, 0.2);
    color: #4CAF50;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.order-status-badge.status-cancelled,
.order-status-badge.status-failed {
    background: rgba(244, 67, 54, 0.2);
    color: #f44336;
    border: 1px solid rgba(244, 67, 54, 0.3);
}

.date-text {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* Column widths for orders table */
.col-order-id { width: 12%; }
.col-customer { width: 18%; }
.col-game-id { width: 15%; }
.col-diamonds { width: 15%; }
.col-amount { width: 12%; }
.col-status { width: 15%; }
.col-date { width: 13%; }

@media (max-width: 768px) {
    .orders-table {
        font-size: 0.8rem;
    }
    
    .orders-table th,
    .orders-table td {
        padding: 0.75rem 0.5rem;
    }
    
    /* Hide less important columns on mobile */
    .col-game-id,
    .game-id-cell {
        display: none;
    }
    
    .col-date,
    .date-cell {
        display: none;
    }
    
    /* Adjust remaining column widths */
    .col-order-id { width: 15%; }
    .col-customer { width: 25%; }
    .col-diamonds { width: 20%; }
    .col-amount { width: 15%; }
    .col-status { width: 25%; }
    
    .order-number {
        font-size: 0.9rem;
    }
    
    .order-status-badge {
        padding: 0.3rem 0.6rem;
        font-size: 0.75rem;
    }
    
    /* Mobile pagination styles */
    .pagination {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .pagination-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
        min-width: auto;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInScale {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
} 