/* ============================================================
   eTech — proyekt-spesifik overrides
   Dizaynın orijinal CSS faylları toxunulmadan qalır.
   Burada yalnız real məlumat / API inteqrasiyası üçün tənzimləmələr.
   ============================================================ */

/* Məhsul kartında real şəkilləri konteynerdə saxla */
.sf-prod-img {
  position: relative;
  overflow: hidden;
}
.sf-prod-img img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}
/* Anchor wrapper-i flex saxla */
a.sf-prod-img {
  text-decoration: none;
  color: inherit;
}

/* Mega-kateqoriya sidebar-da count rəqəmləri */
.sf-megacat a small {
  margin-left: auto;
  color: var(--ink-400);
  font-size: 11px;
  font-weight: 500;
}
.sf-megacat a small + .arr { margin-left: 8px; }

/* Məhsul kartının başlığı a-element olduğu üçün */
a.sf-prod-title {
  text-decoration: none;
  color: var(--ink-800);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.35;
  min-height: 36px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  letter-spacing: -0.005em;
}
a.sf-prod-title:hover { color: var(--brand); }

/* ============================================================
   Info-page primitives (haqqimizda, xidmetler, faq, gizlilik,
   sertler, catdirilma)
   ============================================================ */
.sf-info-section { margin: 28px 0 0; }
.sf-info-section + .sf-info-section { margin-top: 28px; }

.sf-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 28px 32px;
  box-shadow: var(--shadow-xs, 0 1px 2px rgba(15,23,42,.04));
}
.sf-card + .sf-card { margin-top: 18px; }
.sf-card h2 { font-family: var(--font-sans); font-size: 20px; font-weight: 700;
  color: var(--ink-900); margin: 0 0 14px; letter-spacing: -0.01em; }
.sf-card h3 { font-family: var(--font-sans); font-size: 16px; font-weight: 600;
  color: var(--ink-900); margin: 18px 0 8px; }
.sf-card p { font-size: 14px; line-height: 1.7; color: var(--ink-700); margin: 0 0 12px; }
.sf-card p:last-child { margin-bottom: 0; }
.sf-card ul, .sf-card ol { padding-left: 22px; margin: 0 0 12px; color: var(--ink-700); font-size: 14px; line-height: 1.7; }
.sf-card li + li { margin-top: 6px; }
.sf-card strong, .sf-card .bold { color: var(--ink-900); font-weight: 600; }
.sf-card a { color: var(--brand); text-decoration: none; }
.sf-card a:hover { text-decoration: underline; }

.sf-page-header {
  text-align: center;
  padding: 36px 0 8px;
}
.sf-page-header h1 {
  font-family: var(--font-sans);
  font-size: 30px;
  font-weight: 700;
  color: var(--brand);
  margin: 0 0 8px;
  letter-spacing: -0.015em;
}
.sf-page-header .crumb {
  font-size: 13px;
  color: var(--ink-500);
}
.sf-page-header .crumb a { color: var(--ink-500); text-decoration: none; }
.sf-page-header .crumb a:hover { color: var(--brand); }

/* Values grid (haqqimizda) */
.sf-value-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.sf-value-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 22px 18px;
  text-align: center;
  transition: all var(--t);
}
.sf-value-card:hover { border-color: var(--brand); transform: translateY(-2px); }
.sf-value-card .icon {
  width: 56px; height: 56px; margin: 0 auto 12px;
  background: var(--brand-50);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--brand); font-size: 22px;
}
.sf-value-card h4 {
  font-size: 14px; font-weight: 600; color: var(--ink-900);
  margin: 0; line-height: 1.35;
}
@media (max-width: 760px) {
  .sf-value-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Service tiles (xidmetler) */
.sf-svc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.sf-svc-tile {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 22px;
  display: flex; flex-direction: column; gap: 10px;
  transition: all var(--t);
}
.sf-svc-tile:hover { border-color: var(--brand); box-shadow: var(--shadow-sm, 0 4px 14px rgba(15,23,42,.06)); }
.sf-svc-tile .icon {
  width: 40px; height: 40px;
  background: var(--brand-50);
  color: var(--brand);
  border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}
.sf-svc-tile h4 {
  font-size: 15px; font-weight: 600; color: var(--ink-900);
  margin: 0;
}
.sf-svc-tile p {
  font-size: 13px; color: var(--ink-600); margin: 0; line-height: 1.55;
}
@media (max-width: 900px) { .sf-svc-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .sf-svc-grid { grid-template-columns: 1fr; } }

/* FAQ accordion */
.sf-faq { display: flex; flex-direction: column; gap: 10px; }
.sf-faq details {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 0;
  overflow: hidden;
  transition: border-color var(--t);
}
.sf-faq details[open] { border-color: var(--brand); }
.sf-faq summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 20px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink-900);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.sf-faq summary::-webkit-details-marker { display: none; }
.sf-faq summary::after {
  content: '+';
  font-size: 22px;
  font-weight: 400;
  color: var(--ink-500);
  transition: transform var(--t);
}
.sf-faq details[open] summary::after { content: '−'; color: var(--brand); }
.sf-faq details > div {
  padding: 0 20px 16px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--ink-700);
}
.sf-faq details > div p { margin: 0 0 8px; }
.sf-faq details > div p:last-child { margin-bottom: 0; }

/* Contact strip used on info pages */
.sf-contact-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.sf-contact-strip .item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 18px;
  display: flex; gap: 12px; align-items: center;
}
.sf-contact-strip .icon {
  width: 40px; height: 40px;
  background: var(--brand-50); color: var(--brand);
  border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; flex-shrink: 0;
}
.sf-contact-strip h5 { font-size: 13px; font-weight: 600; color: var(--ink-900); margin: 0 0 2px; }
.sf-contact-strip p, .sf-contact-strip a { font-size: 13px; color: var(--ink-600); margin: 0; text-decoration: none; }
.sf-contact-strip a:hover { color: var(--brand); }
@media (max-width: 760px) { .sf-contact-strip { grid-template-columns: 1fr; } }

/* ============================================================
   Search autocomplete dropdown — Phase 3
   Ported from legacy css/style.css since new pages don't load it.
   ============================================================ */
.search-dropdown {
    display: none;
    position: absolute;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 8px 28px rgba(0,0,0,0.18);
    z-index: 99999;
    overflow: hidden;
    border: 1px solid var(--border);
    max-height: 420px;
    overflow-y: auto;
}
.sd-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    text-decoration: none;
    color: var(--ink-900);
    transition: background 0.12s;
    border-bottom: 1px solid var(--ink-50);
}
.sd-item:hover, .sd-item.sd-active { background: var(--brand-50); }
.sd-img {
    width: 40px; height: 40px;
    object-fit: contain;
    flex-shrink: 0;
    border-radius: 4px;
    background: var(--ink-50);
}
.sd-info { flex: 1; min-width: 0; }
.sd-name {
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--ink-900);
}
.sd-name mark { background: transparent; color: var(--brand); font-weight: 700; }
.sd-meta { display: flex; gap: 6px; margin-top: 2px; }
.sd-brand {
    font-size: 11px;
    color: var(--ink-600);
    background: var(--ink-50);
    border-radius: 3px;
    padding: 1px 6px;
}
.sd-cat {
    font-size: 11px;
    color: var(--brand);
    background: var(--brand-50);
    border-radius: 3px;
    padding: 1px 6px;
}
.sd-price {
    font-size: 13px;
    font-weight: 700;
    color: var(--brand);
    white-space: nowrap;
}
.sd-all {
    display: block;
    padding: 9px 14px;
    font-size: 12px;
    color: var(--brand);
    text-decoration: none;
    background: var(--brand-50);
    text-align: center;
    font-weight: 600;
}
.sd-all:hover, .sd-all.sd-active { background: var(--brand-100); }

/* ============================================================
   Social login (Google + Facebook) — daxil-ol / qeydiyyat
   ============================================================ */
.sf-social-divider {
  display: flex; align-items: center; gap: 12px;
  margin: 22px 0 16px;
  color: var(--ink-400); font-size: 12px; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.6px;
}
.sf-social-divider::before, .sf-social-divider::after {
  content: ""; flex: 1; height: 1px; background: var(--border);
}
.sf-social-row {
  display: flex; flex-direction: column; gap: 10px;
}
/* Google's rendered iframe has its own height; container just centers it */
.sf-social-google-slot {
  width: 100%; display: flex; justify-content: center;
}
.sf-social-google-slot > div { width: 100% !important; }
/* Generic social button (Facebook + future providers) */
.sf-social-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; height: 42px;
  background: #fff; color: var(--ink-800);
  border: 1px solid var(--border); border-radius: var(--r-sm);
  font-family: inherit; font-size: 14px; font-weight: 500;
  cursor: pointer; transition: background 0.15s, border-color 0.15s;
}
.sf-social-btn:hover { background: var(--ink-50); border-color: var(--ink-300); }
.sf-social-btn:active { transform: translateY(1px); }
.sf-social-fb svg { flex-shrink: 0; }

/* Custom Google sign-in button — full width, centered content */
.sf-google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  height: 46px;
  padding: 0 20px;
  background: #fff;
  color: var(--ink-800);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.1px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.sf-google-btn:hover {
  background: #F6F8FB;
  border-color: var(--ink-300);
  box-shadow: 0 1px 3px rgba(15,26,43,0.08);
}
.sf-google-btn:active { transform: translateY(1px); }
.sf-google-btn:focus-visible {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-50);
}
.sf-google-btn-icon {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.sf-google-btn-text {
  display: inline-flex;
  align-items: center;
}

/* ============================================================
   Category trigger dropdown (search bar — "Bütün kateqoriyalar")
   ============================================================ */
.sf-cat-trigger.on {
  background: var(--brand-100);
  color: var(--brand-700);
}
.sf-cat-trigger.on .arr { transform: rotate(180deg); }
.sf-cat-trigger .arr { transition: transform .18s; }

.sf-cat-dropdown {
  display: none;
  position: absolute;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(15,26,43,0.16);
  border: 1px solid var(--border);
  z-index: 99999;
  padding: 8px;
  max-height: 480px;
  overflow-y: auto;
  min-width: 260px;
}
.sf-cat-dd-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  color: var(--ink-800);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  transition: background .12s, color .12s;
}
.sf-cat-dd-item:hover {
  background: var(--brand-50);
  color: var(--brand);
}
.sf-cat-dd-item i {
  width: 24px;
  text-align: center;
  color: var(--ink-500);
  font-size: 14px;
  flex-shrink: 0;
}
.sf-cat-dd-item:hover i { color: var(--brand); }
.sf-cat-dd-name { flex: 1; min-width: 0; }
.sf-cat-dd-count {
  font-size: 11px;
  font-weight: 600;
  color: var(--ink-400);
  background: var(--ink-50);
  padding: 2px 8px;
  border-radius: 999px;
  flex-shrink: 0;
}
.sf-cat-dd-item:hover .sf-cat-dd-count {
  background: #fff;
  color: var(--brand);
}
.sf-cat-dd-all {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px;
  margin-top: 4px;
  border-top: 1px solid var(--border);
  color: var(--brand);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}
.sf-cat-dd-all:hover { background: var(--brand-50); border-radius: 8px; }
