/**
 * Ürün kartları – oldcss’teki yapı (cam rozet, info grid, gölge/hover).
 * .service-card hariç (Teknik Destek kartlarına uygulanmaz).
 */

.product-grid {
  margin-top: 15px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, max-content));
  justify-content: center;
  align-items: center;
  gap: 30px;
  perspective: 1200px;
  padding: 30px 30px 48px;
  box-sizing: border-box;
}

.card:not(.service-card) {
  position: relative;
  background: #bab0a2;
  color: #fef7e5;
  width: 300px;
  border-radius: 22px;
  /* overflow hidden gölgeyi keser; iç slider kendi overflow'u ile kırpılıyor */
  overflow: visible;
  box-shadow:
    0 4px 14px rgba(0, 0, 0, 0.08),
    0 12px 36px rgba(0, 0, 0, 0.14),
    0 24px 56px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition:
    transform 0.5s cubic-bezier(0.33, 1, 0.68, 1),
    box-shadow 0.55s cubic-bezier(0.33, 1, 0.68, 1);
}

/* Glass badge – oldcss .device-badge */
.card:not(.service-card) .device-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
  color: #3c2a21;
  z-index: 5;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    inset 0 -1px 0 rgba(0, 0, 0, 0.15),
    0 6px 18px rgba(0, 0, 0, 0.25);
  overflow: hidden;
}

/* Ürün kartı — iletişim overlay (oldjs openDevice / oldcss) */
.card:not(.service-card).show-overlay > *:not(.card-overlay-inner) {
  filter: blur(3px) brightness(0.7);
  transition: filter 0.3s ease;
}

.card-overlay-inner {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px;
  box-sizing: border-box;
  opacity: 0;
  transform: scale(1.05);
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 12;
  border-radius: inherit;
}

.card:not(.service-card).show-overlay .card-overlay-inner {
  opacity: 1;
  transform: scale(1);
}

.card-overlay-inner .card-overlay-title {
  color: #fff;
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  line-height: 1.4;
  max-width: 24em;
}

.card-overlay-inner .overlay-wa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 10px;
  background: #2f2f2f;
  color: #fff;
  text-decoration: none;
  font-size: 12px;
  min-width: 200px;
  box-sizing: border-box;
}

.card-overlay-inner .overlay-wa img {
  width: 16px;
  height: 16px;
  object-fit: contain;
  flex-shrink: 0;
}

.card:not(.service-card) .device-badge::before {
  content: "";
  position: absolute;
  top: -40%;
  left: -30%;
  width: 160%;
  height: 160%;
  background: linear-gradient(
    120deg,
    transparent 0%,
    rgba(255, 255, 255, 0.35) 45%,
    transparent 60%
  );
  transform: rotate(20deg);
  pointer-events: none;
}

.card:not(.service-card) .card-header {
  padding: 12px;
  position: relative;
  padding-right: 90px;
}

.card:not(.service-card) .card-header h2 {
  margin: 0;
  font-size: 22px;
  position: relative;
  color: #fef7e5;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3),
    0 6px 12px rgba(0, 0, 0, 0.15);
  font-family: inherit;
  font-weight: 600;
}

.card:not(.service-card) .card-header p {
  margin: 4px 0 0;
  font-size: 12px;
  opacity: 0.7;
}

/* Görsel alanı – oldcss .image-wrapper hissi */
.card:not(.service-card) .image-slider {
  position: relative;
  margin: 0 12px 12px;
  width: calc(100% - 24px);
  height: 400px;
  border-radius: 12px;
  overflow: hidden;
  box-sizing: border-box;
}

/* OEM: üst kenar ile görsel arasında nefes payı (rozet mutlak konumda) */
.card.oemSystems:not(.service-card) .image-slider {
  margin-top: 16px;
}

.card:not(.service-card) .slides {
  transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.card:not(.service-card) .slide {
  min-width: 100%;
  height: 100%;
  position: relative;
}

.card:not(.service-card) .slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card:not(.service-card) .nav {
  background: rgba(0, 0, 0, 0.5);
  font-size: 22px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  color: white;
  cursor: pointer;
  transition: background 0.3s ease;
}

.card:not(.service-card) .nav:hover {
  background: rgba(0, 0, 0, 0.7);
}

.card:not(.service-card) .prev {
  left: 12px;
}

.card:not(.service-card) .next {
  right: 12px;
}

.card:not(.service-card) .dots {
  bottom: 18px;
}

.card:not(.service-card) .dot {
  width: 7px;
  height: 7px;
}

.card:not(.service-card) .dot.active {
  transform: scale(1.2);
}

/* INFO GRID – oldcss */
.card:not(.service-card) .info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 12px;
}

.card:not(.service-card) .info-box {
  background: #fef7e5;
  color: #3d2012;
  padding: 10px;
  border-radius: 12px;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-direction: row;
  border: 1.5px solid #a28c80;
}

.card:not(.service-card) .info-box img {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.card:not(.service-card) .info-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.card:not(.service-card) .info-text .label {
  font-size: 12px;
  opacity: 0.7;
}

.card:not(.service-card) .info-text .value {
  font-size: 12px;
  font-weight: 600;
}

/* Tek sayıda info kutusu: son satır (çoğunlukla garanti) tam genişlik */
.card:not(.service-card) .info-grid--odd .info-box:last-child {
  grid-column: 1 / -1;
}

/* Diğer ürün: kart gövdesi görünmez; sadece slider (gölge slider’da) */
.card:not(.service-card).other {
  background: transparent;
  box-shadow: none;
  border-radius: 22px; /* 🔥 overlay köşeleri için 0 -> 22px yapıldı */
  overflow: visible;
  cursor: default;
  width: min(300px, 100%);
  justify-self: center;
}

.card:not(.service-card).other .image-slider {
  margin: 0;
  width: 100%;
  max-width: 300px;
  border-radius: 22px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
  transition:
    transform 0.5s cubic-bezier(0.33, 1, 0.68, 1),
    box-shadow 0.55s cubic-bezier(0.33, 1, 0.68, 1);
}

/* ========== Teknik destek kartı (oldcss) ========== */
/* Sabit genişlik: tüm servis kartları aynı (ör. KAMERA DEĞİŞİMİ genişliği) */
.product-grid .service-card {
  width: 400px;
  max-width: 100%;
  box-sizing: border-box;
  background: #bab0a2;
  color: #fef7e5;
  border-radius: 22px;
  /* Hafif, kenarları sertleştirmeyen yayvan gölge */
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.06),
    0 12px 36px rgba(0, 0, 0, 0.1),
    0 24px 48px rgba(0, 0, 0, 0.06);
  position: relative;
  isolation: isolate;
  cursor: pointer;
  transition:
    transform 0.5s cubic-bezier(0.33, 1, 0.68, 1),
    box-shadow 0.55s cubic-bezier(0.33, 1, 0.68, 1);
}

/* Dokunmatikte :hover “yapışır”; lift sadece gerçek mouse hover’da */
@media (hover: hover) and (pointer: fine) {
  .card:not(.service-card):hover {
    transform: translateY(-6px) scale(1.012);
    box-shadow:
      0 6px 18px rgba(0, 0, 0, 0.09),
      0 15px 40px rgba(0, 0, 0, 0.15),
      0 28px 58px rgba(0, 0, 0, 0.105);
  }

  .card:not(.service-card).other:hover {
    transform: none;
    box-shadow: none;
  }

  .card:not(.service-card).other:hover .image-slider {
    transform: translateY(-6px) scale(1.012);
    box-shadow: 0 16px 42px rgba(0, 0, 0, 0.42);
  }

  .product-grid .service-card:hover {
    transform: translateY(-6px) scale(1.012);
    box-shadow:
      0 5px 18px rgba(0, 0, 0, 0.065),
      0 14px 38px rgba(0, 0, 0, 0.105),
      0 26px 52px rgba(0, 0, 0, 0.065);
  }
}

.service-header {
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  width: 100%;
  box-sizing: border-box;
}

.service-header h3 {
  margin: 0;
  font-size: 22px;
  width: 100%;
  text-align: center;
  line-height: 1.25;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3),
    0 6px 12px rgba(0, 0, 0, 0.15);
}

.service-hint {
  font-size: 12px;
  opacity: 0.6;
  color: #3d2012;
  display: block;
  width: 100%;
  max-width: 28em;
  margin: 0 auto;
  text-align: center;
  line-height: 1.35;
}

.service-details {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  padding: 0 14px;
  transition: max-height 0.35s ease, opacity 0.35s ease, padding 0.35s ease;
}

.service-card.open {
  z-index: 5;
}

.service-card.open .service-details {
  max-height: 500px;
  opacity: 1;
  padding: 10px 14px 14px;
}

.service-table-header {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  font-size: 16px;
  margin-top: 10px;
  margin-bottom: 6px;
  column-gap: 12px;
  color: #fef7e5;
}

.service-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  font-size: 13px;
  padding: 8px 0;
  border-top: 1px solid rgba(61, 32, 18, 0.1);
  column-gap: 12px;
  align-items: center;
}

.service-col {
  min-width: 0;
  word-break: break-word;
}

.service-col-model {
  text-align: left;
  justify-self: stretch;
}

.service-col-original {
  text-align: center;
  justify-self: stretch;
}

.service-col-yan {
  text-align: right;
  justify-self: stretch;
}

@media (max-width: 500px) {
  .product-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 36px;
    padding: 16px 16px 44px;
  }

  .card:not(.service-card) {
    width: 90%;
    max-width: 340px;
    border-radius: 16px;
  }

  .card:not(.service-card).other {
    width: min(300px, 100%);
    max-width: 340px;
  }

  .card:not(.service-card):not(.other) .image-slider {
    height: min(400px, 62vh);
  }

  .card:not(.service-card).other .image-slider {
    height: min(400px, 62vh);
  }

  .product-grid .service-card {
    width: min(400px, 94vw);
  }
}
