/* Rahat Kredit – mobil / telefon uyğunlaşdırması */

html,
body {
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

#root {
  overflow-x: hidden;
  max-width: 100%;
}

/* —— Depozit səhifəsi —— */
[data-testid="payment-start-btn"] {
  white-space: normal !important;
  word-break: break-word;
  overflow-wrap: anywhere;
  line-height: 1.35 !important;
  height: auto !important;
  min-height: 3rem;
}

[data-testid="payment-start-btn"] svg {
  flex-shrink: 0;
}

[data-testid="deposit-amount"] {
  line-height: 1.15 !important;
  word-break: break-word;
}

.ss-deposit-operator-text {
  word-break: break-word;
  overflow-wrap: anywhere;
  hyphens: auto;
  max-width: 100%;
  line-height: 1.45 !important;
}

body.ss-route-depozit [data-testid="deposit-amount"] {
  font-size: clamp(1.75rem, 9vw, 3rem) !important;
}

body.ss-route-depozit [data-testid="payment-start-btn"] {
  font-size: clamp(0.9rem, 3.8vw, 1.15rem) !important;
  padding-top: 0.875rem !important;
  padding-bottom: 0.875rem !important;
}

body.ss-route-depozit .ss-deposit-operator-text {
  font-size: clamp(0.8125rem, 3.4vw, 1rem) !important;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

body.ss-route-depozit .p-8 {
  padding: 1.25rem !important;
}

body.ss-route-depozit .py-7,
body.ss-route-depozit .py-8 {
  padding-top: 0.875rem !important;
  padding-bottom: 0.875rem !important;
}

/* —— Footer ünvanları —— */
footer span.text-sm,
footer [data-ss-addresses-done] span {
  word-break: break-word;
  overflow-wrap: anywhere;
  max-width: 100%;
}

footer .flex.flex-col.gap-2 {
  width: 100%;
  max-width: 100%;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
  box-sizing: border-box;
}

/* —— Qeydiyyat forması (iOS zoom qarşısı) —— */
[data-testid="fin-code-input"],
[data-testid="id-series-input"],
[data-testid="first-name-input"],
[data-testid="last-name-input"],
[data-testid="phone-input"] {
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  font-size: 16px;
}

/* —— Müqavilə və ümumi mətn —— */
[data-testid="contract-content"] {
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* —— Header loqo —— */
header img,
nav img {
  max-height: 2.75rem;
  width: auto;
  max-width: min(11rem, 52vw);
  height: auto;
  object-fit: contain;
}

@media (max-width: 639px) {
  [data-testid="payment-start-btn"] {
    font-size: clamp(0.875rem, 3.6vw, 1rem) !important;
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }

  [data-testid="payment-start-btn"] svg {
    width: 1.25rem !important;
    height: 1.25rem !important;
    margin-right: 0.5rem !important;
  }

  body.ss-route-depozit .text-2xl,
  body.ss-route-depozit .text-3xl,
  body.ss-route-depozit .sm\:text-3xl {
    font-size: clamp(1.2rem, 5vw, 1.5rem) !important;
    line-height: 1.25 !important;
  }

  body.ss-route-depozit .text-xl,
  body.ss-route-depozit .text-2xl.animate-pay-cta {
    font-size: clamp(0.875rem, 3.6vw, 1rem) !important;
  }

  .ss-calc-wrap .ss-calc-title {
    font-size: 1.35rem;
  }

  .ss-calc-field .ss-field-label {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }

  .ss-calc-summary {
    grid-template-columns: 1fr;
  }

  .ss-summary-card .ss-summary-value {
    font-size: 1.1rem;
  }

  .ss-calc-body {
    padding: 1rem;
  }

  .ss-calc-card .ss-calc-header {
    padding: 0.875rem 1rem;
  }

  .ss-calc-nav-box {
    margin: 1rem;
    max-width: calc(100vw - 2rem);
    padding: 1.25rem 1rem;
  }

  .ss-calc-slider-wrap {
    touch-action: pan-x;
    -webkit-tap-highlight-color: transparent;
  }

  .ss-calc-wrap {
    touch-action: manipulation;
  }

  main,
  section,
  footer {
    max-width: 100%;
  }

  table {
    display: block;
    overflow-x: auto;
    max-width: 100%;
  }
}

@media (max-width: 380px) {
  body.ss-route-depozit [data-testid="deposit-amount"] {
    font-size: 1.65rem !important;
  }
}
