/**
 * AR Retail & POS — Login Page
 * Tema: Natural Emerald / Hijau Alami Elegan & Nyaman di Pandang
 */
:root {
    --auth-emerald: #059669;
    --auth-emerald-bright: #10B981;
    --auth-emerald-light: #34D399;
    --auth-emerald-dark: #047857;
    --auth-emerald-soft: rgba(16, 185, 129, 0.20);
    --auth-emerald-glow: rgba(16, 185, 129, 0.35);

    --auth-bg: #0C1A13;
    --auth-surface: #12241A;
    --auth-surface-2: #1A3124;
    --auth-surface-hover: #213B2C;
    --auth-border: rgba(52, 211, 153, 0.24);
    --auth-border-subtle: rgba(255, 255, 255, 0.08);

    --auth-text: #D1E7DD;
    --auth-text-heading: #F0FDF4;
    --auth-text-muted: #86A795;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: var(--auth-bg);
    color: var(--auth-text);
}

/* ── Page background ── */
.auth-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background:
        radial-gradient(ellipse 70% 50% at 50% 0%, rgba(16, 185, 129, 0.22) 0%, transparent 60%),
        radial-gradient(ellipse 60% 50% at 100% 100%, rgba(4, 120, 87, 0.18) 0%, transparent 55%),
        radial-gradient(circle at 10% 80%, rgba(5, 150, 105, 0.10) 0%, transparent 45%),
        var(--auth-bg);
}

/* ── Card ── */
.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--auth-surface);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--auth-border);
    box-shadow:
        0 20px 45px -10px rgba(0, 0, 0, 0.65),
        0 0 35px rgba(16, 185, 129, 0.12);
    backdrop-filter: blur(12px);
}

/* ── Brand header ── */
.auth-brand {
    position: relative;
    text-align: center;
    padding: 2.25rem 1.5rem 1.75rem;
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.12) 0%, rgba(18, 36, 26, 0.6) 100%);
    border-bottom: 1px solid var(--auth-border-subtle);
    overflow: hidden;
}

.auth-brand-glow {
    position: absolute;
    top: -30%;
    left: 50%;
    transform: translateX(-50%);
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.28) 0%, transparent 70%);
    pointer-events: none;
}

.auth-logo {
    position: relative;
    max-width: 155px;
    max-height: 155px;
    width: 135px;
    height: 135px;
    object-fit: contain;
    margin: 0 auto;
    filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.45)) drop-shadow(0 0 20px rgba(16, 185, 129, 0.25));
    transition: transform 0.25s ease;
}

.auth-logo:hover {
    transform: scale(1.03);
}

.auth-brand-caption {
    position: relative;
    display: inline-block;
    margin-top: 1rem;
    padding: 0.35rem 1.15rem;
    background: rgba(16, 185, 129, 0.14);
    border: 1px solid rgba(52, 211, 153, 0.35);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #A7F3D0;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

/* ── Form body ── */
.auth-body {
    padding: 1.75rem 1.75rem 2rem;
}

.auth-intro {
    margin-bottom: 1.5rem;
}

.auth-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--auth-text-heading);
    margin: 0 0 0.3rem;
    letter-spacing: -0.02em;
}

.auth-subtitle {
    font-size: 0.84rem;
    color: var(--auth-text-muted);
    margin: 0;
}

.auth-label {
    display: block;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--auth-text);
    margin-bottom: 0.45rem;
}

/* ── Inputs ── */
.auth-input-wrap {
    position: relative;
}

.auth-input-icon {
    position: absolute;
    left: 0.95rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--auth-text-muted);
    font-size: 0.95rem;
    pointer-events: none;
    transition: color 0.15s;
}

.auth-input {
    width: 100%;
    height: 46px;
    padding: 0 2.75rem 0 2.65rem;
    background: var(--auth-surface-2);
    border: 1px solid var(--auth-border-subtle);
    border-radius: 10px;
    color: var(--auth-text-heading);
    font-size: 0.88rem;
    transition: all 0.18s ease-in-out;
}

.auth-input::placeholder {
    color: var(--auth-text-muted);
    opacity: 0.65;
}

.auth-input:focus {
    outline: none;
    background: #14281E;
    border-color: var(--auth-emerald-bright);
    box-shadow: 0 0 0 3px var(--auth-emerald-soft);
}

.auth-input:focus + .auth-input-icon,
.auth-input-wrap:focus-within .auth-input-icon {
    color: var(--auth-emerald-bright);
}

.auth-toggle-pass {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--auth-text-muted);
    padding: 0.35rem 0.5rem;
    font-size: 1rem;
    cursor: pointer;
    line-height: 1;
    border-radius: 6px;
    transition: color 0.15s;
}

.auth-toggle-pass:hover {
    color: var(--auth-emerald-light);
}

/* ── Options row ── */
.auth-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.auth-check-label {
    font-size: 0.83rem;
    color: var(--auth-text-muted) !important;
    cursor: pointer;
}

.form-check-input {
    background-color: var(--auth-surface-2);
    border-color: rgba(52, 211, 153, 0.3);
    cursor: pointer;
}

.form-check-input:checked {
    background-color: var(--auth-emerald-bright);
    border-color: var(--auth-emerald-bright);
}

.form-check-input:focus {
    box-shadow: 0 0 0 2px var(--auth-emerald-soft);
    border-color: var(--auth-emerald-bright);
}

/* ── Submit button ── */
.auth-btn-submit {
    width: 100%;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #10B981 0%, #059669 100%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    color: #FFFFFF;
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.32);
    transition: all 0.18s ease;
}

.auth-btn-submit:hover {
    background: linear-gradient(135deg, #34D399 0%, #059669 100%);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.45);
    color: #FFFFFF;
    transform: translateY(-1px);
}

.auth-btn-submit:active {
    transform: translateY(1px);
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
}

/* ── Alerts ── */
.auth-alert {
    padding: 0.75rem 1rem;
    border-radius: 10px;
    font-size: 0.83rem;
    margin-bottom: 1.25rem;
}

.auth-alert-danger {
    background: rgba(239, 68, 68, 0.12);
    color: #FCA5A5;
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.auth-alert-success {
    background: rgba(16, 185, 129, 0.15);
    color: #6EE7B7;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

/* ── Footer ── */
.auth-footer {
    margin-top: 1.5rem;
    font-size: 0.75rem;
    color: var(--auth-text-muted);
    opacity: 0.75;
}

/* Invalid state */
.auth-input.is-invalid {
    border-color: #EF4444;
}

@media (max-width: 575.98px) {
    .auth-body {
        padding: 1.5rem 1.25rem 1.75rem;
    }

    .auth-brand {
        padding: 1.75rem 1.25rem 1.35rem;
    }

    .auth-logo {
        width: 115px;
        height: 115px;
    }
}
