/* Off Beat Ninja: ink on charcoal, bone text, vermilion for danger. */
.obn-top{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px}
.obn-top h1{font-size:1.15rem;letter-spacing:.04em;white-space:nowrap}
.obn-ctl{display:flex;gap:6px}
.obn-ctl button{min-height:44px;min-width:44px;padding:0 10px;background:#1d1612;color:#ece3d0;border:1px solid #5a4a3c;border-radius:8px;font:600 .78rem Georgia,serif;cursor:pointer}
.obn-ctl button:active{background:#33261d}
.obn{position:relative;width:100%;border-radius:12px;overflow:hidden;background:#14100d;border:1px solid #3a2e25;user-select:none;-webkit-user-select:none;-webkit-tap-highlight-color:transparent}
#obn-canvas{display:block;width:100%;touch-action:none;cursor:crosshair}
.obn-layer{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;padding:16px 14px calc(16px + env(safe-area-inset-bottom));background:rgba(14,10,8,.84);overflow-y:auto;text-align:center}
.obn-layer[hidden]{display:none}
.obn-layer h2{font-size:2.3rem;line-height:1.02;letter-spacing:.05em;text-transform:uppercase}
.obn-layer h3{font-size:1.6rem;letter-spacing:.04em}
.logo{display:flex;align-items:center;gap:14px;margin-bottom:2px}
.seal{width:48px;height:48px;border-radius:50%;background:#d8402a;box-shadow:0 0 0 4px #14100d,0 0 0 6px #ece3d0;flex:none;animation:obnpulse 1.2s ease-out infinite}
.logo h2{text-align:left}
.tag{font-size:.9rem;color:#cbbfa8;max-width:290px}
.meta{font-size:.75rem;color:#9a8f7c;max-width:300px}
.meta.warn{color:#e8b04a}
.row{display:flex;gap:8px;justify-content:center;align-items:center;width:100%}
.obn-btn{min-height:48px;min-width:48px;padding:0 16px;background:#1d1612;color:#ece3d0;border:2px solid #ece3d0;border-radius:6px;font:700 .95rem Georgia,serif;cursor:pointer;flex:1;max-width:190px}
.obn-btn.big{background:#d8402a;border-color:#d8402a;color:#fff7ea;width:100%;max-width:300px;min-height:56px;font-size:1.05rem;flex:none}
.obn-btn.sq{flex:none;width:56px;font-size:1.4rem}
.obn-btn:active{transform:translateY(1px);filter:brightness(1.15)}
.obn-btn:focus-visible,.cell:focus-visible{outline:3px solid #e8b04a;outline-offset:2px}
.val{min-width:90px;font:700 1.1rem ui-monospace,Menlo,Consolas,monospace}
.dot{display:inline-block;width:12px;height:12px;border-radius:50%;vertical-align:middle}
.grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;width:100%;max-width:340px}
.cell{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;min-height:84px;padding:6px 4px;background:#1d1612;color:#ece3d0;border:2px solid #5a4a3c;border-radius:8px;font-family:Georgia,serif;cursor:pointer}
.cell b{font-size:1.2rem;color:#e8b04a}.cell span{font-size:.78rem;font-weight:700}.cell em{font-size:.62rem;font-style:normal;color:#9a8f7c}
.cell[disabled]{opacity:.4;cursor:default}
.lock{font-size:.62rem!important;color:#9a8f7c}
.st{display:inline-flex;gap:3px;margin-top:3px}.st i{width:9px;height:9px;transform:rotate(45deg);border:1.5px solid #8a7d68;display:block}.st i.on{background:#e8b04a;border-color:#e8b04a}
.sub{min-height:20px}
.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:6px;width:100%;max-width:320px}
.stats b{display:block;font-size:1.25rem;color:#e8b04a;font-family:ui-monospace,Menlo,Consolas,monospace}.stats span{font-size:.65rem;color:#9a8f7c}
.newbest{color:#e8b04a;font-weight:700}
.is-result.lose h3{color:#d8402a}
.obn-help{font-size:.78rem;color:#9a8f7c;margin-top:8px;line-height:1.35}
.obn-fallback{padding:24px;text-align:center}
@keyframes obnpulse{0%{box-shadow:0 0 0 4px #14100d,0 0 0 6px #ece3d0,0 0 0 6px rgba(216,64,42,.7)}100%{box-shadow:0 0 0 4px #14100d,0 0 0 6px #ece3d0,0 0 0 18px rgba(216,64,42,0)}}
@media (prefers-reduced-motion:reduce){.seal{animation:none}.obn-btn:active{transform:none}}
@media (max-height:640px){.obn-layer h2{font-size:1.8rem}.obn-layer{gap:6px}}
.how{list-style:none;display:flex;flex-direction:column;gap:10px;max-width:310px;text-align:left}
.how li{display:flex;gap:12px;align-items:flex-start}
.how p{font-size:.9rem;line-height:1.35;color:#ece3d0}
.how .n{flex:none;width:30px;height:30px;border-radius:50%;background:#d8402a;color:#fff7ea;font:700 1rem Georgia,serif;display:flex;align-items:center;justify-content:center}
.meta.streak{color:#e8b04a}
/* Full screen: board fills the stage, chrome hidden. */
html.pip-immersive .game-wrap,html.pip-native .game-wrap,.game-wrap:fullscreen{display:flex;flex-direction:column;max-width:none;padding:6px 8px calc(6px + env(safe-area-inset-bottom));padding-left:calc(8px + env(safe-area-inset-left));padding-right:calc(8px + env(safe-area-inset-right));overflow:hidden}
html.pip-immersive .obn-help,html.pip-native .obn-help,.game-wrap:fullscreen .obn-help,html.pip-immersive .obn-top h1,html.pip-native .obn-top h1{display:none}
html.pip-immersive .obn-top,html.pip-native .obn-top{justify-content:flex-end;margin-bottom:4px;flex:none}
html.pip-immersive .obn,html.pip-native .obn,.game-wrap:fullscreen .obn{flex:1 1 auto;min-height:0;height:auto}
html.pip-immersive #obn-canvas,html.pip-native #obn-canvas,.game-wrap:fullscreen #obn-canvas{position:absolute;inset:0;width:100%;height:100%}
@media (orientation:landscape) and (max-height:520px){html.pip-immersive .obn-layer,html.pip-native .obn-layer{padding:8px 12px;gap:6px}html.pip-immersive .obn-layer h2,html.pip-native .obn-layer h2{font-size:1.5rem}html.pip-immersive .how,html.pip-native .how{flex-direction:row;max-width:none}}
