/**
 * Ana sayfa vitrin — kartlar, bölüm başlıkları, liste görünümü
 * Mevcut koyu tema + mor aksan korunur; hiyerarşi ve boşluklar netleştirilir.
 */
:root {
  --uo-card-bg: linear-gradient(165deg, rgba(36, 46, 64, 0.95) 0%, rgba(22, 28, 40, 0.98) 100%);
  --uo-card-border: rgba(167, 130, 233, 0.22);
  --uo-card-border-hover: rgba(167, 130, 233, 0.48);
  --uo-cta: #3ecf8e;
  --uo-cta-hover: #52e0a0;
  --uo-price: #ffffff;
  --uo-price-old: rgba(173, 186, 208, 0.55);
}

/* Bölüm aralığı */
.section.section--bg,
.section {
  padding-top: 28px;
  padding-bottom: 8px;
}
.section-after-home-hero {
  padding-top: 20px !important;
}

/* Başlık şeridi */
.section__title-wrap {
  align-items: center;
  margin-bottom: 6px;
}
.section__title--boxed {
  font-size: clamp(15px, 2.2vw, 18px) !important;
  font-weight: 700 !important;
  letter-spacing: 0.02em;
  color: #fff !important;
  border-radius: 14px !important;
  border-color: rgba(167, 130, 233, 0.4) !important;
  background: linear-gradient(135deg, rgba(90, 63, 191, 0.28), rgba(167, 130, 233, 0.08)) !important;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22) !important;
  min-height: 44px !important;
}
.section__title--boxed b {
  color: #c9b4f5;
  font-weight: 800;
}
.section__nav--bg {
  border-radius: 12px !important;
  border: 1px solid rgba(167, 130, 233, 0.35) !important;
  background: rgba(255, 255, 255, 0.04) !important;
  width: 40px !important;
  height: 40px !important;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}
.section__nav--bg:hover {
  border-color: rgba(167, 130, 233, 0.7) !important;
  background: rgba(167, 130, 233, 0.16) !important;
  transform: translateY(-1px);
}
.section__view {
  color: #b8a0e8 !important;
  font-weight: 600;
  font-size: 13px;
}
.section__view:hover {
  color: #e4d6ff !important;
}

/* Bölüm atlama chip’leri */
.home-sections-boxes {
  gap: 8px !important;
  padding: 12px 0 6px !important;
  margin-bottom: 8px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  touch-action: pan-x;
}
.home-sections-boxes__item {
  border-radius: 999px !important;
  padding: 8px 14px !important;
  min-height: 34px !important;
  font-size: 12px !important;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: rgba(255, 255, 255, 0.03) !important;
  border: 1px solid rgba(153, 178, 214, 0.22) !important;
  color: #c5d2e8 !important;
}
.home-sections-boxes__item:hover {
  color: #fff !important;
  border-color: rgba(167, 130, 233, 0.55) !important;
  background: rgba(167, 130, 233, 0.14) !important;
}

/* Katalog carousel — mobil: 2 eşit kart; masaüstü: main.css sabit carousel genişliği korunur */
.section__carousel--catalog {
  padding-top: 10px;
  padding-bottom: 18px;
  overflow: hidden;
  box-sizing: border-box;
}
.section__carousel--catalog .owl-stage-outer {
  overflow: hidden;
}
.section__carousel--catalog .owl-stage {
  display: block !important; /* flex stage eşit genişliği bozar */
}
.section__carousel--catalog .owl-item {
  float: left;
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  height: auto;
  min-width: 0 !important;
  box-sizing: border-box;
}
.section__carousel--catalog .owl-item > .card,
.section__carousel--catalog .card {
  min-width: 0 !important;
  box-sizing: border-box;
  margin-left: 0 !important;
  margin-right: 0 !important;
  overflow: hidden;
}

/* Masaüstü: kartlar carousel’in sabit genişliğine sığsın (w-full şişmesin) */
@media (min-width: 768px) {
  .section__carousel--catalog .owl-item > .card,
  .section__carousel--catalog .card {
    width: 100% !important;
    max-width: 100%;
  }
}

/* Ürün kartı */
.section .card,
.section__carousel .card {
  position: relative;
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -webkit-flex-direction: column;
  flex-direction: column;
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0 0 12px;
  border-radius: 16px;
  border: 1px solid var(--uo-card-border);
  background: var(--uo-card-bg);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  transition: border-color 0.22s ease, box-shadow 0.22s ease, -webkit-transform 0.22s ease, transform 0.22s ease;
}
.section .card:hover,
.section__carousel .card:hover {
  border-color: var(--uo-card-border-hover);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.32);
}
.section .card__cover,
.section__carousel .card__cover {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  border-radius: 0;
  background: #0e1420;
  /* Safari / eski tarayıcı yedek */
  height: 0;
  padding-bottom: 133.333%; /* 3:4 */
}
@supports (aspect-ratio: 3 / 4) {
  .section .card__cover,
  .section__carousel .card__cover {
    height: auto;
    padding-bottom: 0;
    aspect-ratio: 3 / 4;
  }
}
.section .card__cover img,
.section__carousel .card__cover img {
  position: absolute;
  left: 0;
  top: 0;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  -o-object-fit: cover;
  display: block;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
  transition: -webkit-transform 0.35s ease, transform 0.35s ease;
}
.section .card__platforms,
.section__carousel .card__platforms {
  position: absolute;
  left: 8px;
  top: 8px;
  z-index: 3;
  display: flex;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
  pointer-events: none;
}
.section .card__platforms li img,
.section__carousel .card__platforms li img {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.45);
  padding: 2px;
}
.section .card__new,
.section__carousel .card__new {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 4px 8px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, #6f4fd8, #a782e9);
  box-shadow: 0 6px 14px rgba(90, 63, 191, 0.35);
}
.section .card__title,
.section__carousel .card__title {
  flex: 1 1 auto;
  padding: 12px 12px 8px;
  min-height: 72px;
}
.section .card__title h3,
.section__carousel .card__title h3 {
  margin: 0 0 8px;
  font-size: 14px;
  line-height: 1.35;
  font-weight: 600;
}
.section .card__title h3 a,
.section__carousel .card__title h3 a {
  color: #eef2fa;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  /* Safari clamp sabitleme */
  max-height: 2.7em;
}
.section .card__title h3 a:hover,
.section__carousel .card__title h3 a:hover {
  color: #c9b4f5;
}
.section .card__title > span,
.section__carousel .card__title > span {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
  color: var(--uo-price) !important;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
}
.section .card__title > span s,
.section__carousel .card__title > span s {
  color: var(--uo-price-old) !important;
  font-size: 12px;
  font-weight: 500;
  text-decoration-thickness: 1px;
}
.section .card__actions,
.section__carousel .card__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  margin-top: auto;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}
.section .card__buy,
.section__carousel .card__buy {
  flex: 1 1 auto;
  width: auto !important;
  min-width: 0;
  min-height: 42px;
  padding: 0 12px !important;
  border-radius: 11px !important;
  background: linear-gradient(180deg, var(--uo-cta-hover), var(--uo-cta)) !important;
  color: #062416 !important;
  font-weight: 800 !important;
  font-size: 12.5px !important;
  letter-spacing: 0.01em;
  line-height: 1.2 !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  border: 0 !important;
  box-shadow: 0 8px 18px rgba(62, 207, 142, 0.22);
  transition: filter 0.18s ease, transform 0.18s ease;
}
.section .card__buy:hover,
.section__carousel .card__buy:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
}
.section .card__favorite,
.section__carousel .card__favorite {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  border-radius: 11px !important;
  border: 1px solid rgba(153, 178, 214, 0.28) !important;
  background: rgba(255, 255, 255, 0.04) !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.18s ease, background 0.18s ease;
}
.section .card__favorite:hover,
.section__carousel .card__favorite:hover {
  border-color: rgba(232, 83, 71, 0.55) !important;
  background: rgba(232, 83, 71, 0.12) !important;
}
.section .card__favorite svg,
.section__carousel .card__favorite svg {
  width: 18px;
  height: 18px;
  stroke: #c5d2e8;
}

/* Üç kolon liste */
.list--mb {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.list__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 14px;
  border: 1px solid rgba(153, 178, 214, 0.18);
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}
.list__item:hover {
  border-color: rgba(167, 130, 233, 0.4);
  background: rgba(167, 130, 233, 0.08);
  transform: translateY(-1px);
}
.list__cover {
  flex: 0 0 56px;
  width: 56px;
  height: 56px;
  border-radius: 10px;
  overflow: hidden;
  background: #0e1420;
}
.list__cover img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
}
.list__wrap {
  flex: 1;
  min-width: 0;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  column-gap: 10px;
  align-items: center;
}
.list__title {
  grid-column: 1;
  margin: 0;
  font-size: 13px;
  line-height: 1.3;
}
.list__title a {
  color: #eef2fa;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.list__price {
  grid-column: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
}
.list__price s {
  color: var(--uo-price-old) !important;
  font-weight: 500;
  font-size: 11px;
}
.list__price b {
  font-size: 10px;
  font-weight: 700;
  color: #3ecf8e;
  background: rgba(62, 207, 142, 0.12);
  border: 1px solid rgba(62, 207, 142, 0.28);
  border-radius: 999px;
  padding: 2px 7px;
}
.list__buy {
  grid-column: 2;
  grid-row: 1 / span 2;
  width: 36px;
  height: 36px;
  border-radius: 10px !important;
  background: linear-gradient(180deg, var(--uo-cta-hover), var(--uo-cta)) !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 14px rgba(62, 207, 142, 0.2);
}
.list__buy svg {
  width: 16px;
  height: 16px;
  stroke: #062416;
}

@media (max-width: 767px) {
  .section.section--bg,
  .section {
    padding-top: 20px;
    padding-bottom: 4px;
  }

  .section__title-wrap {
    flex-wrap: wrap;
    gap: 8px;
  }

  .section__title--boxed {
    max-width: calc(100% - 96px);
    font-size: 14px !important;
    min-height: 40px !important;
    padding: 8px 12px 8px 14px !important;
  }

  .section__nav--bg {
    width: 44px !important;
    height: 44px !important;
  }

  .home-sections-boxes {
    margin-left: -4px;
    margin-right: -4px;
    padding-left: 4px !important;
    padding-right: 4px !important;
  }

  .home-sections-boxes__item {
    min-height: 40px !important;
    padding: 10px 14px !important;
    -webkit-tap-highlight-color: rgba(167, 130, 233, 0.25);
  }

  .section .card,
  .section__carousel .card {
    margin: 0 0 2px !important;
    border-radius: 14px;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
  }

  /* Mobil: tam 2 eşit kart; masaüstü genişliğini ezme */
  .section__carousel--catalog {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0;
    padding-right: 0;
  }
  .section__carousel--catalog .owl-item {
    -webkit-box-flex: 0;
    -webkit-flex: 0 0 auto;
    flex: 0 0 auto;
  }
  .section__carousel--catalog .owl-item > .card,
  .section__carousel--catalog .card {
    width: 100% !important;
    max-width: 100% !important;
  }

  .section .card__buy,
  .section__carousel .card__buy {
    font-size: 11px !important;
    padding: 0 8px !important;
    min-width: 0 !important;
    -webkit-box-flex: 1;
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
  }

  .section .card__cover,
  .section__carousel .card__cover {
    /* Safari eski: padding oranı yedek */
    height: 0;
    padding-bottom: 133.333%;
    aspect-ratio: auto;
  }
  @supports (aspect-ratio: 3 / 4) {
    .section .card__cover,
    .section__carousel .card__cover {
      height: auto;
      padding-bottom: 0;
      aspect-ratio: 3 / 4;
    }
  }
  .section .card__cover img,
  .section__carousel .card__cover img {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
  }

  .section .card__title,
  .section__carousel .card__title {
    min-height: 64px;
    padding: 10px 10px 6px;
  }
  .section .card__title h3,
  .section__carousel .card__title h3 {
    font-size: 13px;
  }
  .section .card__title > span,
  .section__carousel .card__title > span {
    font-size: 14px;
  }
  .section .card__actions,
  .section__carousel .card__actions {
    padding: 0 8px;
    gap: 6px;
    min-width: 0;
  }
  .section .card__buy,
  .section__carousel .card__buy {
    min-height: 44px;
    font-size: 11px !important;
    -webkit-tap-highlight-color: transparent;
  }
  .section .card__favorite,
  .section__carousel .card__favorite {
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
  }

  .list__item {
    padding: 12px;
    -webkit-tap-highlight-color: transparent;
  }
  .list__cover {
    flex: 0 0 52px;
    width: 52px;
    height: 52px;
  }
  .list__buy {
    width: 44px;
    height: 44px;
  }

  /* 3 kolon mobilde alt alta rahat */
  .section .col-md-4 + .col-md-4 {
    margin-top: 18px;
  }
}

/* Hover sadece gerçek hover cihazlarda (iOS sticky hover engeli) */
@media (hover: hover) and (pointer: fine) {
  .section .card:hover,
  .section__carousel .card:hover {
    -webkit-transform: translateY(-4px);
    transform: translateY(-4px);
    border-color: var(--uo-card-border-hover);
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.32);
  }
  .section .card:hover .card__cover img,
  .section__carousel .card:hover .card__cover img {
    -webkit-transform: scale(1.04);
    transform: scale(1.04);
  }
}

/* iPhone notch / home indicator */
@supports (padding: max(0px)) {
  .home-sections-boxes {
    padding-left: max(4px, env(safe-area-inset-left));
    padding-right: max(4px, env(safe-area-inset-right));
  }
}

/* Safari flex gap yedekleri (eski iOS) */
@supports not (gap: 8px) {
  .section .card__actions > * + *,
  .section__carousel .card__actions > * + * {
    margin-left: 8px;
  }
  .section .card__platforms li + li,
  .section__carousel .card__platforms li + li {
    margin-left: 4px;
  }
  .list--mb > .list__item + .list__item {
    margin-top: 10px;
  }
  .list__item > .list__wrap {
    margin-left: 12px;
  }
  .list__price > * + * {
    margin-left: 6px;
  }
  .home-sections-boxes__item + .home-sections-boxes__item {
    margin-left: 8px;
  }
}
