/* =====================================================================
   Master Being — UI/UX upgrade (v4.7.4)
   Ładowany PO front(.min).css. Zawiera:
     1) „Drogę mleczną" — świetlisty szlak między Etapem 1 i 2 (sekcja #proces)
     2) Modernizację UX/UI formularzy (modal projektu, konsultacja, chat)
   Zakresowane pod .mb-process-grid / .mb-form / .mb-chat-form, żeby nic nie wyciekło.
   ===================================================================== */

/* ------------------------------------------------------------------ */
/* 1) DROGA MLECZNA MIĘDZY ETAPAMI                                     */
/* ------------------------------------------------------------------ */

/* Domyślnie (mobile / ≤900px): karty stoją w pionie, łącznik w przepływie. */
.mb-milkyway{
  width: min(120px, 42%);
  height: 104px;
  margin: -2px auto 2px;
  position: relative;
  pointer-events: none;
}
.mb-milkyway-svg{ display:block; width:100%; height:100%; overflow:visible; }

.mb-mw-comet{
  filter: drop-shadow(0 0 5px #a855f7) drop-shadow(0 0 11px #06b6d4);
}

/* Desktop: dwie karty obok siebie, szlak wije się pionowo w przerwie między nimi. */
@media (min-width: 901px){
  .mb-process-grid.mb-has-milkyway{
    grid-template-columns: 1fr 1fr;
    gap: clamp(56px, 7vw, 128px);
    position: relative;
  }
  .mb-process-grid.mb-has-milkyway .mb-step{ position: relative; z-index: 1; }
  .mb-process-grid.mb-has-milkyway .mb-milkyway{
    position: absolute;
    top: 10px; bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: clamp(64px, 7vw, 112px);
    height: auto;
    margin: 0;
    z-index: 0;
  }
}

@media (prefers-reduced-motion: reduce){
  .mb-mw-comet{ display: none; }
}

/* ------------------------------------------------------------------ */
/* 2) FORMULARZE — UX/UI                                              */
/* ------------------------------------------------------------------ */

.mb-form .mb-field{ gap: 8px; }

.mb-form .mb-field label,
.mb-form .mb-checkbox{
  font-size: 13.5px;
  font-weight: 600;
  color: #e7e7ea;
  letter-spacing: .005em;
}

/* Pola: większy touch-target (≥48px), 16px font (brak zoomu na iOS), miękkie przejścia. */
.mb-form .mb-field input,
.mb-form .mb-field select,
.mb-form .mb-field textarea{
  width: 100%;
  min-height: 48px;
  padding: 13px 15px;
  border: 1.5px solid var(--mb-border-2, rgba(255,255,255,.14));
  border-radius: 12px;
  background: #0c0c10;
  color: #fff;
  font: inherit;
  font-size: 16px;
  line-height: 1.35;
  transition: border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}

.mb-form .mb-field textarea{ min-height: 108px; resize: vertical; }

.mb-form .mb-field input::placeholder,
.mb-form .mb-field textarea::placeholder{ color: #6b6b73; opacity: 1; }

.mb-form .mb-field input:hover:not(:focus),
.mb-form .mb-field select:hover:not(:focus),
.mb-form .mb-field textarea:hover:not(:focus){
  border-color: rgba(255,255,255,.30);
}

/* Widoczny, dostępny focus (nie tylko kolor). */
.mb-form .mb-field input:focus,
.mb-form .mb-field select:focus,
.mb-form .mb-field textarea:focus{
  outline: none;
  border-color: #a855f7;
  background: #0e0e15;
  box-shadow: 0 0 0 3px rgba(168,85,247,.28);
}

/* Select — własna strzałka, spójna wysokość. */
.mb-form .mb-field select{
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  padding-right: 42px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23a1a1aa' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px 16px;
  cursor: pointer;
}

/* Stan błędu (JS ustawia .mb-field-error / aria-invalid). */
.mb-form .mb-field.mb-field--error input,
.mb-form .mb-field.mb-field--error select,
.mb-form .mb-field.mb-field--error textarea,
.mb-form .mb-field input[aria-invalid="true"],
.mb-form .mb-field select[aria-invalid="true"],
.mb-form .mb-field textarea[aria-invalid="true"]{
  border-color: #f87171;
  box-shadow: 0 0 0 3px rgba(248,113,113,.22);
}
.mb-form .mb-field-error{
  color: #fca5a5;
  font-size: 12.5px;
  font-weight: 500;
  display: block;
  min-height: 1em;
}

.mb-form .mb-field-hint{ color: #8a8a93; font-size: 12px; }

/* Checkbox — większy, własny, dostępny. */
.mb-form .mb-checkbox{
  display: flex;
  gap: 11px;
  align-items: flex-start;
  cursor: pointer;
  font-weight: 500;
  line-height: 1.5;
  color: #c9c9d2;
}
.mb-form .mb-checkbox input[type="checkbox"]{
  appearance: none; -webkit-appearance: none;
  width: 22px; height: 22px; min-width: 22px;
  margin: 1px 0 0;
  border: 1.5px solid var(--mb-border-2, rgba(255,255,255,.14));
  border-radius: 6px;
  background: #0c0c10;
  cursor: pointer;
  position: relative;
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.mb-form .mb-checkbox input[type="checkbox"]:hover{ border-color: rgba(255,255,255,.34); }
.mb-form .mb-checkbox input[type="checkbox"]:focus-visible{
  outline: none;
  box-shadow: 0 0 0 3px rgba(168,85,247,.32);
}
.mb-form .mb-checkbox input[type="checkbox"]:checked{
  background: var(--mb-grad, linear-gradient(135deg,#c084fc,#7c3aed));
  border-color: transparent;
}
.mb-form .mb-checkbox input[type="checkbox"]:checked::after{
  content: "";
  position: absolute;
  left: 7px; top: 3px;
  width: 5px; height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* Przycisk wysyłki — czytelny, pełna szerokość na mobile, focus ring. */
.mb-form .mb-form-submit{
  min-height: 52px;
  width: 100%;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .01em;
}
.mb-form .mb-form-submit:focus-visible{
  outline: none;
  box-shadow: 0 0 0 3px rgba(168,85,247,.42);
}
@media (min-width: 641px){
  .mb-modal-form .mb-form-submit{ width: auto; min-width: 220px; }
}

.mb-form-status{ font-size: 13.5px; }

/* Chat — spójny fokus + brak zoomu na mobile. */
.mb-chat-form input,
.mb-chat-form textarea{ font-size: 16px; }
.mb-chat-form input:focus,
.mb-chat-form textarea:focus{
  outline: none;
  border-color: #a855f7;
  box-shadow: 0 0 0 3px rgba(168,85,247,.25);
}

/* ------------------------------------------------------------------ */
/* 3) KARTY ETAPÓW — delikatny lift (spójny z „drogą mleczną")         */
/* ------------------------------------------------------------------ */
.mb-process-grid .mb-step{
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
@media (hover: hover){
  .mb-process-grid .mb-step:hover{
    transform: translateY(-4px);
    border-color: rgba(168,85,247,.45);
    box-shadow: 0 18px 40px -22px rgba(124,58,237,.55);
  }
}
