@layer base{html,body{width:100%;margin:0;padding:0;min-height:100%;}body{overscroll-behavior-y:none;-webkit-tap-highlight-color:transparent;}*,*::before,*::after{box-sizing:border-box;}.pb-safe{padding-bottom:env(safe-area-inset-bottom,0px);}.pt-safe{padding-top:env(safe-area-inset-top,0px);}}
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* Tactile 3D Bevel and Depth */
.tactile-3d-card {
  box-shadow: 0 4px 14px -2px rgba(6, 19, 34, 0.06), 0 1px 3px 0 rgba(6, 19, 34, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.tactile-3d-card:active {
  transform: translateY(1px);
  box-shadow: 0 2px 6px -1px rgba(6, 19, 34, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

/* Premium 3D Packaging Showroom Cards */
.box-showroom-card {
  background: linear-gradient(178deg, #ffffff 0%, #fbf8f3 100%);
  border: 1px solid rgba(196, 198, 204, 0.55);
  border-bottom: 3.5px solid #d4c8b9;
  box-shadow: 0 8px 20px -4px rgba(27, 40, 56, 0.07), 0 2px 6px -1px rgba(27, 40, 56, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.95);
  transition: all 0.22s cubic-bezier(0.2, 0.8, 0.25, 1);
  position: relative;
  overflow: hidden;
}

.box-showroom-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px -5px rgba(27, 40, 56, 0.1), 0 4px 8px -2px rgba(27, 40, 56, 0.06), inset 0 1px 0 rgba(255, 255, 255, 1);
}

.box-showroom-card:active {
  transform: translateY(1px);
  border-bottom: 1.5px solid #c2b5a5;
  box-shadow: 0 3px 8px -1px rgba(27, 40, 56, 0.08), inset 0 1px 2px rgba(0,0,0,0.04);
}

/* Active 3D Card State (Elevated Amber Glow & Thick Edge) */
.box-showroom-card.is-active-box {
  background: linear-gradient(175deg, #fffcf7 0%, #f9f1e4 100%);
  border: 1.5px solid #b87333;
  border-bottom: 4px solid #8f551b;
  box-shadow: 0 14px 28px -6px rgba(151, 71, 36, 0.22), 0 4px 10px -2px rgba(151, 71, 36, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.95), inset 3px 0 0 #b87333;
  transform: translateY(-2px);
}

/* Tactile 3D Keycap Price Chips */
.keycap-price-chip {
  transition: all 0.15s cubic-bezier(0.2, 0.8, 0.25, 1);
  position: relative;
  user-select: none;
}
.keycap-price-chip:active {
  transform: translateY(2px) !important;
  box-shadow: 0 1px 0 rgba(0,0,0,0.15) !important;
}

.keycap-kraft {
  background: linear-gradient(180deg, #f7e6cd 0%, #ecd4b0 100%);
  border: 1px solid #d4b589;
  border-bottom: 2.5px solid #ad834c;
  box-shadow: 0 2px 4px rgba(130, 85, 30, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.keycap-beyaz {
  background: linear-gradient(180deg, #ffffff 0%, #f1eee9 100%);
  border: 1px solid #d8d3ca;
  border-bottom: 2.5px solid #beb5a6;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05), inset 0 1px 0 rgba(255, 255, 255, 1);
}

.keycap-renkli {
  background: linear-gradient(180deg, #ffede3 0%, #ffd9c9 100%);
  border: 1px solid #f3b092;
  border-bottom: 2.5px solid #c86337;
  box-shadow: 0 2px 4px rgba(151, 71, 36, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

/* 3D Acrylic Deep Push Button */
.btn-tactile-3d {
  background: linear-gradient(180deg, #1b2838 0%, #0c1724 100%);
  border: 1px solid #233449;
  border-bottom: 3.5px solid #060c13;
  box-shadow: 0 4px 10px rgba(6, 19, 34, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: all 0.15s ease;
}
.btn-tactile-3d:hover {
  filter: brightness(1.08);
}
.btn-tactile-3d:active {
  transform: translateY(2px);
  border-bottom-width: 1.5px;
  box-shadow: 0 2px 4px rgba(6, 19, 34, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.btn-tactile-secondary {
  background: linear-gradient(180deg, #f2ede7 0%, #e6dfd5 100%);
  border: 1px solid #d3cac0;
  border-bottom: 3px solid #b5a99c;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: all 0.15s ease;
}
.btn-tactile-secondary:active {
  transform: translateY(2px);
  border-bottom-width: 1.5px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

/* Modal Open Transition State */
.modal-active {
  opacity: 1 !important;
  pointer-events: auto !important;
}
.modal-active #orderModalSheet,
.modal-active #cartModalSheet {
  transform: scale(1) translateY(0) !important;
}

/* Güncelle + son saat tek kutu. Simge kutunun sol başında sabit; iki yazı ortak eksende ortalı. */
.refresh-unit {
  box-sizing: border-box;   /* Tailwind preflight yüklenmese de kutu taşmasın */
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.1rem;
  width: 100%;
  max-width: 100%;
  padding: 0.4rem 0.7rem 0.45rem;
  border-radius: 0.85rem;
  background: linear-gradient(180deg, #ffffff 0%, #f7f2ea 100%);
  border: 1px solid #dcd4c8;
  border-bottom: 3px solid #bfae99;
  box-shadow: 0 3px 8px rgba(27, 40, 56, 0.08), inset 0 1px 0 #ffffff;
}
@media (min-width: 640px) {
  .refresh-unit {
    width: auto;
    min-width: 15.5rem;
    max-width: 24rem;
  }
}
.refresh-unit button {
  box-sizing: border-box;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin: 0;
  padding: 0 1.15rem;
  background: none;
  border: 0;
  box-shadow: none;
  color: #974724;
}
.refresh-unit button .material-symbols-outlined {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
  width: 16px;
  font-size: 16px;
  line-height: 1;
}
.refresh-unit button:active {
  transform: none;
}
.refresh-unit:has(button:active) {
  transform: translateY(1px);
  border-bottom-width: 1.5px;
}
.refresh-unit > span {
  display: block;
  text-align: center;
  line-height: 1.25;
  white-space: normal;
}

/* Mobil: simge iki yazının tam ortasında, yazılar bir tık büyük. Diğer ekranlarda düz kalır. */
@media (max-width: 639.98px) {
  .refresh-unit {
    position: relative;   /* simgenin konumlandırma referansı tüm kutu olsun */
    gap: 0.15rem;
    /* Üst 1px + alt 3px kenarlık: 1+8px = 3+6px, yazı bloğu kutunun tam ortasına oturur. */
    padding: 0.5rem 0.75rem 0.375rem;
  }
  .refresh-unit button {
    position: static;     /* mutlak simge, buton yerine kutuya göre hizalanır */
    padding: 0 1.6rem;
    font-size: 12px;
  }
  .refresh-unit button .material-symbols-outlined {
    position: absolute;
    left: 0.75rem;        /* kutunun iç boşluğuyla aynı hizada */
    /* Üst 1px + alt 3px kenarlık asimetrisini dengeleyip iki satırın tam ortasına oturtur. */
    top: 50%;
    transform: translateY(calc(-50% + 1px));
    width: 22px;
    height: 22px;
    font-size: 22px;
    line-height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .refresh-unit > span {
    font-size: 12px;
  }
}

/* Kraft / Beyaz / Renkli her ekranda aynı kutu ölçüsünde, 3’lü. */
#priceLegend {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.375rem;
  width: max-content;
  max-width: 100%;
}
#priceLegend > span {
  justify-content: center;
  width: 100%;
  min-width: 0;
  min-height: 2.25rem;
  padding-left: 0.35rem;
  padding-right: 0.35rem;
  text-align: center;
  line-height: 1.15;
  white-space: normal;
}
@media (max-width: 639.98px) {
  #catalogToolbar {
    flex-direction: column;
    align-items: center;
  }
  #priceLegend {
    width: 100%;
  }
}

/* 320–374: 375px düzeni ekran oranıyla küçülür. 375–639: yazı ve kart o ölçüde kalır. */
@media (max-width: 639.98px) {
  header > div.max-w-7xl,
  main > div.max-w-7xl,
  nav.fixed > div {
    max-width: 375px;
  }
}
@media (max-width: 374.98px) {
  html {
    zoom: calc(100vw / 375px);
  }
}

/* Ürün galerisi: telefonda 3 sütun, tablet ve üstünde 6 sütun. Çerçeve 2:3. */
#productGallery .gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.625rem;
}
@media (min-width: 768px) {
  #productGallery .gallery-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}
#productGallery .gallery-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 2 / 3;
}
/* Görsel çerçeveyi tamamen doldurur; Tailwind preflight/sınıfları yüklenmese de taşmaz. */
#productGallery .gallery-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Ürün galerisi: kareler yer değiştirirken kısa solma */
#productGallery img {
  transition: opacity 220ms ease, transform 300ms ease;
}
#productGallery img.is-swapping {
  opacity: 0;
}
@media (prefers-reduced-motion: reduce) {
  #productGallery img { transition: none; }
}
