/*
 Theme Name: RealesWP Child
 Template: realeswp
 Author: Maurizio
 Description: Child theme per RealesWP
 Version: 1.0
*/

/* ==========================
   RESET E WRAPPER
   ========================== */
html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden; /* evita scroll orizzontale */
}
.page-wrapper,
.page-content {
  width: 100% !important;   /* correzione: niente 100vw */
  margin: 0 auto !important;
  padding: 0 !important;
  max-width: 100% !important;
}

/* ==========================
   CUSTOM: Layout filtro immobili
   ========================== */
.immobili-search-form {
  background: #fff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  margin-bottom: 40px;
  color: #222;
  transition: all 0.3s ease;
}
.immobili-search-form:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(0,0,0,0.12);
}
.immobili-search-form .search-title {
  margin: 0 0 20px;
  font-size: 22px;
  font-weight: 700;
  color: #0073e6;
}
.immobili-search-form .form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}
.immobili-search-form .form-group {
  flex: 1 1 220px;
  min-width: 220px;
}
.immobili-search-form label {
  font-weight: 600;
  margin-bottom: 5px;
  display: block;
  color: #333;
}
.immobili-search-form .form-control.input-lg {
  height: 44px;
  font-size: 16px;
  width: 100%;
  border-radius: 6px;
  border: 1px solid #ccc;
  transition: border-color 0.3s ease;
}
.immobili-search-form .form-control.input-lg:focus {
  border-color: #0073e6;
  outline: none;
}
.immobili-search-form .btn-block {
  width: 100%;
  border-radius: 6px;
  transition: background 0.3s ease;
}
.immobili-search-form .btn-block:hover {
  background: #005bb5;
  color: #fff;
}

/* ===========================
   HERO FULLSCREEN
   =========================== */
.hero-fullscreen {
  width: 100%;
  background-image: url('/wp-content/themes/realeswp-child/images/hero.jpg');
  background-size: cover;
  background-position: center;
  height: 100vh;
  margin: 100px 0 0 0; /* 🔧 separa l'hero dalla testata */
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-align: center;
  position: relative;
}
.hero-fullscreen .hero-text {
  background: rgba(0,0,0,0.5);
  padding: 40px;
  border-radius: 12px;
  max-width: 1140px;
  margin: 0 auto;
  backdrop-filter: blur(4px);
  text-align: center;
}
.hero-fullscreen h1 {
  font-size: 3.2rem;
  font-weight: bold;
  margin-bottom: 20px;
  text-shadow: 0 2px 6px rgba(0,0,0,0.4);
}
.hero-fullscreen p {
  font-size: 1.3rem;
}

/* ===========================
   SEZIONE COME FUNZIONA
   =========================== */
.come-funziona {
  padding: 70px 0;
  background: linear-gradient(180deg, #f9f9f9 0%, #fff 100%);
}
.come-funziona h2 {
  text-align: center;
  margin-bottom: 50px;
  font-size: 2.2rem;
  font-weight: 700;
  color: #0073e6;
}
.come-funziona .row h4 {
  margin-top: 15px;
  font-weight: 600;
}
.come-funziona .row p {
  font-size: 0.95rem;
  color: #555;
}
.come-funziona img {
  display: block;
  margin: 0 auto 20px;
  width: 100px;
  height: auto;
  border-radius: 8px;
  transition: transform 0.3s ease;
}
.come-funziona img:hover {
  transform: scale(1.1);
}
.come-funziona .col-md-3 {
  background: #fff;
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  margin-bottom: 30px;
  text-align: center;
  transition: all 0.3s ease;
}
.come-funziona .col-md-3:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 25px rgba(0,0,0,0.12);
}

/* ===========================
   CTA BANNER
   =========================== */
.cta-banner {
  width: 100%;
  background-image: url('/wp-content/themes/realeswp-child/images/city-banner.jpg');
  background-size: cover;
  background-position: center;
  margin: 0;
  padding: 100px 0;
  color: #fff;
  text-align: center;
  position: relative;
}
.cta-banner::before {
  content: "";
  position: absolute;
  top:0; left:0; right:0; bottom:0;
  background: rgba(0,0,0,0.55);
}
.cta-banner .container {
  position: relative;
  z-index: 2;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 15px;
  text-align: center;
}
.cta-banner h2 {
  font-size: 2.4rem;
  margin-bottom: 20px;
  text-shadow: 0 2px 6px rgba(0,0,0,0.4);
}
.cta-banner p {
  font-size: 1.2rem;
  margin-bottom: 25px;
}
.cta-banner .btn {
  background: #5BC5CE;
  border: none;
  padding: 14px 30px;
  font-size: 1.1rem;
  border-radius: 6px;
  color: #000;
  text-decoration: none;
  transition: background 0.3s ease, transform 0.3s ease;
}
.cta-banner .btn:hover {
  background: #E6E6E6;
  transform: translateY(-2px);
}
/* ===========================
   SERVIZI CON SFONDO E TESTO SOVRAPPOSTO
   =========================== */

.servizi {
  padding: 70px 0;
  background-color: #f9f9f9;
}
.servizi h2 {
  text-align: center;
  margin-bottom: 50px;
  font-size: 2.2rem;
  font-weight: 700;
  color: #0073e6;
}
.servizi .row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px; /* 🔧 distanza uniforme tra i box */
}
.servizi .col-md-3 {
  flex: 1 1 calc(25% - 30px); /* 4 colonne su una riga */
  max-width: calc(25% - 30px);
  height: 300px;
  background-size: cover;
  background-position: center;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
  color: #fff;
  position: relative;
}
.servizi .col-md-3:hover {
  transform: scale(1.02);
  box-shadow: 0 6px 25px rgba(0,0,0,0.12);
}
.servizi .col-md-3::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 1;
}
.servizi .col-md-3 h4,
.servizi .col-md-3 p {
  z-index: 2;
  position: relative;
  padding: 0 15px;
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 992px) {
  /* Tablet: 2 colonne per riga */
  .servizi .col-md-3 {
    flex: 1 1 calc(50% - 30px);
    max-width: calc(50% - 30px);
    height: 260px;
  }
}

@media (max-width: 768px) {
  /* Mobile: 1 colonna per riga */
  .servizi .col-md-3 {
    flex: 1 1 100%;
    max-width: 100%;
    height: 240px;
  }
  .servizi .row {
    gap: 20px; /* spazio ridotto su mobile */
  }
}
/* Rimuove sidebar da tutte le pagine */
.page .sidebar,
.page #secondary {
  display: none !important;
}

/* Allarga il contenuto a tutta la larghezza */
.page .content-area,
.page .site-content,
.page .container {
  width: 100% !important;
  max-width: 100% !important;
}
/* Area contenuti bianca e leggibile */
.page .entry-content,
.page .site-content,
.page .content-area {
  background: #fff !important;
  color: #000 !important;
  padding: 30px;
  border-radius: 8px;
}
/* Nasconde la sidebar ovunque */
.page .col-xs-12.sidebar,
.page .col-xs-12#secondary,
.page .col-xs-12.widget-area,
.page .col-xs-12.sidebar-right {
  display: none !important;
}

/* Allarga il contenuto principale */
.page .content-area,
.page .site-content,
.page .container,
.page .col-xs-12 {
  width: 100% !important;
  max-width: 100% !important;
}
/* Nasconde completamente la colonna sidebar */
.page .col-xs-12.sidebar,
.page .col-xs-12#secondary,
.page .col-xs-12.widget-area,
.page .col-xs-12.sidebar-right,
.page .col-xs-12:last-child {
  display: none !important;
}
.home-logo img {
    max-height: 80px;
    width: auto;
}
