/* =========================================================
   dajgames.ir/support: player support form.
   Standalone and light on purpose (no GSAP, no particles): players open it
   from inside a game, often on weak phones and mobile data.
   Never use letter-spacing on Persian text.
   ========================================================= */

@font-face { font-family: "Lalezar"; src: url("../fonts/lalezar-arabic-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0020, U+060C, U+061B, U+061F, U+0621-0655, U+0660-066C, U+0670, U+067E, U+0686, U+0698, U+06A9, U+06AF, U+06C0, U+06CC, U+06F0-06F9, U+200C-200D; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn-arabic-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0020, U+060C, U+061B, U+061F, U+0621-0655, U+0660-066C, U+0670, U+067E, U+0686, U+0698, U+06A9, U+06AF, U+06C0, U+06CC, U+06F0-06F9, U+200C-200D; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn-arabic-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; unicode-range: U+0020, U+060C, U+061B, U+061F, U+0621-0655, U+0660-066C, U+0670, U+067E, U+0686, U+0698, U+06A9, U+06AF, U+06C0, U+06CC, U+06F0-06F9, U+200C-200D; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0021-007E, U+00A9, U+00AB, U+00BB, U+2013-2014, U+2019, U+201C-201D, U+2022; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; unicode-range: U+0021-007E, U+00A9, U+00AB, U+00BB, U+2013-2014, U+2019, U+201C-201D, U+2022; }

/* same tokens as style.css */
:root {
  --lapis: #0E1640;
  --lapis-deep: #070B24;
  --lapis-up: #18245E;
  --firoozeh: #36D1C4;
  --saffron: #FFB238;
  --anar: #E23D5B;
  --plaster: #EFE6D8;
  --plaster-dim: rgba(239, 230, 216, .68);
  --line: rgba(239, 230, 216, .14);
  --display: "Lalezar", "Vazirmatn", system-ui, sans-serif;
  --body: "Vazirmatn", Tahoma, system-ui, sans-serif;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --gutter: clamp(1rem, .5rem + 3vw, 2.5rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh;
  font-family: var(--body); font-size: 1.0625rem; line-height: 1.85;
  color: var(--plaster);
  background:
    radial-gradient(60rem 30rem at 85% -10%, rgba(226, 61, 91, .22), transparent 60%),
    radial-gradient(50rem 30rem at 0% 110%, rgba(54, 209, 196, .14), transparent 60%),
    var(--lapis-deep);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2 { margin: 0; font-weight: 400; line-height: 1.2; }
p { margin: 0; }
a { color: inherit; }
[hidden] { display: none !important; }
::selection { background: var(--anar); color: #fff; }
:focus-visible { outline: 2px solid var(--saffron); outline-offset: 3px; border-radius: 6px; }

/* ---------- Top bar ---------- */
.top {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem var(--gutter); max-width: 46rem; margin-inline: auto;
}
.top__brand img { height: 44px; width: auto; filter: drop-shadow(0 0 10px rgba(226, 61, 91, .55)); }
.top__home { font-size: .875rem; text-decoration: none; opacity: .8; }
.top__home:hover { opacity: 1; color: var(--saffron); }

/* ---------- Layout ---------- */
.wrap { max-width: 46rem; margin-inline: auto; padding: .5rem var(--gutter) 3rem; }
.intro { padding-block: 1rem 1.6rem; }
.kicker { color: var(--saffron); font-weight: 700; font-size: .875rem; }
.intro h1 {
  font-family: var(--display); font-size: clamp(2.3rem, 1.6rem + 3vw, 3.4rem);
  margin-block: .2rem .5rem;
  text-shadow: 0 0 24px rgba(226, 61, 91, .45);
}
.lead { color: var(--plaster-dim); max-width: 40ch; }

.card {
  background: linear-gradient(180deg, rgba(24, 36, 94, .72), rgba(14, 22, 64, .72));
  border: 1px solid var(--line); border-radius: 22px;
  padding: clamp(1.1rem, .7rem + 2vw, 2rem);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .7);
}

/* ---------- Fields ---------- */
.field { border: 0; margin: 0 0 1.5rem; padding: 0; min-width: 0; }
.field legend, .field > label, .label {
  display: block; padding: 0; margin-bottom: .55rem;
  font-weight: 700; font-size: .95rem;
}
small { font-weight: 400; color: var(--plaster-dim); font-size: .8rem; }
.hint { font-size: .8rem; color: var(--plaster-dim); margin-top: .35rem; }

input[type="text"], textarea {
  width: 100%; display: block;
  font: inherit; font-size: 1rem; color: var(--plaster);
  background: rgba(7, 11, 36, .6);
  border: 1.5px solid var(--line); border-radius: 14px;
  padding: .75rem .95rem;
  transition: border-color .2s, box-shadow .2s;
}
textarea { resize: vertical; min-height: 9rem; line-height: 1.8; }
input::placeholder, textarea::placeholder { color: rgba(239, 230, 216, .38); }
input[type="text"]:focus, textarea:focus {
  outline: none; border-color: var(--firoozeh);
  box-shadow: 0 0 0 4px rgba(54, 209, 196, .15);
}
.is-invalid { border-color: var(--anar) !important; box-shadow: 0 0 0 4px rgba(226, 61, 91, .15) !important; }

/* chips (radio buttons) */
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span {
  display: inline-flex; align-items: center; min-height: 44px;
  padding: .4rem 1rem; border-radius: 999px;
  border: 1.5px solid var(--line); background: rgba(7, 11, 36, .45);
  font-size: .9rem; transition: border-color .2s, background-color .2s, color .2s;
}
.chip:hover span { border-color: rgba(239, 230, 216, .35); }
.chip input:checked + span {
  border-color: var(--accent, var(--saffron));
  background: var(--accent, var(--saffron)); color: var(--lapis-deep); font-weight: 700;
}
.chip input:focus-visible + span { outline: 2px solid var(--saffron); outline-offset: 3px; }

/* "opened from inside the game" chip */
.from-game {
  display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .7rem;
  margin-bottom: 1.5rem; padding: .8rem 1rem;
  border-radius: 14px; border: 1px dashed rgba(54, 209, 196, .5);
  background: rgba(54, 209, 196, .08);
}
.from-game__label { font-size: .8rem; color: var(--firoozeh); }
.from-game__meta { font-size: .8rem; color: var(--plaster-dim); }
.from-game .link { margin-inline-start: auto; }

/* screenshot */
.shot {
  display: flex; align-items: center; justify-content: center;
  min-height: 5.5rem; border-radius: 14px; cursor: pointer;
  border: 1.5px dashed rgba(239, 230, 216, .3); background: rgba(7, 11, 36, .35);
  color: var(--plaster-dim); transition: border-color .2s, color .2s;
}
.shot:hover { border-color: var(--saffron); color: var(--plaster); }
.shot input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.shot:focus-within { outline: 2px solid var(--saffron); outline-offset: 3px; }
.shot__empty { display: inline-flex; align-items: center; gap: .5rem; font-size: .9rem; }
.shot__empty svg { width: 24px; height: 24px; }
.shot-preview { display: flex; align-items: flex-end; gap: 1rem; }
.shot-preview img {
  max-height: 11rem; width: auto; border-radius: 10px; border: 1px solid var(--line);
}

.trap { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  width: 100%; min-height: 54px; padding: .6rem 1.4rem;
  border: 0; border-radius: 999px; cursor: pointer;
  font: inherit; font-weight: 700; font-size: 1rem; text-decoration: none;
  background: var(--saffron); color: var(--lapis-deep);
  transition: transform .3s var(--ease), box-shadow .3s, opacity .2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 30px -10px var(--saffron); }
.btn[disabled] { opacity: .6; cursor: wait; transform: none; box-shadow: none; }
.btn.is-busy::before {
  content: ""; width: 18px; height: 18px; border-radius: 50%;
  border: 2.5px solid currentColor; border-inline-end-color: transparent;
  animation: spin .8s linear infinite;
}
.btn--ghost { background: transparent; color: var(--plaster); border: 1.5px solid currentColor; }
.btn--ghost:hover { background: var(--plaster); color: var(--lapis-deep); box-shadow: none; }
.link {
  background: none; border: 0; padding: .2rem 0; cursor: pointer;
  font: inherit; font-size: .875rem; color: var(--firoozeh);
  text-decoration: underline; text-underline-offset: 4px;
}

.error {
  margin-bottom: 1rem; padding: .7rem 1rem; border-radius: 12px;
  background: rgba(226, 61, 91, .14); border: 1px solid rgba(226, 61, 91, .5);
  font-size: .9rem;
}

/* ---------- Success ---------- */
.done { text-align: center; }
.done:focus { outline: none; }
.done__icon svg { width: 76px; height: 76px; margin: 0 auto 1rem; fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.done__icon circle { stroke: var(--firoozeh); stroke-dasharray: 151; stroke-dashoffset: 151; animation: draw .7s var(--ease) forwards; }
.done__icon path { stroke: var(--saffron); stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw .45s .55s var(--ease) forwards; }
.done h2 { font-family: var(--display); font-size: 2rem; margin-bottom: .8rem; }
.done__code {
  font-family: var(--body); font-weight: 700; font-size: 2.2rem; line-height: 1.4;
  color: var(--saffron); text-shadow: 0 0 20px rgba(255, 178, 56, .4);
}
.done__note { color: var(--plaster-dim); max-width: 34ch; margin: 1rem auto 1.6rem; }
.done .btn { width: auto; }

.alt { margin-top: 1.6rem; text-align: center; font-size: .85rem; color: var(--plaster-dim); }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition: none !important; }
}
