/* SPDX-License-Identifier: AGPL-3.0-only — Copyright (C) 2026 Gabriele Falcinelli (https://gabrielefalcinelli.com)
   Termini aggiuntivi (attribuzione, nomi e loghi): ADDITIONAL-TERMS.md */
/* ── FINESTRA AL DOWNLOAD (tutti i tool) ──
   Scheda pulita sopra la pagina scurita: niente bordi, solo ombra; il colore del tool solo sul pulsante e sul
   nome. */
.thanks {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 16px;
  border: 0;
  background: transparent;
  color: var(--ink);
  overflow: hidden;
}
.thanks[open] { display: grid; place-items: center; }
.thanks::backdrop { background: rgba(0, 0, 0, 0.55); animation: thanks-fade 0.35s ease-out; }

.thanks-card {
  position: relative;
  /* abbastanza larga perché ogni formula del colophon stia su una riga */
  width: min(600px, 100%);
  padding: 34px 32px 26px;
  border-radius: 6px;
  background: var(--bg);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
  text-align: center;
  animation: thanks-in 0.45s cubic-bezier(0.2, 0.9, 0.25, 1.15);
}
:root[data-theme="dark"] .thanks-card { box-shadow: 0 24px 70px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.06); }

/* X come nella finestra di Ko-fi: bianca, al posto del pulsante della lingua (posizionata via script) */
.thanks .thanks-close {
  position: fixed;
  z-index: 2;
  top: 36px;
  right: 8px;
  border-color: #ffffff;
  color: #ffffff;
  background: transparent;
}
.thanks .thanks-close:hover { background: #ffffff; color: #000000; }
.thanks .thanks-close:focus-visible { outline: 2px solid #ffffff; outline-offset: 3px; }

/* Titolo come da mockup: piccolo, maiuscolo, nel colore del testo */
.thanks-title {
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.03em;
  line-height: 1.3;
  text-transform: uppercase;
}
.thanks-text {
  margin-top: 16px;
  font-size: 13px;
  line-height: 1.5;
}
.thanks-text + .thanks-text { margin-top: 8px; }
.thanks-text a { color: inherit; font-weight: 900; text-underline-offset: 3px; }

.thanks-donate {
  display: block;
  width: 100%;
  margin-top: 22px;
  padding: 14px 16px;
  border-radius: 6px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: filter 0.15s, transform 0.15s;
}
.thanks-donate:hover { filter: brightness(1.06); transform: translateY(-1px); }

.thanks-notes {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(127, 127, 127, 0.25);
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}
.thanks-notes a { color: inherit; }
/* Formule per il colophon: corsivo, con "Copia" sottolineato come i link */
.thanks-colophon { display: grid; gap: 4px; margin-top: -2px; }
.thanks-formula { font-style: italic; }
.thanks-copy {
  margin-left: 4px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  text-decoration: underline dotted;
  text-underline-offset: 3px;
}

@keyframes thanks-in {
  from { opacity: 0; transform: translateY(14px) scale(0.96); }
  to { opacity: 1; transform: none; }
}
@keyframes thanks-fade { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .thanks-card, .thanks::backdrop { animation: none; }
}
