@import url('https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap');

:root {
    --auth-bg: #fcfcfd;
    --card-bg: #ffffff;
    --input-bg: #ffffff;
    --text-main: #101828;
    --text-muted: #667085;
    --accent: #000000;
    --accent-soft: rgba(0, 0, 0, 0.05);
    --accent-glow: rgba(0, 0, 0, 0.05);
    --border-color: #eaecf0;
    --border-radius: 12px;
    --input-height: 48px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.08);
}

[data-theme="dark"] {
    --auth-bg: #0a0a0a;
    --card-bg: #111111;
    --input-bg: #1a1a1a;
    --text-main: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.6);
    --accent: #ffffff;
    --accent-soft: rgba(255, 255, 255, 0.08);
    --accent-glow: rgba(255, 255, 255, 0.1);
    --border-color: #222222;
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.4);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.auth-page {
    min-height: 100vh;
    font-family: 'Rubik', sans-serif;
    color: var(--text-main);
    background: var(--auth-bg);
}

.auth-main {
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.auth-container {
    width: 100%;
    min-height: 100vh;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* ─── Decorative Background Shapes ─── */
.auth-container::before,
.auth-container::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    z-index: 0;
    pointer-events: none;
}

.auth-container::before {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.03) 0%, transparent 70%);
    top: -200px;
    right: -200px;
}

[data-theme="dark"] .auth-container::before {
    background: radial-gradient(circle, rgba(255, 255, 255, 0.03) 0%, transparent 70%);
}

.auth-container::after {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.02) 0%, transparent 70%);
    bottom: -150px;
    left: -150px;
}

[data-theme="dark"] .auth-container::after {
    background: radial-gradient(circle, rgba(255, 255, 255, 0.02) 0%, transparent 70%);
}

.auth-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

/* --- Form Side --- */
.auth-form-side {
    padding: 40px 72px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    position: relative;
    background: var(--card-bg);
}

.auth-form-side::-webkit-scrollbar {
    width: 4px;
}

.auth-form-side::-webkit-scrollbar-track {
    background: transparent;
}

.auth-form-side::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

.auth-brand-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 48px;
}

.auth-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    font-size: 20px;
    color: var(--text-main);
    text-decoration: none;
    transition: var(--transition);
}

.auth-logo:hover {
    opacity: 0.8;
}

.auth-logo img {
    height: 38px;
    width: auto;
    filter: brightness(0);
    transition: filter 0.3s ease;
}

[data-theme="dark"] .auth-logo img {
    filter: brightness(0) invert(1);
}

.auth-back-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 100px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.auth-back-link:hover {
    color: var(--text-main);
    background: var(--auth-bg);
    border-color: var(--text-main);
}

.auth-form-content {
    max-width: 480px;
    width: 100%;
    margin: auto;
    padding: 8px 0;
    position: relative;
    transition: min-height 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

.auth-header {
    margin-bottom: 36px;
    text-align: center;
}

.auth-header--compact {
    margin-bottom: 32px;
}

.auth-header--compact .auth-title {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: var(--text-main);
}

.auth-header .auth-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 24px;
    color: #fff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

[data-theme="dark"] .auth-header .auth-icon {
    color: #000;
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.1);
}

.auth-title {
    font-size: 30px;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
    color: var(--text-main);
    line-height: 1.2;
}

.auth-subtitle {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* --- Auth Methods (Premium) --- */
.auth-methods {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
    transition:
        opacity 0.45s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
        filter 0.4s ease;
    will-change: opacity, transform, filter;
}

.auth-form-content.auth-show-form .auth-methods {
    opacity: 0;
    transform: translateY(-20px) scale(0.97);
    filter: blur(6px);
    pointer-events: none;
    position: absolute;
    inset-inline: 0;
    visibility: hidden;
    transition:
        opacity 0.35s cubic-bezier(0.4, 0, 1, 1),
        transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        filter 0.3s ease,
        visibility 0s linear 0.4s;
}

.auth-methods-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 0;
}

.auth-method-btn {
    width: 100%;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    background: var(--card-bg);
    border: 1.5px solid var(--border-color);
    border-radius: 14px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.auth-method-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.02) 0%, rgba(0, 0, 0, 0.04) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.auth-method-btn:hover:not(:disabled):not(.auth-method-btn--soon) {
    background: var(--card-bg);
    border-color: var(--border-color);
    transform: none;
    box-shadow: none;
}

.auth-method-btn:hover:not(:disabled):not(.auth-method-btn--soon)::before {
    opacity: 0;
}

.auth-method-btn:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.auth-method-btn img {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.auth-method-btn i {
    font-size: 20px;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.auth-method-btn span {
    position: relative;
    z-index: 1;
}

.auth-method-btn--soon {
    opacity: 0.6;
    cursor: not-allowed;
}

[data-theme="dark"] .auth-method-btn {
    background: var(--card-bg);
    border-color: var(--border-color);
}

[data-theme="dark"] .auth-method-btn:hover:not(:disabled):not(.auth-method-btn--soon) {
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.04);
}

[data-theme="dark"] .auth-method-btn::before {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.02) 0%, rgba(255, 255, 255, 0.04) 100%);
}

.auth-soon-badge {
    position: absolute;
    inset-inline-end: 14px;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 100px;
    background: var(--accent-soft);
    color: var(--text-muted);
    letter-spacing: 0.2px;
}

html[dir="ltr"] .auth-soon-badge {
    inset-inline-end: 14px;
}

.auth-email-panel {
    display: grid;
    grid-template-rows: 0fr;
    opacity: 0;
    transform: translateY(28px) scale(0.98);
    filter: blur(8px);
    transition:
        grid-template-rows 0.75s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.55s cubic-bezier(0.4, 0, 0.2, 1) 0.12s,
        transform 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.08s,
        filter 0.5s ease 0.1s;
    overflow: hidden;
    will-change: grid-template-rows, opacity, transform, filter;
}

.auth-form-content.auth-show-form .auth-email-panel {
    grid-template-rows: 1fr;
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
}

.auth-form-content.is-closing .auth-email-panel {
    transition:
        grid-template-rows 0.45s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.3s ease,
        transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
        filter 0.25s ease;
}

.auth-form-content.is-closing .auth-methods {
    visibility: visible;
    transition:
        opacity 0.45s cubic-bezier(0.22, 1, 0.36, 1) 0.15s,
        transform 0.55s cubic-bezier(0.22, 1, 0.36, 1) 0.12s,
        filter 0.4s ease 0.1s,
        visibility 0s linear 0s;
}

.auth-email-panel-inner {
    min-height: 0;
    overflow: hidden;
}

.auth-back-to-methods {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 0 0 24px;
    margin-bottom: 4px;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.auth-back-to-methods:hover {
    color: var(--text-main);
    gap: 12px;
}

html[dir="rtl"] .auth-back-to-methods i {
    transform: rotate(180deg);
}

.auth-form-content.auth-show-form .auth-email-panel-inner > *,
.auth-form-content.auth-show-form .auth-step,
.auth-form-content.auth-show-form .auth-step-actions {
    animation: authRevealItem 0.65s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.auth-form-content.auth-show-form .auth-back-to-methods { animation-delay: 0.14s; }
.auth-form-content.auth-show-form .auth-tabs { animation-delay: 0.2s; }
.auth-form-content.auth-show-form .auth-tab-content.active .auth-form-group:nth-child(1),
.auth-form-content.auth-show-form .auth-form-row:nth-of-type(1) { animation-delay: 0.26s; }
.auth-form-content.auth-show-form .auth-tab-content.active .auth-form-group:nth-child(2),
.auth-form-content.auth-show-form .auth-form-row:nth-of-type(2) { animation-delay: 0.32s; }
.auth-form-content.auth-show-form .auth-tab-content.active .auth-form-group:nth-child(3) { animation-delay: 0.38s; }
.auth-form-content.auth-show-form .auth-tab-content.active .auth-form-group:nth-child(4) { animation-delay: 0.44s; }
.auth-form-content.auth-show-form .auth-link-row { animation-delay: 0.5s; }
.auth-form-content.auth-show-form .auth-terms-row { animation-delay: 0.5s; }
.auth-form-content.auth-show-form .auth-btn-primary { animation-delay: 0.56s; }
.auth-form-content.auth-show-form .auth-step-actions { animation-delay: 0.56s; }

@keyframes authRevealItem {
    from {
        opacity: 0;
        transform: translateY(22px);
        filter: blur(4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

.auth-legal-note {
    margin-top: 24px;
    text-align: center;
    font-size: 12px;
    line-height: 1.6;
    color: var(--text-muted);
}

.auth-legal-note a {
    color: var(--text-main);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.auth-methods .auth-divider {
    margin: 20px 0;
    text-transform: none;
    letter-spacing: 0;
    font-weight: 500;
    font-size: 13px;
}

.auth-form-content.auth-show-form .auth-step,
.auth-form-content.auth-show-form .auth-step-actions {
    animation: authRevealItem 0.65s cubic-bezier(0.22, 1, 0.36, 1) both;
}

#show-email-form-btn {
    position: relative;
    overflow: hidden;
}

#show-email-form-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.35) 0%, transparent 70%);
    opacity: 0;
    transform: scale(0.5);
    transition: opacity 0.4s ease, transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
}

#show-email-form-btn.is-pressed::after {
    opacity: 1;
    transform: scale(1.4);
}

/* --- Social Buttons (legacy) --- */
.auth-social-group {
    display: flex;
    gap: 10px;
    margin-bottom: 28px;
}

.auth-social-btn {
    flex: 1;
    height: 52px;
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
    font-size: 14px;
    color: var(--text-main);
    cursor: pointer;
    font-family: inherit;
    transition: var(--transition);
    white-space: nowrap;
    padding: 0 20px;
    position: relative;
    overflow: hidden;
}

.auth-social-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--accent-soft);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.auth-social-btn:hover {
    transform: translateY(-2px);
    border-color: var(--accent);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.auth-social-btn:hover::before {
    opacity: 1;
}

.auth-social-btn:active {
    transform: translateY(0);
}

.auth-social-btn img {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.auth-social-btn i {
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

/* --- Divider (Premium) --- */
.auth-divider {
    display: flex;
    align-items: center;
    margin: 24px 0;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0.5px;
}

.auth-divider::before,
.auth-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
}

.auth-divider span {
    padding: 0 20px;
    position: relative;
}

/* --- Forms --- */
.auth-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-bottom: 18px;
}

.auth-form-group {
    margin-bottom: 28px;
    position: relative;
}

.auth-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 8px;
    letter-spacing: 0.2px;
    transition: color 0.25s ease;
}

.auth-form-group.is-focused .auth-label {
    color: var(--text-main);
}

.auth-input-wrapper {
    position: relative;
}

.auth-input {
    width: 100%;
    height: 54px;
    background: var(--input-bg);
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    padding: 0 18px;
    font-size: 15px;
    color: var(--text-main);
    font-family: inherit;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    outline: none;
}

.auth-input:hover {
    border-color: rgba(0, 0, 0, 0.2);
}

.auth-input:focus {
    border-color: var(--text-main);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

[data-theme="dark"] .auth-input:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] .auth-input:focus {
    border-color: var(--text-main);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.auth-input::placeholder {
    color: #98a2b3;
}

/* Phone input with country code */
.auth-phone-wrapper {
    display: flex;
    gap: 10px;
}

.auth-phone-input {
    flex: 1;
    min-width: 0;
}

#phone-code-select + .auth-phone-input,
.auth-phone-wrapper .auth-phone-input {
    height: 56px;
}

/* Custom Select */
.auth-custom-select {
    position: relative;
    z-index: 10;
}

.auth-custom-select-full {
    width: 100%;
}

#phone-code-select {
    width: 180px;
    min-width: 180px;
    flex-shrink: 0;
}

#phone-code-select .auth-custom-select-trigger {
    height: 56px;
    padding: 0 16px;
    gap: 10px;
    background: var(--input-bg);
}

#phone-code-select .auth-custom-select-trigger .flag {
    width: 32px;
    height: 24px;
}

#phone-code-select .auth-custom-select-trigger .code {
    font-size: 16px;
    font-weight: 700;
}

#phone-code-select .auth-custom-select-trigger .fa-chevron-down {
    font-size: 14px;
}

#phone-code-select .auth-custom-select-options .option {
    padding: 12px 14px;
    font-size: 14px;
    gap: 10px;
}

#phone-code-select .auth-custom-select-options .option .flag {
    width: 28px;
    height: 21px;
}

#phone-code-select .auth-custom-select-options .option .code {
    font-size: 14px;
}

.auth-custom-select-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    height: var(--input-height);
    padding: 0 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--input-bg);
    cursor: pointer;
    transition: var(--transition);
    user-select: none;
}

.auth-custom-select-trigger:hover {
    border-color: var(--text-muted);
}

.auth-custom-select.open .auth-custom-select-trigger {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
}

.auth-custom-select-trigger .flag {
    width: 28px;
    height: 21px;
    border-radius: 2px;
    object-fit: cover;
    flex-shrink: 0;
    display: block;
}

.auth-custom-select-trigger .code {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-main);
    margin-inline-end: auto;
}

.auth-custom-select-trigger .label {
    flex: 1;
    font-size: 14px;
    color: var(--text-muted);
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.auth-custom-select.selected .auth-custom-select-trigger .label,
.auth-custom-select-trigger .selected-text {
    color: var(--text-main);
    font-weight: 600;
    font-size: 14px;
}

.auth-custom-select-trigger .fa-chevron-down {
    font-size: 12px;
    color: var(--text-muted);
    transition: transform 0.25s ease;
    flex-shrink: 0;
}

.auth-custom-select.open .auth-custom-select-trigger .fa-chevron-down {
    transform: rotate(180deg);
}

.auth-custom-select-options {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    max-height: 280px;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: all 0.2s ease;
}

[data-theme="dark"] .auth-custom-select-options {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    border-color: #222;
}

.auth-custom-select.open .auth-custom-select-options {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.auth-custom-select-options .option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.15s ease;
    font-size: 14px;
}

.auth-custom-select-options .option:hover {
    background: var(--accent-soft);
}

[data-theme="dark"] .auth-custom-select-options .option:hover {
    background: rgba(255, 255, 255, 0.06);
}

.auth-custom-select-options .option.selected {
    background: var(--accent-soft);
    font-weight: 600;
    position: relative;
}

[data-theme="dark"] .auth-custom-select-options .option.selected {
    background: rgba(255, 255, 255, 0.12);
}

.auth-custom-select-options .option.selected::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 12px;
    color: var(--accent);
    position: absolute;
    inset-inline-end: 14px;
    top: 50%;
    transform: translateY(-50%);
}

.auth-custom-select-options .option .flag {
    width: 24px;
    height: 18px;
    border-radius: 2px;
    object-fit: cover;
    flex-shrink: 0;
    display: block;
}

.auth-custom-select-options .option i {
    width: 22px;
    text-align: center;
    font-size: 16px;
    color: var(--text-muted);
    flex-shrink: 0;
}

.auth-custom-select-options .option .label {
    flex: 1;
    color: var(--text-main);
}

.auth-custom-select-options .option .code {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 13px;
}

.auth-custom-select-options::-webkit-scrollbar {
    width: 4px;
}

.auth-custom-select-options::-webkit-scrollbar-track {
    background: transparent;
}

.auth-custom-select-options::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

html[dir="rtl"] .auth-custom-select-trigger .fa-chevron-down {
    margin-inline-start: auto;
    margin-inline-end: 0;
}

/* Step actions */
.auth-step-actions {
    display: flex;
    gap: 12px;
    margin-top: 32px;
}

.auth-step-actions .auth-btn-primary {
    flex: 1;
}

.auth-password-toggle {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    border-radius: 8px;
}

html[dir="rtl"] .auth-password-toggle {
    left: 6px;
}
html[dir="ltr"] .auth-password-toggle {
    right: 6px;
}

.auth-password-toggle:hover {
    color: var(--text-main);
    background: var(--accent-soft);
}

.auth-link-row {
    margin-bottom: 20px;
    display: flex;
    justify-content: flex-end;
}

.auth-text-link {
    color: var(--text-main);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.auth-terms-row {
    margin-top: 10px;
    margin-bottom: 28px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}

.auth-terms-row input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--accent);
    border-radius: 4px;
}

.auth-terms-row label {
    cursor: pointer;
    color: var(--text-muted);
}

.auth-btn-primary {
    width: 100%;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    position: relative;
    overflow: hidden;
}

.auth-btn-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

[data-theme="dark"] .auth-btn-primary {
    color: #000;
}

.auth-btn-primary:hover {
    transform: none;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.auth-btn-primary:hover::before {
    opacity: 0;
}

.auth-btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.auth-btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none;
}

.auth-footer {
    margin-top: 32px;
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--text-main);
    font-weight: 700;
    text-decoration: none;
    margin-inline-start: 6px;
    transition: none;
}

/* --- Sidebar Side --- */
.auth-sidebar {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
    margin: 0;
    height: 100vh;
    border-radius: 0;
}

.auth-sidebar-media {
    position: absolute;
    inset: 0;
    z-index: 1;
    overflow: hidden;
}

.auth-sidebar-image {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    transform: translate(-50%, -50%) scale(1.15);
    animation: imageZoomIn 1.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes imageZoomIn {
    0% {
        transform: translate(-50%, -50%) scale(1.25);
        filter: brightness(0.7) saturate(0.6);
    }
    60% {
        filter: brightness(0.9) saturate(0.9);
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
        filter: brightness(1) saturate(1);
    }
}

.auth-sidebar-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to top, rgba(8, 12, 24, 0.5) 0%, rgba(8, 12, 24, 0.1) 40%, rgba(8, 12, 24, 0.15) 100%);
    z-index: 2;
}

.auth-sidebar-card {
    position: absolute;
    bottom: 32px;
    left: 32px;
    right: 32px;
    z-index: 3;
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(24px) saturate(1.4);
    -webkit-backdrop-filter: blur(24px) saturate(1.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px 28px 18px;
    overflow: hidden;
}

.auth-slider {
    position: relative;
    height: 60px;
    overflow: hidden;
}

.auth-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    opacity: 0;
    pointer-events: none;
    text-align: center;
}

.auth-slide.active {
    opacity: 1;
    pointer-events: auto;
}

.auth-slide.active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.auth-slide.exit-left {
    opacity: 0;
    transform: translateX(-80px);
}

.auth-slide.enter-right {
    transform: translateX(80px);
}

.auth-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
    text-align: center;
}

.auth-slide.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.auth-slide i {
    font-size: 1.3rem;
    color: #fff;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

.auth-slide p {
    font-size: 1.05rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.92);
    margin: 0;
    line-height: 1.6;
    letter-spacing: -0.01em;
}

.auth-slider-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 14px;
}

.auth-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    transition: background 0.5s ease, transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), width 0.4s ease;
    cursor: pointer;
}

.auth-dot:hover {
    background: rgba(255, 255, 255, 0.4);
}

.auth-dot.active {
    background: #fff;
    transform: scale(1);
    width: 22px;
    border-radius: 10px;
}

.auth-sidebar-content {
    position: relative;
    z-index: 3;
    color: #fff;
    max-width: 420px;
    animation: fadeInUp 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

.auth-sidebar-content--hero {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 22px;
    max-width: 480px;
}

.auth-sidebar-tagline {
    font-size: clamp(30px, 3.8vw, 44px);
    font-weight: 600;
    line-height: 1.25;
    letter-spacing: -0.03em;
    color: rgba(255, 255, 255, 0.96);
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.35);
    animation: fadeInUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.15s both;
}

.auth-sidebar-brand-pill {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: #ffffff;
    color: #0a1328;
    padding: 12px 22px 12px 16px;
    border-radius: 12px;
    font-weight: 800;
    font-size: 19px;
    letter-spacing: -0.02em;
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.28),
        0 0 0 1px rgba(255, 255, 255, 0.15);
    animation: authPillPop 0.75s cubic-bezier(0.22, 1, 0.36, 1) 0.35s both;
}

.auth-sidebar-brand-pill img {
    height: 30px;
    width: auto;
    filter: none;
}

@keyframes authPillPop {
    from {
        opacity: 0;
        transform: translateY(16px) scale(0.92);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* legacy sidebar elements */
.auth-sidebar-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 8px 18px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 24px;
    letter-spacing: 0.3px;
    animation: fadeInUp 0.6s ease 0.2s both;
}

.auth-sidebar-badge .badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
    animation: pulse 2s ease-in-out infinite;
}

.auth-sidebar-content h2 {
    font-size: 42px;
    font-weight: 900;
    margin-bottom: 18px;
    line-height: 1.15;
    letter-spacing: -1px;
    background: linear-gradient(180deg, #ffffff 0%, rgba(255, 255, 255, 0.75) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: fadeInUp 0.6s ease 0.35s both;
}

.auth-sidebar-content p {
    font-size: 17px;
    opacity: 0.85;
    line-height: 1.75;
    margin-bottom: 12px;
    animation: fadeInUp 0.6s ease 0.5s both;
}

.sidebar-features {
    margin-top: 36px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.sidebar-feature {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 15px;
    font-weight: 500;
    opacity: 0;
    animation: fadeInUp 0.5s ease forwards;
}

.sidebar-feature:nth-child(1) { animation-delay: 0.7s; }
.sidebar-feature:nth-child(2) { animation-delay: 0.85s; }
.sidebar-feature:nth-child(3) { animation-delay: 1s; }
.sidebar-feature:nth-child(4) { animation-delay: 1.15s; }

.sidebar-feature .icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    flex-shrink: 0;
}

/* --- Policy Footer --- */
.auth-policy-footer {
    margin-top: auto;
    padding-top: 32px;
    text-align: center;
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    justify-content: center;
    gap: 20px;
}

.auth-policy-footer a {
    color: var(--text-muted);
    text-decoration: none;
    transition: var(--transition);
}

.auth-policy-footer a:hover {
    color: var(--accent);
}

/* --- Responsive --- */
@media (max-width: 1100px) {
    .auth-card {
        grid-template-columns: 1fr;
    }
    .auth-sidebar {
        display: none;
    }
    .auth-form-side {
        padding: 32px 24px;
    }
    .auth-form-content {
        max-width: 100%;
    }
}

@media (max-width: 600px) {
    .auth-form-row {
        grid-template-columns: 1fr;
    }
    .auth-brand-nav {
        margin-bottom: 32px;
    }
    .auth-title {
        font-size: 24px;
    }
    .auth-form-side {
        padding: 28px 22px;
    }
    .auth-sidebar-tagline {
        font-size: 26px;
    }
    .auth-sidebar-brand-pill {
        font-size: 16px;
        padding: 10px 18px 10px 14px;
    }
}

/* --- RTL Fixes --- */
html[dir="rtl"] .auth-logo {
    flex-direction: row-reverse;
}

html[dir="rtl"] .auth-back-link i {
    transform: rotate(180deg);
}

/* --- Auth Messages --- */
.auth-message {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
    animation: fadeIn 0.3s ease;
    border-width: 1px;
    border-style: solid;
    transition: var(--transition);
}

.auth-message.error {
    background: #fef2f2;
    color: #b91c1c;
    border-color: #fecaca;
}

[data-theme="dark"] .auth-message.error {
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.2);
}

.auth-message.success {
    background: #f0fdf4;
    color: #15803d;
    border-color: #bbf7d0;
}

[data-theme="dark"] .auth-message.success {
    background: rgba(16, 185, 129, 0.1);
    color: #34d399;
    border-color: rgba(16, 185, 129, 0.2);
}

.auth-message.info {
    background: #f0f9ff;
    color: #0369a1;
    border-color: #bae6fd;
}

[data-theme="dark"] .auth-message.info {
    background: rgba(255, 255, 255, 0.06);
    color: #f1f5f9;
    border-color: rgba(255, 255, 255, 0.15);
}

/* Step navigation */
.auth-step {
    animation: fadeIn 0.35s ease-out;
}

.auth-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 52px;
    padding: 0 28px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--card-bg);
    color: var(--text-main);
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.auth-btn-secondary:hover {
    background: var(--accent-glow);
    border-color: var(--text-muted);
    transform: translateY(-1px);
}

.auth-btn-secondary i {
    font-size: 16px;
    color: var(--text-muted);
}

html[dir="rtl"] .auth-btn-secondary i {
    transform: rotate(180deg);
}

/* ─── Auth Tabs ─── */
.auth-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 32px;
    background: rgba(0, 0, 0, 0.03);
    padding: 4px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

[data-theme="dark"] .auth-tabs {
    background: rgba(255, 255, 255, 0.04);
}

.auth-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 42px;
    padding: 0 16px;
    border: none;
    border-radius: 9px;
    background: transparent;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
}

.auth-tab.active {
    background: var(--card-bg);
    color: var(--text-main);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

[data-theme="dark"] .auth-tab.active {
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.auth-tab i {
    font-size: 14px;
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.auth-tab.active i {
    transform: scale(1.1);
}

/* ─── Tab Content ─── */
.auth-tab-content {
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.3s cubic-bezier(0.22, 1, 0.36, 1), transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
    position: absolute;
    width: 100%;
}

.auth-tab-content.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    position: relative;
}

#login-form {
    position: relative;
    min-height: 320px;
}

/* ─── OTP Group ─── */
.auth-otp-group {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

/* ─── Animations ─── */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes authShake {
    10%, 90% { transform: translate3d(-1px, 0, 0); }
    20%, 80% { transform: translate3d(2px, 0, 0); }
    30%, 50%, 70% { transform: translate3d(-4px, 0, 0); }
    40%, 60% { transform: translate3d(4px, 0, 0); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    33% { transform: translateY(-10px) rotate(1deg); }
    66% { transform: translateY(5px) rotate(-1deg); }
}

/* ─── Entry Animations (opacity only — no layout shift) ─── */
.auth-form-side {
    animation: authFadeIn 0.6s ease both;
}

.auth-logo {
    animation: authFadeIn 0.5s ease 0.1s both;
}

.auth-back-link {
    animation: authFadeIn 0.5s ease 0.15s both;
}

.auth-title {
    animation: authFadeIn 0.55s ease 0.2s both;
}

.auth-methods-stack .auth-method-btn:nth-child(1) { animation: authFadeIn 0.45s ease 0.25s both; }
.auth-methods-stack .auth-method-btn:nth-child(2) { animation: authFadeIn 0.45s ease 0.32s both; }
.auth-methods-stack .auth-method-btn:nth-child(3) { animation: authFadeIn 0.45s ease 0.39s both; }

.auth-divider { animation: authFadeIn 0.4s ease 0.35s both; }

.auth-sidebar-card {
    animation: authFadeIn 0.6s ease 0.4s both;
}

.auth-legal-note { animation: authFadeIn 0.4s ease 0.45s both; }
.auth-footer { animation: authFadeIn 0.4s ease 0.5s both; }

@keyframes authFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ─── Floating Shapes ─── */
.auth-shapes {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.auth-shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.5;
}

.auth-shape-1 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.04) 0%, transparent 70%);
    top: -100px;
    right: -100px;
    animation: float 8s ease-in-out infinite;
}

.auth-shape-2 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.03) 0%, transparent 70%);
    bottom: -80px;
    left: -80px;
    animation: float 10s ease-in-out infinite reverse;
}

.auth-shape-3 {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.02) 0%, transparent 70%);
    top: 40%;
    left: 60%;
    animation: float 12s ease-in-out infinite;
}

/* ─── Loading Spinner ─── */
.auth-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ─── Preloader ─── */
.auth-preloader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: #0a0a0a;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 28px;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.auth-preloader.hidden {
    opacity: 0;
    visibility: hidden;
}

.auth-preloader-logo {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    object-fit: contain;
    animation: preloaderPulse 1.2s ease-in-out infinite;
}

.auth-preloader-text {
    color: #fff;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.auth-preloader-sub {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    font-weight: 500;
}

.auth-preloader-bar {
    width: 200px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
}

.auth-preloader-bar-fill {
    height: 100%;
    width: 0%;
    background: #fff;
    border-radius: 3px;
    animation: preloaderFill 1.2s ease-in-out forwards;
}

@keyframes preloaderFill {
    0% { width: 0%; }
    60% { width: 80%; }
    100% { width: 100%; }
}

@keyframes preloaderPulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.8; }
}

@media (prefers-reduced-motion: reduce) {
    .auth-email-panel,
    .auth-methods,
    .auth-form-content.auth-show-form .auth-email-panel-inner > *,
    .auth-form-content.auth-show-form .auth-step,
    .auth-form-content.auth-show-form .auth-step-actions,
    .auth-sidebar-image,
    .auth-sidebar-tagline,
    .auth-sidebar-brand-pill,
    .auth-form-side,
    .auth-logo,
    .auth-back-link,
    .auth-title,
    .auth-methods-stack .auth-method-btn,
    .auth-divider,
    .auth-sidebar-card,
    .auth-legal-note,
    .auth-footer,
    .auth-form-side::after {
        transition: none !important;
        animation: none !important;
        transform: none !important;
        filter: none !important;
        opacity: 1 !important;
    }
}

/* ─── Creative Sections Below Card ─── */
.auth-creative-sections {
    width: 100%;
    padding: 80px 24px 60px;
    position: relative;
    z-index: 1;
}

.auth-creative-sections * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ─── Section Title ─── */
.creative-section-title {
    text-align: center;
    margin-bottom: 50px;
}

.creative-section-title h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.creative-section-title p {
    font-size: 1.05rem;
    color: var(--text-muted);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ─── Features Grid ─── */
.creative-features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    max-width: 1100px;
    margin: 0 auto 70px;
}

.creative-feature-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px 28px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.creative-feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.creative-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}

.creative-feature-card:hover::before {
    opacity: 1;
}

[data-theme="dark"] .creative-feature-card:hover {
    box-shadow: 0 12px 40px rgba(255, 255, 255, 0.05);
}

.creative-feature-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    margin-bottom: 20px;
    background: var(--accent-soft);
    color: var(--text-main);
    transition: var(--transition);
}

.creative-feature-card:hover .creative-feature-icon {
    transform: scale(1.08);
}

.creative-feature-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 10px;
}

.creative-feature-card p {
    font-size: 0.92rem;
    color: var(--text-muted);
    line-height: 1.65;
}

/* ─── Stats Bar ─── */
.creative-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 60px;
    max-width: 900px;
    margin: 0 auto 70px;
    padding: 40px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.creative-stat-item {
    text-align: center;
}

.creative-stat-number {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1;
    margin-bottom: 8px;
    letter-spacing: -0.03em;
}

.creative-stat-label {
    font-size: 0.88rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* ─── Trust Badges ─── */
.creative-trust {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
    margin-bottom: 70px;
}

.creative-trust-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: var(--accent-soft);
    border-radius: 100px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: var(--transition);
}

.creative-trust-badge i {
    font-size: 1rem;
    color: var(--text-main);
}

.creative-trust-badge:hover {
    background: var(--card-bg);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    transform: translateY(-2px);
}

[data-theme="dark"] .creative-trust-badge:hover {
    box-shadow: 0 4px 16px rgba(255, 255, 255, 0.04);
}

/* ─── CTA Banner ─── */
.creative-cta {
    max-width: 800px;
    margin: 0 auto 40px;
    text-align: center;
    padding: 48px 40px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
}

.creative-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 0%, var(--accent-soft) 0%, transparent 70%);
    pointer-events: none;
}

.creative-cta h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 12px;
    position: relative;
}

.creative-cta p {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 28px;
    position: relative;
    line-height: 1.6;
}

.creative-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 36px;
    background: var(--text-main);
    color: var(--auth-bg);
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
    position: relative;
}

.creative-cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    opacity: 0.9;
}

.creative-cta-btn i {
    font-size: 0.9rem;
    transition: transform 0.3s ease;
}

.creative-cta-btn:hover i {
    transform: translateX(-3px);
}

/* ─── Responsive ─── */
@media (max-width: 768px) {
    .auth-creative-sections {
        padding: 50px 16px 40px;
    }

    .creative-section-title h2 {
        font-size: 1.5rem;
    }

    .creative-features-grid {
        grid-template-columns: 1fr;
        gap: 16px;
        margin-bottom: 50px;
    }

    .creative-stats {
        gap: 30px;
        padding: 30px 0;
        margin-bottom: 50px;
    }

    .creative-stat-number {
        font-size: 1.8rem;
    }

    .creative-trust {
        gap: 12px;
        margin-bottom: 50px;
    }

    .creative-cta {
        padding: 32px 24px;
        margin-bottom: 30px;
    }

    .creative-cta h3 {
        font-size: 1.2rem;
    }
}

/* ─── Premium Button Loading & Success States ─── */
.auth-btn-primary,
.auth-btn-secondary,
.auth-method-btn {
    position: relative;
    overflow: hidden;
}

/* Loading spinner inside button */
.auth-btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    opacity: 1;
    transition: opacity 0.2s ease;
}

.auth-btn-loading .auth-btn-spinner {
    width: 18px;
    height: 18px;
    border: 2.5px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: authBtnSpin 0.7s linear infinite;
}

[data-theme="dark"] .auth-btn-loading .auth-btn-spinner {
    border-color: rgba(0, 0, 0, 0.25);
    border-top-color: #000;
}

.auth-btn-secondary .auth-btn-loading .auth-btn-spinner,
.auth-method-btn .auth-btn-loading .auth-btn-spinner {
    border-color: rgba(128, 128, 128, 0.3);
    border-top-color: var(--text-main);
}

@keyframes authBtnSpin {
    to { transform: rotate(360deg); }
}

/* Success checkmark inside button */
.auth-btn-primary.is-success,
.auth-btn-secondary.is-success {
    background: #22c55e !important;
    box-shadow: 0 4px 24px rgba(34, 197, 94, 0.4);
    animation: authBtnPulse 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.auth-btn-success {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.2s ease;
}

.auth-btn-success .auth-checkmark-svg {
    width: 30px;
    height: 30px;
}

.auth-btn-success .auth-checkmark-circle {
    fill: none;
    stroke: #fff;
    stroke-width: 2;
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    animation: authCheckCircle 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.auth-btn-success .auth-checkmark-check {
    fill: none;
    stroke: #fff;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: authCheckStroke 0.35s cubic-bezier(0.65, 0, 0.45, 1) 0.4s forwards;
}

@keyframes authBtnPulse {
    0% { transform: scale(1); }
    40% { transform: scale(1.04); }
    100% { transform: scale(1); }
}

@keyframes authCheckCircle {
    to { stroke-dashoffset: 0; }
}

@keyframes authCheckStroke {
    to { stroke-dashoffset: 0; }
}

/* Button transition smoothness */
.auth-btn-primary.is-loading,
.auth-btn-primary.is-success {
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.auth-method-btn.is-loading,
.auth-method-btn.is-success {
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
