/* Nazarie web — sign in / sign up (email + password) */
:root {
    --primary-black: #000000;
    --accent-blue: #007aff;
    --accent-green: #00c896;
    --text-primary: #ffffff;
    --text-secondary: #999999;
    --text-muted: #666666;
    --gradient-accent: linear-gradient(135deg, #007aff 0%, #00c896 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #000000;
    color: #ffffff;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    position: relative;
    overflow-x: hidden;
    font-weight: 400;
}

input[type="email"],
input[type="password"],
input[type="tel"],
input[type="text"] {
    color: #ffffff !important;
}

.auth-container.ff-auth-shell {
    position: relative;
    width: 100%;
    max-width: 420px;
    z-index: 1;
    background: transparent;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.ff-auth-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    border-radius: 18px;
    background: radial-gradient(ellipse 90% 45% at 50% 0%, rgba(0, 122, 255, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse 90% 45% at 50% 100%, rgba(0, 200, 150, 0.1) 0%, transparent 50%);
}

.ff-auth-card {
    position: relative;
    z-index: 1;
    margin: 0;
    padding: 1.5rem 1.35rem 1.5rem;
    background: linear-gradient(165deg, #1e1e1e 0%, #121212 45%, #0c0c0c 100%);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 14px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.auth-brand {
    text-align: center;
    margin-bottom: 1rem;
}

.auth-brand-name {
    display: inline-block;
    font-size: 1.35rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.02em;
    text-decoration: none;
    transition: color 0.2s ease;
}

.auth-brand-name:hover {
    color: #7dffc7;
}

.auth-brand-tagline {
    margin: 0.4rem 0 0;
    font-size: 0.8rem;
    font-weight: 500;
    color: #9a9a9a;
    letter-spacing: 0.02em;
}

.ff-auth-title {
    font-size: 1.35rem;
    font-weight: 600;
    text-align: center;
    color: #ffffff;
    letter-spacing: -0.02em;
    margin: 0 0 1rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

/* Alerts */
.error-message {
    background: rgba(255, 107, 107, 0.12);
    border: 1px solid rgba(255, 107, 107, 0.35);
    color: #ff8f8f;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    font-size: 0.875rem;
    margin-bottom: 0.85rem;
    display: none;
    align-items: center;
    gap: 0.5rem;
}

.error-message.active {
    display: flex;
}

.error-message::before {
    content: "⚠️";
    font-size: 1rem;
    flex-shrink: 0;
}

.success-message {
    background: rgba(0, 200, 150, 0.1);
    border: 1px solid rgba(0, 200, 150, 0.35);
    color: #7dffc7;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    font-size: 0.875rem;
    margin-bottom: 0.85rem;
    display: none;
    align-items: center;
    gap: 0.5rem;
}

.success-message.active {
    display: flex;
}

.success-message::before {
    content: "✅";
    font-size: 1rem;
    flex-shrink: 0;
}

/* Form layout */
.auth-form.ff-auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.05rem;
    padding: 0;
    margin: 0;
    background: transparent;
    border: none;
    box-shadow: none;
}

#signUpFields,
#emailSignInForm {
    display: none;
    flex-direction: column;
    gap: 1.05rem;
}

#signUpFields .auth-submit,
#emailSignInForm .auth-submit {
    margin-top: 0.35rem;
}

.auth-form-meta {
    text-align: right;
    margin-top: 0.15rem;
    margin-bottom: 0;
}

/* Inputs */
.ff-auth-card .auth-input {
    width: 100%;
    max-width: none;
    padding: 0.8rem 1rem;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 12px;
    color: #ffffff;
    font-size: 0.95rem;
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    min-height: 46px;
  box-sizing: border-box;
}

.ff-auth-card .auth-input:focus {
    outline: none;
    border-color: #4da3ff;
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.28);
    transform: none;
}

.ff-auth-card .auth-input::placeholder {
    color: #8a8a8a;
    opacity: 1;
}

.ff-auth-card .auth-input.pw-match {
    border-color: #00c896 !important;
    box-shadow: 0 0 0 3px rgba(0, 200, 150, 0.22) !important;
}

.ff-auth-card .auth-input.pw-mismatch {
    border-color: #ff6b6b !important;
    box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.18) !important;
}

.password-field-wrap {
    position: relative;
    width: 100%;
}

.ff-auth-card .password-field-wrap .auth-input {
    padding-right: 2.75rem;
}

.ff-auth-card .password-toggle-btn {
    position: absolute;
    right: 0.45rem;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    padding: 0.35rem;
    cursor: pointer;
    color: rgba(255, 255, 255, 0.45);
    border-radius: 8px;
    line-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease, background 0.2s ease;
}

.ff-auth-card .password-toggle-btn:hover {
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.08);
}

.ff-auth-card .password-toggle-btn:focus-visible {
    outline: 2px solid #4da3ff;
    outline-offset: 2px;
}

.ff-auth-card .password-toggle-btn svg {
    width: 1.15rem;
    height: 1.15rem;
    flex-shrink: 0;
}

.ff-auth-card .password-toggle-btn:not(.is-revealed) .password-toggle-eye-off {
    display: none;
}

.ff-auth-card .password-toggle-btn.is-revealed .password-toggle-eye-open {
    display: none;
}

/* Primary CTA */
.ff-auth-card .auth-submit {
    width: 100%;
    margin-top: 0.35rem;
    padding: 0.85rem 1.25rem;
    background: #e8e8e8 !important;
    color: #111111 !important;
    border: 1px solid rgba(255, 255, 255, 0.35) !important;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.15s ease, box-shadow 0.15s ease;
    min-height: 48px;
    transform: none !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35) !important;
}

.ff-auth-card .auth-submit:hover {
    background: #f5f5f5 !important;
    transform: none !important;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.45) !important;
}

.ff-auth-card .auth-submit:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.btn-link-auth {
    background: transparent;
    border: none;
    color: #6eb8ff;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    padding: 0.35rem 0.45rem;
    border-radius: 6px;
    transition: color 0.15s ease, background 0.15s ease;
}

.ff-auth-footer .btn-link-auth {
    padding: 0.35rem 0.5rem;
}

.btn-link-auth:hover {
    color: #7dffc7;
    background: rgba(0, 200, 150, 0.12);
    text-decoration: underline;
}

/* Footer / switch */
.auth-switch.ff-auth-footer {
    margin-top: 1.15rem;
    padding-top: 0.5rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem 0.75rem;
    color: #a8a8a8;
    font-size: 0.875rem;
    margin-bottom: 0;
    border: none;
    background: transparent;
}

#authSwitchText {
    color: #a8a8a8;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.875rem;
}

.name-fields {
    display: none;
}

.name-fields.active {
    display: grid;
}

.otp-section {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

#recaptcha-container {
    margin: 1rem 0;
}

@media (max-width: 480px) {
    .ff-auth-card {
        padding: 1.25rem 1.1rem 1.35rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}
