/**
 * Login Page Styles
 * Vendor Portal - Unified Login (Internal & Vendor)
 * Colors matched with app.css
 */

/* ============================================
   CSS VARIABLES (Same as app.css)
   ============================================ */

:root {
    --primary-blue: #174081;
    --accent-blue: #3B82F6;
    --white: #FFFFFF;
    --bg-light: #FAFBFD;
    --border-grey: #D8DEE9;
    --text-dark: #222222;
    --text-grey: #373737;
}

/* ============================================
   BASE STYLES
   ============================================ */

* {
    font-family: 'Inter', 'Segoe UI', Arial, sans-serif;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.login-page {
    min-height: 100vh;
    background: var(--bg-light);
    overflow-x: hidden;
}

.login-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ============================================
   LEFT PANEL - BRANDING
   ============================================ */

.left-panel {
    flex: 1;
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--accent-blue) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px;
    position: relative;
    overflow: hidden;
}

.left-panel #bgCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.left-panel .brand-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: white;
}

.left-panel .logo-container {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s ease;
}

.left-panel .logo-container:hover {
    transform: scale(1.05);
}

.left-panel .logo-container img {
    width: 60px;
    height: 60px;
}

.left-panel h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
}

.left-panel .tagline {
    font-size: 16px;
    opacity: 0.7;
    max-width: 300px;
    line-height: 1.6;
}

/* Features List */
.left-panel .features {
    margin-top: 50px;
    text-align: left;
}

.left-panel .feature-item {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    opacity: 0.9;
    transition: all 0.3s ease;
}

.left-panel .feature-item:hover {
    opacity: 1;
    transform: translateX(5px);
}

.left-panel .feature-item i {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    font-size: 18px;
}

.left-panel .feature-item span {
    font-size: 14px;
    font-weight: 500;
}

/* ============================================
   RIGHT PANEL - LOGIN FORM
   ============================================ */

.right-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    background: var(--white);
}

.login-form-container {
    width: 100%;
    max-width: 400px;
}

/* Login Header */
.login-header {
    margin-bottom: 40px;
}

.login-header .badge-admin {
    display: inline-flex;
    align-items: center;
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary-blue);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 20px;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.login-header .badge-admin i {
    margin-right: 6px;
    color: var(--accent-blue);
}

.login-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 8px;
}

.login-header p {
    color: var(--text-grey);
    font-size: 14px;
    margin: 0;
}

/* ============================================
   FORM STYLES
   ============================================ */

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.input-wrapper {
    position: relative;
}

.input-wrapper i.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    font-size: 16px;
    transition: color 0.3s;
}

.input-wrapper input {
    width: 100%;
    padding: 14px 16px 14px 48px;
    border: 1.5px solid var(--border-grey);
    border-radius: 12px;
    font-size: 14px;
    transition: all 0.3s;
    background: var(--bg-light);
    color: var(--text-dark);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--accent-blue);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.input-wrapper input:focus + i.input-icon,
.input-wrapper input:focus ~ i.input-icon {
    color: var(--accent-blue);
}

.input-wrapper input::placeholder {
    color: #9ca3af;
}

/* Password Toggle */
.input-wrapper .toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    padding: 0;
    font-size: 16px;
    transition: color 0.2s;
}

.input-wrapper .toggle-password:hover {
    color: var(--accent-blue);
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.form-check-custom {
    display: flex;
    align-items: center;
}

.form-check-custom input {
    width: 18px;
    height: 18px;
    margin-right: 10px;
    accent-color: var(--accent-blue);
    cursor: pointer;
}

.form-check-custom label {
    font-size: 13px;
    color: var(--text-grey);
    cursor: pointer;
    margin: 0;
}

/* ============================================
   SUBMIT BUTTON - SOLID ACCENT BLUE
   ============================================ */

.btn-login {
    width: 100%;
    padding: 14px 24px;
    background-color: var(--accent-blue);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-login:hover {
    background-color: #2563EB;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.35);
}

.btn-login:focus {
    background-color: #2563EB;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25);
}

.btn-login:active {
    background-color: #1D4ED8;
    transform: translateY(0);
}

.btn-login:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* ============================================
   ALERTS
   ============================================ */

.alert {
    padding: 14px 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert-danger {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

/* ============================================
   FOOTER
   ============================================ */

.login-footer {
    margin-top: 40px;
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--border-grey);
}

.login-footer p {
    font-size: 12px;
    color: #9ca3af;
    margin: 0;
}

.login-footer a {
    color: var(--accent-blue);
    text-decoration: none;
    font-weight: 500;
}

.login-footer a:hover {
    text-decoration: underline;
}

/* ============================================
   FORGOT PASSWORD LINK
   ============================================ */

.forgot-link {
    font-size: 13px;
    color: var(--accent-blue);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.forgot-link:hover {
    color: var(--primary-blue);
    text-decoration: underline;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 992px) {
    .left-panel {
        display: none;
    }

    .right-panel {
        flex: 1;
    }

    .login-form-container {
        max-width: 100%;
    }
}

@media (max-width: 576px) {
    .right-panel {
        padding: 24px;
    }

    .login-header h2 {
        font-size: 24px;
    }

    .input-wrapper input {
        padding: 12px 14px 12px 44px;
    }

    .btn-login {
        padding: 12px 20px;
    }
}