/* Import Manrope font */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&display=swap');

:root{
  --soho-accent: #6c2cff;
  --soho-accent-2: #ff3e6c;
  --soho-border: #b6b6b6;
  --soho-text: #2b2b2b;
  --soho-muted: #9aa0a6;
  --soho-radius: 10px;
  --soho-shadow: 0 8px 24px rgba(108,44,255,0.12);
}

/* Form wrapper */
#soho-consultation-form{
  max-width: 720px;
  padding: 20px 30px 30px 0;
  font-family: "Manrope", sans-serif;
  color: var(--soho-text);
  box-sizing: border-box;
}

/* Layout */
.soho-form{
  display:flex;
  flex-direction:column;
  gap:20px;
}

/* Row: two-column layout on desktop */
.soho-row {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  flex-wrap: nowrap;
}

/* === Field wrapper (ensures input + error stack vertically) ===
   JS wraps inputs/selects/textarea into .soho-field-wrapper so the error can be inserted underneath.
*/
.soho-field-wrapper {
  display: flex;
  flex-direction: column;
  width: 100%;
  box-sizing: border-box;
}

/* Make each wrapper inside a row act as the column */
.soho-row > .soho-field-wrapper {
  flex: 1 1 calc(50% - 10px); /* two columns with gap considered */
  min-width: 0;
}

/* Special-case: if a checkbox row contains a field wrapper, allow block layout */
.soho-checkbox-row .soho-field-wrapper { display: block; }

/* Ensure inputs/selects fill wrapper width */
.soho-field-wrapper .soho-input,
.soho-field-wrapper input,
.soho-field-wrapper select,
.soho-field-wrapper textarea {
  width: 100%;
  box-sizing: border-box;
}

/* Inputs & Select */
.soho-input{
  height:52px;
  padding:0 16px;
  border:1px solid var(--soho-border);
  border-radius:var(--soho-radius);
  font-size:13px;
  color:var(--soho-text);
  background:#fff;
  line-height:52px;
  box-sizing:border-box;
  transition:border-color .2s, box-shadow .2s;
}
.soho-input::placeholder{ color:var(--soho-muted); }

/* Select dropdown arrow */
.soho-select{
  appearance:none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='7'><path fill='%23999' d='M1 1l5 5 5-5'/></svg>");
  background-repeat:no-repeat;
  background-position:right 14px center;
  background-size:12px 7px;
}

/* Focus */
.soho-input:focus{
  border-color:var(--soho-accent);
  box-shadow:0 0 0 3px rgba(108,44,255,0.15);
  outline:none;
}

/* Checkbox rows (label wraps input + text) */
.soho-checkbox-row{ margin-top:4px; }
.soho-checkbox-label,
.privacy-text{
  align-items:center; /* center text with checkbox */
  gap:12px;
  font-size:13px;
  line-height:1.4;
}

.privacy-text {
  padding: 10px 0 20px 0;
}

/* --- Custom checkbox styling & override theme/native styles --- */
#soho-consultation-form input.soho-checkbox-input[type="checkbox"]{
  -webkit-appearance:none !important;
  -moz-appearance:none !important;
  appearance:none !important;
  background-image:none !important;

  width:20px !important;
  height:20px !important;
  min-width:20px !important;
  min-height:20px !important;
  box-sizing:border-box !important;
  margin:0 !important;
  padding:0 !important;

  border:2px solid var(--soho-border) !important;
  border-radius:3px !important;
  background:#fff !important;

  position:relative !important; /* make ::after relative */
  cursor:pointer !important;
  transition:all .18s ease !important;
}

#soho-consultation-form label.soho-checkbox-label {
  display: inline-flex !important;
  gap: 8px !important;                /* spacing between box & text */
  cursor: pointer;
  font-size: 13px;
  line-height: 1.4;
}

/* remove old margin-right hack */
#soho-consultation-form label.soho-checkbox-label input.soho-checkbox-input {
  margin: 2px 0 0 0 !important;  /* tiny nudge for baseline alignment */
  flex: 0 0 auto !important;
  display: inline-block !important;
  position: relative !important;
}
/* custom tick centered absolutely */
#soho-consultation-form input.soho-checkbox-input::after{
  content:"" !important;
  position:absolute !important;
  top:50% !important;
  left:50% !important;
  transform:translate(-50%, -50%) rotate(40deg) scale(0) !important;
  transform-origin:center center !important;

  width:4px !important;
  height:8px !important;
  border:solid #fff !important;
  border-width:0 2px 2px 0 !important;
  transition:transform .15s ease !important;
  box-sizing:content-box !important;
}

/* checked state */
#soho-consultation-form input.soho-checkbox-input:checked{
  background:var(--soho-accent) !important;
  border-color:var(--soho-accent) !important;
}
#soho-consultation-form input.soho-checkbox-input:checked::after{
  transform:translate(-50%, -50%) rotate(40deg) scale(1) !important;
}

/* focus ring */
#soho-consultation-form input.soho-checkbox-input:focus-visible{
  outline:none !important;
  box-shadow:0 0 0 3px rgba(108,44,255,0.15) !important;
}

/* small utility */
.soho-checkbox-text{ line-height:1.4; color:var(--soho-text); }
.soho-muted{ color:var(--soho-muted); }

/* Button */
.soho-submit{ margin-top:8px; }
.soho-btn{
  margin-top:10px;
  background: linear-gradient(90deg,#8900FF 0%,#FF675F 100%) !important;
  color:#fff !important;
  border:none !important;
  border-radius:50px !important;
  padding:16px 40px !important;
  font-weight:600 !important;
  transition:all .3s ease;
  cursor:pointer !important;
}
.soho-btn:hover{ transform:translateY(-2px); }

/* Responsive */
@media (max-width:768px){
  #soho-consultation-form{
    padding: 20px 0px 20px 0;
  }
  .soho-row{ flex-direction:column; }
  .soho-row > .soho-field-wrapper { flex: 1 1 100%; }
  .soho-btn{ width:100%; }
}

/* === Error styles === */
/* Error text under each field */
.soho-error-text {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.3;
  color: #d04545;
}

/* Input error visual */
.soho-input-error {
  border-color: #d04545 !important;
  box-shadow: 0 0 0 3px rgba(208,69,69,0.08) !important;
}

/* For checkbox label errors: aligned under label text (indent) */
.soho-checkbox-row .soho-error-text {
  margin-left: 34px;
}

/* Small accessibility/layout fixes */
.soho-row > * { min-width: 0; } /* prevents overflow on long content */
