/* ============================================================
   Kantor Calculator — стили 1:1 с whitemoney.4kls.com
   ============================================================ */

.conv {
  width: 100%;
}

.conv__card {
  background: #fff;
  border-radius: 16px;
  padding: 28px 24px 20px;
  max-width: 420px;
  box-shadow: 0 2px 24px rgba(24,59,130,.10);
}

.conv__label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #8c9ab5;
  margin: 0 0 8px;
}

/* ── Input row ── */
.conv__input-group {
  display: flex;
  align-items: stretch;
  border: 1.5px solid #e0e8f4;
  border-radius: 10px;
  overflow: visible;
  background: #f8fafd;
  margin-bottom: 4px;
  transition: border-color .2s;
  position: relative;
}

.conv__input-group:focus-within {
  border-color: #188de7;
}

.conv__input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 22px;
  font-weight: 700;
  padding: 12px 14px;
  outline: none;
  color: #1a2340;
  min-width: 0;
  font-family: inherit;
}

.conv__input--readonly {
  color: #3a4a6b;
}

/* ── Custom select ── */
.conv__input-group .custom-select {
  position: relative;
  flex-shrink: 0;
  border-left: 1.5px solid #e0e8f4;
  background: #fff;
  border-radius: 0 8px 8px 0;
  min-width: 120px;
  z-index: 10;
}

.conv__input-group .custom-select .select-trigger {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 14px 0 10px;
  height: 100%;
  cursor: pointer;
  user-select: none;
  min-height: 52px;
}

.conv__input-group .custom-select .select-trigger:hover {
  background: #f4f7fb;
}

.conv__input-group .custom-select .select-trigger::after {
  content: '';
  display: inline-block;
  width: 0; height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid #8c9ab5;
  margin-left: 2px;
  transition: transform .18s;
  flex-shrink: 0;
}

.conv__input-group .custom-select.open .select-trigger::after {
  transform: rotate(180deg);
}

.conv__input-group .custom-select .flag {
  display: flex;
  align-items: center;
  width: 28px;
  height: 20px;
  flex-shrink: 0;
}

.conv__input-group .custom-select .flag img {
  width: 28px;
  height: auto;
  border-radius: 2px;
  display: block;
}

.conv__input-group .custom-select .code {
  font-size: 15px;
  font-weight: 700;
  color: #1a2340;
  white-space: nowrap;
}

/* Dropdown */
.conv__input-group .custom-select .select-options {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 150px;
  background: #fff;
  border: 1.5px solid #e0e8f4;
  border-radius: 10px;
  box-shadow: 0 8px 32px rgba(24,59,130,.13);
  z-index: 9999;
  overflow-y: auto;
  max-height: 280px;
}

.conv__input-group .custom-select.open .select-options {
  display: block;
}

.conv__input-group .custom-select .option {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  color: #1a2340;
  transition: background .12s;
}

.conv__input-group .custom-select .option:hover {
  background: #f0f6ff;
  color: #188de7;
}

.conv__input-group .custom-select .option[data-selected="true"] {
  font-weight: 700;
  color: #188de7;
  background: #eef5ff;
}

.conv__input-group .custom-select .option .flag {
  width: 24px; height: 18px;
}

.conv__input-group .custom-select .option .flag img {
  width: 24px;
}

/* ── Swap ── */
.conv__swap-wrap {
  display: flex;
  align-items: center;
  margin: 14px 0;
  gap: 12px;
}

.conv__swap-line {
  flex: 1;
  height: 1px;
  background: #e8edf3;
}

.conv__swap-btn {
  background: #fff;
  border: 1.5px solid #e0e8f4;
  border-radius: 50%;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  color: #8c9ab5;
  transition: background .15s, border-color .15s, color .15s, transform .22s;
  flex-shrink: 0;
  line-height: 1;
}

.conv__swap-btn:hover {
  background: #188de7;
  border-color: #188de7;
  color: #fff;
  transform: rotate(180deg);
}

/* ── Rate badge ── */
.conv__rate-badge {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px;
  background: #f4f7fb;
  border: 1px solid #e0e8f4;
  border-radius: 8px;
  padding: 9px 14px;
  margin: 14px 0 16px;
  font-size: 13px;
  color: #6b7a99;
}

.conv__rate-badge-label {
  display: flex;
  align-items: center;
  gap: 5px;
}

.conv__rate-badge-value {
  font-weight: 700;
  color: #188de7;
  font-size: 16px;
}

.conv__spread-label {
  font-size: 12px;
  color: #aab4c8;
}

/* ── Wholesale row ── */
.conv__hurt-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  background: #f0faf3;
  border: 1px solid #bbdfc8;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 12px;
  color: #2d6a4f;
  margin-bottom: 14px;
}

.conv__hurt-label { opacity: .75; }
.conv__hurt-val   { font-weight: 700; }
.conv__hurt-result { font-weight: 700; margin-left: auto; color: #1a7a44; }

/* ── Order button ── */
.conv__order-btn {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 15px;
  border-radius: 10px;
  border: none;
  background: linear-gradient(90deg, #188de7 0%, #1265c0 100%);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  transition: opacity .15s, transform .12s;
  font-family: inherit;
  letter-spacing: .02em;
  text-decoration: none;
}

.conv__order-btn:hover {
  opacity: .9;
  transform: translateY(-1px);
}

.conv__note {
  font-size: 11px;
  color: #b0bac9;
  margin: 8px 0 0;
  text-align: center;
}

/* ── Loading ── */
.conv__loading {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  font-size: 13px;
  color: #8c9ab5;
}

.conv__spinner {
  display: inline-block;
  width: 16px; height: 16px;
  border: 2px solid #d0d8e8;
  border-top-color: #188de7;
  border-radius: 50%;
  animation: kc-spin .7s linear infinite;
  flex-shrink: 0;
}

@keyframes kc-spin { to { transform: rotate(360deg); } }

/* ── Error ── */
.conv__error {
  background: #fff8e6;
  border: 1px solid #ffd166;
  border-radius: 8px;
  padding: 9px 14px;
  font-size: 13px;
  color: #7a5c00;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0;
}

.conv__error button {
  background: none;
  border: 1px solid currentColor;
  border-radius: 4px;
  padding: 2px 10px;
  font-size: 12px;
  cursor: pointer;
  color: inherit;
  margin-left: auto;
  font-family: inherit;
}

/* ── Updated ── */
.conv__updated {
  font-size: 11px;
  color: #c0c8d8;
  margin-top: 10px;
  text-align: right;
}

/* rate type label */
.conv__rate-type {
  font-weight: 400;
  font-size: 12px;
  color: #aab4c8;
  margin-left: 2px;
}


.custom-select {
    position: relative;
}

.custom-select.open {
    z-index: 999999;
}

.select-options {
    z-index: 999999;
}