/* Фаза 3: формы кабинета — вход, регистрация, профиль, настройки. Мобильная раскладка — основная. */
:root { --err: #b42318; --ok: #1f7a4d; }
[data-theme="dark"] { --err: #ff8f85; --ok: #6fd3a0; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --err: #ff8f85; --ok: #6fd3a0; } }
.card { background: var(--paper); border-radius: var(--r-card); box-shadow: var(--ring); padding: var(--s5); }
.auth { max-width: 440px; margin: 0 auto; display: grid; gap: var(--s4); }
.auth__foot { color: var(--muted); font-size: 14px; text-align: center; }
.auth__foot a, .acc__card a:not(.pill) { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.f { display: grid; gap: var(--s4); }
.f-row { display: grid; gap: var(--s2); }
.f-label { font-size: 14px; font-weight: 600; color: var(--ink); }
.f-input { min-height: 48px; width: 100%; padding: 0 var(--s4); border: 0; border-radius: var(--r-nav); background: var(--oat); color: var(--ink); font: inherit; font-size: 16px; }
.f-input:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.f-check { display: flex; gap: var(--s3); align-items: flex-start; font-size: 14px; color: var(--text); }
.f-check input { width: 20px; height: 20px; margin-top: 1px; accent-color: var(--ink); flex: none; }
.f-captcha { min-height: 65px; }
.f-msg { font-size: 14px; margin: 0; }
.f-msg--err, .f-err { color: var(--err); }
.f-msg--ok { color: var(--ok); }
.pill:disabled { opacity: .55; cursor: progress; }
.acc__card { display: grid; gap: var(--s4); margin-bottom: var(--s4); max-width: 640px; }
.acc__dl { display: grid; grid-template-columns: minmax(110px, auto) 1fr; gap: var(--s2) var(--s4); margin: 0; }
.acc__dl dt { color: var(--muted); }
.acc__dl dd { margin: 0; color: var(--ink); overflow-wrap: anywhere; }
.acc__secret { display: block; padding: var(--s3) var(--s4); background: var(--oat); border-radius: var(--r-nav); font-size: 16px; letter-spacing: .06em; overflow-wrap: anywhere; user-select: all; }
.acc__list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s2); }
.acc__item { display: flex; gap: var(--s3); align-items: center; justify-content: space-between; padding: var(--s3) 0; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--text); }
.auth__or { text-align: center; margin: 0; }

/* Фаза 6: PickCaptcha. Плитки — кнопки с aria-pressed; на телефоне сетка занимает всю ширину формы. */
.pc { display: grid; gap: var(--s3); padding: var(--s4); border-radius: var(--r-card); background: var(--oat); }
.pc-head { display: flex; gap: var(--s3); align-items: flex-start; justify-content: space-between; }
.pc-prompt { margin: 0; font-weight: 600; color: var(--ink); font-size: 15px; }
.pc-refresh { flex: none; width: 40px; height: 40px; border: 0; border-radius: var(--r-pill); background: var(--paper); color: var(--ink); font-size: 18px; cursor: pointer; box-shadow: var(--ring); }
.pc-grid { display: grid; gap: var(--s2); grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pc-tile { position: relative; padding: 0; border: 0; border-radius: var(--r-nav); background: var(--paper); cursor: pointer; aspect-ratio: 1; overflow: hidden; box-shadow: var(--ring); touch-action: manipulation; }
.pc-tile img { display: block; width: 100%; height: 100%; object-fit: cover; pointer-events: none; user-select: none; }
.pc-tile[aria-pressed="true"] { box-shadow: inset 0 0 0 3px var(--blue); }
.pc-tile[aria-pressed="true"]::after { content: "✓"; position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%; background: var(--blue); color: #fff; font-size: 13px; line-height: 22px; text-align: center; }
.pc-tile:focus-visible, .pc-refresh:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.pc-rotbox { display: grid; gap: var(--s3); justify-items: center; }
.pc-rot { width: min(200px, 60vw); aspect-ratio: 1; border-radius: 50%; overflow: hidden; background: var(--paper); box-shadow: var(--ring); }
.pc-rot img { display: block; width: 100%; height: 100%; user-select: none; pointer-events: none; }
.pc-range { width: 100%; min-height: 40px; accent-color: var(--blue); }
.pc-verify { justify-self: start; }
.pc-status { margin: 0; font-size: 14px; color: var(--muted); }
.pc-status--err { color: var(--err); }
.pc-status--ok { color: var(--ok); }
@media (prefers-reduced-motion: no-preference) { .pc-rot img { transition: transform .05s linear; } }

/* Фаза 7: кошелёк */
.wal__top { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: var(--s4); }
.wal__stat { display: flex; flex-direction: column; gap: 2px; }
.wal__lbl, .wal__sub { font-size: 13px; color: var(--muted); }
.wal__val { font-size: 22px; color: var(--ink); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.wal__lvl { display: flex; flex-direction: column; gap: var(--s3); margin-top: var(--s4); }
.wal__lvlrow { display: flex; justify-content: space-between; align-items: center; gap: var(--s3); }
.wal__list { list-style: none; margin: var(--s3) 0; padding: 0; }
.wal__row { display: flex; justify-content: space-between; align-items: center; gap: var(--s3); padding: var(--s3) 0; border-top: 1px solid var(--line); }
.wal__row div { display: flex; flex-direction: column; min-width: 0; }
.wal__amt { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--ink); white-space: nowrap; }
.wal__amt--in { color: var(--mint); }

/* Фаза 8: Faucet «Coin Forge» */
.fc-forge { display: flex; flex-direction: column; align-items: center; gap: var(--s4); text-align: center; }
.fc-anvil { position: relative; width: 140px; height: 140px; }
.fc-anvil img { width: 100%; height: 100%; object-fit: contain; }
.fc-spark { position: absolute; left: 50%; bottom: 18%; width: 10px; height: 10px; border-radius: 50%; background: var(--gold); opacity: 0; transform: translateX(-50%); }
.fc-clock { display: flex; flex-direction: column; gap: 2px; }
.fc-timer { font-size: 36px; font-variant-numeric: tabular-nums; color: var(--ink); }
.fc-form { display: flex; flex-direction: column; align-items: center; gap: var(--s3); width: 100%; max-width: 420px; }
.fc-form .pill { min-width: 180px; }
.fc-result { display: flex; flex-direction: column; gap: 4px; padding: var(--s3) var(--s4); border-radius: var(--r-card); background: var(--oat); width: 100%; max-width: 420px; }
.fc-result__roll { font-size: var(--fs-card); }
.fc-result__amt { font-size: 22px; color: var(--ink); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.fc-result--good { box-shadow: inset 0 0 0 2px var(--mint); }
.fc-result--great { box-shadow: inset 0 0 0 2px var(--sky); }
.fc-result--jackpot { box-shadow: inset 0 0 0 2px var(--gold); }
.fc-chips { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: var(--s3); }
.fc-chip { display: flex; flex-direction: column; gap: 2px; padding: var(--s3); border-radius: var(--r-card); background: var(--oat); min-width: 0; }
.fc-chip b { font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.fc-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.fc-table th, .fc-table td { text-align: left; padding: var(--s2) var(--s1); border-top: 1px solid var(--line); }
.fc-table th { color: var(--muted); font-weight: 500; font-size: var(--fs-meta); }
@media (prefers-reduced-motion: no-preference) {
  .fc-anvil--hit img { animation: fc-hit .35s var(--ease) 2; }
  .fc-anvil--hit .fc-spark { animation: fc-spark .35s ease-out 2; }
}
@keyframes fc-hit { 0% { transform: rotate(0); } 40% { transform: rotate(-8deg) translateY(4px); } 100% { transform: rotate(0); } }
@keyframes fc-spark { 0% { opacity: 1; transform: translate(-50%, 0) scale(1); } 100% { opacity: 0; transform: translate(-50%, -40px) scale(2.5); } }
/* Фаза 9: вывод */
.wd-note { border-left: 4px solid var(--warn, var(--err)); }
.wd-form { margin-top: 12px; }
.wd-right { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.pill--sm { padding: 4px 10px; font-size: 13px; }
/* Фаза 10: новости на главной кабинета */
.news-row { display: flex; flex-direction: column; gap: 2px; padding: 10px 0; border-top: 1px solid var(--line); color: inherit; text-decoration: none; }
/* Фаза 32: компактная капча и заметная кнопка Verify во всех разделах. */
.pc { max-width: 380px; }
.pc-grid { max-width: 340px; }
.pc-verify { min-height: 40px; padding: 0 22px; font-weight: 700; background: var(--pill); color: var(--pill-text); box-shadow: 0 2px 8px rgba(0, 0, 0, .18); }
.pc-verify:disabled { opacity: .55; cursor: default; }
.pc-verify:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
