:root{--bg:#07111f;--panel:#0d1b2e;--panel2:#132742;--text:#eef6ff;--muted:#9fb0c7;--line:rgba(255,255,255,.11);--accent:#67e8f9}
*{box-sizing:border-box}body{margin:0;background:radial-gradient(circle at top,#12304c,#07111f 42%);color:var(--text);font-family:Inter,system-ui,sans-serif;line-height:1.6}
a{color:inherit}.wrap{width:min(980px,calc(100% - 24px));margin:auto}.top{padding:18px 0;display:flex;align-items:center;justify-content:space-between;gap:12px}.brand{text-decoration:none;font-weight:900}.back{color:#bdf7ff;text-decoration:none}
.game-layout{display:grid;grid-template-columns:minmax(0,640px) 1fr;gap:22px;align-items:start}.game-panel,.side-panel,.article{background:rgba(13,27,46,.94);border:1px solid var(--line);border-radius:22px;box-shadow:0 20px 55px rgba(0,0,0,.26)}
.game-panel{padding:18px}.side-panel{padding:18px;position:sticky;top:16px}.stats{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:14px}.stat{padding:12px;border-radius:14px;background:var(--panel2);text-align:center}.stat strong{display:block;font-size:1.35rem}.stat span{font-size:.8rem;color:var(--muted)}
.controls{display:flex;flex-wrap:wrap;gap:10px;margin-top:15px}.btn{border:0;border-radius:12px;padding:11px 14px;font-weight:900;cursor:pointer;background:var(--accent);color:#06101c}.btn.secondary{background:var(--panel2);color:var(--text);border:1px solid var(--line)}
.ad-slot{min-height:100px;border:1px dashed rgba(255,255,255,.2);border-radius:14px;margin:16px 0;display:grid;place-items:center;text-align:center;color:#8798af;padding:16px}.ad-slot small{display:block;text-transform:uppercase;letter-spacing:.12em}
.article{padding:clamp(20px,5vw,40px);margin:24px 0 50px}.article h1{font-size:clamp(2rem,5vw,3.4rem);line-height:1.1;margin:0 0 14px}.article h2{margin-top:30px}.article p,.article li{color:#c4d1e2}.note{color:var(--muted);font-size:.92rem}
.modal{position:fixed;inset:0;background:rgba(0,0,0,.72);display:none;place-items:center;padding:20px;z-index:20}.modal.show{display:grid}.modal-card{width:min(420px,100%);background:var(--panel);border:1px solid var(--line);border-radius:20px;padding:26px;text-align:center}
@media(max-width:800px){.game-layout{grid-template-columns:1fr}.side-panel{position:static}}

/* Embedded player mode */
html.embed-mode,
html.embed-mode body {
    width: 100%;
    height: 100%;
    min-height: 100%;
    overflow: hidden;
}

html.embed-mode body {
    background: #07111f;
}

html.embed-mode .wrap {
    width: 100%;
    max-width: none;
    height: 100%;
    margin: 0;
}

html.embed-mode .top,
html.embed-mode .side-panel,
html.embed-mode .article {
    display: none !important;
}

html.embed-mode .game-layout {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
}

html.embed-mode .game-panel {
    width: 100%;
    height: 100%;
    min-height: 100%;
    padding: 12px;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    overflow: auto;
    scrollbar-width: thin;
}

html.embed-mode .stats {
    margin-bottom: 8px;
}

html.embed-mode .stat {
    padding: 7px 10px;
}

html.embed-mode .controls {
    margin-top: 8px;
}

html.embed-mode .note {
    margin: 7px 0;
}

@media (max-width: 600px) {
    html.embed-mode .game-panel {
        padding: 8px;
    }
}


/* =========================================================
   PlayZone Premium Game Controls
   Visual-only upgrade: does not alter game logic.
   ========================================================= */
.game-control-panel{
  margin-top:16px;
  padding:16px;
  border:1px solid rgba(255,255,255,.11);
  border-radius:20px;
  background:
    radial-gradient(circle at 12% 0%,rgba(103,232,249,.12),transparent 35%),
    linear-gradient(145deg,rgba(19,39,66,.98),rgba(7,20,36,.98));
  box-shadow:0 18px 42px rgba(0,0,0,.22);
}
.game-control-title{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:14px;
}
.game-control-title strong{
  color:#f4f9ff;
  font-size:15px;
  letter-spacing:.01em;
}
.game-control-title span{
  color:#8fa3bb;
  font-size:12px;
}
.game-panel .pad{
  display:grid;
  grid-template-columns:repeat(3,64px);
  grid-template-areas:
    ". up ."
    "left down right";
  justify-content:center;
  gap:10px;
  margin:0 auto 16px;
}
.game-panel .pad button{
  appearance:none;
  width:64px;
  height:58px;
  display:grid;
  place-items:center;
  border:1px solid rgba(134,167,211,.26);
  border-radius:17px;
  background:
    linear-gradient(145deg,rgba(31,61,98,.96),rgba(12,29,52,.98));
  color:#f4fbff;
  font-size:24px;
  font-weight:900;
  line-height:1;
  cursor:pointer;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.07),
    0 9px 22px rgba(0,0,0,.2);
  transition:
    transform .14s ease,
    border-color .14s ease,
    background .14s ease,
    box-shadow .14s ease;
  touch-action:manipulation;
  -webkit-tap-highlight-color:transparent;
}
.game-panel .pad .up{grid-area:up}
.game-panel .pad .left{grid-area:left}
.game-panel .pad .down{grid-area:down}
.game-panel .pad .right{grid-area:right}
.game-panel .pad button:hover,
.game-panel .pad button:focus-visible{
  transform:translateY(-2px);
  border-color:rgba(103,232,249,.72);
  background:linear-gradient(145deg,rgba(39,78,122,.98),rgba(17,39,68,.98));
  box-shadow:0 11px 26px rgba(0,0,0,.28),0 0 0 3px rgba(103,232,249,.09);
  outline:none;
}
.game-panel .pad button:active,
.game-panel .pad button.is-pressed{
  transform:translateY(1px) scale(.96);
  box-shadow:inset 0 4px 12px rgba(0,0,0,.27);
}
.game-panel .controls.premium-actions{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  margin-top:0;
}
.game-panel .controls.premium-actions .btn{
  min-height:48px;
  width:100%;
  padding:11px 14px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  border:1px solid transparent;
  border-radius:15px;
  font-size:14px;
  font-weight:900;
  letter-spacing:.01em;
  box-shadow:0 10px 24px rgba(0,0,0,.18);
  transition:transform .15s ease,box-shadow .15s ease,filter .15s ease,border-color .15s ease;
}
.game-panel .controls.premium-actions .btn:hover,
.game-panel .controls.premium-actions .btn:focus-visible{
  transform:translateY(-2px);
  box-shadow:0 14px 30px rgba(0,0,0,.27);
  filter:brightness(1.05);
  outline:none;
}
.game-panel .controls.premium-actions .btn:active{transform:translateY(0) scale(.98)}
.game-panel .controls.premium-actions .btn-primary{
  color:#03121c;
  background:linear-gradient(135deg,#67e8f9,#38bdf8);
}
.game-panel .controls.premium-actions .btn-pause{
  color:#fff7ed;
  border-color:rgba(251,146,60,.25);
  background:linear-gradient(135deg,#c2410c,#f97316);
}
.game-panel .controls.premium-actions .btn-favorite{
  grid-column:1/-1;
  color:#ffe9f1;
  border-color:rgba(244,114,182,.25);
  background:linear-gradient(135deg,rgba(157,23,77,.95),rgba(219,39,119,.92));
}
.game-panel .controls.premium-actions .btn-favorite[aria-pressed="true"],
.game-panel .controls.premium-actions .btn-favorite.is-active{
  color:#fff;
  background:linear-gradient(135deg,#be123c,#f43f5e);
}
.game-panel .controls.premium-actions .control-icon{
  font-size:17px;
  line-height:1;
}
.control-help{
  margin:12px 0 0;
  padding-top:12px;
  border-top:1px solid rgba(255,255,255,.08);
  color:#91a5bd;
  font-size:12px;
  text-align:center;
}
.control-help kbd{
  display:inline-block;
  min-width:25px;
  margin:0 2px;
  padding:2px 6px;
  border:1px solid rgba(255,255,255,.14);
  border-bottom-width:2px;
  border-radius:7px;
  background:#081524;
  color:#e8f5ff;
  font:700 11px/1.5 Inter,system-ui,sans-serif;
}

/* General improvement for shared game buttons */
.game-panel .controls:not(.premium-actions) .btn{
  min-height:46px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  border-radius:14px;
  padding:11px 17px;
  box-shadow:0 9px 22px rgba(0,0,0,.18);
  transition:transform .15s ease,filter .15s ease,box-shadow .15s ease;
}
.game-panel .controls:not(.premium-actions) .btn:hover{
  transform:translateY(-2px);
  filter:brightness(1.05);
  box-shadow:0 13px 26px rgba(0,0,0,.25);
}

@media(max-width:600px){
  .game-control-panel{padding:13px;border-radius:17px}
  .game-panel .pad{
    grid-template-columns:repeat(3,58px);
    gap:8px;
  }
  .game-panel .pad button{
    width:58px;
    height:54px;
    border-radius:15px;
  }
  .game-panel .controls.premium-actions{
    grid-template-columns:1fr 1fr;
  }
  .game-panel .controls.premium-actions .btn{
    min-height:50px;
    padding:10px 9px;
    font-size:13px;
  }
}