@import url('../main.css');

/* Contacts page: desktop layout */
.contact-content-card {
  width: 85%;
  max-width: calc(100vw - 40px);
  height: 100%;
  margin-top: 12%;
  margin-right: auto;
  margin-bottom: 5%;
  margin-left: auto;
  padding: 0;
  display: flex;
  justify-content: space-between;
  overflow: hidden;
  box-sizing: border-box;
  border-radius: 50px;
  background-color: #FFFFFF;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

/* Left column: intro text + direct contacts */
.contact-left {
  flex: 1;
  max-width: 50%;
  min-width: 0;
  margin-left: 5%;
  box-sizing: border-box;
  overflow-wrap: break-word;
}

.contact-left h1 {
  margin-top: 45%;
  margin-bottom: 5%;
  color: var(--color-accent);
  font-family: "Roboto";
  font-size: clamp(36px, 3vw, 48px);
  font-weight: 700;
}

.contact-left p {
  max-width: 83%;
  margin-bottom: 2%;
  color: var(--color-accent);
  text-align: justify;
  font-family: "Roboto";
  font-size: clamp(14px, 1.2vw, 16px);
  font-weight: 400;
}

.contact-info {
  margin-top: 15%;
  margin-left: 1%;
}

.info-block {
  display: flex;
  align-items: center;
  margin-bottom: 30px;
}

.info-block i {
  margin-right: 15px;
  color: var(--color-accent);
  font-size: 20px;
}

.info-block > div {
  display: flex;
  flex-direction: column;
}

.label {
  margin-bottom: 2px;
  color: #571a297a;
  line-height: 1.2;
  font-family: "Roboto";
  font-size: 14px;
}

.value {
  color: var(--color-accent);
  line-height: 1.2;
  font-family: "Roboto", sans-serif;
  font-size: 18px;
  font-weight: 400;
}

/* Right column: form card */
.contact-right {
  width: 48%;
  max-width: 48%;
  min-width: 0;
  height: 30%;
  margin-top: 5%;
  margin-right: 3%;
  margin-bottom: 5%;
  padding: 25px;
  display: flex;
  justify-content: center;
  box-sizing: border-box;
  border-radius: 50px;
  background-color: #F0EFEB;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.contact-form {
  width: 90%;
  padding: 0;
  color: var(--color-accent);
  background: none;
  box-shadow: none;
}

.form-group {
  margin-bottom: 10px;
}

.contact-form label {
  display: block;
  margin-top: 7%;
  margin-left: 1%;
  color: var(--color-accent);
  line-height: 1.2;
  font-family: "Roboto";
  font-size: 20px;
  font-weight: 500;
}

.contact-form input[type="text"]:first-of-type {
  margin-bottom: 0;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  margin-top: 2%;
  padding: 12px 15px;
  border: none;
  border-radius: 13px;
  color: var(--color-accent);
  background: #ffffff7a;
  box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.02);
  font-family: "Roboto", sans-serif;
  font-size: 16px;
}

/* Unified focus style for all form controls */
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border: 1px solid var(--color-accent);
  box-shadow: 0 0 5px rgba(87, 26, 41, 0.5);
}

.contact-form ::placeholder {
  color: #571a297a;
  opacity: 1;
}

/* Two-column row for email/phone on larger screens */
.email-phone-group {
  display: flex;
  gap: 20px;
}

.email-input,
.phone-input {
  flex: 1;
}

/* Preserves vertical alignment because the phone label is visually empty */
.phone-input label {
  visibility: hidden;
  height: 1.2em;
}

/* Stile per il campo di selezione (Oggetto della richiesta) */
.custom-select-wrapper {
 position: relative;
}

.custom-select-wrapper::after {
 content: "\f078"; /* Icona freccia giù di Font Awesome */
 font-family: 'Font Awesome 6 Free';
 font-weight: 900;
 position: absolute;
 top: 50%;
 right: 15px;
 transform: translateY(-50%);
 color: var(--color-accent);
 pointer-events: none; /* Permette il click sull'elemento select */
}

.contact-form select {
 appearance: none; /* Rimuovi la freccia di default */
 -webkit-appearance: none;
 -moz-appearance: none;
 padding-right: 35px; /* Spazio per l'icona personalizzata */
}

.contact-form textarea {
  min-height: 180px;
  resize: none;
}

.submit-btn-wrapper {
  display: flex;
  justify-content: flex-end;
  margin-top: 20px;
}

.submit-btn {
  width: auto;
  padding: 6px 15px;
  border: none;
  border-radius: 10px;
  color: var(--color-accent);
  background: #F0EFEB;
  cursor: pointer;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: background 0.3s ease;
  font-family: "Roboto";
  font-size: 14px;
  font-weight: 500;
}

.submit-btn:hover {
  opacity: 1;
  text-decoration: underline;
}

/* Responsive breakpoints: 1200, 992, 800, 480 */
@media (max-width: 1200px) {
  .contact-content-card {
    width: 90%;
    margin-top: 13%;
  }

  .contact-left h1 {
    margin-top: 40%;
    font-size: clamp(34px, 3.5vw, 38px);
  }

  .contact-left p {
    font-size: clamp(12px, 1.4vw, 18px);
  }

  .contact-right {
    width: 50%;
    max-width: 50%;
  }

  .contact-form {
    width: 97%;
  }

  .contact-form label {
    font-size: clamp(12px, 1.4vw, 18px);
  }

  .contact-form input,
  .contact-form select,
  .contact-form textarea {
    font-size: clamp(12px, 1.3vw, 16px);
  }


}

@media (max-width: 992px) {
  .contact-content-card {
    width: 90%;
    margin-top: 130px;
    flex-direction: column;
  }

  .contact-left {
    max-width: 100%;
    margin-left: 5%;
    padding: 5% 4%;
  }

  .contact-left h1 {
    margin-top: 0;
    font-size: clamp(32px, 4.5vw, 40px);
  }

  .contact-left p {
    font-size: clamp(16px, 1.6vw, 20px) !important;
  }

  .contact-info {
    margin-top: 8%;
    margin-left: 5%;
    font-size: clamp(14px, 1.6vw, 18px);
  }

  .contact-right {
    width: 85%;
    max-width: 100%;
    margin: auto auto 8% auto;
    padding: 20px 25px;
    border-radius: 50px;
  }

  .contact-form {
    width: 100%;
  }

  .contact-form label {
    font-size: clamp(14px, 1.8vw, 20px);
  }

  .contact-form input,
  .contact-form select,
  .contact-form textarea {
    font-size: clamp(14px, 1.6vw, 16px);
  }
}

@media (max-width: 800px) {
  .contact-content-card {
    width: 98%;
    margin-top: 130px;
    border-radius: 30px;
  }

  .contact-left {
    padding: 4% 3%;
  }

  .contact-left h1 {
    margin-bottom: 4%;
    font-size: clamp(28px, 4.5vw, 32px);
  }

  .contact-left p {
    margin-bottom: 1.5%;
    font-size: clamp(14px, 2vw, 16px);
  }

  .contact-info {
    margin-top: 8%;
  }

  .info-block {
    margin-bottom: 25px;
  }

  .info-block i {
    margin-right: 12px;
    font-size: 18px;
  }

  .label {
    font-size: clamp(12px, 2vw, 14px);
  }

  .value {
    font-size: clamp(16px, 2.2vw, 18px);
  }

  .contact-right {
    padding: 25px 20px;
    border-radius: 30px;
  }

  .contact-form label {
    margin-top: 5%;
    font-size: clamp(16px, 2.2vw, 18px);
  }

  .contact-form input,
  .contact-form select,
  .contact-form textarea {
    padding: 10px 12px;
    font-size: clamp(14px, 2vw, 16px);
  }

  .email-phone-group {
    flex-direction: column;
    gap: 0;
  }

  .contact-form textarea {
    min-height: 150px;
  }

  .submit-btn {
    padding: 5px 12px;
    font-size: clamp(12px, 2.5vw, 14px);
  }
}

@media (max-width: 480px) {
  .contact-content-card {
    width: 100%;
    margin-top: 130px;
    border-radius: 20px;
  }

  .contact-left {
    padding: 3% 2.5%;
  }

  .contact-left h1 {
    font-size: clamp(24px, 5vw, 28px);
  }

  .contact-left p {
    font-size: clamp(13px, 3vw, 14px);
  }

  .contact-info {
    margin-top: 6%;
  }

  .info-block {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    margin-bottom: 20px;
  }

  .info-block i {
    margin-bottom: 5px;
  }

  .label {
    font-size: 12px;
  }

  .value {
    font-size: clamp(14px, 3vw, 16px);
  }

  .contact-right {
    padding: 20px 15px;
    border-radius: 20px;
  }

  .contact-form label {
    margin-top: 4%;
    font-size: clamp(14px, 3vw, 16px);
  }

  .contact-form input,
  .contact-form select,
  .contact-form textarea {
    padding: 8px 10px;
    font-size: 14px;
  }

  .contact-form textarea {
    min-height: 120px;
  }

  .submit-btn {
    padding: 4px 10px;
    font-size: 12px;
  }
}
