.mt-font-search,
.mt-font-search * {
  box-sizing: border-box;
}

.mt-font-search {
  --mt-black: #030303;
  --mt-cream: #f5f2ea;
  --mt-text: #1d1d1d;
  --mt-muted: rgba(29, 29, 29, 0.48);
  --mt-line: rgba(255, 255, 255, 0.08);
  --mt-orange: #ff3b0a;
  --mt-radius: 12px;
  width: 100%;
  overflow: hidden;
  color: var(--mt-text);
}

.mt-search-hero {
  background: var(--mt-black);
  color: #fff;
  padding: clamp(48px, 7vw, 86px) clamp(20px, 5.5vw, 72px) clamp(54px, 8vw, 92px);
}

.mt-search-intro {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: clamp(42px, 6vw, 72px);
}

.mt-search-eyebrow {
  margin: 0;
  font-size: clamp(16px, 1.55vw, 22px);
  line-height: 1.25;
  color: rgba(255, 255, 255, 0.88);
}

.mt-search-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--mt-orange);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 220ms ease, background-color 220ms ease;
}

.mt-search-cta:hover {
  color: #fff;
  transform: translateY(-2px);
  background: #ff4e22;
}

.mt-search-form {
  position: relative;
  display: flex;
  align-items: center;
  gap: clamp(16px, 2vw, 24px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  transition: border-color 220ms ease;
}

.mt-font-search.is-focused .mt-search-form {
  border-color: rgba(255, 255, 255, 0.42);
}

.mt-search-icon {
  width: clamp(42px, 5.2vw, 62px);
  height: clamp(42px, 5.2vw, 62px);
  flex: 0 0 auto;
  border: 4px solid #fff;
  border-radius: 50%;
  opacity: 0.96;
  position: relative;
  transform: rotate(-45deg);
  transition: transform 300ms ease, opacity 300ms ease;
}

.mt-search-icon::after {
  content: "";
  position: absolute;
  width: 4px;
  height: 24px;
  left: 50%;
  top: 100%;
  background: #fff;
  border-radius: 10px;
  transform: translateX(-50%);
}

.mt-font-search.is-focused .mt-search-icon {
  transform: rotate(-45deg) scale(0.92);
  opacity: 1;
}

.mt-search-input {
  width: 100%;
  min-height: clamp(74px, 9vw, 104px);
  border: 0;
  outline: 0;
  background: transparent;
  color: #fff;
  font-size: clamp(46px, 7vw, 82px);
  line-height: 1;
  letter-spacing: -0.06em;
  font-weight: 500;
}

.mt-search-input::placeholder {
  color: rgba(255, 255, 255, 0.10);
  opacity: 1;
}

.mt-search-clear {
  position: absolute;
  right: 0;
  bottom: 24px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 12px;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 180ms ease, transform 180ms ease, background-color 180ms ease;
}

.mt-font-search.has-keyword .mt-search-clear {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.mt-results-area {
  background: var(--mt-cream);
  padding: clamp(42px, 6vw, 78px) clamp(20px, 5.5vw, 72px) clamp(54px, 7vw, 90px);
}

.mt-results-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: clamp(28px, 3.2vw, 42px);
}

.mt-results-title {
  margin: 0;
  color: var(--mt-text);
  font-size: clamp(34px, 4vw, 52px);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.mt-results-meta {
  margin: 0;
  color: var(--mt-muted);
  font-size: 14px;
}

.mt-grid-shell {
  position: relative;
}

.mt-product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(22px, 2.2vw, 30px) 16px;
  transition: opacity 220ms ease, filter 220ms ease, transform 220ms ease;
}

.mt-font-search.is-searching .mt-product-grid {
  opacity: 0.24;
  filter: blur(2px);
  transform: translateY(4px);
  pointer-events: none;
}

.mt-product-card {
  min-width: 0;
  opacity: 1;
}

.mt-product-card.is-visible {
  animation: mt-card-reveal 460ms cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: var(--mt-stagger, 0ms);
}

@keyframes mt-card-reveal {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.mt-product-media {
  position: relative;
  display: block;
  aspect-ratio: 1.5 / 1;
  overflow: hidden;
  border-radius: var(--mt-radius);
  background: rgba(0, 0, 0, 0.06);
  transform: translateZ(0);
}

.mt-product-img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  display: block;
  transition: transform 520ms cubic-bezier(0.22, 1, 0.36, 1), filter 520ms ease;
}

.mt-product-card:hover .mt-product-img {
  transform: scale(1.055);
  filter: saturate(1.03);
}

.mt-product-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: #ff1414;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: -0.02em;
  transition: transform 240ms ease;
}

.mt-product-card:hover .mt-product-badge {
  transform: scale(1.07) rotate(5deg);
}

.mt-product-badge.is-sale {
  font-size: 10px;
}

.mt-product-info {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 6px 0;
}

.mt-product-main {
  min-width: 0;
}

.mt-product-title {
  display: block;
  color: var(--mt-text);
  font-size: clamp(15px, 1.2vw, 18px);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.045em;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mt-product-title:hover {
  color: var(--mt-orange);
}

.mt-product-category {
  display: block;
  margin-top: 8px;
  color: rgba(29, 29, 29, 0.42);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mt-product-price {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.06);
  color: var(--mt-text);
  font-size: 15px;
  font-weight: 900;
  line-height: 1;
  transition: transform 220ms ease, background-color 220ms ease;
}

.mt-product-card:hover .mt-product-price {
  transform: translateY(-2px);
  background: rgba(0, 0, 0, 0.09);
}

.mt-product-price del {
  display: none;
}

.mt-product-price ins {
  text-decoration: none;
}

.mt-grid-loader {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: center;
  padding-top: clamp(58px, 7vw, 96px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.mt-font-search.is-searching .mt-grid-loader {
  opacity: 1;
}

.mt-loader-inner {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  background: rgba(245, 242, 234, 0.82);
  color: var(--mt-text);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(10px);
}

.mt-loader-word {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.16em;
}

.mt-loader-dots {
  display: inline-flex;
  gap: 4px;
}

.mt-loader-dots i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--mt-orange);
  animation: mt-dot 850ms ease-in-out infinite;
}

.mt-loader-dots i:nth-child(2) {
  animation-delay: 120ms;
}

.mt-loader-dots i:nth-child(3) {
  animation-delay: 240ms;
}

@keyframes mt-dot {
  0%, 100% {
    transform: translateY(0);
    opacity: 0.35;
  }
  50% {
    transform: translateY(-4px);
    opacity: 1;
  }
}

.mt-empty-state {
  grid-column: 1 / -1;
  min-height: 260px;
  border: 1px dashed rgba(0, 0, 0, 0.14);
  border-radius: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 34px;
  color: var(--mt-text);
}

.mt-empty-icon {
  display: inline-flex;
  width: 52px;
  height: 52px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.06);
  font-size: 34px;
  margin-bottom: 14px;
}

.mt-empty-state h3 {
  margin: 0 0 8px;
  font-size: 24px;
  letter-spacing: -0.04em;
}

.mt-empty-state p {
  margin: 0;
  color: var(--mt-muted);
}

.mt-font-search-error {
  padding: 16px;
  background: #fff3f3;
  color: #9b1111;
}

@media (max-width: 1024px) {
  .mt-product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .mt-search-hero,
  .mt-results-area {
    padding-left: 18px;
    padding-right: 18px;
  }

  .mt-search-intro {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
  }

  .mt-search-form {
    gap: 12px;
  }

  .mt-search-icon {
    border-width: 3px;
  }

  .mt-search-icon::after {
    width: 3px;
    height: 18px;
  }

  .mt-search-input {
    font-size: clamp(38px, 12vw, 58px);
    min-height: 82px;
  }

  .mt-results-head {
    display: block;
  }

  .mt-results-meta {
    margin-top: 10px;
  }

  .mt-product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 12px;
  }

  .mt-product-info {
    padding-left: 2px;
    padding-right: 2px;
  }

  .mt-product-title {
    font-size: 14px;
  }

  .mt-product-category {
    font-size: 10px;
    letter-spacing: 0.18em;
  }

  .mt-product-price {
    min-height: 26px;
    font-size: 13px;
    padding: 0 8px;
  }

  .mt-product-badge {
    width: 40px;
    height: 40px;
    font-size: 10px;
    top: 8px;
    right: 8px;
  }
}

@media (max-width: 420px) {
  .mt-product-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mt-font-search *,
  .mt-font-search *::before,
  .mt-font-search *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
    scroll-behavior: auto !important;
  }
}
