/* ================================================================
   MTAA HOMEPAGE V15 — MODERN DIRECTORY / MARKETPLACE
   Visual direction: clean, generous, trustworthy and image-led.
   Scoped to the public homepage so owner/admin/business pages are safe.
   ================================================================ */

:root{
  --mtaa15-green:#07834f;
  --mtaa15-green-dark:#05613b;
  --mtaa15-ink:#10261f;
  --mtaa15-muted:#687b73;
  --mtaa15-line:#dfece6;
  --mtaa15-soft:#f3faf6;
  --mtaa15-yellow:#f5c43b;
  --mtaa15-shadow:0 8px 28px rgba(10,42,30,.08);
  --mtaa15-radius:14px;
}

body{color:var(--mtaa15-ink);background:#fff}

/* Keep the page at a comfortable marketplace reading width. */
.category-section > .container,
.discovery-strip > .container,
.home-feature-row,
.home-marketplace-row,
.trending-section > .container,
.recent-section > .container,
.browse-counties > .container,
.homepage-stats > .container,
.homepage-cta > .container{max-width:1120px!important}

/* ================================================================
   HERO
   ================================================================ */
.hero{
  padding:74px 0 54px!important;
  background:
    linear-gradient(180deg,rgba(0,91,57,.90),rgba(5,121,72,.96)),
    url('../images/branding/hero-illustration.jpeg') center/cover no-repeat!important;
}
.hero-overlay{
  background:
    radial-gradient(circle at 85% 20%,rgba(255,255,255,.12),transparent 30%),
    linear-gradient(180deg,rgba(0,66,42,.10),rgba(0,91,57,.10))!important;
}
.hero-content{max-width:940px!important}
.hero-tagline{
  padding:6px 13px!important;
  font-size:11px!important;
  background:rgba(255,255,255,.12)!important;
}
.hero-location-chip{transform:scale(.9);transform-origin:center}
.hero h1{
  font-size:clamp(2rem,4vw,3.25rem)!important;
  margin:10px 0 10px!important;
  letter-spacing:-.035em;
}
.hero-subtitle{font-size:14px!important;max-width:620px!important;margin-bottom:20px!important}
.hero-search{
  width:min(900px,100%)!important;
  grid-template-columns:minmax(0,1fr) 190px auto!important;
  padding:6px!important;
  box-shadow:0 14px 34px rgba(0,40,25,.20)!important;
}
.hero-search-input,.hero-search-category,.hero-search-button{height:48px!important}
.hero-search-button{height:48px!important;padding:0 22px!important}

/* Search suggestions — keep the dropdown visible, clean and above the hero content. */
.hero{overflow:visible!important}
.hero-search-input{z-index:30!important}
.ai-search-suggestions{
  position:absolute!important;
  top:calc(100% + 8px)!important;
  left:0!important;
  right:0!important;
  z-index:1000!important;
  display:none;
  max-height:320px;
  overflow-y:auto;
  padding:6px;
  background:#fff;
  border:1px solid rgba(16,38,31,.10);
  border-radius:16px;
  box-shadow:0 16px 38px rgba(10,42,30,.18);
  text-align:left;
}
.ai-search-suggestion{
  display:flex;
  align-items:center;
  gap:11px;
  width:100%;
  min-height:48px;
  padding:9px 12px;
  border-radius:11px;
  color:var(--mtaa15-ink);
  background:#fff;
  cursor:pointer;
  transition:background .15s ease,transform .15s ease;
}
.ai-search-suggestion:hover,
.ai-search-suggestion:focus{
  background:var(--mtaa15-soft);
}
.ai-search-suggestion + .ai-search-suggestion{margin-top:2px}
.suggestion-icon{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 32px;
  width:32px;
  height:32px;
  border-radius:10px;
  background:#eef8f2;
  font-size:15px;
}
.suggestion-content{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:2px;
  line-height:1.2;
}
.suggestion-content strong{
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:12px;
  font-weight:800;
  color:var(--mtaa15-ink);
}
.suggestion-content small{
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:10px;
  color:var(--mtaa15-muted);
}
.ai-search-suggestions::-webkit-scrollbar{width:6px}
.ai-search-suggestions::-webkit-scrollbar-thumb{background:#cfe4d9;border-radius:99px}
.popular-searches{margin-top:12px!important;font-size:10px!important}
.popular-searches a{padding:4px 8px!important}
.hero-stats{margin-top:22px!important}

/* ================================================================
   SECTION HEADINGS
   ================================================================ */
.home-section-heading{margin-bottom:16px!important}
.home-section-heading .heading-copy h2{
  font-size:1.25rem!important;
  font-weight:800!important;
  letter-spacing:-.025em;
}
.home-section-heading .heading-copy p{font-size:.70rem!important;margin-bottom:0!important}
.section-badge{
  display:inline-flex!important;
  background:#eaf8f1!important;
  color:var(--mtaa15-green-dark)!important;
  font-size:.52rem!important;
  font-weight:800!important;
  padding:4px 8px!important;
  border-radius:999px!important;
  text-transform:uppercase;
}
.section-view-all{
  color:var(--mtaa15-green)!important;
  font-size:.60rem!important;
  font-weight:800!important;
  white-space:nowrap;
}

/* ================================================================
   CATEGORIES — larger, simple and aligned
   ================================================================ */
.category-section{padding:34px 0 30px!important}
.category-section > .container > .text-center:first-child{margin-bottom:20px!important}
.category-section .display-5{font-size:1.35rem!important;margin-top:8px!important;margin-bottom:5px!important}
.category-section .lead{font-size:.68rem!important}
.category-section .row{--bs-gutter-x:10px!important;--bs-gutter-y:10px!important}
.category-section .row > [class*="col-"]{width:12.5%!important;flex:0 0 12.5%!important;max-width:12.5%!important}
.category-section .category-card{
  min-height:82px!important;
  padding:12px 7px!important;
  border:1px solid var(--mtaa15-line)!important;
  border-radius:11px!important;
  background:#fff!important;
  box-shadow:0 4px 16px rgba(10,42,30,.035)!important;
  transition:.2s ease!important;
}
.category-section .category-card:hover{transform:translateY(-3px);box-shadow:var(--mtaa15-shadow)!important;border-color:#b9ddca!important}
.category-section .category-icon{font-size:14px!important;color:var(--mtaa15-green)!important;margin-bottom:6px!important}
.category-section .category-card h4{font-size:.58rem!important;line-height:1.2!important;margin:0 0 3px!important;font-weight:800!important}
.category-section .category-card p{font-size:.44rem!important;color:var(--mtaa15-muted)!important;margin:0!important}
.category-section .category-link{display:none!important}
.category-section > .container > .text-center:last-child{margin-top:15px!important}
.category-section > .container > .text-center:last-child .btn{font-size:.56rem!important;padding:6px 11px!important}

/* ================================================================
   QUICK DISCOVERY
   ================================================================ */
.discovery-strip{padding:30px 0!important}
.discovery-grid{display:grid!important;grid-template-columns:repeat(8,minmax(0,1fr));gap:9px!important}
.discovery-tile{
  min-height:54px!important;
  padding:9px!important;
  border:1px solid var(--mtaa15-line)!important;
  border-radius:10px!important;
  background:#fff!important;
}
.discovery-tile strong{font-size:.56rem!important}
.discovery-tile small{font-size:.43rem!important}
.discovery-icon{width:27px!important;height:27px!important;font-size:10px!important;background:#eff9f4!important;color:var(--mtaa15-green)!important}
.discovery-tile .arrow{font-size:8px!important}

/* ================================================================
   FEATURED BUSINESS — image + information side-by-side
   ================================================================ */
.home-feature-row{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) 285px!important;
  gap:18px!important;
  margin:0 auto!important;
  padding:22px 12px 34px!important;
}
.home-feature-row > .business-week-section,
.home-feature-row > .why-mtaa{padding:0!important;margin:0!important;background:transparent!important}
.home-feature-row .container{max-width:none!important;padding:0!important}
.business-week-card{
  position:relative!important;
  display:grid!important;
  grid-template-columns:42% 58%!important;
  min-height:275px!important;
  overflow:hidden!important;
  background:#fff!important;
  border:1px solid var(--mtaa15-line)!important;
  border-radius:14px!important;
  box-shadow:var(--mtaa15-shadow)!important;
}
.business-week-card .week-cover{
  grid-column:1!important;
  grid-row:1!important;
  min-height:275px!important;
  height:100%!important;
  position:relative!important;
}
.business-week-card .week-cover img{width:100%!important;height:100%!important;object-fit:cover!important}
.business-week-card .week-overlay{background:linear-gradient(180deg,rgba(0,0,0,.08),rgba(0,0,0,.45))!important}
.business-week-card .week-featured-badge{top:10px!important;left:10px!important;font-size:.52rem!important;padding:5px 8px!important}
.business-week-card .week-open-badge{bottom:10px!important;left:10px!important;font-size:.52rem!important;padding:5px 8px!important}
.business-week-card .week-logo{
  position:absolute!important;
  left:calc(42% - 34px)!important;
  bottom:17px!important;
  top:auto!important;
  z-index:8!important;
  width:68px!important;height:68px!important;
  border:3px solid #fff!important;
  border-radius:14px!important;
  background:#fff!important;
  box-shadow:0 7px 18px rgba(0,0,0,.17)!important;
}
.business-week-card .week-logo img{width:100%!important;height:100%!important;object-fit:contain!important;border-radius:10px!important}
.business-week-card .week-content{
  grid-column:2!important;
  grid-row:1!important;
  display:flex!important;
  align-items:center!important;
  gap:15px!important;
  padding:24px 20px!important;
}
.business-week-card .week-left{min-width:0!important;flex:1!important}
.business-week-card .week-left h2{font-size:1.05rem!important;line-height:1.25!important;margin-bottom:7px!important;font-weight:800!important}
.business-week-card .week-badges span{font-size:.50rem!important;padding:4px 7px!important}
.business-week-card .week-meta{font-size:.56rem!important;margin:9px 0!important;color:var(--mtaa15-muted)!important}
.business-week-card .week-description{font-size:.61rem!important;line-height:1.5!important;color:#53675f!important;margin-bottom:0!important}
.business-week-card .week-right{width:135px!important;flex:0 0 135px!important}
.business-week-card .week-buttons{display:grid!important;grid-template-columns:1fr 1fr!important;gap:6px!important}
.business-week-card .week-btn{font-size:.53rem!important;padding:7px 5px!important;border-radius:6px!important}
.business-week-card .view-featured{display:block!important;margin-top:7px!important;font-size:.52rem!important;padding:7px!important;text-align:center!important;border-radius:6px!important}

/* Why MTAA becomes a compact vertical trust panel. */
.why-mtaa .home-section-heading{margin-bottom:10px!important}
.why-mtaa .home-section-heading .heading-copy h2{font-size:.88rem!important}
.why-mtaa .why-grid{display:grid!important;grid-template-columns:1fr!important;gap:7px!important}
.why-mtaa .why-card{
  padding:10px!important;
  border:1px solid var(--mtaa15-line)!important;
  border-radius:10px!important;
  background:#fff!important;
  box-shadow:0 4px 15px rgba(10,42,30,.035)!important;
}
.why-mtaa .why-icon{width:28px!important;height:28px!important;font-size:11px!important;margin-bottom:5px!important;color:var(--mtaa15-green)!important;background:#eef9f4!important}
.why-mtaa .why-card h3{font-size:.60rem!important;margin-bottom:2px!important;font-weight:800!important}
.why-mtaa .why-card p{font-size:.48rem!important;line-height:1.35!important;margin:0!important;color:var(--mtaa15-muted)!important}

/* ================================================================
   BUSINESS LISTINGS — logo is anchored inside the image, never floating
   in the card body. This is the key fix for the screenshot issue.
   ================================================================ */
.home-marketplace-row{
  max-width:1120px!important;
  margin:0 auto!important;
  padding:0 12px 30px!important;
}
.home-marketplace-row > section{padding:0!important;margin:0 0 30px!important;background:transparent!important}
.home-marketplace-row > section > .container{max-width:none!important;padding:0!important}
.home-marketplace-row .row,
.trending-section .row,
.recent-section .row{--bs-gutter-x:12px!important;--bs-gutter-y:12px!important}
.home-marketplace-row .row > [class*="col-"],
.trending-section .row > [class*="col-"],
.recent-section .row > [class*="col-"]{width:25%!important;flex:0 0 25%!important;max-width:25%!important}

.home-marketplace-row .business-card,
.trending-section .business-card,
.recent-section .business-card{
  position:relative!important;
  display:flex!important;
  flex-direction:column!important;
  min-width:0!important;
  height:100%!important;
  background:#fff!important;
  border:1px solid var(--mtaa15-line)!important;
  border-radius:12px!important;
  overflow:hidden!important;
  box-shadow:0 5px 20px rgba(10,42,30,.055)!important;
  transition:transform .18s ease,box-shadow .18s ease!important;
}
.home-marketplace-row .business-card:hover,
.trending-section .business-card:hover,
.recent-section .business-card:hover{transform:translateY(-3px)!important;box-shadow:0 14px 30px rgba(10,42,30,.11)!important}

.home-marketplace-row .card-image,
.trending-section .card-image,
.recent-section .card-image{
  position:relative!important;
  width:100%!important;
  height:145px!important;
  min-height:145px!important;
  overflow:hidden!important;
  background:#edf2ef!important;
}
.home-marketplace-row .card-image img,
.trending-section .card-image img,
.recent-section .card-image img{width:100%!important;height:100%!important;object-fit:cover!important}
.home-marketplace-row .image-overlay,
.trending-section .image-overlay,
.recent-section .image-overlay{background:linear-gradient(180deg,rgba(0,0,0,0),rgba(0,0,0,.34))!important}

/* Logo is now a child of .card-image and therefore has a stable anchor. */
.home-marketplace-row .card-logo,
.trending-section .card-logo{
  position:absolute!important;
  left:10px!important;
  bottom:10px!important;
  top:auto!important;
  z-index:6!important;
  width:52px!important;
  height:52px!important;
  padding:3px!important;
  margin:0!important;
  border:2px solid #fff!important;
  border-radius:11px!important;
  background:#fff!important;
  box-shadow:0 5px 14px rgba(0,0,0,.18)!important;
}
.home-marketplace-row .card-logo img,
.trending-section .card-logo img{
  width:100%!important;height:100%!important;
  object-fit:contain!important;
  border-radius:8px!important;
  background:#fff!important;
}

.home-marketplace-row .card-body,
.trending-section .card-body{
  display:flex!important;flex-direction:column!important;flex:1!important;
  min-width:0!important;padding:12px!important;
}
.home-marketplace-row .title-row h4,
.trending-section .title-row h4{
  font-size:.70rem!important;line-height:1.28!important;font-weight:800!important;
  min-height:2.55em!important;margin:0!important;overflow-wrap:anywhere!important;
}
.home-marketplace-row .text-muted.mb-2,
.trending-section .text-muted.mb-2{font-size:.48rem!important;margin:3px 0 5px!important}
.home-marketplace-row .business-rating,
.trending-section .business-rating{font-size:.52rem!important;margin:0 0 4px!important}
.home-marketplace-row .business-rating small,
.trending-section .business-rating small{font-size:.44rem!important}
.home-marketplace-row .business-location,
.trending-section .business-location{font-size:.47rem!important;margin:0 0 5px!important}
.home-marketplace-row .text-muted.small,
.trending-section .text-muted.small{font-size:.46rem!important;line-height:1.4!important;min-height:2.8em!important;margin:0 0 7px!important}
.home-marketplace-row .quick-actions,
.trending-section .quick-actions{gap:5px!important;margin:0 0 6px!important}
.home-marketplace-row .quick-actions a,
.trending-section .quick-actions a{width:25px!important;height:25px!important;flex:0 0 25px!important;font-size:9px!important}
.home-marketplace-row .view-btn,
.trending-section .view-btn{margin-top:auto!important;width:100%!important;padding:6px!important;font-size:.48rem!important;border-radius:6px!important}
.home-marketplace-row .featured-ribbon,
.home-marketplace-row .verified-badge,
.home-marketplace-row .home-card-status,
.trending-section .featured-ribbon,
.trending-section .verified-badge,
.trending-section .home-card-status{font-size:.43rem!important;padding:4px 6px!important}
.home-marketplace-row .featured-ribbon,
.trending-section .featured-ribbon{top:8px!important;left:8px!important}
.home-marketplace-row .verified-badge,
.trending-section .verified-badge{top:8px!important;right:8px!important}
.home-marketplace-row .home-card-status,
.trending-section .home-card-status{left:8px!important;bottom:8px!important}

/* ================================================================
   TRENDING
   ================================================================ */
.trending-section{padding:34px 0!important;background:var(--mtaa15-soft)!important}
.trending-section .container{max-width:1120px!important}
.trending-section .card-image{height:145px!important;min-height:145px!important}

/* ================================================================
   RECENTLY ADDED — compact horizontal-feeling cards
   ================================================================ */
.recent-section{padding:34px 0!important;background:#fff!important}
.recent-section .card-image{height:105px!important;min-height:105px!important}
.recent-section .card-logo{display:none!important}
.recent-section .card-body{padding:10px!important}
.recent-section .title-row h4{font-size:.62rem!important;min-height:2.4em!important}
.recent-section .text-muted.mb-2,
.recent-section .business-rating,
.recent-section .business-location{font-size:.44rem!important}
.recent-section .text-muted.small{font-size:.42rem!important;min-height:2.6em!important}
.recent-section .quick-actions{display:flex!important}
.recent-section .view-btn{display:block!important}

/* ================================================================
   COUNTIES / STATS / CTA
   ================================================================ */
.browse-counties{padding:34px 0!important;background:#fff!important}
.browse-counties .row{--bs-gutter-x:12px!important}
.browse-counties .col-lg-3{width:25%!important;flex:0 0 25%!important;max-width:25%!important}
.county-card{padding:15px!important;border-radius:11px!important}
.homepage-stats{padding:34px 0!important}
.homepage-stats .stat-card{padding:16px 10px!important}
.homepage-cta{padding:30px 0!important}
.homepage-cta .container{max-width:1120px!important}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media(max-width:1199.98px){
  .category-section .row > [class*="col-"]{width:16.666667%!important;flex-basis:16.666667%!important;max-width:16.666667%!important}
}
@media(max-width:991.98px){
  .hero{padding-top:58px!important}
  .hero-search{grid-template-columns:1fr!important;border-radius:18px!important}
  .hero-search-category{border-left:0!important;border-top:1px solid #e9ecef!important;padding-left:18px!important}
  .hero-search-button{width:100%!important}
  .discovery-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important}
  .home-feature-row{grid-template-columns:1fr!important}
  .business-week-card{grid-template-columns:44% 56%!important}
  .business-week-card .week-logo{left:calc(44% - 30px)!important;width:60px!important;height:60px!important}
  .home-marketplace-row .row > [class*="col-"],
  .trending-section .row > [class*="col-"],
  .recent-section .row > [class*="col-"]{width:50%!important;flex-basis:50%!important;max-width:50%!important}
  .browse-counties .col-lg-3{width:50%!important;flex-basis:50%!important;max-width:50%!important}
}
@media(max-width:767.98px){
  .category-section .row > [class*="col-"]{width:25%!important;flex-basis:25%!important;max-width:25%!important}
  .discovery-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .business-week-card{display:flex!important;flex-direction:column!important}
  .business-week-card .week-cover{min-height:220px!important;height:220px!important}
  .business-week-card .week-logo{left:14px!important;bottom:-28px!important;width:60px!important;height:60px!important}
  .business-week-card .week-content{display:block!important;padding:42px 15px 15px!important}
  .business-week-card .week-right{width:auto!important;margin-top:12px!important}
  .business-week-card .week-buttons{grid-template-columns:1fr 1fr!important}
  .home-marketplace-row,.trending-section .container,.recent-section .container{padding-left:12px!important;padding-right:12px!important}
}
@media(max-width:575.98px){
  .hero h1{font-size:2rem!important}
  .category-section .row > [class*="col-"]{width:50%!important;flex-basis:50%!important;max-width:50%!important}
  .home-marketplace-row .row > [class*="col-"],
  .trending-section .row > [class*="col-"],
  .recent-section .row > [class*="col-"]{width:100%!important;flex-basis:100%!important;max-width:100%!important}
  .home-marketplace-row .card-image,.trending-section .card-image{height:190px!important;min-height:190px!important}
  .home-marketplace-row .card-logo,.trending-section .card-logo{width:62px!important;height:62px!important}
  .browse-counties .col-lg-3{width:100%!important;flex-basis:100%!important;max-width:100%!important}
}
/* ================================================================
   MTAA — BUSINESS OF THE WEEK LOGO
   FORCE COMPLETE LOGO / PRESERVE ORIGINAL ASPECT RATIO
   ================================================================ */

.business-week-card .week-logo{
    position:absolute!important;
    left:calc(42% - 34px)!important;
    bottom:17px!important;
    top:auto!important;

    z-index:20!important;

    width:68px!important;
    height:68px!important;

    margin:0!important;
    padding:6px!important;

    box-sizing:border-box!important;

    display:flex!important;
    align-items:center!important;
    justify-content:center!important;

    overflow:hidden!important;

    background:#fff!important;
    border:3px solid #fff!important;
    border-radius:14px!important;

    box-shadow:0 7px 18px rgba(0,0,0,.17)!important;
}

.business-week-card .week-logo img{
    position:static!important;

    display:block!important;

    width:auto!important;
    height:auto!important;

    min-width:0!important;
    min-height:0!important;

    max-width:100%!important;
    max-height:100%!important;

    margin:0!important;
    padding:0!important;

    box-sizing:border-box!important;

    object-fit:contain!important;
    object-position:center center!important;

    border:0!important;
    border-radius:8px!important;

    background:#fff!important;

    transform:none!important;
}