/* ---- GF Field Tooltips -------------------------------------------- */

/* Label flex — damit ? mit margin-left:auto nach rechts wandert */
.gf-tt-label {
  display: flex !important;
  align-items: center;
  width: 100%;
}

.gf-tt {
  position: relative;
  display: inline-block;
  margin-left: auto;
  padding-left: 10px;
  flex-shrink: 0;
  margin-top: -4px;
}

.gf-tt-icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  border: 1.5px solid var(--e-global-color-primary);
  font-size: 13px;
  font-weight: 500;
  line-height: 1;
  color: var(--e-global-color-primary);
  transition: all 200ms ease-in-out;
  user-select: none;
  font-family: inherit;
  padding-left: 1px;
  cursor: pointer; /* WICHTIG FÜR iOS SAFARI */
}

.gfield_label:hover .gf-tt-icon {
    transition: all 200ms ease-in-out;
    border: 1.5px solid var(--e-global-color-accent);
    box-shadow: 0px 0 0 1px var(--e-global-color-accent) !important;
}

.gf-tt:hover .gf-tt-icon,
.gf-tt-icon:focus {
    color: #fff;
    outline: none;
    background: var(--e-global-color-primary);
    border: 1.5px solid var(--e-global-color-primary);
    transition: all 200ms ease-in-out;
    box-shadow: none !important;
}

/* Größerer Touch-Bereich auf Mobile */
@media (hover: none) {
  .gf-tt-icon::before {
    content: '';
    position: absolute;
    inset: -14px;
  }
}

/* Bubble: rechts-verankert, erscheint ÜBER dem Feld */
.gf-tt-bubble {
  display: none;
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  left: auto;
  width: 260px;
  max-width: calc(100vw - 1.5rem);
  background: #1e2433;
  color: #e8ecf0;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.5;
  padding: 9px 13px;
  border-radius: 6px;
  z-index: 9999;
  box-shadow: 0 3px 10px rgba(0,0,0,0.2);
  white-space: normal;
}

/* Pfeil rechts unter der Bubble (zeigt auf das ?-Icon) */
.gf-tt-bubble::after {
  content: '';
  position: absolute;
  top: 100%;
  right: 6px;
  left: auto;
  border: 6px solid transparent;
  border-top-color: #1e2433;
}

@media (hover: hover) {
  .gf-tt:hover .gf-tt-bubble {
    display: block;
  }
}

.gf-tt.gf-tt-open .gf-tt-bubble {
  display: block;
}

.gf-tt-bubble.gf-tt-open {
  display: block;
}