:root {
    --bg-color: #dbeafe;
    --card-bg: #ffffff;
    --text-main: #1e3a5f;
    --text-muted: #64748b;
    --primary: #1a73e8;
    --primary-hover: #1558c0;
    --primary-light: #e0ecfd;
    --border-color: #bfdbfe;
    --input-bg: #f0f9ff;
    --shadow: 0 10px 25px rgba(26, 115, 232, 0.08);
    --focus-ring: rgba(26, 115, 232, 0.15);
    --white: #ffffff;

    --blue-panel: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    --blue-card: linear-gradient(135deg, #e0f2fe 0%, #dbeafe 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    /* Prevent scrolling which can offset centering */
}

body {
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 20px;
}

body::before,
body::after {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    filter: blur(120px);
    z-index: -1;
    opacity: 0.4;
    transition: all 2s ease-in-out;
}

body::before {
    background: var(--primary);
    top: -200px;
    left: -200px;
    animation: moveBlob1 20s infinite alternate;
}

body::after {
    background: var(--primary-light);
    bottom: -200px;
    right: -200px;
    animation: moveBlob2 25s infinite alternate-reverse;
}

@keyframes moveBlob1 {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(100px, 100px);
    }
}

@keyframes moveBlob2 {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(-100px, -100px);
    }

}

.login-wrapper {
    display: flex;
    background: var(--blue-card);
    /* No pure white */
    border-radius: 40px;
    box-shadow: var(--shadow);
    overflow: hidden;
    width: 100%;
    max-width: 946px;
    min-height: 616px;
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    border: 1px solid rgba(255, 255, 255, 0.3);
    /* Subtle light blue border instead of solid */
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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



.login-wrapper:hover {
    transform: translateY(-5px);
}

.login-info-section {
    flex: 1;
    background: var(--primary);
    color: #ffffff;
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.brand-logo-container {
    background: white;
    width: 64px;
    height: 64px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15), inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.login-info-section h2 {
    font-size: 2.75rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.login-info-section p {
    font-size: 1.1rem;
    line-height: 1.6;
    opacity: 0.9;
    margin-bottom: 48px;
    max-width: 90%;
}

.features-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.features-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.95);
}

.check-icon {
    width: 24px;
    height: 24px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    flex-shrink: 0;
}

.check-icon svg {
    color: white;
}

/* Right side */
.login-form-section {
    flex: 1.25;
    padding: 60px 70px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #ffffff;
    position: relative;
}

.login-header h1 {
    font-size: 2.25rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.login-header p {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 36px;
    text-align: center;
}

.role-selector {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
}

.role-option {
    flex: 1;
}

.role-option input {
    display: none;
}

.role-btn {
    display: block;
    text-align: center;
    padding: 12px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: var(--text-muted);
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.role-btn:hover {
    background: #f8fafc;
}

.role-option input:checked+.role-btn {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 4px 12px var(--focus-ring);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-main);
}

.form-control {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #ffffff;
    font-size: 0.95rem;
    color: var(--text-main);
    transition: all 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--focus-ring);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    font-size: 0.9rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: var(--text-muted);
}

.forgot-password {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.btn-submit {
    width: 100%;
    padding: 14px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px var(--focus-ring);
}

.btn-submit:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 15px 35px -10px rgba(37, 99, 235, 0.7), 0 0 20px rgba(37, 99, 235, 0.4);
    filter: brightness(1.15);
}

.btn-submit:hover::after {
    left: 100%;
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px var(--focus-ring);
}

.btn-submit:active {
    transform: scale(0.98);
}

.sign-up-link {
    text-align: center;
    margin-top: 24px;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.sign-up-link a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

@media (max-width: 768px) {
    .login-wrapper {
        flex-direction: column;
        max-width: 480px;
    }

    .login-info-section {
        padding: 40px 24px;
        flex: none;
    }

    .login-form-section {
        padding: 30px 24px;
    }

    .login-info-section h2 {
        font-size: 2rem;
    }
}

/* ── Input wrapper (icon prefix support) ── */
.input-wrapper {
    position: relative;
}

.input-wrapper .form-control {
    padding-left: 16px;
}

/* ── Form options row (remember me + forgot password) ── */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    font-size: 0.875rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: var(--text-muted);
}

.remember-me input[type="checkbox"] {
    accent-color: var(--primary);
    width: 15px;
    height: 15px;
}

/* ── Spinner ── */
.spinner {
    width: 22px;
    height: 22px;
    animation: rotate 1.4s linear infinite;
    display: inline-block;
    vertical-align: middle;
}

.spinner .path {
    stroke: #fff;
    stroke-linecap: round;
    animation: dash 1.4s ease-in-out infinite;
}

@keyframes rotate {
    100% {
        transform: rotate(360deg);
    }
}

@keyframes dash {
    0% {
        stroke-dasharray: 1, 150;
        stroke-dashoffset: 0;
    }

    50% {
        stroke-dasharray: 90, 150;
        stroke-dashoffset: -35;
    }

    100% {
        stroke-dasharray: 90, 150;
        stroke-dashoffset: -124;
    }
}

.hidden {
    display: none !important;
}

/* ── Button state variants ── */
.btn-submit.loading {
    opacity: 0.8;
    cursor: not-allowed;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-submit.success {
    background: linear-gradient(135deg, #059669, #10b981);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}