/* =========================================================
   MERCHANT DISCOVERY PORTAL
========================================================= */

.merchant-discovery-portal {
  position: relative;
  padding: 2rem 0 4rem;
}

.merchant-discovery-base {
  position: relative;
  z-index: 1;
}

.merchant-discovery-stack {
  position: relative;
  z-index: 5;
}


/* =========================================================
   HERO BASE LAYER
========================================================= */

.merchant-hero-shell {
  position: relative;
  padding: 24px;
  border-radius: 18px;
  overflow: hidden;
  background:
    radial-gradient(
      circle at 90% 12%,
      rgba(var(--ccc-cyan-glow-rgb), 0.18),
      transparent 28%
    ),
    linear-gradient(
      90deg,
      rgba(var(--ccc-blue-rgb), 0.04),
      rgba(var(--ccc-green-rgb), 0.04)
    );
}

.merchant-hero-shell::before {
  content: "";
  position: absolute;
  inset: auto 24px 18px 24px;
  height: 12px;
  border-radius: 999px;
  background: rgba(0,0,0,0.08);
  filter: blur(10px);
  pointer-events: none;
}

.merchant-hero-grid {
  position: relative;
  z-index: 2;
}

.merchant-hero-primary {
  min-height: 300px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.merchant-hero-kicker {
  width: fit-content;
  margin-bottom: 0.6rem;
  color: var(--ccc-text-muted);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.merchant-hero-type {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  width: fit-content;
  margin-bottom: 1rem;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  background: rgba(var(--ccc-green-rgb), 0.12);
  color: var(--ccc-green-dark);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.merchant-hero-title {
  margin: 0;
  color: var(--ccc-burgundy);
  font-family: 'Russo One', sans-serif;
  font-size: clamp(2.35rem, 5vw, 4.7rem);
  line-height: 0.95;
}

.merchant-hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.25rem;
}

.merchant-hero-tags a {
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.82);
  border: 1px solid rgba(0,0,0,0.08);
  color: var(--ccc-shell-dark);
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
}

.merchant-hero-tags a:hover {
  color: var(--ccc-burgundy);
}

.merchant-hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.merchant-hero-stats div {
  padding: 0.85rem;
  border-radius: 14px;
  background: rgba(255,255,255,0.72);
  border: 1px solid rgba(0,0,0,0.06);
  text-align: center;
}

.merchant-hero-stats strong,
.merchant-hero-stats span {
  display: block;
}

.merchant-hero-stats strong {
  color: var(--ccc-burgundy);
  font-family: 'Russo One', sans-serif;
  font-size: 1.45rem;
  line-height: 1;
}

.merchant-hero-stats span {
  margin-top: 0.25rem;
  color: var(--ccc-text-muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.merchant-hero-explore-cue {
  margin-top: 1.2rem;
  color: var(--ccc-shell-dark);
  font-size: 0.92rem;
  font-weight: 700;
  opacity: 0.78;
}

.merchant-hero-explore-cue i {
  margin-right: 0.4rem;
  color: var(--ccc-green-dark);
}

.merchant-hero-image-card {
  position: relative;
  height: 100%;
  min-height: 330px;
  border-radius: 18px;
  overflow: hidden;
  background:
    linear-gradient(145deg, #23232a, #151515);
  box-shadow:
    0 16px 34px rgba(0,0,0,0.14),
    inset 0 0 18px rgba(255,255,255,0.08);
}

.merchant-hero-image-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      to top,
      rgba(0,0,0,0.42),
      rgba(0,0,0,0.02) 58%
    );
  pointer-events: none;
}

.merchant-hero-image-card img {
  width: 100%;
  height: 100%;
  min-height: 330px;
  object-fit: cover;
  display: block;
}

.merchant-hero-placeholder {
  height: 100%;
  min-height: 330px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  color: rgba(255,255,255,0.82);
}

.merchant-hero-placeholder i {
  font-size: 2.25rem;
}

.merchant-hero-placeholder span {
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.merchant-hero-table-label {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 2;
  padding: 0.75rem 0.9rem;
  border-radius: 14px;
  background: rgba(255,255,255,0.88);
  color: var(--ccc-shell-dark);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
  box-shadow: 0 8px 18px rgba(0,0,0,0.14);
}


/* =========================================================
   DISCOVERY STACK OVER HERO
========================================================= */

.merchant-discovery-base {
  position: relative;
}

.merchant-discovery-stack {
  position: absolute;
  inset: 0;
  z-index: 20;
  pointer-events: none;
}


/* =========================================================
   DISCOVERY TAB RAIL
========================================================= */

.merchant-discovery-controls {
  position: absolute;
  top: 2.5rem;
  bottom: 1.5rem;
  
  z-index: 24;

  width: 190px;
  left: calc(1.5rem + 82% - 46px);

  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.55rem;

  pointer-events: auto;
  
  background-color: #eee;
  border-radius: 30px;
}

.merchant-discovery-choice {
  width: 160px;
  min-height: 52px;
  padding: 0.55rem 0.75rem;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;

  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 0 999px 999px 0;

  background: rgba(255,255,255,1);
  color: var(--ccc-shell-dark);

  font-size: 0.85rem;
  font-weight: 900;
  text-align: left;
  cursor: pointer;

  /* box-shadow: 0 6px 14px rgba(0,0,0,0.12); */

  transition:
    background 0.18s ease,
    color 0.18s ease;
}

.merchant-discovery-choice:hover,
.merchant-discovery-choice.is-active {
  background: var(--ccc-burgundy);
  color: #fff;
}

.merchant-discovery-choice {
  display: grid;
  grid-template-columns: 1fr 46px;
  align-items: center;
  column-gap: 0.65rem;

  width: 190px;
  min-height: 56px;
  padding: 0.55rem 0.65rem 0.55rem 0.85rem;
}

.merchant-discovery-choice .choice-label {
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
}

.merchant-discovery-choice .choice-icon {
  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 1.45rem;
  line-height: 1;
}


/* =========================================================
   DISCOVERY PANELS
========================================================= */

.merchant-discovery-stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 18px;
  pointer-events: none;
}

.merchant-discovery-panel {
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;

  width: 90%;
  min-height: calc(100% - 3rem);

  border-radius: 18px;

  background:
    linear-gradient(
      145deg,
      rgba(255,255,255,1),
      rgba(246,246,246,1)
    );

  /* 
box-shadow:
    0 18px 38px rgba(0,0,0,0.18),
    inset 0 0 18px rgba(255,255,255,0.45);
 */

  transform: translateX(-112%);
  opacity: 1;
  pointer-events: none;

  transition:
    transform 0.48s ease,
    opacity 0.22s ease;
}

.merchant-discovery-panel.is-active {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
  z-index: 25;
}

.merchant-discovery-panel-inner {
  min-height: 100%;
  padding: 1.35rem 5.5rem 1.35rem 1.35rem;
}

.merchant-panel-kicker {
  margin-bottom: 0.35rem;
  color: var(--ccc-text-muted);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.merchant-discovery-panel h2 {
  margin-bottom: 0.75rem;
  color: var(--ccc-burgundy);
  font-family: 'Russo One', sans-serif;
}

.merchant-discovery-panel img {
  max-width: 100%;
  border-radius: 15px;
}

.merchant-discovery-close {
  margin-top: 1rem;
  border-top: 2px solid rgba(0,0,0,0.1);
}

.merchant-discovery-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;

  margin-top: 1.25rem;
  padding-top: 1rem;

  border-top: 1px solid rgba(0,0,0,0.08);
}

.merchant-discovery-nav button {
  padding: 0.65rem 0.95rem;
  border: 0;
  border-radius: 999px;

  background: var(--ccc-burgundy);
  color: #fff;

  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
}

.merchant-discovery-nav span {
  color: var(--ccc-text-muted);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}


/* =========================================================
   MOBILE DISCOVERY PANELS
========================================================= */

@media only screen and (max-width: 40em) {

  .merchant-discovery-controls {
    width: 150px;
    left: calc(1rem + 62% - 38px);
    background-color: none;
  }

  .merchant-discovery-choice {
    width: 150px;
    grid-template-columns: 1fr 38px;
    min-height: 48px;
    padding: 0.4rem 0.45rem 0.4rem 0.65rem;
  }

  .merchant-discovery-choice .choice-icon {
    font-size: 1.25rem;
  }

  .merchant-discovery-panel {
    top: 1rem;
    left: 1rem;

    width: 80%;
    min-height: calc(100% - 2rem);
  }

  .merchant-discovery-panel-inner {
    padding: 1rem;
  }
  
  #Main {
    margin: 5px;
  }
  .grid-container {
    padding:0;
  }
}

