/* tg-link.css — styles for the "الاشتراك بالنجوم" entry + dialog */

.wg-tg {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  margin: 6px 0;
  padding: 10px 12px;
  min-height: 44px;
  border: 1px solid rgba(120, 170, 255, .28);
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(58, 110, 220, .18), rgba(58, 110, 220, .08));
  color: #eaf1ff;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform .14s ease, background .16s ease, border-color .16s ease, box-shadow .2s ease;
}
.wg-tg:hover { transform: translateY(-1px); background: linear-gradient(180deg, rgba(80, 140, 255, .26), rgba(58, 110, 220, .12)); border-color: rgba(140, 190, 255, .5); box-shadow: 0 6px 20px rgba(20, 60, 160, .28); }
.wg-tg:active { transform: translateY(0) scale(.99); }
.wg-tg .wg-tg-ico { font-size: 18px; line-height: 1; filter: drop-shadow(0 0 6px rgba(255, 210, 90, .45)); }
.wg-tg .wg-tg-txt { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wg-tg #wg-tg-welcome, .wg-tg .wg-tg-txt:empty { display: none; }

/* dialog */
#wg-tg-overlay { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center; padding: 16px; }
#wg-tg-overlay .wg-tg-back { position: absolute; inset: 0; background: rgba(4, 8, 20, .62); backdrop-filter: blur(3px); animation: wg-tg-fade .2s ease both; }
#wg-tg-overlay .wg-tg-card {
  position: relative;
  width: min(440px, 100%);
  max-height: 90vh;
  overflow: auto;
  box-sizing: border-box;
  padding: 22px 20px 20px;
  border-radius: 18px;
  background: linear-gradient(180deg, #12172a, #0c1020);
  border: 1px solid rgba(120, 170, 255, .22);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .55);
  color: #eaf1ff;
  text-align: center;
  animation: wg-tg-pop .26s cubic-bezier(.16, 1, .3, 1) both;
}
#wg-tg-overlay .wg-tg-x {
  position: absolute; top: 10px; inset-inline-end: 12px;
  width: 34px; height: 34px; border-radius: 10px; border: 0;
  background: rgba(255, 255, 255, .06); color: #cdd8f0; font-size: 15px; cursor: pointer;
}
#wg-tg-overlay .wg-tg-x:hover { background: rgba(255, 255, 255, .12); }
#wg-tg-overlay .wg-tg-title { font-size: 19px; font-weight: 800; margin: 4px 0 6px; }
#wg-tg-overlay .wg-tg-sub { font-size: 13.5px; color: #9db0d6; line-height: 1.7; margin-bottom: 14px; }
#wg-tg-overlay .wg-tg-step { font-size: 13px; color: #8fa3c9; text-align: start; margin: 12px 2px 6px; }
#wg-tg-overlay .wg-tg-code {
  display: flex; align-items: center; gap: 8px; justify-content: space-between;
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 12px; padding: 8px 10px;
}
#wg-tg-overlay .wg-tg-code code { font-size: 15px; direction: ltr; unicode-bidi: embed; color: #dfe9ff; letter-spacing: .5px; }
#wg-tg-overlay .wg-tg-copy {
  flex: none; border: 0; border-radius: 9px; padding: 8px 12px; cursor: pointer;
  background: rgba(90, 140, 255, .22); color: #dfe9ff; font-weight: 700; font-size: 12.5px;
}
#wg-tg-overlay .wg-tg-copy:hover { background: rgba(90, 140, 255, .34); }
#wg-tg-overlay .wg-tg-open {
  display: block; margin: 14px auto 4px; max-width: 320px;
  padding: 12px 14px; border-radius: 12px; text-decoration: none; font-weight: 800;
  color: #08122b; background: linear-gradient(180deg, #ffd76a, #f4b73c);
  box-shadow: 0 8px 24px rgba(244, 183, 60, .3);
}
#wg-tg-overlay .wg-tg-open:hover { filter: brightness(1.05); }
#wg-tg-overlay .wg-tg-hint { margin-top: 12px; font-size: 12px; color: #7f93ba; }
#wg-tg-overlay .wg-tg-hint b { color: #cdd8f0; letter-spacing: .5px; direction: ltr; unicode-bidi: embed; }

@keyframes wg-tg-fade { from { opacity: 0 } to { opacity: 1 } }
@keyframes wg-tg-pop { from { opacity: 0; transform: translateY(10px) scale(.97); } to { opacity: 1; transform: none; } }

@media (max-width: 560px) {
  #wg-tg-overlay .wg-tg-card { padding: 20px 16px 16px; border-radius: 16px; }
  #wg-tg-overlay .wg-tg-title { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) {
  #wg-tg-overlay .wg-tg-card, #wg-tg-overlay .wg-tg-back, .wg-tg { animation: none !important; transition: none !important; }
}
