/* admin/css/login.css */
@import url('./style.css');

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--bg-main);
    /* Deep dark premium charcoal canvas */
}

/* ==========================================================================
   1. FIXED-TOP GLOBAL NAVBAR (Perfectly Proportioned)
   ========================================================================== */
.navbar-global {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5%;
    background-color: var(--bg-surface);
    /* Solid near-black container background */
    border-bottom: var(--y2k-border);
    /* High-impact crisp cream border line */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    z-index: 1050;
    box-sizing: border-box;
}

.nav-logo-block {
    text-decoration: none !important;
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-box-image-wrapper {
    width: 46px;
    height: 46px;
    border: var(--y2k-border);
    border-radius: 50%;
    overflow: hidden;
    background-color: #d2d7c4 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.logo-box-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.nav-logo-block .logo-text {
    display: flex;
    flex-direction: column;
}

.logo-text strong {
    font-size: 15px;
    font-weight: 900;
    letter-spacing: 0.5px;
    line-height: 1.1;
    color: var(--text-primary);
}

.logo-text span {
    font-size: 13px;
    /* Slightly bumped up to match your main site precisely */
    font-weight: 600;
    color: var(--text-secondary);
    line-height: 1.3;
    margin-top: 2px;
    max-width: 580px;
    /* Increased width bounds to let "Environment" sit comfortably */
    display: block;
    /* Allows text to naturally drop to a clean second line if needed on laptops */
    white-space: normal;
    /* REPLACES nowrap - lets the words breathe without cutting off */
}

.system-title {
    font-size: 11px;
    font-weight: 800;
    background-color: var(--bg-main);
    border: var(--y2k-border);
    color: var(--text-primary);
    padding: 6px 14px;
    border-radius: 20px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* ==========================================================================
   2. VIEWPORT CANVAS WITH BRUTALIST GRID BACKGROUND
   ========================================================================== */
.login-viewport-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 20px 40px 20px;
    width: 100%;
    /* Subtle geometric grid line backdrop using CSS linear gradients */
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 40px 40px;
    background-position: center;
}

/* Centered High-Contrast Core Form Box */
.login-card {
    background: var(--bg-surface);
    border: var(--y2k-border);
    border-radius: 24px;
    box-shadow: 8px 8px 0px var(--brand-primary);
    /* Bold, flat structural offset shadow */
    width: 100%;
    max-width: 460px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.login-body {
    padding: 45px 35px 35px 35px;
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* Typography Identity Blocks */
.welcome-text-group {
    text-align: center;
    margin-bottom: 35px;
    position: relative;
}

.welcome-text-group h2 {
    font-size: 11px;
    font-weight: 800;
    color: var(--brand-primary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.welcome-text-group h3 {
    font-size: 1.6rem;
    font-weight: 900;
    color: var(--text-primary);
    letter-spacing: -0.5px;
    margin-bottom: 8px;
    line-height: 1.2;
}

.welcome-text-group p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ==========================================================================
   3. HIGH-CONTRAST Y2K INPUT FIELDS
   ========================================================================== */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 22px;
    width: 100%;
}

.form-group label {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 0.2px;
}

.form-group input {
    width: 100%;
    background-color: var(--bg-main);
    border: var(--y2k-border);
    border-radius: 12px;
    padding: 13px 16px;
    font-size: 14px;
    color: var(--text-charcoal);
    outline: none;
    transition: var(--transition-smooth);
}

.form-group input:focus {
    border-color: var(--brand-primary);
    background-color: var(--bg-surface);
}

/* Custom placeholder visibility adjustments */
.form-group input::placeholder {
    color: #5e5d5a;
}

.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.password-input-wrapper input {
    padding-right: 48px;
}

.toggle-password-btn {
    position: absolute;
    right: 14px;
    background: none;
    border: none;
    color: var(--brand-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    transition: var(--transition-smooth);
}

.toggle-password-btn:hover {
    color: var(--brand-light);
}

/* ==========================================================================
   4. PREMIUM INTERACTIVE ACTION SYSTEM BUTTONS
   ========================================================================== */
.action-wrapper {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: 10px;
    margin-bottom: 25px;
}

.btn-submit {
    width: 100%;
    background-color: var(--brand-primary);
    /* Balanced matte matcha green tint */
    color: #121110 !important;
    /* Flat dark print font color text rules */
    border: var(--y2k-border);
    border-radius: 14px;
    padding: 15px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 4px 4px 0px var(--text-primary);
    /* Rigid un-blurred block shadow line */
    transition: var(--transition-smooth);
}

.btn-submit:hover {
    background-color: var(--brand-light);
    transform: translateY(-2px);
    box-shadow: 6px 6px 0px var(--text-primary);
}

.btn-submit:active {
    transform: translateY(1px);
    box-shadow: 2px 2px 0px var(--text-primary);
}

/* Dynamic Notification System Banner */
.error-banner {
    display: none;
    background-color: #2D1414;
    border: 2px solid #DE3B3B;
    color: #FF8787;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 20px;
}

/* Base Card Clear Footer Notice */
.login-footer {
    text-align: center;
    border-top: 1.5px dashed #2b2a27;
    /* Clean, dashed border separator line style */
    padding-top: 22px;
    margin-top: 5px;
    width: 100%;
}

.login-footer p {
    font-size: 12px;
    color: #a3a19c;
    font-weight: 600;
}

/* admin/css/login.css additions */

.forgot-password-wrapper {
    display: flex;
    justify-content: flex-end;
    margin-top: 6px;
}

.link-forgot-password {
    background: none;
    border: none;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-secondary);
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    transition: var(--transition-smooth);
    padding: 2px 4px;
}

.link-forgot-password:hover {
    color: var(--brand-primary);
    text-decoration: underline;
}

/* 🚨 Right-side sliding toast notifications alignment core styles */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    font-family: inherit;
}

.toast-notification {
    background: #111111;
    color: #ff4d4d;
    border: 2px solid #ff4d4d;
    box-shadow: 4px 4px 0px #ff4d4d;
    padding: 15px 20px;
    margin-bottom: 10px;
    min-width: 300px;
    max-width: 450px;
    font-weight: bold;
    font-size: 14px;
    display: none; /* Controlled via script toggle */
    animation: slideInLeft 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes slideInLeft {
    from {
        transform: translateX(120%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ==========================================================================
   5. DEVICE ADAPTIVE Breakpoints RESPONSIVITY MATRIX
   ========================================================================== */
/* Update this exact media query block at the bottom of admin/css/login.css */
@media (max-width: 992px) {
    .navbar-global {
        height: 65px;
        padding: 0 12px;
        /* Pulls padding inward slightly to save precious horizontal pixels */
    }

    .logo-box-image-wrapper {
        width: 36px;
        /* Slightly tightened icon footprint */
        height: 36px;
    }

    .logo-text strong {
        font-size: 15px;
        /* Perfect balance for mobile viewports */
    }

    /* ❌ Drops the long organization tagline instantly */
    .logo-text span {
        display: none !important;
    }

    /* 📱 COHESIVE MOBILE CMS BADGE LAYOUT RULES */
    .system-title {
        display: block !important;
        font-size: 9px;
        padding: 4px 8px;
        letter-spacing: 0.5px;
        white-space: nowrap;
        /* Forces the badge container to lock onto a single line */
    }

    /* ⚡ THE REAL PHONES FIX: Dynamic content compression for narrow viewports */
    @media (max-width: 400px) {
        .navbar-global {
            padding: 0 10px;
        }

        /* Swaps out or overrides long text layout footprints via CSS content injects */
        .system-title {
            font-size: 8px;
            padding: 3px 6px;
        }
    }
}

@media (max-width: 480px) {
    .login-body {
        padding: 35px 20px 25px 20px;
    }

    .welcome-text-group h3 {
        font-size: 1.35rem;
    }
}