/* ================================================================
   auth_styles.css — Split layout for auth & setup pages
   Used by: login, register, forgot_password, reset_password,
            employee_setup, employer_setup
   ================================================================ */

:root {
    --auth-primary: #4C5BC5;
    --auth-primary-hover: #3a49b0;
    --auth-gray: #797979;
    --auth-light-gray: #ddd;
    --auth-black: #1E1E1E;
    --auth-white: #ffffff;
    --auth-bg: #f6f7fa;
    --auth-accent-blue: #90B3F3;
    --auth-font-heading: 'Dela Gothic One', cursive;
    --auth-font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

/* ── Reset ── */
html.auth-html,
html.auth-html body.auth-body {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow-x: hidden;
    font-family: var(--auth-font-body);
    color: var(--auth-black);
    background: var(--auth-white);
}

/* ── Split container ── */
.auth-split {
    display: flex;
    min-height: 100vh;
}

/* ── Left panel — solid dark background ── */
.auth-left {
    width: 50%;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    background: var(--auth-black);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.auth-left-overlay {
    display: none;
}

.auth-left-logo {
    position: absolute;
    top: 30px;
    left: 30px;
    z-index: 2;
}

.auth-left-logo img {
    height: 70px;
    width: auto;
}

.auth-left-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    padding: 0 40px;
}

.auth-left-heading {
    font-family: var(--auth-font-heading);
    font-weight: 400;
    font-size: 36px;
    color: var(--auth-white);
    margin: 0 0 16px;
}

.auth-left-heading-sm {
    font-family: var(--auth-font-heading);
    font-weight: 400;
    font-size: 28px;
    color: var(--auth-white);
    margin: 0 0 8px;
}

.auth-left-role {
    font-family: var(--auth-font-heading);
    font-weight: 400;
    font-size: 48px;
    color: var(--auth-white);
    margin: 0;
}

.auth-left-subtext {
    font-family: var(--auth-font-body);
    font-weight: 400;
    font-size: 19.2px;
    color: var(--auth-white);
    max-width: 420px;
    text-align: left;
    line-height: 1.45;
    margin: 0;
}

.auth-subtext-line1 {
    white-space: nowrap;
}

/* Legacy class — hide if still in HTML */
.auth-left-text {
    display: none;
}


/* ── Right panel — scrollable form area ── */
.auth-right {
    width: 52%;
    margin-left: 48%;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 40px 32px;
    box-sizing: border-box;
    overflow-y: auto;
    background: var(--auth-white);
    border-radius: 24px 0 0 24px;
    position: relative;
    z-index: 2;
}

/* ── Close button (top-right X) ── */
.auth-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    line-height: 1;
    color: #797979;
    text-decoration: none;
    transition: background 0.2s;
    z-index: 3;
}
.auth-close-btn:hover {
    background: #f5f5f5;
    color: #797979;
    text-decoration: none;
}

.auth-form-container {
    max-width: 480px;
    width: 100%;
}

/* ── Title ── */
.auth-title {
    font-family: var(--auth-font-heading);
    font-weight: 400;
    font-size: 28px;
    text-transform: uppercase;
    color: var(--auth-black);
    margin: 0 0 28px;
    letter-spacing: 0.5px;
}

/* ── Alerts ── */
.auth-alert {
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 18px;
    font-family: var(--auth-font-body);
}
.auth-alert--danger {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}
.auth-alert--success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}
.auth-alert--info {
    background: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

/* ── Form group ── */
.auth-field {
    margin-bottom: 22px;
}

.auth-label {
    display: block;
    font-family: var(--auth-font-body);
    font-weight: 400;
    font-size: 13px;
    color: var(--auth-gray);
    margin-bottom: 4px;
}

.auth-input {
    display: block;
    width: 100%;
    border: none;
    border-bottom: 1px solid var(--auth-light-gray);
    border-radius: 0;
    padding: 10px 0;
    font-family: var(--auth-font-body);
    font-size: 15px;
    color: var(--auth-black);
    background: transparent;
    outline: none;
    transition: border-color 0.2s;
    box-sizing: border-box;
}
.auth-input:focus {
    border-bottom-color: var(--auth-primary);
    box-shadow: none;
}
.auth-input::placeholder {
    color: #bbb;
}
/* Override Bootstrap form-control if both classes used */
.auth-input.form-control {
    border: none;
    border-bottom: 1px solid var(--auth-light-gray);
    border-radius: 0;
    box-shadow: none;
    padding: 10px 0;
}
.auth-input.form-control:focus {
    border-bottom-color: var(--auth-primary);
    box-shadow: none;
}

/* ── Checkbox / Radio ── */
.auth-checks {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 14px;
}
.auth-check {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 0;
    font-size: 12px;
    color: var(--auth-black);
    font-family: var(--auth-font-body);
    cursor: pointer;
    line-height: 1.35;
}
.auth-check-text {
    flex: 1;
    min-width: 0;
}
@media (min-width: 480px) {
    .auth-check-text {
        white-space: nowrap;
    }
}
.auth-check input[type="checkbox"],
.auth-check input[type="radio"] {
    margin: 2px 0 0;
    flex-shrink: 0;
    accent-color: var(--auth-primary);
}
.auth-check a {
    color: var(--auth-primary);
}
.auth-required {
    color: #EF522C;
}

/* Radio group for role selection */
.auth-role-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 22px;
}
.auth-role-group-label {
    font-family: var(--auth-font-body);
    font-weight: 400;
    font-size: 13px;
    color: var(--auth-gray);
    margin-bottom: 2px;
}
.auth-role-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border: 1px solid var(--auth-light-gray);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    font-size: 14px;
}
.auth-role-option:hover {
    border-color: var(--auth-primary);
}
.auth-role-option input[type="radio"] {
    accent-color: var(--auth-primary);
    flex-shrink: 0;
}
.auth-role-option.active,
.auth-role-option:has(input:checked) {
    border-color: var(--auth-primary);
    background: #f0f1ff;
}

/* ── Submit button ── */
.auth-btn {
    display: block;
    width: 100%;
    border-radius: 30px;
    background: var(--auth-primary);
    color: var(--auth-white);
    border: none;
    padding: 13px 24px;
    font-family: var(--auth-font-body);
    font-weight: 600;
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 8px;
}
.auth-btn:hover {
    background: var(--auth-primary-hover);
}

.auth-btn--outline {
    display: block;
    width: 100%;
    border-radius: 30px;
    background: var(--auth-white);
    color: var(--auth-black);
    border: 1.5px solid var(--auth-light-gray);
    padding: 13px 24px;
    font-family: var(--auth-font-body);
    font-weight: 600;
    font-size: 15px;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
    margin: 0;
    text-align: center;
    box-sizing: border-box;
}
.auth-btn--outline:hover {
    border-color: #c6c6c6;
    box-shadow: 0 1px 6px rgba(32, 33, 36, 0.12);
}

.auth-btn-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 4px;
}

.auth-prose {
    font-family: var(--auth-font-body);
    font-size: 14px;
    line-height: 1.65;
    color: var(--auth-black);
    margin: 0 0 14px;
}
.auth-prose--muted {
    font-size: 13px;
    color: var(--auth-gray);
}
.auth-prose a {
    color: var(--auth-primary);
    text-decoration: underline;
}
.auth-prose a:hover {
    color: var(--auth-primary-hover);
}

/* ── Links ── */
.auth-links {
    margin-top: 20px;
    text-align: center;
    font-size: 14px;
    line-height: 1.8;
}
.auth-link {
    color: var(--auth-black);
    text-decoration: underline;
    font-family: var(--auth-font-body);
    transition: color 0.2s;
}
.auth-link:hover {
    color: var(--auth-primary);
}

/* ── Social footer ── */
.auth-social {
    margin-top: 36px;
    text-align: center;
}
.auth-social-text {
    font-size: 12px;
    color: var(--auth-gray);
    margin-bottom: 10px;
    font-family: var(--auth-font-body);
}
.auth-social-icons {
    display: flex;
    justify-content: center;
    gap: 16px;
}
.auth-social-icons a {
    color: var(--auth-gray);
    font-size: 20px;
    text-decoration: none;
    transition: color 0.2s;
}
.auth-social-icons a:hover {
    color: var(--auth-primary);
}

/* ── Setup pages modifier (wider form) ── */
.auth-right--setup {
    padding: 30px 24px;
    align-items: flex-start;
}
.auth-right--setup .auth-form-container {
    max-width: 920px;
    padding-top: 20px;
}

/* Setup form keeps its own internal styles from setup_profile_shell.css */
.auth-right--setup .setup-panel {
    max-width: 100%;
    margin: 0;
    box-shadow: none;
    border-radius: 0;
    background: transparent;
    padding: 0;
}
.auth-right--setup .setup-title {
    font-family: var(--auth-font-heading);
    font-weight: 400;
    text-transform: uppercase;
}

/* ── Responsive ── */
@media (max-width: 767.98px) {
    .auth-left {
        display: none;
    }
    .auth-right {
        width: 100%;
        margin-left: 0;
        padding: 30px 20px;
    }
    .auth-right--setup {
        padding: 20px 16px;
    }
    .auth-title {
        font-size: 24px;
    }
}

/* ── Google OAuth Button ────────────────────────────── */
/* Обвивка: в някои браузъри <button> не се разтяга до 100% без block родител */
.auth-google-wrap {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.auth-google-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0 16px;
    color: #999;
    font-size: 13px;
    font-family: 'Inter', sans-serif;
}
.auth-google-divider::before,
.auth-google-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}
button.auth-google-btn {
    width: 100%;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 20px;
    border: 1.5px solid #dadce0;
    border-radius: 999px;
    background: #fff;
    color: #3c4043;
    font-family: var(--auth-font-body);
    font-size: 15px;
    font-weight: 500;
    line-height: 1.2;
    min-height: 48px;
    height: auto;
    box-sizing: border-box;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
    transition: box-shadow 0.2s, border-color 0.2s;
    margin: 0 0 4px;
    flex-shrink: 0;
    text-align: center;
}

/* Firefox: премахва „нативния“ вътрешен padding — иначе бутонът изглежда малък/смачкан */
button.auth-google-btn::-moz-focus-inner {
    border: 0;
    padding: 0;
}

button.auth-google-btn svg {
    flex: 0 0 auto;
    display: block;
}
button.auth-google-btn:hover {
    box-shadow: 0 1px 6px rgba(32, 33, 36, .28);
    border-color: #c6c6c6;
}

/* Cloudflare Turnstile — видим блок преди submit */
.auth-turnstile-wrap {
    min-height: 72px;
    margin: 16px 0 12px;
}
.auth-turnstile-mount {
    min-height: 65px;
}
.auth-turnstile-fallback {
    margin: 8px 0 0;
    font-size: 13px;
    line-height: 1.4;
    color: #b91c1c;
}

@media (min-width: 768px) and (max-width: 1199px) {
    .auth-left {
        width: 40%;
    }
    .auth-right {
        width: 60%;
        margin-left: 40%;
    }
    .auth-left-heading {
        font-size: 28px;
    }
    .auth-left-heading-sm {
        font-size: 22px;
    }
    .auth-left-role {
        font-size: 36px;
    }
    .auth-left-subtext {
        font-size: 17.28px;
    }
}
