html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .chain-glow{position:fixed;inset:0;z-index:-1;pointer-events:none;background:radial-gradient(circle at 12% 42%,var(--lx-primary-a15),transparent 28rem),radial-gradient(circle at 86% 72%,var(--lx-secondary-a20),transparent 34rem)}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .goal-panel{width:min(100%,var(--standard-board-width));
  min-height:104px;
  margin:0 auto 12px;
  padding:12px 22px;
  display:grid;
  grid-template-columns:1fr 70px 1fr;
  align-items:center;
  gap:10px;
  border:2px solid var(--lx-border-strong);
  border-radius:20px;
  background:var(--lx-inset-background);
  box-shadow:var(--lx-card-shadow);}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .goal-panel>div:not(.goal-arrow){min-width:0;text-align:center}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .goal-panel span{display:block;color:var(--lx-text-muted);font-size:20px;font-weight:900;letter-spacing:.08em;text-transform:uppercase}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .goal-panel strong{display:block;margin-top:4px;overflow:hidden;color:var(--lx-reward);font-size:40px;font-weight:950;line-height:1;text-overflow:ellipsis;letter-spacing:.12em;text-transform:uppercase;white-space:nowrap}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .goal-arrow{color:var(--lx-secondary);font-size:48px;font-weight:950;text-align:center}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .word-editor{width:min(100%,var(--standard-board-width));
  margin:0 auto 12px;
  padding:14px;
  border:2px solid var(--lx-border);
  border-radius:20px;
  background:var(--lx-card-surface);}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .editor-label{display:block;margin-bottom:9px;color:var(--lx-text-muted);font-size:19px;font-weight:900;letter-spacing:.08em;text-align:center;text-transform:uppercase}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .current-word{--length:4;display:grid;grid-template-columns:repeat(var(--length),minmax(0,1fr));gap:9px;margin:0 auto}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .letter-slot{min-width:0;
  height:92px;
  padding:0;
  display:grid;
  place-items:center;
  appearance:none;
  -webkit-appearance:none;
  border:2px solid var(--lx-border-strong);
  border-radius:17px;
  color:var(--lx-text-strong);
  background:var(--lx-level-surface);
  box-shadow:var(--lx-button-shadow,var(--lx-card-shadow)),inset 0 1px 0 var(--lx-highlight-a08);
  font-size:48px;
  font-weight:950;
  text-transform:uppercase;
  touch-action:manipulation;
  cursor:pointer;
  transition:transform .12s ease,border-color .12s ease,background .12s ease;}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .letter-slot.selected{transform:translateY(-3px);
  border-color:var(--lx-reward);
  color:var(--lx-on-accent);
  background:var(--lx-active-tab-background);
  box-shadow:0 0 0 3px var(--lx-reward-a20),var(--lx-button-shadow,var(--lx-card-shadow));}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .game-actions button:active:not(:disabled){transform:translateY(3px) scale(.98)}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .chain-heading{width:min(100%,var(--standard-board-width));margin:16px auto 7px;display:flex;justify-content:space-between;gap:12px;color:var(--lx-text-muted);font-size:18px;font-weight:900;letter-spacing:.06em;text-transform:uppercase}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .chain-list{width:min(100%,var(--standard-board-width));min-height:76px;margin:auto;padding:10px;display:flex;align-items:center;gap:8px;overflow-x:auto;border:2px solid var(--lx-border);border-radius:17px;background:var(--lx-control-surface);scrollbar-width:thin}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .chain-node{flex:0 0 auto;padding:12px 15px;border:2px solid var(--lx-border);border-radius:14px;color:var(--lx-text-strong);background:var(--lx-level-surface);font-size:21px;font-weight:950;letter-spacing:.1em;text-transform:uppercase}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .chain-node.current{border-color:var(--lx-reward);color:var(--lx-reward)}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .chain-arrow{flex:0 0 auto;color:var(--lx-secondary);font-size:25px;font-weight:950}







html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .intro-chain{margin:0 0 18px;display:flex;align-items:center;justify-content:center;gap:10px}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .intro-chain span{padding:12px 16px;border:2px solid var(--lx-border);border-radius:15px;background:var(--lx-level-surface);font-size:24px;font-weight:950;letter-spacing:.1em}
html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .intro-chain b{color:var(--lx-secondary);font-size:26px}

@media (max-width:700px){html[data-game="lexaketju"][data-game-ui-profile="standard-board"] .letter-slot{height:78px;font-size:40px}}


/* Pelikohtainen työpöytä/tabletti-asettelu; siirretty pois yhteisestä UI-kerroksesta. */
html[data-responsive-layout="adaptive"][data-layout-mode="desktop"][data-game="lexaketju"] .chain-panel{display:grid!important;grid-template-columns:minmax(620px,1.15fr) minmax(380px,.85fr)!important;grid-template-rows:auto auto auto auto auto!important;gap:14px 22px!important;align-items:start!important;}
html[data-responsive-layout="adaptive"][data-layout-mode="desktop"][data-game="lexaketju"] .chain-panel>.board-tools{grid-column:1/-1!important;}
html[data-responsive-layout="adaptive"][data-layout-mode="desktop"][data-game="lexaketju"] .chain-panel>:is(.goal-panel,.word-editor,lexapyr-keyboard,.game-actions){grid-column:1!important;width:100%!important;}
html[data-responsive-layout="adaptive"][data-layout-mode="desktop"][data-game="lexaketju"] .chain-panel>.chain-heading{grid-column:2!important;grid-row:2!important;width:100%!important;margin-top:0!important;}
html[data-responsive-layout="adaptive"][data-layout-mode="desktop"][data-game="lexaketju"] .chain-panel>.chain-list{grid-column:2!important;grid-row:3/6!important;width:100%!important;min-height:360px!important;align-content:flex-start!important;flex-wrap:wrap!important;}

/* Game-owned rules relocated from the former shared override layer. */
@media (min-width:0px){
html[data-responsive-layout="adaptive"][data-layout-mode="desktop"][data-game="lexaketju"] .chain-panel{
    grid-template-columns:minmax(0,1fr) 340px!important;
    grid-template-rows:auto auto auto auto minmax(0,1fr)!important;
    gap:8px 14px!important;
    align-items:start!important;
  }

html[data-responsive-layout="adaptive"][data-layout-mode="desktop"][data-game="lexaketju"] .chain-panel>.chain-list{
    min-height:0!important;
    height:100%!important;
    max-height:100%!important;
    overflow:auto!important;
  }
}

html[data-game="lexaketju"] .current-word[data-length="4"]{--length:4;}
html[data-game="lexaketju"] .current-word[data-length="5"]{--length:5;}
html[data-game="lexaketju"] .current-word[data-length="6"]{--length:6;}
html[data-game="lexaketju"] .current-word[data-length="7"]{--length:7;}
html[data-game="lexaketju"] .current-word[data-length="8"]{--length:8;}
