/* =========================================================
   ANUNCIOS CON ESTILOS — Estilos públicos
========================================================= */
:root {
  --primary: #7B2FB5;
  --primary-dark: #4B1D80;
  --primary-light: #F3E8FD;
  --accent: #E8590C;
  --accent-light: #FFE9DB;
  --ink: #2B1A3D;
  --muted: #6B6480;
  --border: #ECE6F5;
  --bg: #FAF8FD;
  --radius: 16px;
  --shadow: 0 8px 24px rgba(75, 29, 128, 0.08);
  --font-display: 'Fredoka', 'Poppins', sans-serif;
  --font-body: 'Poppins', sans-serif;
}

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
}

h1,
h2,
h3,
h4,
.brand-font {
  font-family: var(--font-display);
}

a {
  text-decoration: none;
}

.text-primary-brand {
  color: var(--primary) !important;
}

.bg-primary-brand {
  background: var(--primary) !important;
}

/* ---------- Navbar ---------- */
.navbar-aces {
  background: #fff;
  box-shadow: 0 2px 12px rgba(75, 29, 128, .06);
}

.navbar-aces .navbar-brand img {
  height: 40px;
  width: 40px;
  object-fit: contain;
}

.navbar-aces .navbar-brand .brand-text {
  line-height: 1.05;
}

.navbar-aces .brand-text strong {
  color: var(--primary);
  font-family: var(--font-display);
  font-size: 1.05rem;
}

.navbar-aces .brand-text span {
  color: var(--accent);
  font-size: .68rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  display: block;
}

.navbar-aces .nav-link {
  color: var(--ink);
  font-weight: 500;
}

.navbar-aces .nav-link.active,
.navbar-aces .nav-link:hover {
  color: var(--primary);
}

.btn-publicar {
  background: var(--primary);
  color: #fff;
  border-radius: 50px;
  padding: .55rem 1.3rem;
  font-weight: 600;
  border: none;
}

.btn-publicar:hover {
  background: var(--primary-dark);
  color: #fff;
}

.icon-search-btn {
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-light);
  color: var(--primary);
  border: none;
}

/* ---------- Hero / slider ---------- */
.hero-slider .carousel-item {
  height: 420px;
  background-size: cover;
  background-position: center;
  position: relative;
}

.hero-slider .carousel-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(43, 26, 61, .85) 0%, rgba(75, 29, 128, .55) 45%, rgba(75, 29, 128, .15) 100%);
}

.hero-slider .carousel-caption-custom {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 2;
  max-width: 640px;
  padding: 0 4rem;
  color: #fff;
}

.hero-slider .carousel-caption-custom .eyebrow {
  text-transform: uppercase;
  letter-spacing: .15em;
  font-size: .78rem;
  color: var(--accent-light);
  font-weight: 600;
  margin-bottom: .5rem;
}

.hero-slider .carousel-caption-custom h1 {
  font-size: 2.6rem;
  font-weight: 600;
  margin-bottom: .9rem;
}

.hero-slider .carousel-caption-custom h1 .highlight {
  color: #FFB48A;
}

.hero-slider .carousel-caption-custom p {
  font-size: 1.05rem;
  color: #E9E1F5;
  margin-bottom: 1.4rem;
}

.hero-slider .badge-pill {
  background: rgba(255, 255, 255, .15);
  border: 1px solid rgba(255, 255, 255, .35);
}

.btn-hero {
  background: var(--accent);
  border: none;
  color: #fff;
  font-weight: 600;
  padding: .7rem 1.5rem;
  border-radius: 50px;
}

.btn-hero:hover {
  background: #C94A08;
  color: #fff;
}

.hero-slider .carousel-indicators {
  z-index: 3;
}

.hero-slider .carousel-control-prev,
.hero-slider .carousel-control-next {
  width: 5%;
  z-index: 3;
}

@media (max-width: 767px) {
  .hero-slider .carousel-item {
    height: 520px;
  }

  .hero-slider .carousel-caption-custom {
    padding: 0 1.5rem;
    max-width: 100%;
  }

  .hero-slider .carousel-caption-custom h1 {
    font-size: 1.8rem;
  }
}

/* ---------- Buscador global (superpuesto) ---------- */
.search-panel {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.1rem 1.3rem;
  margin-top: -48px;
  position: relative;
  z-index: 5;
}

.search-panel .form-control,
.search-panel .form-select {
  border: none;
  background: var(--bg);
  border-radius: 10px;
  padding: .65rem .9rem;
}

.search-panel .form-control:focus,
.search-panel .form-select:focus {
  box-shadow: 0 0 0 3px var(--primary-light);
}

.btn-buscar {
  background: var(--primary);
  color: #fff;
  font-weight: 600;
  border-radius: 10px;
  border: none;
}

.btn-buscar:hover {
  background: var(--primary-dark);
  color: #fff;
}

/* ---------- Categorías (pastillas) ---------- */
.cat-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: 1.1rem .5rem;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--ink);
  font-weight: 600;
  font-size: .85rem;
  transition: transform .15s ease, box-shadow .15s ease;
  text-align: center;
  height: 100%;
}

.cat-pill:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  color: var(--ink);
}

.cat-pill .cat-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: #fff;
}

.cat-pill small {
  color: var(--muted);
  font-weight: 400;
  font-size: .72rem;
}

/* ---------- Section headers ---------- */
.section-eyebrow {
  display: flex;
  align-items: center;
  gap: .6rem;
  color: var(--primary);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .85rem;
  margin-bottom: 1.4rem;
}

.section-eyebrow::before,
.section-eyebrow::after {
  content: "";
  height: 2px;
  flex: 1;
  background: var(--border);
}

.section-eyebrow i {
  color: var(--accent);
}

/* ---------- Cards de empresa ---------- */
.empresa-card {
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform .15s ease, box-shadow .15s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.empresa-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.empresa-card .img-wrap {
  position: relative;
  height: 160px;
  overflow: hidden;
}

.empresa-card .img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.empresa-card .badge-destacada {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--accent);
  color: #fff;
  font-size: .68rem;
  font-weight: 700;
  padding: .3rem .6rem;
  border-radius: 50px;
}

.empresa-card .card-body {
  padding: 1rem 1.1rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.empresa-card .cat-tag {
  color: var(--primary);
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.empresa-card h5 {
  font-size: 1.02rem;
  margin: .2rem 0 .3rem;
  font-weight: 600;
}

.empresa-card p.desc {
  color: var(--muted);
  font-size: .85rem;
  flex: 1;
}

.empresa-card .rating {
  color: #F5A623;
  font-size: .82rem;
  font-weight: 600;
}

.empresa-card .rating .bi-star-fill {
  color: #F5A623;
}

.empresa-card .loc {
  color: var(--muted);
  font-size: .78rem;
}

.btn-ver-mas {
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  padding: .45rem 1rem;
  font-size: .85rem;
  width: 100%;
}

.btn-ver-mas:hover {
  background: #C94A08;
  color: #fff;
}

/* Fila lista compacta (como Restaurantes -> Empresas de restaurantes) */
.empresa-row {
  display: flex;
  gap: 1rem;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: .8rem;
  margin-bottom: .9rem;
  align-items: center;
}

.empresa-row img {
  width: 84px;
  height: 84px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}

.empresa-row .info {
  flex: 1;
  min-width: 0;
}

.empresa-row h6 {
  font-weight: 600;
  margin-bottom: .15rem;
}

.empresa-row p {
  color: var(--muted);
  font-size: .82rem;
  margin-bottom: .25rem;
}

.empresa-row .social-mini a {
  color: var(--primary);
  font-size: 1rem;
  margin-right: .5rem;
}

.btn-detalle {
  background: var(--accent);
  color: #fff;
  font-size: .8rem;
  font-weight: 600;
  padding: .4rem .9rem;
  border-radius: 8px;
  border: none;
  white-space: nowrap;
}

.btn-detalle:hover {
  background: #C94A08;
  color: #fff;
}

/* ---------- Category page hero ---------- */
.cat-hero {
  height: 230px;
  background-size: cover;
  background-position: center;
  position: relative;
  border-radius: 0 0 24px 24px;
  overflow: hidden;
}

.cat-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(75, 29, 128, .92), rgba(75, 29, 128, .35));
}

.cat-hero .content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #fff;
  padding: 0 3rem;
}

.cat-hero h1 {
  font-weight: 700;
  font-size: 2.1rem;
}

.cat-hero .icon-badge {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: .8rem;
}

/* ---------- Mapa ---------- */
.map-container {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

#map,
#map-cat,
#map-full {
  width: 100%;
  height: 100%;
  min-height: 320px;
}

.leaflet-popup-content h6 {
  margin-bottom: .2rem;
  font-weight: 600;
}

.leaflet-popup-content .cat-tag-mini {
  color: var(--primary);
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
}

/* ---------- Footer ---------- */
.footer-aces {
  background: linear-gradient(180deg, var(--primary-dark), #35134f);
  color: #E9E1F5;
}

.footer-aces h6 {
  color: #fff;
  font-weight: 700;
  margin-bottom: 1rem;
}

.footer-aces a {
  color: #D9C9EE;
}

.footer-aces a:hover {
  color: #fff;
}

.footer-aces .social-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  margin-right: .5rem;
}

.footer-aces .social-circle:hover {
  background: var(--accent);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12);
  font-size: .82rem;
}

/* ---------- Generic ---------- */
.badge-cat {
  border-radius: 50px;
  padding: .4rem .9rem;
  font-size: .8rem;
  font-weight: 600;
  border: 1px solid var(--border);
  color: var(--ink);
  background: #fff;
}

.badge-cat.active,
.badge-cat:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.rounded-16 {
  border-radius: var(--radius);
}

.shadow-soft {
  box-shadow: var(--shadow);
}

.breadcrumb-aces a {
  color: var(--primary);
}

.stars-static {
  color: #F5A623;
}

.whatsapp-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .25);
  z-index: 999;
}

.whatsapp-fab:hover {
  color: #fff;
  transform: scale(1.06);
}