/*
 * Copyright (c) 2025 EUMETSAT
 * License: Proprietary
 * Login page design 
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

html, body {
    height: 100%;
    margin: 0;
}

body {
    min-height: 100vh;
    display: flex;
    background: var(--color-surface);
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
    background-image: none !important;
}

#wrap {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-height: 100vh;
}

#wrap > .container,
#wrap > .container-fluid {
    display: flex;
    width: 100%;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    flex: 1;
    min-height: 100vh;
}

.login-hero {
    position: relative;
    flex: 1 1 62%;
    min-height: 100vh;
    background-color: #05060b;
    background-image: url('../images/Eumetsat_Earth.png');
    background-size: cover;
    background-position: top center;
    background-repeat: no-repeat;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    --hero-pad-left: 36px;
    padding: 56px 56px 56px var(--hero-pad-left);
    box-sizing: border-box;
    overflow: hidden;
}

.login-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(8, 10, 20, 0.82) 0%,
        rgba(8, 10, 20, 0.55) 35%,
        rgba(8, 10, 20, 0.10) 65%,
        rgba(8, 10, 20, 0) 100%
    );
    pointer-events: none;
    z-index: 1;
}

.login-hero-logo {
    position: absolute;
    top: 28px;
    left: var(--hero-pad-left);
    z-index: 3;
}
.login-hero-logo img {
    height: 36px;
    width: auto;
    opacity: 0.92;
}

.login-hero-content {
    position: relative;
    z-index: 2;
    max-width: 580px;
    color: var(--color-surface);
}

.login-hero-title {
    font-size: 3.4rem;
    font-weight: 800;
    line-height: 1.1;
    margin: 0 0 20px;
    letter-spacing: -0.01em;
    color: var(--color-surface);
    text-shadow: 0 2px 10px rgba(0,0,0,0.4);
}
.login-hero-title .accent {
    color: var(--color-surface);
}

.login-hero-subtitle {
    font-size: 1.1rem;
    line-height: 1.7;
    color: rgba(255,255,255,0.82);
    margin: 0 0 36px;
    max-width: 520px;
    font-weight: 400;
}

.login-hero-divider {
    width: 500px;
    height: 5px;
    border-radius: 2px;
    background: var(--color-accent);
    margin-bottom: 28px;
}

.login-hero-features {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 16px;
}

.login-hero-feature {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    font-size: 1rem;
    font-weight: 500;
    color: rgba(255,255,255,0.92);
}

.login-hero-feature i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-lg);
 
    border: 1px solid rgba(30,64,175,0.25);
    color: var(--color-surface); 
    font-size: 17px;
    flex-shrink: 0;
    margin-top: 2px;
}

.login-hero-feature-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.feature-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: rgba(255,255,255,0.95);
    line-height: 1.3;
}

.feature-desc {
    font-size: 0.88rem;
    font-weight: 400;
    color: rgba(255,255,255,0.55);
    line-height: 1.4;
}

.login-panel {
    flex: 1 1 38%;
    min-width: 380px;
    max-width: 520px;
    height: 100vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 48px clamp(24px, 5vw, 56px);
    background: var(--color-surface);
    box-sizing: border-box;
    position: relative;
}

.glass-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    flex: 1;
    height: 100%;
}

.content-container {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0;
}

.login-icon-badge {
    width: 56px; height: 56px;
    border-radius: 50%;
    background: var(--color-accent-light);
    border: 1px solid #dbeafe;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: var(--color-accent);
    margin-top: 40px;
    margin-bottom: 18px;
}

.custom-title-style { text-align: center; margin: 0 0 6px; }
.custom-title-style h1 {
    font-size: 1.7em;
    font-weight: 800;
    color: var(--color-text-primary);
    margin: 0;
    padding: 0;
    letter-spacing: -0.01em;
    font-family: 'Inter', sans-serif;
}
.custom-title-style h1 .accent { color: var(--color-accent); }

.login-subtitle {
    font-size: 0.95rem;
    color: var(--color-text-subtle);
    margin: 0 0 24px;
    font-weight: 400;
}

.header { display: none; }

.login_success {
    width: 100%;
    color: var(--color-success-dark);
    background-color: var(--color-success-bg);
    border: 1px solid var(--color-success-border);
    padding: 13px 18px;
    border-radius: var(--radius-md-2);
    font-weight: 500;
    font-size: 14px;
    margin-bottom: 16px;
    text-align: left;
    box-sizing: border-box;
}

.login_error {
    width: 100%;
    color: var(--color-danger);
    background-color: var(--color-danger-bg);
    border: 1px solid var(--color-danger-border);
    padding: 13px 18px;
    border-radius: var(--radius-md-2);
    font-weight: 500;
    font-size: 14px;
    margin-bottom: 16px;
    text-align: left;
    box-sizing: border-box;
}

.warning-message {
    width: 100%;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    color: var(--color-warning-dark);
    background: var(--color-warning-bg);
    border: 1px solid var(--color-warning-border);
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    margin-bottom: 22px;
    line-height: 1.5;
    text-align: left;
    box-sizing: border-box;
}
.warning-message i { font-size: 14px; color: var(--color-warning); flex-shrink: 0; margin-top: 1px; }

.form-signin {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    text-align: left;
}

.form-signin label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-secondary-alt);
    margin-bottom: 6px;
}

.form-control,
.form-signin .form-control {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid var(--color-border-2);
    border-radius: var(--radius-md-2);
    background: var(--color-surface);
    color: var(--color-text-primary);
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    transition: border-color 0.18s, box-shadow 0.18s;
    box-sizing: border-box;
    margin-bottom: 0;
}
.form-control:focus,
.form-signin .form-control:focus {
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(37,99,235,0.12);
    outline: none;
}
.form-control::placeholder { color: var(--color-text-muted); }

.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}
.password-input-wrapper .form-control {
    padding-right: 44px;
}

.password-input-wrapper .form-control::-ms-reveal,
.password-input-wrapper .form-control::-ms-clear {
    display: none;
    width: 0;
    height: 0;
}

.password-toggle-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 26px;
    height: 26px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: var(--color-text-muted);
    display: flex !important;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: color 0.15s;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    outline: none;
    opacity: 1 !important;
    visibility: visible !important;
    z-index: 5;
    pointer-events: auto;
    box-sizing: border-box;
    flex-shrink: 0;
}
.password-toggle-btn:hover {
    color: var(--color-accent);
}
.password-toggle-btn:focus,
.password-toggle-btn:focus-visible {
    box-shadow: 0 0 0 2px rgba(37,99,235,0.25);
    opacity: 1 !important;
    visibility: visible !important;
}

.password-toggle-btn svg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 18px;
    height: 18px;
    pointer-events: none;
    opacity: 1 !important;
    visibility: visible !important;
}
.password-input-wrapper .form-control:focus ~ .password-toggle-btn,
.password-input-wrapper .form-control:not(:placeholder-shown) ~ .password-toggle-btn,
.password-input-wrapper .form-control:-webkit-autofill ~ .password-toggle-btn {
    opacity: 1 !important;
    visibility: visible !important;
    display: flex !important;
}
.form-signin .btn-primary,
.form-signin .btn-lg {
    width: 100%;
    padding: 12px 20px;
    border-radius: var(--radius-md-2);
    background-color: var(--color-accent);
    color: var(--color-surface);
    font-size: 15px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background-color 0.18s, box-shadow 0.18s;
    box-shadow: 0 1px 2px rgba(37,99,235,0.25);
    font-family: 'Inter', sans-serif;
    margin-top: 4px;
}
.form-signin .btn-primary:hover,
.form-signin .btn-lg:hover {
    background-color: #1d4ed8;
    box-shadow: 0 4px 10px rgba(37,99,235,0.3);
}

.forgot-password-container { width: 100%; margin-top: 4px; text-align: right; }
.forgot-password-container-inside { display: inline-block; }
.forgot-password,
.forgot-password-link {
    text-decoration: none;
    font-size: 13px;
    color: var(--color-accent);
    font-weight: 500;
}
.forgot-password:hover,
.forgot-password-link:hover { text-decoration: underline; }
.forgot-password i { margin-right: 4px; }

.password-reset { margin-top: 10px; }
.password-reset-link { color: var(--color-danger); text-decoration: none; font-weight: 600; font-size: 13px; }
.password-reset-link:hover { text-decoration: underline; }





.environment-badge {
    display: inline-block;
    margin-top: 18px;
    padding: 12px 24px;
    font-size: 20px;
    font-weight: 900;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #ffffff;
    background: #dc2626;
    border: 2px solid #b91c1c;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}



.login-divider {
    width: 100%;
    max-width: 400px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 24px 0 14px;
    color: var(--color-text-muted);
    font-size: 12px;
    font-weight: 500;
}
.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

.contact-support {
    width: 100%;
    max-width: 400px;
    margin-top: 12px;
    text-align: left;
}
.contact-support h2 { display: none; }
.contact-support .forgot-password-container,
.contact-support .forgot-password-container-inside {
    width: 100%;
    text-align: left;
    margin: 0;
    display: block;
}
.contact-support a.forgot-password,
.contact-support a.forgot-password-link {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    background-color: var(--color-surface-4);
    border: 1px solid var(--color-border);
    color: var(--color-text-secondary-alt);
    padding: 14px 16px;
    border-radius: var(--radius-lg);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.18s, border-color 0.18s;
    box-sizing: border-box;
}
.contact-support a.forgot-password:hover,
.contact-support a.forgot-password-link:hover {
    background-color: var(--color-border-4);
    border-color: var(--color-border-2);
    color: var(--color-text-primary);
    text-decoration: none;
}
.contact-support a.forgot-password i,
.contact-support a.forgot-password-link i {
    font-size: 18px;
    color: var(--color-text-subtle);
}

body > .bs-footer,
body > footer.bs-footer {
    display: none;
}

.login-panel-footer {
    width: 100%;
    max-width: 400px;
    margin-top: auto !important;
    padding-top: 20px;
    border-top: 1px solid var(--color-surface-2);
    text-align: center;
    color: var(--color-text-muted);
    font-size: 12px;
}
.login-panel-footer .footer-text {
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}
.login-panel-footer .footer-text + .footer-text {
    margin-top: 8px;
}
.login-panel-footer img { display: block; }
.login-panel-footer .footer-text-highlight { color: var(--color-accent); font-weight: 600; }
.login-panel-footer .footer-link { color: var(--color-accent); text-decoration: none; }
.login-panel-footer .footer-link:hover { text-decoration: underline; }
.footer-text-highlight { color: var(--color-accent); font-weight: 600; }
.footer-link { color: var(--color-accent); text-decoration: none; }
.footer-link:hover { text-decoration: underline; }

@media (min-width: 1400px) {
    .login-hero { flex: 0 0 70%; }
    .login-panel { flex: 0 0 30%; min-width: 420px; }
}

@media (max-width: 1280px) and (min-width: 993px) {
    .login-hero { flex: 1 1 55%; padding: 40px 40px 40px var(--hero-pad-left); }
    .login-hero-title { font-size: 2.6rem; }

    .login-panel {
        flex: 1 1 45%;
        min-width: 340px;
        max-width: 460px;
        height: 100vh;
        padding: 36px clamp(20px, 4vw, 40px) 40px;
        justify-content: flex-start;
        overflow-y: auto;
        align-items: center;
    }

    .login-panel-footer { margin-top: auto !important; }
}

@media (max-width: 992px) {
    body { display: block; }
    #wrap > .container,
    #wrap > .container-fluid { flex-direction: column; }

    .login-hero {
        flex: none;
        width: 100%;
        min-height: 38vh;
        height: 38vh;
        --hero-pad-left: 20px;
        padding: 24px 24px 24px var(--hero-pad-left);
        justify-content: flex-start;
    }
    .login-hero-content { max-width: 100%; }
    .login-hero-title { font-size: 1.7rem; }
    .login-hero-subtitle { font-size: 0.85rem; margin-bottom: 18px; }
    .login-hero-features { gap: 12px; }
    .login-hero-feature { font-size: 0.8rem; }
    .login-hero-logo { top: 16px; }
    .login-hero-logo img { height: 28px; }

    .login-panel {
        flex: none;
        width: 100%;
        min-width: 0;
        max-width: none;
        height: auto;
        overflow-y: visible;
        padding: 32px 20px 40px;
    }
    .login-panel-footer { margin-top: 48px !important; }
}

@media (max-width: 576px) {
    .login-hero {
        min-height: 30vh;
        height: 30vh;
        padding: 16px;
    }
    .login-hero-title { font-size: 1.35rem; }
    .login-hero-divider { margin-bottom: 14px; }
    .login-hero-subtitle { display: none; }
    .login-hero-features { display: none; }
    .login-hero-logo img { height: 24px; }

    .login-panel { padding: 24px 16px 32px; }
    .content-container,
    .form-signin,
    .login-divider,
    .contact-support,
    .login-panel-footer { max-width: 100%; }

    .login-icon-badge { width: 48px; height: 48px; font-size: 18px; margin-bottom: 14px; }
    .custom-title-style h1 { font-size: 1.4em; }
    .login-panel-footer { margin-top: 40px !important; }
}

@keyframes fadeInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

.animate-in-left {
    animation: fadeInLeft 0.9s ease-out both;
}

.animate-in-right {
    animation: fadeInRight 0.9s ease-out both;
}