/* Genel Sıfırlama ve Temel Stiller */
:root {
  --primary-color: #2563eb; /* Temiz mavi */
  --secondary-color: #1e40af; /* Koyu mavi */
  --text-color: #1f2937;
  --light-text-color: #6b7280;
  --background-color: #ffffff;
  --card-background: #ffffff;
  --border-color: #e5e7eb;
  --shadow-light: rgba(0, 0, 0, 0.05);
  --shadow-medium: rgba(0, 0, 0, 0.1);
  --warning-bg: #fef3c7;
  --warning-border: #f59e0b;
  --warning-text: #92400e;
  --hover-bg: #f9fafb;
  --search-bg: #f8fafc;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Inter", sans-serif;
  background-color: var(--background-color);
  color: var(--text-color);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  cursor: default;
  /* Metin seçimini engelle */
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
}

/* Yazı imleci sadece belirli elementlerde */
input[type="text"],
textarea {
  cursor: text;
  -webkit-user-select: text;
  -moz-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

/* Diğer tüm elementlerde default cursor */
* {
  cursor: default;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
}

/* Header Stilleri */
.main-header {
  background: var(--background-color);
  border-bottom: 1px solid var(--border-color);
  padding: 20px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 3px var(--shadow-light);
}

.header-content {
  display: flex;
  justify-content: center;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  font-size: 1.5em;
  font-weight: 600;
  color: var(--primary-color);
}

.logo i {
  margin-right: 10px;
  font-size: 1.2em;
}

.logo-link {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

.logo-link:hover {
  color: var(--secondary-color);
  text-decoration: none;
}

/* Hero Section Stilleri */
.hero-section {
  text-align: center;
  padding: 40px 20px 25px; /* Padding küçültüldü */
  margin-bottom: 25px; /* Margin küçültüldü */
}

.hero-section h1 {
  color: var(--text-color);
  margin-bottom: 15px;
  font-size: 2.5em;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.hero-section p {
  font-size: 1.1em;
  color: var(--light-text-color);
  max-width: 600px;
  margin: 0 auto 30px;
  font-weight: 400;
}

/* Arama Çubuğu Stilleri - Tüm bölüm küçültüldü */
.search-container {
  position: relative;
  max-width: 300px; /* 400px'den 300px'e */
  margin: 0 auto;
}

#searchInput {
  width: 100%;
  padding: 10px 15px 10px 40px; /* Biraz daha büyük padding */
  border: 1px solid var(--border-color);
  border-radius: 20px;
  font-size: 0.95em; /* Font boyutu biraz büyütüldü */
  background: var(--search-bg);
  transition: all 0.2s ease;
  font-family: inherit;
  cursor: text;
}

.search-icon {
  position: absolute;
  left: 15px; /* İkon pozisyonu ayarlandı */
  top: 50%;
  transform: translateY(-50%);
  color: var(--light-text-color);
  font-size: 1em; /* İkon boyutu normal */
  pointer-events: none;
}

/* Uyarı Bölümü Stilleri */
.warning-section {
  margin-bottom: 30px;
}

.warning-box {
  background: var(--warning-bg);
  border: 1px solid var(--warning-border);
  border-radius: 8px;
  padding: 20px;
  display: flex;
  align-items: flex-start;
  gap: 15px;
}

.warning-icon {
  color: var(--warning-text);
  font-size: 1.3em;
  margin-top: 2px;
  flex-shrink: 0;
}

.warning-content h3 {
  color: var(--warning-text);
  margin: 0 0 8px 0;
  font-size: 1.1em;
  font-weight: 600;
}

.warning-content p {
  color: var(--warning-text);
  margin: 0;
  font-size: 0.95em;
  line-height: 1.5;
}

/* Kategori Butonları Stilleri - İki satır düzeni */
.category-buttons-section {
  margin-bottom: 40px;
}

.category-buttons {
  display: flex;
  flex-wrap: wrap; /* İki satır için wrap aktif */
  justify-content: center;
  gap: 12px;
  padding: 20px;
  background: var(--search-bg);
  border-radius: 12px;
  border: 1px solid var(--border-color);
}

.category-btn {
  padding: 10px 18px;
  border: 2px solid transparent;
  border-radius: 8px; /* 25px'den 8px'e düşürüldü */
  background: transparent;
  color: var(--text-color);
  font-size: 0.9em;
  font-weight: 600;
  font-family: inherit;
  transition: all 0.3s ease;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

/* Her renk için border renkleri */
.category-btn[data-category*="sarı"] {
  border-color: #f0c800;
}

.category-btn[data-category*="turuncu"] {
  border-color: #f06400;
}

.category-btn[data-category*="kırmızı"] {
  border-color: #c80000;
}

.category-btn[data-category*="mor"] {
  border-color: #8c4b96;
}

.category-btn[data-category*="mavi"] {
  border-color: #0064c8;
}

.category-btn[data-category*="yeşil"] {
  border-color: #009632;
}

.category-btn[data-category*="gri"] {
  border-color: #646464;
}

.category-btn[data-category*="kahverengi"] {
  border-color: #966432;
}

.category-btn[data-category*="beyaz"] {
  border-color: #8c8c8c;
}

/* Hover efektleri - içine renk alması */
.category-btn[data-category*="sarı"]:hover {
  background-color: #f0c800;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(240, 200, 0, 0.3);
}

.category-btn[data-category*="turuncu"]:hover {
  background-color: #f06400;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(240, 100, 0, 0.3);
}

.category-btn[data-category*="kırmızı"]:hover {
  background-color: #c80000;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(200, 0, 0, 0.3);
}

.category-btn[data-category*="mor"]:hover {
  background-color: #8c4b96;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(140, 75, 150, 0.3);
}

.category-btn[data-category*="mavi"]:hover {
  background-color: #0064c8;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 100, 200, 0.3);
}

.category-btn[data-category*="yeşil"]:hover {
  background-color: #009632;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 150, 50, 0.3);
}

.category-btn[data-category*="gri"]:hover {
  background-color: #646464;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(100, 100, 100, 0.3);
}

.category-btn[data-category*="kahverengi"]:hover {
  background-color: #966432;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(150, 100, 50, 0.3);
}

.category-btn[data-category*="beyaz"]:hover {
  background-color: #8c8c8c;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(140, 140, 140, 0.3);
}

/* TÜMÜ butonu için özel stiller */
.category-btn[data-category="all"] {
  border-color: var(--primary-color);
}

.category-btn[data-category="all"]:hover {
  background-color: var(--primary-color);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.category-btn.active {
  background-color: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

/* Renkli butonlar için özel stiller */
.color-categories {
  padding-bottom: 40px;
}

.color-category {
  margin-bottom: 50px;
}

.category-title {
  font-size: 1.8em;
  color: var(--text-color);
  margin-bottom: 25px;
  font-weight: 600;
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 10px;
}

.color-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}

.color-card {
  background: var(--card-background);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 3px var(--shadow-light);
  transition: all 0.2s ease;
  border: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  cursor: default;
}

.color-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px var(--shadow-medium);
  background: var(--hover-bg);
}

.color-box {
  width: 100%;
  height: 120px;
  border-bottom: 1px solid var(--border-color);
}

.color-info {
  padding: 15px;
  text-align: center;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* RAL Kodu - Üstte, büyük harfle */
.color-code {
  font-size: 1em;
  font-weight: 600; /* Daha kalın */
  margin-bottom: 5px;
  color: var(--text-color);
  line-height: 1.3;
  cursor: default;
  text-transform: uppercase; /* Büyük harf */
  letter-spacing: 0.5px; /* Harfler arası boşluk */
}

/* Renk İsmi - Altta, normal yazım (baş harfleri büyük) */
.color-name {
  font-size: 0.85em;
  color: var(--light-text-color);
  margin: 0;
  font-weight: 400;
  cursor: default;
  /* text-transform: lowercase; kaldırıldı */
}

/* Footer Stilleri */
.main-footer {
  background: var(--background-color);
  border-top: 1px solid var(--border-color);
  padding: 30px 0;
  text-align: center;
  font-size: 0.9em;
  margin-top: 40px;
}

.footer-content {
  color: var(--light-text-color);
}

/* Yukarı Kaydır Butonu Stilleri */
.scroll-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 1.2em;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
  transition: all 0.3s ease;
  opacity: 0;
  visibility: hidden;
  z-index: 1000;
}

.scroll-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-to-top:hover {
  background: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.4);
}

.scroll-to-top:active {
  transform: translateY(0);
}

/* Duyarlı Tasarım Ayarlamaları */
@media (max-width: 768px) {
  .container {
    padding: 15px;
  }

  .hero-section {
    padding: 30px 15px 20px;
    margin-bottom: 20px;
  }

  .hero-section h1 {
    font-size: 2em;
  }

  .hero-section p {
    font-size: 1em;
  }

  .search-container {
    max-width: 250px;
  }

  .warning-box {
    flex-direction: column;
    text-align: center;
    gap: 10px;
  }

  .warning-icon {
    align-self: center;
  }

  .category-buttons {
    padding: 15px 10px;
    gap: 8px;
    justify-content: center; /* Mobilde merkez hizala */
  }

  .category-btn {
    padding: 8px 14px;
    font-size: 0.8em;
    border-radius: 6px; /* Mobilde daha da az yuvarlak */
  }

  .color-category {
    margin-bottom: 35px;
  }

  .category-title {
    font-size: 1.5em;
    margin-bottom: 20px;
  }

  .color-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 15px;
  }

  .color-box {
    height: 100px;
  }

  .color-info {
    padding: 12px;
  }

  .color-code {
    font-size: 0.9em;
  }

  .color-name {
    font-size: 0.8em;
  }

  .scroll-to-top {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
    font-size: 1.1em;
  }
}

@media (max-width: 480px) {
  .hero-section h1 {
    font-size: 1.8em;
  }

  .search-container {
    max-width: 220px;
  }

  #searchInput {
    padding: 6px 10px 6px 30px;
    font-size: 0.85em;
  }

  .search-icon {
    left: 10px;
    font-size: 0.8em;
  }

  .category-buttons {
    padding: 12px 8px;
    gap: 6px;
  }

  .category-btn {
    padding: 6px 12px;
    font-size: 0.75em;
    border-radius: 5px; /* En küçük ekranlarda minimal yuvarlak */
  }

  .color-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
  }

  .color-box {
    height: 80px;
  }

  .color-code {
    font-size: 0.85em;
  }

  .color-name {
    font-size: 0.75em;
  }

  .scroll-to-top {
    bottom: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    font-size: 1em;
  }
}
