/*
Autor: David Vargas C.
Contacto: dx.crazzy@gmail.com
Version 1.0.0
*/
:root {
            --primary: #004631;
            --primary-hover: #00582f;
            --accent-light: #bedb8b;
            --bg-page: #eef1f4;
            --text-main: #1f2937;
            --text-muted: #6b7280;
            --border: #d1d5db;
            --border-soft: #e5e7eb;
            --input-bg: #f9fafb;
        }
        * { margin: 0; padding: 0; box-sizing: border-box; }
        body {
            font-family: 'Inter', sans-serif;
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
            background: var(--bg-page);
            color: var(--text-main);
            padding: 20px;
        }
        .login-shell {
            width: 100%;
            max-width: 640px;
            min-height: 460px;
            display: flex;
            background: #ffffff;
            border-radius: 20px;
            overflow: hidden;
            border: 1px solid var(--border-soft);
            box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
            animation: fadeIn 0.5s ease;
        }
        @keyframes fadeIn {
            from { opacity: 0; transform: translateY(8px); }
            to   { opacity: 1; transform: translateY(0); }
        }
        
        .brand {
            flex: 1;
            background:
        linear-gradient(rgba(0, 70, 49, 0.86), rgba(0, 70, 49, 0.92)),
        url('../images/fondo_login.webp') center / cover no-repeat;
            color: #ffffff;
            padding: 30px 26px;
            display: flex;
            flex-direction: column;
        }
        .brand-main {
            display: flex;
            flex-direction: column;
            align-items: center;
            margin: auto 0;
        }
        .brand-logos {
            display: flex;
            flex-direction: column;
            gap: 14px;
            justify-content: center;
            align-items: center;
        }
        .brand-logos .chip {
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .brand-logos .chip img {
            max-height: 85px;
            max-width: 180px;
            object-fit: contain;
        }
        .brand-center {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            text-align: center;
            margin-top: 16px;
        }
        .brand-center h2 {
            font-size: 1.15rem;
            font-weight: 700;
            line-height: 1.25;
            white-space: nowrap;
        }
        .brand-center .sub {
            color: var(--accent-light);
            letter-spacing: 1.5px;
            font-size: 0.78rem;
            font-weight: 600;
            margin-top: 8px;
        }
        .brand-center .tag {
            color: rgba(255, 255, 255, 0.78);
            font-size: 0.8rem;
            line-height: 1.5;
            margin-top: 16px;
            max-width: 250px;
        }
        .form-footer {
            text-align: center;
            font-size: 0.72rem;
            color: #9ca3af;
            letter-spacing: 0.5px;
            margin-top: 18px;
        }
        .brand-footer {
            text-align: center;
            font-size: 0.72rem;
            color: rgba(255, 255, 255, 0.65);
            letter-spacing: 0.5px;
        }
        .brand-footer-mobile { display: none; }

        .form-panel {
            flex: 1;
            padding: 32px;
            display: flex;
            flex-direction: column;
            justify-content: center;
        }
        .form-panel h1 {
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--text-main);
        }
        .form-panel .lead {
            color: var(--text-muted);
            font-size: 0.9rem;
            margin: 6px 0 28px;
        }
        .form-group { margin-bottom: 16px; }
        .form-group label {
            display: block;
            font-size: 0.78rem;
            font-weight: 600;
            color: #374151;
            margin-bottom: 7px;
        }
        .input-wrapper {
            position: relative;
            display: flex;
            align-items: center;
        }
        .input-wrapper i.field-icon {
            position: absolute;
            left: 14px;
            top: 50%;
            transform: translateY(-50%);
            color: #9ca3af;
            font-size: 0.95rem;
            z-index: 2;
        }
        .form-control {
            width: 100%;
            padding: 12px 14px 12px 40px;
            border: 1px solid var(--border);
            border-radius: 10px;
            font-size: 0.9rem;
            background: var(--input-bg);
            color: var(--text-main);
            font-family: 'Inter', sans-serif;
            transition: all 0.2s ease;
        }
        .form-control:focus {
            outline: none;
            border-color: var(--primary);
            background: #ffffff;
            box-shadow: 0 0 0 4px rgba(0, 70, 49, 0.08);
        }
        .form-control::placeholder { color: #9ca3af; }
        .toggle-password {
            position: absolute;
            right: 10px;
            top: 50%;
            transform: translateY(-50%);
            cursor: pointer;
            color: #9ca3af;
            padding: 6px;
            z-index: 3;
        }
        .toggle-password:hover { color: var(--primary); }
        .btn-login {
            width: 100%;
            padding: 12px;
            background: var(--primary);
            color: #ffffff;
            border: 1px solid var(--primary);
            border-radius: 10px;
            font-size: 0.9rem;
            font-weight: 600;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            margin-top: 22px;
            font-family: 'Inter', sans-serif;
            transition: all 0.2s ease;
        }
        .btn-login:hover { background: var(--primary-hover); }
        .btn-login:active { transform: scale(0.99); }
        .btn-login:disabled { opacity: 0.7; cursor: not-allowed; }
        .divider {
            border-top: 1px solid var(--border-soft);
            margin: 22px 0 16px;
        }
        .btn-public {
            width: 100%;
            padding: 12px;
            background: #e5e7eb;
            color: #4b5563;
            border: 1.5px solid #9ca3af;
            border-radius: 10px;
            font-size: 0.88rem;
            font-weight: 600;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            text-decoration: none;
            transition: all 0.2s ease;
        }
        .btn-public:hover,
        .btn-public:active,
        .btn-public:focus-visible {
            background: #004631;
            border-color: #004631;
            color: #ffffff;
        }
        
        @media (max-width: 820px) {
            .login-shell {
                flex-direction: column;
                max-width: 440px;
                min-height: 0;
            }
            .brand { flex: none; padding: 30px 28px; }
            .brand-main { margin: 0; }
            .brand-center { margin-top: 18px; }
            .brand-center .tag { display: none; }
            .brand > .brand-footer { display: none; }
            .brand-footer-mobile {
                display: block;
                color: #9ca3af;
                margin: 18px 0 22px;
            }
            .form-panel { padding: 34px 28px; }
        }
