/* ============================================================
   Investor auth pages only (join, portal login, portal forgot
   password). Black / coral-pink / white brand palette, matching
   portal.css. Kept as its own file, separate from auth.css, so the
   admin/staff sign-in and reset pages keep their own look and this
   file can change freely without touching the admin side.
   Mobile-first: base styles target small screens, larger
   screens are layered on with min-width media queries.
   ============================================================ */

:root {
    --color-primary: #ff788d;
    --color-primary-hover: #e85f76;
    --color-primary-soft: rgba(255, 120, 141, 0.14);
    --color-on-primary: #1a1414;
    --color-bg: #ffffff;
    --color-surface: #ffffff;
    --color-surface-alt: #f4f3f4;
    --color-text: #14110f;
    --color-muted: rgba(20, 17, 15, 0.62);
    --color-border: rgba(20, 17, 15, 0.12);
    --color-error: #e0303f;
    --color-error-bg: rgba(224, 48, 63, 0.1);
    --color-success: #1a9d5b;
    --color-success-bg: rgba(26, 157, 91, 0.12);
    --radius: 10px;
    --shadow: 0 1px 2px rgba(20, 17, 15, 0.06), 0 10px 26px rgba(20, 17, 15, 0.08);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body.auth-body {
    min-height: 100vh;
    /* A soft pink glow radiating from the top of the page instead of
       a flat fill, the same "premium glow" treatment used on the
       black/pink portal shell, so the very first screen an investor
       sees already carries the brand. */
    background:
        radial-gradient(circle at 50% -10%, rgba(255, 120, 141, 0.16), transparent 55%),
        var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
}

.auth-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    gap: 16px;
}

.auth-card {
    position: relative;
    width: 100%;
    max-width: 400px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 32px 24px 28px;
    overflow: hidden;
}

/* A thin pink gradient bar across the top of the card, the same
   signature touch used elsewhere in the portal, so the card reads
   as branded rather than a plain dark box. */
.auth-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #e85f76, #ff9fb0 50%, #e85f76);
}

.auth-brand {
    text-align: center;
    margin-bottom: 20px;
}

.auth-brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--color-primary-soft);
    color: var(--color-primary);
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 12px;
    /* A soft pink glow ring behind the badge, reading as a halo
       rather than a hard outline. */
    box-shadow: 0 0 0 6px rgba(255, 120, 141, 0.12), 0 8px 18px rgba(255, 120, 141, 0.28);
}

.auth-brand h1 {
    font-size: clamp(1.1rem, 4vw, 1.35rem);
    margin: 0 0 4px;
    color: var(--color-text);
}

.auth-brand-name {
    display: block;
    margin: 10px 0 2px;
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--color-primary);
}

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

.auth-alert {
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 0.88rem;
    margin-bottom: 14px;
    line-height: 1.4;
}

.auth-alert-error {
    background: var(--color-error-bg);
    color: var(--color-error);
    border: 1px solid rgba(255, 107, 107, 0.3);
}

.auth-alert-success {
    background: var(--color-success-bg);
    color: var(--color-success);
    border: 1px solid rgba(61, 220, 132, 0.3);
}

.auth-alert-info {
    background: var(--color-primary-soft);
    color: var(--color-primary);
    border: 1px solid rgba(255, 120, 141, 0.3);
}

.auth-form {
    display: flex;
    flex-direction: column;
}

.auth-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text);
    margin: 14px 0 6px;
}

.auth-label:first-of-type {
    margin-top: 0;
}

.auth-input {
    width: 100%;
    padding: 11px 12px;
    font-size: 1rem; /* >=16px prevents iOS auto-zoom on focus */
    border: 1px solid var(--color-border);
    border-radius: 8px;
    background: var(--color-surface-alt, #f4f3f4);
    color: var(--color-text);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(255, 120, 141, 0.22);
}

.cf-turnstile {
    margin-top: 20px;
    margin-bottom: 6px;
    display: flex;
    justify-content: center;
}

.auth-button {
    margin-top: 22px;
    width: 100%;
    padding: 12px 14px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-on-primary);
    background: var(--color-primary);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease;
    -webkit-tap-highlight-color: transparent;
}

.auth-button:hover,
.auth-button:focus-visible {
    background: var(--color-primary-hover);
    box-shadow: 0 10px 24px rgba(255, 120, 141, 0.4);
}

.auth-button:active {
    transform: translateY(1px);
}

.auth-button:disabled {
    opacity: 0.75;
    cursor: not-allowed;
    transform: none;
}

.auth-links {
    margin-top: 16px;
    text-align: center;
    font-size: 0.88rem;
}

.auth-links a,
.auth-footnote a {
    color: var(--color-primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-links a:hover,
.auth-footnote a:hover {
    text-decoration: underline;
}

.auth-footnote {
    text-align: center;
    font-size: 0.85rem;
    color: var(--color-muted);
    margin: 0;
}

/* Tablet and up */
@media (min-width: 640px) {
    .auth-card {
        padding: 36px 32px;
    }

    .auth-brand-mark {
        width: 52px;
        height: 52px;
        font-size: 17px;
    }
}
