/* ==========================================================================
   BilgeAP — giriş / kayıt / şifre sıfırlama (giris.html, sifre-sifirla.html)
   Masaüstü: form + enerjik görsel panel; telefon: tek sütun (önce form).
   styles.css token'ları; ham renk yalnızca mor degrade üstündeki beyaz yazı için.
   Ön ek: .gr-
   ========================================================================== */

:root { --gr-ease: cubic-bezier(.2, .8, .2, 1); }
body.page-giris { overflow-x: clip; }
.gr-main { max-width: 1120px; margin: 0 auto; padding: clamp(16px, 3vw, 40px) 16px clamp(32px, 5vw, 56px); }
.gr-shell {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 460px); gap: 0; align-items: stretch;
  border-radius: 28px; overflow: hidden; background: var(--surface); border: 1px solid var(--border);
  box-shadow: 0 30px 70px -30px color-mix(in srgb, var(--accent) 45%, transparent), var(--shadow-card);
}
.gr-shell > .gr-visual { order: -1; }

/* --- Form kartı --------------------------------------------------------- */
.gr-card { min-width: 0; display: grid; gap: var(--sp-5); align-content: start; padding: clamp(24px, 4vw, 48px) clamp(20px, 3.5vw, 44px); }
.gr-view { display: grid; gap: var(--sp-5); min-width: 0; }
.gr-view[hidden], .gr-panel[hidden], .gr-form[hidden] { display: none; }
.gr-title { margin: 0; font-size: clamp(1.625rem, 1.3rem + 1vw, 2rem); font-weight: 900; line-height: 1.15; letter-spacing: -.01em; }
.gr-title:focus { outline: none; }
.gr-sub { margin: -12px 0 0; color: var(--text-muted); }
.gr-form { display: grid; gap: var(--sp-4); min-width: 0; }
.gr-form .text-input { min-height: 48px; border-radius: 14px; font-size: var(--fs-16); }
.gr-form .text-input:focus { border-color: var(--accent); box-shadow: var(--focus-ring); }
.gr-form .field.is-valid > .text-input, .gr-form .field.is-valid .input-wrap > .text-input { border-color: color-mix(in srgb, var(--ok) 60%, var(--border)); }
.gr-form .text-input[aria-invalid="true"] { border-color: var(--bad); }
.gr-form .field-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--sp-3); }
.gr-label-row { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); }
.gr-label-row label { font-weight: 700; font-size: .9rem; color: var(--text); }
.gr-link { display: inline-flex; align-items: center; min-height: 36px; padding: 0; border: 0; background: none; color: var(--accent); font: 700 var(--fs-14)/1.2 var(--font-sans); cursor: pointer; text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 3px; transition: text-decoration-color .15s ease; }
.gr-link:hover { text-decoration-color: currentColor; }
.gr-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.gr-submit { min-height: 52px; border-radius: 14px; font-size: var(--fs-16); transition: transform .15s var(--gr-ease), box-shadow .2s ease, background-color .15s ease; }
.gr-submit:active:not(:disabled) { transform: scale(.985); }
.gr-switch { margin: 0; text-align: center; color: var(--text-muted); font-size: var(--fs-14); }
.gr-safe { margin: 0; display: flex; gap: 8px; align-items: center; justify-content: center; color: var(--text-muted); font-size: var(--fs-14); padding-top: var(--sp-4); border-top: 1px solid var(--border); }
.gr-safe svg { width: 16px; height: 16px; flex: none; color: var(--ok); }

/* Sekmeler: kayan gösterge */
.gr-tabs { position: relative; display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 16px; background: var(--surface-3); }
.gr-tabs::before { content: ""; position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); border-radius: 12px; background: var(--surface); box-shadow: var(--shadow-card), 0 0 0 1px var(--border); transition: transform .35s var(--gr-ease); }
.gr-tabs[data-active="kayit"]::before { transform: translateX(100%); }
.gr-tab { position: relative; z-index: 1; min-height: 44px; border: 0; background: none; border-radius: 12px; color: var(--text-muted); font: 800 var(--fs-16)/1 var(--font-head); cursor: pointer; transition: color .2s ease; }
.gr-tab[aria-selected="true"] { color: var(--accent); }
.gr-tab:hover { color: var(--text); }
.gr-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Şifre gücü */
.gr-meter { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; margin-top: 2px; }
.gr-meter i { height: 6px; border-radius: 6px; background: var(--surface-3); transition: background-color .25s ease, transform .25s var(--gr-ease); transform-origin: left; }
.gr-meter[data-guc="1"] i:nth-child(-n+1) { background: var(--bad); }
.gr-meter[data-guc="2"] i:nth-child(-n+2) { background: var(--warn); }
.gr-meter[data-guc="3"] i:nth-child(-n+3) { background: color-mix(in srgb, var(--ok) 70%, var(--warn)); }
.gr-meter[data-guc="4"] i { background: var(--ok); }
.gr-meter-t { margin: 0; font-size: .82rem; color: var(--text-muted); font-weight: 600; min-height: 1.3em; }

/* Onaylar */
.gr-consent { border: 0; margin: 0; padding: var(--sp-4); display: grid; gap: var(--sp-2); border-radius: 16px; background: var(--surface-2); border: 1px solid var(--border); min-width: 0; }
.gr-check { display: flex; gap: 12px; align-items: flex-start; font-size: .92rem; line-height: 1.45; cursor: pointer; min-height: 32px; }
.gr-check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--accent); flex-shrink: 0; cursor: pointer; }
.gr-check a { font-weight: 700; }
.gr-check small { color: var(--text-muted); }
.gr-consent .field-error { margin: -4px 0 4px 32px; }

/* Geçiş animasyonları */
@media (prefers-reduced-motion: no-preference) {
  .gr-panel.is-enter, .gr-view.is-enter { animation: gr-in .38s var(--gr-ease); }
  .gr-shell { animation: gr-rise .6s var(--gr-ease) both; }
}
@keyframes gr-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes gr-rise { from { opacity: 0; transform: translateY(16px) scale(.99); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .gr-tabs::before, .gr-meter i, .gr-submit { transition: none; } }

/* --- Görsel panel ------------------------------------------------------- */
.gr-visual {
  position: relative; overflow: hidden; isolation: isolate; min-width: 0; display: flex; flex-direction: column; gap: var(--sp-6); justify-content: center;
  padding: clamp(28px, 4vw, 56px); color: #fff; background: linear-gradient(140deg, var(--hero-a), #6a3cf0 50%, var(--hero-b));
}
.gr-mesh { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.gr-mesh span { position: absolute; border-radius: 50%; }
.gr-mesh span:nth-child(1) { width: 70%; aspect-ratio: 1; right: -25%; top: -25%; background: radial-gradient(circle, color-mix(in srgb, var(--energy) 70%, transparent), transparent 62%); }
.gr-mesh span:nth-child(2) { width: 65%; aspect-ratio: 1; left: -25%; bottom: -30%; background: radial-gradient(circle, rgba(56, 189, 248, .42), transparent 62%); }
.gr-mesh span:nth-child(3) { width: 40%; aspect-ratio: 1; left: 35%; top: 40%; background: radial-gradient(circle, rgba(236, 72, 153, .3), transparent 65%); }
@media (prefers-reduced-motion: no-preference) {
  .gr-mesh span:nth-child(1) { animation: gr-f1 13s ease-in-out infinite alternate; }
  .gr-mesh span:nth-child(2) { animation: gr-f2 16s ease-in-out infinite alternate; }
  .gr-mesh span:nth-child(3) { animation: gr-f1 10s ease-in-out infinite alternate-reverse; }
  .gr-points li { animation: gr-in .6s var(--gr-ease) both; }
  .gr-points li:nth-child(2) { animation-delay: .12s; } .gr-points li:nth-child(3) { animation-delay: .24s; }
}
@keyframes gr-f1 { to { transform: translate(-14%, 12%) scale(1.12); } }
@keyframes gr-f2 { to { transform: translate(14%, -12%) scale(1.15); } }
.gr-eyebrow { margin: 0; align-self: flex-start; display: inline-flex; padding: 6px 14px; border-radius: 999px; background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .25); font-weight: 700; font-size: var(--fs-14); }
.gr-visual-h { margin: 0; font: 900 clamp(1.5rem, 1.1rem + 1.6vw, 2.25rem)/1.12 var(--font-head); letter-spacing: -.01em; text-wrap: balance; }
.gr-points { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-3); }
.gr-points li { display: flex; gap: var(--sp-3); align-items: center; padding: 12px 14px; border-radius: 16px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .18); }
.gr-points strong { display: block; font-family: var(--font-head); font-weight: 800; }
.gr-points span:not(.gr-ico) { display: block; color: rgba(255, 255, 255, .88); font-size: var(--fs-14); line-height: 1.4; }
.gr-ico { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: rgba(255, 255, 255, .95); color: var(--brand-600); }
.gr-ico svg { width: 20px; height: 20px; }
.gr-open { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); min-height: 56px; padding: 10px 16px; border-radius: 16px; background: #fff; color: #1a1033; text-decoration: none; transition: transform .2s var(--gr-ease); }
.gr-open:hover { transform: translateY(-2px); color: #1a1033; text-decoration: none; }
.gr-open:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.gr-open strong { display: block; font-family: var(--font-head); font-weight: 800; }
.gr-open small { color: #5e5873; font-weight: 600; }
.gr-open svg { width: 20px; height: 20px; flex: none; color: #5b3df5; }

/* --- Şifre sıfırlama (sifre-sifirla.html) ------------------------------ */
.gr-shell.is-narrow { grid-template-columns: minmax(0, 1fr); max-width: 480px; margin-inline: auto; }

/* --- Duyarlı ------------------------------------------------------------ */
@media (max-width: 900px) {
  .gr-shell { grid-template-columns: minmax(0, 1fr); max-width: 560px; margin-inline: auto; }
  .gr-shell > .gr-visual { order: 0; gap: var(--sp-4); }
  .gr-visual-h { font-size: 1.35rem; }
}
@media (max-width: 420px) {
  .gr-main { padding-inline: 12px; }
  .gr-shell { border-radius: 22px; }
  .gr-form .field-row { grid-template-columns: minmax(0, 1fr); }
}

/* 1.9.0 Şifre sıfırlama: geçersiz bağlantıda yalnız uyarı + tek eylem */
.gr-form.is-gecersiz .field, .gr-form.is-gecersiz .gr-submit { display: none; }
