/*
 * effiq.win v3 — общая база для всех вариантов.
 * Палитра и форма из логотипа: красный #e8302a, почти чёрный, тёплый белый,
 * скруглённый квадрат, галочка, ромб над «i». Каждый вариант задаёт свои значения
 * переменных ниже — общие компоненты (галочка, полоса энергии, модалки) берут цвета из них.
 */
:root {
  --red: #e8302a; --red-d: #c9231d; --on-red: #fff;
  --ink: #16130f; --mute: #7a7268; --line: #e6dfd3; --soft: #f1ece3;
  --bg: #fbf8f3; --card: #ffffff;
  --font: "Onest", system-ui, sans-serif;
  --r: 18px;
}
[x-cloak] { display: none !important; }
* { -webkit-tap-highlight-color: transparent; }
body { font-family: var(--font); background: var(--bg); color: var(--ink); font-feature-settings: "tnum" 1; }
.num { font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
::selection { background: var(--red); color: var(--on-red); }

/* ---------- логотип ---------- */
.logo { display: inline-flex; align-items: center; gap: .32em; text-decoration: none; color: var(--ink); font-size: 30px; }
.logo svg { width: 1.2em; height: 1.2em; flex: none; }
.wm { font: 800 1em/1 "DM Sans", sans-serif; letter-spacing: -.025em; font-variant-ligatures: none; white-space: nowrap; }
.wm i { font-style: normal; color: var(--red); }
.wm .di { position: relative; }
.wm .di b { position: absolute; left: 50%; top: -.24em; width: .3em; height: .3em; margin-left: -.15em; background: var(--red); transform: rotate(45deg); }

/* ромб — фирменная метка «внимание» и «бонус» (как точка над i в логотипе) */
.dia { display: inline-block; width: .5em; height: .5em; background: var(--red); transform: rotate(45deg); flex: none; }
.dia.o { background: transparent; box-shadow: inset 0 0 0 1.5px currentColor; opacity: .35; }

/* ---------- галочка как в логотипе ---------- */
/* штрих галочки рисуется цветом фона и выходит за правый верхний угол — получается «вырез» */
.chk { width: 30px; height: 30px; flex: none; overflow: visible; }
.chk rect { fill: transparent; stroke: var(--ink); stroke-width: 8; transition: fill .2s, stroke .2s; }
.chk path { fill: none; stroke: var(--chk-bg, var(--card)); stroke-width: 14; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 120; stroke-dashoffset: 120; transition: stroke-dashoffset .4s cubic-bezier(.6,0,.2,1) .08s; }
.chk.on rect { fill: var(--red); stroke: var(--red); }
.chk.on path { stroke-dashoffset: 0; }
.chk.on { animation: chkpop .35s ease-out; }
@keyframes chkpop { 0% { transform: scale(.8) } 60% { transform: scale(1.12) } 100% { transform: scale(1) } }
button:hover > .chk:not(.on) rect, .row:hover .chk:not(.on) rect { stroke: var(--red); }

/* ---------- полоса энергии: заливка, красная штриховка недобора до цели, риска цели ---------- */
.ebar { position: relative; height: 8px; border-radius: 99px; background: var(--soft); overflow: hidden; }
.ebar > i { position: absolute; inset: 0 auto 0 0; background: var(--ink); border-radius: 99px; transition: width .7s cubic-bezier(.2,.8,.2,1); }
.ebar > b { position: absolute; top: 0; bottom: 0; background: repeating-linear-gradient(-45deg, var(--red) 0 2px, transparent 2px 5px); opacity: .85; transition: left .7s cubic-bezier(.2,.8,.2,1), width .7s cubic-bezier(.2,.8,.2,1); }
.ebar > u { position: absolute; top: -2px; bottom: -2px; width: 2px; margin-left: -1px; background: var(--ink); }
.xbar { height: 3px; border-radius: 99px; background: var(--soft); overflow: hidden; }
.xbar > i { display: block; height: 100%; background: var(--red); transition: width .7s cubic-bezier(.2,.8,.2,1); }
.hatch { background: repeating-linear-gradient(-45deg, var(--red) 0 2px, transparent 2px 5px); }

/* ---------- кнопки ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; border-radius: 12px; padding: 9px 16px; font-weight: 700; font-size: 14px; transition: transform .12s, background .15s, color .15s; }
.btn:active { transform: translateY(1px); }
.btn-red { background: var(--red); color: var(--on-red); } .btn-red:hover { background: var(--red-d); }
.btn-ink { background: var(--ink); color: var(--bg); } .btn-ink:hover { background: var(--red); color: var(--on-red); }
.btn-line { box-shadow: inset 0 0 0 1.5px var(--line); } .btn-line:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }
.ico { font-size: 1.15em; line-height: 1; }

/* ---------- эффекты ---------- */
@keyframes floatUp { 0% { opacity: 0; transform: translate(-50%,0) scale(.7) } 15% { opacity: 1; transform: translate(-50%,-10px) scale(1.08) } 100% { opacity: 0; transform: translate(-50%,-64px) scale(1) } }
.float { position: fixed; z-index: 80; pointer-events: none; font: 800 17px var(--font); color: var(--red); animation: floatUp 1.3s ease-out forwards; white-space: nowrap; }
.float.muted { color: var(--ink); font-size: 14px; font-weight: 700; }
@keyframes fall { 0% { transform: translateY(-20px) rotate(0) } 100% { transform: translateY(105vh) rotate(540deg) } }
.confetti { position: fixed; top: 0; width: 9px; height: 9px; z-index: 75; pointer-events: none; border-radius: 2px; animation: fall linear forwards; }
.confetti.dia { width: 8px; height: 8px; border-radius: 0; }
@keyframes pop { 0% { transform: scale(.94); opacity: 0 } 100% { transform: scale(1); opacity: 1 } }
.pop { animation: pop .22s ease-out; }
@keyframes shake { 0%,100% { transform: translateX(0) } 25% { transform: translateX(-5px) } 75% { transform: translateX(5px) } }
.shake { animation: shake .3s ease-in-out 2; }
.noscroll::-webkit-scrollbar { display: none; }
.noscroll { scrollbar-width: none; }

/* ---------- модалки (общая разметка из ui.js) ---------- */
.modal-bg { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 16px; overflow: auto; background: color-mix(in srgb, #16130f 55%, transparent); backdrop-filter: blur(3px); }
.modal { width: 100%; background: var(--card); color: var(--ink); border-radius: 24px; padding: 26px; box-shadow: 0 30px 80px -20px rgba(0,0,0,.45); }
.lbl { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--mute); }
.inp { width: 100%; border-radius: 12px; background: var(--soft); padding: 10px 12px; outline: none; box-shadow: inset 0 0 0 1.5px transparent; transition: box-shadow .15s; }
.inp:focus { box-shadow: inset 0 0 0 1.5px var(--ink); }
input[type=range] { accent-color: var(--red); }

/* lucide.css задаёт иконкам font-size: inherit вне слоёв — это перебивает утилиты Tailwind (text-xl и т.п.) на самом <i> */
[class^="icon-"], [class*=" icon-"] { font-size: revert-layer; line-height: 1; }
