/**
 * Giriş / Kayıt — tek kaynak
 * Bootstrap .card kullanılmaz (main.css içindeki contain kurallarından kaçınmak için).
 */

/* ---- Sayfa: main içinde blok akışı, flex hack yok ---- */
#main-content .auth-wp {
    width: 100%;
    padding-bottom: 2rem;
}

/* Ana kutu: WoW başlık şeridi + auth içeriği (sidebar arama / güncellemeler ile aynı kabuk) */
.auth-page-shell.category-panel {
    padding: 0;
    overflow: hidden;
    max-width: 920px;
    margin-inline: auto;
    margin-bottom: 0 !important;
}

.auth-page-shell--register {
    max-width: 1040px;
}

.auth-page-shell > .auth-frame {
    border: none;
    border-radius: 0;
    box-shadow: none;
    max-width: none;
    margin: 0;
    background: transparent;
}

/* ---- Çerçeve (eski “premium-*-card”) ---- */
.auth-frame {
    --auth-radius: 18px;
    --auth-border: rgba(255, 255, 255, 0.08);
    --auth-form-bg: var(--dm-card-bg, #0c1420);
    --auth-form-text: var(--text-color, #e8eaef);
    --auth-input-bg: rgba(0, 0, 0, 0.2);
    --auth-input-border: rgba(255, 255, 255, 0.12);
    --auth-muted: rgba(232, 234, 239, 0.65);

    max-width: 920px;
    margin-inline: auto;
    border-radius: var(--auth-radius);
    border: 1px solid var(--auth-border);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.35);
    background: var(--auth-form-bg);
    color: var(--auth-form-text);
    display: grid;
    grid-template-columns: 1fr;
    overflow: hidden;
}

.auth-frame--register {
    max-width: 1040px;
}

[data-bs-theme="light"] .auth-frame {
    --auth-border: rgba(0, 0, 0, 0.08);
    --auth-form-bg: #ffffff;
    --auth-form-text: #1a1528;
    --auth-input-bg: #f4f2ee;
    --auth-input-border: rgba(0, 0, 0, 0.12);
    --auth-muted: rgba(26, 21, 40, 0.55);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

@media (min-width: 768px) {
    .auth-frame {
        grid-template-columns: minmax(260px, 38%) 1fr;
    }

    .auth-frame--register {
        grid-template-columns: minmax(240px, 34%) 1fr;
    }
}

/* ---- Sol görsel panel ---- */
.auth-frame__visual {
    display: none;
    position: relative;
    isolation: isolate;
    min-height: 300px;
    padding: 1.75rem 1.25rem;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    overflow: hidden;
    background: linear-gradient(-42deg, #0f172a, #1e1b4b, rgba(var(--primary-color-rgb), 0.55), #0f172a);
    background-size: 400% 400%;
    animation: authPagesGradient 16s ease infinite;
    box-shadow: inset 0 0 80px rgba(0, 0, 0, 0.55);
}

@media (min-width: 768px) {
    .auth-frame__visual {
        display: flex;
    }
}

@keyframes authPagesGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.auth-frame__visual::before,
.auth-frame__visual::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    filter: blur(56px);
    z-index: 0;
    pointer-events: none;
    animation: authPagesOrb 11s ease-in-out infinite alternate;
}

.auth-frame__visual::before {
    width: 220px;
    height: 220px;
    background: rgba(var(--primary-color-rgb), 0.45);
    top: -40px;
    left: -40px;
}

.auth-frame__visual::after {
    width: 260px;
    height: 260px;
    background: rgba(139, 92, 246, 0.35);
    bottom: -80px;
    right: -40px;
    animation-delay: -5s;
    animation-duration: 13s;
}

@keyframes authPagesOrb {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(32px, -28px) scale(1.12); }
}

.auth-frame__stars {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: 0.28;
    background-image:
        radial-gradient(2px 2px at 20px 30px, #eee, transparent),
        radial-gradient(2px 2px at 80px 60px, #fff, transparent),
        radial-gradient(2px 2px at 50px 140px, #ddd, transparent);
    background-size: 180px 180px;
}

.auth-frame__brand {
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 14px rgba(0, 0, 0, 0.55);
}

/* Sol yan panel — marka + bölümlü içerik */
.auth-frame__brand--side {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 18.5rem;
    margin-inline: auto;
    gap: 1rem;
    text-align: center;
}

.auth-frame__brand-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    width: 100%;
}

.auth-frame__logo-img {
    max-height: 58px;
    width: auto;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 4px 18px rgba(0, 0, 0, 0.5));
}

.auth-frame__brand-caption {
    margin: 0;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    opacity: 0.88;
    line-height: 1.3;
}

.auth-frame__brand-fallback {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    line-height: 1.2;
    font-family: var(--site-font-title, inherit);
}

.auth-frame__lead {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.5;
    opacity: 0.88;
    padding: 0 0.15rem;
}

.auth-frame__visual-section {
    width: 100%;
    text-align: left;
}

.auth-frame__visual-kicker {
    margin: 0 0 0.5rem;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    opacity: 0.78;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.auth-frame__perk-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.auth-frame__perk-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin: 0;
    text-align: left;
}

.auth-frame__perk-icon {
    flex-shrink: 0;
    width: 1.85rem;
    height: 1.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.2);
    color: #fbbf24;
    font-size: 0.85rem;
}

.auth-frame__perk-body {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
}

.auth-frame__perk-title {
    display: block;
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1.25;
}

.auth-frame__perk-desc {
    display: block;
    font-size: 0.74rem;
    line-height: 1.4;
    opacity: 0.78;
    font-weight: 400;
}

.auth-frame__lead--register {
    margin-bottom: 0;
}

/* İki blok (üyelik + gözde konular) arasında hafif boşluk */
.auth-frame__brand--side > .auth-frame__visual-section + .auth-frame__visual-section {
    margin-top: 0.25rem;
}

.auth-frame__topic-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.38rem;
}

.auth-frame__topic-links a {
    display: block;
    font-size: 0.76rem;
    line-height: 1.35;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.94);
    text-decoration: none;
    padding: 0.4rem 0.55rem;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(0, 0, 0, 0.18);
    transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.auth-frame__topic-links a:hover {
    color: #fff;
    border-color: rgba(var(--primary-color-rgb), 0.55);
    background: rgba(var(--primary-color-rgb), 0.22);
}

.auth-frame__topic-hint,
.auth-frame__topic-empty {
    margin: 0.55rem 0 0;
    font-size: 0.7rem;
    line-height: 1.4;
    opacity: 0.64;
}

.auth-frame__topic-empty {
    opacity: 0.72;
}

/* Kayıt sol sütun: daha kompakt yükseklik */
.auth-frame--register .auth-frame__visual {
    min-height: 0;
    padding: 1.45rem 1.1rem 1.6rem;
}

@media (min-width: 768px) {
    .auth-frame--register .auth-frame__visual {
        min-height: 280px;
        justify-content: flex-start;
        padding-top: 1.75rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-frame__visual,
    .auth-frame__visual::before,
    .auth-frame__visual::after {
        animation: none;
    }
}

/* ---- Form sütunu ---- */
.auth-frame__main {
    padding: 1.75rem 1.35rem 2rem;
    background: var(--auth-form-bg);
}

@media (min-width: 768px) {
    .auth-frame__main {
        padding: 2rem 2rem 2.25rem;
    }
}

.auth-frame__title {
    font-size: 1.45rem;
    font-weight: 700;
    margin-bottom: 0.35rem;
    color: var(--auth-form-text);
}

.auth-frame__subtitle {
    font-size: 0.875rem;
    color: var(--auth-muted);
    margin-bottom: 1.25rem;
}

.auth-frame__main .form-label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--auth-muted);
}

.auth-frame__main .form-control {
    background: var(--auth-input-bg) !important;
    border: 1px solid var(--auth-input-border) !important;
    color: var(--auth-form-text) !important;
    border-radius: 4px;
    min-height: 44px;
}

.auth-frame__main .form-control:focus {
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 0.2rem rgba(var(--primary-color-rgb), 0.2) !important;
}

/* Giriş: input-group */
.auth-input-line .input-group-text {
    background: var(--auth-input-bg);
    border: 1px solid var(--auth-input-border);
    border-right: none;
    color: var(--auth-form-text);
    border-radius: 4px 0 0 4px;
}

.auth-input-line .form-control {
    border-radius: 0 4px 4px 0 !important;
}

[data-bs-theme="light"] .auth-input-line .input-group-text {
    background: #ebe8e3;
    border-color: var(--auth-input-border);
    color: #1a1528;
}

/* Giriş: beni hatırla */
.auth-remember {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    margin: 0 0 1rem;
    padding: 0.7rem 0.9rem;
    border-radius: 4px;
    border: 1px solid var(--auth-input-border);
    background: var(--auth-input-bg);
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
    user-select: none;
}

.auth-remember:hover {
    border-color: rgba(var(--primary-color-rgb), 0.4);
    background: rgba(var(--primary-color-rgb), 0.05);
}

.auth-remember:has(.auth-remember__input:focus-visible) {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(var(--primary-color-rgb), 0.18);
}

.auth-remember__input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
}

.auth-remember__box {
    flex-shrink: 0;
    width: 1.2rem;
    height: 1.2rem;
    border-radius: 4px;
    border: 1.5px solid var(--auth-input-border);
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}

.auth-remember__input:checked + .auth-remember__box {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.auth-remember__input:checked + .auth-remember__box::after {
    content: "";
    width: 0.32rem;
    height: 0.58rem;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    margin-top: -0.12rem;
}

.auth-remember__text {
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
    min-width: 0;
    flex: 1;
}

.auth-remember__title {
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--auth-form-text);
    line-height: 1.25;
    letter-spacing: 0.01em;
}

.auth-remember__hint {
    font-size: 0.72rem;
    color: var(--auth-muted);
    line-height: 1.35;
    font-weight: 400;
}

.auth-remember__icon {
    flex-shrink: 0;
    margin-left: auto;
    font-size: 0.82rem;
    color: var(--auth-muted);
    opacity: 0.55;
    transition: color 0.15s ease, opacity 0.15s ease;
}

.auth-remember:hover .auth-remember__icon,
.auth-remember:has(.auth-remember__input:checked) .auth-remember__icon {
    color: var(--primary-color);
    opacity: 0.85;
}

[data-bs-theme="light"] .auth-remember {
    background: #f4f2ee;
}

[data-bs-theme="light"] .auth-remember:hover {
    background: rgba(var(--primary-color-rgb), 0.06);
}

/* Kayıt: önizleme + hazır avatarlar */
.auth-profile-block {
    text-align: center;
    margin-bottom: 1.5rem;
}

.auth-profile-hint {
    color: var(--auth-muted);
}

.auth-preview-wrap {
    position: relative;
    display: inline-block;
}

.auth-preview-img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    border: 3px solid rgba(var(--primary-color-rgb), 0.45);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.auth-upload-fab {
    position: absolute;
    right: -6px;
    bottom: -6px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary-color);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 3px solid var(--auth-form-bg);
    font-size: 0.85rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.auth-preset-row {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    gap: 0.45rem;
    margin-top: 1rem;
    padding: 0.35rem 0.25rem;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.auth-preset-row::-webkit-scrollbar {
    height: 4px;
}

.auth-preset-row::-webkit-scrollbar-thumb {
    background: rgba(var(--primary-color-rgb), 0.35);
    border-radius: 4px;
}

.auth-preset-item {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
}

.auth-preset-item label {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0;
    border-radius: 50%;
    cursor: pointer;
}

.auth-preset-item img {
    width: 38px;
    height: 38px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid transparent;
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-preset-item input:checked + label img {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(var(--primary-color-rgb), 0.35);
}

.auth-preset-item input:focus-visible + label {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Form ızgarası (kayıt) */
.auth-form-grid {
    display: grid;
    gap: 1rem 1.1rem;
    grid-template-columns: 1fr;
    margin-bottom: 0.25rem;
}

@media (min-width: 576px) {
    .auth-form-grid {
        grid-template-columns: 1fr 1fr;
    }

    .auth-form-grid__wide {
        grid-column: 1 / -1;
    }
}

.auth-captcha {
    padding: 0.85rem 1rem;
    border-radius: 4px;
    border: 1px dashed rgba(var(--primary-color-rgb), 0.35);
    background: rgba(var(--primary-color-rgb), 0.06);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.auth-captcha .form-control {
    max-width: 120px;
}

/* Eylemler */
.auth-actions {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    margin-top: 1.25rem;
}

.auth-actions .btn.btn-primary {
    border-radius: 4px;
    font-weight: 700;
    letter-spacing: 0.03em;
    min-height: 48px;
    box-shadow: 0 4px 14px rgba(var(--primary-color-rgb), 0.28);
}

.auth-frame .btn.btn-primary:hover,
.auth-frame .btn.btn-primary:focus {
    transform: none;
    filter: brightness(1.06);
}

.auth-or {
    text-align: center;
    position: relative;
    margin: 0.15rem 0;
    font-size: 0.82rem;
    color: var(--auth-muted);
}

.auth-or::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    height: 1px;
    background: var(--auth-input-border);
}

.auth-or span {
    position: relative;
    padding: 0 0.85rem;
    background: var(--auth-form-bg);
}

.auth-btn-google {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    min-height: 48px;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    border: 1px solid var(--auth-input-border);
    background: transparent;
    color: var(--auth-form-text);
    font-weight: 600;
    text-decoration: none;
    transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.auth-btn-google:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.07);
}

.auth-frame__footer {
    margin-top: 1.5rem;
    text-align: center;
    font-size: 0.875rem;
    color: var(--auth-muted);
}

.auth-frame__footer a {
    font-weight: 700;
}

.auth-frame__aux-link {
    color: var(--primary-color);
}

.auth-frame__aux-link:hover {
    color: var(--primary-color);
    opacity: 0.88;
}

/* Kayıt: alan doğrulama + şifre kuralları */
.auth-field-input {
    position: relative;
}

.auth-field-input .form-control {
    padding-right: 2rem;
}

.auth-input-status {
    position: absolute;
    right: 0.6rem;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    line-height: 1;
}

.auth-input-status:empty {
    display: none;
}

.auth-pw-rules {
    font-size: 0.78rem;
    line-height: 1.45;
    margin-top: 0.5rem;
    color: var(--auth-muted);
}

.auth-pw-rule {
    display: flex;
    align-items: flex-start;
    gap: 0.45rem;
    margin-bottom: 0.25rem;
    transition: color 0.15s ease;
}

.auth-pw-rule:last-child {
    margin-bottom: 0;
}

.auth-pw-rule-icon {
    font-size: 0.45rem;
    margin-top: 0.35rem;
    opacity: 0.5;
    flex-shrink: 0;
}

.auth-pw-rule.is-done {
    color: #198754;
}

.auth-pw-rule.is-done .auth-pw-rule-icon {
    display: none;
}

.auth-pw-rule.is-done::before {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 0.65rem;
    margin-top: 0.2rem;
    flex-shrink: 0;
    color: #198754;
}

.auth-pw-match-hint.text-success {
    font-weight: 600;
}

.auth-field-wrap .form-control.is-valid,
.auth-field-wrap .form-control.is-invalid {
    background-image: none;
}

[data-bs-theme="dark"] .auth-pw-rule.is-done {
    color: #5ee397;
}

[data-bs-theme="dark"] .auth-pw-rule.is-done::before {
    color: #5ee397;
}

/* Şifremi unuttum — başarı bilgi paneli */
.forgot-pw-success-panel {
    border: 1px solid rgba(25, 135, 84, 0.35);
    border-radius: 12px;
    padding: 1rem 1.1rem;
    margin-bottom: 1.25rem;
    background: rgba(25, 135, 84, 0.08);
    color: var(--auth-form-text);
}

[data-bs-theme="light"] .forgot-pw-success-panel {
    background: rgba(25, 135, 84, 0.06);
    border-color: rgba(25, 135, 84, 0.28);
}

.forgot-pw-success-panel__title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: var(--auth-form-text);
}

.forgot-pw-success-panel__title i {
    color: #198754;
}

.forgot-pw-success-panel__email {
    font-weight: 700;
    word-break: break-all;
    color: var(--auth-form-text);
}

.forgot-pw-success-panel__lead {
    font-size: 0.875rem;
    color: var(--auth-muted);
    margin-bottom: 0.75rem;
    line-height: 1.45;
}

.forgot-pw-hint-list {
    margin: 0;
    padding-left: 0;
    list-style: none;
    font-size: 0.8125rem;
    color: var(--auth-muted);
    line-height: 1.5;
}

.forgot-pw-hint-list li {
    display: grid;
    grid-template-columns: 1.125rem minmax(0, 1fr);
    gap: 0.5rem;
    align-items: start;
    margin-bottom: 0.45rem;
}

.forgot-pw-hint-list li:last-child {
    margin-bottom: 0;
}

/* Konu listesi başlık linkleri ile aynı tema renkleri */
.forgot-pw-hint-list i {
    justify-self: center;
    flex-shrink: 0;
    width: 1rem;
    text-align: center;
    font-size: inherit;
    line-height: 1;
    display: block;
    padding-top: 0.28em;
    color: var(--secondary-text-color-hex);
}

[data-bs-theme="dark"] .forgot-pw-hint-list i {
    color: var(--dark-secondary-text-color-hex);
}

.forgot-pw-btn-icons {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.125rem;
}
