/* Gate 7 — Premium Marketplace homepage
   Brand via --primary-color / --heading-color from styles.blade.php
   Scoped under .mp-home / .mp-hero / .mp-card — does not affect Sales Landing
*/

.mp-preview-banner {
  position: sticky;
  top: 0;
  z-index: 1040;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1rem;
  background: #0a0a0a;
  color: #fafafa;
  font-size: 0.875rem;
  text-align: center;
}

.mp-preview-banner strong {
  color: #93c5fd;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* —— Hero —— */
.mp-hero {
  --mp-hero-fg: #f8fafc;
  position: relative;
  isolation: isolate;
  min-height: clamp(320px, 52vh, 560px);
  max-height: 620px;
  display: flex;
  align-items: flex-end;
  padding: 5.5rem 0 2.25rem;
  color: var(--mp-hero-fg);
  background:
    linear-gradient(145deg, #0a0a0a 0%, #18181b 55%, color-mix(in srgb, var(--primary-color, #167dfe) 35%, #0a0a0a) 100%);
  overflow: hidden;
}

.mp-hero--event::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: var(--mp-hero-image);
  background-size: cover;
  background-position: center;
  transform: scale(1.02);
}

.mp-hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  pointer-events: none;
}

.mp-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: #030712;
  pointer-events: none;
}

.mp-hero__inner {
  position: relative;
  z-index: 2;
  width: 100%;
}

.mp-hero__eyebrow {
  margin: 0 0 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.85;
}

.mp-hero__title {
  margin: 0 0 0.85rem;
  max-width: 18ch;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 750;
  line-height: 1.15;
  color: inherit;
  letter-spacing: -0.02em;
}

.mp-hero__lead {
  max-width: 36rem;
  margin: 0 0 1.25rem;
  font-size: 1.05rem;
  opacity: 0.9;
}

.mp-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.15rem;
  margin: 0 0 1.25rem;
  padding: 0;
  list-style: none;
  font-size: 0.925rem;
  opacity: 0.92;
}

.mp-hero__meta i {
  margin-right: 0.4rem;
  opacity: 0.8;
}

.mp-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 1.35rem;
}

/* —— Buttons —— */
.mp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 44px;
  padding: 0.65rem 1.15rem;
  border-radius: 0.75rem;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.925rem;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.mp-btn--primary {
  background: var(--primary-color, #167dfe);
  color: #fff;
  box-shadow: 0 8px 24px color-mix(in srgb, var(--primary-color, #167dfe) 35%, transparent);
}

.mp-btn--primary:hover,
.mp-btn--primary:focus {
  color: #fff;
  transform: translateY(-1px);
  text-decoration: none;
}

.mp-btn--ghost {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.28);
  color: #fff;
  backdrop-filter: blur(8px);
}

.mp-btn--ghost:hover,
.mp-btn--ghost:focus {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  text-decoration: none;
}

/* —— Search —— */
.mp-search {
  display: grid;
  grid-template-columns: minmax(120px, 180px) 1fr auto;
  gap: 0.5rem;
  padding: 0.5rem;
  margin-bottom: 1rem;
  background: rgba(255, 255, 255, 0.96);
  border-radius: 1rem;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
  color: #0f172a;
}

.mp-search__field select,
.mp-search__field input {
  width: 100%;
  min-height: 44px;
  border: 1px solid #e2e8f0;
  border-radius: 0.65rem;
  padding: 0.5rem 0.75rem;
  background: #fff;
  font-size: 0.95rem;
}

.mp-search__field select:focus,
.mp-search__field input:focus {
  outline: none;
  border-color: var(--primary-color, #167dfe);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary-color, #167dfe) 25%, transparent);
}

.mp-search__submit span {
  display: inline;
}

.mp-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.mp-chip {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 550;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.mp-chip:hover,
.mp-chip:focus {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  text-decoration: none;
}

/* —— Sections —— */
.mp-home {
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 40%, #f1f5f9 100%);
}

.mp-section {
  padding: clamp(2.5rem, 5vw, 4rem) 0;
}

.mp-section--featured {
  background: #f8fafc;
}

.mp-section--upcoming {
  background: #0a0a0a;
  color: #f8fafc;
}

.mp-section--upcoming .mp-section__head h2,
.mp-section--upcoming .mp-section__link {
  color: #f8fafc;
}

.mp-section--upcoming .mp-section__link {
  opacity: 0.85;
}

.mp-section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.mp-section__head--center {
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.mp-section__head h2 {
  margin: 0;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--heading-color, #0f172a);
}

.mp-section__head p {
  margin: 0.5rem 0 0;
  max-width: 40rem;
  color: #64748b;
}

.mp-section__link {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary-color, #167dfe);
  white-space: nowrap;
}

.mp-section__link:hover {
  text-decoration: underline;
}

/* —— Cards —— */
.mp-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
}

.mp-rail {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.mp-rail .mp-card {
  flex: 0 0 min(280px, 78vw);
  scroll-snap-align: start;
}

.mp-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 1.15rem;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.mp-section--upcoming .mp-card {
  background: #18181b;
  border-color: #27272a;
  color: #f4f4f5;
}

.mp-card__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #e2e8f0;
}

.mp-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.mp-card__date {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 3rem;
  padding: 0.35rem 0.45rem;
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.94);
  color: #0f172a;
  line-height: 1.1;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.mp-card__day {
  font-size: 1.05rem;
  font-weight: 750;
}

.mp-card__month {
  font-size: 0.65rem;
  font-weight: 650;
  letter-spacing: 0.04em;
}

.mp-card__badges {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  align-items: flex-end;
}

.mp-badge {
  display: inline-flex;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(15, 23, 42, 0.82);
  color: #fff;
}

.mp-badge--free {
  background: #16a34a;
}

.mp-badge--seat {
  background: color-mix(in srgb, var(--primary-color, #167dfe) 88%, #000);
}

.mp-card__body {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 1rem 1.05rem 1.1rem;
  flex: 1;
}

.mp-card__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
}

.mp-card__title a {
  color: inherit;
  text-decoration: none;
}

.mp-card__title a:hover {
  color: var(--primary-color, #167dfe);
}

.mp-section--upcoming .mp-card__title a:hover {
  color: #93c5fd;
}

.mp-card__meta {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.8125rem;
  color: #64748b;
}

.mp-section--upcoming .mp-card__meta {
  color: #a1a1aa;
}

.mp-card__meta i {
  width: 1rem;
  margin-right: 0.35rem;
  opacity: 0.75;
}

.mp-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: auto;
  padding-top: 0.35rem;
}

.mp-card__price-label {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--heading-color, #0f172a);
}

.mp-section--upcoming .mp-card__price-label {
  color: #fafafa;
}

.mp-card__price-label--muted {
  font-weight: 600;
  color: #64748b;
  font-size: 0.85rem;
}

.mp-card__price-was {
  display: block;
  font-size: 0.75rem;
  text-decoration: line-through;
  color: #94a3b8;
}

.mp-card__cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0.35rem 0.75rem;
  border-radius: 0.55rem;
  background: color-mix(in srgb, var(--primary-color, #167dfe) 12%, #fff);
  color: var(--primary-color, #167dfe);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  text-transform: uppercase;
}

.mp-card__cta:hover {
  background: var(--primary-color, #167dfe);
  color: #fff;
  text-decoration: none;
}

@media (hover: hover) and (pointer: fine) {
  .mp-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.1);
  }

  .mp-card:hover .mp-card__img {
    transform: scale(1.03);
  }
}

/* —— Categories —— */
.mp-cat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.85rem;
}

.mp-cat-card {
  position: relative;
  display: block;
  aspect-ratio: 5 / 3;
  border-radius: 1rem;
  overflow: hidden;
  background: #0f172a;
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
}

.mp-cat-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.mp-cat-card__name {
  position: absolute;
  left: 0.9rem;
  bottom: 0.85rem;
  right: 0.9rem;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

.mp-cat-card:hover img {
  transform: scale(1.04);
  opacity: 0.85;
}

/* —— Organizers —— */
.mp-org-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.mp-org-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.85rem;
  align-items: center;
  padding: 1rem;
  border-radius: 1rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.mp-org-card:hover {
  border-color: color-mix(in srgb, var(--primary-color, #167dfe) 40%, #e2e8f0);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
  text-decoration: none;
  color: inherit;
}

.mp-org-card__logo {
  width: 52px;
  height: 52px;
  border-radius: 0.85rem;
  overflow: hidden;
  background: #e2e8f0;
  display: grid;
  place-items: center;
  font-weight: 750;
  color: #475569;
}

.mp-org-card__logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mp-org-card__meta strong {
  display: block;
  font-size: 0.95rem;
}

.mp-org-card__meta span {
  font-size: 0.8rem;
  color: #64748b;
}

.mp-org-card__cta {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary-color, #167dfe);
  white-space: nowrap;
}

/* —— Trust / about / how —— */
.mp-trust-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem 1.75rem;
  border-radius: 1.25rem;
  background: linear-gradient(120deg, #0f172a, color-mix(in srgb, var(--primary-color, #167dfe) 55%, #0f172a));
  color: #fff;
}

.mp-trust-band h2 {
  margin: 0 0 0.35rem;
  color: inherit;
  font-size: 1.35rem;
}

.mp-trust-band p {
  margin: 0;
  opacity: 0.9;
}

.mp-trust-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.mp-trust-item {
  padding: 1.25rem;
  border-radius: 1rem;
  background: #fff;
  border: 1px solid #e2e8f0;
}

.mp-trust-item__icon {
  display: inline-grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 0.75rem;
  border-radius: 0.75rem;
  background: color-mix(in srgb, var(--primary-color, #167dfe) 14%, #fff);
  color: var(--primary-color, #167dfe);
}

.mp-trust-item h3 {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.mp-trust-item p {
  margin: 0;
  font-size: 0.9rem;
  color: #64748b;
}

.mp-about {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 2rem;
  align-items: center;
}

.mp-about__media img {
  width: 100%;
  border-radius: 1.25rem;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.1);
}

.mp-about__lead {
  color: #64748b;
  font-size: 1.05rem;
}

.mp-feature-grid,
.mp-how-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.mp-feature-item,
.mp-how-item {
  padding: 1.25rem;
  border-radius: 1rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  text-align: center;
}

.mp-feature-item i,
.mp-how-item i {
  font-size: 1.35rem;
  color: var(--primary-color, #167dfe);
  margin-bottom: 0.65rem;
}

.mp-how-item__num {
  display: inline-grid;
  place-items: center;
  width: 1.75rem;
  height: 1.75rem;
  margin-bottom: 0.5rem;
  border-radius: 999px;
  background: #0f172a;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
}

.mp-feature-item h3,
.mp-how-item h3 {
  font-size: 1rem;
  margin: 0 0 0.4rem;
}

.mp-feature-item p,
.mp-how-item p {
  margin: 0;
  font-size: 0.875rem;
  color: #64748b;
}

.mp-testimonial-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.mp-testimonial {
  margin: 0;
  padding: 1.25rem;
  border-radius: 1rem;
  background: #fff;
  border: 1px solid #e2e8f0;
}

.mp-testimonial p {
  margin: 0 0 0.85rem;
  color: #334155;
}

.mp-testimonial footer {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: 0.85rem;
  color: #64748b;
}

.mp-partner-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.25rem 2rem;
  align-items: center;
}

.mp-partner img {
  max-height: 48px;
  width: auto;
  filter: grayscale(1);
  opacity: 0.75;
  transition: filter 0.2s ease, opacity 0.2s ease;
}

.mp-partner:hover img {
  filter: none;
  opacity: 1;
}

.mp-empty {
  text-align: center;
  padding: 2.5rem 1rem;
  border-radius: 1.15rem;
  background: #fff;
  border: 1px dashed #cbd5e1;
}

.mp-empty h3 {
  margin: 0 0 0.5rem;
}

.mp-empty p {
  margin: 0 0 1rem;
  color: #64748b;
}

.mp-empty--compact {
  padding: 1.25rem;
}

/* Reveal */
.mp-reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.mp-reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .mp-reveal,
  .mp-card,
  .mp-card__img,
  .mp-btn,
  .mp-cat-card img {
    transition: none !important;
    transform: none !important;
  }

  .mp-reveal {
    opacity: 1;
  }
}

/* —— Responsive —— */
@media (max-width: 1199.98px) {
  .mp-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .mp-cat-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .mp-feature-grid,
  .mp-how-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 991.98px) {
  .mp-about {
    grid-template-columns: 1fr;
  }

  .mp-org-grid,
  .mp-trust-grid,
  .mp-testimonial-grid {
    grid-template-columns: 1fr 1fr;
  }

  .mp-hero {
    min-height: 0;
    max-height: none;
    padding-top: 4.75rem;
  }
}

@media (max-width: 767.98px) {
  .mp-search {
    grid-template-columns: 1fr;
  }

  .mp-search__submit {
    width: 100%;
  }

  .mp-grid,
  .mp-cat-grid,
  .mp-org-grid,
  .mp-trust-grid,
  .mp-testimonial-grid,
  .mp-feature-grid,
  .mp-how-grid {
    grid-template-columns: 1fr;
  }

  .mp-section__head {
    align-items: flex-start;
    flex-direction: column;
  }

  .mp-hero__title {
    max-width: none;
  }

  .mp-card--compact .mp-card__meta li:nth-child(n + 3) {
    display: none;
  }
}

/* Marketplace header polish (consumer chrome only when body has class) */
body.mp-marketplace .main-header {
  backdrop-filter: blur(10px);
}

body.mp-marketplace .header-upper {
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}
