/* === GRID SAYFASI === */
.santiye-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
}

.santiye-kart {
  width: 100%;
  max-width: 300px;
  border: 1px solid #ddd;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  padding: 10px;
  box-sizing: border-box;
  text-align: center;
  background: #fff;
  border-radius: 6px;
  transition: transform 0.2s ease;
}

.santiye-kart:hover {
  transform: scale(1.02);
}

.santiye-kart h3 {
  margin: 10px 0 5px;
  font-size: 18px;
}

.santiye-kart p {
  font-size: 14px;
  color: #555;
}

.santiye-kart a {
  text-decoration: none;
  color: inherit;
}

.santiye-kart .resimler {
  display: flex;
  gap: 5px;
  justify-content: center;
}

.santiye-kart .resim,
.santiye-kart .resim-full {
  flex: 1;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 6px;
}

.santiye-kart img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 6px;
}

/* === DETAY SAYFASI === */
.santiye-detay {
  max-width: 1000px;
  margin: 0 auto;
  padding: 20px;
  font-family: 'Segoe UI', sans-serif;
}

.santiye-detay h2 {
  font-size: 2em;
  margin-bottom: 15px;
  text-align: center;
}

.aciklama {
  background-color: #f9f9f9;
  padding: 15px;
  border-radius: 6px;
  margin-bottom: 30px;
}

.on-son {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  margin-bottom: 40px;
}

.on-son .resim {
  position: relative;
  flex: 1 1 45%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 6px;
}

.on-son img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 6px;
}

.etiket {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(0,0,0,0.6);
  color: white;
  padding: 4px 8px;
  font-size: 14px;
  border-radius: 4px;
  font-weight: bold;
  z-index: 2;
}

/* === GALERİ === */
.galeri {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 15px;
}

.galeri a {
  display: block;
}

.galeri img {
  width: 100%;
  border-radius: 6px;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 5px rgba(0,0,0,0.1);
}

.galeri img:hover {
  transform: scale(1.05);
  cursor: zoom-in;
}

/* === GERİ DÖN BUTONU === */
.btn-retour {
  display: inline-block;
  margin-top: 40px;
  padding: 10px 20px;
  background-color: #1e1e1e;
  color: #fff;
  border-radius: 6px;
  text-decoration: none;
  transition: background 0.3s;
}

.btn-retour:hover {
  background-color: #e5221c;
}

/* === PANEL GÖRÜNÜMÜ === */
.santiye-panel-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: flex-start;
}

.santiye-panel-form, .santiye-panel-list {
  flex: 1 1 100%;
  background: #fff;
  border: 1px solid #e2e2e2;
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.04);
}

.santiye-panel-form h2, .santiye-panel-list h2 {
  font-size: 22px;
  margin-bottom: 20px;
  color: #222;
}

.santiye-panel-form label {
  font-weight: 600;
  display: block;
  margin-bottom: 5px;
  color: #333;
}

.santiye-panel-form input[type="text"],
.santiye-panel-form textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 14px;
  margin-bottom: 20px;
}

.santiye-panel-form img {
  margin-bottom: 10px;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.santiye-panel-form button {
  background: #1e1e1e;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  font-size: 15px;
  cursor: pointer;
  margin-bottom: 20px;
}

.santiye-panel-form button:hover {
  background: #e5221c;
}

#galerie_preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 12px;
  margin-top: 10px;
  margin-bottom: 20px;
}

#galerie_preview img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  display: block;
}

/* === BUTONLARI RENKLİLEŞTİRME (Sil / Düzenle) === */
.santiye-panel-list table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.santiye-panel-list th, .santiye-panel-list td {
  padding: 12px;
  border-bottom: 1px solid #eee;
  text-align: left;
}

.santiye-panel-list th {
  background: #f8f8f8;
  font-weight: 600;
}

.santiye-panel-list a {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 6px;
  font-weight: 500;
  font-size: 14px;
  color: #fff;
  text-decoration: none;
  margin-right: 10px;
}

.santiye-panel-list a[href*="edit"] {
  background-color: #0073aa;
}

.santiye-panel-list a[href*="edit"]:hover {
  background-color: #005e8a;
}

.santiye-panel-list a[href*="supprimer"] {
  background-color: #d63638;
}

.santiye-panel-list a[href*="supprimer"]:hover {
  background-color: #a80000;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .on-son {
    flex-direction: column;
  }

  .on-son .resim {
    flex: 1 1 100%;
  }

  .santiye-kart {
    max-width: 100%;
  }

  .santiye-panel-form, .santiye-panel-list {
    flex: 1 1 100% !important;
  }
}