.oftimor-auth-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 160ms ease;
}
.oftimor-auth-overlay[aria-hidden="false"] {
    opacity: 1;
    pointer-events: auto;
}

.oftimor-auth-overlay__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 18, 32, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.oftimor-auth-overlay__card {
    position: relative;
    background: #fff;
    color: #0F1220;
    max-width: 460px;
    width: 100%;
    border-radius: 12px;
    padding: 28px 28px 22px;
    box-shadow: 0 24px 60px rgba(15, 18, 32, 0.28);
    transform: translateY(8px);
    transition: transform 160ms ease;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
}
.oftimor-auth-overlay[aria-hidden="false"] .oftimor-auth-overlay__card {
    transform: translateY(0);
}

.oftimor-auth-overlay__close {
    position: absolute;
    top: 10px;
    right: 12px;
    background: transparent;
    border: 0;
    font-size: 1.6rem;
    line-height: 1;
    padding: 6px 10px;
    cursor: pointer;
    color: #6B7180;
}
.oftimor-auth-overlay__close:hover { color: #0F1220; }

.oftimor-auth-overlay__title {
    font-size: 1.35rem;
    margin: 0 0 16px;
    letter-spacing: -0.005em;
}

/* ===== Tabs (Log In / Sign Up) ===== */
.oftimor-auth-overlay__tabs {
    display: flex;
    gap: 4px;
    background: #f3f5fb;
    padding: 4px;
    border-radius: 999px;
    margin: 0 0 18px;
}
.oftimor-auth-overlay__tab {
    flex: 1;
    background: transparent;
    border: 0;
    padding: 8px 14px;
    border-radius: 999px;
    font-weight: 600;
    color: #6B7180;
    cursor: pointer;
    transition: background 120ms ease, color 120ms ease;
}
.oftimor-auth-overlay__tab.is-active {
    background: #fff;
    color: #1F2B5E;
    box-shadow: 0 1px 4px rgba(15, 18, 32, 0.08);
}
.oftimor-auth-overlay__tab:hover:not(.is-active) {
    color: #0F1220;
}
.oftimor-auth-overlay__panel { display: none; }
.oftimor-auth-overlay__panel.is-active { display: block; }

.oftimor-auth-overlay__body :where(input, button, select, textarea) {
    font: inherit;
}
.oftimor-auth-overlay__body input[type="text"],
.oftimor-auth-overlay__body input[type="email"],
.oftimor-auth-overlay__body input[type="tel"],
.oftimor-auth-overlay__body input[type="password"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #D8DBE5;
    border-radius: 6px;
    box-sizing: border-box;
}

.oftimor-auth-overlay__hint,
.oftimor-auth-overlay__fallback {
    margin: 14px 0 0;
    font-size: 0.85rem;
    color: #6B7180;
    text-align: center;
}

/* Floating sign-in / account button */
.oftimor-auth-overlay-fab {
    position: fixed;
    top: 12px;
    right: 16px;
    z-index: 99998;
    background: #1F2B5E;
    color: #fff;
    border: 0;
    border-radius: 999px;
    padding: 9px 16px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(15, 18, 32, 0.18);
    font-size: 0.9rem;
    text-decoration: none;
    line-height: 1.2;
}
.oftimor-auth-overlay-fab:hover { background: #273476; }
.oftimor-auth-overlay-fab[data-state="account"] {
    background: #fff;
    color: #1F2B5E;
    border: 1px solid #1F2B5E;
}

@media (max-width: 480px) {
    .oftimor-auth-overlay__card { padding: 20px 18px; border-radius: 10px; }
    .oftimor-auth-overlay-fab { top: 8px; right: 10px; padding: 7px 12px; font-size: 0.85rem; }
}

@media (prefers-reduced-motion: reduce) {
    .oftimor-auth-overlay,
    .oftimor-auth-overlay__card { transition: none; }
}
