/*
Theme Name: Best Pool Companies – South Florida Directory
Theme URI: https://bestpoolcompaniesinsouthflorida.com/
Author: AEIOM Studio
Author URI: https://aeiom.com/
Description: A custom WordPress theme for Best Pool Companies South Florida — helping users find top-rated pool builders, repair, and maintenance services across Miami-Dade, Broward, and Palm Beach.
Version: 1.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bestpoolcompanies
*/


/*
 * Reset basic styles and set up default fonts.  Using a simple reset helps
 * normalise margins, paddings and box sizing across browsers.  The body
 * font families are imported from Google Fonts in header.php, but we
 * declare them here so the theme still looks consistent if the fonts
 * fail to load.
 */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
}

/* Set up box sizing so padding and borders are included in element widths */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Global colour palette using CSS variables.  Adjust these values to tweak the
 * overall look and feel of the site.  The colours were picked to loosely
 * match the mood of the reference screenshot: rich blues for headings,
 * soft creams for backgrounds and a bright teal accent for call‑to‑action
 * elements.  Using variables here makes it easy to change the palette in
 * one place.
 */
:root {
    --colour-dark: #0b3d63;
    --colour-text: #263A52;
    --colour-accent: #00a99d;
    --colour-accent-dark: #008578;
    --colour-bg: #f9f5ef;
    --colour-section: #f4efe7;
    --colour-card: #ffffff;
    --colour-feature-icon-1: #e5b54c;
    --colour-feature-icon-2: #e7923c;
    --colour-feature-icon-3: #e6a764;
}

body {
    font-family: 'Open Sans', Arial, sans-serif;
    line-height: 1.6;
    background-color: var(--colour-bg);
    color: var(--colour-text);
}

/* Offset the fixed header height on pages other than the home/front page.
   WordPress typically adds the `home` class to the body on the front page
   and `page-template-front-page` when using a static front page.  By
   applying padding to the top of the body for all other pages, we ensure
   that headings and content are not obscured by the fixed header. */
body:not(.home):not(.page-template-front-page) {
    padding-top: 0px;
}

.blog-entry,
.contact-page,

 {
    padding: 400px 0 !important;

}

.list-company-page,
.company-directory,
.blog-directory {
    padding: 140px 0 !important;

}

.services-page
{
    padding: 60px 0 !important;

}

@media (min-width: 992px){

	/* Add additional top padding for specific custom templates that don’t
   inherit the page classes above.  These selectors target the wrapper
   elements defined in the PHP templates and ensure consistent spacing. */
.blog-entry,
.contact-page,

 {
    padding: 400px 0 !important;

}

.list-company-page,
.company-directory,
.blog-directory {
    padding: 140px 0 !important;

}

.services-page
{
    padding: 60px 0 !important;

}
}


a {
    color: inherit;
    text-decoration: none;
}


/* ===== Header base ===== */
/* Default: header normal (no persigue el scroll) */
header.site-header{
  z-index: 1000;
}

/* HOME: overlay encima del hero */
.home header.site-header{
  position: absolute;      /* se coloca sobre la imagen y se va con el scroll */
}

/* Opcional: en móviles, dale fondo para legibilidad */
@media (max-width: 991.98px){
  .home header.site-header{
	  width: 100%;

  }
}


/* ===== Header main ===== */
.site-header .header-main{ padding:0; }
.site-header .header-main .container{ display:flex; align-items:center; }

 .top-bar{
	  display: none !important;
  }

body:not(.home) .site-logo2 {
  opacity: 1 !important;
}

.site-logo2{height:3.2rem!important;opacity:0;transition:opacity .4s ease,height .4s ease}

.top-bar2{display:flex!important}


body.scrolled .site-logo2{opacity:1!important}
body.scrolled .top-bar2{position:fixed;background-color:#0062ad;width:100vw;display:flex!important;z-index:1200;top:0}

 body:not(.home) .top-bar2 {
  display: flex !important;
  position: fixed;
  background-color: #0062ad !important;
  width: 100vw;
  justify-content: space-between;
  align-items: center;
  z-index: 1200;

}


@media (min-width: 992px){


	  .top-bar{
	  display: flex!important;
      padding: 2rem 12rem !important;
  }

  .top-bar2{
	  display: none!important;
  }

 body:not(.home) .top-bar2 {
  display: flex !important;
  position: fixed;
  background-color: #0062ad !important;
  width: 100vw;
  justify-content: space-between;
  align-items: center;
  z-index: 1200;
  padding: 0.5rem 2rem !important;
}


   body:not(.home) .top-bar{
	  display: none!important;
  }

	.header-cta {
    padding: 9px 25px !important;
    font-size: 20px !important;
}
}


/* Logo */


/* Tamaño del logo (móvil) */
.site-header .site-logo img,
.site-header .custom-logo {      /* WP custom_logo también usa .custom-logo */
      height: 12rem;

}
.site-header .site-logo2 img,
.site-header .custom-logo {      /* WP custom_logo también usa .custom-logo */
      height: 3.2rem !important;
}


/* Tamaño del logo (desktop) */
@media (min-width: 992px){
  .site-header .site-logo img,
  .site-header .custom-logo {
    height: 12rem;               /* agranda solo en desktop */
  }
}


.navbar-nav{
	display: none !important;
}


@media (min-width:992px){
	.site-logo img{ height:88px; }

.navbar-nav{
	display: flex !important;
	font-size: 1.4em !important;
}


.navbar-toggler{

    --bs-navbar-toggler-border-color: none !important;
    }

}


.navbar-toggler{

    --bs-navbar-toggler-border-color: none !important;
    }

/* Menú + CTA a la derecha */
.brand-cta{ display:flex; align-items:center; width:100%; }
.menu-cta{
  display:flex; align-items:center; gap:12px; margin-left:auto;
  width:auto; /* ← clave: NO 100% en desktop */
}
.menu-cta .navbar{ align-items:center; }
.menu-cta .navbar-nav{ display:flex; flex-direction:row; gap:18px; align-items:center; }

/* Links del menú */
.navbar-dark .navbar-nav .nav-link{ color:#fff; font-weight:600; padding:0; }
.navbar-dark .navbar-nav .nav-link:hover{ opacity:.85; }

/* CTA */
.header-cta{

    background: var(--colour-accent);
    color: #f5eedf;
    font-weight: 600;
    padding: 6px 12px;
    text-decoration: none;
    white-space: nowrap;
    border-radius: 21px;
        font-size: 15px;

}


.header-cta:hover{ filter:brightness(.95); }

/* Toggler visible */
.navbar-dark .navbar-toggler{ border-color:rgba(255,255,255,.35); }
.navbar-dark .navbar-toggler-icon{ filter:invert(1) grayscale(100%); }

/* Móvil: menú en bloque, CTA full width debajo */
@media (max-width:991.98px){
  #mainNav{ width:100%; }
  .brand-cta{ flex-wrap:wrap; justify-content:center; row-gap:12px; }
  .menu-cta .header-cta{ width:100%; margin-left:0; }
}


.menuham{
	height: 100vh;
    width: 100%;
    padding-top: 8rem;
    position: relative !important;
    background-color: #3874b3;
    margin-top: 65px !important;

}


/* Desktop: fila con nav pegado al CTA */
@media (min-width:992px){
  .brand-cta{ display:flex; align-items:center; column-gap:12px; }
  .menu-cta{ margin-left:auto; }
  .menu-cta .navbar{ align-items:center; }
  .menu-cta .navbar-nav{ display:flex; flex-direction:row; gap:18px; align-items:center; gap: 2rem !important; margin-right: 2rem !important;}
  .menu-cta .header-cta{ margin-left:12px; width:auto; text-decoration: none;}
}

/* ===== Nav del medio ===== */
.brand-cta .navbar-nav .nav-link{ color:#fff; font-weight:600; padding-left:0; padding-right:0; }
.brand-cta .navbar-nav .nav-link:hover{ opacity:.85; }

/* Toggler visible sobre fondo oscuro */
.navbar-toggler{ border-color:rgba(255,255,255,.35); }
.navbar-toggler-icon{
    left: 1em;
    top: 1em;
    width: 2em !important;
    height: 2em !important;
   	}

.navbar-toggler-icon {
    opacity: 0;
}
body.scrolled .navbar-toggler-icon {
    opacity: 1;
}


/* Desktop ≥992px: 2 renglones (logo izq / CTA der en misma fila) */
@media (min-width: 992px){

	body:not(.home) .navbar-toggler-icon {
    opacity: 1;
}

  .site-header .header-main {
	  padding-bottom: 20px;
        width: 80%;
        margin-left: auto;
        margin-right: auto;}
  .brand-cta{
    display: flex; align-items: center; justify-content: space-between;
  }
  .site-logo img { height: 120px; } /* ligeramente más compacto en desktop */
}

.navbar-toggler-icon {
    opacity: 0.1;
}

body:not(.home) .navbar-toggler-icon {
    opacity: 1;
}


/* Limpia estilos anteriores que te estaban estorbando */
.header-right, .primary-navigation { display: none !important; }
.lang-switcher a:hover { opacity: .85; }


/* Fila principal: logo izq, menú+CTA der */

.menu-cta{ display:flex; align-items:center; gap:12px; margin-left:auto; }

/* Nav links blancos y con buen peso */
.navbar-dark .navbar-nav .nav-link{ color:#f5eedf; font-weight:600; padding:0; }
.navbar-dark .navbar-nav .nav-link:hover{ opacity:.85; }

/* Toggler correcto para fondo oscuro (con navbar-dark en el nav) */
.navbar-dark .navbar-toggler{ border-color: rgba(255,255,255,.35); }

/* Logo tamaños */

.site-logo img{
        height: 16rem;
        padding: 2rem;

        }

@media (min-width:992px){

	.site-logo img{
        height: 22rem;
        padding: 3rem;
        }

         }


/* ===== END Header main ===== */


/* content */


#site-content{
	padding: 6em 1em;
}


/* Hero base (ajusta a tu layout) */
.hero{ position:relative; isolation:isolate; }

/* Título */
.hero-title{
  position:relative;
  z-index:1;
  font-weight:800;
  line-height:1.05;
  color:#f5eee0;
  text-align:center;
}


.hero-subtitle{
	width: 67%;
	margin: auto;
	padding: 0 3rem 3rem 3rem;
}
/* Spotlight sobre el texto (sin imágenes extra) */
.hero-title.spotlight{
  display:inline-block;
  padding: 3em 2em 55px 2em !important;
  background:
    radial-gradient( circle 160px at var(--mx,50%) var(--my,50%),
      rgba(255,255,255,.98) 0%,
      rgba(255,255,255,.75) 35%,
      rgba(255,255,255,.15) 70%,
      rgba(255,255,255,0) 100% )
    no-repeat;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;        /* muestra el gradiente en el texto */
  transition: background-size .15s linear;     /* respuesta suave */
  will-change: background-position;
}

/* Accesibilidad: no animar si el usuario lo pide */
@media (prefers-reduced-motion: reduce){
  .hero-title.spotlight{ background: none; -webkit-text-fill-color: #fff; padding: 20rem 0 0 0 !important;

}

	  .hero-subtitle{
	width: 100%;
	margin: auto;
	padding: 1rem 0 2rem 0;
}
}

/* Tamaños sugeridos (ajusta a tu diseño) */
.hero{ display:flex; justify-content:center; align-items:center; min-height: 4vh; }
.hero-title{ font-size: clamp(36px, 5vw, 72px); }


/* HERO (único bloque) */
.hero-section{
  position: relative;
  width: 100%;
  min-height: clamp(520px, 78vh, 920px);
  background-color:#0A2F47;   /* color de fondo mientras carga el video */
  text-align: center;
  color: #f5eee0;
  padding: 72px 20px calc(140px + env(safe-area-inset-bottom, 0));
  overflow: hidden;
  box-sizing: border-box;
  /* importante: NO pointer-events aquí */
}

.hero-bg{
  position: absolute;
  inset: 0;
  width: 100%;
  object-fit: cover;
  z-index: 0;
  pointer-events: none; /* el video no bloquea clics */
}

.hero-content{
  position: relative;
  z-index: 1;
  font-size: 1.1rem;
}

/* Desktop */
@media (min-width: 992px){
  .hero-section{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 85vh;
    padding: 0 20px;
  }
  .hero-content{ width: 50%; }
}

/* Respeta usuarios con “reducir movimiento”: muestra imagen estática */
@media (prefers-reduced-motion: reduce){
  .hero-bg{ display: block; }
  .hero-section{
    background: url('assets/img/hero.jpg') center/cover no-repeat;
    background-color:#0A2F47;
  }
}

/* Form base */
.search-form{
  display:flex;
  justify-content:center;
  align-items:center;
  width:100%;
  max-width:600px;
  margin:0 auto;
  border-radius:50px;
  overflow:hidden;
  background:#fff;
  box-shadow:0 4px 12px rgba(0,0,0,.1);
}

.search-form input[type="text"]{
  flex:1;
  min-width:0;               /* evita overflow */
  border:none;
  padding:16px 24px;
  font-size:16px;            /* evita zoom iOS y mejora cabida */
  outline:none;
  border-radius:0;
  color:var(--colour-text);
  background-color:#f5eedf;
}

.search-form button{
  border:none;
  padding:16px 32px;
  background:var(--colour-accent);
  color:#f5eedf;
  font-size:16px;
  font-weight:600;
  cursor:pointer;
  transition:background-color .2s;
  border-radius:0;
  white-space:nowrap;
}

.search-form button:hover{
  background:var(--colour-accent-dark);
}

/* ✅ Mobile: apilar en pantallas pequeñas */
@media (max-width: 600px){
  .search-form{
    flex-direction:column;
    border-radius:16px;
    overflow:visible;
    margin-top: 2rem;
  }
  .search-form input[type="text"]{
    width:100%;
    border-bottom:1px solid #eee;
    border-radius:16px 16px 0 0;
            text-align: center;

  }
  .search-form button{
    width:100%;
    border-radius:0 0 16px 16px;
  }
}


/* Features section */
.features-section {
    background-color: var(--colour-section);
    padding: 60px 0;
}

.features-section .container {
  display: block !important;
  max-width: 1100px;
  margin: 0 auto;
}

.feature {
    flex: 1 1 30%;
    text-align: center;
    padding: 0 10px;
}

.feature .icon {
    margin-bottom: 16px;
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.feature h3 {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 1.25rem;
    margin-bottom: 6px;
    color: var(--colour-dark);
}

.feature p {
    font-size: 0.95rem;
    color: var(--colour-text);
    line-height: 1.4;
}
/* Topcompany section */
.topcompany-section {
    background-color: var(--colour-section);
            padding: 60px 0 80px 0;
}


/* === Featured Companies (Nautilus Elegant Style) === */

.cities-section {
    background-color: #E8F9FB;
  padding: 80px 0;
  text-align: center;
}

.cities-section h2 {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  color: #0a2342;
  font-size: 2.2rem;
  margin-bottom: 50px;
  letter-spacing: 0.5px;
}

.cities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 35px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 15px;
}

.city-card {
  display: block;
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  background: #fff;
}

.city-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform 0.6s ease;
  filter: saturate(105%) contrast(102%);
}

.city-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(255,255,255,0) 60%, rgba(0,0,0,0.15) 100%);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.city-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 14px 30px rgba(0,0,0,0.12);
}

.city-card:hover img {
  transform: scale(1.06);
}

.city-card:hover::after {
  opacity: 1;
}

.city-name {
  display: block;
  position: absolute;
  bottom: 0;
  width: 100%;
  padding: 14px 0;
  background: rgba(255,255,255,0.95);
  color: #0a2342;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.3px;
  text-transform: none;
  font-family: 'Inter', sans-serif;
  border-top: 1px solid rgba(0,0,0,0.08);
}
/* Company cards */
.companies-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: space-between;
}

.company-card {
    flex: 1 1 30%;
    background-color: var(--colour-card);
    border-radius: 8px;
    padding: 24px 20px 32px 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

.company-card .stars {
    margin-bottom: 12px;
}

.company-card .stars span {
    color: var(--colour-feature-icon-1);
    font-size: 1.1rem;
    margin-right: 2px;
}

/* When using SVG icons for star ratings, ensure they align nicely */
.company-card .stars svg,
.company-profile-rating svg {
    width: 16px;
    height: 16px;
    margin-right: 2px;
}

/* Numeric rating displayed next to star icons */
.rating-number {
    margin-left: 4px;
    font-size: 0.85rem;
    color: var(--colour-accent);
    font-weight: 600;
}

/* Blog entry title centering and image sizing */
.blog-entry-title {
    text-align: center;
}
.blog-entry-image img {
    max-width: 800px;
    height: auto;
    margin: 0 auto;
    display: block;
}

.company-card .company-icon {
    height: 60px;
    margin-bottom: 10px;
}

.company-card .company-name {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 1.3rem;
    margin-bottom: 8px;
    color: var(--colour-dark);
}

.company-card .company-desc {
    font-size: 0.95rem;
    color: var(--colour-text);
    margin-bottom: 20px;
    min-height: 48px;
}

.company-card .button {
    display: inline-block;
    background-color: var(--colour-accent);
    color: #fff;
    padding: 10px 24px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    text-align: center;
    transition: background-color 0.2s;
}

.company-card .button:hover {
    background-color: var(--colour-accent-dark);
}

/* Blog section */
.blog-section {
    background-color: #E8F9FB;
    padding: 60px 0;
}

.blog-section .container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.blog-section h2 {
    text-align: center;
    font-family: 'Merriweather', Georgia, serif;
    font-size: 2.2rem;
    color: var(--colour-dark);
    margin-bottom: 40px;
}

.blog-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: space-between;
}

.blog-card {
    flex: 1 1 30%;
    background-color: var(--colour-card);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.blog-card .blog-image img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    display: block;
}

.blog-card .blog-content {
    padding: 20px;
}

.blog-card .blog-content h3 {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 1.4rem;
    margin-bottom: 12px;
    color: var(--colour-dark);
}

.blog-card .blog-content p {
    font-size: 0.95rem;
    color: var(--colour-text);
    margin-bottom: 20px;
}

.blog-card .blog-content .button {
    display: inline-block;
    background-color: var(--colour-accent);
    color: #fff;
    padding: 10px 24px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    text-align: center;
    transition: background-color 0.2s;
    text-decoration: none;
}

.blog-card .blog-content .button:hover {
    background-color: var(--colour-accent-dark);
}

/* Blog entry page */
.blog-entry {
    background-color: var(--colour-section);
    padding-bottom: 80px;
}

.blog-entry-title {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 2.2rem;
    color: var(--colour-dark);
    margin-bottom: 24px;
    text-align: center;
}

.blog-entry-image img {
    /* Limit the maximum width of blog images on larger screens so they
       don’t become excessively large.  The width defaults to 100% of
       their container but never exceeds 700px on wide displays. */
    width: 100%;
    max-width: 700px;
    height: auto;
    border-radius: 8px;
    display: block;
    margin: 0 auto 24px auto;
}

.blog-entry-content {
    max-width: 700px;
    margin: 0 auto;
    font-size: 1rem;
    line-height: 1.8;
    color: var(--colour-text);
    padding: 0 20px;
}

.blog-entry-content p {
    margin-bottom: 1.2em;
}

/* Map section */
.map-section {
    background-color: var(--colour-section);
    padding: 60px 0;
}

/* Blog directory styles */
.blog-directory {
    background-color: var(--colour-section);
    padding: 60px 0 80px;
}
.blog-directory .directory-controls {
    max-width: 1100px;
    margin: 0 auto;
}
.blog-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
}
.blog-grid .blog-card {
    flex: 1 1 calc(33.333% - 16px);
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.blog-grid .blog-card .blog-image img {
    /* Ensure all blog thumbnails have the same height on the home page.  We
       use object-fit: cover to crop excess while preserving the aspect
       ratio.  This makes the cards uniform and prevents uneven heights
       across posts. */
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}
.blog-grid .blog-card .blog-content {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex: 1;
}
.blog-grid .blog-card .blog-content h3 {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 1.4rem;
    margin-bottom: 8px;
    color: var(--colour-dark);
}
.blog-grid .blog-card .blog-content p {
    flex: 1;
    font-size: 0.95rem;
    color: var(--colour-text);
    margin-bottom: 12px;
}
.blog-grid .blog-card .blog-content .button {
    align-self: flex-start;
}

/* List view for blog directory */
.blog-grid.list-view .blog-card {
    flex: 1 1 100%;
    flex-direction: row;
    align-items: flex-start;
    gap: 20px;
    padding: 16px;
}
.blog-grid.list-view .blog-card .blog-image {
    flex: none;
    width: 120px;
}
.blog-grid.list-view .blog-card .blog-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}
.blog-grid.list-view .blog-card .blog-content {
    flex: 1;
    padding: 0;
}

/* Company directory list view adjustments */
.company-directory {
    background-color: #E8F9FB;
}

.company-directory .companies-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: space-between;
}

.company-directory .company-card {
    flex: 1 1 30%;
    background-color: #fff;
    border-radius: 14px;
    padding: 24px 20px 24px 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}


.company-directory .company-icon.no-logo {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}


.company-directory .company-card > a {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    text-align: center !important;
}

.company-directory .company-icon {
    width: 92px;
    height: 92px;
    min-width: 92px;
    max-width: 92px;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 18px;
    padding: 12px;
    overflow: hidden;
    margin: 0 auto 16px auto !important;
}

.company-directory .company-icon img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.company-directory .company-name {
    width: 100%;
    text-align: center;
    color: var(--colour-dark);
}

.company-directory .company-name-line {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.company-directory .company-title-text {
    font-size: 1.2rem;
    line-height: 1.2;
    font-weight: 700;
    text-align: center;
}

.company-directory .company-services {
    font-size: 0.98rem;
    line-height: 1.5;
    color: #6b7280;
    margin-top: 4px;
    text-align: center;
}

.company-directory .company-desc {
    display: none;
}

.company-directory .stars {
    margin-top: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: 100%;
}

.company-directory .rating-number {
    font-weight: 600;
    color: var(--colour-accent);
    margin-left: 4px;
}

.company-directory .companies-grid.list-view {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.company-directory .companies-grid.list-view .company-card {
    flex: 1 1 100%;
    display: flex;
    align-items: center;
    text-align: left;
    padding: 16px 18px;
}

.company-directory .companies-grid.list-view .company-card > a {
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 100%;
}

.company-directory .companies-grid.list-view .company-icon {
    width: 80px;
    height: 80px;
    min-width: 80px;
    margin: 0 16px 0 0;
}

.company-directory .companies-grid.list-view .company-name {
    flex: 1;
    text-align: left;
}

.company-directory .companies-grid.list-view .company-name-line {
    justify-content: flex-start;
    margin-bottom: 6px;
}

.company-directory .companies-grid.list-view .company-services {
    text-align: left;
}

.company-directory .companies-grid.list-view .stars {
    width: auto;
    margin-top: 0;
    margin-left: auto;
    justify-content: flex-end;
}

.view-toggle .view-button {
    padding: 8px 16px;
    border-radius: 30px;
    border: 1px solid var(--colour-accent);
    background-color: #fff;
    color: var(--colour-accent);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-toggle .view-button.active {
    background-color: var(--colour-accent);
    color: #fff;
}

.view-toggle .view-button:hover {
    filter: brightness(0.95);
}

@media (max-width: 1024px) {
    .company-directory .company-card {
        flex: 1 1 45%;
    }
}

@media (max-width: 768px) {
    .company-directory .company-card {
        flex: 1 1 100%;
    }

    .company-directory .company-icon {
        width: 82px;
        height: 82px;
        min-width: 82px;
    }

    .company-directory .company-title-text {
        font-size: 1.08rem;
    }

    .company-directory .company-services {
        font-size: 0.93rem;
    }

    .company-directory .companies-grid.list-view .company-card > a {
        flex-wrap: wrap;
    }

    .company-directory .companies-grid.list-view .stars {
        width: 100%;
        justify-content: flex-start;
        margin-top: 10px;
        margin-left: 0;
    }
}

.company-directory .company-card {
    align-items: center !important;
    justify-content: flex-start !important;
    text-align: center !important;
}

.company-directory .company-card > a {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    text-align: center !important;
}

.company-directory .company-icon {
    margin: 0 auto 16px auto !important;
}

.company-directory .company-name {
    width: 100% !important;
    text-align: center !important;
}

.company-directory .company-name-line {
    justify-content: center !important;
}


.verified-only-badge.seal {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 19px;
    height: 19px;
    flex: 0 0 19px;
    transform: translateY(-1px);
}

.verified-only-badge.seal svg {
    display: block;
    width: 19px;
    height: 19px;
}


.map-section .container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.map-section h2 {
    text-align: center;
    font-family: 'Merriweather', Georgia, serif;
    font-size: 2.2rem;
    color: var(--colour-dark);
    margin-bottom: 40px;
}

/* Map search input/button */
.map-search {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
    gap: 12px;
}

.map-search input {
    flex: 1;
    max-width: 300px;
    padding: 10px 16px;
    border: 1px solid #ccc;
    border-radius: 30px;
    font-size: 1rem;
    color: var(--colour-text);
}

.map-search-button {
    background-color: var(--colour-accent);
    color: #fff;
    padding: 10px 24px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s;
}

.map-search-button:hover {
    background-color: var(--colour-accent-dark);
}

/* Company profile page */
.company-profile {
    background-color: var(--colour-section);
    padding: 80px 0;
}

/* About page styles */
.about-page {
    background-color: var(--colour-section);
}

.about-hero {
    position: relative;
    height: 300px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--colour-dark);
}

.about-hero::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.about-hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    padding: 0 20px;
}

.about-hero-content h1 {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 2.8rem;
    margin-bottom: 16px;
    color: #E8F9FB;
}

.about-hero-content p {
    font-size: 1.1rem;
    color: #E8F9FB;
}

.about-content {
    padding: 60px 0 80px;
}

.about-content .container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.about-content h2 {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 1.8rem;
    margin-bottom: 16px;
    color: var(--colour-dark);
}

.about-content p {
    font-size: 1rem;
    margin-bottom: 20px;
    color: var(--colour-text);
    line-height: 1.6;
}

.company-profile .container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.services-list {
    margin-left: 20px;
    margin-bottom: 24px;
    list-style-type: disc;
}

.back-link a {
    color: var(--colour-accent);
    font-weight: 600;
    transition: opacity 0.2s;
}

.back-link a:hover {
    opacity: 0.8;
}

.company-actions .button:hover {
    background-color: var(--colour-accent-dark);
}


/* ===== Company Directory Header (Bootstrap aligned) ===== */
.company-header {
    background-color: #e8f9fb;
    color: var(--colour-dark);
    font-size: 0.95rem;
}


/* ===== Companies in list view ===== */
/* Company Directory section */


.company-directory {
background-color: #E8F9FB;
}
.company-directory .companies-grid.list-view {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.company-directory .companies-grid.list-view .company-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    background-color: var(--colour-card);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.company-directory .companies-grid.list-view .company-card:hover {
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.05);
    transform: translateY(-2px);
}

/* Logo */
.company-directory .companies-grid.list-view .company-icon {
    flex: 0 0 60px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Company name */
.company-directory .companies-grid.list-view .company-name {
    flex: 1;
    font-weight: 600;
    color: var(--colour-dark);
    font-size: 1rem;
}

/* Stars */
.company-directory .companies-grid.list-view .stars {
    flex: 0 0 100px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.25rem;
}

.company-directory .companies-grid.list-view .stars span {
    color: var(--colour-feature-icon-1);
}

.company-directory .companies-grid.list-view .rating-number {
    font-weight: 600;
    color: var(--colour-accent);
    margin-left: 0.25rem;
}

/* Description (visible only on large screens) */
@media (min-width: 992px) {
    .company-directory .companies-grid.list-view .company-desc {
        display: block;
        font-size: 0.9rem;
        color: var(--colour-text);
        margin-top: 0.25rem;
    }
}

/* Button */
.company-directory .companies-grid.list-view .button {
    margin-left: auto;
    padding: 0.4rem 0.9rem;
    font-size: 0.85rem;
    border-radius: 2rem;
}
/* ===== View toggle buttons ===== */
.view-toggle .view-button {
    padding: 8px 16px;
    border-radius: 30px;
    border: 1px solid var(--colour-accent);
    background-color: #fff;
    color: var(--colour-accent);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-toggle .view-button.active {
    background-color: var(--colour-accent);
    color: #fff;
}

.view-toggle .view-button:hover {
    filter: brightness(0.95);
}


/* Responsive behaviour */
@media (max-width: 1024px) {
    .cities-grid .city-card {
        flex: 1 1 45%;
    }
    .company-card {
        flex: 1 1 45%;
    }
}

@media (max-width: 768px) {

    .primary-navigation ul {
        gap: 20px;
    }
    .hero-content h1 {
        font-size: 2.4rem;
    }
    .hero-content p {
        font-size: 1rem;
    }
    .features-section .container {
        flex-direction: column;
        align-items: center;
    }
    .feature {
        flex: none;
        margin-bottom: 30px;
    }
    .cities-grid .city-card,
    .company-card {
        flex: 1 1 100%;
    }
}


/* Blog entry styling */
.blog-entry {
    padding: 60px 0;
    background-color: var(--colour-section);
}
.blog-entry-title {
    font-family: 'Merriweather', Georgia, serif;
    font-size: 2.4rem;
    margin-bottom: 20px;
    color: var(--colour-dark);
    text-align: left;
}
.blog-entry-image img {
    width: 100%;
    max-width: 800px;
    height: auto;
    border-radius: 8px;
    margin: 0 auto 24px auto;
}
.blog-entry-content {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 24px;
    color: var(--colour-text);
}
.blog-entry .back-link a {
    color: var(--colour-accent);
    font-weight: 600;
    transition: opacity 0.2s;
}
.blog-entry .back-link a:hover {
    opacity: 0.8;
}

/*
 * Accent button style
 *
 * This class defines the teal call‑to‑action button used in the
 * header (List Your Company / Publica tu empresa).  We keep the
 * rounded pill shape consistent with the design and ensure good
 * contrast against the dark header.  The hover state darkens the
 * background and adds a subtle box shadow.  Bootstrap’s default
 * button classes remain available if needed, but this class
 * maintains our custom colour palette.
 */
.btn-accent {
    background-color: var(--colour-accent);
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 0.5rem 1.5rem;
    font-weight: 600;
    transition: background-color 0.2s, box-shadow 0.2s;
}
.btn-accent:hover,
.btn-accent:focus {
    background-color: var(--colour-accent-dark);
    color: #fff;
    box-shadow: 0 0 0 0.2rem rgba(0, 169, 157, 0.25);
}

/*
 * CTA button style for the header
 *
 * This button uses a white background with teal text and a
 * teal border, giving it strong contrast on the dark header.  On
 * hover, the background switches to teal and the text becomes white.
 */
.btn-cta {
    background-color: #fff;
    color: var(--colour-accent);
    border: 2px solid var(--colour-accent);
    border-radius: 50px;
    padding: 0.5rem 1.5rem;
    font-weight: 600;
    transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.btn-cta:hover,
.btn-cta:focus {
    background-color: var(--colour-accent);
    color: #fff;
    box-shadow: 0 0 0 0.2rem rgba(0, 169, 157, 0.25);
}