/* MegaPortal Colorful Theme */

/* Body Base */
body.colorful-theme {
    background-color: #0f1020;
    color: #ffffff;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Animations */
@keyframes bg-shift {

    0%,
    100% {
        background-position: 0% 0%, 100% 0%, 0% 100%, 100% 100%, 0% 0%;
    }

    25% {
        background-position: 10% 10%, 90% 10%, 10% 90%, 90% 90%, 0% 0%;
    }

    50% {
        background-position: 20% 5%, 80% 15%, 15% 85%, 85% 80%, 0% 0%;
    }

    75% {
        background-position: 5% 15%, 95% 5%, 5% 95%, 95% 85%, 0% 0%;
    }
}

@keyframes pulse-glow {
    0% {
        opacity: 0.15;
        transform: scale(1) translate(0, 0);
    }

    50% {
        opacity: 0.25;
        transform: scale(1.1) translate(20px, 10px);
    }

    100% {
        opacity: 0.2;
        transform: scale(1.05) translate(-10px, 20px);
    }
}

@keyframes pulse-glow-2 {
    0% {
        opacity: 0.12;
        transform: scale(1) translate(0, 0);
    }

    50% {
        opacity: 0.2;
        transform: scale(1.15) translate(-20px, -10px);
    }

    100% {
        opacity: 0.15;
        transform: scale(1.08) translate(10px, -20px);
    }
}

/* Background Effects */
body.colorful-theme .main-content::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(ellipse at 20% 20%, rgba(147, 51, 234, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(236, 72, 153, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 40% 80%, rgba(37, 99, 235, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(6, 182, 212, 0.1) 0%, transparent 50%),
        linear-gradient(180deg, rgba(15, 16, 32, 0.8) 0%, rgba(15, 16, 32, 0.95) 100%);
    z-index: -1;
    pointer-events: none;
    animation: bg-shift 15s ease-in-out infinite;
}

body.colorful-theme::before {
    content: '';
    position: fixed;
    top: -15%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: #9333ea;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.2;
    z-index: -1;
    pointer-events: none;
    animation: pulse-glow 8s infinite alternate;
}

body.colorful-theme::after {
    content: '';
    position: fixed;
    bottom: -15%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: #2563eb;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.2;
    z-index: -1;
    pointer-events: none;
    animation: pulse-glow-2 10s infinite alternate;
}

/* Glassmorphism Utils */
.glass {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

.gradient-text {
    background: linear-gradient(135deg, #9333ea, #db2777);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Components - Card */
body.colorful-theme .card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    color: #ffffff;
    border-radius: 8px;
}

body.colorful-theme .card-header {
    background: transparent;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

/* Buttons */
body.colorful-theme .btn-primary {
    background: linear-gradient(135deg, #9333ea, #db2777);
    border: none;
    box-shadow: 0 4px 15px rgba(147, 51, 234, 0.4);
    transition: all 0.3s ease;
}

body.colorful-theme .btn-primary:hover {
    filter: brightness(1.15);
    box-shadow: 0 6px 20px rgba(147, 51, 234, 0.6);
    transform: translateY(-2px);
}

body.colorful-theme .btn-success {
    background: linear-gradient(135deg, #16a34a, #84cc16);
    border: none;
    box-shadow: 0 4px 15px rgba(22, 163, 74, 0.4);
}

body.colorful-theme .btn-danger {
    background: linear-gradient(135deg, #ea580c, #ef4444);
    border: none;
    box-shadow: 0 4px 15px rgba(234, 88, 12, 0.4);
}

/* Forms */
body.colorful-theme .form-control,
body.colorful-theme .form-select {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
}

body.colorful-theme .form-control:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(147, 51, 234, 0.5);
    box-shadow: 0 0 15px rgba(147, 51, 234, 0.3);
    color: #ffffff;
}

body.colorful-theme .form-control::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

/* Theme Toggle */
.theme-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-right: 15px;
}

.theme-toggle-label {
    font-size: 12px;
    color: #6c757d;
    white-space: nowrap;
}

.theme-switch {
    position: relative;
    width: 50px;
    height: 26px;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.theme-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #e0e0e0, #bdbdbd);
    transition: 0.4s;
    border-radius: 26px;
}

.theme-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.theme-switch input:checked+.theme-slider {
    background: linear-gradient(135deg, #9333ea, #db2777);
}

.theme-switch input:checked+.theme-slider:before {
    transform: translateX(24px);
}

body.colorful-theme ::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

body.colorful-theme ::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}

body.colorful-theme ::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 10px;
}

body.colorful-theme ::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Glow Effects */
.glow-purple {
    box-shadow: 0 0 20px rgba(147, 51, 234, 0.4);
}

.glow-blue {
    box-shadow: 0 0 20px rgba(37, 99, 235, 0.4);
}

/* Fade In Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

/* Table Styles */
body.colorful-theme .table {
    color: #ffffff;
}

body.colorful-theme .table thead th {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

body.colorful-theme .table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s ease;
}

body.colorful-theme .table tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

body.colorful-theme .table tbody td {
    vertical-align: middle;
    padding: 1rem 0.75rem;
}

/* Badge Styles */
body.colorful-theme .badge {
    padding: 0.35em 0.65em;
    font-weight: 500;
}

/* Progress Bar */
body.colorful-theme .progress {
    background: rgba(255, 255, 255, 0.1);
}

body.colorful-theme .progress-bar {
    background: linear-gradient(90deg, #9333ea, #db2777);
}

/* Navbar */
body.colorful-theme .navbar {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* Info Button */
body.colorful-theme .btn-info {
    background: linear-gradient(135deg, #0ea5e9, #06b6d4);
    border: none;
    box-shadow: 0 4px 15px rgba(14, 165, 233, 0.4);
}

body.colorful-theme .btn-info:hover {
    filter: brightness(1.15);
    box-shadow: 0 6px 20px rgba(14, 165, 233, 0.6);
    transform: translateY(-2px);
}

/* Warning Button */
body.colorful-theme .btn-warning {
    background: linear-gradient(135deg, #f59e0b, #eab308);
    border: none;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4);
    color: #1a1a2e;
}

body.colorful-theme .btn-warning:hover {
    filter: brightness(1.15);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.6);
    transform: translateY(-2px);
    color: #1a1a2e;
}

/* Outline Buttons */
body.colorful-theme .btn-outline-light {
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #ffffff;
    background: transparent;
    transition: all 0.3s ease;
}

body.colorful-theme .btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
    color: #ffffff;
    transform: translateY(-2px);
}

body.colorful-theme .btn-outline-secondary {
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.7);
    background: transparent;
}

body.colorful-theme .btn-outline-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.3);
    color: #ffffff;
}

body.colorful-theme .btn-outline-primary {
    border: 1px solid rgba(147, 51, 234, 0.5);
    color: #9333ea;
    background: transparent;
}

body.colorful-theme .btn-outline-primary:hover {
    background: rgba(147, 51, 234, 0.1);
    border-color: rgba(147, 51, 234, 0.8);
    color: #9333ea;
}