@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  background-color: transparent; /* Прозорий фон для ідеальної інтеграції */
  padding: 0;
  margin: 0;
  color: #111827;
}

.form-container {
  width: 100%;
  /* max-width: 480px;  Прибираємо обмеження ширини, хай займає контейнер батька */
  margin: 0 auto;
}

.consultation-form {
  background-color: #ffffff;
  /* Прибираємо жорстку рамку */
  border: 1px solid #f3f4f6;
  border-radius: 12px;
  padding: 32px; /* Трохи більше внутрішнього відступу теж не завадить */
  /* Легка, дорога тінь замість синьої рамки */
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  gap: 24px; /* Більше повітря між полями */
}

/* INPUTS & SELECTS */
.input-group {
  position: relative;
  width: 100%;
}

.input-group input,
.input-group select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  background-color: #f9fafb; /* Ледве сірий для контрасту */
  color: #1f2937;
  transition: all 0.2s ease;
}

.input-group input:hover,
.input-group select:hover {
  border-color: #d1d5db;
  background-color: #ffffff;
}

.input-group input:focus,
.input-group select:focus {
  outline: none;
  border-color: #2563eb;
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.input-group input::placeholder {
  color: #9ca3af;
}

/* Phone Group Styling */
.phone-group {
  display: flex;
  gap: 10px;
}

.country-selector {
  flex-shrink: 0;
  width: 140px; /* Фіксована ширина для селекту країни */
}

.country-selector select {
  padding-right: 20px;
  text-overflow: ellipsis;
}

/* Custom Checkboxes */
.checkbox-group {
  margin-top: 5px;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  cursor: pointer;
  gap: 12px;
  user-select: none;
}

.checkbox-label input[type="checkbox"] {
  display: none;
}

.checkmark {
  width: 20px;
  height: 20px;
  border: 2px solid #d1d5db;
  border-radius: 5px;
  flex-shrink: 0;
  margin-top: 2px;
  position: relative;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  background-color: #fff;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
  background-color: #2563eb;
  border-color: #2563eb;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 2px;
  width: 4px;
  height: 9px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-text {
  font-size: 14px;
  color: #4b5563;
  line-height: 1.4;
}

/* Submit Button - Gradient */
.submit-btn {
  width: 100%;
  padding: 16px;
  margin-top: 24px; /* Більше відступу перед кнопкою */

  /* Use gradient matching the site logo/theme */
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);

  color: #ffffff;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition:
    transform 0.1s,
    box-shadow 0.2s;
  box-shadow:
    0 4px 6px -1px rgba(37, 99, 235, 0.2),
    0 2px 4px -1px rgba(37, 99, 235, 0.1);
}

.submit-btn:hover {
  background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
  box-shadow:
    0 10px 15px -3px rgba(37, 99, 235, 0.3),
    0 4px 6px -2px rgba(37, 99, 235, 0.15);
  transform: translateY(-1px);
}

.submit-btn:active {
  transform: translateY(1px);
}

.submit-btn:disabled {
  background: #9ca3af;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Social Icons */
.social-icons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid #f3f4f6;
}

.social-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px; /* Squrcle looks more modern */
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all 0.2s;
}

.social-icon:hover {
  transform: translateY(-2px);
  filter: brightness(1.1);
}

/* Info Text */
.info-text {
  font-size: 13px;
  color: #6b7280;
  text-align: center;
  margin-top: 5px;
}

/* Validation Errors */
.error-message {
  font-size: 12px;
  color: #ef4444;
  margin-top: 4px;
  margin-left: 2px;
  display: none;
}

.input-group input.error,
.input-group select.error {
  border-color: #ef4444;
  background-color: #fef2f2;
}

.input-group input.error + .error-message,
.input-group select.error + .error-message,
.checkbox-group.error .error-message {
  display: block;
}

/* Mobile Adjustments */
@media (max-width: 480px) {
  .consultation-form {
    padding: 20px 16px;
    box-shadow: none;
    border: none;
    background: transparent;
  }

  .phone-group {
    flex-direction: column;
    gap: 12px;
  }

  .country-selector {
    width: 100%;
  }
}
