/* Padding per pagina */
  body {
    padding-top: 75px !important;
  }

  @media (max-width: 991px) {
    body {
      padding-top: 75px !important;
    }
  }

  @media (max-width: 576px) {
    body {
      padding-top: 65px !important;
    }
  }

  /* ===== Stili specifici per la pagina Ricerca ===== */
  /* Nota: Fonts, variables, reveal, hero, promo card, search box già in hero-contact-unified.css */

  #main .franchising-card {
    transition: transform .25s ease, box-shadow .25s ease;
  }

  #main .franchising-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(2, 8, 20, 0.12);
  }

  #main .logos-row img {
    filter: grayscale(100%);
    opacity: .8;
    transition: opacity .2s ease, filter .2s ease;
  }

  #main .logos-row img:hover {
    filter: grayscale(0%);
    opacity: 1;
  }

  /* ===== TRANSITION SPACER ===== */
  .section-spacer {
    background: linear-gradient(180deg, #fff 0%, #f3bc86ff 100%);
    min-height: 90px;
    position: relative;
  }

  .section-spacer-reverse {
    background: linear-gradient(180deg, #f3bc86ff 0%, #fff 100%);
    min-height: 90px;
    position: relative;
  }

  /* ===== OUR SERVICE SECTION STYLES ===== */
  .our-service-section {
    background: #fff;
    padding: 80px 0;
    position: relative;
    overflow: hidden;
  }

  @media (min-width:1200px) {
    .our-service-section .container {
      max-width: 1400px;
    }
  }

  @media (min-width:1400px) {
    .our-service-section .container {
      max-width: 1600px;
    }
  }

  .service-main-title {
    color: var(--brand-primary);
    font-weight: 800;
    font-size: clamp(1.8rem, 4vw + .5rem, 3.2rem);
    line-height: 1.15;
    margin: 0 0 1rem 0;
    letter-spacing: -.01em;
    text-align: center;
  }

  .service-intro {
    color: #0b3c8c;
    font-size: clamp(1rem, 2vw + .2rem, 1.2rem);
    line-height: 1.6;
    margin: 0 0 2rem 0;
    font-weight: 400;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
    max-width: 900px;
    position: relative;
    z-index: 2;
  }

  .service-content {
    background: #fff;
    color: #0b3c8c;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 12px 32px rgba(11, 60, 140, 0.10);
    border: 2px solid #f28c2a22;
    margin: 2rem 0;
    transition: box-shadow 0.2s ease, transform 0.05s ease;
  }

  .service-content:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 60px rgba(11, 60, 140, 0.18), 0 0 0 2px #f28c2a44;
  }

  .service-list {
    padding-left: 0;
    margin: 0;
    text-align: left;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
  }

  .service-list-item {
    display: flex;
    align-items: flex-start;
    font-size: clamp(1rem, 1.8vw + .2rem, 1.2rem);
    line-height: 1.6;
    color: #0b3c8c;
    font-weight: 400;
  }

  .service-list-item .bullet-icon {
    display: inline-block;
    width: 18px;
    height: 18px;
    min-width: 18px;
    min-height: 18px;
    background-color: #0b3c8c;
    border-radius: 50%;
    margin-right: 15px;
    margin-top: 3px;
    flex-shrink: 0;
  }

  .why-choose-section {
    background: #f3bc86ff;
  }

  @media(max-width: 768px) {
    .our-service-section {
      padding: 60px 0;
    }

    .service-content {
      padding: 30px 20px;
    }

    .service-main-title {
      font-size: clamp(1.5rem, 5vw, 2.2rem);
    }

    .service-intro {
      font-size: clamp(1rem, 3vw, 1.3rem);
    }

    .service-list-item {
      font-size: clamp(0.9rem, 2.5vw, 1.1rem);
    }

    .service-list-item .bullet-icon {
      width: 15px;
      height: 15px;
      min-width: 15px;
      min-height: 15px;
      margin-right: 12px;
      margin-top: 2px;
    }

    .why-choose-section {
      padding: 60px 0;
    }

    .feature-card {
      padding: 30px 20px;
      min-height: 240px;
      margin-bottom: 20px;
    }

    .feature-icon {
      width: 110px;
      height: 110px;
      margin-bottom: 20px;
    }

    .feature-icon img {
      width: 90px !important;
      height: 90px !important;
    }

    .feature-title {
      font-size: clamp(0.9rem, 2.5vw, 1.1rem);
    }
  }

  @media(max-width: 576px) {
    .our-service-section {
      padding: 40px 0;
    }
  }


  .why-choose-title {
    color: #0b3c8c;
    font-weight: 700;
    font-size: clamp(1.8rem, 4vw + .5rem, 3rem);
    line-height: 1.2;
    margin-bottom: 3rem;
  }

  .feature-card {
    background-color: #f3bc86ff;
    border-radius: 16px;
    padding: 40px 30px;
    text-align: center;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 280px;
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
  }

  .feature-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('../images/table5.png');
    background-size: cover;
    background-position: center;
    opacity: 0.85;
    z-index: 1;
    pointer-events: none;
  }

  .feature-card>* {
    position: relative;
    z-index: 2;
  }

  .feature-card:hover {
    transform: translateY(-8px) scale(1.04);
    box-shadow: 0 25px 50px rgba(242, 140, 42, 0.3);
  }

  .feature-icon {
    width: 143px;
    height: 143px;
    background-color: transparent;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    flex-shrink: 0;
    transition: transform 0.05s ease;
    overflow: hidden;
    vertical-align: middle;
  }

  .feature-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    display: block;
  }

  .feature-card:hover .feature-icon {
    transform: scale(1.1);
  }

  .feature-icon i {
    font-size: 2.5rem;
    color: #fff;
  }

  .feature-title {
    color: #fff;
    font-weight: 700;
    font-size: clamp(1rem, 2vw + .3rem, 1.3rem);
    line-height: 1.3;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 15px 20px;
    border-radius: 12px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1),
      0 4px 8px rgba(0, 0, 0, 0.1),
      0 8px 16px rgba(0, 0, 0, 0.1);
    transition: color 0.4s ease, background 0.05s ease;
  }

  .feature-card:hover .feature-title {
    color: #0b3c8c;
    background: rgba(255, 255, 255, 0.25);
  }

  @media(max-width: 768px) {
    .why-choose-section {
      padding: 60px 0;
    }

    .feature-card {
      padding: 30px 20px;
      min-height: 240px;
      margin-bottom: 20px;
    }

    .feature-icon {
      width: 121px;
      height: 121px;
      margin-bottom: 20px;
      border-radius: 12px;
    }

    .feature-icon img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      border-radius: 12px;
      display: block;
    }

    .feature-title {
      font-size: clamp(0.9rem, 2.5vw, 1.1rem);
    }
  }

  @media(max-width: 576px) {

    /* Hero mobile ottimizzato */
    .hero {
      min-height: 80vh;
      padding: 0;
    }

    .hero-bg {
      object-fit: cover;
      object-position: center center;
      width: 100%;
      height: 100%;
      transform: scale(1.08);
    }

    .hero-overlay {
      padding: 40px 0;
      background: transparent;
    }

    .hero::after {
      background: transparent;
    }

    .hero-title {
      font-size: clamp(1.5rem, 7vw, 2.2rem);
      margin-bottom: 0.4rem;
    }

    .hero-sub {
      font-size: clamp(1.1rem, 5vw, 1.5rem);
      margin-bottom: 1rem;
    }

    .promo-card {
      padding: 1.3rem 1.1rem;
      min-height: auto;
      border-radius: 0.9rem;
      margin-top: 1.5rem !important;
    }

    /* Feature cards mobile */
    .feature-card {
      padding: 25px 15px;
      min-height: 200px;
    }

    .feature-icon {
      width: 110px;
      height: 110px;
      margin-bottom: 15px;
      border-radius: 12px;
    }

    .feature-icon img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      border-radius: 12px;
      display: block;
    }
  }

  /* ===== CTA SPLIT SECTION (TEXT + IMAGE) ===== */
  .cta-split-section {
    background: #fff;
    padding: 80px 0;
  }

  .image-text-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
  }

  .grid-block {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.2s ease, transform 0.05s ease;
    position: relative;
  }

  .grid-block:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 40px rgba(11, 60, 140, 0.15);
  }

  .grid-block-image {
    position: relative;
    height: 320px;
    overflow: hidden;
  }

  .grid-block-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.05s ease;
  }

  .grid-block:hover .grid-block-image img {
    transform: scale(1.05);
  }

  .grid-block-text {
    padding: 40px 35px;
    min-height: 320px;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .grid-block-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--brand-primary);
    margin-bottom: 20px;
    line-height: 1.2;
  }

  .grid-block-description {
    font-size: 1.05rem;
    color: #0b3c8c;
    line-height: 1.7;
    margin: 0;
  }

  .grid-block-btn {
    display: inline-block;
    background: #0b3c8c;
    color: #fff;
    border: none;
    border-radius: 999px;
    padding: 12px 28px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .06em;
    box-shadow: 0 8px 20px rgba(2, 6, 23, .18);
    transition: transform .15s var(--ease), box-shadow .2s var(--ease), background .3s ease;
    text-decoration: none;
    margin-top: auto;
    align-self: flex-start;
  }

  .grid-block-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(2, 6, 23, .22);
    background: #0a3578;
    color: #fff;
  }

  @media (max-width: 768px) {
    .cta-split-section {
      padding: 60px 0;
    }

    .image-text-grid {
      grid-template-columns: 1fr;
      gap: 20px;
      display: flex;
      flex-direction: column;
    }

    .grid-block-image {
      height: 250px;
    }

    .grid-block-text {
      padding: 30px 25px;
      min-height: auto;
    }

    .grid-block-title {
      font-size: 1.5rem;
    }

    .grid-block-description {
      font-size: 1rem;
    }
  }

  /* ===== CTA SECTION ===== */
  .cta-section {
    position: relative;
    padding: 130px 20px;
    text-align: center;
    color: #fff;
    background: url('../images/last.png') center/cover no-repeat;
    overflow: hidden
  }

  .cta-section::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(11, 60, 140, 0.5)
  }

  .cta-content {
    position: relative;
    z-index: 2;
    max-width: 860px;
    margin: auto
  }

  .cta-section h2 {
    font-size: 2.1rem;
    font-weight: 1000;
    text-transform: uppercase;
    margin-bottom: 28px;
    letter-spacing: .04em
  }

  .btn-cta {
    background: var(--brand-accent);
    color: #fff;
    border: none;
    padding: 13px 34px;
    font-size: 1.12rem;
    font-weight: 900;
    border-radius: 10px;
    letter-spacing: .04em;
    transition: transform .3s var(--ease), background .3s var(--ease), box-shadow .3s var(--ease);
    box-shadow: var(--shadow-soft)
  }

  .btn-cta:hover {
    background: #d6731d;
    transform: translateY(-2px)
  }

  .cta-bg-parallax {
    transform: translateY(0)
  }

  /* ===== SPACING SECTION ===== */
  .spacing-section {
    background: #fff;
    padding: 60px 0;
  }

  @media(max-width:768px) {
    .spacing-section {
      padding: 40px 0;
    }
  }

  /* ===== PROMOZIONALE SECTION STYLES ===== */
  .promo-highlight-section {
    background: #fff;
    padding: 40px 0 80px 0;
    position: relative;
    overflow: hidden;
  }

  .promo-highlight-section::before {
    content: "";
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    pointer-events: none;
  }

  .promo-highlight-section::after {
    content: "";
    position: absolute;
    bottom: -30%;
    left: -5%;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    pointer-events: none;
  }

  .promo-content {
    position: relative;
    z-index: 2;
  }

  .promo-main-title {
    color: var(--brand-primary);
    font-weight: 800;
    font-size: clamp(1.8rem, 4vw + .5rem, 3.2rem);
    line-height: 1.15;
    margin: 0 0 1rem 0;
    letter-spacing: -.01em;
  }

  .promo-main-title span {
    display: block;
    color: var(--brand-accent);
    font-weight: 600;
    font-size: clamp(1.3rem, 2.8vw + .3rem, 2.2rem);
    margin-top: 0.5rem;
    line-height: 1.3;
  }

  .promo-subtitle {
    color: var(--brand-accent);
    font-weight: 900;
    display: inline-block;
    position: relative;
    padding-bottom: 8px;
  }

  .promo-subtitle::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--brand-accent);
    border-radius: 2px;
  }

  .promo-description {
    color: #0b3c8c;
    font-size: clamp(1rem, 2vw + .2rem, 1.2rem);
    line-height: 1.6;
    margin: 0 0 2rem 0;
    font-weight: 400;
  }

  @media(max-width: 768px) {
    .promo-highlight-section {
      padding: 60px 0;
    }

    .promo-main-title {
      font-size: clamp(1.6rem, 5vw, 2.5rem);
    }

    .promo-description {
      font-size: clamp(0.95rem, 3vw, 1.1rem);
    }
  }

  @media(max-width: 576px) {
    .promo-highlight-section {
      padding: 40px 0;
    }
  }

  /* ===== PAGINATION STYLES ===== */
  .pagination-container {
    display: flex;
    justify-content: center;
    margin: 40px 0;
  }

  .pagination {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 8px;
  }

  .pagination li {
    margin: 0;
  }

  .pagination a,
  .pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: none;
    border: 2px solid transparent;
  }

  .pagination a {
    background: #fff;
    color: var(--brand-primary);
    border-color: #e2e8f0;
  }

  .pagination a:hover {
    background: var(--brand-primary);
    color: #fff;
    border-color: var(--brand-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(11, 60, 140, 0.2);
  }

  .pagination .current {
    background: var(--brand-accent);
    color: #fff;
    border-color: var(--brand-accent);
    font-weight: 800;
  }

  .pagination .disabled {
    background: #f1f5f9;
    color: #cbd5e1;
    cursor: not-allowed;
    border-color: #f1f5f9;
  }

  @media(max-width: 576px) {
    .pagination a,
    .pagination span {
      min-width: 36px;
      height: 36px;
      padding: 6px 10px;
      font-size: 0.85rem;
    }

    .pagination {
      gap: 4px;
    }
  }

  /* ===== HIDE SECTIONS WHEN SEARCH IS ACTIVE ===== */
  #main.search-active .promo-highlight-section,
  #main.search-active .our-service-section,
  #main.search-active .why-choose-section,
  #main.search-active .cta-split-section,
  #main.search-active .contact-form-section,
  #main.search-active .section-spacer,
  #main.search-active .section-spacer-reverse {
    display: none !important;
  }

  /* ===== SEARCH STYLES ===== */
  .search-container {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
  }

  #search-input {
    flex: 1;
    padding: 10px;
    font-size: 1rem;
    border: 2px solid #0b3c8c;
    border-radius: 4px 0 0 4px;
    outline: none;
    transition: border-color 0.05s ease;
  }

  #search-input:focus {
    border-color: #f28c2a;
  }

  #search-button {
    padding: 10px 20px;
    font-size: 1rem;
    color: #fff;
    background: #0b3c8c;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    transition: background 0.05s ease;
  }

  #search-button:hover {
    background: #f28c2a;
  }

  #search-results {
    margin-top: 1rem;
    padding: 1rem;
    background: #fff;
    border: 2px solid #e2e8f0;
    border-radius: 4px;
  }

  #search-results div {
    padding: 0.5rem 0;
    border-bottom: 1px solid #e2e8f0;
  }

  #search-results div:last-child {
    border-bottom: none;
  }

  /* ===== MODAL IMMOBILE ===== */
  .immobile-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeInModal 0.3s ease;
  }

  .immobile-modal.active {
    display: flex;
  }

  @keyframes fadeInModal {
    from { opacity: 0; }
    to { opacity: 1; }
  }

  @keyframes slideUpModal {
    from {
      opacity: 0;
      transform: translateY(30px) scale(0.95);
    }
    to {
      opacity: 1;
      transform: translateY(0) scale(1);
    }
  }

  .immobile-modal-content {
    background: #fff;
    border-radius: 12px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUpModal 0.4s ease;
  }

  .modal-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: none;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  }

  .modal-close-btn:hover {
    background: #fff;
    border-color: var(--brand-primary);
    transform: rotate(90deg);
  }

  .modal-close-btn i {
    font-size: 20px;
    color: #333;
  }

  .modal-close-btn:hover i {
    color: var(--brand-primary);
  }

  .immobile-modal-header {
    position: relative;
    padding: 28px 40px 22px 40px;
    background: linear-gradient(135deg, var(--brand-primary) 0%, #4a6ba8 100%);
    border-radius: 12px 12px 0 0;
  }

  .immobile-modal-title {
    color: #fff;
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0 0 8px 0;
    padding-right: 50px;
    line-height: 1.3;
  }

  .immobile-modal-subtitle {
    color: rgba(255, 255, 255, 0.95);
    font-size: 0.92rem;
    margin: 0;
    font-weight: 500;
  }

  .immobile-modal-body {
    padding: 28px 40px;
  }

  .immobile-modal-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
  }

  .immobile-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
  }

  .immobile-info-item {
    padding: 12px;
    background: #f8fafc;
    border-radius: 8px;
    border-left: 3px solid var(--brand-primary);
  }

  .immobile-info-label {
    color: var(--brand-primary);
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    margin-bottom: 4px;
  }

  .immobile-info-value {
    color: #0b3c8c;
    font-size: 1rem;
    font-weight: 500;
  }

  .immobile-description {
    margin-top: 20px;
    padding: 20px;
    background: #f8fafc;
    border-radius: 8px;
  }

  .immobile-description h4 {
    color: var(--brand-primary);
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 12px;
  }

  .immobile-description p {
    color: #0b3c8c;
    line-height: 1.6;
    margin: 0;
  }

  @media (max-width: 768px) {
    .immobile-modal-content {
      max-width: 95%;
      max-height: 95vh;
    }

    .immobile-modal-header,
    .immobile-modal-body {
      padding: 20px;
    }

    .immobile-info-grid {
      grid-template-columns: 1fr;
      gap: 12px;
    }

    .immobile-modal-title {
      font-size: 1.2rem;
      padding-right: 40px;
    }
  }

  /* ===== CONTACT FORM BUTTON ===== */
  .btn-contact-form {
    background: #0b3c8c;
    color: #fff;
    border: none;
    border-radius: 25px;
    padding: 16px 40px;
    font-weight: 700;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: .02em;
    box-shadow: 0 10px 24px rgba(11, 60, 140, .25);
    transition: transform .15s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease);
    cursor: pointer;
    min-width: 150px;
  }

  .btn-contact-form:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(11, 60, 140, .35);
    background: #062c5e;
    color: #fff;
  }

  .btn-contact-form:active {
    transform: translateY(0);
  }

  .btn-contact-form:disabled {
    background: #a8d8ea;
    color: #64748b;
    cursor: not-allowed;
    box-shadow: 0 4px 12px rgba(168, 216, 234, .15);
  }
