.custom-callback-modal-dialog {
  width: min(100% - 24px, 760px);
  max-width: 760px;
}

.custom-callback-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: #1f3552;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  z-index: 5;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.18);
  opacity: 1;
}

.custom-callback-shell {
  background: linear-gradient(145deg, #f7fbff 0%, #ffffff 48%, #eef6ff 100%);
  border-radius: 28px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.28);
  max-height: 75vh;
  overflow: hidden;
  border: 0;
}

.custom-callback-body {
  padding: 24px;
  max-height: 75vh;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

.custom-status-banner {
  margin-bottom: 16px;
  padding: 14px 16px;
  border-radius: 18px;
  display: grid;
  gap: 4px;
  background: #e8f7ed;
  color: #12512d;
}

.custom-status-banner.is-error {
  background: #fff0ef;
  color: #a1251d;
}

.custom-status-banner strong {
  font-size: 15px;
}

.custom-status-banner span {
  font-size: 14px;
  line-height: 1.55;
}

.custom-callback-header {
  display: flex;
  gap: 18px;
  margin-bottom: 20px;
  padding-right: 44px;
}

.custom-callback-header img {
  width: 130px;
  height: 130px;
  border-radius: 20px;
  object-fit: cover;
  background: #dfeaf7;
  flex-shrink: 0;
}

.custom-callback-tour-info {
  flex: 1;
}

.custom-callback-kicker {
  margin: 0 0 8px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #0e67b1;
  font-weight: 800;
}

.custom-callback-tour-info h4 {
  margin: 0 0 8px;
  font-size: 28px;
  line-height: 1.25;
  color: #10233c;
  font-weight: 800;
}

.custom-callback-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin: 0 0 16px;
  color: #5d7189;
  font-size: 14px;
}

.custom-callback-meta span:empty {
  display: none;
}

.custom-callback-price-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.modal-new-price {
  font-size: 32px;
  font-weight: 800;
  color: #10233c;
  line-height: 1;
}

.modal-old-price {
  font-size: 15px;
  color: #7d8ea4;
  text-decoration: line-through;
}

.modal-save-badge {
  background: #e7f8ec;
  color: #10813d;
  font-size: 12px;
  font-weight: 800;
  padding: 6px 10px;
  border-radius: 999px;
}

.custom-callback-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.custom-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.custom-form-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.custom-form-group label,
.custom-form-row label {
  font-size: 13px;
  font-weight: 700;
  color: #244261;
}

.custom-form-group input,
.custom-form-row input,
.custom-form-row select {
  width: 100%;
  border: 1px solid #d8e2ee;
  border-radius: 14px;
  padding: 13px 14px;
  font-size: 15px;
  outline: none;
  background: #fff;
}

.custom-form-group input:focus,
.custom-form-row input:focus,
.custom-form-row select:focus {
  border-color: #1a88f8;
  box-shadow: 0 0 0 3px rgba(26, 136, 248, 0.12);
}

.custom-form-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 14px;
}

.custom-check-row {
  display: flex;
  align-items: start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: #edf6ff;
  color: #264362;
  font-weight: 600;
}

.custom-check-row input {
  margin-top: 3px;
}

.form-error {
  min-height: 16px;
  color: #d93025;
  font-size: 12px;
}

.custom-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  border: none;
  border-radius: 16px;
  background: linear-gradient(135deg, #ff7a00, #ffaf3f);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 18px 28px rgba(255, 122, 0, 0.22);
}

.custom-submit-btn:hover {
  transform: translateY(-1px);
}

.custom-submit-btn[disabled] {
  opacity: 0.75;
  cursor: wait;
}

.thank-you-message-store {
  display: none;
}

@media (max-width: 767px) {
  #callbackModal {
    padding: 12px 0;
  }

  #callbackModal .modal-dialog-centered {
    min-height: auto;
    align-items: flex-start;
  }

  .custom-callback-modal-dialog {
    width: min(100% - 16px, 420px);
    max-width: 420px;
    margin: 0 auto;
  }

  .custom-callback-shell {
    border-radius: 22px;
    max-height: 75dvh;
  }

  .custom-callback-body {
    padding: 14px 14px 16px;
    max-height: 75dvh;
    overscroll-behavior: contain;
  }

  .custom-callback-header {
    flex-direction: column;
    gap: 8px;
    padding-right: 40px;
    margin-bottom: 12px;
  }

  .custom-callback-header img {
    display: none;
  }

  .custom-callback-close {
    top: 8px;
    right: 8px;
    width: 34px;
    height: 34px;
  }

  .custom-form-grid {
    grid-template-columns: 1fr;
  }

  .custom-callback-tour-info h4 {
    font-size: 18px;
    line-height: 1.2;
    margin-bottom: 4px;
  }

  .modal-new-price {
    font-size: 16px;
  }

  .modal-old-price {
    font-size: 11px;
  }

  .modal-save-badge {
    font-size: 10px;
    padding: 4px 8px;
  }

  .custom-callback-meta {
    gap: 6px 8px;
    margin-bottom: 8px;
    font-size: 11px;
  }

  .custom-callback-kicker {
    margin-bottom: 4px;
    font-size: 10px;
  }

  .custom-callback-form {
    gap: 8px;
  }

  .custom-form-grid,
  .custom-form-row {
    gap: 8px;
  }

  .custom-form-group {
    gap: 4px;
  }

  .custom-form-group label,
  .custom-form-row label {
    font-size: 11px;
  }

  .custom-form-group input,
  .custom-form-row input,
  .custom-form-row select {
    padding: 9px 10px;
    min-height: 40px;
    font-size: 12px;
    border-radius: 10px;
  }

  .custom-check-row {
    padding: 8px 10px;
    border-radius: 12px;
    font-size: 11px;
  }

  .custom-submit-btn {
    min-height: 42px;
    font-size: 14px;
    border-radius: 12px;
    box-shadow: 0 10px 18px rgba(255, 122, 0, 0.18);
  }
}

@media (max-width: 575px) {
  .custom-callback-modal-dialog {
    width: min(100% - 12px, 340px);
    max-width: 340px;
    margin: 0 auto;
  }

  .custom-callback-shell {
    max-height: 75dvh;
    border-radius: 18px;
  }

  .custom-callback-body {
    max-height: 75dvh;
    padding: 12px 12px 14px;
  }

  .custom-form-row {
    grid-template-columns: 1fr;
  }

  .custom-callback-tour-info h4 {
    font-size: 16px;
    line-height: 1.25;
    margin-bottom: 4px;
  }

  .modal-new-price {
    font-size: 16px;
  }

  .modal-old-price {
    font-size: 11px;
  }

  .custom-callback-meta {
    gap: 6px 10px;
    margin-bottom: 8px;
    font-size: 11px;
  }

  .custom-form-group input,
  .custom-form-row input,
  .custom-form-row select {
    padding: 9px 10px;
    min-height: 38px;
    font-size: 12px;
    border-radius: 10px;
  }

  .form-error {
    min-height: 12px;
    font-size: 11px;
  }
}

@media (max-width: 767px) and (orientation: portrait) {
  .custom-callback-modal-dialog,
  .custom-callback-shell,
  .custom-callback-body {
    max-height: 75dvh;
  }

  .custom-callback-tour-info h4 {
    font-size: 16px;
  }
}
