/* L'Esperto Risponde page */

.bfz-esperto {
  position: relative;
  padding-bottom: 44px;
}

.bfz-esperto-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(34px, 6vw, 70px) 0 clamp(76px, 8vw, 116px);
  background: var(--bfz-blue);
}

.bfz-esperto-hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 34%;
  background: linear-gradient(180deg, rgba(243, 244, 247, 0), rgba(243, 244, 247, 0.96));
  pointer-events: none;
}

.bfz-esperto-hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
}

.bfz-esperto-hero-content {
  max-width: 900px;
  text-align: center;
}

.bfz-esperto-hero-title {
  margin: 0;
  color: var(--bfz-white);
  font-size: clamp(1.85rem, 4vw, 3.15rem);
  line-height: 1.05;
  font-weight: 800;
}

.bfz-esperto-hero-desc {
  margin: 18px auto 0;
  color: rgba(255, 255, 255, 0.87);
  font-size: clamp(1rem, 1.4vw, 1.26rem);
  line-height: 1.45;
  max-width: 64ch;
}

/* Form Section */
.bfz-esperto-section {
  margin-top: clamp(-72px, -6vw, -48px);
  position: relative;
  z-index: 3;
  padding-bottom: 44px;
}

.bfz-esperto-wrapper {
  background: #f3f4f7;
  border: 1px solid rgba(23, 72, 142, 0.14);
  border-radius: 22px;
  box-shadow: 0 24px 48px rgba(23, 43, 70, 0.18);
  overflow: hidden;
  display: grid;
  grid-template-columns: 60% 40%;
  gap: 0;
}

.bfz-esperto-recent-articles {
  padding: clamp(20px, 2.5vw, 32px);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(29, 79, 150, 0.04) 100%);
}

.bfz-esperto-recent-articles h2 {
  font-size: clamp(1.35rem, 2.8vw, 1.75rem);
  color: #1d4f96;
  margin: 0 0 clamp(24px, 3vw, 32px) 0;
  font-weight: 700;
  position: relative;
  padding-left: 12px;
  display: flex;
  align-items: center;
}

.bfz-esperto-recent-articles h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 24px;
  background: linear-gradient(180deg, #1d4f96 0%, #15366d 100%);
  border-radius: 2px;
}

.bfz-esperto-recent-item {
  display: flex;
  gap: clamp(16px, 2vw, 20px);
  margin-bottom: clamp(20px, 2.5vw, 28px);
  padding-bottom: clamp(20px, 2.5vw, 28px);
  border-bottom: 1px solid rgba(23, 72, 142, 0.1);
  transition: all 0.3s ease;
}

.bfz-esperto-recent-item:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.bfz-esperto-recent-item:hover {
  transform: translateX(4px);
}

.bfz-esperto-recent-image {
  flex: 0 0 80px;
  width: 80px;
  height: 80px;
  border-radius: 10px;
  overflow: hidden;
  background: linear-gradient(135deg, #f3f4f7 0%, #e9ecf3 100%);
}

.bfz-esperto-recent-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.bfz-esperto-recent-item:hover .bfz-esperto-recent-image img {
  transform: scale(1.1);
}

.bfz-esperto-recent-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bfz-esperto-recent-category {
  display: inline-flex;
  width: fit-content;
  padding: 3px 8px;
  background: rgba(29, 79, 150, 0.1);
  color: #1d4f96;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.bfz-esperto-recent-title {
  margin: 0;
  font-size: 1rem;
  color: #0e2040;
  font-weight: 700;
  line-height: 1.3;
}

.bfz-esperto-recent-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

.bfz-esperto-recent-item:hover .bfz-esperto-recent-title a {
  color: #1d4f96;
}

.bfz-esperto-recent-excerpt {
  margin: 0;
  font-size: 0.85rem;
  color: #586d85;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.bfz-esperto-recent-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #1d4f96;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
  margin-top: 4px;
  transition: all 0.3s ease;
  width: fit-content;
}

.bfz-esperto-recent-link:hover {
  color: #15366d;
  gap: 8px;
}

.bfz-esperto-form-area {
  padding: clamp(20px, 2.5vw, 32px);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(29, 79, 150, 0.04) 100%);
  position: relative;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(23, 72, 142, 0.14);
}

.bfz-esperto-form-area::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #1d4f96 0%, #15366d 50%, rgba(29, 79, 150, 0) 100%);
  border-radius: 22px 22px 0 0;
  pointer-events: none;
}

.bfz-esperto-form-area h2 {
  font-size: clamp(1.1rem, 2.2vw, 1.35rem);
  color: #1d4f96;
  margin: 0 0 4px 0;
  font-weight: 700;
  position: relative;
  padding-left: 12px;
  display: flex;
  align-items: center;
}

.bfz-esperto-form-area h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 20px;
  background: linear-gradient(180deg, #1d4f96 0%, #15366d 100%);
  border-radius: 2px;
}

.bfz-esperto-form-intro {
  font-size: 0.8rem;
  color: #0e2040;
  margin: 0 0 clamp(14px, 1.8vw, 18px) 0;
  line-height: 1.5;
  background: linear-gradient(135deg, rgba(29, 79, 150, 0.06) 0%, rgba(29, 79, 150, 0.02) 100%);
  padding: 8px 10px;
  border-left: 3px solid #1d4f96;
  border-radius: 8px;
}

/* Collector Section */
.bfz-esperto-collector {
  padding: clamp(50px, 6vw, 80px) 0;
}

.bfz-esperto-collector-header {
  text-align: center;
  margin-bottom: clamp(40px, 5vw, 60px);
}

.bfz-esperto-collector-title {
  font-size: clamp(1.85rem, 4vw, 2.5rem);
  color: #0e2040;
  margin: 0 0 clamp(12px, 1.5vw, 16px) 0;
  font-weight: 800;
}

.bfz-esperto-collector-desc {
  font-size: clamp(0.95rem, 1.5vw, 1.15rem);
  color: #384765;
  margin: 0;
  line-height: 1.5;
}

/* Filter Buttons */
.bfz-esperto-filters {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(10px, 2vw, 14px);
  justify-content: center;
  margin-bottom: clamp(40px, 5vw, 60px);
}

.bfz-esperto-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: clamp(10px, 1.5vw, 14px) clamp(16px, 2.5vw, 22px);
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 999px;
  color: #384765;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.bfz-esperto-filter-btn:hover {
  border-color: #1d4f96;
  color: #1d4f96;
  box-shadow: 0 4px 12px rgba(29, 79, 150, 0.15);
  transform: translateY(-2px);
}

.bfz-esperto-filter-btn.active {
  background: linear-gradient(135deg, #1d4f96 0%, #15366d 100%);
  border-color: #1d4f96;
  color: white;
  box-shadow: 0 8px 24px rgba(29, 79, 150, 0.32);
}

.bfz-filter-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  font-size: 0.8rem;
}

/* Grid di Domande */
.bfz-esperto-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: clamp(24px, 3vw, 32px);
}

.bfz-esperto-card {
  animation: fadeIn 0.4s ease-out;
  opacity: 1;
}

.bfz-esperto-card.hidden {
  display: none;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.bfz-esperto-card-inner {
  height: 100%;
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid rgba(23, 72, 142, 0.12);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}

.bfz-esperto-card:hover .bfz-esperto-card-inner {
  border-color: #1d4f96;
  box-shadow: 0 12px 32px rgba(29, 79, 150, 0.2);
  transform: translateY(-4px);
}

.bfz-esperto-card-image {
  width: 100%;
  height: 200px;
  overflow: hidden;
  background: linear-gradient(135deg, #f3f4f7 0%, #e9ecf3 100%);
}

.bfz-esperto-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.bfz-esperto-card:hover .bfz-esperto-card-image img {
  transform: scale(1.08);
}

.bfz-esperto-card-content {
  padding: clamp(16px, 2vw, 24px);
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.bfz-esperto-card-category {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(29, 79, 150, 0.1) 0%, rgba(29, 79, 150, 0.05) 100%);
  color: #1d4f96;
  font-size: 0.8rem;
  font-weight: 700;
  border-radius: 6px;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.bfz-esperto-card-title {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: #0e2040;
  margin: 0 0 clamp(10px, 1.5vw, 14px) 0;
  font-weight: 700;
  line-height: 1.4;
  flex-grow: 1;
}

.bfz-esperto-card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

.bfz-esperto-card:hover .bfz-esperto-card-title a {
  color: #1d4f96;
}

.bfz-esperto-card-excerpt {
  font-size: 0.9rem;
  color: #586d85;
  margin: 0 0 clamp(12px, 1.5vw, 16px) 0;
  line-height: 1.55;
  flex-grow: 1;
}

.bfz-esperto-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #1d4f96;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.bfz-esperto-card-link:hover {
  color: #15366d;
  gap: 10px;
}

.bfz-esperto-empty {
  text-align: center;
  color: #586d85;
  font-size: 1.1rem;
  grid-column: 1 / -1;
  padding: clamp(40px, 5vw, 60px) 20px;
}

/* Single Page */
.bfz-esperto-single-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(34px, 6vw, 70px) 0 clamp(76px, 8vw, 116px);
  background: var(--bfz-blue);
}

.bfz-esperto-single-hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 34%;
  background: linear-gradient(180deg, rgba(243, 244, 247, 0), rgba(243, 244, 247, 0.96));
  pointer-events: none;
}

.bfz-esperto-single-hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
}

.bfz-esperto-single-hero-content {
  max-width: 900px;
  text-align: center;
}

.bfz-esperto-single-hero-title {
  margin: 0;
  color: var(--bfz-white);
  font-size: clamp(1.85rem, 4vw, 3.15rem);
  line-height: 1.1;
  font-weight: 800;
}

.bfz-esperto-single-hero-desc {
  margin: 16px auto 0;
  color: rgba(255, 255, 255, 0.87);
  font-size: clamp(0.95rem, 1.3vw, 1.15rem);
  line-height: 1.45;
}

.bfz-esperto-single-section {
  margin-top: clamp(-60px, -5vw, -40px);
  position: relative;
  z-index: 3;
  padding-bottom: 44px;
}

.bfz-esperto-single-wrapper {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: clamp(40px, 5vw, 60px);
  background: #f3f4f7;
  border: 1px solid rgba(23, 72, 142, 0.14);
  border-radius: 22px;
  padding: clamp(30px, 3.5vw, 50px);
  box-shadow: 0 24px 48px rgba(23, 43, 70, 0.18);
}

.bfz-esperto-single-content {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(29, 79, 150, 0.02) 100%);
  padding: clamp(24px, 3vw, 36px);
  border-radius: 14px;
  border: 1px solid rgba(29, 79, 150, 0.08);
}

.bfz-esperto-single-content p {
  font-size: 1rem;
  line-height: 1.75;
  color: #384765;
  margin: 0 0 clamp(16px, 2vw, 24px) 0;
}

.bfz-esperto-single-featured {
  width: 100%;
  height: auto;
  margin-bottom: clamp(20px, 3vw, 30px);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.bfz-esperto-single-featured img {
  width: 100%;
  height: auto;
  display: block;
}

.bfz-esperto-single-sidebar {
  display: flex;
  flex-direction: column;
  gap: clamp(20px, 3vw, 28px);
}

.bfz-esperto-single-meta {
  background: #ffffff;
  border: 1px solid rgba(23, 72, 142, 0.12);
  border-radius: 12px;
  padding: clamp(16px, 2vw, 20px);
}

.bfz-esperto-single-meta-title {
  font-size: 0.95rem;
  color: #0e2040;
  margin: 0 0 12px 0;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 2px solid #1d4f96;
  padding-bottom: 8px;
}

.bfz-esperto-single-categories {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bfz-esperto-single-cat-link {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  background: linear-gradient(135deg, rgba(29, 79, 150, 0.08) 0%, rgba(29, 79, 150, 0.02) 100%);
  color: #1d4f96;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  border-left: 3px solid transparent;
}

.bfz-esperto-single-cat-link:hover {
  background: linear-gradient(135deg, rgba(29, 79, 150, 0.15) 0%, rgba(29, 79, 150, 0.08) 100%);
  border-left-color: #1d4f96;
}

.bfz-esperto-single-date {
  font-size: 0.95rem;
  color: #586d85;
  margin: 0;
}

.bfz-esperto-single-back {
  margin-top: auto;
}

.bfz-esperto-back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #1d4f96;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s ease;
}

.bfz-esperto-back-link:hover {
  gap: 12px;
  color: #15366d;
}

/* Related Domande */
.bfz-esperto-single-related {
  margin-top: clamp(50px, 6vw, 80px);
  padding-top: clamp(40px, 5vw, 60px);
  border-top: 2px solid rgba(29, 79, 150, 0.1);
}

.bfz-esperto-related-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: #0e2040;
  margin: 0 0 clamp(30px, 4vw, 40px) 0;
  font-weight: 700;
  text-align: center;
}

.bfz-esperto-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: clamp(20px, 3vw, 28px);
}

.bfz-esperto-related-card {
  padding: clamp(16px, 2vw, 20px);
  background: #ffffff;
  border: 1px solid rgba(23, 72, 142, 0.12);
  border-radius: 10px;
  transition: all 0.3s ease;
}

.bfz-esperto-related-card:hover {
  border-color: #1d4f96;
  box-shadow: 0 8px 20px rgba(29, 79, 150, 0.15);
  transform: translateY(-3px);
}

.bfz-esperto-related-card h3 {
  font-size: 1rem;
  color: #0e2040;
  margin: 0 0 10px 0;
  font-weight: 700;
}

.bfz-esperto-related-card h3 a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

.bfz-esperto-related-card:hover h3 a {
  color: #1d4f96;
}

.bfz-esperto-related-card p {
  font-size: 0.9rem;
  color: #586d85;
  margin: 0 0 12px 0;
  line-height: 1.5;
}

.bfz-esperto-related-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #1d4f96;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: gap 0.3s ease;
}

.bfz-esperto-related-link:hover {
  gap: 8px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 991.98px) {
  .bfz-esperto-wrapper {
    grid-template-columns: 1fr;
  }

  .bfz-esperto-form-area {
    border-right: none;
    border-bottom: 1px solid rgba(23, 72, 142, 0.14);
  }

  .bfz-esperto-recent-articles {
    border-bottom: none;
  }

  .bfz-esperto-single-wrapper {
    grid-template-columns: 1fr;
  }

  .bfz-esperto-filters {
    justify-content: flex-start;
  }
}

@media (max-width: 768px) {
  .bfz-esperto-section {
    padding: clamp(30px, 4vw, 50px) 0;
  }

  .bfz-esperto-form-area {
    padding: clamp(24px, 3vw, 40px);
  }

  .bfz-esperto-collector {
    padding: clamp(40px, 4vw, 60px) 0;
  }

  .bfz-esperto-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: clamp(16px, 2vw, 20px);
  }

  .bfz-esperto-filters {
    flex-wrap: wrap;
    gap: 8px;
  }

  .bfz-esperto-filter-btn {
    padding: 8px 14px;
    font-size: 0.85rem;
  }
}

@media (max-width: 575.98px) {
  .bfz-esperto-hero {
    min-height: clamp(360px, 50vh, 480px);
    padding: clamp(40px, 5vw, 60px) 0;
  }

  .bfz-esperto-form-area {
    padding: clamp(16px, 2.5vw, 24px);
  }

  .bfz-esperto-grid {
    grid-template-columns: 1fr;
  }

  .bfz-esperto-filters {
    gap: 6px;
  }

  .bfz-esperto-filter-btn {
    padding: 7px 12px;
    font-size: 0.8rem;
  }

  .bfz-esperto-single-wrapper {
    padding: clamp(16px, 2.5vw, 24px);
  }

  .bfz-esperto-single-content {
    padding: clamp(16px, 2vw, 20px);
  }
}

/* Contact Form 7 Styling */
.bfz-cf7-wrap {
  margin-top: 12px;
}

.bfz-cf7-wrap .wpcf7-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bfz-cf7-wrap .wpcf7-form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bfz-cf7-wrap .row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.bfz-cf7-wrap .col-md-6 {
  display: flex;
  flex-direction: column;
}

.bfz-cf7-wrap input[type="text"],
.bfz-cf7-wrap input[type="email"],
.bfz-cf7-wrap input[type="tel"],
.bfz-cf7-wrap select,
.bfz-cf7-wrap textarea {
  padding: 8px 10px;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  font-size: 0.85rem;
  line-height: 1.4;
  color: #384765;
  background: #ffffff;
  transition: all 0.3s ease;
  font-family: inherit;
}

.bfz-cf7-wrap input[type="text"]::placeholder,
.bfz-cf7-wrap input[type="email"]::placeholder,
.bfz-cf7-wrap input[type="tel"]::placeholder,
.bfz-cf7-wrap textarea::placeholder {
  color: #9ca3af;
}

.bfz-cf7-wrap input[type="text"]:focus,
.bfz-cf7-wrap input[type="email"]:focus,
.bfz-cf7-wrap input[type="tel"]:focus,
.bfz-cf7-wrap select:focus,
.bfz-cf7-wrap textarea:focus {
  border-color: #1d4f96;
  outline: none;
  box-shadow: 0 0 0 3px rgba(29, 79, 150, 0.1);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.8) 0%, rgba(29, 79, 150, 0.02) 100%);
}

.bfz-cf7-wrap textarea {
  resize: vertical;
  min-height: 80px;
}

.bfz-cf7-wrap select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 width=%2712%27 height=%2712%27 viewBox=%270 0 12 12%27%3E%3Cpath fill=%27%231d4f96%27 d=%27M10.293 3.293L6 7.586 1.707 3.293A1 1 0 00.293 4.707l5 5a1 1 0 001.414 0l5-5a1 1 0 10-1.414-1.414z%27/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 30px;
}

.bfz-cf7-wrap input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin-right: 6px;
  cursor: pointer;
  accent-color: #1d4f96;
}

.bfz-cf7-wrap .wpcf7-form-control-wrap {
  display: flex;
  align-items: center;
}

.bfz-cf7-wrap label {
  color: #384765;
  font-weight: 500;
  font-size: 0.8rem;
}

.bfz-cf7-wrap .wpcf7-submit {
  background: linear-gradient(135deg, #1d4f96 0%, #15366d 100%);
  color: #ffffff;
  border: none;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-top: 8px;
  box-shadow: 0 4px 12px rgba(29, 79, 150, 0.2);
}

.bfz-cf7-wrap .wpcf7-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(29, 79, 150, 0.32);
}

.bfz-cf7-wrap .wpcf7-submit:active {
  transform: translateY(0);
}

.bfz-cf7-wrap .wpcf7-response-output {
  padding: clamp(12px, 1.5vw, 16px) clamp(14px, 2vw, 18px);
  border-radius: 10px;
  margin-bottom: 18px;
  font-weight: 500;
}

.bfz-cf7-wrap .wpcf7-mail-sent-ok {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1) 0%, rgba(34, 197, 94, 0.05) 100%);
  border: 1.5px solid #22c55e;
  color: #15803d;
}

.bfz-cf7-wrap .wpcf7-mail-sent-ng,
.bfz-cf7-wrap .wpcf7-validation-errors {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(239, 68, 68, 0.05) 100%);
  border: 1.5px solid #ef4444;
  color: #991b1b;
}

@media (max-width: 768.98px) {
  .bfz-cf7-wrap .row {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}


/* Form Layout Styling */
.bfz-esperto-form {
  margin-top: 24px;
}

/* Contact Form 7 dentro .bfz-esperto-form */
.bfz-esperto-form .wpcf7-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bfz-esperto-form .wpcf7-form-control-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bfz-esperto-form .wpcf7-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bfz-esperto-form .wpcf7-form-group.row {
  flex-direction: row;
  gap: 18px;
}

.bfz-esperto-form .wpcf7-form-group.row .wpcf7-form-control-wrap {
  flex: 1;
}

.bfz-esperto-form input[type="text"],
.bfz-esperto-form input[type="email"],
.bfz-esperto-form input[type="tel"],
.bfz-esperto-form input[type="number"],
.bfz-esperto-form input[type="date"],
.bfz-esperto-form select,
.bfz-esperto-form textarea {
  padding: clamp(12px, 1.4vw, 16px) clamp(14px, 1.8vw, 18px);
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  font-size: 0.98rem;
  line-height: 1.6;
  color: #384765;
  background: #ffffff;
  transition: all 0.3s ease;
  font-family: inherit;
  width: 100%;
  box-sizing: border-box;
}

.bfz-esperto-form input::placeholder,
.bfz-esperto-form textarea::placeholder {
  color: #9ca3af;
}

.bfz-esperto-form input[type="text"]:focus,
.bfz-esperto-form input[type="email"]:focus,
.bfz-esperto-form input[type="tel"]:focus,
.bfz-esperto-form input[type="number"]:focus,
.bfz-esperto-form input[type="date"]:focus,
.bfz-esperto-form select:focus,
.bfz-esperto-form textarea:focus {
  border-color: #1d4f96;
  outline: none;
  box-shadow: 0 0 0 4px rgba(29, 79, 150, 0.12);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(29, 79, 150, 0.03) 100%);
}

.bfz-esperto-form textarea {
  resize: vertical;
  min-height: 140px;
  max-height: 300px;
}

.bfz-esperto-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 width=%2712%27 height=%2712%27 viewBox=%270 0 12 12%27%3E%3Cpath fill=%27%231d4f96%27 d=%27M10.293 3.293L6 7.586 1.707 3.293A1 1 0 00.293 4.707l5 5a1 1 0 001.414 0l5-5a1 1 0 10-1.414-1.414z%27/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-color: #ffffff;
  padding-right: 40px;
}

.bfz-esperto-form input[type="checkbox"] {
  width: 20px;
  height: 20px;
  min-width: 20px;
  min-height: 20px;
  cursor: pointer;
  accent-color: #1d4f96;
}

.bfz-esperto-form input[type="checkbox"] + span {
  color: #384765;
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  line-height: 1.4;
}

.bfz-esperto-form .wpcf7-checkbox,
.bfz-esperto-form .wpcf7-acceptance {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bfz-esperto-form .wpcf7-submit {
  background: linear-gradient(135deg, #1d4f96 0%, #15366d 100%);
  color: #ffffff;
  border: none;
  padding: clamp(13px, 1.8vw, 17px) clamp(28px, 4vw, 36px);
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  box-shadow: 0 4px 12px rgba(29, 79, 150, 0.24);
  align-self: flex-start;
  margin-top: 10px;
}

.bfz-esperto-form .wpcf7-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(29, 79, 150, 0.32);
}

.bfz-esperto-form .wpcf7-submit:active {
  transform: translateY(0);
}

.bfz-esperto-form .wpcf7-response-output {
  padding: clamp(12px, 1.5vw, 16px) clamp(14px, 2vw, 18px);
  border-radius: 10px;
  margin-bottom: 18px;
  font-weight: 500;
}

.bfz-esperto-form .wpcf7-mail-sent-ok {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1) 0%, rgba(34, 197, 94, 0.05) 100%);
  border: 1.5px solid #22c55e;
  color: #15803d;
}

.bfz-esperto-form .wpcf7-mail-sent-ng,
.bfz-esperto-form .wpcf7-validation-errors {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(239, 68, 68, 0.05) 100%);
  border: 1.5px solid #ef4444;
  color: #991b1b;
}

.bfz-esperto-form .wpcf7-form-control.wpcf7-text,
.bfz-esperto-form .wpcf7-form-control.wpcf7-email,
.bfz-esperto-form .wpcf7-form-control.wpcf7-tel,
.bfz-esperto-form .wpcf7-form-control.wpcf7-number,
.bfz-esperto-form .wpcf7-form-control.wpcf7-date,
.bfz-esperto-form .wpcf7-form-control.wpcf7-select,
.bfz-esperto-form .wpcf7-form-control.wpcf7-textarea {
  padding: clamp(12px, 1.4vw, 16px) clamp(14px, 1.8vw, 18px);
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  font-size: 0.98rem;
  line-height: 1.6;
  color: #384765;
  background: #ffffff;
  transition: all 0.3s ease;
  font-family: inherit;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 768.98px) {
  .bfz-esperto-form .wpcf7-form-group.row {
    flex-direction: column;
    gap: 14px;
  }

  .bfz-esperto-form {
    gap: 16px;
  }
}

.bfz-esperto-form-element {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.bfz-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.bfz-form-col {
  display: flex;
  flex-direction: column;
}

.bfz-form-col-full {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
}

.bfz-form-input,
.bfz-form-select,
.bfz-form-textarea {
  padding: clamp(12px, 1.4vw, 16px) clamp(14px, 1.8vw, 18px);
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  font-size: 0.98rem;
  line-height: 1.6;
  color: #384765;
  background: #ffffff;
  transition: all 0.3s ease;
  font-family: inherit;
  width: 100%;
}

.bfz-form-input::placeholder,
.bfz-form-textarea::placeholder {
  color: #9ca3af;
}

.bfz-form-input:focus,
.bfz-form-select:focus,
.bfz-form-textarea:focus {
  border-color: #1d4f96;
  outline: none;
  box-shadow: 0 0 0 4px rgba(29, 79, 150, 0.12);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(29, 79, 150, 0.03) 100%);
}

.bfz-form-textarea {
  resize: vertical;
  min-height: 140px;
  max-height: 300px;
}

.bfz-form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 width=%2712%27 height=%2712%27 viewBox=%270 0 12 12%27%3E%3Cpath fill=%27%231d4f96%27 d=%27M10.293 3.293L6 7.586 1.707 3.293A1 1 0 00.293 4.707l5 5a1 1 0 001.414 0l5-5a1 1 0 10-1.414-1.414z%27/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 40px;
}

.bfz-form-checkbox-row {
  flex-direction: row;
  align-items: center;
  gap: 10px;
  margin-top: 6px;
}

.bfz-form-checkbox {
  width: 20px;
  height: 20px;
  min-width: 20px;
  min-height: 20px;
  cursor: pointer;
  accent-color: #1d4f96;
}

.bfz-form-label-check {
  color: #384765;
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  margin: 0;
  line-height: 1.4;
}

.bfz-esperto-submit-btn {
  background: linear-gradient(135deg, #1d4f96 0%, #15366d 100%);
  color: #ffffff;
  border: none;
  padding: clamp(13px, 1.8vw, 17px) clamp(28px, 4vw, 36px);
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  box-shadow: 0 4px 12px rgba(29, 79, 150, 0.24);
  align-self: flex-start;
  margin-top: 10px;
}

.bfz-esperto-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(29, 79, 150, 0.32);
}

.bfz-esperto-submit-btn:active {
  transform: translateY(0);
}

@media (max-width: 768.98px) {
  .bfz-form-row {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .bfz-esperto-form-element {
    gap: 16px;
  }
}

