@font-face { font-family: Manrope; src: url(/vendor/manrope-cyrillic-wght-normal.woff2) format('woff2'); font-weight: 200 800; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: Manrope; src: url(/vendor/manrope-latin-wght-normal.woff2) format('woff2'); font-weight: 200 800; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

@property --sky1 { syntax: '<color>'; inherits: true; initial-value: #0f3f7d; }
@property --sky2 { syntax: '<color>'; inherits: true; initial-value: #2f7fc4; }

:root {
  --ease: cubic-bezier(.2, .8, .2, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --accent: #ffc94d;
  --accent-ink: #2a1c00;
  --radius: 22px;
  transition: --sky1 1.2s ease, --sky2 1.2s ease;
}
:root, :root[data-theme="dark"] {
  color-scheme: dark;
  --text: #f4f8fc;
  --text-2: rgba(244, 248, 252, .78);
  --muted: rgba(244, 248, 252, .62);
  --line: rgba(255, 255, 255, .16);
  --glass: rgba(9, 20, 36, .42);
  --glass-2: rgba(255, 255, 255, .1);
  --sheet: #142235;
  --surface-solid: #1b2c42;
  --surface-2: #1f3249;
  --good: #1f9d6b;
  --halo: 0 1px 12px rgba(0, 10, 30, .4);
  --blue: #69b7ff;
}
:root[data-theme="light"] {
  color-scheme: light;
  --text: #102136;
  --text-2: rgba(16, 33, 54, .8);
  --muted: rgba(16, 33, 54, .64);
  --line: rgba(16, 33, 54, .14);
  --glass: rgba(255, 255, 255, .55);
  --glass-2: rgba(255, 255, 255, .55);
  --sheet: #f6f9fc;
  --surface-solid: #ffffff;
  --surface-2: #eaf0f6;
  --good: #14805a;
  --halo: 0 1px 12px rgba(255, 255, 255, .55);
  --blue: #1c6fd1;
  --accent: #f0a500;
  --accent-ink: #2a1c00;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; min-height: 100%; }
html { background: var(--sky2); }
body {
  font-family: Manrope, system-ui, sans-serif; color: var(--text); font-size: 16px; line-height: 1.4;
  transition: color .3s;
  overflow-x: hidden;
}
/* Отдельный слой: на iOS background-attachment: fixed не работает. */
body::before { content: ''; position: fixed; inset: 0; z-index: -1; background: linear-gradient(180deg, var(--sky1), var(--sky2)); }
body.is-pro { overflow: hidden; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
button:disabled { opacity: .45; cursor: default; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3, p { margin: 0; }
small { font-size: 12.5px; color: var(--muted); }
[hidden] { display: none !important; }
#scene { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
#app { position: relative; z-index: 1; }
svg { display: block; }

.glass { background: var(--glass); border: 1px solid var(--line); border-radius: var(--radius); backdrop-filter: blur(14px) saturate(1.2); -webkit-backdrop-filter: blur(14px) saturate(1.2); }
.icon-btn { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; flex: none; transition: transform .2s var(--spring), background .2s; }
.icon-btn svg, .place-btn svg, .chip svg, .picked svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:hover { background: var(--glass-2); }
.icon-btn:active { transform: scale(.9); }
.icon-btn.solid { background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.icon-btn.lit { box-shadow: inset 0 0 0 2px var(--accent); }
.icon-btn.busy { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 18px; border-radius: 15px; background: var(--glass-2); border: 1px solid var(--line); font-weight: 700; transition: transform .2s var(--spring), filter .2s; }
.btn:hover { filter: brightness(1.07); }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.btn.wide { width: 100%; margin-top: 10px; }
.btn.big { min-height: 54px; font-size: 17px; font-weight: 700; letter-spacing: 0; margin-top: 0; line-height: normal; }
.btn.ghost { background: none; }
.link { color: inherit; text-decoration: underline; text-underline-offset: 3px; font-weight: 600; font-size: 14px; }
.link.center { display: block; margin: 14px auto 0; }
.input { width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 14px; background: var(--glass-2); border: 1px solid var(--line); outline: 0; margin-bottom: 10px; font-size: 16px; }
.input.big { min-height: 54px; font-size: 18px; font-weight: 500; letter-spacing: 0; margin-top: 0; line-height: normal; }
.input:focus { border-color: var(--accent); }
.input::placeholder { color: var(--muted); }
select.input option { color: #102136; background: #fff; }
.chip { display: inline-flex; gap: 6px; align-items: center; min-height: 38px; padding: 6px 14px; border-radius: 999px; background: var(--glass-2); border: 1px solid var(--line); font-weight: 600; font-size: 14px; white-space: nowrap; transition: background .2s, transform .2s var(--spring); }
.chip:active { transform: scale(.95); }
.chip.on { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.seg { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); flex: none; }
.seg button { padding: 7px 15px; border-radius: 999px; font-weight: 700; font-size: 14px; transition: background .25s, color .25s; }
.seg button.on { background: var(--accent); color: var(--accent-ink); }
.seg.small button { padding: 5px 11px; font-size: 13px; }

/* ---------- иконки погоды ---------- */
.wi { width: 40px; height: 40px; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.i-sun { fill: #ffc94d; stroke: none; }
.i-rays path { stroke: #ffc94d; stroke-width: 3; }
.i-rays { transform-origin: 24px 24px; }
.i-moon { fill: #dfe6ff; stroke: #8c9ad0; stroke-width: 1; }
.i-cloud { fill: #e7eef6; stroke: #8fa3b8; stroke-width: 1.200; }
.i-rain { stroke: #4ea3f2; stroke-width: 3; }
.i-bolt { fill: #ffc94d; stroke: #b98300; stroke-width: 1; }
.i-snow circle { fill: #a9d8ff; stroke: #5d97c9; stroke-width: .8; }
.i-line { stroke: #8fb2cc; stroke-width: 3; }

/* ---------- верхняя панель ---------- */
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 8px; padding: calc(10px + env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) 10px max(14px, env(safe-area-inset-left)); max-width: 1180px; margin: 0 auto; }
body.is-pro .top { position: fixed; left: 0; right: 0; max-width: none; z-index: 30; pointer-events: none; }
body.is-pro .top > * { pointer-events: auto; }
.place-btn { display: flex; align-items: center; gap: 5px; min-height: 42px; padding: 6px 10px; margin-right: auto; border-radius: 15px; font-weight: 800; font-size: 17px; min-width: 0; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.place-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 34vw; }
.avatar { --pct: 0; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; flex: none; background: conic-gradient(var(--accent) calc(var(--pct) * 1%), var(--line) 0); }
.avatar span { width: 35px; height: 35px; border-radius: 50%; display: grid; place-items: center; font-size: 18px; background: var(--sheet); }
.avatar.big { width: 76px; height: 76px; }
.avatar.big span { width: 65px; height: 65px; font-size: 32px; }

/* ---------- Light ---------- */
.light { max-width: 1180px; margin: 0 auto; padding: 4px max(14px, env(safe-area-inset-right)) 34px max(14px, env(safe-area-inset-left)); }
.reveal { animation: rise .6s var(--ease) both; animation-delay: calc(var(--i, 0) * 45ms); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes pop { from { opacity: 0; transform: scale(.6); } }
.hero { display: grid; grid-template-columns: 1fr minmax(240px, 340px); align-items: end; gap: 18px; min-height: 40vh; padding: 3vh 6px 12px; }
.hero-time::first-letter, .m-when b::first-letter { text-transform: uppercase; }
.hero-time { font-weight: 600; color: var(--text-2); text-shadow: var(--halo); }
.hero-temp { font-size: clamp(92px, 19vw, 176px); font-weight: 200; letter-spacing: -.05em; line-height: 1; margin-left: -.03em; font-variant-numeric: tabular-nums; text-shadow: var(--halo); }
.hero-cond { font-size: clamp(22px, 3.4vw, 30px); font-weight: 700; text-shadow: var(--halo); }
.hero-sub { margin-top: 6px; color: var(--text-2); text-shadow: var(--halo); }
.hero-sub b { color: var(--text); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.buddy { display: flex; align-items: flex-end; gap: 10px; text-align: left; }
.mascot { display: block; width: 84px; flex: none; animation: float 4.5s ease-in-out infinite; }
.mascot.hop { animation: hop .55s var(--spring); }
@keyframes float { 50% { transform: translateY(-7px); } }
@keyframes hop { 40% { transform: translateY(-18px) scale(1.06, .95); } }
.m-body { fill: #fff; stroke: #b9cce0; stroke-width: 1.500; }
.m-eyes { fill: #1f3350; transform-origin: 60px 53px; animation: blink 4.5s infinite; }
.m-shine { fill: #fff; }
.m-mouth { fill: none; stroke: #1f3350; stroke-width: 3.500; stroke-linecap: round; }
.m-cheek { fill: #ffb0b0; opacity: .75; }
@keyframes blink { 0%, 94%, 100% { transform: scaleY(1); } 97% { transform: scaleY(.08); } }
.bubble { position: relative; padding: 11px 14px; border-radius: 18px 18px 18px 4px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); font-weight: 600; font-size: 14.5px; }
.sec { font-size: 21px; font-weight: 800; margin: 24px 4px 10px; text-shadow: var(--halo); }
.hours { display: flex; gap: 2px; overflow-x: auto; padding: 10px; scrollbar-width: thin; }
.hour { flex: none; width: 74px; padding: 8px 2px; border-radius: 16px; display: flex; flex-direction: column; align-items: center; gap: 3px; }
.hour.now { background: var(--glass-2); }
.hour b { font-size: 17px; font-weight: 800; }
.hour .pp { font-size: 12px; }
.hour .pp.wet, .d-pp.wet { color: var(--blue); font-weight: 700; }
.hour .hw i { display: inline-block; font-style: normal; margin-right: 2px; }
.chart-card { margin-top: 12px; padding: 14px 16px 8px; }
.chart-card h3, .metric h3 { font-size: 13.5px; font-weight: 700; color: var(--text-2); }
.tchart { position: relative; margin-top: 2px; touch-action: pan-y; }
.t-line { fill: none; stroke: var(--accent); stroke-width: 2.500; stroke-linecap: round; }
.t-a { stop-color: var(--accent); stop-opacity: .34; }
.t-b { stop-color: var(--accent); stop-opacity: 0; }
.t-base { stroke: var(--line); }
.t-x { fill: var(--muted); font-size: 12px; }
.t-v { fill: var(--text); font-weight: 800; font-size: 14px; }
.t-pt { fill: var(--accent); stroke: var(--sheet); stroke-width: 2; }
.t-cross line { stroke: var(--text-2); stroke-dasharray: 3 3; }
.t-cross circle { fill: var(--accent); stroke: var(--sheet); stroke-width: 2; }
.t-tip { position: absolute; top: -4px; transform: translateX(-50%); padding: 5px 10px; border-radius: 10px; background: var(--sheet); border: 1px solid var(--line); font-size: 13px; white-space: nowrap; pointer-events: none; text-align: center; }
.metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 12px; }
.metric { padding: 15px 16px; }
.metric p { font-size: 14px; color: var(--text-2); margin-top: 7px; }
.metric.wide { grid-column: span 3; }
.big { font-size: 34px; font-weight: 300; letter-spacing: -.02em; margin-top: 4px; font-variant-numeric: tabular-nums; line-height: 1.15; }
.big small { font-size: 15px; font-weight: 600; letter-spacing: 0; }
.wind-row { display: flex; gap: 14px; align-items: center; margin-top: 8px; }
.compass { position: relative; width: 66px; height: 66px; border-radius: 50%; border: 1.5px dashed var(--line); flex: none; display: grid; place-items: center; }
.compass .n { position: absolute; top: -1px; font-size: 10px; font-weight: 800; color: var(--muted); }
.compass i { display: block; width: 36px; height: 36px; transition: transform 1s var(--spring); }
.compass svg path { fill: var(--accent); }
.meter { position: relative; height: 7px; border-radius: 99px; background: var(--line); margin-top: 11px; }
.meter i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 99px; background: linear-gradient(90deg, #6fd3e8, #2f76e0); animation: grow 1s var(--ease) both; transform-origin: left; }
.meter.blue i { background: linear-gradient(90deg, #8ac2f5, #2f76e0); }
.meter.grey i { background: linear-gradient(90deg, #cdd7e0, #8896a6); }
@keyframes grow { from { transform: scaleX(0); } }
.meter.dot { background: linear-gradient(90deg, #5a7fe0, #4ec39a, #f0d44e, #f28c33); }
.meter.uv { background: linear-gradient(90deg, #4ec39a, #f0d44e, #f28c33, #d93d3a, #9c2a8c); }
.meter.dot i { width: 15px; height: 15px; top: -4px; background: #fff; border: 3px solid #1f3350; transform: translateX(-50%); animation: none; }
.sun-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 2px; }
.sun-row small, .sun-row b { display: block; }
.sun-row b { font-size: 21px; font-weight: 700; }
.sun-row .right { text-align: right; }
.sun-arc { flex: 1; max-width: 260px; min-width: 0; height: auto; overflow: visible; }
.arc { fill: none; stroke: var(--accent); stroke-width: 2; stroke-dasharray: 3 6; stroke-linecap: round; }
.hor { stroke: var(--line); }
.sun-dot { fill: var(--accent); filter: drop-shadow(0 0 7px var(--accent)); }
.week { padding: 4px 8px; }
.day { border-bottom: 1px solid var(--line); }
.day:last-child { border-bottom: 0; }
.day summary { display: grid; grid-template-columns: minmax(102px, 1.2fr) 44px 56px minmax(150px, 3fr) 22px; align-items: center; gap: 8px; padding: 9px 6px; cursor: pointer; list-style: none; }
.day summary::-webkit-details-marker { display: none; }
.d-name b { display: block; text-transform: capitalize; font-weight: 700; }
.d-pp { font-size: 13px; color: var(--muted); }
.d-range { display: flex; align-items: center; gap: 8px; font-variant-numeric: tabular-nums; }
.d-range b { width: 42px; text-align: right; font-weight: 800; }
.d-range b.lo { color: var(--muted); }
.track { position: relative; flex: 1; height: 6px; border-radius: 9px; background: var(--line); }
.track i { position: absolute; top: 0; bottom: 0; border-radius: 9px; }
.d-chev svg { width: 18px; height: 18px; fill: none; stroke: var(--muted); stroke-width: 2; transition: transform .25s; }
.day[open] .d-chev svg { transform: rotate(180deg); }
.d-more { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px 14px; padding: 2px 8px 14px; animation: rise .35s var(--ease); }
.d-cond { grid-column: 1 / -1; font-weight: 700; }
.stat small, .stat b { display: block; }
.stat b { font-weight: 700; }
.ov-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 9px; }
.ov { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 6px; padding: 7px 12px; text-align: left; border-radius: 16px; font-weight: 600; font-size: 14px; transition: transform .2s var(--spring); }
.ov:hover { transform: translateY(-2px); }
.ov .wi { width: 30px; height: 30px; }
.ov b { font-weight: 800; }
.foot { margin: 28px auto 0; max-width: 420px; text-align: center; }
.attr { font-size: 11.5px; color: var(--muted); margin-top: 12px; text-align: center; }
.loading { min-height: 60vh; display: grid; place-content: center; justify-items: center; gap: 12px; padding: 20px; text-align: center; font-weight: 600; }
.loading .mascot-svg { width: 96px; animation: float 3s ease-in-out infinite; }

/* ---------- окна ---------- */
#sheet-root { position: relative; z-index: 60; }
.sheet-back { position: fixed; inset: 0; background: rgba(4, 10, 20, .5); animation: fade .25s; }
@keyframes fade { from { opacity: 0; } }
.sheet { position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); width: min(520px, 100vw); max-height: 90dvh; overflow-y: auto; background: var(--sheet); border-radius: 26px 26px 0 0; padding: 18px 18px calc(22px + env(safe-area-inset-bottom)); animation: up .36s var(--ease); }
@keyframes up { from { transform: translate(-50%, 40px); opacity: 0; } }
@media (min-width: 720px) {
  .sheet { top: 50%; bottom: auto; transform: translate(-50%, -50%); border-radius: 26px; animation: pop2 .3s var(--ease); }
  @keyframes pop2 { from { transform: translate(-50%, -46%); opacity: 0; } }
}
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.sheet h2 { font-size: 22px; font-weight: 800; }
.sheet h3 { font-size: 13.5px; font-weight: 700; color: var(--muted); margin: 16px 0 7px; }
.search-row { display: flex; gap: 8px; align-items: flex-start; }
.search-row .icon-btn { width: 46px; height: 46px; }
.list { max-height: 34dvh; overflow-y: auto; }
.row-btn { display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 13px; }
.row-btn:hover { background: var(--glass-2); }
.row-btn.solid { background: var(--glass-2); border: 1px solid var(--line); }
.row-btn b, .row-btn small { display: block; }
.saved { display: flex; align-items: center; }
.hint { padding: 9px 12px; color: var(--muted); font-size: 14px; }
.scope-note { font-size: 14px; color: var(--text-2); margin-bottom: 11px; }
.profile { display: flex; gap: 14px; align-items: center; }
.profile-txt { flex: 1; min-width: 0; }
.profile-txt b, .profile-txt small { display: block; }
.profile-txt b { font-size: 18px; font-weight: 800; }
.xp { height: 7px; background: var(--line); border-radius: 9px; margin: 6px 0 3px; overflow: hidden; }
.xp i { display: block; height: 100%; background: var(--accent); border-radius: 9px; }
.ach-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; margin-top: 13px; }
.ach { text-align: center; padding: 8px 3px; border-radius: 13px; background: var(--glass-2); opacity: .55; }
.ach span { display: block; font-size: 23px; filter: grayscale(1); }
.ach small { display: block; font-size: 10.5px; line-height: 1.2; }
.ach.got { opacity: 1; box-shadow: inset 0 0 0 1.5px var(--accent); }
.ach.got span { filter: none; }
.guest-card p { color: var(--text-2); font-size: 15px; }
.form-err { color: #ff8a80; font-size: 14px; margin-bottom: 6px; }
:root[data-theme="light"] .form-err { color: #c0271a; }
#toasts { position: fixed; z-index: 80; top: calc(62px + env(safe-area-inset-top)); left: 50%; transform: translateX(-50%); width: min(380px, calc(100vw - 24px)); display: grid; gap: 8px; pointer-events: none; }
.toast { display: flex; gap: 10px; align-items: center; padding: 11px 15px; border-radius: 16px; background: var(--sheet); border: 1px solid var(--line); box-shadow: 0 12px 30px rgba(0, 10, 30, .3); font-weight: 600; font-size: 14.5px; animation: rise .4s var(--spring); transition: opacity .35s, transform .35s; }
.toast.out { opacity: 0; transform: translateY(-10px); }
.toast-ic { font-size: 25px; }
.toast.ach { box-shadow: 0 12px 30px rgba(0, 10, 30, .3), inset 0 0 0 1.5px var(--accent); }

/* ---------- территория ---------- */
.scope-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.scope-card { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 11px 5px; border-radius: 17px; background: var(--glass-2); border: 1.5px solid var(--line); text-align: center; transition: transform .2s var(--spring), border-color .2s; }
.scope-card span { font-size: 25px; line-height: 1.25; }
.flag-ua { display: inline-block; width: 30px; height: 21px; border-radius: 4px; background: linear-gradient(180deg, #2f6fd6 50%, #ffd23f 50%); vertical-align: -2px; }
.scope-card b { font-size: 14px; font-weight: 800; line-height: 1.15; }
.scope-card small { font-size: 11.5px; line-height: 1.2; }
.scope-card.on { border-color: var(--accent); transform: translateY(-2px); }
.scope-sub { margin-top: 11px; }
.field-label { display: block; font-size: 13px; font-weight: 700; color: var(--text-2); margin-bottom: 5px; }
.picked { display: flex; align-items: center; gap: 6px; margin-top: 2px; font-size: 15px; }
.picked svg { width: 17px; height: 17px; }
.picked small { margin-left: 4px; }

/* ---------- знакомство ---------- */
.ob { min-height: 100dvh; display: flex; flex-direction: column; padding: calc(12px + env(safe-area-inset-top)) 16px calc(16px + env(safe-area-inset-bottom)); }
.ob-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 980px; width: 100%; margin: 0 auto; }
.ob-hud { position: relative; display: grid; grid-template-columns: 1fr auto; column-gap: 8px; align-items: center; flex: 1; max-width: 300px; }
.ob-quest { grid-column: 1 / -1; font-size: 12.5px; font-weight: 700; color: var(--text-2); }
.ob-bar { height: 9px; border-radius: 9px; background: var(--line); overflow: hidden; }
.ob-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent), #ff8f4d); border-radius: 9px; transition: width .7s var(--spring); }
.ob-hud b { font-size: 13.5px; font-weight: 800; }
.xp-float { position: absolute; right: 0; top: 34px; font-weight: 800; color: var(--accent); text-shadow: var(--halo); animation: floatUp 1.5s var(--ease) both; white-space: nowrap; }
@keyframes floatUp { from { opacity: 0; transform: translateY(14px) scale(.8); } 20% { opacity: 1; transform: none; } to { opacity: 0; transform: translateY(-22px); } }
.ob-opts { display: flex; gap: 6px; align-items: center; margin-left: auto; }
.ob-stage { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 440px); gap: 38px; align-items: center; max-width: 980px; width: 100%; margin: 0 auto; padding: 20px 0; }
.ob-char { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.ob-char .mascot { width: clamp(120px, 20vw, 196px); cursor: pointer; }
.ob-say { min-height: 5.200em; font-size: clamp(19px, 2.500vw, 27px); font-weight: 700; line-height: 1.3; text-shadow: var(--halo); }
.ob-panel { padding: 18px; border-radius: 24px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); animation: rise .5s var(--ease) both; }
.ob-title { font-size: clamp(38px, 6vw, 52px); font-weight: 800; letter-spacing: -.03em; line-height: 1.05; }
.ob-lead { margin: 6px 0 10px; color: var(--text-2); }
.elements { display: grid; grid-template-columns: repeat(5, 1fr); gap: 7px; margin-bottom: 4px; }
.element { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 11px 2px; border-radius: 15px; background: var(--glass-2); border: 1.5px solid var(--line); transition: transform .25s var(--spring), border-color .2s; }
.element span { font-size: 28px; }
.element b { font-size: 12px; font-weight: 700; }
.element.on { border-color: var(--accent); transform: translateY(-4px) scale(1.06); }
.game { position: relative; height: 232px; border-radius: 18px; overflow: hidden; background: linear-gradient(180deg, rgba(120, 170, 225, .35), rgba(120, 170, 225, .08)); border: 1px solid var(--line); touch-action: manipulation; }
.game-sun { position: absolute; left: 50%; top: 50%; font-size: 76px; opacity: 0; transform: translate(-50%, -50%) scale(.6); transition: transform .4s var(--spring), opacity .4s; }
.g-cloud .wi { width: 72px; height: 72px; pointer-events: none; }
.g-cloud { position: absolute; width: 74px; height: 74px; animation: drift 3s ease-in-out infinite alternate; transition: transform .28s var(--ease), opacity .28s; }
.g-cloud.pop { opacity: 0; transform: scale(1.8); pointer-events: none; }
@keyframes drift { to { translate: 9px -7px; } }
.game-foot { display: flex; justify-content: space-between; font-weight: 800; font-size: 18px; margin: 8px 3px 0; }
.modes { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.mode-card { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding: 14px; border-radius: 17px; background: var(--glass-2); border: 1.5px solid var(--line); text-align: left; transition: transform .2s var(--spring), border-color .2s; }
.mode-card span { font-size: 31px; }
.mode-card b { font-size: 18px; font-weight: 800; }
.mode-card.on { border-color: var(--accent); transform: translateY(-3px); }
.pw-row { display: flex; gap: 10px; align-items: stretch; }
.pw-row .input { margin-bottom: 0; }
.thermo { position: relative; flex: none; width: 18px; border-radius: 12px; background: var(--line); overflow: hidden; }
.thermo i { position: absolute; left: 0; right: 0; bottom: 0; height: 0; background: #4ea3f2; transition: height .4s var(--spring), background .3s; }
.thermo i[data-s="2"] { background: #f0d44e; }
.thermo i[data-s="3"] { background: #f28c33; }
.thermo i[data-s="4"] { background: #e5482f; }
.pw-word { min-height: 1.500em; margin: 5px 2px 2px; font-weight: 700; font-size: 14px; color: var(--text-2); }
.finale { text-align: center; }
.burst { font-size: 74px; animation: pop .7s var(--spring) both; }
.fin-lv { font-weight: 700; color: var(--text-2); }
.fin-ach { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-bottom: 4px; }
.fin-ach span { padding: 5px 10px; border-radius: 99px; font-size: 13.5px; font-weight: 700; background: var(--glass-2); border: 1px solid var(--accent); }

/* ---------- галерея ---------- */
body.gallery .light, body.gallery .top { visibility: hidden; }
#gallery { position: fixed; z-index: 50; left: 0; right: 0; bottom: 0; padding: 12px 12px calc(12px + env(safe-area-inset-bottom)); background: var(--glass); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
.gal-chips { display: flex; flex-wrap: wrap; gap: 7px; justify-content: center; max-height: 38dvh; overflow-y: auto; }
.gal-chips .wi { width: 24px; height: 24px; }
.gal-foot { display: flex; justify-content: center; align-items: center; gap: 12px; margin-top: 10px; }
.gal-foot label { cursor: pointer; }

/* ---------- Pro ---------- */
.pro { position: fixed; inset: 0; z-index: 2; background: #101a28; touch-action: none; }
:root[data-theme="light"] .pro { background: #dfe7ef; }
.pro canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
#lc { cursor: grab; touch-action: none; }
#lc:active { cursor: grabbing; }
.map-ui { position: absolute; inset: 0; pointer-events: none; }
.map-ui > * { pointer-events: auto; }
.readout { position: absolute; left: 0; top: 0; padding: 3px 9px; border-radius: 9px; background: var(--sheet); font-weight: 800; font-size: 13.5px; pointer-events: none; z-index: 5; box-shadow: 0 4px 14px rgba(0, 10, 30, .3); }
.map-state { position: absolute; left: 50%; top: 42%; transform: translateX(-50%); padding: 12px 18px; border-radius: 16px; background: var(--sheet); font-weight: 700; text-align: center; max-width: 86vw; }
.m-layers { position: absolute; right: 12px; top: calc(66px + env(safe-area-inset-top)); display: flex; flex-direction: column; gap: 5px; max-height: calc(100dvh - 240px); overflow-y: auto; scrollbar-width: none; }
.m-layer { display: flex; align-items: center; justify-content: flex-end; gap: 7px; min-height: 40px; padding: 4px 11px; border-radius: 13px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); font-weight: 700; transition: background .2s, transform .2s var(--spring); }
.m-layer small { order: -1; color: inherit; font-size: 13px; }
.m-layer span { font-size: 17px; }
.m-layer:hover { transform: translateX(-3px); }
.m-layer.on { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.m-tools { position: absolute; left: 12px; top: calc(66px + env(safe-area-inset-top)); display: flex; flex-direction: column; gap: 6px; }
.m-levels { position: absolute; left: 66px; top: calc(66px + env(safe-area-inset-top)); display: flex; gap: 5px; flex-wrap: wrap; right: 180px; }
.m-levels .chip { background: var(--glass); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); min-height: 34px; padding: 4px 11px; font-size: 13px; }
.m-levels .chip.on { background: var(--accent); }
.m-bottom { position: absolute; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); display: flex; align-items: flex-end; gap: 12px; pointer-events: none; }
.m-bottom > * { pointer-events: auto; }
.m-legend { width: 272px; flex: none; padding: 9px 12px 8px; border-radius: 16px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.lg-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; }
.lg-head b { font-weight: 800; }
.lg-bar { height: 9px; border-radius: 5px; margin-top: 5px; }
.lg-ticks { position: relative; height: 16px; margin: 3px 5px 0; }
.lg-ticks span { position: absolute; transform: translateX(-50%); font-size: 11px; font-weight: 700; white-space: nowrap; }
.lg-note { font-size: 11px; color: var(--text-2); display: flex; align-items: center; gap: 4px; }
.lg-note i { width: 9px; height: 9px; border-radius: 3px; background: #2f76e0; }
.lg-note i.s { background: #8f62e8; margin-left: 7px; }
.m-time { flex: 1; min-width: 0; display: flex; gap: 11px; align-items: center; padding: 9px 13px; border-radius: 18px; }
.play { width: 46px; height: 46px; border-radius: 50%; flex: none; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; transition: transform .2s var(--spring); }
.play:active { transform: scale(.9); }
.play svg { width: 24px; height: 24px; }
.play .fill { fill: currentColor; }
.m-track { flex: 1; min-width: 0; }
.m-when { display: flex; align-items: center; gap: 9px; }
.m-when b { font-weight: 800; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-when small { margin-left: auto; white-space: nowrap; }
.m-when .link { font-size: 13px; }
.m-busy { width: 13px; height: 13px; flex: none; border-radius: 50%; border: 2px solid var(--line); border-top-color: var(--accent); opacity: 0; }
.m-busy.on { opacity: 1; animation: spin .8s linear infinite; }
#tr { --p: 0%; -webkit-appearance: none; appearance: none; width: 100%; height: 26px; background: none; margin: 0; cursor: pointer; touch-action: none; }
#tr::-webkit-slider-runnable-track { height: 6px; border-radius: 6px; background: linear-gradient(90deg, var(--accent) var(--p), var(--line) var(--p)); }
#tr::-moz-range-track { height: 6px; border-radius: 6px; background: linear-gradient(90deg, var(--accent) var(--p), var(--line) var(--p)); }
#tr::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; margin-top: -7px; border-radius: 50%; background: #fff; border: 3px solid var(--accent); box-shadow: 0 2px 7px rgba(0, 10, 30, .35); }
#tr::-moz-range-thumb { width: 15px; height: 15px; border-radius: 50%; background: #fff; border: 3px solid var(--accent); }
.m-days { position: relative; height: 15px; }
.m-days span { position: absolute; font-size: 11.5px; font-weight: 600; color: var(--muted); white-space: nowrap; text-transform: capitalize; }
#pointcard { position: absolute; z-index: 6; right: 12px; bottom: calc(112px + env(safe-area-inset-bottom)); width: 330px; max-width: calc(100vw - 24px); }
.point { position: relative; padding: 15px; animation: rise .35s var(--ease); background: var(--sheet); max-height: calc(100dvh - 240px); overflow-y: auto; }
.point .icon-btn { position: absolute; right: 7px; top: 7px; width: 36px; height: 36px; }
.point h3 { font-size: 18px; font-weight: 800; padding-right: 32px; }
.pt-main { display: flex; align-items: center; gap: 9px; margin: 8px 0; }
.pt-main b { font-size: 34px; font-weight: 300; }
.pt-main span { font-weight: 700; }
.pt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pt-grid small, .pt-grid b { display: block; }
.pt-grid b { font-size: 14px; font-weight: 700; }
.pt-chart { margin-top: 10px; }
.pt-bars { display: flex; align-items: flex-end; gap: 2px; height: 44px; margin-top: 3px; border-bottom: 1px solid var(--line); }
.pt-bars i { flex: 1; background: var(--blue); border-radius: 2px 2px 0 0; min-width: 2px; }
.pt-load { display: grid; justify-items: center; gap: 7px; padding: 14px; font-weight: 600; }
.pt-load svg { width: 70px; }

/* ---------- «Поблагодарить разработчика» — как в «Финмониторинге» ---------- */
.thanks-btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 46px; margin-top: 14px; padding: 9px 14px; border-radius: 14px; border: 1.5px solid color-mix(in srgb, #e5484d 50%, var(--line)); background: color-mix(in srgb, #e5484d 12%, var(--surface-solid)); color: #e5484d; font-weight: 700; font-size: 15px; transition: transform .2s var(--spring); }
:root[data-theme="dark"] .thanks-btn { color: #ff8589; }
.thanks-btn:hover { transform: translateY(-1px); }
.thanks-btn:active { transform: scale(.98); }
.ic-heart { width: 20px; height: 20px; fill: currentColor; flex: none; }
.thanks-btn .ic-heart { animation: beat 2.4s ease-in-out infinite; }
@keyframes beat { 0%, 60%, 100% { transform: scale(1); } 70% { transform: scale(1.18); } 80% { transform: scale(1); } 90% { transform: scale(1.12); } }
.dev-line { margin: 12px 0 0; text-align: center; font-size: 13.5px; color: var(--muted); text-shadow: var(--halo); }
.dev-line b { color: var(--text); font-weight: 700; }
.sheet .dev-line { text-shadow: none; }
.thanks-hero { display: flex; gap: 14px; align-items: center; margin: -4px 0 16px; }
.thanks-hero p { font-size: 15px; line-height: 1.5; color: var(--text-2); }
.thanks-heart { flex: none; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #ff6b6b, #e5484d); box-shadow: 0 10px 24px rgba(229, 72, 77, .35); animation: pop .6s var(--spring) both; }
.thanks-heart .ic-heart { width: 28px; height: 28px; }
.pay-card { border-radius: 20px; padding: 16px; margin-bottom: 14px; animation: rise .5s var(--ease) both; }
.pay-usdt { animation-delay: 80ms; background: var(--surface-2); border: 1.5px solid var(--line); text-align: center; }
.pay-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.pay-top b { font-size: 17px; }
.pay-top span { font-size: 13px; font-weight: 600; opacity: .85; }
.pay-mono { color: #fff; background: linear-gradient(135deg, #1b1b1f 0%, #3a3a44 100%); }
.pay-num { font-size: 24px; font-weight: 700; letter-spacing: .06em; font-variant-numeric: tabular-nums; margin: 4px 0 16px; white-space: nowrap; }
.pay-usdt .pay-top { text-align: left; }
.pay-qr { display: block; width: 212px; height: 212px; margin: 2px auto 12px; padding: 8px; border-radius: 14px; background: #fff; image-rendering: pixelated; }
.pay-addr { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 15px; font-weight: 600; line-height: 1.45; word-break: break-all; margin-bottom: 14px; }
.pay-copy { width: 100%; font-weight: 700; border: 0; }
.pay-copy svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.pay-mono .pay-copy { background: #fff; color: #17171c; }
.pay-usdt .pay-copy { background: #0b7a5f; color: #fff; }
.pay-copy.copied { background: var(--good) !important; color: #fff !important; }
.pay-warn { margin: 12px 2px 0; font-size: 13px; line-height: 1.45; color: var(--muted); text-align: left; }

/* ---------- телефон ---------- */
@media (max-width: 900px) {
  .ob-stage { grid-template-columns: 1fr; gap: 14px; align-items: start; align-content: center; padding: 10px 0; }
  .ob-char { flex-direction: row; align-items: center; gap: 12px; }
  .ob-char .mascot { width: 92px; }
  .ob-say { min-height: 4.300em; font-size: 17.5px; flex: 1; display: flex; align-items: center; }
  .m-legend { position: absolute; left: 0; bottom: 142px; width: 226px; padding: 6px 9px 4px; }
  #pointcard { bottom: calc(150px + env(safe-area-inset-bottom)); }
  .m-layers { left: 12px; right: 12px; top: auto; bottom: calc(102px + env(safe-area-inset-bottom)); flex-direction: row; max-height: none; overflow-x: auto; overflow-y: hidden; }
  .m-layer { flex: none; min-height: 36px; padding: 3px 10px; }
  .m-layer:hover { transform: none; }
  .m-levels { right: 12px; }
  .m-bottom { align-items: stretch; }
  .m-when small { display: none; }
}
@media (max-width: 720px) {
  .hero { grid-template-columns: 1fr; min-height: auto; padding-top: 12px; }
  .buddy { margin-top: 2px; }
  .buddy .mascot { width: 62px; }
  .metrics { grid-template-columns: 1fr 1fr; gap: 9px; }
  .metric.wide { grid-column: span 2; }
  .metric { padding: 13px; }
  .big { font-size: 28px; }
  .wind-row { gap: 9px; }
  .compass { width: 52px; height: 52px; }
  .compass i { width: 28px; height: 28px; }
  .day summary { grid-template-columns: minmax(70px, 1fr) 34px minmax(112px, 2fr) 16px; gap: 5px; }
  .d-pp { display: none; }
  .d-ic .wi { width: 32px; height: 32px; }
  .d-range { gap: 4px; }
  .d-range b { width: 36px; font-size: 14.5px; }
  .place-name { max-width: 28vw; }
  .place-btn { font-size: 15px; padding: 6px 7px; }
  .seg button { padding: 7px 10px; font-size: 13px; }
  .top { gap: 5px; }
  .elements { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 380px) { .pay-num { font-size: 20px; } .thanks-hero { align-items: flex-start; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Ключ восстановления */
.sheet-note { margin: 0 0 12px; font-size: 14px; opacity: .85; }
.rkey { margin-bottom: 12px; }
.rkey code { display: block; margin-bottom: 10px; padding: 14px 8px; border-radius: 14px; background: var(--glass-2); border: 1.5px dashed var(--line); font: 800 clamp(16px, 4.6vw, 21px)/1.3 ui-monospace, Consolas, monospace; letter-spacing: .04em; text-align: center; user-select: all; -webkit-user-select: all; }
.rkey-input { font-family: ui-monospace, Consolas, monospace; letter-spacing: .04em; }
