:root {
    --ov-black: #020005;
    --ov-purple: #7b2cff;
    --ov-magenta: #ff4fd8;
    --ov-blue: #5a2daa;
    --ov-cyan: #b48eff;
    --ov-text: #ffffff;
    --ov-muted: rgba(255, 255, 255, 0.65);
    --ov-border: rgba(140, 80, 220, 0.2);
    --ov-glass: rgba(10, 4, 28, 0.7);
    --ov-radius: 24px;
}

body { 
    background: #080711; 
    font-family: Poppins, sans-serif;
}

.login-screen {
    min-height: 100vh;
    display: grid;
    place-items: center;
    background: 
        radial-gradient(circle at 15% 20%, rgba(255, 79, 216, 0.22), transparent 45%),
        radial-gradient(circle at 85% 80%, rgba(123, 44, 255, 0.2), transparent 50%),
        linear-gradient(135deg, #020005 0%, #0d0024 100%);
    position: relative;
    overflow: hidden;
}

.login-screen::before {
    content: "";
    position: absolute;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 79, 216, 0.2) 0%, transparent 70%);
    filter: blur(25px);
    top: 15%;
    left: 20%;
    animation: float-slow 12s ease-in-out infinite alternate;
}

.login-screen::after {
    content: "";
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(123, 44, 255, 0.18) 0%, transparent 70%);
    filter: blur(30px);
    bottom: 10%;
    right: 15%;
    animation: float-slow 15s ease-in-out infinite alternate-reverse;
}

@keyframes float-slow {
    0% { transform: translateY(0) scale(1); }
    100% { transform: translateY(-20px) scale(1.05); }
}

.login-card {
    width: min(92vw, 430px);
    padding: 2.5rem;
    border-radius: var(--ov-radius);
    background: var(--ov-glass);
    border: 1px solid var(--ov-border);
    box-shadow: 
        0 24px 60px rgba(0, 0, 0, 0.5), 
        0 0 32px rgba(120, 60, 200, 0.15), 
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: relative;
    z-index: 2;
    color: var(--ov-text);
}

.login-card h1 {
    font-family: Montserrat, sans-serif;
    font-weight: 800;
    color: #fff;
    font-size: 1.95rem;
    text-align: center;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #fff 30%, var(--ov-cyan) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-card p {
    color: var(--ov-muted);
    font-size: 0.88rem;
    text-align: center;
    margin-bottom: 2rem;
    line-height: 1.5;
}

.login-card .form-label {
    color: var(--ov-muted);
    font-size: 0.82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.45rem;
}

.login-card .form-control {
    background: rgba(255, 255, 255, 0.04) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #fff !important;
    border-radius: 12px;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.login-card .form-control:focus {
    border-color: var(--ov-cyan) !important;
    box-shadow: 0 0 12px rgba(180, 142, 255, 0.25) !important;
    background: rgba(255, 255, 255, 0.06) !important;
}

.login-card .btn-primary {
    background: #e94da9 !important;
    border: 0 !important;
    border-radius: 99px !important;
    padding: 0.8rem 1.5rem !important;
    font-family: Montserrat, sans-serif !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    color: #fff !important;
    box-shadow: 0 0 24px rgba(233, 77, 169, 0.45), inset 0 0 10px rgba(255, 255, 255, 0.25) !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease !important;
    margin-top: 1rem;
}

.login-card .btn-primary:hover {
    background: #ff5bc1 !important;
    box-shadow: 0 0 32px rgba(255, 91, 193, 0.65), inset 0 0 12px rgba(255, 255, 255, 0.3) !important;
    transform: translateY(-2px) scale(1.02);
}

.login-card .btn-primary:active {
    transform: translateY(0) scale(1);
}

.login-card .alert {
    border-radius: 12px;
    font-size: 0.88rem;
    padding: 0.75rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(220, 53, 69, 0.15);
    color: #ff6b7d;
}

.login-card .alert-success {
    background: rgba(40, 167, 69, 0.15);
    color: #5edb7d;
}

.back-link {
    display: inline-block;
    color: var(--ov-cyan);
    font-size: 0.88rem;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.25s ease, text-shadow 0.25s ease;
}

.back-link:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(180, 142, 255, 0.6);
}

/* Sidebar admin dashboard overrides */
:root {
    --ov-deep: #080313;
    --ov-ink: #0d061f;
    --sidebar-width: 260px;
}

body.admin-layout {
    background: var(--ov-deep) !important;
    color: var(--ov-text) !important;
    min-height: 100vh;
    margin: 0;
}

.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styling */
.admin-sidebar {
    width: var(--sidebar-width);
    background: var(--ov-black) !important;
    border-right: 1px solid var(--ov-border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1000;
    transition: transform 0.3s ease;
}

.sidebar-header {
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--ov-border);
}

.sidebar-brand {
    text-decoration: none;
    font-family: Montserrat, sans-serif;
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 2px;
}

.sidebar-brand span {
    color: #fff;
}

.sidebar-brand strong {
    color: var(--ov-magenta);
}

.sidebar-brand small {
    display: inline-block;
    font-size: 0.65rem;
    background: rgba(180, 142, 255, 0.15);
    color: var(--ov-cyan);
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 6px;
    letter-spacing: 0.05em;
    font-weight: 700;
}

.sidebar-close-btn {
    background: none;
    border: 0;
    color: #fff;
    font-size: 1.25rem;
}

.sidebar-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.25rem 1rem;
}

.sidebar-nav .nav-item {
    margin-bottom: 0.35rem;
}

.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    color: var(--ov-muted) !important;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    transition: background 0.2s ease, color 0.2s ease;
}

.sidebar-nav .nav-link i {
    width: 20px;
    font-size: 1.05rem;
    text-align: center;
    transition: color 0.2s ease;
}

.sidebar-nav .nav-link:hover {
    background: rgba(255, 255, 255, 0.03) !important;
    color: #fff !important;
}

.sidebar-nav .nav-link.active {
    background: linear-gradient(135deg, rgba(123, 44, 255, 0.2), rgba(255, 79, 216, 0.15)) !important;
    color: #fff !important;
    border: 1px solid rgba(255, 79, 216, 0.25) !important;
    box-shadow: 0 0 15px rgba(255, 79, 216, 0.1) !important;
}

.sidebar-nav .nav-link.active i {
    color: var(--ov-magenta) !important;
}

.sidebar-footer {
    margin-top: auto;
}

.sidebar-footer .nav-link {
    padding: 0.5rem 1rem;
}

/* Main Content Area */
.admin-main {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* Topbar */
.admin-topbar {
    height: 70px;
    background: rgba(2, 0, 5, 0.6);
    border-bottom: 1px solid var(--ov-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    position: sticky;
    top: 0;
    z-index: 900;
}

.sidebar-toggle-btn {
    background: none;
    border: 0;
    color: #fff;
    font-size: 1.25rem;
}

.topbar-title h2 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0;
    color: #fff;
    font-family: Montserrat, sans-serif;
}

.user-badge {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--ov-border);
    padding: 0.45rem 1rem;
    border-radius: 99px;
    font-size: 0.88rem;
    font-weight: 500;
    color: #fff;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Content Container */
.admin-content {
    padding: 2rem;
    flex: 1;
}

/* Dashboard & CRUD custom classes */
.admin-card {
    padding: 1.5rem !important;
    border-radius: var(--ov-radius) !important;
    background: var(--ov-glass) !important;
    border: 1px solid var(--ov-border) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
    transition: transform 0.2s ease, border-color 0.2s ease;
    position: relative;
    overflow: hidden;
}

.admin-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 79, 216, 0.35) !important;
}

.admin-card span {
    display: block;
    color: var(--ov-muted) !important;
    font-size: 0.85rem !important;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.admin-card strong {
    display: block;
    font-size: 2.2rem !important;
    font-weight: 800 !important;
    color: #fff !important;
    line-height: 1.1;
    font-family: Montserrat, sans-serif;
}

.admin-table,
.admin-form {
    padding: 1.5rem !important;
    border-radius: var(--ov-radius) !important;
    background: var(--ov-glass) !important;
    border: 1px solid var(--ov-border) !important;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.4) !important;
}

.admin-toolbar {
    display: flex;
    gap: .75rem;
    padding: 1.25rem !important;
    border-radius: var(--ov-radius) !important;
    background: var(--ov-glass) !important;
    border: 1px solid var(--ov-border) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3) !important;
    margin-bottom: 1.5rem;
}

/* Form controls overrides */
.form-control,
.form-select {
    background-color: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #fff !important;
    border-radius: 10px !important;
    padding: 0.65rem 1rem !important;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--ov-cyan) !important;
    box-shadow: 0 0 10px rgba(180, 142, 255, 0.25) !important;
    background-color: rgba(255, 255, 255, 0.05) !important;
}

.form-label {
    font-weight: 600;
    color: var(--ov-muted) !important;
    font-size: 0.88rem;
    margin-bottom: 0.5rem;
}

/* Custom table rules */
.table {
    --bs-table-color: var(--ov-text) !important;
    --bs-table-bg: transparent !important;
    --bs-table-border-color: rgba(255, 255, 255, 0.08) !important;
    --bs-table-hover-color: #fff !important;
    --bs-table-hover-bg: rgba(255, 255, 255, 0.05) !important;
    --bs-table-striped-color: var(--ov-text) !important;
    --bs-table-striped-bg: rgba(255, 255, 255, 0.02) !important;
    color: var(--ov-text) !important;
    background: transparent !important;
}

.table th {
    font-weight: 600;
    border-bottom-color: rgba(255, 255, 255, 0.15) !important;
    color: var(--ov-muted) !important;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    padding: 1rem 0.75rem !important;
    background: transparent !important;
}

.table td {
    border-bottom-color: rgba(255, 255, 255, 0.08) !important;
    vertical-align: middle;
    padding: 1rem 0.75rem !important;
    background: transparent !important;
}

.table-hover tbody tr:hover td {
    color: #fff !important;
    background-color: rgba(255, 255, 255, 0.05) !important;
}

/* Pagination overrides */
.pagination .page-link {
    background-color: var(--ov-glass) !important;
    border-color: var(--ov-border) !important;
    color: var(--ov-cyan) !important;
}

.pagination .page-item.active .page-link {
    background: linear-gradient(135deg, var(--ov-magenta), var(--ov-purple)) !important;
    border-color: transparent !important;
    color: #fff !important;
}

.pagination .page-link:hover {
    background-color: rgba(255, 255, 255, 0.05) !important;
    color: #fff !important;
}

/* Alert overrides */
.alert-success {
    background-color: rgba(40, 167, 69, 0.15) !important;
    border-color: rgba(40, 167, 69, 0.25) !important;
    color: #5edb7d !important;
}

.alert-danger {
    background-color: rgba(220, 53, 69, 0.15) !important;
    border-color: rgba(220, 53, 69, 0.25) !important;
    color: #ff6b7d !important;
}


/* Custom buttons overrides */
.btn-primary {
    background: linear-gradient(135deg, var(--ov-magenta), var(--ov-purple)) !important;
    border: 0 !important;
    font-weight: 600 !important;
    border-radius: 10px !important;
    padding: 0.6rem 1.25rem !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(255, 79, 216, 0.4) !important;
}

.btn-outline-primary {
    border-color: var(--ov-cyan) !important;
    color: var(--ov-cyan) !important;
    border-radius: 10px !important;
    font-weight: 600 !important;
    transition: all 0.2s ease !important;
}

.btn-outline-primary:hover {
    background: var(--ov-cyan) !important;
    color: #020005 !important;
    transform: translateY(-1px);
}

.btn-outline-secondary {
    border-color: rgba(255, 255, 255, 0.15) !important;
    color: var(--ov-muted) !important;
    border-radius: 10px !important;
    font-weight: 600 !important;
}

.btn-outline-secondary:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #fff !important;
}

.btn-outline-danger {
    border-color: rgba(220, 53, 69, 0.4) !important;
    color: #ff6b7d !important;
    border-radius: 10px !important;
    font-weight: 600 !important;
}

.btn-outline-danger:hover {
    background: #dc3545 !important;
    color: #fff !important;
}

/* Responsive sidebar */
@media (max-width: 991px) {
    .admin-sidebar {
        transform: translateX(-100%);
    }
    
    .admin-sidebar.show {
        transform: translateX(0);
    }
    
    .admin-main {
        margin-left: 0;
    }
}
