/* WiFi Auto Auth Dashboard - Custom Styles */

:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    
    --gradient-primary: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --gradient-success: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
    --gradient-danger: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    --gradient-info: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    
    --border-radius: 10px;
    --box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

/* Global Styles */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
}

/* Navigation Enhancements */
.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
}

.navbar-brand i {
    margin-right: 0.5rem;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Card Enhancements */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.card-header {
    background: var(--gradient-primary);
    color: white;
    border-bottom: none;
    padding: 1rem 1.5rem;
}

.card-header h5 {
    margin: 0;
    font-weight: 600;
}

.card-body {
    padding: 1.5rem;
}

/* Statistics Cards */
.card.bg-primary {
    background: var(--gradient-primary) !important;
    border: none;
}

.card.bg-success {
    background: var(--gradient-success) !important;
    border: none;
}

.card.bg-danger {
    background: var(--gradient-danger) !important;
    border: none;
}

.card.bg-info {
    background: var(--gradient-info) !important;
    border: none;
}

.card .fs-1 {
    opacity: 0.8;
    transition: var(--transition);
}

.card:hover .fs-1 {
    opacity: 1;
    transform: scale(1.1);
}

/* Form Enhancements */
.form-control, .form-select {
    border-radius: var(--border-radius);
    border: 2px solid #e9ecef;
    transition: var(--transition);
    padding: 0.75rem 1rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.form-label {
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

/* Button Enhancements */
.btn {
    border-radius: var(--border-radius);
    font-weight: 600;
    padding: 0.5rem 1.5rem;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background: var(--gradient-primary);
    border: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
}

.btn-secondary:hover {
    transform: translateY(-2px);
}

.btn-outline-light:hover {
    transform: translateY(-2px);
}

/* Table Enhancements */
.table {
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-bottom: 0;
}

.table thead th {
    border-bottom: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.02);
}

.table-hover tbody tr:hover {
    background-color: rgba(102, 126, 234, 0.05);
    transform: scale(1.002);
}

/* Badge Enhancements */
.badge {
    border-radius: 20px;
    padding: 0.5em 0.8em;
    font-weight: 600;
    font-size: 0.75rem;
}

.badge.bg-success {
    background: var(--gradient-success) !important;
}

.badge.bg-danger {
    background: var(--gradient-danger) !important;
}

.badge.bg-primary {
    background: var(--gradient-primary) !important;
}

/* Alert Enhancements */
.alert {
    border: none;
    border-radius: var(--border-radius);
    padding: 1rem 1.5rem;
}

.alert-info {
    background: linear-gradient(135deg, rgba(23, 162, 184, 0.1) 0%, rgba(23, 162, 184, 0.05) 100%);
    color: #0c5460;
    border-left: 4px solid var(--info-color);
}

/* Chart Container Enhancements */
canvas {
    max-height: 400px !important;
}

.card .card-body canvas {
    background: rgba(255, 255, 255, 0.8);
    border-radius: var(--border-radius);
    padding: 1rem;
}

/* Code Styling */
code {
    background: rgba(102, 126, 234, 0.1);
    color: var(--primary-color);
    padding: 0.2em 0.4em;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 600;
}

/* Responsive Enhancements */
@media (max-width: 768px) {
    .card-body {
        padding: 1rem;
    }
    
    .table-responsive {
        border-radius: var(--border-radius);
    }
    
    .row.g-3 > * {
        margin-bottom: 1rem;
    }
    
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .d-flex.justify-content-between {
        flex-direction: column;
        align-items: flex-start !important;
    }
    
    .navbar-nav.ms-auto {
        margin-top: 1rem;
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

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

/* Utility Classes */
.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
}

.glass-effect {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.shadow-custom {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Dark Theme Support (Optional) */
@media (prefers-color-scheme: dark) {
    :root {
        --light-color: #1a1a1a;
        --dark-color: #f8f9fa;
    }
    
    body {
        background-color: #1a1a1a;
        color: #f8f9fa;
    }
    
    .card {
        background-color: #2d2d2d;
        color: #f8f9fa;
    }
    
    .table-striped tbody tr:nth-of-type(odd) {
        background-color: rgba(255, 255, 255, 0.05);
    }
    
    .form-control, .form-select {
        background-color: #2d2d2d;
        border-color: #404040;
        color: #f8f9fa;
    }
    
    .form-control:focus, .form-select:focus {
        background-color: #2d2d2d;
        color: #f8f9fa;
    }
}