/* CSS Reset ve Temel Stiller */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-green: #2d7a3e;
  --primary-orange: #ff8c42;
  --dark-green: #1e5a2e;
  --light-green: #e8f5e9;
  --light-orange: #fff3e6;
  --text-dark: #333;
  --text-light: #666;
  --border-color: #e0e0e0;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.15);
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  background: #fafafa;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
}

/* Üst Bilgi Barı */
.top-bar {
  background: linear-gradient(135deg, var(--primary-green), var(--dark-green));
  color: white;
  padding: 10px 0;
  font-size: 14px;
}

.top-bar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.top-bar-left span {
  margin-right: 20px;
}

.top-bar-right a {
  color: white;
  margin-left: 15px;
  transition: opacity 0.3s;
}

.top-bar-right a:hover {
  opacity: 0.8;
}

/* Header */
.header {
  background: white;
  padding: 20px 0;
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.logo h1 {
  color: var(--primary-green);
  font-size: 28px;
  font-weight: 700;
}

.logo .tagline {
  color: var(--primary-orange);
  font-size: 13px;
  margin-top: -5px;
}

.search-box {
  flex: 1;
  max-width: 500px;
}

.search-box form {
  display: flex;
  border: 2px solid var(--primary-green);
  border-radius: 25px;
  overflow: hidden;
}

.search-box input {
  flex: 1;
  border: none;
  padding: 12px 20px;
  font-size: 15px;
  outline: none;
}

.search-box button {
  background: var(--primary-green);
  color: white;
  border: none;
  padding: 12px 25px;
  cursor: pointer;
  font-size: 18px;
  transition: background 0.3s;
}

.search-box button:hover {
  background: var(--dark-green);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.header-info {
  display: flex;
  gap: 20px;
}

.info-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.info-item .icon {
  font-size: 24px;
}

.info-text small {
  display: block;
  font-size: 12px;
  color: var(--text-light);
}

.info-text strong {
  font-size: 14px;
  color: var(--primary-green);
}

.cart-icon a {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-orange);
  color: white;
  padding: 12px 20px;
  border-radius: 25px;
  font-size: 20px;
  position: relative;
  transition: all 0.3s;
}

.cart-icon a:hover {
  background: #e67a32;
  transform: translateY(-2px);
}

.cart-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background: red;
  color: white;
  font-size: 12px;
  padding: 3px 7px;
  border-radius: 50%;
  min-width: 22px;
  text-align: center;
}

.cart-text {
  font-size: 14px;
  font-weight: 600;
}

/* Navigasyon */
.main-nav {
  background: var(--light-green);
  border-top: 2px solid var(--primary-green);
}

.mobile-menu-toggle {
  display: none;
  background: var(--primary-green);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  margin: 10px 0;
}

.nav-list {
  list-style: none;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}

.nav-list > li {
  position: relative;
}

.nav-list > li > a {
  display: block;
  padding: 15px 20px;
  color: var(--text-dark);
  font-weight: 500;
  transition: all 0.3s;
}

.nav-list > li > a:hover,
.nav-list > li > a.active {
  background: var(--primary-green);
  color: white;
}

/* Dropdown */
.has-dropdown:hover .dropdown {
  display: block;
}

.dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  min-width: 220px;
  box-shadow: var(--shadow-hover);
  border-radius: 0 0 8px 8px;
  z-index: 1000;
}

.dropdown li a {
  display: block;
  padding: 12px 20px;
  color: var(--text-dark);
  border-bottom: 1px solid var(--border-color);
  transition: all 0.3s;
}

.dropdown li:last-child a {
  border-bottom: none;
}

.dropdown li a:hover {
  background: var(--light-green);
  color: var(--primary-green);
  padding-left: 25px;
}

/* Ana İçerik */
.main-content {
  min-height: 60vh;
  padding: 30px 0;
}

/* Hero Slider */
.hero-slider {
  position: relative;
  margin-bottom: 40px;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: var(--shadow-hover);
}

.slider-item {
  display: none;
  position: relative;
}

.slider-item.active {
  display: block;
}

.slider-item img {
  width: 100%;
  height: 450px;
  object-fit: cover;
}

/* Mobil ve desktop slider görselleri */
.slider-item .mobile-slider {
  display: none;
}

.slider-item .desktop-slider {
  display: block;
}

@media (max-width: 768px) {
  .slider-item .mobile-slider {
    display: block;
  }

  .slider-item .desktop-slider {
    display: none;
  }

  .slider-item img {
    height: 300px;
  }
}

.slider-content {
  position: absolute;
  top: 50%;
  left: 60px;
  transform: translateY(-50%);
  color: white;
  max-width: 500px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.slider-content h2 {
  font-size: 48px;
  margin-bottom: 15px;
}

.slider-content p {
  font-size: 20px;
  margin-bottom: 25px;
}

.slider-btn {
  display: inline-block;
  background: var(--primary-orange);
  color: white;
  padding: 15px 35px;
  border-radius: 30px;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s;
}

.slider-btn:hover {
  background: white;
  color: var(--primary-orange);
  transform: translateY(-2px);
}

.slider-controls {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

.slider-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s;
}

.slider-dot.active {
  background: white;
  width: 30px;
  border-radius: 6px;
}

/* Kategori Kutuları */
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 50px;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

.category-card {
  background: white;
  border-radius: 12px;
  padding: 25px;
  text-align: center;
  box-shadow: var(--shadow);
  transition: all 0.3s;
  cursor: pointer;
}

.category-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-5px);
}

.category-card .icon {
  font-size: 50px;
  margin-bottom: 15px;
}

.category-card h3 {
  color: var(--primary-green);
  font-size: 18px;
}

/* Ürün Grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 25px;
  margin-top: 30px;
}

.product-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s;
  position: relative;
}

.product-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-5px);
}

.product-image {
  position: relative;
  overflow: hidden;
  height: 250px;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-image img {
  width: 100%;
  height: 100%;
  max-height: 250px;
  object-fit: contain;
  transition: transform 0.3s;
}

.product-card:hover .product-image img {
  transform: scale(1.05);
}

.product-badges {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.badge {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  color: white;
}

.badge-new {
  background: #4caf50;
}

.badge-bestseller {
  background: #ff9800;
}

.badge-campaign {
  background: #f44336;
}

.discount-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: red;
  color: white;
  padding: 8px 12px;
  border-radius: 50%;
  font-size: 14px;
  font-weight: 700;
}

.product-info {
  padding: 20px;
}

.product-name {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 10px;
  min-height: 40px;
  color: var(--text-dark);
}

.product-prices {
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.product-price {
  font-size: 22px;
  font-weight: 700;
  color: var(--primary-green);
  display: inline-block;
}

.product-old-price {
  font-size: 16px;
  color: #999;
  text-decoration: line-through;
  display: inline-block;
}

.product-stock {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 15px;
}

.add-to-cart-btn {
  width: 100%;
  background: var(--primary-orange);
  color: white;
  border: none;
  padding: 12px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.add-to-cart-btn:hover {
  background: #e67a32;
  transform: translateY(-2px);
}

/* Bölüm Başlıkları */
.section-title {
  text-align: center;
  margin: 50px 0 30px;
}

.section-title h2 {
  font-size: 32px;
  color: var(--primary-green);
  margin-bottom: 10px;
}

.section-title p {
  color: var(--text-light);
  font-size: 16px;
}

/* Info Banner */
.info-banner {
  background: linear-gradient(135deg, var(--primary-green), var(--dark-green));
  color: white;
  padding: 30px;
  border-radius: 15px;
  margin: 40px 0;
  text-align: center;
}

.info-banner h3 {
  font-size: 28px;
  margin-bottom: 10px;
}

/* Footer */
.footer {
  background: var(--dark-green);
  color: white;
  padding: 50px 0 20px;
  margin-top: 60px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 30px;
}

.footer-col h3,
.footer-col h4 {
  margin-bottom: 20px;
  color: var(--primary-orange);
}

.footer-col p {
  line-height: 1.8;
  margin-bottom: 20px;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 10px;
}

.footer-col ul li a {
  color: white;
  transition: color 0.3s;
}

.footer-col ul li a:hover {
  color: var(--primary-orange);
}

.social-links {
  display: flex;
  gap: 15px;
  margin-top: 20px;
}

.social-links a {
  font-size: 24px;
  transition: transform 0.3s;
}

.social-links a:hover {
  transform: scale(1.2);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

/* WhatsApp Butonu */
.whatsapp-btn {
  position: fixed;
  bottom: 80px;
  right: 20px;
  background: #25d366;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  transition: all 0.3s;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

/* Mobil Alt Bar */
.mobile-bottom-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.mobile-bottom-bar a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 5px;
  color: var(--text-dark);
  font-size: 12px;
  position: relative;
  transition: all 0.3s;
}

.mobile-bottom-bar a.active {
  color: var(--primary-green);
}

.mobile-bottom-bar .icon {
  font-size: 22px;
  margin-bottom: 3px;
}

.mobile-bottom-bar .badge {
  position: absolute;
  top: 5px;
  right: 15px;
  background: var(--primary-orange);
  color: white;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 10px;
}

/* Form Stiller */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--text-dark);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 15px;
  border: 2px solid var(--border-color);
  border-radius: 8px;
  font-size: 15px;
  transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary-green);
}

.btn {
  display: inline-block;
  padding: 12px 30px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-primary {
  background: var(--primary-green);
  color: white;
}

.btn-primary:hover {
  background: var(--dark-green);
  transform: translateY(-2px);
}

.btn-secondary {
  background: var(--primary-orange);
  color: white;
}

.btn-secondary:hover {
  background: #e67a32;
}

/* Alert Mesajları */
.alert {
  padding: 15px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.alert-success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.alert-error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.alert-info {
  background: #d1ecf1;
  color: #0c5460;
  border: 1px solid #bee5eb;
}

/* Breadcrumbs */
.breadcrumbs {
  padding: 15px 0;
  font-size: 14px;
  color: var(--text-light);
}

.breadcrumbs a {
  color: var(--primary-green);
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 1024px) {
  .header-info {
    display: none;
  }
}

@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: block;
  }

  .main-nav {
    position: relative;
  }

  .nav-list {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: white;
    z-index: 9999;
    overflow-y: auto;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  }

  .nav-list.active {
    display: flex;
  }

  .nav-list > li {
    width: 100%;
  }

  .nav-list > li > a {
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    display: block;
    font-size: 16px;
  }

  /* Mobilde dropdown menüleri tamamen gizle */
  .dropdown {
    display: none !important;
  }

  /* Alt kategori varsa işaret göster */
  .has-dropdown > a::after {
    content: ' ›';
    margin-left: 5px;
    font-size: 18px;
  }

  /* Mobil menü kapat butonu */
  .close-menu-btn {
    width: 100%;
    padding: 15px;
    background: var(--primary-green);
    color: white;
    border: none;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    margin-bottom: 20px;
  }

  .close-menu-btn:hover {
    background: var(--hover-green);
  }

  .header-content {
    flex-wrap: wrap;
  }

  .search-box {
    order: 3;
    width: 100%;
    max-width: 100%;
  }

  .slider-content {
    left: 30px;
    max-width: 80%;
  }

  .slider-content h2 {
    font-size: 28px;
  }

  .slider-content p {
    font-size: 16px;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 15px;
  }

  .product-image {
    height: 180px;
  }

  .product-image img {
    max-height: 180px;
  }

  .product-price {
    font-size: 18px;
  }

  .product-old-price {
    font-size: 14px;
  }

  .mobile-bottom-bar {
    display: flex;
  }

  .main-content {
    padding-bottom: 80px;
  }

  .whatsapp-btn {
    bottom: 90px;
    right: 15px;
    width: 50px;
    height: 50px;
  }
}

@media (max-width: 480px) {
  .logo h1 {
    font-size: 20px;
  }

  .category-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .product-image {
    height: 160px;
  }

  .product-image img {
    max-height: 160px;
  }

  .product-info {
    padding: 12px;
  }

  .product-name {
    font-size: 14px;
    min-height: 35px;
  }

  .product-price {
    font-size: 16px;
  }

  .product-old-price {
    font-size: 13px;
  }

  .add-to-cart-btn {
    padding: 10px;
    font-size: 13px;
  }

  /* Sepet sayfası mobil düzeltmeleri */
  .container > div[style*="grid-template-columns: 2fr 1fr"] {
    display: block !important;
  }

  .container > div > div {
    margin-bottom: 20px;
  }

  /* Form sayfaları mobil düzeltmeleri */
  .form-group input[type="text"],
  .form-group input[type="email"],
  .form-group input[type="password"],
  .form-group input[type="tel"],
  .form-group input[type="number"],
  .form-group select,
  .form-group textarea {
    font-size: 16px !important; /* iOS zoom önleme */
  }

  /* Buton düzeltmeleri */
  .btn {
    width: 100%;
    text-align: center;
    padding: 12px 20px;
  }

  /* Tablo responsive */
  table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

/* Genel mobil düzeltmeler - tüm ekranlar için */
@media (max-width: 768px) {
  /* Header mobil düzeltmeleri */
  .header {
    padding: 10px 0;
  }

  .header-content {
    gap: 15px;
  }

  .logo img {
    max-height: 45px !important;
  }

  .header-info {
    display: none; /* Kargo bilgisini mobilde gizle */
  }

  .cart-icon {
    font-size: 14px;
  }

  /* Grid layoutları tek sütuna çevir */
  [style*="display: grid"][style*="grid-template-columns: 2fr 1fr"],
  [style*="display: grid"][style*="grid-template-columns: 1fr 1fr"] {
    display: block !important;
  }

  /* Flex layoutları dikey yap */
  [style*="display: flex"] {
    flex-wrap: wrap;
  }

  /* Padding ve margin ayarlamaları */
  .container {
    padding: 0 15px;
  }

  /* Sticky pozisyonları kaldır */
  [style*="position: sticky"] {
    position: relative !important;
    top: auto !important;
  }

  /* Overflow düzeltmeleri */
  body {
    overflow-x: hidden;
  }

  /* Form düzeni */
  .form-group {
    margin-bottom: 15px;
  }

  /* Sipariş özeti kutusu */
  .admin-card,
  [style*="background: white"][style*="border-radius"] {
    margin-bottom: 20px;
  }

  /* Sepet sayfası özel düzeltmeleri */
  .cart-layout {
    display: block !important;
    grid-template-columns: 1fr !important;
  }

  .cart-item {
    flex-direction: column !important;
    gap: 15px !important;
    padding: 15px 0 !important;
  }

  .cart-item-image {
    width: 100% !important;
    height: 200px !important;
    max-width: 100% !important;
  }

  .cart-item-details {
    width: 100%;
  }

  .cart-item-details h3 {
    font-size: 16px !important;
  }

  .cart-item-details > div[style*="display: flex"] {
    flex-direction: column !important;
    gap: 10px !important;
  }

  /* Sipariş özeti responsive */
  .cart-layout > div:last-child {
    order: -1; /* Sipariş özetini üste taşı */
    margin-bottom: 20px;
  }

  /* Ürün detay sayfası mobil */
  .product-detail-layout {
    display: block !important;
    grid-template-columns: 1fr !important;
  }

  .product-image-section img {
    height: 300px !important;
  }

  .product-detail-layout > div {
    margin-bottom: 30px;
  }

  /* Padding düzeltmeleri */
  [style*="padding: 40px"] {
    padding: 20px !important;
  }

  [style*="padding: 30px"] {
    padding: 15px !important;
  }

  /* Gap düzeltmeleri */
  [style*="gap: 50px"] {
    gap: 20px !important;
  }

  [style*="gap: 30px"] {
    gap: 15px !important;
  }
}
