/* ============================================================
   ADMIN.CSS
   Odium Stüdyo — Admin Panel Stilleri
   
   Bu dosya sadece admin panel bileşenlerini stillendirir.
   Site tasarımını etkilemez.
   ============================================================ */


/* ==========================================================
   OVERLAY — Login ve Panel arkaplanı
   ========================================================== */

.adm-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  overflow-y: auto;
}

.adm-overlay[hidden] {
  display: none !important;
}


/* ==========================================================
   LOGIN MODAL
   ========================================================== */

.adm-login {
  position: relative;
  width: 100%;
  max-width: 400px;
  background: #141514;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 40px 32px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
}

.adm-login__header {
  text-align: center;
  margin-bottom: 32px;
}

.adm-login__logo {
  border-radius: 8px;
  margin-bottom: 16px;
}

.adm-login__title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}

.adm-login__hint {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #606060;
  letter-spacing: 0.03em;
}

.adm-login__form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.adm-login__error {
  background: rgba(220, 60, 60, 0.12);
  border: 1px solid rgba(220, 60, 60, 0.25);
  color: #e06060;
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 8px;
  text-align: center;
}

.adm-login__error[hidden] {
  display: none;
}

.adm-login__btn {
  width: 100%;
  padding: 14px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: #0F100F;
  background: linear-gradient(135deg, #FFFFFF 0%, #D4D4D4 50%, #C0C0C0 100%);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.25s ease;
  margin-top: 4px;
}

.adm-login__btn:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(255, 255, 255, 0.1);
}

.adm-login__btn:active {
  transform: translateY(0);
  filter: brightness(0.95);
}

.adm-login__btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  filter: none;
}

.adm-login__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #606060;
  background: none;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.2s, background 0.2s;
}

.adm-login__close:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}


/* ==========================================================
   FORM ALANLARI — Genel
   ========================================================== */

.adm-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.adm-field__label {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: #A0A0A0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.adm-field__help {
  font-size: 11px;
  color: #606060;
  margin-bottom: 4px;
  line-height: 1.4;
}

.adm-field__input {
  width: 100%;
  padding: 12px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #fff;
  background: #0F100F;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  outline: none;
  transition: border-color 0.2s;
}

.adm-field__input:focus {
  border-color: rgba(255, 255, 255, 0.25);
}

.adm-field__input::placeholder {
  color: #404040;
}

.adm-field__textarea {
  width: 100%;
  padding: 12px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #fff;
  background: #0F100F;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  outline: none;
  resize: vertical;
  min-height: 80px;
  transition: border-color 0.2s;
  line-height: 1.5;
}

.adm-field__textarea:focus {
  border-color: rgba(255, 255, 255, 0.25);
}

.adm-field__textarea::placeholder {
  color: #404040;
}

.adm-field__select {
  width: 100%;
  padding: 10px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #fff;
  background: #0F100F;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  outline: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23606060' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.adm-field__select:focus {
  border-color: rgba(255, 255, 255, 0.25);
}

/* Küçük input — satır içi kullanım */
.adm-field__input--sm {
  padding: 8px 10px;
  font-size: 13px;
}

/* İnline field grubu */
.adm-field-row {
  display: flex;
  gap: 12px;
  align-items: flex-end;
}

.adm-field-row .adm-field {
  flex: 1;
}


/* ==========================================================
   ADMIN PANEL MODAL
   ========================================================== */

.adm-panel {
  width: 100%;
  max-width: 900px;
  max-height: 90vh;
  background: #141514;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
}


/* ==========================================================
   PANEL ÜST BAR
   ========================================================== */

.adm-panel__topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
  gap: 16px;
}

.adm-panel__topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.adm-panel__topbar-left img {
  border-radius: 6px;
}

.adm-panel__topbar-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
}

.adm-panel__topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.adm-panel__status {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #606060;
  white-space: nowrap;
}

.adm-panel__status--saving {
  color: #9B978A;
}

.adm-panel__status--saved {
  color: #8A9B8A;
}

.adm-panel__status--error {
  color: #e06060;
}

.adm-panel__publish-btn {
  padding: 8px 20px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #0F100F;
  background: linear-gradient(135deg, #FFFFFF 0%, #D4D4D4 50%, #C0C0C0 100%);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.adm-panel__publish-btn:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
}

.adm-panel__publish-btn:active {
  transform: translateY(0);
  filter: brightness(0.95);
}

.adm-panel__publish-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.adm-panel__logout-btn {
  padding: 8px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: #A0A0A0;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.adm-panel__logout-btn:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.04);
}

.adm-panel__close-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: #606060;
  background: none;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.2s, background 0.2s;
}

.adm-panel__close-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}


/* ==========================================================
   SEKMELER
   ========================================================== */

.adm-panel__tabs {
  display: flex;
  padding: 0 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.adm-tab {
  padding: 14px 20px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: #606060;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  white-space: nowrap;
}

.adm-tab:hover {
  color: #A0A0A0;
}

.adm-tab.active {
  color: #fff;
  border-bottom-color: #fff;
}


/* ==========================================================
   SEKME İÇERİKLERİ
   ========================================================== */

.adm-panel__body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}

.adm-tab-content {
  display: none;
}

.adm-tab-content.active {
  display: block;
}


/* ==========================================================
   BÖLÜM BAŞLIKLARI
   ========================================================== */

.adm-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 16px;
}

.adm-section-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 0;
}

/* Bölüm başlığı section-header olmadan kullanılırsa */
.adm-tab-content > .adm-section-title {
  margin-bottom: 20px;
}


/* ==========================================================
   EKLE BUTONU
   ========================================================== */

.adm-add-btn {
  padding: 8px 16px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 500;
  color: #8A9B8A;
  background: rgba(138, 155, 138, 0.08);
  border: 1px solid rgba(138, 155, 138, 0.2);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.adm-add-btn:hover {
  color: #fff;
  background: rgba(138, 155, 138, 0.15);
  border-color: rgba(138, 155, 138, 0.35);
}


/* ==========================================================
   ITEM LİSTESİ — Düzenlenebilir kartlar
   ========================================================== */

.adm-items-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}


/* ==========================================================
   ITEM KARTI — Tek bir düzenlenebilir öğe
   ========================================================== */

.adm-item {
  background: #1A1B1A;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.2s;
}

.adm-item:hover {
  border-color: rgba(255, 255, 255, 0.1);
}

/* Kart başlığı — tıklanabilir, aç/kapat */
.adm-item__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  cursor: pointer;
  user-select: none;
  gap: 12px;
}

.adm-item__header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.adm-item__drag {
  color: #404040;
  cursor: grab;
  flex-shrink: 0;
  font-size: 16px;
  line-height: 1;
}

.adm-item__title {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.adm-item__header-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.adm-item__toggle {
  color: #606060;
  font-size: 14px;
  transition: transform 0.2s, color 0.2s;
}

.adm-item.is-open .adm-item__toggle {
  transform: rotate(180deg);
  color: #A0A0A0;
}

/* Silme butonu */
.adm-item__delete {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #606060;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: color 0.2s, background 0.2s;
}

.adm-item__delete:hover {
  color: #e06060;
  background: rgba(220, 60, 60, 0.1);
}

/* Kart gövdesi — düzenleme alanları */
.adm-item__body {
  display: none;
  padding: 0 18px 18px;
}

.adm-item.is-open .adm-item__body {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Ayırıcı çizgi */
.adm-item__body::before {
  content: '';
  display: block;
  height: 1px;
  background: rgba(255, 255, 255, 0.04);
  margin-bottom: 4px;
}


/* ==========================================================
   PROJE BUTONLARI — Alt liste
   ========================================================== */

.adm-buttons-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.adm-button-item {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  padding: 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 8px;
}

.adm-button-item .adm-field {
  flex: 1;
}

.adm-button-item__remove {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #606060;
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  cursor: pointer;
  flex-shrink: 0;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.adm-button-item__remove:hover {
  color: #e06060;
  border-color: rgba(220, 60, 60, 0.2);
  background: rgba(220, 60, 60, 0.06);
}

.adm-add-sub-btn {
  padding: 6px 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #606060;
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  align-self: flex-start;
}

.adm-add-sub-btn:hover {
  color: #A0A0A0;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
}


/* ==========================================================
   EKİP SOSYAL MEDYA — Alt liste
   ========================================================== */

.adm-socials-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.adm-social-item {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}

.adm-social-item .adm-field {
  flex: 1;
}

.adm-social-item__remove {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #606060;
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  cursor: pointer;
  flex-shrink: 0;
  transition: color 0.2s, background 0.2s;
}

.adm-social-item__remove:hover {
  color: #e06060;
  background: rgba(220, 60, 60, 0.06);
}


/* ==========================================================
   ROLLER TAG INPUT — Virgülle ayrılmış
   ========================================================== */

.adm-field__help--inline {
  font-size: 10px;
  color: #505050;
  margin-top: 2px;
}


/* ==========================================================
   TOAST / BİLDİRİM (basit)
   ========================================================== */

.adm-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 10000;
  padding: 14px 24px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  background: #1A1B1A;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  animation: admToastIn 0.3s ease forwards;
  pointer-events: none;
}

.adm-toast--success {
  border-color: rgba(138, 155, 138, 0.3);
}

.adm-toast--error {
  border-color: rgba(220, 60, 60, 0.3);
}

.adm-toast--out {
  animation: admToastOut 0.3s ease forwards;
}

@keyframes admToastIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes admToastOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(20px);
  }
}


/* ==========================================================
   RESPONSIVE — Mobil admin panel
   ========================================================== */

@media (max-width: 639px) {
  .adm-overlay {
    padding: 0;
    align-items: stretch;
  }

  .adm-login {
    max-width: none;
    border-radius: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .adm-panel {
    max-width: none;
    max-height: none;
    height: 100vh;
    border-radius: 0;
  }

  .adm-panel__topbar {
    padding: 12px 16px;
    flex-wrap: wrap;
  }

  .adm-panel__topbar-right {
    flex-wrap: wrap;
    gap: 8px;
  }

  .adm-panel__tabs {
    padding: 0 16px;
  }

  .adm-tab {
    padding: 12px 14px;
    font-size: 12px;
  }

  .adm-panel__body {
    padding: 16px;
  }

  .adm-item__header {
    padding: 12px 14px;
  }

  .adm-item__body {
    padding: 0 14px 14px;
  }

  .adm-field-row {
    flex-direction: column;
  }

  .adm-button-item {
    flex-direction: column;
    align-items: stretch;
  }

  .adm-button-item__remove {
    align-self: flex-end;
  }

  .adm-section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
}

@media (max-width: 379px) {
  .adm-panel__topbar-title {
    font-size: 14px;
  }

  .adm-panel__publish-btn {
    padding: 7px 14px;
    font-size: 12px;
  }
}


/* ==========================================================
   SCROLLBAR — Admin panel içi
   ========================================================== */

.adm-panel__body::-webkit-scrollbar {
  width: 6px;
}

.adm-panel__body::-webkit-scrollbar-track {
  background: transparent;
}

.adm-panel__body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
}

.adm-panel__body::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.15);
}