.xp-popup {
  position: fixed;
  width: 280px;
  max-width: 85vw;
  z-index: 55;
  background: #ece9d8;
  border: 3px solid #0054e3;
  border-radius: 8px 8px 0 0;
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
  overflow: hidden;
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.xp-popup.xp-hidden {
  opacity: 0;
  transform: scale(0.3);
  pointer-events: none;
}

.xp-popup.xp-visible {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

@media (max-width: 360px) {
  .xp-popup {
    width: 95vw;
  }

  .xp-title {
    font-size: 11px;
  }

  .xp-btn {
    width: 18px;
    height: 18px;
    font-size: 10px;
  }
}

.xp-titlebar {
  background: linear-gradient(180deg, #0997ff, #0053e0);
  padding: 6px 8px;
  cursor: move;
  user-select: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.xp-title {
  font-family: 'Trebuchet MS', Tahoma, sans-serif;
  font-weight: bold;
  font-size: 12px;
  color: #fff;
  text-shadow: 1px 1px 1px rgba(0,0,0,0.4);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 280px;
}

.xp-buttons {
  display: flex;
  gap: 3px;
}

.xp-btn {
  width: 21px;
  height: 21px;
  border: 1px solid rgba(0,0,0,0.3);
  border-radius: 3px;
  font-size: 12px;
  font-weight: bold;
  font-family: 'Trebuchet MS', Tahoma, sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  padding: 0;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.3), 0 1px 2px rgba(0,0,0,0.2);
}

.xp-btn-minimize {
  background: linear-gradient(180deg, #3c8cf5, #2670d6);
  color: #fff;
  text-shadow: 0 1px 0 rgba(0,0,0,0.2);
}

.xp-btn-minimize:hover {
  background: linear-gradient(180deg, #5ba0f7, #3c8cf5);
}

.xp-btn-close {
  background: linear-gradient(180deg, #e08358, #c5543a);
  color: #fff;
  text-shadow: 0 1px 0 rgba(0,0,0,0.2);
}

.xp-btn-close:hover {
  background: linear-gradient(180deg, #e89a75, #d66a50);
}

.xp-body-img {
  background: #fff;
  border-top: 2px solid #0054e3;
  display: flex;
  align-items: center;
  justify-content: center;
}

.xp-body-img img {
  width: 100%;
  height: auto;
  display: block;
}
