/* =============================================
   CGTPerformance — ortak tasarım sistemi
   CGTDebate Hub teması: logodan türetilen lacivert ve mavi, milimetrik ızgara, keskin köşeler.
   Fontlar fonts/fonts.css ile sunucudan yüklenir (Space Grotesk, JetBrains Mono).
   ============================================= */

:root {
  --bg:          #051230;
  --bg2:         #071a3d;
  --bg3:         #0a2350;
  --panel:       #071a3d;
  --surface:     rgba(76,178,255,0.04);
  --border:      #17305f;
  --border-2:    #23447e;
  --text:        #eef6ff;
  --muted:       #a9bfe0;
  --text-muted:  #7d93b8;
  --accent:      #2f80ff;
  --accent-2:    #4cb2ff;
  --blue:        #2f80ff;
  --purple:      #1f6fe8;   /* eski adıyla birincil buton rengi (beyaz yazıyla 4.7:1) */
  --deep-purple: #1f63d6;
  --cyan:        #4cb2ff;
  --success:     #3ddc97;
  --error:       #ff7a7a;
  --warning:     #ffc861;
  --font:        'Space Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono:        'JetBrains Mono', ui-monospace, Consolas, monospace;
  --nav-h:       68px;
}

/* ── Reset & Base ───────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background-color: var(--bg);
  background-image:
    linear-gradient(rgba(76,178,255,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(76,178,255,0.06) 1px, transparent 1px),
    linear-gradient(rgba(76,178,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(76,178,255,0.025) 1px, transparent 1px);
  background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px;
  background-attachment: fixed;
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
code { font-family: var(--mono); }
::selection { background: rgba(47,128,255,0.45); color: #fff; }
:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }

/* Eski sayfalardaki parlayan küreler bu temada kullanılmıyor */
.orb { display: none; }

/* ── Navigation ──────────────────────────────── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 100;
  display: flex;
  align-items: center;
  padding: 0 40px;
  background: rgba(5,18,48,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  flex: 1;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}
.logo-icon {
  width: 44px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.logo-icon img { width: 100%; height: auto; display: block; }
.logo-text span { color: var(--accent-2); }

.nav-links {
  flex: 2;
  display: flex;
  justify-content: center;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 500;
  transition: color 0.2s;
  font-family: var(--mono);
}
.nav-links a:hover { color: var(--text); }

.nav-cta-container {
  flex: 1;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
}
.nav-cta, .btn-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  background: var(--purple);
  border: 1px solid var(--purple);
  border-radius: 3px;
  color: #fff;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.nav-cta:hover, .btn-nav:hover { background: var(--deep-purple); border-color: var(--deep-purple); }
.btn-nav-ghost {
  background: transparent;
  border: 1px solid var(--border-2);
  color: var(--muted);
}
.btn-nav-ghost:hover {
  background: rgba(47,128,255,0.08);
  border-color: var(--accent);
  color: var(--text);
}

/* ── Animations ─────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.3} }
@keyframes spin   { to { transform: rotate(360deg); } }
@keyframes blink  { 0%,100%{opacity:1} 50%{opacity:0} }

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ── Auth Card Layout ────────────────────────── */
.auth-page {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--nav-h) + 40px) 16px 40px;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--panel);
  border: 1px solid var(--border-2);
  border-radius: 4px;
  padding: 40px 36px;
  position: relative;
}
/* Köşe işaretleri (Hub kartlarındaki gibi) */
.auth-card::before,
.auth-card::after {
  content: "";
  position: absolute;
  width: 12px; height: 12px;
  border: 2px solid var(--accent-2);
  pointer-events: none;
}
.auth-card::before { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
.auth-card::after { bottom: -1px; right: -1px; border-left: 0; border-top: 0; }

.auth-icon {
  width: 52px; height: 52px;
  border-radius: 3px;
  background: rgba(47,128,255,0.12);
  border: 1px solid var(--border-2);
  display: flex; align-items: center; justify-content: center;
  font-size: 24px;
  margin-bottom: 20px;
}

.auth-title {
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}
.auth-subtitle {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 28px;
}
.auth-subtitle a { color: var(--accent-2); font-weight: 600; }
.auth-subtitle a:hover { text-decoration: underline; }

/* ── Form Elements ───────────────────────────── */
.form-group { margin-bottom: 18px; }

.form-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
  font-family: var(--mono);
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  background: rgba(5,18,48,0.7);
  border: 1px solid var(--border-2);
  border-radius: 3px;
  color: var(--text);
  font-family: var(--font);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-input::placeholder { color: var(--text-muted); }
.form-input:focus {
  border-color: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(76,178,255,0.15);
}
.form-input.error {
  border-color: var(--error);
  box-shadow: 0 0 0 3px rgba(255,122,122,0.15);
}

.input-wrapper { position: relative; }
.input-icon {
  position: absolute;
  left: 14px; top: 50%;
  transform: translateY(-50%);
  font-size: 15px;
  pointer-events: none;
}
.input-wrapper .form-input { padding-right: 44px; }
.input-toggle {
  position: absolute;
  right: 8px; top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  color: var(--muted); cursor: pointer;
  font-family: var(--mono);
  font-size: 0.7rem;
  padding: 6px;
}
.input-toggle:hover { color: var(--text); }

.field-hint  { font-size: 0.78rem; color: var(--text-muted); margin-top: 6px; }
.field-error { font-size: 0.78rem; color: var(--error); margin-top: 6px; display: none; }
.field-error.show { display: block; }

/* ── Password Strength ───────────────────────── */
.pwd-strength { margin-top: 8px; }
.pwd-bars { display: flex; gap: 4px; margin-bottom: 4px; }
.pwd-bar  { height: 3px; flex: 1; border-radius: 1px; background: var(--border); transition: background 0.3s; }
.pwd-bar.weak   { background: var(--error); }
.pwd-bar.medium { background: var(--warning); }
.pwd-bar.strong { background: var(--success); }
.pwd-label { font-size: 0.72rem; color: var(--text-muted); font-family: var(--mono); }
.pwd-label.weak   { color: var(--error); }
.pwd-label.medium { color: var(--warning); }
.pwd-label.strong { color: var(--success); }

/* ── Submit Button ───────────────────────────── */
.btn-submit {
  width: 100%;
  padding: 13px;
  background: var(--purple);
  border: 1px solid var(--purple);
  border-radius: 3px;
  color: #fff;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 0.2s, opacity 0.2s;
  margin-top: 8px;
  position: relative;
}
.btn-submit:hover:not(:disabled) { background: var(--deep-purple); }
.btn-submit:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-submit .btn-spinner {
  display: none;
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  margin: 0 auto;
}
.btn-submit.loading .btn-text { display: none; }
.btn-submit.loading .btn-spinner { display: block; }

/* ── Divider ─────────────────────────────────── */
.auth-divider {
  display: flex; align-items: center; gap: 12px;
  margin: 22px 0;
  color: var(--text-muted);
  font-size: 0.75rem;
  font-family: var(--mono);
}
.auth-divider::before, .auth-divider::after {
  content: ""; flex: 1; height: 1px; background: var(--border);
}

/* ── Alert ───────────────────────────────────── */
.alert {
  padding: 12px 14px;
  border-radius: 3px;
  font-size: 0.86rem;
  line-height: 1.5;
  margin-bottom: 20px;
  display: flex; align-items: flex-start; gap: 10px;
  animation: fadeUp 0.25s ease;
}
.alert-error   { background: rgba(255,122,122,0.08); border: 1px solid rgba(255,122,122,0.4); color: #ffb3b3; }
.alert-success { background: rgba(61,220,151,0.08);  border: 1px solid rgba(61,220,151,0.4);  color: #9ff0c9; }
.alert-info    { background: rgba(47,128,255,0.1);   border: 1px solid rgba(76,178,255,0.4);  color: #c3d6f2; }
.alert-warning { background: rgba(255,200,97,0.08);  border: 1px solid rgba(255,200,97,0.4);  color: #ffe0a3; }

/* ── Checkbox ────────────────────────────────── */
.check-group { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 14px; }
.check-group input[type="checkbox"] { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--accent); flex-shrink: 0; cursor: pointer; }
.check-label { font-size: 0.84rem; color: var(--muted); line-height: 1.55; }
.check-label a { color: var(--accent-2); text-decoration: underline; text-underline-offset: 2px; }

/* ── Utility ─────────────────────────────────── */
.text-center { text-align: center; }
.mt-4 { margin-top: 16px; }

/* ── Plan rozetleri ───────────────────────────── */
.plan-badge-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 2px;
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: var(--mono);
  z-index: 1;
}
.plan-badge-pill.basic   { background: rgba(169,191,224,0.08); color: var(--muted); border: 1px solid var(--border-2); }
.plan-badge-pill.pro     { background: rgba(47,128,255,0.14); color: #8fd0ff; border: 1px solid rgba(76,178,255,0.45); }
.plan-badge-pill.premium { background: rgba(255,200,97,0.1); color: var(--warning); border: 1px solid rgba(255,200,97,0.45); }
.plan-badge-pill.max     { background: rgba(238,246,255,0.1); color: #fff; border: 1px solid var(--accent-2); box-shadow: 0 0 0 1px rgba(76,178,255,0.25), 0 0 14px rgba(76,178,255,0.25); }

/* ── Yasal bağlantılar / site altı ─────────────── */
.legal-footer {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 18px;
  padding: 20px 16px 28px;
  font-size: 0.78rem;
  font-family: var(--mono);
  color: var(--text-muted);
}
.legal-footer a { color: var(--muted); }
.legal-footer a:hover { color: var(--text); text-decoration: underline; }

/* ── Responsive ──────────────────────────────── */
@media (max-width: 768px) {
  nav { padding: 0 20px; }
  .nav-links { display: none; }
}

@media (max-width: 600px) {
  .auth-card { padding: 30px 20px; }
}

@media (max-width: 480px) {
  :root { --nav-h: 60px; }
  nav { padding: 0 16px; }
  .logo-text span { display: none; }
  .btn-nav { padding: 7px 12px; font-size: 0.78rem; }
  .auth-page { padding: calc(var(--nav-h) + 20px) 16px 32px; }
  .auth-title { font-size: 1.45rem; }
  .auth-subtitle { font-size: 0.85rem; margin-bottom: 22px; }
  .form-input { font-size: 16px; padding: 11px 12px; } /* iOS odaklanma yakınlaştırmasını engeller */
}
