/* Dosya : login.css */
/* Klasör: balik-stok-erp/assets/css/ */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-page: #e3e2e9;
  --bg-white: #ffffff;
  --border: #ececf0;
  --border-strong: #e2e2e8;
  --text-primary: #17171c;
  --text-secondary: #6f6f7a;
  --text-tertiary: #9a9aa5;
  --purple: #7c3aed;
  --purple-dark: #6d28d9;
  --red: #dc2626;
  --red-bg: #fdeaea;
  --radius: 14px;
  --font: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
}

body {
  font-family: var(--font);
  background: var(--bg-page);
  color: var(--text-primary);
  font-size: 13px;
}

/* ===== Sayfa düzeni: sol görsel + sağ form ===== */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.login-shell {
  display: flex;
  width: 100%;
  max-width: 1080px;
  min-height: 640px;
  background: var(--bg-white);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(20,20,40,.12);
}

/* ===== Sol: görsel slayt ===== */
.login-visual {
  position: relative;
  width: 42%;
  min-width: 320px;
  overflow: hidden;
  color: #fff;
}

.visual-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1.2s ease;
  background-size: cover;
  background-position: center;
}
.visual-slide.active { opacity: 1; }

/* NOT: url() yolları bu CSS dosyasının konumuna (assets/css/) göre hesaplanır.
   Bu yüzden assets/img/ klasörüne ulaşmak için ../img/ kullanılır. */
.slide-1 { background: url('../img/login-slide-1.jpg') center/cover no-repeat, linear-gradient(135deg, #4c3a6e, #7c3aed); }
.slide-2 { background: url('../img/login-slide-2.jpg') center/cover no-repeat, linear-gradient(135deg, #2e2a4d, #5b21b6); }
.slide-3 { background: url('../img/login-slide-3.jpg') center/cover no-repeat, linear-gradient(135deg, #6d28d9, #3730a3); }

.visual-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 28px 30px;
  background: linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,0) 30%, rgba(0,0,0,0) 55%, rgba(0,0,0,.55) 100%);
  z-index: 2;
}

.visual-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -.2px;
}
.logo-badge {
  width: 28px; height: 28px; border-radius: 8px;
  background: rgba(255,255,255,.18);
  display: flex; align-items: center; justify-content: center;
}
.logo-badge svg { width: 15px; height: 15px; }

.visual-quote p {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -.3px;
  margin-bottom: 14px;
}
.quote-name { font-weight: 700; font-size: 13.5px; }
.quote-role { font-size: 12px; opacity: .8; margin-top: 2px; }

/* ===== Sağ: form ===== */
.login-form-side {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.login-card {
  width: 100%;
  max-width: 380px;
}

.login-card h1 {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -.4px;
  text-align: center;
  margin-bottom: 6px;
}
.login-sub {
  color: var(--text-secondary);
  font-size: 13.5px;
  text-align: center;
  margin-bottom: 28px;
  line-height: 1.5;
}

.login-error {
  background: var(--red-bg);
  color: var(--red);
  font-size: 12.5px;
  font-weight: 600;
  padding: 10px 12px;
  border-radius: 8px;
  margin-bottom: 16px;
}

.field-box {
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  padding: 9px 14px 10px;
  margin-bottom: 14px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field-box:focus-within {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(124,58,237,.14);
}
.field-box label {
  display: block;
  font-size: 11px;
  color: var(--text-tertiary);
  margin-bottom: 2px;
}
.field-box input {
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  font-family: var(--font);
  font-size: 14px;
  color: var(--text-primary);
  padding: 0;
}

.forgot-row {
  margin-bottom: 14px;
}
.forgot-link {
  color: var(--purple);
  font-weight: 600;
  font-size: 13px;
  text-decoration: none;
}
.forgot-link:hover { text-decoration: underline; }

.remember-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}
.remember-label {
  color: var(--text-secondary);
  font-size: 13px;
}

.toggle { position: relative; display: inline-block; cursor: pointer; }
.toggle input { position: absolute; opacity: 0; width: 0; height: 0; }
.toggle-track {
  display: block;
  width: 38px; height: 22px;
  background: var(--border-strong);
  border-radius: 999px;
  position: relative;
  transition: background .2s ease;
}
.toggle-thumb {
  position: absolute;
  top: 2px; left: 2px;
  width: 18px; height: 18px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,.25);
  transition: transform .2s ease;
}
.toggle input:checked + .toggle-track { background: var(--purple); }
.toggle input:checked + .toggle-track .toggle-thumb { transform: translateX(16px); }

.login-btn {
  width: 100%;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  padding: 13px 16px;
  border: none;
  border-radius: 10px;
  background: var(--purple);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(124,58,237,.35);
}
.login-btn:hover { background: var(--purple-dark); }
.login-btn:disabled { opacity: .6; cursor: default; }

@media (max-width: 860px) {
  .login-shell { flex-direction: column; min-height: 0; }
  .login-visual { width: 100%; height: 220px; }
  .visual-quote p { font-size: 16px; }
}