:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --secondary-color: #ec4899;
    --background-bg: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-radius: 16px;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: #f1f5f9;
    background-image: radial-gradient(at 0% 0%, hsla(253, 16%, 95%, 1) 0, transparent 50%), radial-gradient(at 50% 0%, hsla(225, 39%, 95%, 1) 0, transparent 50%), radial-gradient(at 100% 0%, hsla(339, 49%, 95%, 1) 0, transparent 50%);
    background-attachment: fixed;
    min-height: 100vh;
}

/* Glassmorphism Card */
.custom-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    border-radius: var(--border-radius);
    box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.8);
    padding: 2rem;
    margin-bottom: 2rem;
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 24px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    padding: 3rem;
    max-width: 450px;
    width: 100%;
    margin: 0 1rem;
    /* Add margin to prevent touching edges on mobile */
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .login-card {
        padding: 2rem;
        border-radius: 16px;
    }

    .custom-card {
        padding: 1.5rem;
    }
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    letter-spacing: -0.025em;
    color: var(--text-main);
}

.text-gradient {
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border: none;
    border-radius: 12px;
    padding: 10px 24px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.3);
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
    border-radius: 8px;
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    color: white;
}

/* Form Controls */
.form-control {
    border-radius: 12px;
    border: 2px solid #e2e8f0;
    padding: 12px 16px;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

/* Table Styling */
.table-custom {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
}

.table-custom thead th {
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    padding: 1rem;
}

.table-custom tbody tr {
    background-color: white;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.table-custom tbody tr:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    z-index: 10;
    position: relative;
}

.table-custom td {
    padding: 1rem;
    vertical-align: middle;
    border: none;
}

.table-custom td:first-child {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
}

.table-custom td:last-child {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

/* QR Code Image */
.qr-preview {
    border-radius: 12px;
    border: 4px solid white;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease;
}

.qr-preview:hover {
    transform: scale(1.5);
    z-index: 20;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .container-fluid {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    /* Card Adjustments */
    .custom-card {
        padding: 1.5rem;
        margin-bottom: 1.5rem;
    }

    /* Form Adjustments */
    .input-group {
        flex-direction: column;
    }
    
    .input-group > .form-control,
    .input-group > .form-select,
    .input-group > .input-group-text,
    .input-group > .btn {
        width: 100% !important;
        border-radius: 12px !important;
        margin-bottom: 0.5rem;
        border-right-width: 2px !important; /* Restore border for stacked items */
        border-left-width: 2px !important;
    }

    .input-group > .input-group-text {
        display: none; /* Hide icons in input groups on mobile to save space if needed, or keep them but rounded */
    }

    /* Alternatively, keep icons but styling fixes */
    /*
    .input-group > .input-group-text {
        border-radius: 12px 12px 0 0 !important;
        margin-bottom: 0;
        border-bottom: 0;
    }
    */

    /* Table Adjustments - Horizontal Scroll is usually default in Bootstrap table-responsive, 
       but we can make it card-view if needed. For now standard scroll is safer. 
    */
    
    .btn-group {
        display: flex;
        flex-direction: row; /* Keep buttons in row but maybe smaller */
        justify-content: center;
    }
    
    .btn-group .btn {
        padding: 0.25rem 0.5rem;
    }

    /* Typography */
    h1.h2 {
        font-size: 1.75rem;
    }
}