/* =============================================================================
   Zaituna Baia — Login / Auth Page
   Split layout: brand panel (left) + form panel (right)
   ============================================================================= */

*, *::before, *::after { box-sizing: border-box; }

:root {
    --auth-navy:      #0f172a;
    --auth-navy-mid:  #1b2133;
    --auth-navy-soft: #1e3a5f;
    --auth-amber:     #e7a022;
    --auth-amber-dk:  #c8891a;
    --auth-green:     #16a34a;
    --auth-text:      #1b2133;
    --auth-muted:     #64748b;
    --auth-border:    #e2e8f0;
    --auth-bg:        #f8fafc;
    --auth-white:     #ffffff;
    --auth-radius:    12px;
    --auth-dur:       .22s;
    --auth-ease:      cubic-bezier(.4, 0, .2, 1);
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: 'Inter', 'Cairo', 'Nunito', sans-serif;
    font-size: 15px;
    color: var(--auth-text);
    background: var(--auth-bg);
    -webkit-font-smoothing: antialiased;
}

/* ── Layout ─────────────────────────────────────────────────────────────────── */
.fabt-login {
    display: flex;
    min-height: 100vh;
}

/* ── Brand panel ────────────────────────────────────────────────────────────── */
.fabt-login__brand {
    position: relative;
    width: 42%;
    flex-shrink: 0;
    background: linear-gradient(145deg, var(--auth-navy) 0%, var(--auth-navy-soft) 60%, #16336b 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 48px;
    overflow: hidden;
    color: #fff;
}

/* decorative blurred circles */
.fabt-login__brand::before {
    content: '';
    position: absolute;
    width: 380px;
    height: 380px;
    border-radius: 50%;
    background: rgba(231, 160, 34, .12);
    top: -80px;
    right: -100px;
    filter: blur(1px);
}
.fabt-login__brand::after {
    content: '';
    position: absolute;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(22, 163, 74, .10);
    bottom: -60px;
    left: -60px;
    filter: blur(2px);
}

.fabt-login__brand-inner {
    position: relative;
    z-index: 1;
    text-align: center;
}

.fabt-login__logo {
    display: block;
    margin: 0 auto 28px;
    max-width: 180px;
    max-height: 130px;
    object-fit: contain;
    filter: brightness(0) invert(1) drop-shadow(0 4px 24px rgba(0,0,0,.4));
}

.fabt-login__brand-title {
    font-size: 1.55rem;
    font-weight: 700;
    letter-spacing: -.3px;
    color: #fff;
    margin: 0 0 10px;
}

.fabt-login__brand-sub {
    font-size: .9rem;
    font-weight: 400;
    color: var(--auth-amber);
    margin: 0 0 40px;
    letter-spacing: .3px;
}

/* feature bullets */
.fabt-login__features {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
    text-align: left;
    max-width: 240px;
}
.fabt-login__features li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: .82rem;
    color: rgba(255,255,255,.75);
}
.fabt-login__features li::before {
    content: '';
    display: block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--auth-amber);
    flex-shrink: 0;
}

/* bottom dot pattern */
.fabt-login__dots {
    position: absolute;
    bottom: 32px;
    right: 32px;
    display: grid;
    grid-template-columns: repeat(5, 6px);
    gap: 5px;
    z-index: 1;
}
.fabt-login__dots span {
    display: block;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(255,255,255,.18);
}

/* ── Form panel ─────────────────────────────────────────────────────────────── */
.fabt-login__panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 32px;
    background: var(--auth-bg);
}

.fabt-login__card {
    width: 100%;
    max-width: 400px;
}

/* heading */
.fabt-login__heading {
    margin: 0 0 6px;
    font-size: 1.55rem;
    font-weight: 700;
    color: var(--auth-text);
    letter-spacing: -.3px;
}
.fabt-login__subheading {
    font-size: .875rem;
    color: var(--auth-muted);
    margin: 0 0 32px;
}

/* alerts */
.fabt-login__alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border-radius: var(--auth-radius);
    font-size: .83rem;
    margin-bottom: 20px;
    line-height: 1.5;
}
.fabt-login__alert--danger {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}
.fabt-login__alert--success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}
.fabt-login__alert__close {
    margin-left: auto;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    line-height: 1;
    color: inherit;
    opacity: .6;
    font-size: 1rem;
}
.fabt-login__alert__close:hover { opacity: 1; }

/* form */
.fabt-login__form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* field */
.fabt-login__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.fabt-login__label {
    font-size: .8rem;
    font-weight: 600;
    color: var(--auth-text);
    letter-spacing: .2px;
}
.fabt-login__input-wrap {
    position: relative;
}
.fabt-login__input {
    width: 100%;
    padding: 11px 42px 11px 14px;
    border: 1.5px solid var(--auth-border);
    border-radius: 8px;
    font-size: .9rem;
    color: var(--auth-text);
    background: var(--auth-white);
    outline: none;
    transition: border-color var(--auth-dur) var(--auth-ease),
                box-shadow var(--auth-dur) var(--auth-ease);
    font-family: inherit;
}
.fabt-login__input::placeholder { color: #b0bec5; }
.fabt-login__input:focus {
    border-color: var(--auth-amber);
    box-shadow: 0 0 0 3px rgba(231, 160, 34, .15);
}
.fabt-login__input.is-error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, .1);
}
.fabt-login__input-icon {
    position: absolute;
    right: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    pointer-events: none;
    font-size: .95rem;
    display: flex;
    align-items: center;
}
.fabt-login__toggle-pw {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 2px 4px;
    cursor: pointer;
    color: #94a3b8;
    font-size: .9rem;
    display: flex;
    align-items: center;
    transition: color var(--auth-dur);
}
.fabt-login__toggle-pw:hover { color: var(--auth-amber); }

.fabt-login__error-text {
    font-size: .75rem;
    color: #ef4444;
    margin: 0;
}

/* submit button */
.fabt-login__btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, var(--auth-amber) 0%, var(--auth-amber-dk) 100%);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-size: .92rem;
    font-weight: 700;
    letter-spacing: .3px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 4px;
    transition: opacity var(--auth-dur), transform var(--auth-dur);
    font-family: inherit;
    box-shadow: 0 4px 14px rgba(231, 160, 34, .35);
}
.fabt-login__btn:hover {
    opacity: .9;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(231, 160, 34, .40);
}
.fabt-login__btn:active {
    transform: translateY(0);
    opacity: 1;
}
.fabt-login__btn svg {
    width: 16px;
    height: 16px;
    transition: transform var(--auth-dur);
}
.fabt-login__btn:hover svg { transform: translateX(3px); }

/* copyright */
.fabt-login__copy {
    margin-top: 36px;
    font-size: .72rem;
    color: #b0bec5;
    text-align: center;
}
.fabt-login__copy strong { color: var(--auth-muted); font-weight: 600; }

/* ── Responsive ─────────────────────────────────────────────────────────────── */
@media (max-width: 860px) {
    .fabt-login { flex-direction: column; }

    .fabt-login__brand {
        width: 100%;
        padding: 40px 24px 36px;
        flex-direction: row;
        justify-content: center;
        gap: 24px;
        min-height: auto;
    }
    .fabt-login__brand::before { width: 200px; height: 200px; top: -60px; right: -40px; }
    .fabt-login__brand::after  { width: 140px; height: 140px; bottom: -40px; left: -30px; }
    .fabt-login__brand-inner { display: flex; align-items: center; gap: 18px; text-align: left; }
    .fabt-login__logo { margin: 0; width: 72px; max-width: 72px; }
    .fabt-login__brand-title { font-size: 1.2rem; margin-bottom: 4px; }
    .fabt-login__brand-sub  { margin-bottom: 0; font-size: .8rem; }
    .fabt-login__features, .fabt-login__dots { display: none; }

    .fabt-login__panel { padding: 36px 20px 48px; }
}

@media (max-width: 480px) {
    .fabt-login__brand { padding: 28px 20px; }
    .fabt-login__brand-inner { flex-direction: column; text-align: center; }
    .fabt-login__logo { width: 80px; max-width: 80px; margin-bottom: 8px; }
}

/* ── Dark mode (body.dark-mode) ─────────────────────────────────────────────── */
.dark-mode {
    background: #0f172a;
}
.dark-mode .fabt-login__brand {
    background: linear-gradient(145deg, #07101f 0%, #0e2340 60%, #102545 100%);
}
.dark-mode .fabt-login__panel { background: #0f172a; }
.dark-mode .fabt-login__card { }
.dark-mode .fabt-login__heading { color: #f1f5f9; }
.dark-mode .fabt-login__subheading { color: #64748b; }
.dark-mode .fabt-login__label { color: #cbd5e1; }
.dark-mode .fabt-login__input {
    background: #1e293b;
    border-color: #334155;
    color: #f1f5f9;
}
.dark-mode .fabt-login__input::placeholder { color: #475569; }
.dark-mode .fabt-login__input:focus {
    border-color: var(--auth-amber);
    box-shadow: 0 0 0 3px rgba(231, 160, 34, .18);
}
.dark-mode .fabt-login__alert--danger {
    background: rgba(185, 28, 28, .15);
    border-color: rgba(239, 68, 68, .25);
    color: #fca5a5;
}
.dark-mode .fabt-login__copy { color: #334155; }
.dark-mode .fabt-login__copy strong { color: #475569; }
