/* chi-siamo.css - Complete and Integrated */

/* ===== GLOBAL VARIABLES ===== */
:root {
  --primary-color: rgb(32, 55, 61);
  --primary-light: rgb(52, 75, 81);
  --secondary-color: #bca454;
  --secondary-light: #e8c874;
  --accent-color: rgb(32, 55, 61);
  --dark-color: #222222;
  --light-color: #f8f9fa;
  --gray-color: #6c757d;
  --white-color: #ffffff;
  --overlay-color: rgba(0, 0, 0, 0.7);
  --font-main: 'Inter', sans-serif;
  --font-heading: 'Playfair Display', serif;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
  --border-radius: 8px;
  --container-width: 1320px;

  /* Text size variables for consistency */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;
  --text-4xl: 2.25rem;
  --text-5xl: 3rem;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  font-size: 16px; /* Consistent base font size */
}

body {
  font-family: var(--font-main);
  color: var(--dark-color);
  background-color: var(--light-color);
  line-height: 1.6;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ===== CONTACT PAGE STYLES ===== */
.contact-main {
  padding: 60px 0;
  background-color: var(--light-gray);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: calc(100vh - 80px);
  box-sizing: border-box;
}

.contact-container {
  display: flex;
  gap: 40px;
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  align-items: stretch;
}

.contact-info-column {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.contact-form-column {
  flex: 1;
  display: flex;
}

.contact-info-card {
  background: var(--white-color);
  padding: 30px 25px;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border: 1px solid var(--secondary-color);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-info-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.contact-info-card h2 {
  color: var(--primary-color);
  font-size: 1.8rem;
  margin-bottom: 25px;
  position: relative;
  padding-bottom: 15px;
  text-align: center;
  width: 100%;
  font-weight: 700;
  font-family: 'Playfair Display', serif;
}

.contact-info-card h2::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: var(--secondary-color);
}

.contact-info-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
  text-align: center;
  width: 100%;
  transition: transform 0.3s ease;
}

.contact-info-item:hover {
  transform: translateX(5px);
}

.contact-icon {
  width: 50px;
  height: 50px;
  background: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.3s ease, background-color 0.3s ease;
  box-shadow: 0 4px 10px rgba(32, 55, 61, 0.15);
}

.contact-icon:hover {
  transform: scale(1.1);
  background-color: var(--secondary-color);
}

.contact-icon svg {
  color: var(--white-color);
  width: 22px;
  height: 22px;
}

.contact-info-text {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.contact-info-text h3 {
  color: var(--primary-color);
  font-size: 1.1rem;
  margin-bottom: 6px;
  font-weight: 600;
  text-align: center;
}

.contact-info-text p {
  color: var(--gray-color);
  font-size: 0.95rem;
  line-height: 1.5;
  text-align: center;
}

.map-container {
  height: 380px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  position: relative;
  border: 1px solid var(--secondary-color);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.map-container:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.map-container iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.contact-form-card {
  background: var(--white-color);
  padding: 30px 25px;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  width: 100%;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--secondary-color);
  height: 100%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-form-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.contact-form-card h2 {
  color: var(--primary-color);
  font-size: 1.8rem;
  margin-bottom: 8px;
  text-align: center;
  font-weight: 700;
  font-family: 'Playfair Display', serif;
}

.form-subtitle {
  color: var(--gray-color);
  margin-bottom: 25px;
  font-size: 1.05rem;
  line-height: 1.5;
  text-align: center;
}

.professional-form {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  gap: 20px;
}

.form-row {
  display: flex;
  gap: 15px;
  margin-bottom: 0;
}

.form-group {
  flex: 1;
  display: flex;
  flex-direction: column;
  margin-bottom: 0;
}

.form-group label {
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--dark-color);
  font-size: 0.95rem;
  display: block;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 14px 16px;
  border: 1px solid #e1e5e9;
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  transition: all 0.3s ease;
  background: #fcfcfc;
  width: 100%;
  box-sizing: border-box;
}

.form-group.message-group textarea {
  min-height: 200px !important;
  height: 100% !important;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(32, 55, 61, 0.1);
  background: #fff;
}

.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 16px;
  padding-right: 45px;
}

/* Message textarea group */
.form-group.message-group {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  margin: 0 !important;
}

.form-group.message-group textarea {
  width: 100% !important;
  min-height: 300px !important;
  height: 100% !important;
  flex-grow: 1 !important;
  padding: 16px !important;
  border: 1px solid #e1e5e9 !important;
  border-radius: 8px !important;
  font-family: inherit !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
  resize: vertical !important;
  background: #fcfcfc !important;
  box-sizing: border-box !important;
}

/* Privacy checkbox styling - FIXED */
.privacy-group {
  display: flex;
  align-items: flex-start;
  margin: 15px 0 20px !important;
  padding: 0;
  gap: 10px;
}

.privacy-group input[type="checkbox"] {
  margin-top: 3px !important;
  width: 18px !important;
  height: 18px !important;
  flex-shrink: 0;
  cursor: pointer;
  /* Ensure checkbox is visible */
  appearance: checkbox;
  -webkit-appearance: checkbox;
  -moz-appearance: checkbox;
}

.privacy-group label {
  display: block !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
  margin: 0 !important;
  cursor: pointer;
  font-weight: normal !important;
  text-align: left;
}

.privacy-group a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s;
}

.privacy-group a:hover {
  color: var(--secondary-color);
  text-decoration: underline;
}

/* Remove the old problematic styles without breaking the checkbox */
.form-group:has(#privacyConsent) {
  all: unset;
}

.form-group:has(#privacyConsent) label,
.form-group:has(#privacyConsent) input[type="checkbox"],
.form-group:has(#privacyConsent) a {
  all: unset;
}

/* Specifically target and reset only the problematic styles */
.form-group:has(#privacyConsent) {
  margin: 15px 0 20px !important;
  padding: 0;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.form-group:has(#privacyConsent) label {
  display: block !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
  margin: 0 !important;
  cursor: pointer;
  font-weight: normal !important;
  text-align: left;
}

.form-group:has(#privacyConsent) input[type="checkbox"] {
  margin-top: 3px !important;
  width: 18px !important;
  height: 18px !important;
  flex-shrink: 0;
  cursor: pointer;
  appearance: checkbox;
  -webkit-appearance: checkbox;
  -moz-appearance: checkbox;
}

.form-group:has(#privacyConsent) a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s;
}

.form-submit {
  margin-top: 4px;
  display: flex;
  justify-content: center;
}

.submit-button {
  background: var(--primary-color);
  color: var(--white-color);
  border: none;
  padding: 14px 35px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  max-width: 280px;
  box-shadow: 0 3px 10px rgba(32, 55, 61, 0.15);
}

.submit-button:hover {
  background: rgb(22, 45, 51);
  transform: translateY(-1px);
  box-shadow: 0 5px 12px rgba(32, 55, 61, 0.25);
}

.submit-button:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(32, 55, 61, 0.15);
}

/* Form response message */
.form-response {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: 6px;
  font-size: 0.9rem;
  text-align: center;
}

/* ===== ENHANCED RESPONSIVE STYLES ===== */

/* Large tablets and small laptops (1024px and below) */
@media (max-width: 1024px) {
  .contact-container {
    width: 92%;
    gap: 25px;
  }
  
  .contact-info-card,
  .contact-form-card {
    padding: 22px 18px;
  }
  
  .map-container {
    height: 320px;
  }
  
  .contact-info-card h2,
  .contact-form-card h2 {
    font-size: 1.5rem;
    margin-top: 5%;
  }
  
  .form-group input,
  .form-group select,
  .form-group textarea {
    padding: 11px 13px;
  }

  .form-group.message-group textarea {
    width: 100% !important;
    min-height: 200px !important;
    max-height: 250px;
    height: 100% !important;
    flex-grow: 1 !important;
    padding: 16px !important;
    border: 1px solid #e1e5e9 !important;
    border-radius: 8px !important;
    font-family: inherit !important;
    font-size: 1rem !important;
    line-height: 1.5 !important;
    resize: vertical !important;
    background: #fcfcfc !important;
    box-sizing: border-box !important;
  }
}

/* Tablet Breakpoint (991px and below) */
@media (max-width: 991px) {
  .contact-container {
    flex-direction: column;
    width: 90%;
    gap: 25px;
  }
  
  .contact-info-column {
    flex-direction: row;
    gap: 20px;
  }
  
  .contact-info-card,
  .contact-form-card {
    padding: 20px;
  }
  
  .map-container {
    height: 300px;
    margin-top: 0;
  }
  
  .contact-info-card h2,
  .contact-form-card h2 {
    font-size: 1.5rem;
  }
  
  .form-row {
    flex-direction: row;
  }
  
  .form-group.message-group textarea {
    min-height: 260px;
  }
}

/* Tablet Portrait (768px and below) */
@media (max-width: 768px) {
  .contact-main {
    padding: 35px 0;
  }
  
  .contact-container {
    width: 92%;
    gap: 20px;
  }
  
  .contact-info-column {
    flex-direction: column;
    gap: 20px;
  }
  
  .contact-info-card,
  .contact-form-card {
    padding: 18px;
  }
  
  .contact-info-item {
    gap: 10px;
    margin-bottom: 16px;
  }
  
  .contact-icon {
    width: 40px;
    height: 40px;
  }
  
  .contact-icon svg {
    width: 18px;
    height: 18px;
  }
  
  .form-row {
    flex-direction: column;
    gap: 0;
    margin-bottom: 0;
  }
  
  .map-container {
    height: 260px;
  }
  
  .form-group.message-group textarea {
    min-height: 240px;
  }
  
  .form-group input,
  .form-group select,
  .form-group textarea {
    padding: 10px 12px;
  }
}

/* Medium Mobile (600px and below) */
@media (max-width: 600px) {
  .contact-main {
    padding: 30px 0;
  }
  
  .contact-container {
    width: 94%;
    gap: 15px;
  }
  
  .contact-info-card,
  .contact-form-card {
    padding: 16px 14px;
    border-radius: 8px;
  }
  
  .contact-info-card h2,
  .contact-form-card h2 {
    font-size: 1.4rem;
    margin-bottom: 16px;
    padding-bottom: 10px;
  }
  
  .contact-info-card h2::after {
    width: 45px;
    height: 2px;
  }
  
  .form-subtitle {
    font-size: 0.95rem;
    margin-bottom: 16px;
  }
  
  .contact-info-item {
    flex-direction: row;
    gap: 10px;
    margin-bottom: 14px;
    text-align: left;
    align-items: flex-start;
  }
  
  .contact-info-text {
    align-items: flex-start;
  }
  
  .contact-info-text h3 {
    font-size: 0.95rem;
  }
  
  .contact-info-text p {
    font-size: 0.85rem;
  }
  
  .form-group label {
    font-size: 0.85rem;
  }
  
  .form-group input,
  .form-group select,
  .form-group textarea {
    padding: 9px 11px;
    font-size: 0.9rem;
  }
  
  .submit-button {
    padding: 12px 25px;
    font-size: 0.95rem;
  }
  
  .map-container {
    height: 220px;
  }
  
  .form-group.message-group textarea {
    min-height: 220px;
  }
}

/* Small Mobile (480px and below) */
@media (max-width: 480px) {
  .contact-main {
    padding: 25px 0;
  }
  
  .contact-container {
    width: 95%;
    gap: 15px;
  }
  
  .contact-info-card,
  .contact-form-card {
    padding: 14px 12px;
  }
  
  .contact-info-card h2,
  .contact-form-card h2 {
    font-size: 1.3rem;
  }
  
  .contact-info-item {
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
    align-items: center;
    text-align: center;
  }
  
  .contact-info-text {
    align-items: center;
  }
  
  .contact-icon {
    width: 36px;
    height: 36px;
  }
  
  .contact-icon svg {
    width: 16px;
    height: 16px;
  }
  
  .form-group input,
  .form-group select,
  .form-group textarea {
    padding: 8px 10px;
  }
  
  .map-container {
    height: 200px;
  }
  
  .form-group.message-group textarea {
    min-height: 110px;
  }
  
  .submit-button {
    padding: 11px 20px;
  }
}

/* Extra Small Mobile (414px and below) */
@media (max-width: 414px) {
  .contact-main {
    padding: 20px 0;
  }
  
  .contact-info-card,
  .contact-form-card {
    padding: 12px 10px;
  }
  
  .contact-info-card h2,
  .contact-form-card h2 {
    font-size: 1.2rem;
  }
  
  .contact-info-text h3 {
    font-size: 0.9rem;
  }
  
  .contact-info-text p {
    font-size: 0.8rem;
  }
  
  .map-container {
    height: 180px;
  }
  
  .form-group:has(#privacyConsent) label {
    font-size: 11px !important;
  }
}

/* iPhone 6/7/8 and similar (375px and below) */
@media (max-width: 375px) {
  .contact-main {
    padding: 15px 0;
  }
  
  .contact-container {
    width: 96%;
    gap: 12px;
  }
  
  .contact-info-card,
  .contact-form-card {
    padding: 10px 8px;
  }
  
  .contact-info-card h2,
  .contact-form-card h2 {
    font-size: 1.15rem;
  }
  
  .form-subtitle {
    font-size: 0.9rem;
  }
  
  .contact-info-item {
    margin-bottom: 12px;
  }
  
  .contact-icon {
    width: 32px;
    height: 32px;
  }
  
  .contact-icon svg {
    width: 14px;
    height: 14px;
  }
  
  .form-group input,
  .form-group select,
  .form-group textarea {
    padding: 8px 10px;
    font-size: 0.85rem;
  }
  
  .submit-button {
    padding: 10px 18px;
    font-size: 0.9rem;
  }
  
  .map-container {
    height: 160px;
  }
}

/* Smallest Mobile (320px and below) */
@media (max-width: 320px) {
  .contact-info-card,
  .contact-form-card {
    padding: 8px 6px;
  }
  
  .contact-info-card h2,
  .contact-form-card h2 {
    font-size: 1.1rem;
    margin-bottom: 12px;
  }
  
  .contact-info-text h3 {
    font-size: 0.85rem;
  }
  
  .contact-info-text p {
    font-size: 0.75rem;
  }
  
  .form-group label {
    font-size: 0.8rem;
  }
  
  .form-group input,
  .form-group select,
  .form-group textarea {
    padding: 7px 9px;
    font-size: 0.8rem;
  }
  
  .submit-button {
    padding: 9px 16px;
    font-size: 0.85rem;
  }
  
  .map-container {
    height: 140px;
  }
  
  .form-group:has(#privacyConsent) label {
    font-size: 10px !important;
  }
}

/* Orientation-specific adjustments */
@media (max-width: 991px) and (orientation: landscape) {
  .contact-main {
    padding: 30px 0;
  }
  
  .contact-container {
    flex-direction: row;
    gap: 15px;
  }
  
  .contact-info-column {
    flex-direction: column;
  }
  
  .map-container {
    height: 220px;
  }
}

@media (max-width: 768px) and (orientation: landscape) {
  .contact-container {
    flex-direction: column;
  }
  
  .contact-info-column {
    flex-direction: row;
    gap: 12px;
  }
  
  .map-container {
    height: 180px;
  }
}

@media (max-width: 600px) and (orientation: landscape) {
  .contact-info-column {
    flex-direction: column;
  }
  
  .map-container {
    height: 160px;
  }
}

/* Fix for form elements on iOS */
@supports (-webkit-touch-callout: none) {
  .form-group input,
  .form-group select,
  .form-group textarea {
    font-size: 16px;
  }
}

/* Height adjustments for form elements to match left column */
@media (min-width: 992px) {
  .professional-form {
    min-height: 650px;
  }
  
  .form-group.message-group textarea {
    min-height: 220px;
  }
}

@media (max-width: 991px) and (min-width: 768px) {
  .professional-form {
    min-height: 580px;
  }
  
  .form-group.message-group textarea {
    min-height: 200px;
  }
}