/* fun.perkuno.eu – pradžios puslapis (data-page=home) ir testas (data-page=test). Jokių išorinių šriftų ar paveikslėlių. */
:root {
  --bg: #7c4dff;
  --ink: #15132b;
  --yellow: #ffe14d;
  --pink: #ff3d7f;
  --green: #27e08a;
  --red: #ff8a8a;
  --card: #ffffff;
  --bar: 58px;            /* the bottom bar: advert on calm screens, running line during questions */
}

* { box-sizing: border-box; }

html, body { height: 100%; margin: 0; }

body {
  font-family: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  transition: background-color .6s;
  -webkit-user-select: none;
  user-select: none;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

body[data-page=test] { overflow: hidden; }

[hidden] { display: none !important; }

a { color: inherit; }

/* ---------- background ---------- */
.rays { position: fixed; left: 0; top: 0; right: 0; bottom: 0; overflow: hidden; pointer-events: none; }
/* the turning rays are far bigger than the screen; the box above keeps them from widening the page */
.rays::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 220vmax;
  height: 220vmax;
  margin: -110vmax 0 0 -110vmax;
  background: repeating-conic-gradient(from 0deg, rgba(255, 255, 255, .14) 0 10deg, transparent 10deg 20deg);
  animation: spin 70s linear infinite;
}

canvas {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
#bg { z-index: 1; }
#fx { z-index: 20; }

.dvd {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 2;
  padding: .3em .8em;
  font-weight: 900;
  font-size: clamp(16px, 4.2vw, 28px);
  letter-spacing: .1em;
  border: 3px solid var(--ink);
  border-radius: 999px;
  background: var(--yellow);
  box-shadow: 4px 4px 0 var(--ink);
  pointer-events: none;
  will-change: transform;
}

/* ---------- top bar ---------- */
.top {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: calc(10px + env(safe-area-inset-top)) 12px 8px;
  pointer-events: none;
}
.top > * { pointer-events: auto; }
.top .grow { flex: 1; pointer-events: none; }
.progress:not([hidden]) ~ .grow, .progress:not([hidden]) ~ .brand { display: none; }

.brand {
  padding: .45em .9em;
  font-weight: 900;
  font-size: 15px;
  letter-spacing: .02em;
  text-decoration: none;
  background: #fff;
  border: 3px solid var(--ink);
  border-radius: 999px;
  box-shadow: 3px 3px 0 var(--ink);
}
.brand b { color: var(--pink); }

.progress {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  font-size: 15px;
  color: #fff;
  text-shadow: 2px 2px 0 var(--ink);
  white-space: nowrap;
}
.bar {
  position: relative;
  flex: 1;
  height: 18px;
  background: #fff;
  border: 3px solid var(--ink);
  border-radius: 999px;
  box-shadow: 3px 3px 0 var(--ink);
}
.bar i {
  display: block;
  height: 100%;
  width: 0;
  background: var(--green);
  border-radius: 999px;
  transition: width .6s cubic-bezier(.3, 1.5, .5, 1);
}
.bar span {
  position: absolute;
  top: -15px;
  left: 0;
  font-size: 24px;
  line-height: 1;
  transform: translateX(-50%);
  transition: left .6s cubic-bezier(.3, 1.5, .5, 1);
  text-shadow: none;
}

.icon-btn {
  width: 44px;
  height: 44px;
  font-size: 20px;
  line-height: 1;
  border: 3px solid var(--ink);
  border-radius: 14px;
  background: #fff;
  box-shadow: 3px 3px 0 var(--ink);
  cursor: pointer;
  padding: 0;
}
.icon-btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }

/* ---------- stage and card ---------- */
.stage {
  position: fixed;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  display: flex;
  padding: calc(68px + env(safe-area-inset-top)) 14px calc(var(--bar) + 14px + env(safe-area-inset-bottom));
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.card {
  width: min(560px, 100%);
  margin: auto;
  background: var(--card);
  border: 4px solid var(--ink);
  border-radius: 26px;
  box-shadow: 8px 8px 0 var(--ink);
  padding: clamp(18px, 4.5vw, 30px);
  text-align: center;
  animation: cardIn .5s cubic-bezier(.2, 1.6, .4, 1) both;
}
.card.shake { animation: shake .45s linear 2; }

.title {
  margin: .05em 0 .1em;
  /* --fit = letters of the longest word x .74, set by the script: any name fits one line of the card */
  font-size: min(5.2rem, calc(78vw / var(--fit, 6)), calc(470px / var(--fit, 6)));
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: .02em;
  color: var(--pink);
  -webkit-text-stroke: 3px var(--ink);
  paint-order: stroke fill;
  text-shadow: 5px 5px 0 var(--ink);
}
.title .word { display: inline-block; white-space: nowrap; margin: 0 .12em; }
.title .word span {
  display: inline-block;
  animation: wave 1.1s ease-in-out infinite;
  animation-delay: calc(var(--i) * .08s);
}

.lead { margin: .7em 0 1em; font-size: clamp(1.05rem, 4.4vw, 1.3rem); font-weight: 700; line-height: 1.35; }
.fine { margin: 1.1em 0 0; font-size: .9rem; font-weight: 700; opacity: .7; }

.qnum {
  display: inline-block;
  margin: 0 0 .7em;
  padding: .25em .8em;
  font-size: .9rem;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
  background: var(--ink);
  color: var(--yellow);
  border-radius: 999px;
  transform: rotate(-2deg);
}
.q, .lead, .hint, .taunt, .compliment { text-wrap: balance; }
.q { margin: 0; font-size: clamp(1.45rem, 6.4vw, 2.15rem); line-height: 1.15; font-weight: 900; }
.hint { margin: .6em 0 0; font-size: 1rem; font-weight: 700; opacity: .75; }
.taunt { min-height: 1.5em; margin: 1em 0 0; font-size: 1.05rem; font-weight: 900; color: #c2185b; }

/* ---------- buttons ---------- */
.btn {
  font: inherit;
  font-weight: 900;
  font-size: clamp(1.1rem, 4.6vw, 1.4rem);
  line-height: 1.1;
  padding: .7em 1.25em;
  min-height: 52px;
  border: 4px solid var(--ink);
  border-radius: 18px;
  background: var(--yellow);
  color: var(--ink);
  box-shadow: 5px 5px 0 var(--ink);
  cursor: pointer;
  transition: transform .1s, box-shadow .1s;
  touch-action: manipulation;
}
.btn:active { transform: translate(4px, 4px); box-shadow: 1px 1px 0 var(--ink); }
.btn:focus-visible, .icon-btn:focus-visible { outline: 4px solid #3dc7ff; outline-offset: 3px; }
a.btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.btn-yes { background: var(--green); }
.btn-no { background: var(--red); }
.btn-plain { background: #fff; }
.btn.pulse { animation: pulse 1s ease-in-out infinite; }

.answers { display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; align-items: center; margin-top: 22px; }
.answers.grid { display: grid; grid-template-columns: 1fr 1fr; }
.answers.grid .btn { animation: wiggle .7s ease-in-out infinite alternate; animation-delay: calc(var(--i) * -.23s); }
.ph { display: inline-block; visibility: hidden; transition: width .35s, height .35s, margin .35s; }

/* The answer that runs: lifted out of the card so it can use the whole screen. */
.btn.loose {
  position: fixed;
  z-index: 9;
  margin: 0;
  white-space: nowrap;
  transform: rotate(var(--rot, 0deg));
  transition: left .26s cubic-bezier(.2, 1.4, .4, 1), top .26s cubic-bezier(.2, 1.4, .4, 1), transform .26s, background-color .3s;
}
.btn.loose:active { transform: rotate(var(--rot, 0deg)); box-shadow: 5px 5px 0 var(--ink); }
.btn.surrender { background: var(--green); animation: wiggle .35s ease-in-out infinite alternate; }

/* growing / shrinking pair */
.btn.grower { font-size: min(calc(1.3rem * var(--g, 1)), 13vw); transition: font-size .35s cubic-bezier(.2, 1.6, .4, 1), transform .1s, box-shadow .1s; }
.btn.shrinker { transform: scale(var(--s, 1)); transition: transform .35s cubic-bezier(.2, 1.6, .4, 1), opacity .35s; }
.btn.shrinker.gone { opacity: 0; pointer-events: none; }

/* ---------- first screen ---------- */
.hero { position: relative; display: flex; justify-content: center; margin-bottom: 2px; }
.dude { width: min(44vw, 180px); height: auto; overflow: visible; }
.dude .all { animation: hop .5s ease-in-out infinite alternate; }
.dude .shadow { transform-origin: 120px 288px; animation: shadow .5s ease-in-out infinite alternate; }
.dude .arm-l { transform-origin: 84px 138px; animation: armL .5s ease-in-out infinite alternate; }
.dude .arm-r { transform-origin: 156px 138px; animation: armR .5s ease-in-out infinite alternate; }
.dude .leg-l { transform-origin: 103px 208px; animation: legL .5s ease-in-out infinite alternate; }
.dude .leg-r { transform-origin: 137px 208px; animation: legR .5s ease-in-out infinite alternate; }
.dude .head { transform-origin: 120px 124px; animation: bob 1s ease-in-out infinite alternate; }
.dude .crown { transform-origin: 120px 44px; animation: crown 1s ease-in-out infinite alternate; }
.dude .glint { animation: glint 2.4s ease-in-out infinite; }

.bubble {
  position: absolute;
  left: calc(50% + min(15vw, 62px));
  top: 4px;
  max-width: min(40vw, 190px);
  padding: .5em .8em;
  font-size: clamp(.85rem, 3.6vw, 1rem);
  font-weight: 900;
  line-height: 1.2;
  text-align: left;
  background: var(--yellow);
  border: 3px solid var(--ink);
  border-radius: 16px 16px 16px 4px;
  box-shadow: 3px 3px 0 var(--ink);
  animation: pop .35s cubic-bezier(.2, 1.8, .4, 1) both;
}

/* ---------- slider ---------- */
.meter {
  margin: 14px 0 6px;
  font-size: clamp(3rem, 17vw, 5.5rem);
  line-height: 1;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  color: var(--pink);
  -webkit-text-stroke: 3px var(--ink);
  paint-order: stroke fill;
  text-shadow: 5px 5px 0 var(--ink);
}
.meter.max output { display: inline-block; animation: pulse .5s ease-in-out infinite; }

input[type=range] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 44px;
  margin: 8px 0 0;
  background: transparent;
  touch-action: pan-y;
}
input[type=range]::-webkit-slider-runnable-track { height: 18px; background: linear-gradient(90deg, #ff8a8a, #ffe14d, #27e08a); border: 3px solid var(--ink); border-radius: 999px; }
input[type=range]::-moz-range-track { height: 12px; background: linear-gradient(90deg, #ff8a8a, #ffe14d, #27e08a); border: 3px solid var(--ink); border-radius: 999px; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 38px; height: 38px; margin-top: -13px; background: #fff; border: 4px solid var(--ink); border-radius: 50%; box-shadow: 3px 3px 0 var(--ink); }
input[type=range]::-moz-range-thumb { width: 30px; height: 30px; background: #fff; border: 4px solid var(--ink); border-radius: 50%; box-shadow: 3px 3px 0 var(--ink); }

/* ---------- finale ---------- */
.cert {
  position: relative;
  padding: 20px 14px 58px;
  border: 4px dashed var(--ink);
  border-radius: 18px;
  background: repeating-linear-gradient(45deg, #fffbe0 0 14px, #fff3b0 14px 28px);
}
.cert .over { margin: 0; font-size: .85rem; font-weight: 900; letter-spacing: .16em; text-transform: uppercase; }
.cert p { margin: .5em 0; font-size: 1.05rem; font-weight: 700; }
.cert .name {
  margin: .1em 0;
  font-size: min(4.4rem, calc(56vw / var(--fit, 6)), calc(340px / var(--fit, 6)));
  line-height: 1.05;
  font-weight: 900;
  color: var(--pink);
  -webkit-text-stroke: 3px var(--ink);
  paint-order: stroke fill;
  text-shadow: 4px 4px 0 var(--ink);
  animation: pulse 1.2s ease-in-out infinite;
}
.cert .big { font-size: clamp(1.25rem, 5.6vw, 1.7rem); font-weight: 900; }
.cert .stats { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 14px 0 6px; padding: 0; list-style: none; }
.cert .stats li { padding: .3em .7em; font-size: .92rem; font-weight: 900; background: #fff; border: 3px solid var(--ink); border-radius: 999px; }
.cert .sign { margin: 1em 0 0; font-style: italic; }
.stamp {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: .15em .55em;
  font-size: .95rem;
  font-weight: 900;
  letter-spacing: .08em;
  color: #d1122f;
  border: 4px solid #d1122f;
  border-radius: 10px;
  background: rgba(255, 255, 255, .7);
  transform: rotate(-12deg);
  animation: stamp .5s .9s cubic-bezier(.2, 2, .4, 1) both;
}
.compliment { min-height: 3.2em; margin: 16px 0 0; font-size: clamp(1.1rem, 4.8vw, 1.35rem); font-weight: 900; line-height: 1.25; }
.compliment.pop { animation: pop .4s cubic-bezier(.2, 1.8, .4, 1) both; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-top: 14px; }

/* ---------- overlays ---------- */
.bottom {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 25;            /* above the confetti: nothing may cover an advert */
  height: calc(var(--bar) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--ink);
  color: var(--yellow);
  overflow: hidden;
}
.ticker {
  height: var(--bar);
  line-height: var(--bar);
  white-space: nowrap;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: .08em;
}
.ticker-track { display: inline-block; animation: ticker 26s linear infinite; }

/* advert: only on calm screens (start, intro, certificate), never next to the running answers */
.adbar { display: none; height: var(--bar); align-items: center; justify-content: center; }
body.calm .adbar { display: flex; }
body.calm .ticker { display: none; }
.house {
  display: flex;
  align-items: center;
  gap: 10px;
  width: min(100%, 560px);
  height: 100%;
  padding: 0 12px;
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  line-height: 1.2;
}
.house .tag { flex: none; padding: .15em .5em; font-size: 10px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; color: var(--ink); background: #b9b6d3; border-radius: 4px; }
.house .txt { flex: 1; min-width: 0; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.house .txt b { color: var(--yellow); }
.house .go { flex: none; padding: .45em .9em; font-weight: 900; color: var(--ink); background: var(--yellow); border-radius: 999px; }
.adbar ins { display: inline-block; width: 320px; height: 50px; }

.praise {
  position: fixed;
  left: 0;
  right: 0;
  top: 38%;
  z-index: 15;
  padding: 0 12px;
  text-align: center;
  font-size: clamp(2rem, 10vw, 4.2rem);
  line-height: 1.05;
  font-weight: 900;
  color: var(--yellow);
  -webkit-text-stroke: 3px var(--ink);
  paint-order: stroke fill;
  text-shadow: 5px 5px 0 var(--ink);
  pointer-events: none;
  opacity: 0;
}
.praise.show { animation: praise 1.1s cubic-bezier(.2, 1.6, .4, 1) both; }

.toast {
  position: fixed;
  left: 50%;
  top: calc(66px + env(safe-area-inset-top));
  z-index: 30;
  max-width: min(92vw, 460px);
  padding: .6em 1em;
  font-size: 1rem;
  font-weight: 900;
  text-align: center;
  background: var(--ink);
  color: #fff;
  border-radius: 14px;
  transform: translate(-50%, -20px) scale(.9);
  opacity: 0;
  pointer-events: none;
  transition: transform .25s cubic-bezier(.2, 1.6, .4, 1), opacity .25s;
}
.toast.show { transform: translate(-50%, 0) scale(1); opacity: 1; }

/* ---------- keyframes ---------- */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes cardIn { from { transform: translateY(40px) rotate(-4deg) scale(.85); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes wave { 0%, 100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-14px) rotate(4deg); } }
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.07); } }
@keyframes wiggle { from { transform: rotate(-3deg); } to { transform: rotate(3deg); } }
@keyframes pop { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes shake { 0%, 100% { transform: translate(0); } 20% { transform: translate(-7px, 3px) rotate(-1.2deg); } 40% { transform: translate(6px, -3px) rotate(1deg); } 60% { transform: translate(-5px, -2px) rotate(-.8deg); } 80% { transform: translate(5px, 3px) rotate(.8deg); } }
@keyframes praise { 0% { transform: scale(.2) rotate(-14deg); opacity: 0; } 25% { transform: scale(1.1) rotate(-5deg); opacity: 1; } 75% { transform: scale(1) rotate(-5deg); opacity: 1; } 100% { transform: scale(1.5) rotate(-5deg); opacity: 0; } }
@keyframes stamp { from { transform: rotate(-12deg) scale(3); opacity: 0; } to { transform: rotate(-12deg) scale(1); opacity: 1; } }
@keyframes ticker { to { transform: translateX(-50%); } }
@keyframes hop { from { transform: translateY(6px); } to { transform: translateY(-10px); } }
@keyframes shadow { from { transform: scaleX(1.05); } to { transform: scaleX(.8); } }
@keyframes armL { from { transform: rotate(20deg); } to { transform: rotate(62deg); } }
@keyframes armR { from { transform: rotate(-62deg); } to { transform: rotate(-20deg); } }
@keyframes legL { from { transform: rotate(10deg); } to { transform: rotate(-6deg); } }
@keyframes legR { from { transform: rotate(6deg); } to { transform: rotate(-10deg); } }
@keyframes bob { from { transform: rotate(-7deg); } to { transform: rotate(7deg); } }
@keyframes crown { from { transform: rotate(-5deg) translateY(0); } to { transform: rotate(6deg) translateY(-4px); } }
@keyframes glint { 0%, 70%, 100% { opacity: 0; } 80%, 90% { opacity: 1; } }

@media (max-height: 620px) {
  .dude { width: min(34vw, 130px); }
  .lead { margin: .4em 0 .7em; }
}

/* Calmer for people who asked their device for less motion; the running answers stay, they are the point. */
@media (prefers-reduced-motion: reduce) {
  .rays::before, .ticker-track, .title .word span, .btn.pulse, .cert .name, .answers.grid .btn { animation: none; }
}

/* ---------- swap, stars, hold ---------- */
.btn.fixed { background: var(--green); animation: pop .35s cubic-bezier(.2, 1.8, .4, 1) both; }

.stars { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 20px; }
.star {
  width: 54px;
  height: 54px;
  padding: 0;
  font-size: 40px;
  line-height: 1;
  color: #d9d6ea;
  background: none;
  border: 0;
  cursor: pointer;
  -webkit-text-stroke: 2.5px var(--ink);
  paint-order: stroke fill;
  transition: color .15s, transform .15s;
}
.star.on { color: var(--yellow); transform: scale(1.12) rotate(-6deg); }
.star.extra { animation: pop .4s cubic-bezier(.2, 1.8, .4, 1) both; }

.gauge { position: relative; height: 34px; margin: 22px 0 6px; background: #fff; border: 4px solid var(--ink); border-radius: 999px; box-shadow: 4px 4px 0 var(--ink); overflow: hidden; }
.gauge i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #ffe14d, #ff8a00, #ff3d7f); }
.gauge b { position: absolute; left: 0; right: 0; top: 0; line-height: 26px; font-size: 1rem; font-variant-numeric: tabular-nums; }
.btn.holder { margin-top: 12px; touch-action: none; -webkit-touch-callout: none; }
.btn.holder.down { transform: translate(4px, 4px) scale(.97); box-shadow: 1px 1px 0 var(--ink); background: #ff8a00; }

/* ---------- home ---------- */
.home { position: relative; z-index: 3; width: min(600px, 100%); margin: 0 auto; padding: calc(70px + env(safe-area-inset-top)) 14px calc(var(--bar) + 30px + env(safe-area-inset-bottom)); }
.home .card { margin: 0 0 18px; animation: none; }
.home h1 { margin: .2em 0 .3em; font-size: clamp(1.9rem, 8.4vw, 2.9rem); line-height: 1.08; font-weight: 900; text-wrap: balance; }
.home h1 em { font-style: normal; color: var(--pink); }
.home h2 { margin: 0 0 .6em; font-size: 1.3rem; font-weight: 900; }
.home .dude { width: min(34vw, 130px); }

form { text-align: left; }
.field { display: block; margin: 0 0 16px; }
.field > span, legend { display: block; margin: 0 0 6px; padding: 0; font-size: 1rem; font-weight: 900; }
.field small, legend small { font-weight: 700; opacity: .65; }
.field input {
  width: 100%;
  min-height: 54px;
  padding: .5em .8em;
  font: inherit;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--ink);
  background: #fff;
  border: 4px solid var(--ink);
  border-radius: 16px;
  -webkit-user-select: text;
  user-select: text;
}
.field input:focus { outline: 4px solid #3dc7ff; outline-offset: 2px; }
.field input[aria-invalid=true] { border-color: #d1122f; background: #fff1f1; }
.err { min-height: 1.3em; margin: 6px 0 0; font-size: .95rem; font-weight: 900; color: #d1122f; }

fieldset { margin: 0 0 18px; padding: 0; border: 0; min-width: 0; }
.chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 10px; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.chip span { display: flex; align-items: center; gap: 8px; min-height: 50px; padding: .4em .8em; font-weight: 900; background: #fff; border: 3px solid var(--ink); border-radius: 14px; box-shadow: 3px 3px 0 var(--ink); transition: transform .1s, box-shadow .1s, background-color .15s; }
.chip input:checked + span { background: var(--yellow); transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.chip input:focus-visible + span { outline: 4px solid #3dc7ff; outline-offset: 2px; }
.chip i { font-style: normal; font-size: 1.25rem; }

.wide { width: 100%; }
.note { margin: 12px 0 0; font-size: .92rem; font-weight: 700; line-height: 1.4; opacity: .8; text-align: center; }

.linkbox { width: 100%; min-height: 50px; padding: .5em .7em; font: inherit; font-size: .95rem; font-weight: 700; color: var(--ink); background: #f3f1ff; border: 3px dashed var(--ink); border-radius: 14px; -webkit-user-select: all; user-select: all; }
.result .actions { margin-top: 14px; }
.result .actions .btn { flex: 1 1 150px; }

.steps { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; text-align: left; counter-reset: step; }
.steps li { display: flex; gap: 12px; align-items: center; font-weight: 700; line-height: 1.3; counter-increment: step; }
.steps li::before { content: counter(step); flex: none; display: grid; place-items: center; width: 38px; height: 38px; font-weight: 900; background: var(--yellow); border: 3px solid var(--ink); border-radius: 50%; }

.foot { margin: 22px 0 0; text-align: center; font-size: .95rem; font-weight: 700; color: #fff; text-shadow: 1px 1px 0 var(--ink); line-height: 2; }
.foot a { margin: 0 .5em; white-space: nowrap; }

/* ---------- legal pages ---------- */
.legal { text-align: left; -webkit-user-select: text; user-select: text; }
.legal h1 { font-size: clamp(1.6rem, 7vw, 2.2rem); margin: .2em 0 .2em; }
.legal h2 { font-size: 1.15rem; margin: 1.4em 0 .4em; }
.legal p, .legal li { font-size: 1rem; font-weight: 500; line-height: 1.55; }
.legal .muted { opacity: .7; font-size: .92rem; }
.legal ul { padding-left: 1.2em; }
