/* =====================================================================
   CareerVision — ORTAK TASARIM SİSTEMİ  (css/app-theme.css)
   ---------------------------------------------------------------------
   Sitedeki tüm ekranların aynı renk, yazı ölçeği, köşe yarıçapı, gölge ve
   düğme diliyle konuşmasını sağlar. Sayfaların kendi <style> blokları bu
   dosyadan SONRA yüklendiği için, kuralları `body[class]` üzerinden
   yazarak özgüllüğü bir adım yukarı taşıyoruz.

   KARANLIK MOD KALDIRILDI — site tek bir açık temada çalışır.
   ===================================================================== */

:root {
  /* Marka */
  --cv-navy:      #33455c;
  --cv-navy-700:  #2a3a4e;
  --cv-blue:      #4c5f7f;
  --cv-blue-600:  #3d4d68;
  --cv-blue-100:  #eef4fb;
  --cv-orange:    #f3711d;
  --cv-orange-600:#d95f11;
  --cv-teal:      #0f8b8d;

  /* Yüzeyler */
  --cv-bg:        #eef3f9;
  --cv-surface:   #ffffff;
  --cv-surface-2: #f7fafd;
  --cv-line:      #dde5ef;
  --cv-line-2:    #eaf0f7;

  /* Metin */
  --cv-text:      #22303f;
  --cv-text-soft: #5b6878;
  --cv-text-mute: #8592a6;

  /* Durum */
  --cv-ok:        #137a3b;
  --cv-ok-bg:     #e7f6ec;
  --cv-warn:      #8a5a12;
  --cv-warn-bg:   #fff4e0;
  --cv-err:       #a12020;
  --cv-err-bg:    #ffe6e6;

  /* Biçim */
  --cv-r-sm: 8px;
  --cv-r:    11px;
  --cv-r-lg: 16px;
  --cv-shadow-1: 0 1px 2px rgba(20, 32, 48, .06), 0 2px 8px rgba(20, 32, 48, .05);
  --cv-shadow-2: 0 10px 30px rgba(20, 32, 48, .10);
  --cv-shadow-3: 0 22px 56px rgba(20, 32, 48, .16);
  --cv-ring: 0 0 0 3px rgba(76, 95, 127, .20);

  --cv-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Karanlık mod artık yok: kalan data-theme kuralları etkisiz kalsın */
html[data-theme="dark"] { color-scheme: light; }

/* ---------------------------------------------------------------------
   1) TİPOGRAFİ ve TEMEL
   --------------------------------------------------------------------- */
body[class] {
  font-family: var(--cv-font);
  color: var(--cv-text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.dashboard-page,
body.manage-page,
body.account-page,
body.create-cv-page,
body.profile-page,
body.admin-page,
body.danger-page,
body.legacy-page,
body.popup-page {
  background-color: var(--cv-bg);
}

body[class] h1 { font-size: 21px; line-height: 1.25; letter-spacing: -.01em; }
body[class] h2 { font-size: 17px; line-height: 1.3; }
body[class] h3 { font-size: 15px; line-height: 1.35; }
body[class] h1, body[class] h2, body[class] h3 { color: var(--cv-navy); font-weight: 700; }

body[class] a { color: var(--cv-blue); }

body[class] ::selection { background: rgba(76, 95, 127, .18); }

/* Odak halkası — klavye kullanıcıları için tutarlı */
body[class] :focus-visible {
  outline: none;
  box-shadow: var(--cv-ring);
  border-radius: var(--cv-r-sm);
}

/* İnce, tutarlı kaydırma çubuğu */
body[class] * { scrollbar-width: thin; scrollbar-color: #c3cedd transparent; }
body[class] ::-webkit-scrollbar { width: 10px; height: 10px; }
body[class] ::-webkit-scrollbar-thumb { background: #c9d4e2; border-radius: 99px; border: 3px solid transparent; background-clip: content-box; }
body[class] ::-webkit-scrollbar-thumb:hover { background: #adbccf; background-clip: content-box; }
body[class] ::-webkit-scrollbar-track { background: transparent; }

/* ---------------------------------------------------------------------
   2) DÜĞMELER — tek dil
   --------------------------------------------------------------------- */
body[class] .btn,
body[class] button.btn,
body[class] a.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: var(--cv-r-sm);
  background: var(--cv-blue);
  color: #fff;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .16s ease, box-shadow .16s ease, transform .06s ease;
}

body[class] .btn:hover { background: var(--cv-blue-600); }
body[class] .btn:active { transform: translateY(1px); }
body[class] .btn[disabled],
body[class] .btn:disabled { opacity: .5; cursor: not-allowed; }

body[class] .btn.primary   { background: var(--cv-orange); }
body[class] .btn.primary:hover { background: var(--cv-orange-600); }
body[class] .btn.secondary { background: var(--cv-surface); color: var(--cv-blue); border-color: var(--cv-line); }
body[class] .btn.secondary:hover { background: var(--cv-blue-100); }
body[class] .btn.ghost     { background: transparent; color: var(--cv-text-soft); border-color: var(--cv-line); }
body[class] .btn.ghost:hover { background: var(--cv-surface-2); }
body[class] .btn.danger    { background: #c0392b; }
body[class] .btn.danger:hover { background: #a5301f; }

/* ---------------------------------------------------------------------
   3) FORM ALANLARI
   --------------------------------------------------------------------- */
body[class] input[type="text"],
body[class] input[type="password"],
body[class] input[type="email"],
body[class] input[type="search"],
body[class] input[type="number"],
body[class] input[type="date"],
body[class] input[type="url"],
body[class] input[type="tel"],
body[class] select,
body[class] textarea {
  font-family: inherit;
  font-size: 14.5px;
  color: var(--cv-text);
  background: var(--cv-surface);
  border: 1px solid var(--cv-line);
  border-radius: var(--cv-r-sm);
  padding: 10px 12px;
  box-sizing: border-box;
  transition: border-color .16s ease, box-shadow .16s ease;
}

body[class] input:focus,
body[class] select:focus,
body[class] textarea:focus {
  outline: none;
  border-color: var(--cv-blue);
  box-shadow: var(--cv-ring);
}

body[class] input::placeholder,
body[class] textarea::placeholder { color: #a9b4c4; }

body[class] label { font-size: 13px; color: var(--cv-text-soft); }

body[class] input[type="color"] {
  padding: 2px;
  height: 34px;
  border-radius: var(--cv-r-sm);
  border: 1px solid var(--cv-line);
  background: var(--cv-surface);
  cursor: pointer;
}

/* ---------------------------------------------------------------------
   4) KART ve PANELLER
   --------------------------------------------------------------------- */
body[class] .cv-card,
body[class] .card,
body[class] .panel,
body[class] .form-container,
body[class] .dash-workspace {
  background: var(--cv-surface);
  border-radius: var(--cv-r-lg);
  box-shadow: var(--cv-shadow-1);
}

body[class] .form-container { border: 1px solid var(--cv-line); }

/* Bilgi / uyarı şeritleri */
body[class] .cv-quota {
  margin: 0 0 14px;
  padding: 9px 12px;
  border-radius: var(--cv-r-sm);
  background: var(--cv-blue-100);
  color: var(--cv-navy);
  border: 1px solid #d8e4f2;
  font-size: 13.5px;
}
body[class] .cv-quota.is-full { background: var(--cv-warn-bg); color: var(--cv-warn); border-color: #f0d9b6; }

body[class] .error-message,
body[class] .error   { background: var(--cv-err-bg);  color: var(--cv-err);  border-radius: var(--cv-r-sm); padding: 10px 12px; font-size: 13.5px; border: 1px solid #f2c9c9; }
body[class] .success-message { background: var(--cv-ok-bg); color: var(--cv-ok); border-radius: var(--cv-r-sm); padding: 10px 12px; font-size: 13.5px; border: 1px solid #bde3c9; }

/* ---------------------------------------------------------------------
   5) ÜST ÇUBUK (manage_content) ve YAN MENÜ uyumu
   --------------------------------------------------------------------- */
body.manage-page .header-bar {
  background: var(--cv-navy);
  box-shadow: var(--cv-shadow-1);
}

body.manage-page .header-bar .btn {
  background: rgba(255, 255, 255, .13);
  border-color: rgba(255, 255, 255, .16);
  color: #fff;
}
body.manage-page .header-bar .btn:hover { background: rgba(255, 255, 255, .24); }

body[class] .app-sidebar { box-shadow: var(--cv-shadow-1); }

/* ---------------------------------------------------------------------
   6) DİL MENÜSÜ (i18n.php tarafından basılır)
   --------------------------------------------------------------------- */
body[class] .cv-settings-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 13px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: var(--cv-r-sm);
  background: rgba(255, 255, 255, .13);
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
}
body.dashboard-page .cv-settings-button {
  background: var(--cv-surface);
  color: var(--cv-navy);
  border-color: var(--cv-line);
  box-shadow: var(--cv-shadow-1);
}

body[class] .cv-settings-panel {
  border-radius: var(--cv-r);
  border: 1px solid var(--cv-line);
  box-shadow: var(--cv-shadow-2);
  background: var(--cv-surface);
  padding: 12px;
}

body[class] .cv-settings-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--cv-text-mute);
  font-weight: 700;
  margin-bottom: 8px;
}

body[class] .cv-lang-chip {
  border-radius: var(--cv-r-sm);
  border: 1px solid var(--cv-line);
  color: var(--cv-text-soft);
  font-weight: 600;
}
body[class] .cv-lang-chip.active { background: var(--cv-blue); color: #fff; border-color: transparent; }

body[class] .cv-settings-close {
  width: 100%;
  margin-top: 10px;
  padding: 8px;
  border: 0;
  border-top: 1px solid var(--cv-line-2);
  background: transparent;
  color: var(--cv-text-mute);
  font-size: 12.5px;
  cursor: pointer;
}

/* ---------------------------------------------------------------------
   7) TABLOLAR (yönetim paneli vb.)
   --------------------------------------------------------------------- */
body[class] table.data,
body.admin-page table {
  border-collapse: collapse;
  background: var(--cv-surface);
  font-size: 13px;
}
body.admin-page th {
  background: var(--cv-surface-2);
  color: var(--cv-text-mute);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: .04em;
  font-weight: 700;
}
body.admin-page th,
body.admin-page td { border: 1px solid var(--cv-line-2); }

/* ---------------------------------------------------------------------
   8) GİRİŞ / KAYIT sayfaları ortak zemin
   --------------------------------------------------------------------- */
body.auth-page {
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, .75), transparent 32%),
    linear-gradient(140deg, #c9dced 0%, #eef4f8 55%, #ffffff 100%);
}

/* ---------------------------------------------------------------------
   9) HAREKET AZALTMA TERCİHİ
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  body[class] *,
  body[class] *::before,
  body[class] *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
