/* New Order — solo tooltip de tiempo promedio */

#avg-time-block .nwo-avg-label {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

#avg-time-block .nwo-info-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: help;
  user-select: none;
  vertical-align: middle;
  text-transform: none;
  letter-spacing: normal;
  color: #2196f3;
  background: rgba(33, 150, 243, 0.12);
  border: 1px solid rgba(33, 150, 243, 0.28);
  transition: background 0.2s ease, border-color 0.2s ease;
}

#avg-time-block .nwo-info-chip i {
  font-size: 0.85rem;
}

#avg-time-block .nwo-info-chip:hover,
#avg-time-block .nwo-info-chip:focus,
#avg-time-block .nwo-info-chip.is-open {
  background: rgba(33, 150, 243, 0.2);
  border-color: rgba(33, 150, 243, 0.45);
  outline: none;
}

#avg-time-block .nwo-info-popover {
  display: none;
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  width: min(280px, calc(100vw - 2rem));
  padding: 0.65rem 0.8rem;
  background: var(--color-0, #1a1b1f);
  color: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--border-1, rgba(255, 255, 255, 0.1));
  border-radius: 10px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  font-size: 0.75rem;
  line-height: 1.45;
  font-weight: 400;
  text-align: left;
  z-index: 1200;
}

#avg-time-block .nwo-info-chip:hover .nwo-info-popover,
#avg-time-block .nwo-info-chip:focus-within .nwo-info-popover,
#avg-time-block .nwo-info-chip.is-open .nwo-info-popover {
  display: block;
}

#avg-time-block .nwo-info-popover-line {
  display: block;
}

#avg-time-block .nwo-info-popover-line + .nwo-info-popover-line {
  margin-top: 0.35rem;
  opacity: 0.88;
}

@media (max-width: 575px) {
  #avg-time-block .nwo-info-popover {
    left: auto;
    right: 0;
  }
}

/* —— Encuesta (Poll): tooltip en label + placeholder suave —— */
.nwo-poll-field .nwo-poll-label {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.nwo-poll-field .nwo-info-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border-radius: 50%;
  font-size: 0.72rem;
  cursor: help;
  user-select: none;
  vertical-align: middle;
  color: #2196f3;
  background: rgba(33, 150, 243, 0.12);
  border: 1px solid rgba(33, 150, 243, 0.28);
  transition: background 0.2s ease, border-color 0.2s ease;
}

.nwo-poll-field .nwo-info-chip i {
  font-size: 0.78rem;
}

.nwo-poll-field .nwo-info-chip:hover,
.nwo-poll-field .nwo-info-chip:focus,
.nwo-poll-field .nwo-info-chip.is-open {
  background: rgba(33, 150, 243, 0.2);
  border-color: rgba(33, 150, 243, 0.45);
  outline: none;
}

.nwo-poll-field .nwo-info-popover {
  display: none;
  position: absolute;
  left: 50%;
  top: calc(100% + 8px);
  transform: translateX(-50%);
  width: min(280px, calc(100vw - 2rem));
  padding: 0.65rem 0.8rem;
  background: var(--color-0, #1a1b1f);
  color: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--border-1, rgba(255, 255, 255, 0.1));
  border-radius: 10px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  font-size: 0.75rem;
  line-height: 1.45;
  font-weight: 400;
  text-align: left;
  z-index: 1200;
}

.nwo-poll-field .nwo-info-chip:hover .nwo-info-popover,
.nwo-poll-field .nwo-info-chip:focus-within .nwo-info-popover,
.nwo-poll-field .nwo-info-chip.is-open .nwo-info-popover {
  display: block;
}

.nwo-poll-field .nwo-poll-input::placeholder {
  color: rgba(255, 255, 255, 0.32);
  opacity: 1;
}

.nwo-poll-field .nwo-poll-input::-webkit-input-placeholder {
  color: rgba(255, 255, 255, 0.32);
}

.nwo-poll-field .nwo-poll-input::-moz-placeholder {
  color: rgba(255, 255, 255, 0.32);
  opacity: 1;
}

@media (max-width: 575px) {
  .nwo-poll-field .nwo-info-popover {
    left: auto;
    right: 0;
    transform: none;
  }
}

/* —— Favoritos: misma estrella + partículas que Services —— */
.nwo-fav-star {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  margin-right: 6px;
  vertical-align: middle;
  border-radius: 9px;
  border: 1px solid rgba(40, 203, 105, 0.35);
  background: rgba(40, 203, 105, 0.1);
  color: var(--color-3, #28cb69);
  overflow: visible;
  flex-shrink: 0;
  box-shadow: 0 0 12px rgba(40, 203, 105, 0.15);
}

.nwo-fav-star.is-favorited {
  border-color: rgba(40, 203, 105, 0.75);
  background: linear-gradient(145deg, rgba(40, 203, 105, 0.28), rgba(40, 203, 105, 0.1));
  box-shadow: 0 0 16px rgba(40, 203, 105, 0.22);
}

.nwo-fav-star .fav-star-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
}

.nwo-fav-star .fas.fa-star {
  color: var(--color-3, #28cb69);
  font-size: 13px;
  line-height: 1;
  filter: drop-shadow(0 0 5px rgba(40, 203, 105, 0.55));
  animation: nwoFavStarPop 0.45s ease;
}

.nwo-fav-star .fav-particle {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 3px;
  height: 3px;
  margin: -1.5px 0 0 -1.5px;
  border-radius: 50%;
  background: #fff;
  pointer-events: none;
  opacity: 0;
}

.nwo-fav-star.is-favorited .fav-particle--1 {
  animation: nwoFavParticle1 2.2s ease-out infinite;
}
.nwo-fav-star.is-favorited .fav-particle--2 {
  animation: nwoFavParticle2 2.6s ease-out infinite 0.3s;
  width: 2px;
  height: 2px;
  background: #bbf7d0;
}
.nwo-fav-star.is-favorited .fav-particle--3 {
  animation: nwoFavParticle3 2s ease-out infinite 0.6s;
  width: 4px;
  height: 4px;
}
.nwo-fav-star.is-favorited .fav-particle--4 {
  animation: nwoFavParticle1 2.8s ease-out infinite 0.9s;
  background: var(--color-3, #28cb69);
}
.nwo-fav-star.is-favorited .fav-particle--5 {
  animation: nwoFavParticle2 2.4s ease-out infinite 1.2s;
  width: 2px;
  height: 2px;
}
.nwo-fav-star.is-favorited .fav-particle--6 {
  animation: nwoFavParticle3 3s ease-out infinite 1.5s;
  width: 3px;
  height: 3px;
  background: #ecfdf5;
}

@keyframes nwoFavParticle1 {
  0% { opacity: 0; transform: translate(0, 0) scale(0.5); }
  15% { opacity: 1; transform: translate(6px, -8px) scale(1); }
  100% { opacity: 0; transform: translate(16px, -12px) scale(0.2); }
}
@keyframes nwoFavParticle2 {
  0% { opacity: 0; transform: translate(0, 0) scale(0.4); }
  20% { opacity: 0.9; transform: translate(-7px, -5px) scale(1); }
  100% { opacity: 0; transform: translate(-14px, -10px) scale(0.15); }
}
@keyframes nwoFavParticle3 {
  0% { opacity: 0; transform: translate(0, 0) scale(0.6); }
  12% { opacity: 1; transform: translate(4px, 7px) scale(1); }
  100% { opacity: 0; transform: translate(11px, 14px) scale(0.1); }
}
@keyframes nwoFavStarPop {
  0% { transform: scale(0.6); }
  55% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

#categoryTitle.nwo-fav-category-title {
  display: inline-flex !important;
  align-items: center;
  gap: 4px;
  overflow: visible !important;
  height: auto !important;
  min-height: 22px;
  max-width: 90%;
  width: auto !important;
}

#categoryItem.nwo-fav-category-item {
  display: flex !important;
  align-items: center;
  gap: 4px;
  color: var(--color-3, #28cb69) !important;
  font-weight: 600;
  background: rgba(40, 203, 105, 0.06);
  border-left: 2px solid rgba(40, 203, 105, 0.55);
}

#categoryItem.nwo-fav-category-item:hover {
  background: rgba(40, 203, 105, 0.14) !important;
}

/* Perf/a11y: contraste + iconos locales chips */
#submitOrderBtn.btn-primary {
  color: #0b1210 !important;
  font-weight: 700;
}
.nwo-cat-btn .text {
  color: #f2f4f7;
}
.nwo-cat-btn.active .text,
.nwo-cat-btn.active .icon {
  color: #0b1210 !important;
}
.service-colors-guide .feature {
  color: var(--color-3) !important;
  opacity: 1 !important;
}
.nwo-yt-facade:focus {
  outline: 2px solid var(--color-3, #28cb69);
  outline-offset: 2px;
}
/* Iconos imagen: inline (sin forzar nowrap en titles — responsive como antes) */
.g-ticon img,
#categoryTitle img,
#serviceTitle img,
#categoryItem img,
#serviceItem img,
.fs-iptv img,
.fs-protonvpn img,
.fs-netflix img,
.fs-disney img,
.fs-chatgpt img,
.fs-canva img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  display: inline;
  vertical-align: middle;
}
.g-ticon,
.fs-iptv,
.fs-protonvpn,
.fs-netflix,
.fs-disney,
.fs-chatgpt,
.fs-canva {
  display: inline;
  line-height: 1;
}
/* CLS: reservar espacio de dashcards + chips antes de fuentes/JS (solo desktop) */
@media (min-width: 992px) {
  .dashcards-row {
    min-height: 112px;
  }
}
@media (max-width: 991.98px) {
  .dashcards-row {
    display: none !important;
    min-height: 0 !important;
    margin: 0 !important;
  }
}
.dash-card .dcb-count {
  min-height: 26px;
}
#accStats {
  display: inline-block;
  min-height: 26px;
  min-width: 6ch;
}
#new-order-cats.nwo-categories {
  min-height: 50px;
}
section.neworder {
  contain: layout;
}

/* Logo header móvil: misma proporción que en PC (no estirar width/height HTML) */
.app-header .app-logo img.logo-lg,
.app-logo img.logo-lg {
  width: auto !important;
  height: 40px !important;
  max-width: min(160px, 55vw);
  object-fit: contain;
  object-position: center;
}
@media (min-width: 768px) {
  .app-header .app-logo img.logo-lg,
  .app-logo img.logo-lg {
    height: auto !important;
    max-height: 80px;
    max-width: 200px;
  }
}
