/* ============================================================
   ELECTION CAMPAIGN — Login Page Styles
   ============================================================ */

:root {
    --primary: #1a3a6b;
    --primary-light: #2a5298;
    --accent: #e63946;
    --accent-hover: #c0313d;
    --gold: #f0a500;
    --dark: #0d1b2a;
    --light: #f8f9fa;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    background: var(--dark);
    overflow: hidden;
}

/* ── Left Panel — Campaign Visual ── */
.login-visual {
    flex: 1;
    position: relative;
    display: none;
    overflow: hidden;
}

@media (min-width: 992px) {
    .login-visual {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

.login-visual-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.3;
}

.login-visual-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg,
            rgba(13, 27, 42, 0.95) 0%,
            rgba(26, 58, 107, 0.88) 50%,
            rgba(13, 27, 42, 0.92) 100%);
}

.login-visual-content {
    position: relative;
    z-index: 2;
    padding: 60px;
    max-width: 520px;
}

.visual-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(240, 165, 0, 0.12);
    border: 1px solid rgba(240, 165, 0, 0.25);
    color: var(--gold);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 2rem;
}

.visual-title {
    font-size: 2.8rem;
    font-weight: 900;
    color: #fff;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 1.2rem;
}

.visual-title .highlight {
    background: linear-gradient(135deg, #e63946, #ff6b6b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.visual-description {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.55);
    line-height: 1.7;
    margin-bottom: 2.5rem;
}

.visual-stats {
    display: flex;
    gap: 32px;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.v-stat-number {
    font-size: 1.6rem;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    margin-bottom: 4px;
}

.v-stat-label {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* Floating particles on left panel */
.particle {
    position: absolute;
    border-radius: 50%;
    background: rgba(240, 165, 0, 0.25);
    animation: float-particle 18s infinite ease-in-out;
    z-index: 1;
}

.particle:nth-child(1) {
    width: 6px;
    height: 6px;
    left: 15%;
    top: 25%;
    animation-delay: 0s;
}

.particle:nth-child(2) {
    width: 4px;
    height: 4px;
    left: 75%;
    top: 15%;
    animation-delay: 3s;
}

.particle:nth-child(3) {
    width: 5px;
    height: 5px;
    left: 60%;
    top: 75%;
    animation-delay: 6s;
}

.particle:nth-child(4) {
    width: 3px;
    height: 3px;
    left: 30%;
    top: 85%;
    animation-delay: 2s;
}

.particle:nth-child(5) {
    width: 4px;
    height: 4px;
    left: 85%;
    top: 55%;
    animation-delay: 4s;
}

@keyframes float-particle {
    0%,
    100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.3;
    }

    25% {
        transform: translate(20px, -30px) scale(1.4);
        opacity: 0.7;
    }

    50% {
        transform: translate(-15px, -60px) scale(1);
        opacity: 0.3;
    }

    75% {
        transform: translate(25px, -20px) scale(1.2);
        opacity: 0.5;
    }
}

/* ── Right Panel — Login Form ── */
.login-form-panel {
    width: 100%;
    max-width: 540px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 48px 56px;
    background: #fff;
    position: relative;
    overflow-y: auto;
}

@media (min-width: 992px) {
    .login-form-panel {
        box-shadow: -30px 0 80px rgba(0, 0, 0, 0.15);
    }
}

@media (max-width: 991px) {
    .login-form-panel {
        max-width: 100%;
        padding: 40px 24px;
    }
}

.login-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #999;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    margin-bottom: 2.5rem;
    transition: color 0.3s ease;
}

.login-back-link:hover {
    color: var(--primary);
    text-decoration: none;
}

.login-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 2rem;
}

.login-logo img {
    height: 44px;
}

.login-logo-text {
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--dark);
    letter-spacing: -0.02em;
}

.login-heading {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -0.02em;
    margin-bottom: 0.4rem;
}

.login-subheading {
    font-size: 0.95rem;
    color: #999;
    margin-bottom: 2.2rem;
    font-weight: 400;
}

/* Form Styling */
.form-group-custom {
    margin-bottom: 1.4rem;
}

.form-label-custom {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #555;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.form-input-wrapper {
    position: relative;
}

.form-input-wrapper i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #bbb;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    z-index: 2;
}

.form-input-custom {
    width: 100%;
    padding: 14px 16px 14px 46px;
    border: 2px solid #e8ecf0;
    border-radius: 12px;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    color: var(--dark);
    background: #fafbfc;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
}

.form-input-custom::placeholder {
    color: #c0c5cc;
}

.form-input-custom:focus {
    border-color: var(--primary-light);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(42, 82, 152, 0.08);
}

.form-input-custom:focus+i,
.form-input-wrapper:focus-within i {
    color: var(--primary-light);
}

.form-input-custom.is-invalid {
    border-color: var(--accent);
}

.form-input-custom.is-invalid:focus {
    box-shadow: 0 0 0 4px rgba(230, 57, 70, 0.08);
}

.invalid-feedback {
    font-size: 0.82rem;
    margin-top: 6px;
}

.password-toggle {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #bbb;
    cursor: pointer;
    font-size: 0.95rem;
    z-index: 2;
    padding: 0;
    transition: color 0.3s ease;
}

.password-toggle:hover {
    color: var(--primary);
}

/* Remember + Forgot */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.custom-checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.custom-checkbox-wrapper input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border: 2px solid #d0d5dd;
    border-radius: 5px;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.custom-checkbox-wrapper input[type="checkbox"]:checked {
    background: var(--primary);
    border-color: var(--primary);
}

.custom-checkbox-wrapper input[type="checkbox"]:checked::after {
    content: '\2713';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
}

.custom-checkbox-wrapper label {
    font-size: 0.88rem;
    color: #666;
    margin: 0;
    cursor: pointer;
}

.forgot-link {
    font-size: 0.88rem;
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
    transition: color 0.3s ease;
}

.forgot-link:hover {
    color: var(--accent-hover);
    text-decoration: none;
}

/* Submit Button */
.btn-login {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    color: #fff;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(26, 58, 107, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    letter-spacing: 0.02em;
    position: relative;
    overflow: hidden;
}

.btn-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.5s;
}

.btn-login:hover::before {
    left: 100%;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(26, 58, 107, 0.35);
}

.btn-login:active {
    transform: translateY(0);
}

/* Divider */
.login-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 1.8rem 0;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e8ecf0;
}

.login-divider span {
    font-size: 0.8rem;
    color: #bbb;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Footer Info */
.login-footer {
    margin-top: 2rem;
    text-align: center;
}

.login-footer p {
    font-size: 0.82rem;
    color: #bbb;
    margin: 0;
}

.login-footer a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.login-footer a:hover {
    text-decoration: underline;
}

/* Secure badge */
.secure-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #28a745;
    font-size: 0.78rem;
    font-weight: 500;
    margin-top: 1.2rem;
}

.secure-badge i {
    font-size: 0.7rem;
}

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

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

.animate-in {
    animation: fadeInUp 0.6s ease both;
}

.animate-in:nth-child(1) { animation-delay: 0.1s; }
.animate-in:nth-child(2) { animation-delay: 0.2s; }
.animate-in:nth-child(3) { animation-delay: 0.3s; }
.animate-in:nth-child(4) { animation-delay: 0.4s; }
.animate-in:nth-child(5) { animation-delay: 0.5s; }
.animate-in:nth-child(6) { animation-delay: 0.6s; }
.animate-in:nth-child(7) { animation-delay: 0.7s; }
