/* =========================================================
   FM COLLECTIONS — AUTHENTICATION LAYOUT
   File: public/css/auth-layout.css
========================================================= */


/* =========================================================
   RESET AND VARIABLES
========================================================= */

:root {
    --auth-primary: #2e7d32;
    --auth-primary-dark: #166534;
    --auth-primary-deep: #071d0c;
    --auth-primary-soft: #f0fdf4;

    --auth-text: #0f172a;
    --auth-text-soft: #334155;
    --auth-muted: #64748b;

    --auth-border: #dbe4ee;
    --auth-border-soft: #e8edf3;

    --auth-surface: #ffffff;
    --auth-surface-soft: #f8fafc;
    --auth-page-bg: #f3f6f9;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    min-width: 320px;
    min-height: 100vh;
    margin: 0;

    color: var(--auth-text);
    background: var(--auth-page-bg);

    font-family:
        "Inter",
        Arial,
        sans-serif;

    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family:
        "Poppins",
        "Inter",
        sans-serif;
}

a {
    color: inherit;
}

button,
input,
textarea,
select {
    font: inherit;
}


/* =========================================================
   MAIN LAYOUT
========================================================= */

.auth-layout {
    display: grid;
    grid-template-columns: minmax(480px, 1fr) minmax(520px, 620px);

    width: 100%;
    min-height: 100vh;
}


/* =========================================================
   BRANDING PANEL
========================================================= */

.auth-brand-panel {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;

    min-height: 100vh;
    padding: 64px;

    color: #ffffff;

    background:
        radial-gradient(
            circle at 85% 10%,
            rgba(255, 255, 255, 0.1),
            transparent 30%
        ),
        radial-gradient(
            circle at 10% 90%,
            rgba(91, 210, 105, 0.12),
            transparent 32%
        ),
        linear-gradient(
            145deg,
            #061208 0%,
            #0c3513 38%,
            #175b21 72%,
            #267b31 100%
        );
}

.auth-brand-panel::before {
    content: "";

    position: absolute;
    right: -190px;
    bottom: -210px;

    width: 530px;
    height: 530px;

    border: 70px solid rgba(255, 255, 255, 0.035);
    border-radius: 50%;

    pointer-events: none;
}

.auth-brand-panel::after {
    content: "";

    position: absolute;
    top: -140px;
    left: -130px;

    width: 350px;
    height: 350px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.025);

    pointer-events: none;
}

.auth-brand-content {
    position: relative;
    z-index: 2;

    width: min(100%, 560px);
}


/* =========================================================
   BRAND LOGO
========================================================= */

.auth-brand-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 82px;
    height: 82px;
    margin-bottom: 30px;

    border-radius: 24px;

    color: var(--auth-primary-dark);
    background: #ffffff;

    font-size: 29px;
    line-height: 1;
    font-weight: 950;
    text-decoration: none;

    box-shadow:
        0 18px 38px rgba(0, 0, 0, 0.22);
}


/* =========================================================
   BRAND HEADING
========================================================= */

.auth-brand-eyebrow,
.auth-card-eyebrow {
    display: block;

    margin-bottom: 9px;

    font-size: 10px;
    line-height: 1;
    font-weight: 900;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.auth-brand-eyebrow {
    color: #a7f3b3;
}

.auth-card-eyebrow {
    color: var(--auth-primary);
}

.auth-brand-heading h1 {
    margin: 0 0 16px;

    color: #ffffff;

    font-size: clamp(38px, 4vw, 52px);
    line-height: 1.12;
    font-weight: 950;
    letter-spacing: -0.045em;
}

.auth-brand-heading p {
    max-width: 520px;
    margin: 0;

    color: rgba(255, 255, 255, 0.84);

    font-size: 15px;
    line-height: 1.85;
}


/* =========================================================
   BRAND FEATURES
========================================================= */

.auth-brand-features {
    display: grid;
    gap: 13px;

    margin-top: 34px;
}

.auth-brand-feature {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 14px;
    align-items: center;

    padding: 15px 17px;

    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;

    background: rgba(255, 255, 255, 0.075);

    backdrop-filter: blur(9px);
}

.auth-brand-feature > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    border-radius: 13px;

    color: #75f488;
    background: rgba(255, 255, 255, 0.08);

    font-size: 20px;
}

.auth-brand-feature strong {
    display: block;

    margin-bottom: 3px;

    color: #ffffff;

    font-size: 13px;
    line-height: 1.4;
    font-weight: 850;
}

.auth-brand-feature small {
    display: block;

    color: rgba(255, 255, 255, 0.7);

    font-size: 10px;
    line-height: 1.55;
}


/* =========================================================
   BRAND STATISTICS
========================================================= */

.auth-brand-statistics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 13px;

    margin-top: 28px;
}

.auth-brand-statistics article {
    padding: 17px 12px;

    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 15px;

    background: rgba(255, 255, 255, 0.065);

    text-align: center;
}

.auth-brand-statistics strong {
    display: block;

    margin-bottom: 5px;

    color: #ffffff;

    font-size: 22px;
    line-height: 1;
    font-weight: 950;
}

.auth-brand-statistics span {
    display: block;

    color: rgba(255, 255, 255, 0.7);

    font-size: 9px;
    line-height: 1.4;
    font-weight: 700;
}


/* =========================================================
   FORM PANEL
========================================================= */

.auth-form-panel {
    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 100vh;
    padding: 50px 42px;

    background:
        radial-gradient(
            circle at top right,
            rgba(46, 125, 50, 0.055),
            transparent 32%
        ),
        var(--auth-page-bg);
}

.auth-form-wrapper {
    width: min(100%, 520px);
}


/* =========================================================
   MOBILE LOGO
========================================================= */

.auth-mobile-logo {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 10px;

    margin-bottom: 22px;

    color: var(--auth-text);
    text-decoration: none;
}

.auth-mobile-logo span {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 45px;
    height: 45px;

    border-radius: 13px;

    color: #ffffff;
    background: var(--auth-primary);

    font-size: 16px;
    font-weight: 950;
}

.auth-mobile-logo strong {
    font-family: "Poppins", sans-serif;
    font-size: 17px;
    font-weight: 850;
}


/* =========================================================
   AUTH CARD
========================================================= */

.auth-card {
    width: 100%;
    padding: 38px;

    border: 1px solid var(--auth-border-soft);
    border-radius: 24px;

    background: var(--auth-surface);

    box-shadow:
        0 24px 58px rgba(15, 23, 42, 0.09),
        0 4px 13px rgba(15, 23, 42, 0.035);
}


/* =========================================================
   AUTH CARD HEADER
========================================================= */

.auth-card-header {
    margin-bottom: 28px;

    text-align: center;
}

.auth-card-header h2 {
    margin: 0 0 10px;

    color: var(--auth-text);

    font-size: clamp(28px, 4vw, 36px);
    line-height: 1.2;
    font-weight: 950;
    letter-spacing: -0.035em;
}

.auth-card-subtitle {
    max-width: 430px;
    margin: 0 auto;

    color: var(--auth-muted);

    font-size: 13px;
    line-height: 1.65;
}


/* =========================================================
   SHARED ALERT
========================================================= */

.auth-layout-alert {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 12px;
    align-items: flex-start;

    margin-bottom: 20px;
    padding: 15px;

    border: 1px solid;
    border-radius: 13px;
}

.auth-layout-alert-success {
    color: #14532d;
    border-color: #bbf7d0;
    background: #f0fdf4;
}

.auth-layout-alert-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    border: 1px solid #bbf7d0;
    border-radius: 50%;

    color: var(--auth-primary);
    background: #ffffff;

    font-size: 15px;
}

.auth-layout-alert strong {
    display: block;

    margin-bottom: 3px;

    font-size: 12px;
    font-weight: 900;
}

.auth-layout-alert p {
    margin: 0;

    font-size: 10px;
    line-height: 1.6;
}


/* =========================================================
   CONTENT
========================================================= */

.auth-card-content {
    width: 100%;
}


/* =========================================================
   LAYOUT FOOTER
========================================================= */

.auth-layout-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;

    margin-top: 18px;
    padding: 0 4px;

    color: var(--auth-muted);

    font-size: 9px;
    line-height: 1.5;
}

.auth-layout-footer p {
    margin: 0;
}

.auth-layout-footer div {
    display: flex;
    align-items: center;
    gap: 12px;
}

.auth-layout-footer a {
    color: var(--auth-primary-dark);

    font-weight: 800;
    text-decoration: none;
}

.auth-layout-footer a:hover {
    text-decoration: underline;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 1100px) {
    .auth-layout {
        grid-template-columns: minmax(390px, 0.9fr) minmax(470px, 1.1fr);
    }

    .auth-brand-panel {
        padding: 45px;
    }

    .auth-brand-statistics {
        grid-template-columns: 1fr;
    }
}


/* =========================================================
   MOBILE / SMALL TABLET
========================================================= */

@media (max-width: 900px) {
    .auth-layout {
        display: block;
    }

    .auth-brand-panel {
        display: none;
    }

    .auth-form-panel {
        min-height: 100vh;
        padding: 34px 20px;
    }

    .auth-mobile-logo {
        display: flex;
    }
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 560px) {
    .auth-form-panel {
        align-items: flex-start;

        padding: 24px 12px 36px;
    }

    .auth-card {
        padding: 28px 20px;

        border-radius: 19px;
    }

    .auth-card-header {
        margin-bottom: 24px;
    }

    .auth-card-header h2 {
        font-size: 29px;
    }

    .auth-layout-footer {
        align-items: center;
        flex-direction: column;

        text-align: center;
    }
}


/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 380px) {
    .auth-card {
        padding: 25px 16px;
    }

    .auth-card-header h2 {
        font-size: 27px;
    }
}


/* =========================================================
   REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {
    .auth-layout *,
    .auth-layout *::before,
    .auth-layout *::after {
        scroll-behavior: auto !important;
        transition: none !important;
        animation: none !important;
    }
}

/* =========================================================
   COMPACT DESKTOP HEIGHT FIX
   Prevents logo/content clipping on shorter laptop screens
========================================================= */

@media (min-width: 901px) and (max-height: 850px) {

    .auth-layout {
        align-items: stretch;
    }

    .auth-brand-panel {
        align-items: flex-start;

        min-height: 100vh;
        padding: 24px 54px;

        overflow-y: auto;
    }

    .auth-brand-content {
        width: min(100%, 560px);
        margin: 0 auto;
    }

    .auth-brand-logo {
        width: 64px;
        height: 64px;
        margin-bottom: 18px;

        border-radius: 18px;

        font-size: 23px;
    }

    .auth-brand-eyebrow {
        margin-bottom: 7px;

        font-size: 9px;
    }

    .auth-brand-heading h1 {
        margin-bottom: 11px;

        font-size: 38px;
    }

    .auth-brand-heading p {
        font-size: 13px;
        line-height: 1.65;
    }

    .auth-brand-features {
        gap: 10px;

        margin-top: 23px;
    }

    .auth-brand-feature {
        grid-template-columns: 42px minmax(0, 1fr);
        gap: 12px;

        padding: 11px 14px;

        border-radius: 13px;
    }

    .auth-brand-feature > span {
        width: 42px;
        height: 42px;

        border-radius: 11px;

        font-size: 17px;
    }

    .auth-brand-feature strong {
        margin-bottom: 2px;

        font-size: 12px;
    }

    .auth-brand-feature small {
        font-size: 9px;
        line-height: 1.4;
    }

    .auth-brand-statistics {
        gap: 10px;

        margin-top: 17px;
    }

    .auth-brand-statistics article {
        padding: 12px 9px;

        border-radius: 13px;
    }

    .auth-brand-statistics strong {
        font-size: 18px;
    }

    .auth-brand-statistics span {
        font-size: 8px;
    }

    .auth-form-panel {
        align-items: flex-start;

        min-height: 100vh;
        padding: 30px 34px;

        overflow-y: auto;
    }

    .auth-form-wrapper {
        margin: auto;
    }

    .auth-card {
        padding: 30px 38px;

        border-radius: 21px;
    }

    .auth-card-header {
        margin-bottom: 23px;
    }

    .auth-card-header h2 {
        margin-bottom: 8px;

        font-size: 32px;
    }

    .auth-card-subtitle {
        font-size: 12px;
        line-height: 1.55;
    }

    .auth-layout-footer {
        margin-top: 13px;
    }
}