/* =========================================================
   GTRANSLATE · TECNOMUR
   Interfaz más intuitiva, aviso y estados de traducción
   ========================================================= */

.tm-gt-translate-hint,
.tm-gt-translate-status,
.tm-gt-translate-hint *,
.tm-gt-translate-status * {
  box-sizing: border-box !important;
}

.tm-gt-translate-hint {
  position: fixed !important;
  z-index: 2147483000 !important;
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  width: max-content !important;
  max-width: min(330px, calc(100vw - 24px)) !important;
  min-height: 58px !important;
  padding: 10px 42px 10px 12px !important;
  border: 1px solid rgba(0,168,255,.48) !important;
  border-radius: 17px !important;
  background:
    radial-gradient(circle at 8% 10%, rgba(0,168,255,.22), transparent 42%),
    linear-gradient(135deg, rgba(22,34,43,.97), rgba(13,22,29,.98)) !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  box-shadow:
    0 18px 46px rgba(0,0,0,.38),
    0 0 26px rgba(0,168,255,.13),
    inset 0 1px 0 rgba(255,255,255,.08) !important;
  backdrop-filter: blur(13px) saturate(1.18) !important;
  -webkit-backdrop-filter: blur(13px) saturate(1.18) !important;
  cursor: pointer !important;
  opacity: 0 !important;
  transform: translateY(8px) scale(.97) !important;
  pointer-events: none !important;
  transition:
    opacity .24s ease,
    transform .24s ease,
    border-color .2s ease,
    box-shadow .2s ease !important;
}

.tm-gt-translate-hint[hidden],
.tm-gt-translate-status[hidden] {
  display: none !important;
}

.tm-gt-translate-hint.tm-gt-visible {
  opacity: 1 !important;
  transform: translateY(0) scale(1) !important;
  pointer-events: auto !important;
}

.tm-gt-translate-hint:hover,
.tm-gt-translate-hint:focus-visible {
  border-color: rgba(69,196,255,.86) !important;
  box-shadow:
    0 21px 52px rgba(0,0,0,.42),
    0 0 32px rgba(0,168,255,.22),
    inset 0 1px 0 rgba(255,255,255,.11) !important;
  outline: none !important;
}

.tm-gt-hint-icon {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 38px !important;
  width: 38px !important;
  height: 38px !important;
  margin: 0 !important;
  border: 1px solid rgba(0,168,255,.42) !important;
  border-radius: 12px !important;
  background: rgba(0,168,255,.14) !important;
  font-size: 21px !important;
  line-height: 1 !important;
}

.tm-gt-hint-copy {
  display: flex !important;
  flex-direction: column !important;
  align-items: flex-start !important;
  min-width: 0 !important;
  margin: 0 !important;
  line-height: 1.18 !important;
}

.tm-gt-hint-copy strong {
  display: block !important;
  margin: 0 0 3px !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  font-size: 13px !important;
  line-height: 1.18 !important;
  font-weight: 900 !important;
}

.tm-gt-hint-copy small {
  display: block !important;
  margin: 0 !important;
  color: rgba(255,255,255,.68) !important;
  -webkit-text-fill-color: rgba(255,255,255,.68) !important;
  font-size: 10.5px !important;
  line-height: 1.25 !important;
  font-weight: 650 !important;
}

.tm-gt-hint-close {
  position: absolute !important;
  top: 7px !important;
  right: 7px !important;
  z-index: 3 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 27px !important;
  height: 27px !important;
  min-width: 27px !important;
  min-height: 27px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 9px !important;
  background: rgba(255,255,255,.075) !important;
  color: rgba(255,255,255,.78) !important;
  -webkit-text-fill-color: rgba(255,255,255,.78) !important;
  box-shadow: none !important;
  font-size: 18px !important;
  line-height: 1 !important;
  font-weight: 500 !important;
  cursor: pointer !important;
}

.tm-gt-hint-close:hover,
.tm-gt-hint-close:focus-visible {
  background: rgba(0,168,255,.22) !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  outline: none !important;
}

.tm-gt-translate-status {
  position: fixed !important;
  left: 50% !important;
  bottom: 22px !important;
  z-index: 2147483001 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  min-height: 46px !important;
  max-width: calc(100vw - 24px) !important;
  padding: 10px 17px !important;
  border: 1px solid rgba(0,168,255,.48) !important;
  border-radius: 999px !important;
  background: rgba(13,24,32,.96) !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  box-shadow:
    0 16px 42px rgba(0,0,0,.40),
    0 0 24px rgba(0,168,255,.16) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  font-size: 12px !important;
  line-height: 1 !important;
  font-weight: 850 !important;
  opacity: 0 !important;
  transform: translate(-50%, 10px) scale(.97) !important;
  pointer-events: none !important;
  transition: opacity .2s ease, transform .2s ease !important;
}

.tm-gt-translate-status.tm-gt-visible {
  opacity: 1 !important;
  transform: translate(-50%, 0) scale(1) !important;
}

.tm-gt-translate-status.tm-gt-complete {
  border-color: rgba(36,209,125,.56) !important;
}

.tm-gt-status-spinner {
  display: inline-block !important;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  border: 2px solid rgba(255,255,255,.22) !important;
  border-top-color: #00a8ff !important;
  border-radius: 50% !important;
  animation: tmGtSpin .75s linear infinite !important;
}

.tm-gt-complete .tm-gt-status-spinner {
  border: 0 !important;
  animation: none !important;
}

.tm-gt-complete .tm-gt-status-spinner::before {
  content: "✓" !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 18px !important;
  height: 18px !important;
  color: #39dc91 !important;
  -webkit-text-fill-color: #39dc91 !important;
  font-size: 17px !important;
  line-height: 1 !important;
  font-weight: 950 !important;
}

@keyframes tmGtSpin {
  to { transform: rotate(360deg); }
}

/* El selector queda más claro y cómodo, sin alterar su funcionamiento. */
.gt_switcher_wrapper.tm-gt-enhanced,
.gtranslate_wrapper.tm-gt-enhanced,
.gt_float_switcher.tm-gt-enhanced,
.gt_switcher.tm-gt-enhanced {
  filter: drop-shadow(0 10px 20px rgba(0,0,0,.20)) !important;
}

.gt_switcher_wrapper.tm-gt-enhanced a,
.gtranslate_wrapper.tm-gt-enhanced a,
.gt_float_switcher.tm-gt-enhanced a,
.gt_switcher.tm-gt-enhanced a {
  touch-action: manipulation !important;
  -webkit-tap-highlight-color: rgba(0,168,255,.20) !important;
}

.gt_white_content {
  border: 1px solid rgba(0,168,255,.34) !important;
  border-radius: 20px !important;
  background: rgba(24,31,36,.985) !important;
  color: #fff !important;
  box-shadow: 0 30px 90px rgba(0,0,0,.55) !important;
  backdrop-filter: blur(16px) saturate(1.12) !important;
  -webkit-backdrop-filter: blur(16px) saturate(1.12) !important;
}

.gt_white_content .gt_languages a {
  min-height: 43px !important;
  padding: 8px 10px !important;
  border-bottom-color: rgba(255,255,255,.08) !important;
  border-radius: 10px !important;
  color: rgba(255,255,255,.84) !important;
  -webkit-text-fill-color: rgba(255,255,255,.84) !important;
  transition: background .18s ease, color .18s ease !important;
}

.gt_white_content .gt_languages a:hover,
.gt_white_content .gt_languages a:focus-visible,
.gt_white_content .gt_languages a.gt-current-lang {
  background: rgba(0,168,255,.16) !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  outline: none !important;
}

.gt_black_overlay {
  background: rgba(0,0,0,.68) !important;
  backdrop-filter: blur(4px) !important;
  -webkit-backdrop-filter: blur(4px) !important;
}

html.tm-light-mode .tm-gt-translate-hint,
body.tm-light-mode .tm-gt-translate-hint,
html.light-mode .tm-gt-translate-hint,
body.light-mode .tm-gt-translate-hint {
  background:
    radial-gradient(circle at 8% 10%, rgba(0,168,255,.15), transparent 42%),
    rgba(255,255,255,.97) !important;
  color: #132c3f !important;
  -webkit-text-fill-color: #132c3f !important;
  border-color: rgba(0,126,190,.34) !important;
  box-shadow: 0 18px 46px rgba(25,48,64,.20) !important;
}

html.tm-light-mode .tm-gt-hint-copy strong,
body.tm-light-mode .tm-gt-hint-copy strong,
html.light-mode .tm-gt-hint-copy strong,
body.light-mode .tm-gt-hint-copy strong {
  color: #132c3f !important;
  -webkit-text-fill-color: #132c3f !important;
}

html.tm-light-mode .tm-gt-hint-copy small,
body.tm-light-mode .tm-gt-hint-copy small,
html.light-mode .tm-gt-hint-copy small,
body.light-mode .tm-gt-hint-copy small {
  color: #597083 !important;
  -webkit-text-fill-color: #597083 !important;
}

@media only screen and (max-width: 680px) {
  .tm-gt-translate-hint {
    max-width: calc(100vw - 18px) !important;
    min-height: 54px !important;
    padding: 9px 39px 9px 10px !important;
    border-radius: 15px !important;
  }

  .tm-gt-hint-icon {
    flex-basis: 34px !important;
    width: 34px !important;
    height: 34px !important;
    font-size: 18px !important;
  }

  .tm-gt-hint-copy strong {
    font-size: 12px !important;
  }

  .tm-gt-hint-copy small {
    font-size: 9.8px !important;
  }

  .tm-gt-translate-status {
    bottom: 14px !important;
    min-height: 43px !important;
    font-size: 11px !important;
  }

  .gt_white_content {
    top: 8vh !important;
    left: 8px !important;
    width: calc(100vw - 16px) !important;
    height: 84vh !important;
    max-height: 84vh !important;
    margin: 0 !important;
    padding: 10px !important;
    border-radius: 17px !important;
  }

  .gt_white_content .gt_languages {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 4px !important;
    max-height: none !important;
    overflow: visible !important;
  }

  .gt_white_content .gt_languages a {
    min-width: 0 !important;
    min-height: 46px !important;
    padding: 8px !important;
    white-space: normal !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tm-gt-translate-hint,
  .tm-gt-translate-status,
  .tm-gt-status-spinner {
    animation: none !important;
    transition: none !important;
  }
}
