/* --------------------------------------------------------------------------
   0. RESET, GLOBAL OVERRIDES & SCROLLBAR
   -------------------------------------------------------------------------- */
* {
  outline: none !important;
  scrollbar-width: thin !important;
  scrollbar-color: rgba(0, 0, 0, 0.25) transparent !important;
}

*::-webkit-scrollbar {
  width: 8px !important;
  height: 8px !important;
}

*::-webkit-scrollbar-track,
*::-webkit-scrollbar-corner {
  background: transparent !important;
}

*::-webkit-scrollbar-thumb {
  background-color: rgba(0, 0, 0, 0.25) !important;
  border-radius: 20px !important;
  border: 2px solid transparent !important;
  background-clip: content-box !important;
}

*::-webkit-scrollbar-thumb:hover {
  background-color: rgba(0, 0, 0, 0.45) !important;
}

html,
body {
  min-height: 100vh;
}

body,
.site {
  overflow-x: clip !important;
  overflow-y: visible !important;
}

.blockUI.blockOverlay {
  position: relative !important;
}

.blockUI.blockOverlay::after {
  content: "" !important;
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  width: 26px !important;
  height: 26px !important;
  margin: -13px 0 0 -13px !important;
  border: 3px solid rgba(28, 28, 28, 0.15) !important;
  border-top-color: #1c1c1c !important;
  border-radius: 50% !important;
  animation: storefront-child-spin 0.7s linear infinite !important;
}

/* İKİNCİ SPINNER'I BASTIR
   WooCommerce çekirdeği (loader.svg) ve bazı eklentiler / üst tema, aynı
   bloklama katmanına `::before` üzerinden kendi dönen göstergesini ekliyor.
   Tema kendi tek göstergesini yukarıdaki `::after` ile çizdiği için,
   `::before` kaynaklı ikinci daireyi tamamen kaldırıyoruz. */
.blockUI.blockOverlay::before {
  content: none !important;
  display: none !important;
  background: none !important;
  border: 0 !important;
  animation: none !important;
}

@keyframes storefront-child-spin {
  to {
    transform: rotate(360deg);
  }
}

#page.site {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

#content.site-content {
  flex: 1 0 auto;
}

/* ==========================================================================
   1. FONT DEFINITIONS (@font-face) & ASSIGNMENTS
   ========================================================================== */
@font-face {
  font-family: "Montserrat";
  src: url("../fonts/Montserrat/Montserrat-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: optional;
}

@font-face {
  font-family: "Montserrat";
  src: url("../fonts/Montserrat/Montserrat-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: optional;
}

@font-face {
  font-family: "Montserrat";
  src: url("../fonts/Montserrat/Montserrat-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: optional;
}

@font-face {
  font-family: "Montserrat";
  src: url("../fonts/Montserrat/Montserrat-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: optional;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter/Inter-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: optional;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter/Inter-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: optional;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter/Inter-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: optional;
}

@font-face {
  font-family: "Inter";
  src: url("../fonts/Inter/Inter-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: optional;
}

/* A. Default Body Font */
body,
p,
li,
span:not(.ab-icon),
div,
td,
th,
label,
textarea,
select,
.site-info,
.tabbar a,
.sub-menu a,
a:not(.button):not(.header-account-link) {
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    sans-serif !important;
}

/* B. Headings */
h1,
h2,
h3,
h4,
h5,
h6,
.site-title,
.entry-title,
.widget-title,
.product_title {
  font-family:
    "Montserrat",
    -apple-system,
    BlinkMacSystemFont,
    sans-serif !important;
}

/* C. Interactive Elements */
button,
input[type="submit"],
input[type="button"],
.button,
.added_to_cart,
.main-navigation a,
.menu-item a,
.header-actions a,
.site-search input,
.site legend {
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    sans-serif !important;
}

/* D. Admin Bar Icon Preservation */
#wpadminbar .ab-icon,
#wpadminbar .ab-icon::before,
#wpadminbar .ab-item::before {
  font-family: dashicons !important;
}

/* ==========================================================================
   13. ADMIN BAR OFFSET PROTECTION
   ========================================================================== */
body.admin-bar .side-cart-panel,
body.admin-bar .fullscreen-mobile-menu {
  top: 32px !important;
  height: calc(100vh - 32px) !important;
}

@media screen and (max-width: 782px) {
  body.admin-bar .side-cart-panel,
  body.admin-bar .fullscreen-mobile-menu {
    top: 46px !important;
    height: calc(100vh - 46px) !important;
  }
}
