/* =====================================================================
   Darkastral — giriş, kayıt, şifre ve doğrulama sayfaları
   site.css tasarım sistemini kullanır (renk, yazı, boşluk, düğmeler).
   ===================================================================== */

body.site--auth { min-height: 100svh; }

.gate { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(440px, 1fr); min-height: 100vh; min-height: 100svh; }

/* ---------- Sol: sinematik görsel ---------- */
.gate__visual { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; isolation: isolate; border-right: 1px solid var(--ds-line); }
.gate__visual img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 76% 50%; z-index: -2; }
.gate__visual::after {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background:
        linear-gradient(180deg, rgba(3, 5, 10, .9) 0%, rgba(3, 5, 10, .5) 30%, rgba(3, 5, 10, 0) 55%),
        linear-gradient(0deg, rgba(3, 5, 10, .7) 0%, rgba(3, 5, 10, 0) 25%);
}
.gate__visual-copy { position: absolute; left: clamp(32px, 5vw, 72px); right: clamp(32px, 5vw, 72px); top: clamp(48px, 10vh, 112px); }
.gate__slogan { margin-top: var(--s4); font-family: var(--ds-display); font-size: clamp(44px, 5.4vw, 84px); font-weight: 700; line-height: .92; text-transform: uppercase; }
.gate__slogan span { display: block; }
.gate__slogan-accent { color: var(--ds-blue); text-shadow: 0 0 48px rgba(61, 169, 255, .35); }
.gate__facts { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-top: var(--s5); color: var(--ds-mute); font-size: 14px; }
.gate__facts li { display: inline-flex; align-items: center; gap: 10px; }
.gate__facts li::before { content: ""; width: 5px; height: 5px; background: var(--ds-blue); transform: rotate(45deg); }

/* ---------- Sağ: form alanı ---------- */
.gate__side { position: relative; display: flex; flex-direction: column; min-width: 0; background: radial-gradient(700px 420px at 100% 0%, rgba(61, 169, 255, .08), transparent 70%), var(--ds-void); }
.gate__top { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); padding: var(--s5) clamp(24px, 4vw, 56px); }
.gate__top-nav { display: flex; align-items: center; gap: var(--s3); }
.gate__back { display: inline-flex; align-items: center; gap: 8px; padding: 8px 4px; color: var(--ds-mute); font-family: var(--ds-label); font-size: 12.5px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.gate__back svg { width: 16px; height: 16px; }
.gate__back:hover { color: var(--ds-ice); }
.gate__main { flex: 1; display: flex; flex-direction: column; justify-content: center; width: 100%; max-width: 520px; margin: 0 auto; padding: var(--s6) clamp(24px, 4vw, 40px) var(--s7); }
.gate__main:has(.auth-card--wide) { max-width: 640px; }
.gate__foot { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 20px; padding: var(--s5) clamp(24px, 4vw, 56px); border-top: 1px solid var(--ds-line); color: var(--ds-faint); font-size: 13px; }
.gate__foot a { color: var(--ds-mute); }
.gate__foot a:hover { color: var(--ds-ice); }

/* Bildirimler */
.gate__flash:empty { display: none; }
.gate__flash { display: grid; gap: var(--s2); margin-bottom: var(--s5); }
.site--auth .flash { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border: 1px solid var(--ds-line-2); border-radius: var(--r-sm); background: rgba(10, 20, 40, .7); color: var(--ds-ice); font-size: 14.5px; }
.site--auth .flash--success { border-color: rgba(111, 215, 170, .35); }
.site--auth .flash--error { border-color: rgba(255, 122, 110, .45); background: rgba(60, 14, 18, .45); }
.site--auth .flash__dot { flex: none; width: 8px; height: 8px; margin-top: 7px; border-radius: 50%; background: var(--ds-blue); }
.site--auth .flash--success .flash__dot { background: #6FD7AA; }
.site--auth .flash--error .flash__dot { background: #FF7A6E; }
.site--auth .flash p { flex: 1; overflow-wrap: anywhere; }
.site--auth .flash a { color: var(--ds-blue-hi); text-decoration: underline; }
.site--auth .flash__close { flex: none; display: grid; place-items: center; width: 28px; height: 28px; margin: -4px -6px -4px 0; border: 0; border-radius: 4px; background: none; color: var(--ds-mute); cursor: pointer; }
.site--auth .flash__close:hover { color: var(--ds-ice); background: rgba(140, 185, 255, .08); }
.site--auth .icon { width: 18px; height: 18px; }

/* ---------- Kart ve form ---------- */
.auth-card h1 { margin-top: var(--s3); font-family: var(--ds-display); font-size: clamp(32px, 3.4vw, 44px); font-weight: 700; line-height: 1.02; letter-spacing: .01em; text-transform: uppercase; text-wrap: balance; }
.auth-card__lead { margin-top: var(--s3); color: var(--ds-mute); font-size: 16px; }
.auth-card__lead strong { color: var(--ds-ice); font-weight: 600; overflow-wrap: anywhere; }
.auth-card .muted { margin-top: var(--s3); color: var(--ds-faint); font-size: 14.5px; }
.auth-card__switch { margin-top: var(--s6); padding-top: var(--s5); border-top: 1px solid var(--ds-line); color: var(--ds-mute); font-size: 15px; text-align: center; }
.auth-card__switch a, .link-btn { color: var(--ds-blue-hi); font-weight: 600; }
.auth-card__switch a:hover, .link-btn:hover { color: var(--ds-ice); }
.link-btn { padding: 4px; border: 0; background: none; cursor: pointer; font: inherit; font-weight: 600; color: var(--ds-blue-hi); }

.site--auth .form { display: grid; gap: var(--s5); margin-top: var(--s6); }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s4); }
.site--auth .field { display: grid; align-content: start; gap: var(--s2); min-width: 0; margin: 0; padding: 0; border: 0; }
.site--auth .field > label:not(.check), .site--auth .field__top label, .site--auth legend {
    padding: 0; color: var(--ds-mute); font-family: var(--ds-label); font-size: 12.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
}
.site--auth legend { margin-bottom: var(--s2); }
.field__top { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s3); }
.field__link { color: var(--ds-blue-hi); font-size: 13.5px; }
.field__link:hover { color: var(--ds-ice); }
.site--auth .field input[type="text"], .site--auth .field input[type="email"], .site--auth .field input[type="password"] {
    width: 100%; min-height: 50px; padding: 0 16px;
    border: 1px solid var(--ds-line-2); border-radius: var(--r-sm);
    background: rgba(10, 20, 40, .55); color: var(--ds-ice);
    font: 500 16px/1.2 var(--ds-body);
    transition: border-color .2s var(--ease), background-color .2s var(--ease), box-shadow .2s var(--ease);
}
.site--auth .field input::placeholder { color: var(--ds-faint); }
.site--auth .field input:hover { border-color: rgba(140, 203, 255, .4); }
.site--auth .field input:focus { outline: none; border-color: var(--ds-blue); background: rgba(10, 20, 40, .85); box-shadow: 0 0 0 3px rgba(61, 169, 255, .2); }
.site--auth .field input[aria-invalid="true"] { border-color: rgba(255, 122, 110, .7); }
.site--auth .field input:-webkit-autofill { -webkit-text-fill-color: var(--ds-ice); -webkit-box-shadow: 0 0 0 1000px #0B1730 inset; caret-color: var(--ds-ice); }
.field__hint { color: var(--ds-faint); font-size: 13.5px; }
.field__hint--links a { color: var(--ds-blue-hi); }
.field__hint--links a:hover { color: var(--ds-ice); }
.field__error { color: #FF9A90; font-size: 13.5px; }

.input-wrap { position: relative; }
.site--auth .input-wrap input { padding-right: 52px; }
/* core.css de translateY(-50%) veriyor: margin-top ile birlikte simge 20px yukarı kayıyordu → yalnızca transform */
.input-wrap__btn { position: absolute; top: 50%; right: 6px; display: grid; place-items: center; width: 40px; height: 40px; margin-top: 0; transform: translateY(-50%); border: 0; border-radius: 4px; background: none; color: var(--ds-mute); cursor: pointer; }
.input-wrap__btn:hover, .input-wrap__btn[aria-pressed="true"] { color: var(--ds-blue-hi); }

/* Sunucu seçimi (birden çok sunucu açıksa) */
.choice-grid { display: grid; gap: var(--s3); }
.choice { position: relative; display: block; cursor: pointer; }
.choice input { position: absolute; opacity: 0; }
.choice__body { display: grid; gap: 4px; padding: 14px 16px; border: 1px solid var(--ds-line-2); border-radius: var(--r-sm); background: rgba(10, 20, 40, .45); transition: border-color .2s var(--ease), background-color .2s var(--ease); }
.choice__title { font-family: var(--ds-display); font-size: 19px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.choice__meta { color: var(--ds-mute); font-size: 13.5px; }
.choice input:checked + .choice__body { border-color: var(--ds-blue); background: rgba(61, 169, 255, .08); }
.choice input:focus-visible + .choice__body { outline: 2px solid var(--ds-blue); outline-offset: 2px; }
.choice.is-disabled { opacity: .5; cursor: not-allowed; }

/* Avatar */
.avatar-pick { display: flex; flex-wrap: wrap; gap: 12px; }
.avatar-pick__item { position: relative; cursor: pointer; }
.avatar-pick__item input { position: absolute; opacity: 0; }
.avatar-pick__item .avatar { width: 46px; height: 46px; font-size: 18px; color: #04121F; box-shadow: inset 0 -6px 12px rgba(0, 0, 0, .25), 0 0 0 2px var(--ds-void), 0 0 0 3px var(--ds-line-2); transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.avatar-pick__item:hover .avatar { transform: translateY(-2px); }
.avatar-pick__item input:checked + .avatar { box-shadow: inset 0 -6px 12px rgba(0, 0, 0, .25), 0 0 0 2px var(--ds-void), 0 0 0 4px var(--ds-blue), 0 0 18px rgba(61, 169, 255, .45); }
.avatar-pick__item input:focus-visible + .avatar { outline: 2px solid var(--ds-blue-hi); outline-offset: 5px; }

/* Onay kutusu */
.check { display: flex; align-items: flex-start; gap: 12px; color: var(--ds-mute); font-size: 14.5px; cursor: pointer; }
/* Onay kutusu: tik SVG arka planı (input::after Safari'de çizilmez). Seçici .site--auth .field ile güçlendirildi:
   önceden ".site--auth .field input:focus" kuralı tıklanınca kutuyu yeniden koyu boyuyordu, tik görünmüyordu. */
.site--auth .field .check input {
    flex: none; appearance: none; -webkit-appearance: none; width: 22px; height: 22px; min-height: 0; margin: 1px 0 0; padding: 0;
    border: 1.5px solid var(--ds-line-2); border-radius: 5px; background: rgba(10, 20, 40, .55) center / 14px 14px no-repeat;
    box-shadow: none; cursor: pointer; transition: background-color .15s var(--ease), border-color .15s var(--ease);
}
.site--auth .field .check input:hover { border-color: rgba(140, 203, 255, .6); background-color: rgba(10, 20, 40, .55); }
.site--auth .field .check input:focus { background-color: rgba(10, 20, 40, .55); box-shadow: none; }
.site--auth .field .check input:checked, .site--auth .field .check input:checked:hover, .site--auth .field .check input:checked:focus {
    border-color: var(--ds-blue); background-color: var(--ds-blue);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3.2 3.2L13 4.8' fill='none' stroke='%2304121F' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.site--auth .field .check input:focus-visible { outline: 2px solid var(--ds-blue); outline-offset: 3px; }
.site--auth .field .check input[aria-invalid="true"]:not(:checked) { border-color: rgba(255, 122, 110, .8); }
.site--auth .check span { user-select: none; -webkit-user-select: none; }

/* Bal küpü alanı: botlar için, insanlara görünmez */
.hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.sbtn--block { width: 100%; }
.site--auth .form .sbtn { margin-top: var(--s2); }

/* ---------- Duyarlı ---------- */
@media (max-width: 1023px) {
    .gate { grid-template-columns: 1fr; }
    .gate__visual { position: relative; height: 230px; border: 0; order: -1; }
    .gate__visual img { object-position: 78% 45%; }
    .gate__visual::after { background: linear-gradient(0deg, var(--ds-void) 0%, rgba(3, 5, 10, .4) 55%, rgba(3, 5, 10, .55) 100%); }
    .gate__visual-copy { display: none; }
    .gate__side { margin-top: -230px; background: none; }
    .gate__top { padding: var(--s4) var(--gutter); }
    .gate__main { justify-content: flex-start; padding: 132px var(--gutter) var(--s7); }
}
@media (max-width: 560px) {
    .form__row { grid-template-columns: 1fr; gap: var(--s5); }
    .gate__back span { display: none; }
    .gate__back { padding: 10px; border: 1px solid var(--ds-line-2); border-radius: var(--r-sm); }
    .gate__main { padding-top: 124px; }
}

/* Kayıt sayfası: hoş geldin hediyesi (WelcomeBonus) */
.auth-gift { margin-top: var(--s4); padding: var(--s4) var(--s5); border: 1px solid rgba(240, 192, 64, .45); border-radius: 10px;
             background: linear-gradient(135deg, rgba(240, 192, 64, .12), rgba(240, 192, 64, .03)); }
.auth-gift__title { margin: 0 0 var(--s2); color: #F5CF63; font: 600 13px/1.2 "Chakra Petch", system-ui, sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.auth-gift__list { display: flex; flex-wrap: wrap; gap: 6px 8px; margin: 0; padding: 0; list-style: none; }
.auth-gift__list li { padding: 4px 10px; border-radius: 999px; background: rgba(240, 192, 64, .16); color: var(--ds-ice); font-size: 14px; font-weight: 600; }
.auth-gift__note { margin: var(--s2) 0 0; color: var(--ds-mute); font-size: 13px; }
