/* REZOMA — AI-agents fake-door landing: «сайт-офис»
   Весь сайт — один пиксельный офис на весь экран. Сцена тёплая, интерфейс поверх неё
   яркий и «игровой»: толстые обводки, жёсткие тени, кислотно-жёлтый и коралловый.
   Шрифт — Onest (бренд REZOMA, лицензия OFL). */

@font-face { font-family: Onest; src: url("../fonts/Onest-Variable.ttf") format("truetype"); font-weight: 100 900; font-display: swap; }

:root {
  --ink: #1F3A2B;       /* тёмный лес: обводки и текст */
  --cream: #FFF6E3;     /* бумага */
  --floor: #F3DDB4;
  --yellow: #FFD24A;    /* маркер */
  --coral: #FF6B4A;     /* главная кнопка */
  --coral-dark: #D9472A;
  --mint: #7BD8A4;
  --sage: #DDE6CF;
  --muted: #5F6B58;
  --line: #E2D3B3;

  --font: Onest, system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(.2, 0, 0, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--floor); color: var(--ink); font: 500 17px/1.5 var(--font); -webkit-font-smoothing: antialiased; }
h1, h2, h3 { margin: 0; font-weight: 800; letter-spacing: -.035em; line-height: 1.06; }
p { margin: 0; }
a { color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, textarea { font: inherit; color: inherit; }
img, svg { display: block; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; height: 52px; padding: 0 24px; border-radius: 10px; border: 3px solid var(--ink); font: 800 16px var(--font); letter-spacing: -.01em; text-decoration: none; cursor: pointer; transition: transform .12s var(--ease), box-shadow .12s var(--ease), background .12s var(--ease); }
.btn--primary { background: var(--coral); color: #fff; box-shadow: 0 5px 0 var(--ink); }
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 7px 0 var(--ink); }
.btn--primary:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--ink); }
.btn--ghost { background: var(--cream); color: var(--ink); box-shadow: 0 5px 0 var(--ink); }
.btn--ghost:hover { background: var(--yellow); transform: translateY(-2px); box-shadow: 0 7px 0 var(--ink); }
.btn--ghost:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--ink); }
.btn--sm { height: 44px; padding: 0 18px; font-size: 15px; background: var(--coral); color: #fff; box-shadow: 0 4px 0 var(--ink); }
.btn--sm:hover { transform: translateY(-2px); box-shadow: 0 6px 0 var(--ink); }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .6; pointer-events: none; }

/* ---------- Header ---------- */
.header { position: fixed; inset: 0 0 auto 0; z-index: 60; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; pointer-events: none; }
.header > * { pointer-events: auto; }
.logo { display: inline-flex; align-items: center; gap: 10px; padding: 6px 14px 6px 8px; background: var(--cream); border: 3px solid var(--ink); border-radius: 10px; box-shadow: 0 4px 0 var(--ink); text-decoration: none; }
.logo__mark { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 6px; background: var(--ink); color: var(--yellow); font: 800 16px var(--font); }
.logo__text { font: 800 16px var(--font); letter-spacing: .12em; }

/* =====================================================================
   МИР: офис на весь экран (десктоп)
   ===================================================================== */
body.is-world { overflow: hidden; height: 100dvh; }
.world { position: fixed; inset: 0; overflow: hidden; background: var(--floor); }
/* На сверхшироких мониторах по бокам остаются полосы. Они чёткие, а не размытые: стена и пол тех же цветов,
   что и края картинки (цвета взяты с самой картинки). --sh: высота сцены, когда её ширина упёрлась в предел. */
.world { --sh: 118.125vh; --sh: 118.125dvh; }
.world::before { content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, #F0D6B8 0 calc(var(--sh) * .57), #EAC59F calc(var(--sh) * .57) 100%) left / 50% 100% no-repeat,
    linear-gradient(to bottom, #F5DFC4 0 calc(var(--sh) * .28), #D1AC88 calc(var(--sh) * .28) calc(var(--sh) * .295), #E9C39C calc(var(--sh) * .295) 100%) right / 50% 100% no-repeat; }

/* Сцена «cover»: картинка 16:9 закрывает весь экран, проценты внутри привязаны к картинке */
/* Сцена закрывает весь экран. Она прижата к верху, поэтому вывеска всегда на виду: на широких экранах
   срезается только низ, где панель. Ширина ограничена 210% высоты, чтобы на сверхшироких мониторах не
   срезать сотрудников (там по бокам будет размытый фон). */
/* Центрирование без transform: дробный сдвиг transform размывает картинку и текст. */
.scene { position: absolute; top: 0; left: 0; right: 0; margin-inline: auto; width: min(max(100vw, 177.78vh), 210vh); width: min(max(100vw, 177.78dvh), 210dvh); aspect-ratio: 16 / 9; container-type: inline-size; }
.art { position: absolute; inset: 0; }
.art__img { width: 100%; height: 100%; user-select: none; -webkit-user-drag: none; }

/* Вывеска на стене */
.sign { position: absolute; left: 32.5%; top: 2.2%; width: 33%; padding: 1.3cqw 1.7cqw 1.6cqw; background: var(--cream); border: 3px solid var(--ink); border-radius: 12px; box-shadow: .55cqw .55cqw 0 var(--ink); transform: rotate(-1deg); animation: sign-in .8s var(--ease) both; z-index: 5; }
.sign::before, .sign::after { content: ""; position: absolute; top: -9px; width: 14px; height: 14px; background: var(--yellow); border: 3px solid var(--ink); border-radius: 50%; }
.sign::before { left: 18px; } .sign::after { right: 18px; }
@keyframes sign-in { from { opacity: 0; transform: translateY(-24px) rotate(-4deg); } }
.sign h1 { font-size: 2.9cqw; line-height: 1.04; letter-spacing: -.04em; text-wrap: balance; }
.sign__lead { margin-top: .8cqw; font-size: max(12.5px, .98cqw); line-height: 1.4; color: var(--muted); }
.sign__cta { margin-top: 1cqw; display: flex; flex-wrap: wrap; gap: .8cqw; }
.sign .btn { height: max(40px, 2.8cqw); padding: 0 1.4cqw; font-size: max(14px, .98cqw); }

/* Клиенты (спрайты) */
.art__clients { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.npc { position: absolute; width: 4.2cqw; transform: translate(-50%, -100%); transition: left 2.3s linear, top 2.3s linear, opacity .6s; filter: drop-shadow(.2cqw .25cqw 0 rgba(31, 58, 43, .28)); }
.npc img { width: 100%; height: auto; image-rendering: pixelated; }
.npc img + img { position: absolute; inset: 0; opacity: 0; }
.npc.walk img:first-child { animation: step-a .36s steps(1) infinite; }
.npc.walk img + img { animation: step-b .36s steps(1) infinite; }
@keyframes step-a { 50% { opacity: 0; } }
@keyframes step-b { 50% { opacity: 1; } }
.npc.walk { animation: bob .36s steps(2) infinite; }
@keyframes bob { 50% { margin-top: -.25cqw; } }
.npc.gone { opacity: 0; }
.npc__say { position: absolute; left: 50%; bottom: 112%; transform: translateX(-50%) scale(.6); transform-origin: 50% 100%; width: max-content; max-width: 12cqw; padding: .55cqw .8cqw; background: #fff; border: 2px solid var(--ink); border-radius: 8px; box-shadow: 2px 2px 0 var(--ink); font: 700 max(11px, .86cqw)/1.25 var(--font); opacity: 0; transition: opacity .2s, transform .25s var(--ease); }
.npc__say::after { content: ""; position: absolute; left: 50%; bottom: -7px; width: 10px; height: 10px; background: #fff; border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: translateX(-50%) rotate(45deg); }
.npc.talk .npc__say { opacity: 1; transform: translateX(-50%) scale(1); }

/* Заявка-конверт */
.art__packet { position: absolute; width: 2.5cqw; min-width: 22px; height: auto; transform: translate(-50%, -50%); opacity: 0; transition: left .9s steps(12), top .9s steps(12), opacity .2s; filter: drop-shadow(2px 2px 0 rgba(31, 58, 43, .35)); pointer-events: none; z-index: 3; }
.art__packet.on { opacity: 1; animation: hop 1.2s steps(2) infinite; }
@keyframes hop { 50% { margin-top: -5px; } }

/* Реплика сотрудника */
.art__bubble { position: absolute; width: 17cqw; padding: .8cqw 1cqw; transform: translate(-50%, -100%); background: #fff; border: 3px solid var(--ink); border-radius: 10px; box-shadow: 4px 4px 0 var(--ink); font: 700 max(13px, 1.02cqw)/1.32 var(--font); pointer-events: none; z-index: 4; transition: left .4s var(--ease), top .4s var(--ease); }
.art__bubble::after { content: ""; position: absolute; left: 50%; bottom: -10px; width: 14px; height: 14px; background: #fff; border-right: 3px solid var(--ink); border-bottom: 3px solid var(--ink); transform: translateX(-50%) rotate(45deg); }
.art__bubble.pop { animation: pop .3s var(--ease); }
@keyframes pop { from { opacity: 0; margin-top: 8px; } }

/* Счётчик у менеджера */
.art__counter { position: absolute; left: 88.4%; top: 49%; transform: translate(-50%, -100%); display: flex; align-items: center; gap: .6cqw; padding: .45cqw .9cqw .45cqw .5cqw; background: var(--ink); color: var(--cream); border: 3px solid var(--ink); border-radius: 10px; box-shadow: 0 .3cqw 0 rgba(31, 58, 43, .35); font: 700 max(11px, .86cqw) var(--font); white-space: nowrap; z-index: 3; }
.art__counter-n { display: grid; place-items: center; min-width: 2cqw; height: 2cqw; padding: 0 .4cqw; background: var(--yellow); color: var(--ink); border-radius: 6px; font: 800 max(14px, 1.2cqw) var(--font); }
.art__counter.bump { animation: bump .45s var(--ease); }
@keyframes bump { 40% { transform: translate(-50%, -100%) scale(1.14); } }
.art__toast { position: absolute; left: 88.4%; top: 43%; transform: translate(-50%, -100%) scale(.7); transform-origin: 50% 100%; padding: .55cqw 1cqw; background: var(--mint); border: 3px solid var(--ink); border-radius: 10px; box-shadow: 3px 3px 0 var(--ink); font: 800 max(12px, .96cqw) var(--font); white-space: nowrap; opacity: 0; pointer-events: none; z-index: 4; transition: opacity .2s, transform .3s var(--ease); }
.art__toast.show { opacity: 1; transform: translate(-50%, -100%) scale(1); }

/* Кнопки на сотрудниках и предметах */
.who { position: absolute; left: var(--x); top: min(var(--y), calc(100vh - 64px)); top: min(var(--y), calc(100dvh - 64px)); transform: translateX(-50%); padding: 0; background: none; border: 0; cursor: pointer; z-index: 6; }
.who::before { content: ""; position: absolute; left: 50%; bottom: 100%; width: 7cqw; height: 9cqw; transform: translateX(-50%); }
.who__chip { position: relative; display: inline-flex; align-items: center; gap: .5cqw; padding: .3cqw .8cqw; background: var(--cream); border: 3px solid var(--ink); border-radius: 8px; box-shadow: 0 .28cqw 0 var(--ink); font: 800 max(12px, .95cqw) var(--font); white-space: nowrap; transition: background .12s var(--ease), transform .12s var(--ease); }
.who__chip i { width: .6cqw; height: .6cqw; min-width: 7px; min-height: 7px; background: #B8AE95; border-radius: 50%; }
.who:hover .who__chip { transform: translateY(-3px); background: #fff; }
.who.on .who__chip { background: var(--yellow); }
.who.on .who__chip i { background: var(--coral); animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: .2; } }
.who--prop .who__chip { background: var(--sage); border-style: dashed; }
.who--prop.on .who__chip { background: var(--yellow); border-style: solid; }

/* ---------- Нижняя игровая панель ---------- */
.hud { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; padding: 0 18px 16px; pointer-events: none; }
.hud > * { pointer-events: auto; }
.panel { width: min(410px, 100%); max-height: 44dvh; overflow-y: auto; padding: 20px 24px 22px; background: var(--cream); border: 3px solid var(--ink); border-radius: 14px; box-shadow: 6px 6px 0 var(--ink); animation: panel-in .35s var(--ease); }
@keyframes panel-in { from { opacity: 0; transform: translateY(10px); } }
.panel__h { font-size: 24px; letter-spacing: -.03em; line-height: 1.12; }
.panel__quote { margin-top: 10px; font-size: 18px; font-weight: 650; line-height: 1.38; letter-spacing: -.01em; }
.panel__result { margin-top: 8px; font-size: 15.5px; color: var(--muted); font-weight: 500; }
.panel .btn { margin-top: 16px; height: 46px; font-size: 15px; }
.tags { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { padding: 5px 12px; background: var(--sage); border: 2px solid var(--ink); border-radius: 8px; font-weight: 700; font-size: 14.5px; }
.faq { margin-top: 10px; border-top: 3px solid var(--ink); }
.faq details { border-bottom: 2px solid var(--line); }
.faq summary { position: relative; padding: 12px 34px 12px 0; font: 700 16px var(--font); cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before, .faq summary::after { content: ""; position: absolute; right: 4px; top: 50%; width: 14px; height: 3px; background: var(--ink); transition: transform .2s var(--ease); }
.faq summary::after { transform: rotate(90deg); }
.faq details[open] summary::after { transform: rotate(0); }
.faq details p { padding: 0 0 12px; font-size: 15px; color: var(--muted); font-weight: 500; }
.chg { margin-top: 10px; border-top: 3px solid var(--ink); }
.chg__row { padding: 10px 0; border-bottom: 2px solid var(--line); display: grid; gap: 2px; }
.chg__row b { font-weight: 800; font-size: 15px; }
.chg__old { color: var(--muted); font-size: 14.5px; font-weight: 500; text-decoration: line-through; text-decoration-color: rgba(31, 58, 43, .35); }
.chg__new { font-weight: 700; font-size: 15px; }
.chg__new::before { content: "✓ "; color: #1F9D5B; }

.dock { max-width: 100%; display: flex; align-items: center; gap: 10px; padding: 8px 10px; background: var(--cream); border: 3px solid var(--ink); border-radius: 14px; box-shadow: 0 5px 0 var(--ink); overflow-x: auto; scrollbar-width: none; }
.dock::-webkit-scrollbar { display: none; }
.dock__play { flex: none; height: 40px; padding: 0 14px; background: var(--yellow); border: 3px solid var(--ink); border-radius: 9px; font: 800 14px var(--font); cursor: pointer; white-space: nowrap; transition: transform .12s var(--ease); }
.dock__play:hover { transform: translateY(-2px); }
.dock__list { display: flex; align-items: center; gap: 8px; }
.dock__list li:nth-child(5) { margin-right: 6px; padding-right: 14px; border-right: 3px dashed var(--line); }
.chipbtn { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 13px 0 8px; background: #fff; border: 3px solid var(--ink); border-radius: 9px; font: 800 14.5px var(--font); cursor: pointer; white-space: nowrap; transition: transform .12s var(--ease), background .12s var(--ease); }
.chipbtn:hover { transform: translateY(-2px); background: var(--cream); }
.chipbtn.on { background: var(--yellow); box-shadow: 0 3px 0 var(--ink); }
.chipbtn__n { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 5px; background: var(--ink); color: var(--yellow); font: 800 13px var(--font); }
.chipbtn--prop { background: var(--sage); border-style: dashed; padding-left: 13px; }
.chipbtn--prop.on { background: var(--yellow); border-style: solid; }

/* ---------- Окно заявки ---------- */
.apply-dialog { width: min(520px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); padding: 0; border: 0; background: transparent; color: var(--ink); overflow: visible; }
.apply-dialog::backdrop { background: rgba(31, 58, 43, .72); backdrop-filter: blur(3px); }
.apply-dialog[open] { animation: dlg .3s var(--ease); }
@keyframes dlg { from { opacity: 0; transform: translateY(16px) scale(.97); } }
.apply-dialog__box { position: relative; max-height: calc(100dvh - 24px); overflow-y: auto; padding: 30px 30px 24px; background: var(--cream); border: 3px solid var(--ink); border-radius: 16px; box-shadow: 8px 8px 0 var(--yellow), 8px 8px 0 3px var(--ink); }
.apply-dialog__close { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; background: #fff; border: 3px solid var(--ink); border-radius: 9px; font: 800 24px/1 var(--font); cursor: pointer; transition: background .12s var(--ease); }
.apply-dialog__close:hover { background: var(--yellow); }
.apply-dialog h2 { padding-right: 48px; font-size: 28px; letter-spacing: -.04em; }
.apply-dialog__lead { margin: 10px 0 20px; color: var(--muted); font-size: 16px; font-weight: 500; }

.seg { margin: 0 0 12px; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); border: 3px solid var(--ink); border-radius: 10px; overflow: hidden; background: #fff; }
.seg label { position: relative; cursor: pointer; }
.seg label + label { border-left: 3px solid var(--ink); }
.seg input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.seg span { display: block; padding: 10px 6px; text-align: center; font: 800 15px var(--font); color: var(--muted); transition: background .12s var(--ease), color .12s var(--ease); }
.seg label:hover span { color: var(--ink); }
.seg input:checked + span { background: var(--ink); color: var(--yellow); }
.seg input:focus-visible + span { outline: 3px solid var(--coral); outline-offset: -3px; }

.consent { display: flex; align-items: flex-start; gap: 10px; margin: 2px 0 14px; padding: 10px 12px; border: 2px solid transparent; border-radius: 10px; cursor: pointer; font-size: 14px; line-height: 1.4; font-weight: 500; }
.consent input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--coral); cursor: pointer; }
.consent a { font-weight: 700; text-underline-offset: 3px; }
.consent.invalid { border-color: #D9472A; background: #FFE9E3; }

.field { display: block; margin-bottom: 16px; }
.field > span { display: block; margin-bottom: 6px; font-size: 14.5px; font-weight: 800; }
.field em { font-style: normal; font-weight: 500; color: var(--muted); margin-left: 4px; }
.field input, .field textarea { width: 100%; padding: 0 14px; height: 50px; background: #fff; border: 3px solid var(--ink); border-radius: 10px; font-weight: 500; transition: box-shadow .12s var(--ease), background .12s var(--ease); }
.field textarea { height: auto; padding: 12px 14px; resize: vertical; min-height: 88px; }
.field input::placeholder, .field textarea::placeholder { color: #9AA18F; }
.field input:focus, .field textarea:focus { outline: 0; box-shadow: 0 4px 0 var(--coral); }
.field.invalid input { background: #FFE9E3; box-shadow: 0 4px 0 #D9472A; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.apply-dialog .btn--block { margin-top: 6px; }
.form-error { margin-top: 12px; padding: 10px 14px; font-size: 14.5px; font-weight: 600; color: #8E2630; background: #FFE3E0; border: 2px solid #D9472A; border-radius: 8px; }
.form-note { margin-top: 14px; font-size: 12.5px; line-height: 1.45; color: var(--muted); text-align: center; font-weight: 500; }
.tg-link { margin-top: 14px; display: block; text-align: center; font-weight: 800; text-underline-offset: 4px; }

/* ---------- Страница политики ---------- */
.doc { padding: 96px 16px 56px; }
.doc__box { width: min(760px, 100%); margin: 0 auto; padding: 38px 40px 40px; background: var(--cream); border: 3px solid var(--ink); border-radius: 16px; box-shadow: 8px 8px 0 var(--yellow), 8px 8px 0 3px var(--ink); }
.doc h1 { font-size: clamp(28px, 4.4vw, 38px); }
.doc__date { margin-top: 8px; color: var(--muted); font-size: 14.5px; }
.doc h2 { margin-top: 28px; font-size: 20px; letter-spacing: -.02em; }
.doc p, .doc li { margin-top: 10px; font-size: 16px; line-height: 1.55; font-weight: 500; }
.doc ul { margin-top: 6px; padding-left: 22px; list-style: disc; }
.doc li { margin-top: 6px; }
.doc__missing { background: var(--yellow); padding: 0 4px; border-radius: 4px; }
@media (max-width: 640px) { .doc__box { padding: 26px 20px 28px; box-shadow: 5px 5px 0 var(--yellow), 5px 5px 0 3px var(--ink); } }

/* ---------- Thank-you ---------- */
body:not(.is-world) { background-color: var(--floor); background-image: linear-gradient(rgba(31, 58, 43, .05) 1px, transparent 1px), linear-gradient(90deg, rgba(31, 58, 43, .05) 1px, transparent 1px); background-size: 32px 32px; }
.thanks { position: relative; min-height: 100dvh; display: grid; place-items: center; padding: 96px 0 56px; }
.thanks__card { width: min(560px, 100% - 32px); padding: 46px 38px 40px; text-align: center; background: var(--cream); border: 3px solid var(--ink); border-radius: 16px; box-shadow: 8px 8px 0 var(--yellow), 8px 8px 0 3px var(--ink); }
.check { width: 76px; height: 76px; margin: 0 auto 24px; display: grid; place-items: center; border-radius: 12px; background: var(--mint); border: 3px solid var(--ink); box-shadow: 0 5px 0 var(--ink); animation: stamp .5s var(--ease) both; }
.check svg { width: 38px; height: 38px; fill: none; stroke: var(--ink); stroke-width: 3.4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: tick .5s .3s var(--ease) forwards; }
@keyframes stamp { from { transform: scale(1.6) rotate(-8deg); opacity: 0; } }
@keyframes tick { to { stroke-dashoffset: 0; } }
.thanks h1 { font-size: clamp(30px, 5vw, 42px); }
.thanks p { margin-top: 16px; color: var(--muted); font-weight: 500; }
.thanks__policy { margin-top: 22px; font-size: 13.5px; }
.thanks__policy a { color: var(--muted); text-underline-offset: 3px; }
.thanks__cta { margin-top: 30px; display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }

/* =====================================================================
   Узкие и «высокие» экраны: офис сверху, всё остальное под ним
   ===================================================================== */
/* Невысокие экраны (ноутбуки с масштабом 125-150%): компактнее панель и вывеска */
@media (min-width: 821px) and (max-height: 700px) {
  .header { padding: 8px 12px; }
  .logo { padding: 4px 10px 4px 6px; }
  .logo__mark { width: 26px; height: 26px; }
  .btn--sm { height: 38px; padding: 0 14px; font-size: 14px; }
  .sign__lead { display: none; }
  .hud { padding: 0 12px 10px; gap: 8px; }
  .panel { width: min(360px, 100%); max-height: 38dvh; padding: 12px 16px 14px; }
  .panel__h { font-size: 19px; }
  .panel__quote { font-size: 15.5px; margin-top: 6px; }
  .panel__result { font-size: 13.5px; margin-top: 5px; }
  .panel .btn { height: 40px; margin-top: 10px; font-size: 14px; }
  .dock { padding: 6px 8px; gap: 8px; }
  .dock__play, .chipbtn { height: 34px; font-size: 13px; }
  .chipbtn { padding: 0 10px 0 6px; gap: 6px; }
  .chipbtn__n { width: 20px; height: 20px; font-size: 12px; }
}

@media (max-width: 820px), (max-aspect-ratio: 3/2) {
  body.is-world { overflow: auto; height: auto; }
  .world { position: static; overflow: visible; padding-top: 76px; }
  .world::before { display: none; }
  .header { position: absolute; padding: 12px 14px; }
  .scene { position: static; width: 100%; aspect-ratio: auto; transform: none; }
  .sign { position: static; width: auto; margin: 6px 16px 22px; padding: 22px 20px 22px; transform: none; box-shadow: 6px 6px 0 var(--ink); }
  .sign h1 { font-size: clamp(28px, 8.4vw, 40px); }
  .sign__lead { font-size: 16px; margin-top: 12px; }
  .sign__cta { margin-top: 18px; gap: 12px; }
  .sign .btn { width: 100%; height: 52px; padding: 0 20px; font-size: 16px; }
  .art { position: relative; inset: auto; aspect-ratio: 16 / 9; border-top: 3px solid var(--ink); border-bottom: 3px solid var(--ink); overflow: hidden; }
  .art__bubble, .art__toast, .who__chip { display: none; }
  .who { width: 15%; height: 20%; margin-top: -22%; }
  .who::before { display: none; }
  .art__counter { font-size: 9px; gap: 4px; padding: 3px 6px 3px 3px; border-width: 2px; top: 52%; }
  .art__counter span:last-child { display: none; }
  .art__counter-n { min-width: 16px; height: 16px; font-size: 11px; }
  .npc__say { font-size: 9px; max-width: 26cqw; padding: 3px 5px; }
  .hud { position: static; padding: 18px 16px 28px; pointer-events: auto; background: var(--floor); }
  .panel { width: 100%; max-height: none; box-shadow: 5px 5px 0 var(--ink); padding: 18px 18px 20px; }
  .dock { flex-wrap: wrap; width: 100%; overflow: visible; box-shadow: 0 4px 0 var(--ink); }
  .dock__play { width: 100%; }
  .dock__list { flex-wrap: wrap; width: 100%; }
  .dock__list li:nth-child(5) { margin-right: 0; padding-right: 0; border-right: 0; }
  .chipbtn { height: 38px; font-size: 14px; }
  .apply-dialog__box { padding: 24px 18px 20px; box-shadow: 5px 5px 0 var(--yellow), 5px 5px 0 3px var(--ink); }
  .apply-dialog h2 { font-size: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0ms !important; }
}
