/* Genel stil */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  background-color: #f4f4f4;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 20px;
}

/* Form Container */
.form-container {
  background-color: #fff;
  padding: 30px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  width: 100%;
  border-radius: 12px;
  text-align: left;
  border: 1px solid #ddd;
  margin: 0 20px;
}
.header-container {
  position: relative; /* İçindeki öğeleri konumlandırmak için gerekli */
  text-align: center; /* Başlığı ortalamak için */
  width: 100%;
}

.header-title {
  margin: 0;
  font-size: 24px;
  line-height: 1.8; /* Yüksekliği biraz artırır */
  padding: 10px 0; /* Üst ve alt boşluk ekler */
}

.header-logo {
  position: absolute;
  right: 20px; /* Sağ kenardan boşluk */
  top: 50%;
  transform: translateY(-50%); /* Logoyu dikey hizalama */
  height: 80px;
  opacity: 0.7;
  padding-right: 40px;
}

/* Başlık, etiket ve select alanları */
h1 {
  font-size: 28px;
  margin-bottom: 30px;
  font-weight: 600;
  color: #333;
}

label {
  font-size: 18px;
  margin-right: 10px;
  font-weight: 500;
  color: #555;
}
.custom-select {
  margin: 0;
}

select {
  width: 100%;
  padding: 12px;
  margin: 10px 0;
  font-size: 16px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background-color: #fafafa;
  transition: border 0.3s ease-in-out, background-color 0.3s ease-in-out;
}

select:hover,
select:focus {
  border-color: #007bff;
  background-color: #f0f8ff;
  outline: none;
}

/* Container düzenleri */
.container {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 20px;
}

/* Katman Listesi ve Metaveri düzeni */
#katmanList, 
#fileContent {
  width: 48%;
  padding: 15px;
  background-color: #f9f9f9;
  border-radius: 8px;
  box-sizing: border-box;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.3s ease-in-out;
}

#katmanList:hover,
#fileContent:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Başlıklar */
.katmanListHeader, 
.metaveriHeader {
  font-weight: bold;
  margin-bottom: 12px;
  font-size: 18px;
  color: #333;
}

/* Katman Listesi Öğeleri */
.katmanItem {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px;
  border: 1px solid #ddd;
  margin: 6px 0;
  border-radius: 6px;
  cursor: pointer;
  background-color: #fff;
  transition: background-color 0.3s ease-in-out;
}

.katmanItem:hover {
  background-color: #e9ecef;
}

/* Seçili katman stili */
.katmanItem.selected {
  background-color: #d1e7dd;
  border-color: #0f5132;
}

/* Gizli başlangıç divleri */
#themeSelectContainer,
#katmanList,
#fileContent,
#cartContainer {
  display: none;
}

/* Metaveri içeriği düzeni */
#fileContentText div {
  margin-bottom: 4px;
  white-space: pre-wrap;
  word-wrap: break-word;
  font-size: 14px;
  line-height: 1.2;
}

#fileContentText pre {
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow-x: auto;
}

/* Buton kapsayıcısı */
.button-container {
  display: flex;
  justify-content: center;
  margin-top: 15px;
}

/* Genel Buton Stili */
.button {
  background-color: #007bff;
  color: white; 
  border: none;
  padding: 10px 15px;
  font-size: 16px;
  cursor: pointer;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

.button:hover {
  background-color: #0056b3;
}

/* Ekle Butonu */
.add-to-cart {
  background-color: #007bff;
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: bold;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.add-to-cart:hover {
  background-color: #0056b3;
  transform: scale(1.05);
}

.add-to-cart:active {
  background-color: #00408a;
  transform: scale(0.98);
}

/* Ok simgesi */
.arrow {
  display: none;
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 10px solid #333;
  margin-top: 20px;
}

.container .arrow {
  align-self: center;
}

/* Sepet Kutusu Stili */
.cart-container {
  margin-top: 20px;
  padding: 15px;
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.cartHeader {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 10px;
  color: #333;
}

.cartItem {
  padding: 10px;
  border-bottom: 1px solid #ddd;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cartItem:last-child {
  border-bottom: none;
}

.remove-item {
  background-color: #dc3545;
  color: white;
  border: none;
  padding: 5px 10px;
  font-size: 16px;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.remove-item:hover {
  background-color: #c82333;
}

/* Temizle Butonu */
.clear-cart {
  background-color: #6c757d;
  color: white;
  border: none;
  padding: 10px 20px;
  font-size: 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  margin-top: 10px;
}

.clear-cart:hover {
  background-color: #5a6268;
  transform: scale(1.05);
}

.clear-cart:active {
  background-color: #545b62;
  transform: scale(0.98);
}

/* 📌 Toplam Boyut Alanı */
.total-size {
  font-size: 16px;
  font-weight: bold;
  padding: 10px 0;
  text-align: center;
  border-top: 2px solid #ddd;
  margin-top: 10px;
}

/* Metaveri satırlarını şıklaştırma */
.styled-line {
  font-size: 14px;
  line-height: 1.2;
  margin-bottom: 5px;
  color: #333;
  word-break: break-word;
  overflow-wrap: break-word;
  white-space: normal;
}

.styled-line strong {
  font-weight: bold;
  color: #000;
  margin-right: 5px;
}

/* Görsel ikon */
.visual-icon {
  cursor: pointer;
  margin-left: 10px;
  width: 30px;
  height: 30px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.visual-icon:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.visual-icon:active {
  transform: scale(0.95);
}

/* Katman Listesi başlığı - görsel etiketli */
.katmanListHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-visual {
  font-weight: bold;
  margin-bottom: 12px;
  font-size: 18px;
  color: #333;
}

/* "Tümünü Talep Et" ve "Talep Oluştur" Butonları */
#bulkRequestButton, 
#createRequestButton {
  margin-left: 10px;
}

/* Modal Butonları */
.modal-button {
  background-color: #007bff;
  color: white;
  padding: 8px 12px;
  font-size: 14px;
  border-radius: 4px;
  cursor: pointer;
  border: none;
  transition: background-color 0.3s ease;
}

.modal-button:hover {
  background-color: #0056b3;
}

/* Modal Arkaplan */
#requestModal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  animation: overlayFadeIn 0.5s forwards; /* Yavaşça açılacak */
   backdrop-filter: blur(3px);

}

/* Modal İçerik */
.modal-content {
  background: white;
  padding: 20px 30px;
  border-radius: 10px;
  width: 800px;
  max-width: 95%;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  margin: 30px auto;
  transform: scale(0.9);
  animation: modalScaleIn 0.5s ease-out forwards;
}

/* Kapatma Butonu */
.modal-close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 28px;
  font-weight: bold;
  color: #777;
  cursor: pointer;
  user-select: none;
  z-index: 1000;
  background: white;
  padding: 5px;
  border-radius: 50%;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  transition: color 0.3s; /* transform geçişini kaldırdık */
}

.modal-close:hover {
  color: #333;
  /* transform: none;  — zaten dönüş yok */
}
/* Modal Header */
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  border-bottom: 2px solid #ddd;
  padding-bottom: 10px;
}

.modal-header div {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* EULA Bölümü */
.eula-header {
  font-size: 18px;
  font-weight: bold;
  text-align: left;
  margin-bottom: 8px;
  color: #333;
  border-bottom: 2px solid #ddd;
  padding-bottom: 5px;
}

.eula-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
  text-align: left;
}
.eula-section {
  background-color: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 10px;
  max-height: 230px;
  overflow-y: auto;
  margin-top: 5px;
}
.eula-section .eula-header {
  margin-bottom: 10px;
  font-size: 18px;
  font-weight: bold;
}
.eula-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 0;
  border-bottom: 1px solid #ddd;
}
.eula-item:last-child {
  border-bottom: none;
}
.eula-item a {
  text-decoration: none;
  background-color: #007bff;
  color: #fff;
  padding: 6px 12px;
  border-radius: 4px;
  transition: background-color 0.3s ease;
}
.eula-item a:hover {
  background-color: #0056b3;
}

.eula-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px;
  border-bottom: 1px solid #ddd;
}

/* Evrak içi bağlantı */
.document-container .document-item a,
a {
  text-decoration: none !important;
}

/* Sepet Butonları */
#cartControls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  width: 100%;
}

/* PHOTO Modal overlay */
.modalphoto-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  animation: overlayFadeIn 0.4s forwards;
}

@keyframes overlayFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Modal Fotoğraf Konteyner */
.modalphoto-container {
  position: relative;
  background-color: #fff;
  padding: 10px;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  max-width: 90vw;
  max-height: 90vh;
  overflow: hidden;
  transform: scale(0.7);
  opacity: 0;
  animation: modalScaleIn 0.4s forwards;
}

@keyframes modalScaleIn {
  from {
    transform: scale(0.7);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.modalphoto-close {
  position: absolute;
  top: 8px;
  right: 12px;
  font-size: 36px;
  font-weight: bold;
  color: red;
  cursor: pointer;
  user-select: none;
  z-index: 1000;
  background: white;
  padding: 5px;
  border-radius: 35%;
  box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease, color 0.2s ease;
}

.modalphoto-close:hover {
  color: darkred;
  transform: scale(1.2);
}

.modalphoto-close:active {
  transform: scale(0.9);
}

.modalphoto-image {
  display: block;
  margin: 0 auto;
  max-width: 100%;
  max-height: 100%;
  transition: transform 0.2s ease-in-out;
  cursor: grab;
}

/* Farklı "Temizle" ve "Talep Oluştur" Butonları */
#clearCartButton,
#createRequestButton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 10px 20px;
  font-size: 16px;
  border-radius: 5px;
  transition: background-color 0.3s ease, transform 0.2s ease;
  cursor: pointer;
}

#clearCartButton {
  background-color: #6c757d;
  color: white;
}

#clearCartButton:hover { 
  background-color: #5a6268;
  transform: scale(1.05);
}

#clearCartButton:active { 
  background-color: #545b62;
  transform: scale(0.98);
}

#createRequestButton {
  background-color: #28a745;
  color: white;
}

#createRequestButton:hover { 
  background-color: #218838;
  transform: scale(1.05);
}

#createRequestButton:active { 
  background-color: #1e7e34;
  transform: scale(0.98);
}

/* Bilgi notu */
.info-note {
  color: red;
  font-size: 14px;
  font-style: italic;
  margin-top: 10px;
}

/* Kullanıcı Formu */
.kullanici {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 20px;
}

/* Form elemanları */
.form-group {
  display: flex;
  flex-direction: column;
}
.form-group label {
  margin-bottom: 5px;
  font-weight: bold;
}
.form-group input,
.form-group select {
  width: 100%;
  padding: 10px;
  height: 40px;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-sizing: border-box;
  font-size: 14px;
}
.info-note {
  grid-column: 1 / -1; /* Tüm sütunları kapla */
  color: #d9534f;
  font-size: 14px;
  font-style: italic;
  margin-bottom: 15px;
}
/* İndirme butonu: “Talep Formu ve Talep Listesi İndir” */
.download-button {
  grid-column: 1 / -1; /* Buton tüm satırı kaplasın */
  padding: 15px;
  font-size: 16px;
  background-color: #007bff;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  margin-bottom: 20px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}
.download-button:hover {
  background-color: #0056b3;
  transform: scale(1.03);
}
.download-button:hover {
  background-color: #0056b3;
  transform: scale(1.03);
}
.error {
  border: 4px solid red;
  box-shadow: 0 0 5px rgba(255, 0, 0, 0.5);
}
.error-tooltip {
  background-color: #f44336;
  color: #fff;
  padding: 5px 10px;
  font-size: 12px;
  border-radius: 3px;
  position: absolute;
  margin-top: 5px;
  z-index: 1001;
}

@keyframes overlayFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

input, select {
  font-family: Arial, sans-serif;
}

/* Header düzenlemeleri: başlık ve buton yan yana */
.site-header {
  display: flex;
  align-items: center;
  justify-content: flex-start; /* Başlangıç hizalaması */
  padding: 1rem 2rem;
  background-color: #f4f4f4;
}

/* Başlık stili */
.site-title {
  font-size: 1.8rem;
  color: #333;
  margin: 0;
}

/* BİLGİ AL butonu: başlığın hemen yanına, biraz boşlukla */
/* Butonu başlığın soluna taşımak */
.bilgi-al-btn {
  order: -1;          /* Flex container içinde önce görünmesini sağlar */
  margin-right: 1rem; /* Sağ tarafına boşluk ekler */
  
  /* Mevcut stil kuralları */
  background-color: #0073e6;
  color: #fff;
  border: none;
  padding: 0.3rem 0.8rem;
  font-size: 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
}
/* Hover efekti */
.bilgi-al-btn:hover {
  background-color: #005bb5;
}
/* Logo alanı */
.logo img {
  height: 40px;
}

/* Popup Overlay */
.info-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 10000;
  overflow-y: auto;
}
.info-popup-overlay.visible {
  display: flex;
}

/* Popup Content */
.info-popup-content {
  background: #fff;
  border-radius: 10px;
  max-width: 600px;
  width: 100%;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  padding: 20px;
  animation: popupFadeIn 0.3s ease-out;
  position: relative;
}

.info-popup-content .modal-close {
  /* Animasyon ve dönüşü sıfırla */
  animation: none !important;
  transform: none !important;
}

@keyframes popupFadeIn {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

/* Close Icon */
.info-popup-content .modal-close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  cursor: pointer;
  color: #333;
}
.info-popup-content .modal-close:hover {
  color: #000;
}

/* Modal Header */
.modal-header h2 {
  margin: 0 0 10px;
  font-size: 22px;
  color: #333;
}

/* Modal Body */
.modal-body p,
.modal-body ul {
  font-size: 14px;
  line-height: 1.6;
  color: #444;
}
.modal-body ul li {
  margin-bottom: 8px;
}
.modal-body a {
  color: #007bff;
  text-decoration: none;
}
.modal-body a:hover {
  text-decoration: underline;
}

/* Buttons */
.modal-button {
  background: #007bff;
  color: #fff;
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.3s;
}
.modal-button:hover {
  background: #0056b3;
}

/* Info Button */
.info-button-container {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}
#infoButton {
  background: #17a2b8;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.3s;
}
#infoButton:hover {
  background: #138496;
}

/* Responsive */
@media (max-width: 768px) {
  .info-popup-content {
    max-width: 90%;
    padding: 15px;
  }
  .modal-header h2 {
    font-size: 18px;
  }
  .modal-body p,
  .modal-body ul {
    font-size: 13px;
  }
  #infoButton {
    width: 100%;
  }
}

@media (max-width: 600px) {
  .bilgi-al-btn {
    padding: 0.4rem 0.4rem;   /* Dikey ve yatay padding azaltıldı */
    font-size: 0.55rem;       /* Yazı boyutu küçültüldü */
  }
}

/* ========== MOBİL UYUMLULUK ========== */
@media (max-width: 768px) {
  /* Genel form ve başlık düzenlemeleri */
  .form-container {
    width: 95%;
    max-width: 100%;
    padding: 20px;
    margin: 0;
  }
   .header-container {
    display: flex;
    justify-content: space-between; /* Başlık sola, logo sağa */
    align-items: center;
    padding: 0 15px; /* Kenarlardan biraz boşluk ekleyelim */
  }

  .header-title {
    font-size: 20px; /* Mobilde biraz küçült */
    text-align: left; /* Başlık sola hizalı */
    flex-grow: 1; /* Boşlukları doldurması için */
  }

  .header-logo {
    height: 50px; /* Mobilde logo daha küçük */
    margin-left: 10px; /* Başlıkla arasına biraz boşluk bırak */
     padding-right: 15px; /* Logonun sağından boşluk ekle */
  }
  
  h1 {
    font-size: 1.4rem;
    margin-bottom: 20px;
    text-align: center;
  }
  
  label {
    font-size: 1rem;
  }
  
  select {
    font-size: 1rem;
    padding: 10px;
  }
  
  /* Container: Katman ve Metaveri alanları */
  .container {
    flex-direction: column;
    gap: 10px;
  }
  
  #katmanList, 
  #fileContent {
    width: 100%;
    padding: 15px;
    margin-bottom: 10px;
  }
  
  .visual-icon {
    width: 25px;
    height: 25px;
  }
  
  /* Sepet Düzeni */
  .cart-container {
    width: 100%;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
  }
  
  .cartItem {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    padding: 10px;
    border-bottom: 1px solid #ddd;
    width: 100%;
    box-sizing: border-box;
    overflow-wrap: break-word;
    word-break: break-all;
  }
  
  .remove-item {
    display: block;
    margin: 0 auto;
  }
  
  .cartHeader {
    font-size: 1.2rem;
    text-align: center;
  }
  
  .button-container {
    flex-direction: column;
    gap: 10px;
  }
  
  .button, .clear-cart, .add-to-cart {
    width: 100%;
    padding: 12px;
    font-size: 1rem;
  }
  
  /* Modal Düzenlemeleri */
  .modal-content {
    width: 95%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 20px;
    border-radius: 8px;
  }
  
  .modal-header {
    font-size: 1.2rem;
    text-align: center;
  }
  
  .modal-close {
    font-size: 1.5rem;
    top: 10px;
    right: 6px;
  }
  
  .modalphoto-container {
    max-width: 95vw;
    max-height: 95vh;
  }
  
  .modalphoto-close {
    top: 5px;
    right: 10px;
    font-size: 24px;
  }
   .kullanici {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .form-container {
    padding: 10px;
  }
  
  h1 {
    font-size: 18px;
  }
  
  label {
    font-size: 14px;
  }
  
  select {
    font-size: 12px;
  }
}
