/* ============================================================
   MORLUP — "Nerede paylaşalım?" penceresi (tüm mini oyunlar)
   Oyunların kendi sınıfları (kk-, wh-, mm-, an- ...) korunur;
   bu dosya pencereye eklenen .share sınıfı üzerinden görünümü toplar.
   ============================================================ */

.share { overflow: visible; padding-top: 30px; }

/* Üstte parlayan paylaş simgesi */
.share h3 { display: flex; flex-direction: column; align-items: center; gap: 12px; font-size: 25px; }
.share h3::before {
  content: "";
  width: 66px; height: 66px; border-radius: 22px;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 15V4M7.5 8.5 12 4l4.5 4.5M5 13v5a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-5' fill='none' stroke='white' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 30px no-repeat,
    linear-gradient(135deg, #b48cff, #7c3aed);
  box-shadow: 0 12px 28px rgba(124, 58, 237, 0.55), 0 0 0 6px rgba(139, 92, 246, 0.15);
  animation: share-bob 2.6s ease-in-out infinite;
}
@keyframes share-bob { 50% { transform: translateY(-5px) rotate(-4deg); } }
.share > p { margin-bottom: 10px !important; }

/* Önizleme: sohbet balonu gibi, renkli çerçeveli */
.share [class$="-share-preview"] {
  position: relative;
  text-align: left; white-space: pre-wrap;
  margin: 8px 0 16px;
  padding: 14px 16px;
  border-radius: 18px 18px 18px 6px;
  border: 1.5px solid transparent;
  background:
    linear-gradient(var(--bg), var(--bg)) padding-box,
    linear-gradient(135deg, #a67bfb, #ed6ba1 55%, #f29e33) border-box;
  color: var(--ink);
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 13.5px; line-height: 1.5;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.3);
  -webkit-user-select: text; user-select: text;
}

/* Düğmeler: büyük, yatay, renkli */
.share [class$="-share-grid"] { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.share [class*="-share-btn"] {
  position: relative; overflow: hidden;
  display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 10px;
  min-height: 58px; padding: 10px 14px; border-radius: 18px;
  border: 0; color: #fff;
  font-family: "Fredoka", sans-serif; font-weight: 600; font-size: 16px;
  text-decoration: none; cursor: pointer;
  transition: transform 0.18s cubic-bezier(.34,1.56,.64,1), box-shadow 0.18s, filter 0.18s;
}
.share [class*="-share-btn"] .ic { font-size: 22px; width: 26px; height: 26px; display: inline-flex; align-items: center; justify-content: center; }
.share [class*="-share-btn"] svg { width: 22px; height: 22px; }
.share [class*="-share-btn"]:hover { transform: translateY(-3px) scale(1.02); filter: brightness(1.08); }
.share [class*="-share-btn"]:active { transform: scale(0.96); }

/* X: siyah, beyaz logo, üstünden geçen ışık */
.share a[class*="-share-btn"] {
  background: linear-gradient(180deg, #2a2a2e, #050505);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.5), inset 0 0 0 1.5px rgba(255, 255, 255, 0.22);
}
.share a[class*="-share-btn"]::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.22), transparent);
  transform: skewX(-18deg);
  animation: share-shine 3.2s ease-in-out 0.8s infinite;
}
@keyframes share-shine { 0%, 60% { left: -60%; } 100% { left: 130%; } }

/* Kopyala: mor */
.share button[class*="-share-btn"].copy {
  background: linear-gradient(180deg, #a67bfb, #7c3aed);
  box-shadow: 0 10px 24px rgba(124, 58, 237, 0.5), inset 0 -3px 0 rgba(0, 0, 0, 0.18);
}
/* Kopyalandı: yeşil + tik */
.share button[class*="-share-btn"].copy.done { background: linear-gradient(180deg, #5fd39e, #2f9e6b); box-shadow: 0 10px 24px rgba(74, 191, 140, 0.45); }
.share button[class*="-share-btn"].copy.done .ic { font-size: 0; }
.share button[class*="-share-btn"].copy.done .ic::before { content: "✓"; font-size: 22px; font-weight: 700; }

/* Kapat: sade */
.share .btn-ghost { border: 0; background: transparent; color: var(--ink-dim); padding: 8px 18px; }
.share .btn-ghost:hover { color: var(--ink); }

@media (max-width: 380px) {
  .share [class$="-share-grid"] { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .share h3::before, .share a[class*="-share-btn"]::after { animation: none; }
}
