/* The "Payment received" page in Spire's look: the night sky, one glass card, the mark with its lamp,
   Cinzel for the heading and Alegreya Sans for the line (both kept here, no outside requests). */

@font-face {
  font-family: 'Cinzel';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/cinzel-600-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Alegreya Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/alegreya-sans-400-latin.woff2') format('woff2');
}

:root {
  color-scheme: dark;
  --night: #0B1016;
  --body: #04070B;
  --ridge: #2B3744;
  --mist: #929FAC;
  --text-2: #A7B2BD;
  --moon: #ECE8DF;
  --beacon: #F2B33D;
}

* { box-sizing: border-box; }

html, body { margin: 0; min-height: 100%; }

body {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  color: var(--moon);
  font-family: 'Alegreya Sans', ui-sans-serif, system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.5;
  background-color: var(--night);
  /* A few stars, the beacon's glow high up, and the dark ridges along the bottom. */
  background-image:
    radial-gradient(1.5px 1.5px at 12% 18%, rgba(236, 232, 223, .55), transparent 60%),
    radial-gradient(1px 1px at 27% 9%, rgba(236, 232, 223, .45), transparent 60%),
    radial-gradient(1.5px 1.5px at 71% 14%, rgba(236, 232, 223, .5), transparent 60%),
    radial-gradient(1px 1px at 86% 27%, rgba(236, 232, 223, .4), transparent 60%),
    radial-gradient(1px 1px at 58% 6%, rgba(236, 232, 223, .35), transparent 60%),
    radial-gradient(1px 1px at 40% 24%, rgba(236, 232, 223, .3), transparent 60%),
    radial-gradient(ellipse 60% 40% at 50% 0%, rgba(242, 179, 61, .10), transparent 70%),
    linear-gradient(172deg, transparent 80%, rgba(24, 32, 42, .55) 80.2%, rgba(14, 20, 27, .9) 100%),
    linear-gradient(186deg, transparent 86%, rgba(14, 20, 27, .95) 86.2%, var(--body) 100%),
    linear-gradient(180deg, #0E151D 0%, var(--night) 55%, var(--body) 100%);
  background-attachment: fixed;
}

.card {
  width: 100%;
  max-width: 460px;
  padding: 36px 28px 32px;
  text-align: center;
  border-radius: 18px;
  border: 1px solid rgba(43, 55, 68, .75);
  border-top-color: rgba(242, 179, 61, .30);
  background: linear-gradient(180deg, rgba(24, 32, 42, .62), rgba(14, 20, 27, .74));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 30px 60px -32px rgba(0, 0, 0, .95);
}

.mark { display: block; margin: 0 auto; overflow: visible; }
.mark .lamp { filter: drop-shadow(0 0 4px rgba(242, 179, 61, .9)); }

.wordmark {
  margin: 10px 0 0;
  font-family: 'Cinzel', serif;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--mist);
}

.state { margin-top: 22px; padding-top: 22px; border-top: 1px solid rgba(43, 55, 68, .75); }

h1 {
  margin: 0;
  font-family: 'Cinzel', serif;
  font-weight: 600;
  font-size: clamp(24px, 6.4vw, 30px);
  line-height: 1.25;
  letter-spacing: .04em;
  color: var(--moon);
}

.state p { margin: 12px 0 0; color: var(--text-2); }

/* The script names the state on <html> before the page is drawn, so the right line shows at once;
   without the script, the [hidden] sections stay hidden and "Payment received" shows. */
html[data-state] .state { display: none; }
html[data-state="paid"] #paid,
html[data-state="cancelled"] #cancelled,
html[data-state="card-updated"] #card-updated,
html[data-state="card-unchanged"] #card-unchanged,
html[data-state="link-ended"] #link-ended,
html[data-state="try-later"] #try-later { display: block; }

@media (max-width: 380px) {
  body { font-size: 17px; }
  .card { padding: 30px 20px 26px; }
}
