@import url('./tokens.css');
/* ===== JOIN PAGE =====
   Token-driven, matching the landing's look: flat #1A1A1A page, #252525
   surface card, coral CTAs with dark ink (coral is too light to carry white
   text - see the landing button contrast decision), custom coral checkbox.
   Replaced the old "liquid glass" theme (teal/purple gradients, shimmer,
   glass blur) that clashed with the brand. */

body {
    background: var(--color-bg);
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.08) transparent;
    font-weight: 500; /* [TINFLE-REDESIGN] bolder base type */
}

body::-webkit-scrollbar { width: 4px; }
body::-webkit-scrollbar-track { background: transparent; }
body::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.08); border-radius: 4px; }

/* Single soft coral glow up top - brand warmth, no purple, no drift loops */
body::before {
    content: '';
    position: fixed;
    top: -30%;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    height: 55%;
    background: radial-gradient(ellipse, rgba(255, 107, 107, 0.07) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
}

/* ===== AUTH CONTAINER ===== */
.auth-container {
    max-width: 420px;
    margin: 48px auto;
    text-align: center;
    background: var(--color-surface);
    border-radius: 16px;
    border: 1px solid var(--color-border);
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.35);
    padding: 36px 28px;
    position: relative;
    animation: card-in 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes card-in {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 460px) {
    .auth-container { margin: 16px 12px; padding: 28px 20px; }
}

/* ===== HEADER / BRAND ===== */
.auth-header { margin-bottom: var(--spacing-lg); }

.auth-brand {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}
.auth-brand img { height: 64px; }
.auth-brand .brand-word {
    font-weight: 900;
    font-size: 1.4rem;
    letter-spacing: -0.01em;
    color: var(--color-text-primary);
}
.auth-brand .brand-pron {
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--color-text-secondary);
    margin-left: 4px;
}

/* ===== BETA WALL ===== */
.beta-wall { padding: 16px 0 8px; text-align: center; }
.beta-wall .wall-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--color-text-primary);
    margin-bottom: 12px;
}
.beta-wall .wall-sub {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: 24px;
}
.beta-wall .btn-primary {
    display: inline-block;
    width: auto;
    text-decoration: none;
    padding: 14px 28px;
}
.beta-wall .wall-invite { margin-top: 18px; }
.beta-wall .wall-invite a {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.beta-wall .wall-invite a:hover { color: var(--color-accent); }

/* ===== FORM FIELDS ===== */
.form-group {
    margin-bottom: var(--spacing-md);
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    color: var(--color-text-secondary);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.form-group input {
    width: 100%;
    padding: 13px 16px;
    border-radius: 10px;
    border: 1px solid var(--color-border);
    background: var(--color-bg);
    color: var(--color-text-primary);
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    color-scheme: dark; /* native date picker chrome follows the theme */
}

.form-group input:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.15);
}

.form-group input::placeholder { color: var(--color-text-muted, #666); }

/* Hint label below inputs */
.form-hint {
    display: block;
    margin-top: 8px;
    font-size: 0.74rem;
    line-height: 1.5;
    color: var(--color-text-secondary);
}
.form-hint strong { color: var(--color-accent); }
.form-hint a {
    color: var(--color-accent);
    text-decoration: none;
    font-weight: 600;
}
.form-hint a:hover { text-decoration: underline; }

/* ===== EMAIL DOMAIN QUICK-COMPLETE PILLS =====
   One-tap domain completion under the email field. Wraps so every domain
   is visible at once (no pills hidden behind a scroll); filtering collapses
   it back toward one row as the user types. [hidden] must beat display:flex
   or the attribute does nothing. */
.email-domains {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}
.email-domains[hidden] { display: none; }

.email-domain-pill {
    flex-shrink: 0;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid var(--color-border);
    background: var(--color-bg);
    color: var(--color-text-secondary);
    font-size: 0.8rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
.email-domain-pill[hidden] { display: none; }
.email-domain-pill:hover {
    border-color: var(--color-accent);
    color: var(--color-text-primary);
}
.email-domain-pill:active {
    background: rgba(255, 107, 107, 0.12);
    border-color: var(--color-accent);
    color: var(--color-text-primary);
}

/* ===== AGE / TERMS CHECKBOX (custom, coral) =====
   The native checkbox inherited the 100%-width input rule and rendered as a
   stretched bar. appearance:none + fixed box, coral fill with a drawn check
   when ticked, coral focus ring. The row's label is sentence-case body text,
   not the uppercase field-label style. */
.check-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
.check-row input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    margin-top: 1px;
    padding: 0;
    border: 1.5px solid #555;
    border-radius: 6px;
    background: var(--color-bg);
    cursor: pointer;
    position: relative;
    transition: border-color 0.15s ease, background 0.15s ease;
}
.check-row input[type="checkbox"]:hover { border-color: var(--color-accent); }
.check-row input[type="checkbox"]:focus-visible {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.2);
}
.check-row input[type="checkbox"]:checked {
    background: var(--color-accent);
    border-color: var(--color-accent);
}
.check-row input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2.5px;
    width: 5px;
    height: 10px;
    border: solid var(--color-bg);
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
}
.check-row label {
    margin: 0;
    font-size: 0.82rem;
    font-weight: 500;
    line-height: 1.5;
    color: var(--color-text-secondary);
    text-transform: none;
    letter-spacing: normal;
    cursor: pointer;
}
.check-row label a {
    color: var(--color-accent);
    font-weight: 600;
    text-decoration: none;
}
.check-row label a:hover { text-decoration: underline; }

/* ===== ERROR MESSAGE ===== */
.error-message {
    color: var(--color-accent);
    font-size: 0.82rem;
    font-weight: 600;
    margin-top: var(--spacing-sm);
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(255, 107, 107, 0.08);
    border: 1px solid rgba(255, 107, 107, 0.25);
    display: none;
    text-align: left;
}

/* ===== PRIMARY BUTTON (coral, dark ink - matches the landing) ===== */
.auth-container .btn-primary {
    width: 100%;
    padding: 14px;
    font-size: 1rem;
    font-weight: 800;
    border-radius: 10px;
    border: none;
    background: var(--color-accent);
    color: var(--color-bg);
    cursor: pointer;
    transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
    box-shadow: 0 0 18px rgba(255, 107, 107, 0.35);
    margin-top: var(--spacing-sm);
    letter-spacing: 0.01em;
}
.auth-container .btn-primary:hover:not(:disabled) {
    background: var(--color-text-primary);
    color: var(--color-bg);
    transform: translateY(-1px);
}
.auth-container .btn-primary:active:not(:disabled) { transform: scale(0.98); }
.auth-container .btn-primary:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
}

/* ===== AUTH FOOTER ===== */
.auth-footer {
    margin-top: var(--spacing-lg);
    font-size: 0.85rem;
    color: var(--color-text-secondary);
}
.auth-footer a {
    color: var(--color-accent);
    font-weight: 700;
    text-decoration: none;
    padding: 2px 8px;
    border-radius: 6px;
    transition: background 0.2s ease;
}
.auth-footer a:hover { background: rgba(255, 107, 107, 0.1); }
