/* Custom Premium Design System - VietKhaShop High Contrast Light Theme */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #4f46e5;
    /* Royal Indigo */
    --primary-hover: #4338ca;
    --primary-rgb: 79, 70, 229;
    --secondary: #db2777;
    /* Rose Pink */
    --secondary-rgb: 219, 39, 119;
    --success: #059669;
    /* Emerald Green */
    --danger: #dc2626;
    /* Red */
    --warning: #d97706;
    /* Amber */
    --info: #0891b2;
    /* Cyan */

    --bg-main: #f1f5f9;
    --bg-card: #ffffff;
    --text-main: #1e293b;
    /* Dark Charcoal - Extremely Readable */
    --text-muted: #64748b;
    --border-color: #cbd5e1;

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 24px;
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

body {
    font-family: 'Outfit', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    color: var(--text-main);

    /* Elegant and clearly visible soft light background gradient */
    background: linear-gradient(135deg, #e0e7ff 0%, #f8fafc 50%, #fbcfe8 100%) fixed;
    background-size: 100% 100%;
    overflow-x: hidden;
}

/* Glassmorphism Container for Main Content (Bright & Clear) */
main.container {
    flex: 1;
    background: rgba(255, 255, 255, 0.95);
    /* Bright white backplate */
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.9);
    padding: 2.5rem !important;
    margin-top: 1.5rem;
    margin-bottom: 2.5rem;
    box-shadow: 0 15px 35px rgba(15, 23, 42, 0.04);
}

/* Navbar Premium Glassmorphism */
.navbar {
    background: rgba(15, 23, 42, 0.92) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 0.9rem 0;
    transition: var(--transition);
}

.navbar-brand {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #a5b4fc, #f472b6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: var(--transition);
}

.navbar-brand:hover {
    transform: scale(1.02);
}

.nav-link {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8) !important;
    padding: 0.5rem 1.1rem !important;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    margin: 0 0.15rem;
}

.nav-link:hover {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.06);
    transform: translateY(-1px);
}

.nav-link.active {
    color: #fff !important;
    background: rgba(79, 70, 229, 0.3) !important;
    border: 1px solid rgba(79, 70, 229, 0.4);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.15);
}

/* Premium Hero Section with Neon Blob */
.hero-gradient {
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
    border-radius: var(--radius-lg);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 15px 30px rgba(15, 23, 42, 0.15);
}

.hero-gradient::before {
    content: '';
    position: absolute;
    top: -30%;
    right: -10%;
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.15) 0%, transparent 70%);
    z-index: 1;
    pointer-events: none;
    filter: blur(40px);
}

.hero-gradient::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    z-index: 1;
    pointer-events: none;
    filter: blur(40px);
}

.hero-gradient .container-fluid {
    position: relative;
    z-index: 2;
}

/* Cards Premium Styling */
.card {
    background-color: var(--bg-card);
    border: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06) !important;
    border-color: rgba(79, 70, 229, 0.3);
}

.card-header {
    background-color: #f8fafc !important;
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    color: var(--text-main);
}

/* Dynamic Interactive Icons */
.card-icon-container {
    display: inline-block;
    padding: 1.25rem;
    border-radius: 50%;
    transition: var(--transition);
}

/* Hover wobble/bounce animation for card icons */
@keyframes iconFloat {

    0%,
    100% {
        transform: translateY(0) scale(1);
    }

    50% {
        transform: translateY(-6px) scale(1.06);
    }
}

.card:hover .card-icon-container {
    animation: iconFloat 0.7s ease-in-out infinite;
}

.card:hover .bg-primary-light {
    background-color: var(--primary) !important;
    color: #fff !important;
}

.card:hover .bg-success-light {
    background-color: var(--success) !important;
    color: #fff !important;
}

.card:hover .bg-warning-light {
    background-color: var(--warning) !important;
    color: #fff !important;
}

.card:hover .bg-danger-light {
    background-color: var(--danger) !important;
    color: #fff !important;
}

.bg-primary-light {
    background-color: rgba(79, 70, 229, 0.08) !important;
    color: var(--primary) !important;
}

.bg-success-light {
    background-color: rgba(5, 150, 105, 0.08) !important;
    color: var(--success) !important;
}

.bg-warning-light {
    background-color: rgba(217, 119, 6, 0.08) !important;
    color: var(--warning) !important;
}

.bg-danger-light {
    background-color: rgba(220, 38, 38, 0.08) !important;
    color: var(--danger) !important;
}

/* Table Premium Styling - Highly Legible */
.table-responsive {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background-color: var(--bg-card);
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.02);
}

.table {
    margin-bottom: 0;
    color: var(--text-main) !important;
}

.table th {
    background-color: #1e293b !important;
    /* Dark Slate - Crisp contrast */
    color: #ffffff !important;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    padding: 1.1rem;
    border-bottom: none;
}

.table td {
    padding: 1.1rem;
    vertical-align: middle;
    border-bottom: 1px solid #e2e8f0;
    color: var(--text-main) !important;
    /* Force legible dark text */
}

/* Text styles inside table to ensure dark colors */
.table td,
.table td a,
.table td span:not(.badge),
.table td p {
    color: var(--text-main) !important;
    font-weight: 500;
}

.table tbody tr {
    transition: var(--transition);
}

.table tbody tr:hover {
    background-color: rgba(79, 70, 229, 0.02) !important;
}

/* Rounded Soft Buttons for Actions */
.btn-action {
    width: 32px;
    height: 32px;
    border-radius: 50% !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    transition: var(--transition);
    font-size: 0.85rem;
    padding: 0 !important;
}

.btn-info-soft {
    background-color: rgba(8, 145, 178, 0.1) !important;
    color: var(--info) !important;
}

.btn-info-soft:hover {
    background-color: var(--info) !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(8, 145, 178, 0.25);
}

.btn-warning-soft {
    background-color: rgba(217, 119, 6, 0.1) !important;
    color: var(--warning) !important;
}

.btn-warning-soft:hover {
    background-color: var(--warning) !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(217, 119, 6, 0.25);
}

.btn-danger-soft {
    background-color: rgba(220, 38, 38, 0.1) !important;
    color: var(--danger) !important;
}

.btn-danger-soft:hover {
    background-color: var(--danger) !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(220, 38, 38, 0.25);
}

/* Standard Buttons with soft shadows */
.btn {
    font-weight: 600;
    padding: 0.55rem 1.3rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.35);
}

.btn-success {
    background-color: var(--success);
    border-color: var(--success);
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.25);
}

.btn-success:hover {
    background-color: #047857;
    border-color: #047857;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(5, 150, 105, 0.35);
}

.btn-warning {
    background-color: var(--warning);
    border-color: var(--warning);
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.25);
}

.btn-warning:hover {
    background-color: #b45309;
    border-color: #b45309;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(217, 119, 6, 0.35);
}

.btn-secondary {
    background-color: #64748b;
    border-color: #64748b;
    color: #fff !important;
}

.btn-secondary:hover {
    background-color: #475569;
    transform: translateY(-2px);
}

/* Forms styling (Clean White inputs with dark borders) */
.form-control,
.form-select {
    background-color: #ffffff !important;
    border: 1px solid #cbd5e1;
    color: #0f172a !important;
    border-radius: var(--radius-sm);
    padding: 0.65rem 1rem;
    transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.15);
}

/* Alerts */
.alert-success {
    background-color: rgba(5, 150, 105, 0.1) !important;
    border: 1px solid rgba(5, 150, 105, 0.2) !important;
    color: #047857 !important;
}

/* Badges styling */
.badge {
    padding: 0.5em 0.9em;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.75rem;
}

.bg-info {
    background-color: rgba(8, 145, 178, 0.1) !important;
    color: var(--info) !important;
    border: 1px solid rgba(8, 145, 178, 0.25) !important;
}

/* Footer styling */
footer {
    background: #0f172a !important;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

footer a {
    color: #94a3b8 !important;
    transition: var(--transition);
}

footer a:hover {
    color: var(--secondary) !important;
    transform: translateY(-1px);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

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

.animate-fade-in {
    animation: fadeIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.03);
        opacity: 0.95;
    }
}

.animate-pulse {
    animation: pulse 3s ease-in-out infinite;
}