/* Oyunova — giriş / kayıt v2: tam ekran bölünmüş yapı + kayan panel
   Eskiye dönmek: login.php?old=1 · register.php?old=1 */

@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .18s; }

html, body { height: 100%; }
body {
  background: #fff !important; padding: 0 !important; margin: 0 !important; min-height: 100vh;
  display: block !important; overflow-x: hidden;
}
.particles-container { display: none !important; }

/* ── İskelet: ekranı ikiye bölen yapı ── */
.auth-shell {
  display: flex !important; width: 100% !important; max-width: none !important; margin: 0 !important;
  height: 100vh; height: 100dvh; min-height: 560px; max-height: none !important;
  border-radius: 0 !important; box-shadow: none !important; overflow: hidden; background: #fff;
  -webkit-backdrop-filter: none; backdrop-filter: none;
}
.auth-shell:has(.register-container) { flex-direction: row-reverse; }

/* sol/sağ tanıtım paneli */
.auth-brand {
  display: flex !important; flex-direction: column; justify-content: center;
  flex: 0 0 46% !important; position: relative; overflow: hidden; padding: 56px clamp(32px, 5vw, 84px) !important;
  color: #fff; opacity: 1 !important; transform: none; transition: none !important;
  background:
    radial-gradient(560px 380px at 12% 8%, rgba(255,255,255,.22), transparent 65%),
    radial-gradient(520px 420px at 95% 100%, rgba(244,114,182,.45), transparent 65%),
    linear-gradient(150deg, #4338ca 0%, #6d28d9 52%, #a21caf 100%) !important;
}
.auth-brand::before, .auth-brand::after { content: ''; position: absolute; border-radius: 50%; background: rgba(255,255,255,.09) !important; pointer-events: none; }
.auth-brand::before { width: 420px; height: 420px; top: -150px; right: -130px; animation: ab-drift 14s ease-in-out infinite; }
.auth-brand::after { width: 320px; height: 320px; bottom: -120px; left: -90px; animation: ab-drift 18s ease-in-out infinite reverse; }
@keyframes ab-drift { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(26px,-22px) scale(1.08); } }
.auth-brand > * { position: relative; z-index: 2; }

.auth-brand-logo {
  width: 68px !important; height: 68px !important; border-radius: 22px !important; margin: 0 0 26px !important;
  display: flex !important; align-items: center; justify-content: center;
  background: rgba(255,255,255,.18) !important; box-shadow: 0 0 0 1px rgba(255,255,255,.32) inset, 0 14px 30px rgba(20,8,70,.35);
}
.auth-brand-logo .aic, .auth-brand-logo svg { width: 36px; height: 36px; color: #fff; }
.auth-brand h1 { font-size: clamp(2rem, 3.2vw, 3rem) !important; line-height: 1.12 !important; font-weight: 800; letter-spacing: -1px; margin: 0 0 16px !important; text-shadow: 0 6px 30px rgba(20,8,70,.35); }
.auth-brand p { font-size: 1.05rem !important; line-height: 1.6; color: rgba(255,255,255,.86) !important; max-width: 420px; margin: 0 0 30px !important; }
.auth-brand-features { list-style: none; padding: 0 !important; margin: 0 !important; display: flex; flex-direction: column; gap: 14px; }
.auth-brand-features li {
  display: flex !important; align-items: center; gap: 14px; background: none !important; box-shadow: none !important; padding: 0 !important;
  font-weight: 700; font-size: 1rem; color: #fff !important; opacity: 1 !important; transform: none !important; transition: none !important;
}
.auth-brand-features li i {
  width: 40px !important; height: 40px !important; border-radius: 13px !important; flex: none; display: flex !important; align-items: center; justify-content: center;
  background: rgba(255,255,255,.18) !important; color: #fde68a !important; font-size: 1rem; box-shadow: 0 0 0 1px rgba(255,255,255,.25) inset;
}

/* yüzen oyun ikonları (js ekler) */
.ab-float { position: absolute; z-index: 1; color: rgba(255,255,255,.16); pointer-events: none; animation: ab-float 9s ease-in-out infinite; }
.ab-float svg { width: 100%; height: 100%; display: block; }
@keyframes ab-float { 0%,100% { transform: translateY(0) rotate(var(--r, 0deg)); } 50% { transform: translateY(-22px) rotate(calc(var(--r, 0deg) + 8deg)); } }

/* metin girişi animasyonu (panel kaydıktan sonra) */
.auth-brand-logo, .auth-brand h1, .auth-brand p, .auth-brand-features li { animation: ab-in .7s cubic-bezier(.2,.7,.2,1) both; }
.auth-brand h1 { animation-delay: .12s; } .auth-brand p { animation-delay: .2s; }
.auth-brand-features li:nth-child(1) { animation-delay: .28s; } .auth-brand-features li:nth-child(2) { animation-delay: .36s; } .auth-brand-features li:nth-child(3) { animation-delay: .44s; }
@keyframes ab-in { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ── Form paneli ── */
.login-container, .register-container {
  flex: 1 1 0 !important; min-width: 0; width: auto !important; max-width: none !important; margin: 0 !important;
  height: 100%; max-height: none !important; overflow-x: hidden; overflow-y: auto !important;
  background: #fff !important; color: #1e1b4b; border-radius: 0 !important; box-shadow: none !important;
  padding: 40px clamp(28px, 6vw, 96px) !important; text-align: left !important;
  display: flex !important; flex-direction: column; align-items: center;
  opacity: 1 !important; transform: none; transition: none !important;
  -webkit-backdrop-filter: none !important; backdrop-filter: none !important;
}
.login-container::before, .login-container::after, .register-container::before, .register-container::after { content: ''; flex: 1 0 0; }
.login-container > *, .register-container > * { width: 100%; max-width: 420px; flex: none; }

h2 {
  display: block !important; margin: 0 0 6px !important; font-size: 2.05rem !important; font-weight: 800; letter-spacing: -.8px;
  color: #1e1b4b !important; text-shadow: none !important; text-align: left; line-height: 1.15;
}
h2::after { display: none !important; }
.auth-sub { margin: 0 0 26px; color: #64748b; font-weight: 500; font-size: .98rem; }
.login-container p, .register-container p { color: #64748b; }
.login-container p[style], .register-container p[style] { color: #64748b !important; }

label { color: #334155 !important; font-weight: 700; font-size: .86rem; margin-bottom: 7px; }
.form-group { margin-bottom: 16px !important; }

input[type="text"], input[type="email"], input[type="password"], input[type="number"], select {
  background: #f4f5fb !important; color: #1e1b4b !important; border: 1.5px solid #e3e6f3 !important; border-radius: 14px !important;
  padding: 15px 46px 15px 16px !important; font-size: 1rem; box-shadow: none !important; transition: border-color .2s, box-shadow .2s, background .2s !important;
}
input::placeholder { color: #9aa3b8 !important; }
input[type="text"]:focus, input[type="email"]:focus, input[type="password"]:focus {
  background: #fff !important; border-color: #6d28d9 !important; box-shadow: 0 0 0 4px rgba(109,40,217,.13) !important; transform: none !important;
}
.register-container input[type="text"], .register-container input[type="email"], .register-container input[type="password"] { padding: 15px 16px 15px 48px !important; }
.input-icon { color: #8b93b0 !important; }
input:focus + .input-icon { color: #6d28d9 !important; transform: none !important; }
input[type="checkbox"] { accent-color: #6d28d9 !important; }
.checkbox-group label, #rememberMeGroup label { color: #475569 !important; font-weight: 600; }
.checkbox-group a { color: #6d28d9 !important; }

.btn {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 60%, #a21caf 100%) !important; color: #fff !important; border: 0 !important;
  border-radius: 14px !important; padding: 16px 26px !important; font-size: 1.05rem !important; font-weight: 800 !important; letter-spacing: .2px;
  box-shadow: 0 14px 30px rgba(109,40,217,.35) !important;
}
.btn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 18px 38px rgba(109,40,217,.45) !important; }
.btn:disabled { background: #d6d9e6 !important; color: #fff !important; box-shadow: none !important; }
.btn .loader { border-color: rgba(255,255,255,.35); border-top-color: #fff; }
.btn-guest { background: #f4f5fb !important; color: #4338ca !important; box-shadow: none !important; }

.register-link, .login-link { color: #64748b !important; text-align: center; margin-top: 18px !important; }
.register-link a, .login-link a { color: #6d28d9 !important; font-weight: 800; border-bottom: 0 !important; }
.register-link a::after, .login-link a::after { background: #6d28d9 !important; }
.google-signin-wrap span[style*="height:1px"] { background: #e3e6f3 !important; }
.g-recaptcha { transform-origin: left center; }

.error-message { background: #fef2f2 !important; color: #b91c1c !important; border: 0 !important; border-radius: 14px !important; box-shadow: 0 0 0 1px #fecaca inset; text-align: left; }
.success-message { background: #f0fdf4 !important; color: #15803d !important; border: 0 !important; border-radius: 14px !important; box-shadow: 0 0 0 1px #bbf7d0 inset; text-align: left; }
.message { border-radius: 14px !important; }
.message.error { background: #fef2f2 !important; color: #b91c1c !important; }
.message.success { background: #f0fdf4 !important; color: #15803d !important; }

.form-footer { color: #94a3b8 !important; border-top: 1px solid #eceef7 !important; text-align: center; }
.form-footer a { color: #6d28d9 !important; }
.social-links { justify-content: center; }
.social-links a { background: #f4f5fb !important; color: #4338ca !important; box-shadow: none !important; }

.otp-box { background: #f4f5fb !important; color: #1e1b4b !important; border: 1.5px solid #e3e6f3 !important; border-radius: 14px !important; }
.otp-box:focus { border-color: #6d28d9 !important; box-shadow: 0 0 0 4px rgba(109,40,217,.15) !important; }
.otp-box.filled { background: #ede9fe !important; border-color: #a78bfa !important; }
.verify-step-box { background: #f4f5fb !important; border: 0 !important; border-radius: 16px !important; color: #1e1b4b !important; }
.verify-step-box h3 { color: #1e1b4b !important; }

/* ── Mobil: üstte kısa şerit, altta form ── */
@media (max-width: 899px) {
  .auth-shell, .auth-shell:has(.register-container) { flex-direction: column !important; height: auto; min-height: 100vh; overflow: visible; }
  .auth-brand { flex: none !important; padding: 34px 26px 62px !important; border-radius: 0 0 34px 34px; }
  .auth-brand-logo { width: 50px !important; height: 50px !important; border-radius: 16px !important; margin-bottom: 14px !important; }
  .auth-brand-logo svg, .auth-brand-logo .aic { width: 28px; height: 28px; }
  .auth-brand h1 { font-size: 1.6rem !important; margin: 0 !important; }
  .auth-brand p, .auth-brand-features, .ab-float { display: none !important; }
  .login-container, .register-container {
    height: auto; overflow: visible !important; margin: -34px 14px 24px !important; border-radius: 26px !important;
    padding: 30px 22px 26px !important; box-shadow: 0 20px 50px rgba(30,27,75,.18) !important; width: auto !important;
    animation: ab-in .6s cubic-bezier(.2,.7,.2,1) both;
  }
  .login-container::before, .login-container::after, .register-container::before, .register-container::after { display: none; }
  .login-container > *, .register-container > * { max-width: none; }
  h2 { font-size: 1.7rem !important; }
}
@media (prefers-reduced-motion: reduce) { .auth-brand::before, .auth-brand::after, .ab-float { animation: none !important; } }
.login-container h2, .register-container h2 { text-align: left !important; width: 100%; }

.back-link { color: #6d28d9 !important; text-align: center; font-weight: 800; margin-top: 18px !important; display: block; text-decoration: none; }
.back-link:hover { text-decoration: underline; }
