/* Кампания «След „Полярной“» (js/story, update/37_STORY_TECH.md): комикс во весь экран, живые эффекты кадра, мини-игры,
   журнал, полоса главы на «Рыбалке», карточка в «Заданиях». Двигается только transform и opacity (память
   miniapp-performance): туман, рябь, лучи — заранее нарисованные слои; без backdrop-filter и смешивания. Пока комикс
   или мини-игра открыты, всё под ними не рисуется (body.in-cine — cine.css). Текст переносится, а не обрезается. */

@keyframes scIn { from { opacity: 0; } }
@keyframes scOut { to { opacity: 0; } }

/* ── комикс ─────────────────────────────────────────────── */
.sc-wrap { position: fixed; inset: 0; z-index: 125; background: #030707; overflow: hidden; color: #F6F3EC; font-family: var(--f-text);
  -webkit-user-select: none; user-select: none; touch-action: manipulation; animation: scIn .3s ease-out both; }
.sc-wrap *, .sc-wrap *::before, .sc-wrap *::after { box-sizing: border-box; }
.sc-wrap.out { animation: scOut .28s ease-in both; }
.sc-panels { position: absolute; inset: 0; }
.sc-panel { position: absolute; inset: 0; opacity: 0; transition: opacity .55s ease; }
.sc-panel.in { opacity: 1; }
.sc-panel.leave { opacity: 0; }
.sc-art { position: absolute; left: var(--art-l, 0); top: var(--art-t, 0); width: var(--art-w, 100%); height: var(--art-h, 100%); overflow: hidden; }
.sc-cam { position: absolute; inset: 0; transform-origin: 50% 42%; }
.sc-panel.in .sc-cam { animation: scSettle 1.4s cubic-bezier(.2, .8, .3, 1) both; }
.sc-panel.in .sc-cam.push { animation: scPush 18s ease-out both; }
@keyframes scSettle { from { transform: scale(1.04); } to { transform: scale(1); } }
@keyframes scPush { from { transform: scale(1); } to { transform: scale(1.08); } }
.sc-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; max-width: none; }
.sc-panel.past .sc-img { filter: sepia(.35) contrast(1.04); }
.sc-fx { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.sc-shade { position: absolute; left: 0; right: 0; pointer-events: none; z-index: 2; }
.sc-shade.top { top: 0; height: calc(var(--safe-top) + 120px); background: linear-gradient(180deg, rgba(3, 7, 7, .8), rgba(3, 7, 7, 0)); }
.sc-shade.low { bottom: 0; height: 62%; background: linear-gradient(180deg, rgba(3, 7, 7, 0) 0%, rgba(3, 7, 7, .5) 34%, rgba(3, 7, 7, .88) 66%, rgba(3, 7, 7, .96) 100%); }
.sc-top { position: absolute; left: 0; right: 0; top: 0; z-index: 4; padding: calc(var(--safe-top) + 12px) 14px 0; display: flex; align-items: center; gap: 10px; }
.sc-x, .sg-x { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 0; padding: 0; display: grid; place-items: center;
  color: #F6F3EC; background: rgba(255, 255, 255, .13); }
.sc-x svg, .sg-x svg { width: 16px; height: 16px; }
.sc-ttl { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.sc-ttl small { font-size: 14px; line-height: 1.1; color: var(--accent); }
.sc-ttl b { font-size: 22px; line-height: 1.05; text-shadow: 0 2px 10px rgba(0, 0, 0, .6); overflow-wrap: anywhere; }
.sc-dots { flex: none; display: flex; gap: 4px; }
.sc-dots i { width: 14px; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, .25); transition: background .3s; }
.sc-dots i.on { background: var(--accent); }
.sc-year { position: absolute; right: 16px; top: calc(var(--safe-top) + 64px); z-index: 3; padding: 2px 11px; border-radius: 8px; font-size: 24px;
  color: #3A2A12; background: rgba(243, 226, 190, .94); transform: rotate(3deg); box-shadow: 0 6px 14px rgba(0, 0, 0, .45); }
.sc-low { position: absolute; left: 14px; right: 14px; bottom: calc(var(--safe-bottom) + 14px); z-index: 4; display: flex; flex-direction: column; gap: 10px; }
.sc-beats { display: flex; flex-direction: column; gap: 9px; }
.sc-cap { position: relative; padding: 12px 14px 13px; border-radius: 6px; font-size: 16.5px; line-height: 1.38; color: #2B2112;
  background: #EFE3C6; box-shadow: 0 10px 24px rgba(0, 0, 0, .5); overflow-wrap: anywhere;
  opacity: 0; transform: translateY(10px); transition: opacity .35s ease, transform .4s cubic-bezier(.2, .8, .3, 1); }
.sc-cap::before { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(43, 33, 18, .22); border-radius: 3px; pointer-events: none; }
.sc-beats.past .sc-cap { background: #E8D3A6; font-style: italic; }
.sc-say { display: flex; align-items: flex-end; gap: 9px; opacity: 0; transform: translateY(10px);
  transition: opacity .3s ease, transform .4s cubic-bezier(.2, .8, .3, 1); }
.sc-cap.in, .sc-say.in { opacity: 1; transform: none; }
.sc-say.gone { opacity: 0; transform: translateY(-8px); }
.sc-face { flex: none; width: 50px; height: 50px; border-radius: 50%; overflow: hidden; background: #0B1719; border: 2.5px solid var(--accent);
  box-shadow: 0 6px 14px rgba(0, 0, 0, .5); }
.sc-face img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; display: block; }
.sc-bub { position: relative; min-width: 0; padding: 9px 13px 10px; border-radius: 18px; font-size: 16.5px; line-height: 1.34; color: #161616;
  background: #fff; box-shadow: 0 10px 24px rgba(0, 0, 0, .45); overflow-wrap: anywhere; }
.sc-bub b { display: block; margin-bottom: 1px; font-size: 15px; line-height: 1.15; color: #8A5A12; }
.sc-bub::before { content: ""; position: absolute; left: -6px; bottom: 14px; width: 13px; height: 13px; background: inherit; transform: rotate(45deg); }
.sc-say.you { justify-content: flex-end; }
.sc-say.you .sc-bub { max-width: 84%; color: #1F1A0E; background: var(--accent); }
.sc-say.you .sc-bub b { color: #5B3D0A; }
.sc-say.you .sc-bub::before { left: auto; right: -6px; }
.sc-tx.typing::after { content: ""; display: inline-block; width: .45em; height: 1em; margin-left: 2px; vertical-align: -.15em; background: currentColor; opacity: .45; }
.sc-foot { min-height: 30px; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .3s; }
.sc-foot.on { opacity: 1; }
.sc-hint { font-size: 13.5px; color: rgba(246, 243, 236, .76); text-align: center; }
.sc-hint b { color: var(--accent); }
.sc-go, .sg-btn { width: 100%; height: 56px; border: 0; border-radius: 18px; display: flex; align-items: center; justify-content: center; gap: 7px;
  font-size: 22px; color: #1F1A0E; box-shadow: 0 10px 28px rgba(0, 0, 0, .45);
  background: var(--accent) radial-gradient(circle at 34% 22%, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 52%); }
.sc-go svg, .sg-btn svg { width: 19px; height: 19px; flex: none; }
@media (max-height: 680px) {
  .sc-cap, .sc-bub { font-size: 15.5px; }
  .sc-face { width: 42px; height: 42px; }
  .sc-ttl b { font-size: 20px; }
}

/* ── эффекты кадра (fx.js) ───────────────────────────────── */
.sx-fog { position: absolute; left: -40%; width: 180%; height: auto; max-width: none; opacity: .5; animation: sxFog1 16s ease-in-out infinite alternate; }
.sx-fog.f2 { opacity: .42; animation: sxFog2 21s ease-in-out infinite alternate; }
@keyframes sxFog1 { from { transform: translateX(-11%); } to { transform: translateX(9%); } }
@keyframes sxFog2 { from { transform: translateX(10%) scaleX(-1); } to { transform: translateX(-10%) scaleX(-1); } }
.sx-fogsoft { position: absolute; inset: -10%; animation: sxFog1 16s ease-in-out infinite alternate;
  background: radial-gradient(60% 30% at 30% 40%, rgba(220, 230, 230, .24), rgba(220, 230, 230, 0) 70%),
              radial-gradient(50% 25% at 70% 62%, rgba(220, 230, 230, .2), rgba(220, 230, 230, 0) 70%); }
.sx-water { position: absolute; left: 0; right: 0; bottom: 0; overflow: hidden; animation: sxShimmer 4.6s ease-in-out infinite alternate;
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0), #000 22%); mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0), #000 22%); }
.sx-water.band { -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0), #000 22%, #000 78%, rgba(0, 0, 0, 0));
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0), #000 22%, #000 78%, rgba(0, 0, 0, 0)); }
.sx-water > i { position: absolute; top: 0; bottom: 0; left: -92px; right: -92px; animation: sxWater 6s linear infinite;
  background: radial-gradient(ellipse 15px 2px at 50% 50%, rgba(255, 250, 235, .42), rgba(255, 250, 235, 0) 70%) 0 0 / 46px 13px; }
.sx-water > i.w2 { animation: sxWater2 10s linear infinite; opacity: .6;
  background: radial-gradient(ellipse 22px 2.5px at 50% 50%, rgba(255, 245, 225, .36), rgba(255, 245, 225, 0) 70%) 0 0 / 70px 19px; }
@keyframes sxWater { from { transform: translateX(0); } to { transform: translateX(46px); } }
@keyframes sxWater2 { from { transform: translateX(0); } to { transform: translateX(-70px); } }
@keyframes sxShimmer { from { opacity: .55; } to { opacity: 1; } }
.sx-glint { position: absolute; width: 54px; height: 54px; margin: -27px 0 0 -27px; opacity: 0; animation: sxGlint 2.8s ease-in-out infinite;
  background: radial-gradient(circle, rgba(255, 250, 228, .95) 0, rgba(255, 238, 196, .45) 14%, rgba(255, 238, 196, 0) 44%),
              linear-gradient(90deg, rgba(255, 245, 215, 0) 47%, rgba(255, 245, 215, .85) 50%, rgba(255, 245, 215, 0) 53%),
              linear-gradient(0deg, rgba(255, 245, 215, 0) 47%, rgba(255, 245, 215, .85) 50%, rgba(255, 245, 215, 0) 53%); }
@keyframes sxGlint { 0%, 55%, 100% { opacity: 0; transform: scale(.4) rotate(0deg); } 70% { opacity: 1; transform: scale(1) rotate(25deg); } 85% { opacity: 0; transform: scale(.7) rotate(45deg); } }
.sx-lamp { position: absolute; width: 64%; aspect-ratio: 1; margin: -32% 0 0 -32%; animation: sxLamp 3.4s ease-in-out infinite alternate;
  background: radial-gradient(circle, rgba(255, 196, 120, .42), rgba(255, 180, 90, .12) 40%, rgba(255, 180, 90, 0) 70%); }
@keyframes sxLamp { from { opacity: .55; transform: scale(.97); } to { opacity: 1; transform: scale(1.03); } }
.sx-rays { position: absolute; width: 190%; aspect-ratio: 1; margin: -95% 0 0 -95%; opacity: .75; animation: sxRays 60s linear infinite;
  background: repeating-conic-gradient(from 0deg, rgba(255, 236, 190, .15) 0deg 4deg, rgba(255, 236, 190, 0) 4deg 13deg);
  -webkit-mask-image: radial-gradient(circle, #000 0, rgba(0, 0, 0, 0) 58%); mask-image: radial-gradient(circle, #000 0, rgba(0, 0, 0, 0) 58%); }
@keyframes sxRays { to { transform: rotate(360deg); } }
.sx-dust { position: absolute; width: 4px; height: 4px; border-radius: 50%; opacity: 0; animation: sxDust 9s linear infinite;
  background: rgba(255, 240, 210, .85); box-shadow: 0 0 6px rgba(255, 228, 180, .8); }
@keyframes sxDust { 0% { opacity: 0; transform: translate(0, 0); } 15% { opacity: .9; } 80% { opacity: .7; } 100% { opacity: 0; transform: translate(18px, -130px); } }
.sx-smoke { position: absolute; width: 36%; aspect-ratio: 1; margin: -18% 0 0 -18%; border-radius: 50%; opacity: 0; animation: sxSmoke 7.2s ease-out infinite;
  background: radial-gradient(circle, rgba(210, 210, 205, .34), rgba(210, 210, 205, 0) 65%); }
@keyframes sxSmoke { 0% { opacity: 0; transform: translateY(0) scale(.5); } 25% { opacity: .85; } 100% { opacity: 0; transform: translateY(-75%) translateX(12%) scale(1.8); } }
.sx-grain { position: absolute; inset: -60px; background-repeat: repeat; background-size: 256px 256px; opacity: .22; animation: cnGrain .48s steps(1) infinite; }
.sx-scratch { position: absolute; top: -5%; bottom: -5%; left: 30%; width: 1.5px; opacity: 0; background: rgba(255, 245, 220, .38); animation: sxScratch 2.3s steps(1) infinite; }
.sx-scratch.s2 { left: 71%; animation-duration: 3.1s; animation-delay: -1.2s; }
@keyframes sxScratch { 0% { opacity: .7; transform: translateX(0); } 12% { opacity: 0; } 40% { opacity: .5; transform: translateX(-38px); } 52% { opacity: 0; } 78% { opacity: .6; transform: translateX(24px); } 86% { opacity: 0; } }
.sx-flicker { position: absolute; inset: 0; background: rgba(24, 14, 4, .2); animation: sxFlicker 3.3s steps(1) infinite; }
@keyframes sxFlicker { 0% { opacity: .2; } 20% { opacity: .55; } 24% { opacity: .15; } 61% { opacity: .4; } 64% { opacity: .1; } 90% { opacity: .35; } }
.sx-snow, .sx-rain { position: absolute; left: 0; right: 0; top: -320px; height: calc(100% + 320px); }
.sx-snow { animation: sxFall 14s linear infinite;
  background: radial-gradient(circle 2px at 20px 30px, rgba(255, 255, 255, .85), rgba(255, 255, 255, 0)) 0 0 / 80px 80px,
              radial-gradient(circle 1.5px at 60px 70px, rgba(255, 255, 255, .7), rgba(255, 255, 255, 0)) 0 0 / 110px 110px; }
.sx-snow.s2 { animation-duration: 22s; opacity: .7; }
.sx-rain { animation: sxFall 1.1s linear infinite;
  background: linear-gradient(170deg, rgba(220, 235, 245, 0) 45%, rgba(220, 235, 245, .32) 50%, rgba(220, 235, 245, 0) 55%) 0 0 / 26px 64px; }
@keyframes sxFall { from { transform: translateY(0); } to { transform: translateY(320px); } }
.sx-spark { position: absolute; width: 3px; height: 3px; border-radius: 50%; opacity: 0; background: #FFD08A; box-shadow: 0 0 6px #FFB050; animation: sxSpark 3.5s ease-out infinite; }
@keyframes sxSpark { 0% { opacity: 0; transform: translate(0, 0); } 10% { opacity: 1; } 100% { opacity: 0; transform: translate(14px, -160px); } }
@keyframes sxFlash { 0% { opacity: 0; } 15% { opacity: .85; } 100% { opacity: 0; } }

/* ── мини-игры (games.js) ────────────────────────────────── */
.sg-wrap { position: fixed; inset: 0; z-index: 126; background: #030707; overflow: hidden; color: #F6F3EC; font-family: var(--f-text);
  -webkit-user-select: none; user-select: none; animation: scIn .3s ease-out both; }
.sg-wrap *, .sg-wrap *::before, .sg-wrap *::after { box-sizing: border-box; }
.sg-wrap.out { animation: scOut .26s ease-in both; }
.sg-body { position: absolute; inset: 0; touch-action: none; }
.sg-top { position: absolute; left: 0; right: 0; top: 0; z-index: 5; padding: calc(var(--safe-top) + 12px) 14px 30px; display: flex; align-items: flex-start; gap: 10px;
  background: linear-gradient(180deg, rgba(3, 7, 7, .88), rgba(3, 7, 7, 0)); pointer-events: none; }
.sg-top > * { pointer-events: auto; }
.sg-ttl { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding-top: 2px; }
.sg-ttl b { font-size: 26px; line-height: 1.02; overflow-wrap: anywhere; }
.sg-ttl small { font-size: 14px; line-height: 1.32; color: rgba(246, 243, 236, .82); }
.sg-low { position: absolute; left: 14px; right: 14px; bottom: calc(var(--safe-bottom) + 16px); z-index: 5; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.sg-hint { font-size: 14px; text-align: center; color: rgba(246, 243, 236, .8); text-shadow: 0 2px 8px rgba(0, 0, 0, .8); }
.sg-hint b { color: var(--accent); }
.sg-btn.ghost { height: 46px; font-size: 18px; color: #F6F3EC; background: rgba(255, 255, 255, .1); border: 1.5px solid rgba(255, 255, 255, .22); box-shadow: none; }
.sg-btn[hidden] { display: none; }

.su-glow { position: absolute; left: 50%; top: 46%; width: 130vmin; aspect-ratio: 1; transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(243, 210, 139, .2), rgba(243, 210, 139, 0) 60%); }
/* картинка поплавка вертикальная (≈ 2:5) — размер задаём высотой, иначе на узком экране он вылезает за край */
.su-item { position: absolute; left: 50%; top: 46%; height: min(48vh, 340px); transform: translate(-50%, -50%) rotate(-24deg); }
.su-item img { display: block; height: 100%; width: auto; max-width: none; }
.su-dial { position: absolute; left: 50%; top: 46%; width: min(64vw, 270px, 40vh); aspect-ratio: 1; transform: translate(-50%, -50%);
  transition: opacity .4s, transform .6s cubic-bezier(.2, .8, .3, 1); }
.su-dial svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.su-dial circle { fill: none; stroke-width: 6; }
.su-dial .bg { stroke: rgba(255, 255, 255, .16); }
.su-dial .fg { stroke: var(--accent); stroke-linecap: round; }
.su-cap { position: absolute; inset: 20%; border-radius: 50%; border: 2px dashed rgba(243, 210, 139, .6);
  background: repeating-conic-gradient(rgba(255, 230, 170, 0) 0deg 6deg, rgba(255, 230, 170, .16) 6deg 12deg); }
.su-cap i { position: absolute; left: 50%; top: 3%; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.su-note { position: absolute; left: 50%; top: 46%; width: min(42vw, 180px); opacity: 0; transform: translate(-50%, -50%) scale(.2);
  transition: transform .9s var(--spring), opacity .45s; }
.su-note img { display: block; width: 100%; }
.sg-unscrew.won .su-dial { opacity: 0; transform: translate(-50%, -80%) scale(.8); }
.sg-unscrew.won .su-note { opacity: 1; transform: translate(-50%, -78%) rotate(-6deg) scale(1); }

/* рамка 2:3, как старый снимок: он нарисован под среднюю вертикальную полосу вида места (cover в рамке 2:3 даёт ровно её).
   В квадратной рамке и с увеличением ×1,06 снимок не совпадал с берегом даже в правильном месте (владелец, 08.10) */
.sp-frame { position: absolute; left: 50%; top: 47%; width: min(84vw, 40vh, 360px); aspect-ratio: 2 / 3; transform: translate(-50%, -50%); overflow: hidden;
  border-radius: 18px; touch-action: none; box-shadow: 0 18px 44px rgba(0, 0, 0, .6), 0 0 0 1.5px rgba(243, 210, 139, .4); }
.sp-now, .sp-old { position: absolute; inset: 0; background-size: cover; background-position: center; }
.sp-old { opacity: .58; filter: sepia(.6); }
.sp-tag { position: absolute; top: 10px; padding: 2px 9px; border-radius: 7px; font-size: 15px; z-index: 2; }
.sp-tag.now { top: auto; bottom: 10px; right: 10px; color: #F6F3EC; background: rgba(3, 7, 7, .62); }
.sp-tag.now.left { right: auto; left: 10px; }
.sp-tag.old { left: 10px; color: #3A2A12; background: rgba(243, 226, 190, .94); }
.sp-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; z-index: 3; }
.sg-photo.won .sp-flash { animation: sxFlash .8s ease-out; }
.sg-photo.won .sp-old { opacity: .9; }

.sd-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.sd-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(3, 7, 7, .1), rgba(3, 7, 7, .35)); }
.sd-ring { position: absolute; left: 0; top: 0; width: 100px; height: 100px; margin: -50px 0 0 -50px; pointer-events: none; z-index: 2; }
.sd-coil { position: absolute; inset: 20px; border-radius: 50%; border: 5px solid rgba(240, 240, 235, .92);
  box-shadow: 0 0 0 3px rgba(0, 0, 0, .35), inset 0 0 0 3px rgba(0, 0, 0, .25); transition: border-color .2s; }
.sd-ring.hot .sd-coil { border-color: var(--accent); }
.sd-ring.hot::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: radial-gradient(circle, rgba(243, 210, 139, .45), rgba(243, 210, 139, 0) 70%); }
.sd-wave { position: absolute; inset: 20px; border-radius: 50%; border: 2px solid rgba(169, 228, 208, .85); opacity: 0; }
.sd-ring.ping .sd-wave { animation: sdPing .6s ease-out; }
.sd-ring.ping .sd-wave.w2 { animation-delay: .12s; }
@keyframes sdPing { from { opacity: .9; transform: scale(1); } to { opacity: 0; transform: scale(2.1); } }
.sd-arrow { position: absolute; left: 0; top: 0; width: 46px; height: 46px; margin: -23px 0 0 -23px; color: var(--accent); opacity: 0; pointer-events: none; z-index: 2;
  transition: opacity .3s; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .7)); }
.sd-arrow.on { opacity: 1; }
.sd-arrow svg { width: 100%; height: 100%; }
.sd-found { position: absolute; left: 0; top: 0; width: 140px; margin: -70px 0 0 -70px; opacity: 0; z-index: 3; transform: var(--at, translate(50vw, 75vh)) scale(.3);
  transition: transform .9s var(--spring), opacity .4s; }
.sd-found img { display: block; width: 100%; }
.sg-detector.won .sd-found { opacity: 1; transform: var(--at, translate(50vw, 75vh)) translateY(-110px) scale(1); }
.sd-dirt { position: absolute; left: 0; top: 0; width: 160px; height: 160px; margin: -80px 0 0 -80px; border-radius: 50%; opacity: 0; z-index: 2;
  transform: var(--at, translate(50vw, 75vh)) scale(.3); background: radial-gradient(circle, rgba(90, 64, 36, .85), rgba(90, 64, 36, 0) 65%); }
.sg-detector.won .sd-dirt { animation: sdDirt .9s ease-out both; }
@keyframes sdDirt { 0% { opacity: 0; } 25% { opacity: 1; } 100% { opacity: 0; } }
.sd-meter { width: 100%; display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: rgba(246, 243, 236, .85); text-shadow: 0 2px 8px rgba(0, 0, 0, .8); }
.sd-meter i { flex: 1; height: 10px; border-radius: 5px; overflow: hidden; background: rgba(255, 255, 255, .16); }
.sd-meter b { display: block; height: 100%; transform-origin: 0 50%; transform: scaleX(0); transition: transform .15s;
  background: linear-gradient(90deg, var(--aqua), var(--accent)); }
.sg-btn.near { box-shadow: 0 0 26px rgba(243, 210, 139, .85); }

/* ── полоса главы на «Рыбалке» (журнал, как полоса верши .trs) ── */
.sts { position: relative; overflow: hidden; display: flex; align-items: center; gap: 10px; width: 100%; min-height: 74px; margin-top: 14px;
  padding: 8px 10px 8px 8px; border-radius: 22px; text-align: left; color: var(--ink);
  background: linear-gradient(100deg, #1B1A12 0%, #0D1A1D 72%); border: 1.5px solid rgba(243, 210, 139, .55);
  box-shadow: 0 12px 28px rgba(3, 10, 12, .4); transition: transform .18s var(--ease); }
.sts:active { transform: scale(.98); }
.sts-art { flex: none; width: 58px; height: 58px; border-radius: 14px; overflow: hidden; display: grid; place-items: center; color: var(--accent);
  background: rgba(243, 210, 139, .12); }
.sts-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sts-art svg { width: 28px; height: 28px; }
.sts-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.sts-tx small { font-size: 13px; line-height: 1.2; color: var(--accent); overflow-wrap: anywhere; }
.sts-tx b { font-size: 19px; line-height: 1.1; overflow-wrap: anywhere; }
.sts-tx i { font-style: normal; font-size: 12.5px; font-weight: 700; line-height: 1.3; color: rgba(246, 243, 236, .78); overflow-wrap: anywhere; }
.sts-go { flex: none; display: inline-flex; align-items: center; gap: 2px; height: 36px; padding: 0 8px 0 12px; border-radius: 12px; font-size: 16px;
  color: var(--ink); background: rgba(255, 255, 255, .1); }
.sts-go svg { width: 16px; height: 16px; }
.sts.new .sts-go { color: #3A2300; background: linear-gradient(100deg, #FFE6A0, #E8B55C); }
.sts.new::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0;
  box-shadow: inset 0 0 0 2px rgba(255, 230, 160, .55), 0 0 22px rgba(243, 210, 139, .45); animation: trsGlow 1.8s ease-in-out 6 alternate; }

/* ── карточка «Журнал рыбака» в «Заданиях» (как Путёвка .tk-pass) ── */
.tk-story { margin-top: 10px; width: 100%; min-height: 64px; border-radius: 20px; display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; align-items: center;
  gap: 12px; padding: 12px 14px; text-align: left; color: var(--ink); border: 1.5px solid rgba(243, 210, 139, .4); transition: transform .18s var(--ease); }
.tk-story:active { transform: scale(.975); }
.tk-story.ready { border-color: rgba(243, 210, 139, .8); }
.tk-story-ico { display: grid; place-items: center; color: var(--accent); }
.tk-story-ico svg { width: 28px; height: 28px; }
.tk-story-tx { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.tk-story-tx b { font-size: 22px; line-height: 1; overflow-wrap: anywhere; }
.tk-story-tx small { font-size: 12.5px; font-weight: 600; line-height: 1.3; color: rgba(246, 243, 236, .74); white-space: normal; overflow-wrap: anywhere; }
.tk.intro .tk-story { animation: hbRise .55s cubic-bezier(.2, .8, .2, 1) .18s both; }

/* ── журнал (страница journal) ───────────────────────────── */
.sj-now { position: relative; overflow: hidden; margin-top: 14px; padding: 118px 16px 16px; border-radius: 24px; display: flex; flex-direction: column; gap: 6px;
  background: #0B1719 var(--cover) center 32% / cover no-repeat; border: 1.5px solid rgba(243, 210, 139, .5); box-shadow: 0 16px 36px rgba(0, 0, 0, .45); }
.sj-now::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(3, 7, 7, 0) 0%, rgba(3, 7, 7, .55) 34%, rgba(3, 7, 7, .93) 72%); }
.sj-now > * { position: relative; }
.sj-now-k { font-size: 13.5px; line-height: 1.2; color: var(--accent); overflow-wrap: anywhere; }
.sj-now b { font-size: 26px; line-height: 1.05; overflow-wrap: anywhere; }
.sj-now small { font-size: 14px; line-height: 1.38; color: rgba(246, 243, 236, .84); }
.sj-pr { display: flex; align-items: center; gap: 10px; margin-top: 4px; }
.sj-pr .tp-bar { flex: 1; }
.sj-pr em { font-style: normal; font-size: 16px; white-space: nowrap; }
.sj-acts { display: grid; gap: 8px; margin-top: 10px; }
.sj-acts .tp-btn { width: 100%; }
.sj-done, .sj-lock { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; }
.sj-done { color: #0B1719; background: var(--green, #9FE3B6); }
.sj-lock { color: rgba(246, 243, 236, .6); background: rgba(255, 255, 255, .08); }
.sj-done svg, .sj-lock svg { width: 16px; height: 16px; }
.sj-ch.locked { opacity: .62; }
.sj-items { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.sj-item { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 6px; padding: 8px 6px 10px;
  border-radius: 16px; color: var(--ink);
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .12); }
/* одна рамка 88 px на все картинки: проценты внутри сетки не держали размер — высокий поплавок растягивал плитку,
   и подписи стояли на разной высоте (владелец, 08.10); подпись — под рамкой, у всех на одной линии */
.sj-item-img { flex: none; width: 100%; height: 88px; display: flex; align-items: center; justify-content: center; overflow: hidden;
  color: var(--accent); }
.sj-item-img img { display: block; width: auto; height: auto; max-width: 92%; max-height: 88px; object-fit: contain; }
.sj-item-img svg { width: 30px; height: 30px; }
.sj-item b { font-size: 14px; line-height: 1.12; text-align: center; overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto; }
/* position: relative — иначе фон окна (.modal-backdrop, absolute) ложится поверх карточки и всё серое (владелец, 08.10) */
.sj-card { position: relative; width: min(360px, calc(100vw - 32px)); padding: 18px; border-radius: 24px; text-align: center; color: var(--ink);
  background: rgba(14, 26, 28, .98); border: 1.5px solid rgba(243, 210, 139, .5); }
.modal-wrap.open .sj-card { animation: cardPop .55s var(--spring) forwards; }
/* картинка предмета — в рамке 170 px: процент внутри сетки не ограничивал, и поплавок закрывал окно (владелец, 08.10) */
.sj-card-img { display: flex; align-items: center; justify-content: center; height: 170px; overflow: hidden; color: var(--accent); }
.sj-card-img img { display: block; width: auto; height: auto; max-height: 170px; max-width: 100%; object-fit: contain; }
.sj-card b { display: block; margin-top: 6px; font-size: 26px; line-height: 1.05; }
.sj-card p { margin: 8px 0 6px; font-size: 15px; line-height: 1.42; color: rgba(246, 243, 236, .86); }
.sj-card small { display: block; margin-bottom: 14px; font-size: 12.5px; line-height: 1.35; color: rgba(246, 243, 236, .6); }

/* ── задания торговца на его странице (как в Таркове, владелец 08.10): доверие, основное задание, «Подработка» ниже ── */
.tq { margin-top: 6px; }
.tq-none { margin-top: 18px; }
.tq-trust { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; padding: 12px 14px; border-radius: 18px;
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1); }
.tq-trust-k { display: flex; align-items: center; gap: 6px; font-size: 18px; line-height: 1.1; color: var(--accent); overflow-wrap: anywhere; }
.tq-trust-k svg { width: 16px; height: 16px; flex: none; }
.tq-trust small { font-size: 12.5px; line-height: 1.4; color: rgba(246, 243, 236, .7); }
.tq-card { position: relative; display: flex; flex-direction: column; gap: 6px; margin-top: 10px; padding: 14px 16px 16px; border-radius: 22px;
  background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .13); }
.tq-card.active { border-color: rgba(243, 210, 139, .5); background: linear-gradient(160deg, rgba(243, 210, 139, .14), rgba(255, 255, 255, .04)); }
.tq-card.offer { border-color: rgba(243, 210, 139, .7); background: linear-gradient(160deg, rgba(243, 210, 139, .22), rgba(255, 255, 255, .05)); }
.tq-k { font-size: 13.5px; line-height: 1.2; color: var(--accent); overflow-wrap: anywhere; }
.tq-card > b { font-size: 25px; line-height: 1.05; overflow-wrap: anywhere; }
.tq-steps { display: flex; flex-direction: column; gap: 6px; margin: 4px 0 0; padding: 0; list-style: none; }
.tq-steps li { display: flex; align-items: flex-start; gap: 9px; font-size: 14px; line-height: 1.35; color: rgba(246, 243, 236, .62); }
.tq-steps li i { flex: none; display: grid; place-items: center; width: 20px; height: 20px; margin-top: 0; border-radius: 50%;
  border: 1.5px solid rgba(246, 243, 236, .35); }
.tq-steps li i svg { width: 12px; height: 12px; }
.tq-steps li.done { color: rgba(246, 243, 236, .55); }
.tq-steps li.done span { text-decoration: line-through; text-decoration-color: rgba(246, 243, 236, .35); }
.tq-steps li.done i { color: #0B1719; background: var(--green); border-color: var(--green); }
.tq-steps li.now { color: var(--ink); font-weight: 700; }
.tq-steps li.now i { border-color: var(--accent); box-shadow: inset 0 0 0 4px rgba(243, 210, 139, .9); }
.tq-hint { font-size: 13px; line-height: 1.4; color: rgba(246, 243, 236, .72); }
.tq-say { margin: 2px 0 0; font-size: 15px; line-height: 1.42; font-style: italic; color: rgba(246, 243, 236, .9); }
.tq-acts { display: grid; margin-top: 8px; }
.tq-acts .tp-btn { width: 100%; }
.tq .tp-row.tq-row { margin-top: 8px; }
.tq .tp-row.tq-row.locked { opacity: .66; }
/* «!» у торговца в «Гавани»: задание ждёт — как значок над головой в Таркове */
.hb-quest { position: absolute; right: -4px; top: -3px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  font-size: 17px; line-height: 1; color: #2A1A00; background: linear-gradient(160deg, #FFE6A0, #E8B55C); border: 2px solid #12262A; }
/* условия следующей ступени доверия: уровень, очки, оборот */
.tq-conds { display: flex; flex-direction: column; gap: 5px; margin: 2px 0; padding: 0; list-style: none; }
.tq-conds li { display: flex; align-items: center; gap: 8px; font-size: 13.5px; line-height: 1.3; color: rgba(246, 243, 236, .78); }
.tq-conds li i { flex: none; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%;
  border: 1.5px solid rgba(246, 243, 236, .35); }
.tq-conds li i svg { width: 11px; height: 11px; }
.tq-conds li span { flex: 1; min-width: 0; }
.tq-conds li em { flex: none; font-style: normal; font-size: 12.5px; color: rgba(246, 243, 236, .55); }
.tq-conds li.ok { color: var(--ink); }
.tq-conds li.ok i { color: #0B1719; background: var(--green); border-color: var(--green); }
.tq-conds li.ok em { color: var(--green); }
.tq-trust-note { color: rgba(246, 243, 236, .5) !important; }
/* что открывает доверие — по пункту на строку (journal.js trustHtml) */
.tq-unl { margin: 4px 0 6px; padding-left: 18px; display: grid; gap: 3px; }
.tq-unl li { font-size: 12.5px; line-height: 1.35; color: rgba(246, 243, 236, .78); }
.tq-unl li::marker { color: #f3d28b; }
