
/* =====================================================================
   AMSYNK V13.7 — UNIFIED PREMIUM MARKETPLACE CARD SYSTEM
   Healthcare + Enterprise AI Data
   Compact, procurement-oriented, category-accented, enterprise visual tone.
   ===================================================================== */

:root{
  --mp-page:#edf3f8;
  --mp-card:#fbfdff;
  --mp-card-alt:#f8fbfe;
  --mp-ink:#07182e;
  --mp-muted:#5c6f82;
  --mp-subtle:#7c8ea0;
  --mp-line:#cfdbe7;
  --mp-line-soft:#e4ebf2;
  --mp-blue:#1f63c9;
  --mp-navy:#0a2341;
  --mp-focus:rgba(36,104,232,.20);
}

/* Marketplace surfaces */
body.health-marketplace-v136,
body.enterprise-marketplace-v135,
body.health-marketplace-v136 main,
body.enterprise-marketplace-v135 main{
  background:var(--mp-page)!important;
}

.med-marketplace,
.ent-marketplace{
  background:
    linear-gradient(180deg,#eef4f8 0%,#edf3f8 50%,#eaf1f6 100%)!important;
}

/* Slightly denser toolbar system */
.med-market-toolbar,
.ent-market-toolbar{
  border-color:#ccd8e5!important;
  background:#f9fbfd!important;
  box-shadow:0 8px 22px rgba(8,31,61,.045)!important;
}

.med-market-summary,
.ent-market-summary{
  margin-top:15px!important;
  margin-bottom:10px!important;
}

/* Category navigation remains compact and readable */
.med-category-nav,
.ent-category-nav{
  gap:7px!important;
  margin-top:12px!important;
}

.med-category,
.ent-category{
  min-height:34px!important;
  padding-inline:11px!important;
  background:#f6f9fc!important;
  border-color:#cbd8e4!important;
}

.med-category:hover,
.ent-category:hover{
  background:#f1f6fb!important;
  border-color:#9fb8d5!important;
}

.med-category.is-active,
.ent-category.is-active{
  background:#e7f0fc!important;
  border-color:#6f9ed9!important;
  color:#164f91!important;
}

/* ---------------------------------------------------------------------
   Shared listing grid
   --------------------------------------------------------------------- */

.med-listing-grid,
.ent-listing-grid{
  align-items:start!important;
  gap:12px!important;
}

/* Typical desktop: 2 columns. Very wide desktop: 3 columns. */
.med-listing-card,
.ent-listing-card{
  --card-accent:#4e7eb8;
  --card-surface:#fbfdff;

  position:relative!important;
  display:flex!important;
  flex-direction:column!important;
  min-height:0!important;
  height:auto!important;
  padding:16px 17px 15px!important;
  overflow:hidden!important;

  border:1px solid #cad7e3!important;
  border-left:3px solid var(--card-accent)!important;
  border-radius:13px!important;

  background:
    linear-gradient(180deg,var(--card-surface) 0 54px,#ffffff 54px)!important;

  box-shadow:
    0 1px 0 rgba(255,255,255,.86) inset,
    0 6px 18px rgba(8,31,61,.035)!important;

  transition:
    border-color .17s ease,
    box-shadow .17s ease,
    transform .17s ease,
    background .17s ease!important;
}

.med-listing-card:hover,
.ent-listing-card:hover{
  transform:translateY(-1px)!important;
  border-color:#aabfd4!important;
  border-left-color:var(--card-accent)!important;
  box-shadow:
    0 1px 0 rgba(255,255,255,.9) inset,
    0 12px 28px rgba(8,31,61,.075)!important;
}

.med-listing-card:focus-within,
.ent-listing-card:focus-within{
  outline:3px solid var(--mp-focus)!important;
  outline-offset:2px!important;
  border-color:#8baed5!important;
  border-left-color:var(--card-accent)!important;
}

/* ---------------------------------------------------------------------
   Purposeful category accents — one small signal, not decorative noise
   --------------------------------------------------------------------- */

/* Healthcare families */
.med-listing-card[data-family="imaging"]{
  --card-accent:#2d6fb7;
  --card-surface:#f7fbff;
}
.med-listing-card[data-family="oncology"]{
  --card-accent:#5a659e;
  --card-surface:#f8f9fd;
}
.med-listing-card[data-family="clinical"]{
  --card-accent:#397a83;
  --card-surface:#f6fbfb;
}
.med-listing-card[data-family="longitudinal"]{
  --card-accent:#536f91;
  --card-surface:#f8fafc;
}
.med-listing-card[data-family="specialty"]{
  --card-accent:#6a668f;
  --card-surface:#faf9fd;
}
.med-listing-card[data-family="audio"]{
  --card-accent:#467b9d;
  --card-surface:#f7fbfd;
}
.med-listing-card[data-family="synthetic"]{
  --card-accent:#7a6d56;
  --card-surface:#fbfaf7;
}

/* Enterprise families */
.ent-listing-card[data-family="enterprise-corpora"]{
  --card-accent:#2d6fb7;
  --card-surface:#f7fbff;
}
.ent-listing-card[data-family="agent-enterprise-worlds"]{
  --card-accent:#4f6993;
  --card-surface:#f8faff;
}
.ent-listing-card[data-family="curated-hybrid"]{
  --card-accent:#397a83;
  --card-surface:#f6fbfb;
}
.ent-listing-card[data-family="software-code"]{
  --card-accent:#596b82;
  --card-surface:#f8fafc;
}
.ent-listing-card[data-family="engineering-technical"]{
  --card-accent:#675f8c;
  --card-surface:#faf9fd;
}

/* ---------------------------------------------------------------------
   Card content hierarchy
   --------------------------------------------------------------------- */

.med-card-topline,
.ent-card-topline{
  margin-bottom:10px!important;
  min-height:22px!important;
}

.med-card-id,
.ent-card-id{
  color:var(--card-accent)!important;
  font-size:.65rem!important;
  letter-spacing:.025em!important;
}

.med-card-origin,
.ent-card-origin{
  padding:5px 7px!important;
  border-color:#d5e0e9!important;
  background:rgba(245,248,251,.9)!important;
  color:#697b8c!important;
  border-radius:5px!important;
  font-size:.59rem!important;
  font-weight:740!important;
}

/* Keep synthetic / hybrid origin factual but visually neutral. */
.ent-listing-card[data-classification="synthetic"] .ent-card-origin,
.med-listing-card[data-classification="synthetic"] .med-card-origin{
  border-color:#ddd8cc!important;
  background:#faf8f3!important;
  color:#726854!important;
}

.ent-listing-card[data-classification="hybrid"] .ent-card-origin{
  border-color:#cfdedc!important;
  background:#f4faf9!important;
  color:#4f6f6d!important;
}

.med-card-heading,
.ent-card-heading{
  display:block!important;
}

.med-card-category,
.ent-card-category{
  display:flex!important;
  align-items:center!important;
  gap:7px!important;
  margin-bottom:6px!important;
  color:#6d8092!important;
  font-size:.59rem!important;
  line-height:1.2!important;
  font-weight:850!important;
  letter-spacing:.075em!important;
}

.med-card-category::before,
.ent-card-category::before{
  content:""!important;
  flex:0 0 auto!important;
  width:6px!important;
  height:6px!important;
  border-radius:2px!important;
  background:var(--card-accent)!important;
}

.med-card-heading h2,
.ent-card-heading h2{
  margin:0!important;
  max-width:none!important;
  color:var(--mp-navy)!important;
  font-size:1.23rem!important;
  line-height:1.12!important;
  letter-spacing:-.032em!important;
  text-wrap:balance!important;
}

.med-card-heading h2 a,
.ent-card-heading h2 a{
  color:var(--mp-navy)!important;
}

.med-card-heading h2 a:hover,
.ent-card-heading h2 a:hover{
  color:#145d9f!important;
}

.med-card-heading h2 a:focus-visible,
.ent-card-heading h2 a:focus-visible,
.med-card-footer a:focus-visible,
.ent-card-footer a:focus-visible{
  outline:2px solid #2c75d1!important;
  outline-offset:3px!important;
  border-radius:3px!important;
}

/* Status is secondary; it should not compete with the title */
.med-card-status,
.ent-card-status{
  align-self:flex-start!important;
  display:inline-flex!important;
  margin-top:9px!important;
  padding:5px 7px!important;
  border:1px solid #d7e1eb!important;
  border-radius:6px!important;
  background:#f6f9fc!important;
  color:#5e7184!important;
  font-size:.59rem!important;
  font-weight:760!important;
}

.med-card-status i,
.ent-card-status i{
  width:5px!important;
  height:5px!important;
  background:var(--card-accent)!important;
}

.med-card-description,
.ent-card-description{
  margin:11px 0 13px!important;
  color:#596d80!important;
  font-size:.78rem!important;
  line-height:1.54!important;
  -webkit-line-clamp:2!important;
}

/* Specifications become compact metadata blocks; no repeated row dividers. */
.med-card-facts,
.ent-card-facts{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:10px!important;
  margin:0!important;
  padding:12px 0 0!important;
  border-top:1px solid #dfe7ef!important;
}

.med-card-facts>div,
.ent-card-facts>div{
  display:block!important;
  min-width:0!important;
  padding:0!important;
  border:0!important;
}

.med-card-facts dt,
.ent-card-facts dt{
  margin-bottom:4px!important;
  color:#8190a0!important;
  font-size:.54rem!important;
  line-height:1.2!important;
  letter-spacing:.06em!important;
}

.med-card-facts dd,
.ent-card-facts dd{
  color:#2a4055!important;
  font-size:.68rem!important;
  line-height:1.4!important;
  font-weight:650!important;
  overflow-wrap:anywhere!important;
}

/* One clean footer divider; CTA is easy to scan. */
.med-card-footer,
.ent-card-footer{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:14px!important;
  margin-top:13px!important;
  padding-top:12px!important;
  border-top:1px solid #e1e8ef!important;
}

.med-card-footer>span,
.ent-card-footer>span{
  min-width:0!important;
  color:#8392a1!important;
  font-size:.61rem!important;
  line-height:1.3!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  white-space:nowrap!important;
}

.med-card-footer a,
.ent-card-footer a{
  flex:0 0 auto!important;
  display:inline-flex!important;
  align-items:center!important;
  gap:4px!important;
  color:#165c9e!important;
  font-size:.72rem!important;
  font-weight:820!important;
  text-decoration:none!important;
  white-space:nowrap!important;
}

.med-card-footer a:hover,
.ent-card-footer a:hover{
  color:#0b447b!important;
  text-decoration:none!important;
}

/* ---------------------------------------------------------------------
   Responsive card density
   --------------------------------------------------------------------- */

@media(min-width:1450px){
  .med-listing-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }

  .ent-listing-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }

  .med-card-facts,
  .ent-card-facts{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }
}

@media(max-width:1180px){
  .med-listing-grid,
  .ent-listing-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }

  .med-card-facts,
  .ent-card-facts{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }

  .med-card-facts>div:last-child,
  .ent-card-facts>div:last-child{
    grid-column:1 / -1!important;
  }
}

@media(max-width:820px){
  .med-listing-grid,
  .ent-listing-grid{
    grid-template-columns:1fr!important;
  }

  .med-listing-card,
  .ent-listing-card{
    padding:15px!important;
  }

  .med-card-heading h2,
  .ent-card-heading h2{
    font-size:1.2rem!important;
  }

  .med-card-facts,
  .ent-card-facts{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }

  .med-card-facts>div:last-child,
  .ent-card-facts>div:last-child{
    grid-column:auto!important;
  }
}

/* V13.8: stronger surface hierarchy without adding height to the listings. */
.med-marketplace,.ent-marketplace{
  background:linear-gradient(135deg,#e9f0f7 0%,#f1f5f9 55%,#e8f0f7 100%)!important;
}
.med-listing-grid,.ent-listing-grid{gap:14px!important}
.med-listing-card,.ent-listing-card{
  background:linear-gradient(155deg,var(--card-surface) 0%,#fff 67%)!important;
  border:1px solid #c4d2e0!important;
  border-top:3px solid var(--card-accent)!important;
  border-left:1px solid #c4d2e0!important;
  border-radius:11px!important;
  box-shadow:0 2px 4px rgba(9,33,61,.035),0 13px 30px rgba(9,33,61,.055)!important;
}
.med-listing-card:hover,.ent-listing-card:hover{
  border-color:#9eb7d0!important;
  border-top-color:var(--card-accent)!important;
  border-left-color:#9eb7d0!important;
  box-shadow:0 4px 8px rgba(9,33,61,.04),0 17px 36px rgba(9,33,61,.11)!important;
}
.med-listing-card.is-filtered-out,.ent-listing-card.is-filtered-out{display:none!important}
.med-card-topline,.ent-card-topline{padding-bottom:9px!important;border-bottom:1px solid #e2eaf2!important}
.med-card-category::before,.ent-card-category::before{display:none!important}
.med-card-heading h2,.ent-card-heading h2{line-height:1.2!important}
.med-card-description,.ent-card-description{margin:10px 0 12px!important}
.med-card-facts,.ent-card-facts{gap:8px!important;padding-top:10px!important}
.med-card-facts dt,.ent-card-facts dt{color:#657a8f!important}
.med-card-footer,.ent-card-footer{margin-top:12px!important;padding-top:10px!important}
.med-card-footer a,.ent-card-footer a{padding:7px 0!important;color:#114e91!important}
@media(max-width:640px){
  .med-listing-card,.ent-listing-card{padding:14px!important}
  .med-card-facts,.ent-card-facts{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .med-card-footer>span,.ent-card-footer>span{max-width:none!important;white-space:normal!important}
}

@media(max-width:560px){
  .med-listing-grid,
  .ent-listing-grid{
    gap:9px!important;
  }

  .med-listing-card,
  .ent-listing-card{
    padding:14px!important;
    border-radius:11px!important;
  }

  .med-card-topline,
  .ent-card-topline{
    margin-bottom:8px!important;
  }

  .med-card-heading h2,
  .ent-card-heading h2{
    font-size:1.13rem!important;
  }

  .med-card-description,
  .ent-card-description{
    margin:10px 0 11px!important;
    -webkit-line-clamp:3!important;
  }

  .med-card-facts,
  .ent-card-facts{
    grid-template-columns:1fr 1fr!important;
    gap:9px 12px!important;
  }

  .med-card-facts>div:last-child,
  .ent-card-facts>div:last-child{
    grid-column:1 / -1!important;
  }

  .med-card-footer,
  .ent-card-footer{
    align-items:flex-start!important;
    gap:9px!important;
    margin-top:11px!important;
    padding-top:10px!important;
  }

  .med-card-footer>span,
  .ent-card-footer>span{
    max-width:42%!important;
  }
}

/* A restrained, consistent action across both marketplace card families. */
.med-card-footer a,.ent-card-footer a{
  min-height:36px!important;
  padding:8px 12px!important;
  border:1px solid #1b5b9d!important;
  border-radius:7px!important;
  background:#123d6c!important;
  color:#fff!important;
  box-shadow:0 2px 5px rgba(9,38,74,.14)!important;
  line-height:1.2!important;
  text-decoration:none!important;
  transition:background .16s ease,border-color .16s ease,box-shadow .16s ease!important;
}
.med-card-footer a:hover,.ent-card-footer a:hover{
  background:#1c5d9e!important;
  border-color:#1c5d9e!important;
  color:#fff!important;
  box-shadow:0 4px 10px rgba(9,38,74,.2)!important;
}
.med-card-footer a:focus-visible,.ent-card-footer a:focus-visible{
  outline:3px solid #70a7ee!important;
  outline-offset:3px!important;
}
@media(max-width:560px){
  .med-card-footer,.ent-card-footer{align-items:center!important}
  .med-card-footer>span,.ent-card-footer>span{max-width:34%!important}
  .med-card-footer a,.ent-card-footer a{white-space:normal!important;text-align:center!important}
}
