@font-face {
  font-family: "Sour Gummy";
  src: url("/sour-gummy.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #f4ebfe;
  --lilac: #dfc5fc;
  --ink: #250250;
  --muted: #654583;
  --focus: #a76af1;
  font-family: "Sour Gummy", ui-rounded, system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100svh;
  display: grid;
  place-items: center;
}

button, a { -webkit-tap-highlight-color: transparent; }

a { color: inherit; }

button { font: inherit; }

button:focus-visible, a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 6px;
}

.page {
  width: min(100% - 40px, 520px);
  padding-block: 48px;
  text-align: center;
}

h1 {
  margin: 0;
  font-size: clamp(48px, 10vw, 72px);
  font-weight: 650;
  letter-spacing: -0.035em;
  line-height: 1.05;
}

.role {
  margin: 20px 0 0;
  font-size: 18px;
  font-weight: 450;
  line-height: 1.5;
}

.website {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 24px;
  padding: 13px 25px;
  border: 3px solid var(--ink);
  background: var(--lilac);
  box-shadow: 4px 4px 0 var(--ink);
  text-decoration: none;
  font-size: 22px;
  font-weight: 600;
  transition: background 150ms, transform 150ms, box-shadow 150ms;
}

svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.website svg { width: 25px; height: 25px; }

.signals {
  margin-top: 44px;
  padding-top: 30px;
  border-top: 3px solid var(--lilac);
}

h2 { margin: 0; font-size: 26px; font-weight: 550; }

.connection {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 10px 0 22px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
}

.status-dot {
  width: 8px;
  height: 8px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  flex-shrink: 0;
}

[data-status="online"] { color: var(--ink); }
[data-status="online"] .status-dot { background: currentColor; }

.buttons { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }

.reaction {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 116px;
  padding: 18px 6px;
  border: 3px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
  font-size: 20px;
  font-weight: 550;
  cursor: pointer;
  transition: background 150ms, transform 150ms, box-shadow 150ms;
}

.reaction svg { width: 32px; height: 32px; }
.reaction:disabled { opacity: 0.45; cursor: not-allowed; }
.reaction.sent { background: var(--lilac); }
.reaction.sent svg { animation: pop 550ms ease-out; }

@media (hover: hover) {
  .website:hover { background: #ecdcfd; transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--ink); }
  .reaction:hover:not(:disabled) { background: var(--lilac); transform: translate(-2px, -2px); box-shadow: 3px 3px 0 var(--ink); }
}

.website:active, .reaction:active:not(:disabled) { transform: translate(2px, 2px); box-shadow: none; }

.feedback {
  min-height: 2.8em;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.4;
}

.feedback.error { color: #81038c; }
noscript p { font-size: 15px; line-height: 1.5; }

@keyframes pop {
  0%, 100% { transform: rotate(0) scale(1); }
  30% { transform: rotate(-12deg) scale(1.18); }
  65% { transform: rotate(8deg) scale(1.08); }
}

@media (max-width: 380px) {
  .page { width: calc(100% - 32px); padding-block: 32px; }
  .role { font-size: 16px; }
  .buttons { gap: 10px; }
  .reaction { font-size: 18px; min-height: 104px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
