/* ------------------------------------------------------------------
   G Tech Aluminium — mobil uyumluluk katmanı
   Uygulama satır içi stil kullandığı için kurallar !important taşır.
   Seçiciler hem yazıldığı hem tarayıcının yeniden serileştirdiği
   ("height: 230px") biçimi kapsar. Renk ve düzen mantığı korunur.
   ------------------------------------------------------------------ */

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { overflow-x: hidden; }
img, video, canvas { max-width: 100%; }

/* iOS Safari form alanına dokununca sayfayı yakınlaştırmasın */
@media (max-width: 820px) {
  input, select, textarea { font-size: 16px !important; min-height: 46px !important; }
  button { font-size: 15px !important; }
}

@media (max-width: 900px) {
  header nav { font-size: 13.5px !important; gap: 10px 14px !important; }
}

/* --- Telefon --- */
@media (max-width: 640px) {
  section, header > div { padding-left: 16px !important; padding-right: 16px !important; }

  /* Üst menü: logo satırı + altında bağlantılar, tam genişlik teklif butonu */
  header > div { padding-top: 10px !important; padding-bottom: 10px !important; gap: 10px !important; }
  header nav {
    margin-left: 0 !important;
    width: 100% !important;
    flex-wrap: wrap !important;
    gap: 8px 14px !important;
    font-size: 13px !important;
    justify-content: flex-start !important;
  }
  header nav > a { min-height: 34px !important; display: inline-flex !important; align-items: center !important; }
  header nav > a[href*="#teklif"] {
    flex: 1 1 100% !important;
    justify-content: center !important;
    padding: 13px 18px !important;
    order: 9 !important;
  }
  header nav > span { order: 8 !important; }

  /* Metin blokları tam genişlik */
  section p { max-width: 100% !important; }
  section div[style*="margin-top: 64px"],
  section div[style*="margin-top:64px"] { gap: 20px 28px !important; margin-top: 34px !important; }

  /* Ana çağrı butonları dokunma hedefi */
  section > div > div > a[href*="#urunler"],
  section > div > div > a[href*="#kartela"],
  section a[href*="#teklif"] {
    min-height: 48px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  /* Kart görselleri kısalsın */
  div[style*="height: 230px"], div[style*="height:230px"] { height: 190px !important; }

  /* İki kolonlu paneller tek kolon */
  div[style*="grid-template-columns: 1fr 1fr"],
  div[style*="grid-template-columns:1fr 1fr"] { grid-template-columns: 1fr !important; }

  /* Renk kartelası: 3 → 2 kolon */
  div[style*="repeat(3, 1fr)"], div[style*="repeat(3,1fr)"] { grid-template-columns: repeat(2, 1fr) !important; }

  /* Yatay kayan tablolar: dokunmatik kaydırma */
  div[style*="overflow-x: auto"], div[style*="overflow-x:auto"] {
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    overscroll-behavior-x: contain;
  }

  /* Bilgi şeritleri */
  div[style*="padding: 12px 16px"], div[style*="padding:12px 16px"] { padding: 10px 12px !important; }

  /* Modal ve büyütme katmanları */
  div[style*="position: fixed"][style*="padding: 32px"],
  div[style*="position:fixed"][style*="padding:32px"] { padding: 12px !important; }
  div[style*="position: fixed"][style*="padding: 24px"],
  div[style*="position:fixed"][style*="padding:24px"] { padding: 10px !important; }
  div[style*="max-height: 92vh"], div[style*="max-height:92vh"] { max-height: 94vh !important; }

  /* Lightbox okları görseli kapatmasın: alt köşelere in */
  div[style*="position: fixed"] > button[style*="left: 24px"],
  div[style*="position:fixed"] > button[style*="left:24px"] {
    left: 12px !important; top: auto !important; bottom: 14px !important; transform: none !important;
    width: 44px !important; height: 44px !important;
  }
  div[style*="position: fixed"] > button[style*="right: 24px"],
  div[style*="position:fixed"] > button[style*="right:24px"] {
    right: 12px !important; top: auto !important; bottom: 14px !important; transform: none !important;
    width: 44px !important; height: 44px !important;
  }

  /* Form gönder butonları tam genişlik */
  form button[type="submit"], form input[type="submit"] { width: 100% !important; min-height: 50px !important; }

  /* Yönetim çekmecesi tam ekran */
  div[style*="width: min(720px, 100vw)"], div[style*="width:min(720px, 100vw)"] { width: 100vw !important; }
}

@media (max-width: 420px) {
  section, header > div { padding-left: 13px !important; padding-right: 13px !important; }
  div[style*="height: 230px"], div[style*="height:230px"] { height: 165px !important; }
  header nav > a:not([href*="#teklif"]) { font-size: 12.5px !important; }
}

/* Hareket azaltma tercihi */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto !important; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
