/* ═══════════════════════════════════════════════════
   RS Viajes — Cotizar Modal Styles
   Premium glassmorphism quote-request modal
   ═══════════════════════════════════════════════════ */

/* ─── Overlay ─── */
.cotizar-overlay {
  position: fixed;
  inset: 0;
  z-index: 99990;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.cotizar-overlay--active {
  opacity: 1;
  visibility: visible;
}

/* ─── Modal Container ─── */
.cotizar-modal {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  z-index: 99991;
  width: 100%;
  max-width: 520px;
  max-height: 92vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 24px 24px 0 0;
  box-shadow: 0 -8px 60px rgba(0, 0, 0, 0.25);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease, visibility 0.35s ease;
  font-family: 'Inter', 'Roboto', sans-serif;
  visibility: hidden;
  pointer-events: none;
}

.cotizar-modal--active {
  transform: translateX(-50%) translateY(0);
  visibility: visible;
  pointer-events: auto;
}

/* Desktop: centered modal */
@media (min-width: 640px) {
  .cotizar-modal {
    bottom: auto;
    top: 50%;
    transform: translate(-50%, -50%) scale(0.92);
    border-radius: 24px;
    max-height: 90vh;
    opacity: 0;
  }

  .cotizar-modal--active {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
}

/* ─── Header ─── */
.cotizar-modal__header {
  position: sticky;
  top: 0;
  z-index: 2;
  background: linear-gradient(135deg, #0d7377 0%, #14919b 100%);
  padding: 24px 28px 20px;
  border-radius: 24px 24px 0 0;
}

@media (min-width: 640px) {
  .cotizar-modal__header {
    border-radius: 24px 24px 0 0;
  }
}

.cotizar-modal__drag-bar {
  display: block;
  width: 40px;
  height: 4px;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 4px;
  margin: 0 auto 16px;
}

@media (min-width: 640px) {
  .cotizar-modal__drag-bar {
    display: none;
  }
}

.cotizar-modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 20px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
  line-height: 1;
}

.cotizar-modal__close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.cotizar-modal__title {
  color: #fff;
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 4px;
  padding-right: 40px;
}

.cotizar-modal__subtitle {
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  margin: 0;
  font-weight: 400;
}

/* ─── Destination Badge ─── */
.cotizar-modal__dest-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  margin-top: 12px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cotizar-modal__dest-badge i {
  font-size: 14px;
  opacity: 0.8;
}

/* ─── Form Body ─── */
.cotizar-modal__body {
  padding: 24px 28px 28px;
}

.cotizar-modal__form-group {
  margin-bottom: 18px;
}

.cotizar-modal__label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.cotizar-modal__input,
.cotizar-modal__select,
.cotizar-modal__textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e8ecef;
  border-radius: 12px;
  font-size: 15px;
  font-family: 'Inter', 'Roboto', sans-serif;
  color: #1a1a2e;
  background: #f8fafb;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
}

.cotizar-modal__input:focus,
.cotizar-modal__select:focus,
.cotizar-modal__textarea:focus {
  border-color: #0d7377;
  box-shadow: 0 0 0 4px rgba(13, 115, 119, 0.1);
  background: #fff;
}

.cotizar-modal__input--error {
  border-color: #e74c3c !important;
  box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.1) !important;
}

.cotizar-modal__textarea {
  resize: vertical;
  min-height: 80px;
}

.cotizar-modal__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 400px) {
  .cotizar-modal__row {
    grid-template-columns: 1fr;
  }
}

/* ─── Submit Button ─── */
.cotizar-modal__submit {
  width: 100%;
  padding: 16px 24px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #0d7377 0%, #14919b 100%);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  font-family: 'Inter', 'Roboto', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 16px rgba(13, 115, 119, 0.3);
  margin-top: 8px;
}

.cotizar-modal__submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(13, 115, 119, 0.4);
}

.cotizar-modal__submit:active {
  transform: translateY(0);
}

.cotizar-modal__submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.cotizar-modal__submit i {
  font-size: 20px;
}

/* ─── WhatsApp Secondary ─── */
.cotizar-modal__wa-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
  padding: 12px;
  border-radius: 12px;
  background: #f0faf5;
  color: #128C7E;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease;
}

.cotizar-modal__wa-link:hover {
  background: #e0f5ed;
  text-decoration: none;
  color: #128C7E;
}

.cotizar-modal__wa-link i {
  font-size: 18px;
  color: #25D366;
}

/* ─── Privacy ─── */
.cotizar-modal__privacy {
  text-align: center;
  margin-top: 16px;
  font-size: 11px;
  color: #999;
}

.cotizar-modal__privacy a {
  color: #0d7377;
  text-decoration: underline;
}

/* ─── Success State ─── */
.cotizar-modal__success {
  text-align: center;
  padding: 40px 28px 48px;
}

.cotizar-modal__success-icon {
  width: 72px;
  height: 72px;
  background: linear-gradient(135deg, #27ae60, #2ecc71);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 32px;
  color: #fff;
  animation: cotizarPop 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes cotizarPop {
  0% { transform: scale(0); }
  70% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.cotizar-modal__success h3 {
  font-size: 22px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 8px;
}

.cotizar-modal__success p {
  font-size: 15px;
  color: #666;
  margin: 0 0 24px;
  line-height: 1.6;
}

.cotizar-modal__success-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, #0d7377, #14919b);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.cotizar-modal__success-btn:hover {
  transform: translateY(-2px);
}

/* ─── Sticky Bottom Bar (Listing Pages) ─── */
.cotizar-sticky-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9990;
  background: linear-gradient(135deg, #0d7377 0%, #14919b 100%);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  font-family: 'Inter', 'Roboto', sans-serif;
}

.cotizar-sticky-bar--visible {
  transform: translateY(0);
}

.cotizar-sticky-bar__text {
  color: rgba(255, 255, 255, 0.9);
  font-size: 14px;
  font-weight: 500;
}

.cotizar-sticky-bar__text strong {
  color: #fff;
}

.cotizar-sticky-bar__btn {
  padding: 10px 24px;
  background: #fff;
  color: #0d7377;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}

.cotizar-sticky-bar__btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.cotizar-sticky-bar__dismiss {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
}

.cotizar-sticky-bar__dismiss:hover {
  color: #fff;
}

@media (max-width: 480px) {
  .cotizar-sticky-bar {
    flex-direction: column;
    gap: 8px;
    padding: 12px 16px 16px;
  }

  .cotizar-sticky-bar__text {
    font-size: 13px;
  }

  .cotizar-sticky-bar__btn {
    width: 100%;
    text-align: center;
  }
}

/* ─── Trip Card Cotizar Badge ─── */
.trip-card__cotizar-badge {
  position: absolute;
  bottom: 14px;
  left: 14px;
  z-index: 3;
  padding: 8px 18px;
  background: rgba(255, 255, 255, 0.95);
  color: #0d7377;
  border: none;
  border-radius: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: background 0.2s ease, transform 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.trip-card__cotizar-badge:hover {
  background: #0d7377;
  color: #fff;
  transform: scale(1.05);
}

/* ─── Detail Page Dual CTA ─── */
.trip-detail__cta-dual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 32px 0;
}

.trip-detail__cta-primary {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 18px 48px;
  background: linear-gradient(135deg, #0d7377 0%, #14919b 100%);
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 17px;
  font-weight: 700;
  border-radius: 60px;
  border: none;
  cursor: pointer;
  box-shadow: 0 6px 24px rgba(13, 115, 119, 0.35);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  letter-spacing: 0.3px;
}

.trip-detail__cta-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 10px 32px rgba(13, 115, 119, 0.45);
}

.trip-detail__cta-primary i {
  font-size: 20px;
}

.trip-detail__cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: #f0faf5;
  color: #128C7E;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  border-radius: 40px;
  text-decoration: none;
  transition: background 0.2s ease;
}

.trip-detail__cta-secondary:hover {
  background: #e0f5ed;
  text-decoration: none;
  color: #128C7E;
}

.trip-detail__cta-secondary i {
  font-size: 18px;
  color: #25D366;
}

/* ─── Inline CTA Section (below iframe on viaje detail) ─── */
.cotizar-inline-cta {
  background: linear-gradient(135deg, #0d7377 0%, #14919b 50%, #0d7377 100%) !important;
  padding: 48px 24px !important;
  text-align: center !important;
  position: relative;
  overflow: hidden;
}

.cotizar-inline-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.cotizar-inline-cta__inner {
  position: relative;
  z-index: 1;
  max-width: 560px;
  margin: 0 auto;
}

.cotizar-inline-cta__icon {
  font-size: 48px;
  margin-bottom: 12px;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,.2));
}

.cotizar-inline-cta__title {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 26px;
  color: #fff;
  margin: 0 0 8px;
}

.cotizar-inline-cta__subtitle {
  font-family: 'Inter', 'Roboto', sans-serif;
  font-size: 15px;
  color: rgba(255,255,255,.85);
  margin: 0 0 28px;
  line-height: 1.5;
}

.cotizar-inline-cta__buttons {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.cotizar-inline-cta__primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 48px;
  font-family: 'Inter', 'Roboto', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #1a1a2e;
  background: linear-gradient(135deg, #c9a84c 0%, #e8c95a 50%, #c9a84c 100%);
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: all .3s ease;
  box-shadow: 0 4px 20px rgba(201,168,76,.4);
  text-transform: none;
  letter-spacing: .3px;
}

.cotizar-inline-cta__primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(201,168,76,.55);
  background: linear-gradient(135deg, #d4b35a 0%, #f0d46a 50%, #d4b35a 100%);
}

.cotizar-inline-cta__secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 24px;
  font-family: 'Inter', 'Roboto', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,.9);
  text-decoration: none;
  background: rgba(255,255,255,.12);
  border-radius: 30px;
  transition: all .3s ease;
  border: 1px solid rgba(255,255,255,.2);
}

.cotizar-inline-cta__secondary:hover {
  background: rgba(255,255,255,.22);
  color: #fff;
  text-decoration: none;
}

.cotizar-inline-cta__secondary i {
  color: #25D366;
  font-size: 18px;
}

@media (max-width: 600px) {
  .cotizar-inline-cta {
    padding: 36px 16px;
  }
  .cotizar-inline-cta__title {
    font-size: 22px;
  }
  .cotizar-inline-cta__primary {
    padding: 14px 36px;
    font-size: 15px;
    width: 100%;
  }
  .cotizar-inline-cta__secondary {
    width: 100%;
    justify-content: center;
  }
}
