/**
 * Modern auth — reference layout, pink theme
 */
body.rx-auth-modern {
    margin: 0;
    min-height: 100dvh;
    font-family: 'Manrope', system-ui, sans-serif;
    background: #eceef2;
    color: #3b0d2e;
    -webkit-tap-highlight-color: transparent;
}

.rx-auth-screen {
    min-height: 100dvh;
    max-width: 430px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.rx-auth-screen::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 42%;
    min-height: 280px;
    background: linear-gradient(135deg, #db2777 0%, #ec4899 42%, #f9a8d4 100%);
    z-index: 0;
}

.rx-auth-hero {
    position: relative;
    z-index: 1;
    padding: max(1.5rem, env(safe-area-inset-top)) 1.75rem 0;
    color: #fff;
}

.rx-auth-hero h1 {
    margin: 0 0 0.65rem;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.15rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.rx-auth-hero p {
    margin: 0;
    max-width: 16rem;
    font-size: 0.78rem;
    line-height: 1.55;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.88);
}

.rx-auth-card-wrap {
    position: relative;
    z-index: 2;
    flex: 1;
    padding: 1.35rem 1.25rem 2rem;
    margin-top: 0.5rem;
}

.rx-auth-card {
    position: relative;
    background: #ffffff;
    border-radius: 1.75rem;
    padding: 1.35rem 1.25rem 2.75rem;
    box-shadow: 0 18px 48px rgba(219, 39, 119, 0.14), 0 4px 14px rgba(20, 20, 40, 0.06);
}

.rx-auth-tabs {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.35rem;
    padding-bottom: 0.15rem;
}

.rx-auth-tabs a {
    position: relative;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 700;
    color: #b8bcc6;
    padding-bottom: 0.45rem;
    transition: color 0.2s ease;
}

.rx-auth-tabs a.is-active {
    color: #db2777;
}

.rx-auth-tabs a.is-active::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, #ec4899, #f472b6);
}

.rx-auth-field {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 0.85rem;
    padding: 0.8rem 1rem;
    border-radius: 999px;
    border: 1px solid #e8eaef;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.rx-auth-field:focus-within {
    border-color: rgba(236, 72, 153, 0.45);
    box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.1);
}

.rx-auth-field i {
    width: 1rem;
    text-align: center;
    color: #c4c9d4;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.rx-auth-field input {
    border: none;
    background: transparent;
    width: 100%;
    outline: none;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    color: #3b0d2e;
}

.rx-auth-field input::placeholder {
    color: #b8bcc6;
    font-weight: 500;
}

.rx-auth-field button.rx-auth-eye {
    border: none;
    background: none;
    padding: 0;
    cursor: pointer;
    color: #b8bcc6;
    flex-shrink: 0;
}

.rx-auth-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin: 0.15rem 0 0.25rem;
    font-size: 0.72rem;
}

.rx-auth-terms {
    display: flex;
    align-items: flex-start;
    gap: 0.55rem;
    margin-top: 0.35rem;
    padding: 0.55rem 0.65rem;
    border-radius: 0.85rem;
    background: #fff5f9;
    border: 1px solid rgba(236, 72, 153, 0.14);
    cursor: pointer;
    user-select: none;
}

.rx-auth-terms input {
    appearance: none;
    -webkit-appearance: none;
    width: 1.05rem;
    height: 1.05rem;
    margin: 0.1rem 0 0;
    flex-shrink: 0;
    border: 2px solid #f9a8d4;
    border-radius: 0.3rem;
    background: #fff;
    cursor: pointer;
    position: relative;
    transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.rx-auth-terms input:checked {
    background: linear-gradient(135deg, #ec4899, #f472b6);
    border-color: #ec4899;
    box-shadow: 0 4px 12px rgba(236, 72, 153, 0.28);
}

.rx-auth-terms input:checked::after {
    content: '';
    position: absolute;
    left: 0.2rem;
    top: 0.02rem;
    width: 0.28rem;
    height: 0.52rem;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.rx-auth-terms span {
    font-size: 0.74rem;
    line-height: 1.45;
    font-weight: 600;
    color: #8b90a0;
}

.rx-auth-terms a {
    color: #ec4899;
    font-weight: 800;
    text-decoration: none;
}

.rx-auth-check {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: #8b90a0;
    font-weight: 600;
    cursor: pointer;
}

.rx-auth-check input {
    width: 0.95rem;
    height: 0.95rem;
    accent-color: #ec4899;
    cursor: pointer;
}

.rx-auth-link {
    color: #ec4899;
    font-weight: 700;
    text-decoration: none;
}

.rx-auth-fab {
    position: absolute;
    left: 50%;
    bottom: -1.65rem;
    transform: translateX(-50%);
    width: 3.35rem;
    height: 3.35rem;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.05rem;
    background: linear-gradient(135deg, #ec4899 0%, #f472b6 55%, #fda4af 100%);
    box-shadow: 0 12px 28px rgba(236, 72, 153, 0.38);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.rx-auth-fab:active {
    transform: translateX(-50%) scale(0.96);
}

.rx-auth-msg {
    margin: 0 0 0.75rem;
    padding: 0.65rem 0.85rem;
    border-radius: 0.75rem;
    font-size: 0.78rem;
    font-weight: 700;
}

.rx-auth-msg.is-error {
    color: #b91c1c;
    background: #fef2f2;
    border: 1px solid #fecaca;
}

.rx-auth-msg.is-success {
    color: #15803d;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.rx-auth-msg.hidden {
    display: none;
}

.rx-auth-ref-note {
    margin: -0.35rem 0 0.75rem;
    font-size: 0.68rem;
    font-weight: 700;
    color: #9d6b85;
    text-align: center;
}
