/**
 * Kayıt sihirbazı (site-next) — modal içi düzen.
 * Çakışmaları çözer: floating label + date/select, sticky aksiyon barı, grid spacing,
 * progress göstergesi, terms checkbox hizası.
 */

#site-next-modal-register .sn-reg-wizard-wrap {
  width: 100%;
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 0 0 auto;
}

#site-next-modal-register .sn-reg-wizard {
  width: 100%;
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  min-height: 0;
}

#site-next-modal-register .sn-reg-wizard__form {
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  min-height: 0;
}

#site-next-modal-register .sn-reg-wizard__panels {
  flex: 0 0 auto;
  min-height: 0;
}

#site-next-modal-register .auth_content-4i6g6.sn-auth-body--register,
#site-next-modal-register .sign-up_form-CAEBg.registration_root {
  justify-content: flex-start !important;
}

#site-next-modal-register .sn-reg-wizard__footer {
  flex: 0 0 auto;
  width: 100%;
  margin-top: var(--spacing-16);
}

/* —— Adım göstergesi —— */
#site-next-modal-register .sn-reg-wizard__progress {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-8);
  margin: 0 0 var(--spacing-16);
  padding: 0;
}

#site-next-modal-register .sn-reg-wizard__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #f5f1e8;
  border: 1px solid rgba(0, 0, 0, 0.1);
  flex-shrink: 0;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

#site-next-modal-register .sn-reg-wizard__dot.is-upcoming {
  background: #f5f1e8;
  border-color: rgba(0, 0, 0, 0.1);
}

#site-next-modal-register .sn-reg-wizard__dot.is-active,
#site-next-modal-register .sn-reg-wizard__dot.is-completed {
  background: var(--color-solid-brand-primary-default, #12b857);
  border-color: var(--color-solid-brand-primary-default, #12b857);
}

#site-next-modal-register .sn-reg-wizard__dot.is-current {
  background: #2563eb;
  border-color: #2563eb;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.18);
  transform: scale(1.2);
}

#site-next-modal-register .sn-reg-wizard__line {
  flex: 1 1 auto;
  max-width: 56px;
  min-width: 16px;
  height: 2px;
  margin: 0;
  background: var(--color-border-base-tertiary);
}

#site-next-modal-register .sn-reg-wizard__step-title {
  margin: 0 0 var(--spacing-12);
  font-size: var(--font-body-semibold-font-size);
  font-weight: var(--font-body-semibold-font-weight);
  color: var(--color-content-base-primary);
  text-align: center;
}

#site-next-modal-register .sn-reg-wizard__hint {
  margin: 0 0 var(--modal-padding-modal-gap-stack-form);
  font-size: var(--font-caption-s-regular-font-size);
  line-height: 1.45;
  color: var(--color-content-base-secondary);
}

#site-next-modal-register .sn-reg-wizard__panel {
  display: none;
  width: 100%;
}

#site-next-modal-register .sn-reg-wizard__panel.is-active {
  display: block;
}

#site-next-modal-register .sn-reg-wizard__panel[hidden] {
  display: none !important;
}

/* Tüm alanlar modalın tam genişliğini alsın — yarım kalmasın */
#site-next-modal-register .sn-reg-wizard__panels,
#site-next-modal-register .sn-reg-wizard__panel,
#site-next-modal-register .sn-reg-wizard__form,
#site-next-modal-register .sn-reg-wizard,
#site-next-modal-register .sn-reg-wizard-wrap,
#site-next-modal-register .field-wrapper_root-xSBJ6,
#site-next-modal-register .field-wrapper_control-xSBJ6 {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

#site-next-modal-login .sn-login-field,
#site-next-modal-login .field-wrapper_root-xSBJ6,
#site-next-modal-login .field-wrapper_control-xSBJ6 {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

/* —— Alan grid'i —— */
#site-next-modal-register .sn-reg-wizard__fields {
  display: flex;
  flex-direction: column;
  gap: 0;
}

#site-next-modal-register .sn-reg-wizard__grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: var(--spacing-12);
  row-gap: 0;
}

@media (max-width: 480px) {
  #site-next-modal-register .sn-reg-wizard__grid-2 {
    grid-template-columns: 1fr;
  }
}

/* Grid içindeki alanlar dahil tüm field-wrapper'larda eşit dikey boşluk */
#site-next-modal-register .sn-reg-wizard__fields .field-wrapper_root-xSBJ6 {
  margin-bottom: var(--modal-padding-modal-gap-stack-form) !important;
}

/* —— Telefon alanı —— */
#site-next-modal-register .sn-reg-phone-field__row {
  display: flex;
  align-items: center;
  gap: var(--spacing-8);
  width: 100%;
  min-width: 0;
}

#site-next-modal-register .sn-reg-phone-field--prefixed .base-field_label-ttxw4 {
  transform: scale(0.72) translateY(-17px);
  inset-inline-start: 0;
  max-width: calc(100% - var(--spacing-8));
}

#site-next-modal-register .sn-reg-phone-field--prefixed .base-field_controlContent-ttxw4 {
  transform: translateY(7px);
}

#site-next-modal-register .sn-reg-phone-field__code {
  flex-shrink: 0;
  font-size: var(--font-body-regular-font-size);
  font-weight: var(--font-body-semibold-font-weight);
  color: var(--color-content-base-primary);
  line-height: 1.25;
  user-select: none;
}

#site-next-modal-register .sn-reg-phone-field__input,
#site-next-modal-register .sn-reg-phone-field input[type='tel'] {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  font: inherit;
  color: var(--color-content-base-primary);
}

#site-next-modal-register .sn-reg-phone-field__input:focus,
#site-next-modal-register .sn-reg-phone-field input[type='tel']:focus {
  outline: none;
}

#site-next-modal-register .sn-reg-phone-field__input::placeholder,
#site-next-modal-register .sn-reg-phone-field input[type='tel']::placeholder {
  color: var(--color-content-base-tertiary);
  opacity: 1;
}

#site-next-modal-register .sn-reg-phone-field__flag img {
  display: block;
  border-radius: 2px;
}

/* —— Tarih + select: floating label çakışmasını gider ——
 * Blade tarafı bu alanlara `base-field_filled-ttxw4` ekliyor (label yukarıda kilitli).
 * Aşağıdaki :has() kuralları, JS hata verirse veya class düşerse safety net. */
#site-next-modal-register .sn-reg-field-date .base-field_label-ttxw4,
#site-next-modal-register .field-wrapper_root-xSBJ6:has(.sn-reg-select) .base-field_label-ttxw4 {
  transform: scale(0.72) translateY(-17px);
}

#site-next-modal-register .sn-reg-field-date .base-field_controlContent-ttxw4,
#site-next-modal-register .field-wrapper_root-xSBJ6:has(.sn-reg-select) .base-field_controlContent-ttxw4 {
  transform: translateY(7px);
}

/* Native chevron yerine custom ok */
#site-next-modal-register .sn-reg-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%239aa3b5'><path d='M3.293 5.793a1 1 0 0 1 1.414 0L8 9.086l3.293-3.293a1 1 0 1 1 1.414 1.414l-4 4a1 1 0 0 1-1.414 0l-4-4a1 1 0 0 1 0-1.414Z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 14px 14px;
  padding-right: 26px;
  cursor: pointer;
}

#site-next-modal-register .sn-reg-select::-ms-expand {
  display: none;
}

/* Native date alanını biraz nötrleyelim (Chrome/Safari iç render) */
#site-next-modal-register .sn-reg-field-date input[type='date'] {
  font-family: inherit;
  color: var(--color-content-base-primary);
}

#site-next-modal-register .sn-reg-field-date input[type='date']::-webkit-date-and-time-value {
  text-align: left;
}

#site-next-modal-register .sn-reg-field-date input[type='date']::-webkit-calendar-picker-indicator {
  filter: invert(0.7);
  opacity: 0.85;
  cursor: pointer;
}

/* —— Promosyon / link —— */
#site-next-modal-register .sn-reg-wizard__link {
  display: inline-block;
  margin: 0 0 var(--modal-padding-modal-gap-form);
  padding: var(--spacing-4) 0;
  border: 0;
  background: none;
  cursor: pointer;
  font: inherit;
  font-size: var(--font-body-semibold-font-size);
  font-weight: var(--font-body-semibold-font-weight);
  color: var(--color-solid-brand-primary-default);
  text-align: left;
}

#site-next-modal-register .sn-reg-wizard__link:hover {
  text-decoration: underline;
}

#site-next-modal-register .sn-reg-wizard__promo {
  margin-bottom: var(--modal-padding-modal-gap-form);
}

#site-next-modal-register .sn-reg-wizard__promo[hidden] {
  display: none !important;
}

/* —— Terms checkbox ——
 * Vendor `.checkbox_box-qop45` `position: absolute; inset: 0` ile gelir;
 * `.checkbox_inputWrapper-qop45` (20×20, position: relative) sarmalayıcısı içinde olması gerek.
 * Markup'ımızda sarmalayıcı olmadığı için kutu absolute ile tüm paneli kaplıyordu (yeşil ekran bug).
 * Bu sebeple kutuyu inline 20×20 olarak normal akışa geri alıyoruz.
 */
#site-next-modal-register .sn-reg-wizard__terms {
  display: flex;
  align-items: center;
  gap: var(--spacing-12);
  margin: 0 0 var(--modal-padding-modal-gap-form);
  padding: var(--spacing-4) 0;
  cursor: pointer;
}

#site-next-modal-register .sn-reg-wizard__terms .checkbox_box-qop45 {
  position: relative !important;
  inset: auto !important;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

#site-next-modal-register .sn-reg-wizard__terms .checkbox_box-qop45 svg {
  width: 12px;
  height: 12px;
  display: none;
}

#site-next-modal-register .sn-reg-wizard__terms .checkbox_input-qop45:checked + .checkbox_box-qop45 svg {
  display: block;
}

#site-next-modal-register .sn-reg-wizard__terms-text {
  font-size: var(--font-caption-s-regular-font-size);
  line-height: 1.45;
  color: var(--color-content-base-secondary);
}

#site-next-modal-register .sn-reg-wizard__terms-text a {
  color: var(--color-solid-brand-primary-default);
  font-weight: var(--font-caption-s-semibold-font-weight);
  text-decoration: none;
}

#site-next-modal-register .sn-reg-wizard__terms-text a:hover {
  text-decoration: underline;
}

/* —— Hint / hata mesajları —— */
#site-next-modal-register .sn-reg-field-hint {
  margin: 0 0 var(--modal-padding-modal-gap-form);
  font-size: var(--font-caption-s-regular-font-size);
  line-height: 1.4;
  color: var(--color-content-base-secondary);
}

#site-next-modal-register .sn-reg-field-hint--error {
  color: var(--color-solid-sentiment-negative-default);
}

#site-next-modal-register .sn-reg-field-hint[hidden] {
  display: none !important;
}

/* —— Alt aksiyon barı (inputların hemen altında) —— */
#site-next-modal-register .sn-reg-wizard__actions {
  position: static;
  display: flex;
  flex-wrap: nowrap;
  gap: var(--spacing-12);
  margin: 0;
  padding: 0;
  align-items: stretch;
}

#site-next-modal-register .sn-reg-wizard__btn-back {
  flex: 0 0 auto;
  min-width: 96px;
}

#site-next-modal-register .sn-reg-wizard__btn-next,
#site-next-modal-register .sn-reg-wizard__btn-submit {
  flex: 1 1 auto;
  min-width: 0;
}

#site-next-modal-register .sn-reg-wizard__btn-next[hidden],
#site-next-modal-register .sn-reg-wizard__btn-submit[hidden],
#site-next-modal-register .sn-reg-wizard__btn-back[hidden] {
  display: none !important;
}

/* —— Alt giriş yap satırı (butonların hemen altında) —— */
#site-next-modal-register .sn-reg-wizard__switch {
  margin: var(--spacing-16) 0 0;
  text-align: center;
}

/* —— Sunucu/istemci uyarı kutusu —— */
#site-next-modal-register .sn-auth-alert {
  margin-bottom: var(--modal-padding-modal-gap-stack-form);
  padding: var(--spacing-12) var(--spacing-16);
  border-radius: var(--rounding-component-popover);
  border: 1px solid var(--color-border-sentiment-negative-default);
  color: var(--color-solid-sentiment-negative-default);
  font-size: var(--font-caption-s-regular-font-size);
  line-height: 1.4;
  background-color: color-mix(in srgb, var(--color-solid-sentiment-negative-default) 10%, transparent);
}

@supports not (background-color: color-mix(in srgb, red 10%, transparent)) {
  #site-next-modal-register .sn-auth-alert {
    background-color: rgba(220, 53, 69, 0.08);
  }
}

#site-next-modal-register .sn-auth-alert[hidden] {
  display: none !important;
}

#site-next-modal-register .sn-auth-alert__row + .sn-auth-alert__row {
  margin-top: var(--spacing-6);
}

/* —— Modal kart boyutları (desktop) ——
 * Vendor default `desktop-modal_size-small-FWyPd` = 390px; çok dar.
 * 460px daha rahat (ad+soyad / il+ilçe grid'i için).
 */
@media (min-width: 1024px) {
  #site-next-modal-register .sn-reg-wizard-card.desktop-modal_card-FWyPd {
    max-width: 460px;
  }

  #site-next-modal-register .sn-reg-wizard-card.desktop-modal_scrollable-FWyPd {
    max-height: var(--sn-modal-desktop-max-height);
  }
}

/* —— Ikon olmayan alanlar (firstName/lastName/il/ilce) için padding düzeltmesi —— */
#site-next-modal-register .field-wrapper_root-xSBJ6:not(:has(.base-field_iconStart-ttxw4))
  .base-field_content-ttxw4 {
  padding-left: var(--spacing-16);
}

/* —— Profil tamamlama: kayıt form alanı kurallarını paylaş —— */
#site-next-modal-complete-profile .sn-complete-profile-wrap,
#site-next-modal-complete-profile .sn-complete-profile__form,
#site-next-modal-complete-profile .sn-reg-wizard__fields,
#site-next-modal-complete-profile .field-wrapper_root-xSBJ6,
#site-next-modal-complete-profile .field-wrapper_control-xSBJ6 {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

#site-next-modal-complete-profile .sn-reg-wizard__fields {
  display: flex;
  flex-direction: column;
  gap: 0;
}

#site-next-modal-complete-profile .sn-reg-wizard__grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: var(--spacing-12);
  row-gap: 0;
}

@media (max-width: 480px) {
  #site-next-modal-complete-profile .sn-reg-wizard__grid-2 {
    grid-template-columns: 1fr;
  }
}

#site-next-modal-complete-profile .sn-reg-wizard__fields .field-wrapper_root-xSBJ6 {
  margin-bottom: var(--modal-padding-modal-gap-stack-form) !important;
}

#site-next-modal-complete-profile .sn-reg-phone-field__row {
  display: flex;
  align-items: center;
  gap: var(--spacing-8);
  width: 100%;
  min-width: 0;
}

#site-next-modal-complete-profile .sn-reg-phone-field--prefixed .base-field_label-ttxw4 {
  transform: scale(0.72) translateY(-17px);
  inset-inline-start: 0;
  max-width: calc(100% - var(--spacing-8));
}

#site-next-modal-complete-profile .sn-reg-phone-field--prefixed .base-field_controlContent-ttxw4 {
  transform: translateY(7px);
}

#site-next-modal-complete-profile .sn-reg-phone-field__code {
  flex-shrink: 0;
  font-size: var(--font-body-regular-font-size);
  font-weight: var(--font-body-semibold-font-weight);
  color: var(--color-content-base-primary);
  line-height: 1.25;
  user-select: none;
}

#site-next-modal-complete-profile .sn-reg-phone-field__input,
#site-next-modal-complete-profile .sn-reg-phone-field input[type='tel'] {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  font: inherit;
  color: var(--color-content-base-primary);
}

#site-next-modal-complete-profile .sn-reg-phone-field__input:focus,
#site-next-modal-complete-profile .sn-reg-phone-field input[type='tel']:focus {
  outline: none;
}

#site-next-modal-complete-profile .sn-reg-phone-field__input::placeholder,
#site-next-modal-complete-profile .sn-reg-phone-field input[type='tel']::placeholder {
  color: var(--color-content-base-tertiary);
  opacity: 1;
}

#site-next-modal-complete-profile .sn-reg-phone-field__flag img {
  display: block;
  border-radius: 2px;
}

#site-next-modal-complete-profile .sn-reg-field-date .base-field_label-ttxw4,
#site-next-modal-complete-profile .field-wrapper_root-xSBJ6:has(.sn-reg-select) .base-field_label-ttxw4 {
  transform: scale(0.72) translateY(-17px);
}

#site-next-modal-complete-profile .sn-reg-field-date .base-field_controlContent-ttxw4,
#site-next-modal-complete-profile .field-wrapper_root-xSBJ6:has(.sn-reg-select) .base-field_controlContent-ttxw4 {
  transform: translateY(7px);
}

#site-next-modal-complete-profile .sn-reg-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%239aa3b5'><path d='M3.293 5.793a1 1 0 0 1 1.414 0L8 9.086l3.293-3.293a1 1 0 1 1 1.414 1.414l-4 4a1 1 0 0 1-1.414 0l-4-4a1 1 0 0 1 0-1.414Z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 14px 14px;
  padding-right: 26px;
  cursor: pointer;
}

#site-next-modal-complete-profile .sn-reg-select::-ms-expand {
  display: none;
}

#site-next-modal-complete-profile .sn-reg-field-date input[type='date'] {
  font-family: inherit;
  color: var(--color-content-base-primary);
}

#site-next-modal-complete-profile .sn-reg-field-date input[type='date']::-webkit-date-and-time-value {
  text-align: left;
}

#site-next-modal-complete-profile .sn-reg-field-date input[type='date']::-webkit-calendar-picker-indicator {
  filter: invert(0.7);
  opacity: 0.85;
  cursor: pointer;
}

#site-next-modal-complete-profile .field-wrapper_root-xSBJ6:not(:has(.base-field_iconStart-ttxw4))
  .base-field_content-ttxw4 {
  padding-left: var(--spacing-16);
}

#site-next-modal-complete-profile .base-field_control-ttxw4,
#site-next-modal-complete-profile .base-field_controlContent-ttxw4,
#site-next-modal-complete-profile .control_root-5SZBQ {
  width: 100%;
  min-width: 0;
}

#site-next-modal-complete-profile .mask-input_input-GDetI,
#site-next-modal-complete-profile .control_root-5SZBQ input,
#site-next-modal-complete-profile .sn-reg-select {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

@media (min-width: 1024px) {
  #site-next-modal-complete-profile .sn-complete-profile-card.desktop-modal_card-FWyPd {
    max-width: 460px;
  }

  #site-next-modal-complete-profile .sn-complete-profile-card.desktop-modal_scrollable-FWyPd {
    max-height: var(--sn-modal-desktop-max-height);
  }
}
