/* ===========================================
  SOPORTE - Landing Principal
=========================================== */

/* -------------------------------------------
  Botón Flotante
------------------------------------------- */
.soporte-btn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 990;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--p-morado);
  color: #fff;
  border: 2px solid #fff;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(117, 102, 219, 0.4);
  transition: all 0.3s ease;
}

.soporte-btn:hover {
  background: #6254c4;
  transform: scale(1.05);
}

.soporte-btn.active {
  z-index: 1100;
}

.soporte-icon {
  transition: all 0.3s ease;
}

.soporte-icon--close {
  position: absolute;
  opacity: 0;
  transform: rotate(-90deg);
}

.soporte-btn.active .soporte-icon--default {
  opacity: 0;
  transform: rotate(90deg);
}

.soporte-btn.active .soporte-icon--close {
  opacity: 1;
  transform: rotate(0);
}

/* Label "Soporte" */
.soporte-btn-label {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  margin-bottom: 0.5rem;
  padding: 0.25rem 0.75rem;
  background: #fff;
  color: var(--p-morado);
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 1rem;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.soporte-btn.active .soporte-btn-label {
  opacity: 0;
  visibility: hidden;
}

/* -------------------------------------------
  Overlay
------------------------------------------- */
.soporte-overlay {
  position: fixed;
  inset: 0;
  z-index: 1050;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

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

/* -------------------------------------------
  Modal
------------------------------------------- */
.soporte-modal {
  position: fixed;
  bottom: 100px;
  right: 2rem;
  z-index: 1060;
  width: 360px;
  max-width: calc(100vw - 2rem);
  max-height: calc(100vh - 140px);
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.3s ease;
}

.soporte-modal.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* -------------------------------------------
  Header
------------------------------------------- */
.soporte-header {
  padding: 1.25rem 1.5rem;
  background: var(--p-morado);
}

.soporte-header-text h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 0.25rem;
}

.soporte-header-text p {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
}

/* -------------------------------------------
  Formulario
------------------------------------------- */
.soporte-form {
  padding: 1.5rem;
  max-height: calc(100vh - 240px);
  overflow-y: auto;
}

.soporte-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.soporte-field {
  margin-bottom: 1rem;
}

.soporte-field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gris-oscuro);
  margin-bottom: 0.5rem;
}

.soporte-field input,
.soporte-field textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  color: var(--gris-oscuro);
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 0.5rem;
  transition: all 0.2s ease;
}

.soporte-field input:focus,
.soporte-field textarea:focus {
  outline: none;
  background: #fff;
  border-color: var(--p-morado);
  box-shadow: 0 0 0 3px rgba(117, 102, 219, 0.1);
}

.soporte-field input::placeholder,
.soporte-field textarea::placeholder {
  color: #adb5bd;
}

.soporte-field textarea {
  resize: none;
}

/* reCaptcha */
.soporte-captcha {
  margin-bottom: 1rem;
  display: flex;
  justify-content: center;
}

.soporte-captcha>div {
  transform: scale(0.9);
  transform-origin: center;
}

/* Términos */
.soporte-terms {
  font-size: 0.75rem;
  color: var(--gris);
  line-height: 1.5;
  text-align: justify;
  margin: 0 0 1rem;
}

.soporte-terms a {
  color: var(--gris);
  font-weight: 600;
  text-decoration: underline;
}

.soporte-terms a:hover {
  color: var(--p-morado);
}

/* Botón Submit */
.soporte-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.875rem 1.5rem;
  background: var(--p-morado);
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.soporte-submit:hover {
  background: #6254c4;
}

.soporte-submit:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(117, 102, 219, 0.3);
}

/* Scrollbar personalizada */
.soporte-form::-webkit-scrollbar {
  width: 6px;
}

.soporte-form::-webkit-scrollbar-track {
  background: transparent;
}

.soporte-form::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

.soporte-form::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

/* Firefox */
.soporte-form {
  scrollbar-width: thin;
  scrollbar-color: #d1d5db transparent;
}

/* -------------------------------------------
  Responsive
------------------------------------------- */
@media (max-width: 576px) {
  .soporte-btn {
    width: 40px;
    height: 40px;
    bottom: 1.2rem;
    right: 1.2rem;
  }

  .soporte-btn svg {
    width: 18px;
    height: 18px;
  }

  .soporte-btn-label {
    font-size: 0.65rem;
    padding: 0.2rem 0.5rem;
    margin-bottom: 0.35rem;
  }

  .soporte-modal {
    left: 1rem;
    right: 1rem;
    bottom: 70px;
    width: auto;
    max-width: none;
  }

  .soporte-form-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .soporte-header {
    padding: 1rem 1.25rem;
  }

  .soporte-form {
    padding: 1.25rem;
  }

  .soporte-captcha>div {
    transform: scale(0.77);
  }
}