/**
 * ================================================================
 * Güneş Otomasyon - Precision Industrial Commerce Design System
 * ================================================================
 * Modern, yüksek performanslı, endüstriyel minimalizm.
 * Temiz çizgiler, yüksek kontrast, mimari solid zeminler.
 * Cam efekti (glassmorphism) sadeleştirilmiş, net 1px sınırlar.
 * ================================================================
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Plus+Jakarta+Sans:wght@600;700;800&display=swap');

/* ================================================================
   1. CSS DEĞİŞKENLERİ & TOKENS
   ================================================================ */
:root {
  --color-primary: #000310;        /* Deep Industrial Black */
  --color-primary-container: #101d36; /* Midnight Navy Header & Structural */
  --color-secondary: #0051d5;      /* Precision Cobalt Blue */
  --color-secondary-hover: #003ea8;
  --color-secondary-container: #316bf3;
  --color-tertiary: #00240a;       /* Dark Emerald Container */
  --color-tertiary-hover: #0e3f1a; /* Dark Emerald Container Hover */
  --color-tertiary-fixed: #7ffc97; /* Light Accent Green */
  --color-on-tertiary-container: #009a43;
  --color-surface: #f8f9ff;        /* Ultra-clean Canvas */
  --color-surface-canvas: #ffffff;
  --color-surface-subtle: #f8f9ff;
  --color-surface-container-lowest: #ffffff;
  --color-surface-container-low: #eff4ff;
  --color-surface-container: #e5eeff;
  --color-surface-container-high: #dce9ff;
  --color-surface-container-highest: #d3e4fe;
  --color-text-main: #0b1c30;      /* Deep Midnight Slate */
  --color-text-muted: #45474d;     /* High Legibility Slate */
  --color-border-hairline: #e2e8f0;
  --color-border-strong: #c5c6ce;
  --color-outline: #75777e;
  --color-whatsapp: #16a34a;
  --color-whatsapp-direct: #25d366;
  --color-success: #16a34a;
  --color-warning: #f59e0b;
  --color-danger: #ba1a1a;

  --font-headline: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 3px 0 rgba(16, 29, 54, 0.04), 0 1px 2px -1px rgba(16, 29, 54, 0.04);
  --shadow-card: 0 1px 3px 0 rgba(16, 29, 54, 0.04), 0 1px 2px -1px rgba(16, 29, 54, 0.04);
  --shadow-hover: 0 12px 24px -4px rgba(16, 29, 54, 0.08), 0 4px 6px -2px rgba(16, 29, 54, 0.03);
  --shadow-dropdown: 0 20px 25px -5px rgba(16, 29, 54, 0.1), 0 8px 10px -6px rgba(16, 29, 54, 0.04);
}

/* ================================================================
   2. TEMEL YAPI VE ARKA PLAN
   ================================================================ */
html, body {
  font-family: var(--font-body);
  color: var(--color-text-main);
  background-color: var(--color-surface-subtle);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6, .font-headline {
  font-family: var(--font-headline);
  letter-spacing: -0.02em;
}

/* Temiz mimari zemin (Eski dokulu arka plan yerine modern solid/subtle) */
.texture-bg {
  background-color: #f8f9ff;
  background-image: none !important;
}

/* ================================================================
   3. BUTONLAR (Precision Industrial)
   ================================================================ */
.btn-primary, .stitched-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.875rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-sm);
  background-color: var(--color-primary);
  color: #ffffff;
  border: 1px solid transparent;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
  cursor: pointer;
  text-decoration: none;
}
.btn-primary:hover, .stitched-button:hover {
  background-color: #1e293b;
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-hover);
}
.btn-primary:active, .stitched-button:active {
  transform: translateY(0);
}

/* Yüksek Dönüşümlü Satın Alma Butonu */
.btn-buy, .btn-accent {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.875rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  background-color: #101d36;
  background-image: linear-gradient(135deg, #101d36 0%, #000310 100%);
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 4px 12px rgba(16, 29, 54, 0.25);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  text-decoration: none;
}
.btn-buy:hover, .btn-accent:hover {
  background-color: #0051d5 !important;
  background-image: linear-gradient(135deg, #0051d5 0%, #003ea8 100%) !important;
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 81, 213, 0.35);
}
.btn-buy:active, .btn-accent:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(0, 81, 213, 0.25);
}
.btn-buy *, .btn-accent * {
  color: inherit;
}

/* Elektrik Mavisi Buton */
.btn-secondary, .stitched-button-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.875rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-sm);
  background-color: var(--color-secondary);
  color: #ffffff;
  border: 1px solid transparent;
  transition: all 0.2s ease;
}
.btn-secondary:hover, .stitched-button-secondary:hover {
  background-color: var(--color-secondary-hover);
  transform: translateY(-1px);
}

/* Çizgili / Outline Buton */
.btn-outline, .stitched-button-outlined {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.875rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-sm);
  background-color: #ffffff;
  color: var(--color-primary);
  border: 1px solid var(--color-border-strong);
  transition: all 0.2s ease;
}
.btn-outline:hover, .stitched-button-outlined:hover {
  background-color: var(--color-surface-subtle);
  border-color: var(--color-primary);
}

/* Doğrudan WhatsApp Butonu */
.btn-whatsapp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.875rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-sm);
  background-color: var(--color-whatsapp);
  color: #ffffff;
  border: 1px solid transparent;
  box-shadow: 0 2px 4px rgba(37, 211, 102, 0.25);
  transition: all 0.2s ease;
}
.btn-whatsapp:hover {
  opacity: 0.92;
  transform: translateY(-1px);
}

/* ================================================================
   4. KARTLAR VE ÇERÇEVELER (Sadeleştirilmiş, Net Hatlar)
   ================================================================ */
.card-industrial, .stitched-border, .stitched-border-variant, .stitched-border-sm {
  background-color: #ffffff;
  border: 1px solid var(--color-border-hairline) !important;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
}

.card-shadow {
  box-shadow: var(--shadow-card);
}

.card-shadow-hover {
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.card-shadow-hover:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  border-color: var(--color-border-strong);
}

/* ================================================================
   5. CAM EFEKTİ SADELEŞTİRMESİ (Clean Flat Planes - No Heavy Blur)
   ================================================================ */
/* Blur/frosted cam efekti yerine temiz, opak, net kartlar */
.glass-panel, .backdrop-blur, .backdrop-blur-md, .backdrop-blur-sm {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  background-color: #ffffff !important;
  border: 1px solid var(--color-border-hairline) !important;
  box-shadow: var(--shadow-card) !important;
}

/* Yarı saydam modal arka planı (Düz temiz koyu slate perde) */
.modal-backdrop, #sidebar-overlay {
  background-color: rgba(15, 23, 42, 0.5) !important;
  backdrop-filter: none !important;
}

/* ================================================================
   6. GİRDİ ELEMANLARI (Form Inputs)
   ================================================================ */
.form-input-industrial, .stitched-input {
  width: 100%;
  height: 42px;
  padding: 0.5rem 0.875rem;
  border-radius: var(--radius-sm);
  background-color: #ffffff;
  border: 1px solid var(--color-border-strong);
  color: var(--color-text-main);
  font-family: var(--font-body);
  font-size: 0.875rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
}
.form-input-industrial:focus, .stitched-input:focus {
  border-color: var(--color-secondary);
  box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.15);
}
.form-input-industrial::placeholder, .stitched-input::placeholder {
  color: #94a3b8;
}

textarea.form-input-industrial, textarea.stitched-input {
  height: auto;
  min-height: 80px;
}

.stitched-checkbox {
  width: 1.125rem;
  height: 1.125rem;
  border: 1px solid var(--color-border-strong);
  border-radius: 4px;
  background-color: #ffffff;
  cursor: pointer;
  accent-color: var(--color-secondary);
}

/* ================================================================
   7. TEKNİK ÇİPLER VE ROZETLER (Badges & Tags)
   ================================================================ */
.spec-badge, .woven-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.1875rem 0.5rem;
  border-radius: var(--radius-xs);
  background-color: #f1f5f9;
  color: #334155;
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border: 1px solid #e2e8f0;
}

.spec-badge-blue, .woven-tag-amber {
  background-color: #eff6ff;
  color: #0066ff;
  border-color: #bfdbfe;
}

.spec-badge-green, .woven-tag-green {
  background-color: #f0fdf4;
  color: #16a34a;
  border-color: #bbf7d0;
}

.spec-badge-amber {
  background-color: #fffbeb;
  color: #d97706;
  border-color: #fde68a;
}

.spec-badge-red {
  background-color: #fef2f2;
  color: #dc2626;
  border-color: #fecaca;
}

/* Marka İtalyan Rozeti */
.brand-tag-nice {
  background-color: var(--color-secondary);
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.05em;
}

/* ================================================================
   8. ÜRÜN KARTI DÜZENİ
   ================================================================ */
.product-card {
  background-color: #ffffff;
  border: 1px solid var(--color-border-hairline);
  border-radius: var(--radius-md);
  padding: 1rem;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-col: column;
  justify-content: space-between;
}
.product-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  border-color: var(--color-border-strong);
}

.product-img-stage {
  position: relative;
  aspect-ratio: 1 / 1;
  background-color: #f8fafc;
  border-radius: var(--radius-sm);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
}

/* ================================================================
   9. BİLDİRİM (TOAST) SİSTEMİ
   ================================================================ */
#toast-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: 400px;
}

.toast-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid transparent;
  box-shadow: var(--shadow-hover);
  background-color: #ffffff;
  cursor: pointer;
  transition: opacity 0.3s ease, transform 0.2s ease;
  animation: toast-slide-in 0.25s ease-out;
}
@keyframes toast-slide-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
.toast-item.toast-success { border-color: #86efac; background-color: #f0fdf4; color: #166534; }
.toast-item.toast-error { border-color: #fca5a5; background-color: #fef2f2; color: #991b1b; }
.toast-item.toast-warning { border-color: #fde047; background-color: #fefce8; color: #854d0e; }
.toast-item.toast-info { border-color: #93c5fd; background-color: #eff6ff; color: #1e40af; }

/* ================================================================
   10. ALERTLER & UYARILAR
   ================================================================ */
.stitched-alert, .alert-industrial {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.stitched-alert-error, .alert-error {
  background-color: #fef2f2;
  border-color: #fecaca;
  color: #991b1b;
}
.stitched-alert-success, .alert-success {
  background-color: #f0fdf4;
  border-color: #bbf7d0;
  color: #166534;
}

/* ================================================================
   11. SAYFALAMA
   ================================================================ */
.pagination-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  transition: all 0.2s ease;
  border: 1px solid var(--color-border-hairline);
  background-color: #ffffff;
  color: var(--color-primary);
  text-decoration: none;
}
.pagination-link:hover {
  background-color: var(--color-surface-subtle);
  border-color: var(--color-primary);
}
.pagination-link.active {
  background-color: var(--color-primary);
  color: #ffffff;
  border-color: var(--color-primary);
}

/* ================================================================
   12. KATEGORİ PİLL VE GEZİNME
   ================================================================ */
.category-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.875rem;
  border-radius: var(--radius-full);
  background-color: #ffffff;
  border: 1px solid var(--color-border-hairline);
  color: var(--color-primary);
  font-size: 0.8125rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.15s ease;
  text-decoration: none;
}
.category-pill:hover, .category-pill.active {
  background-color: #e5eeff;
  border-color: #bfdbfe;
  color: var(--color-secondary);
}

/* ================================================================
   13. SCROLLBAR VE YARDIMCILAR
   ================================================================ */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

.scrollbar-none::-webkit-scrollbar { display: none; }
.scrollbar-none { -ms-overflow-style: none; scrollbar-width: none; }

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
