#gcg-game-root{
  --bg:#07131b;
  --bg-2:#101a2a;
  --panel:rgba(10,20,31,.88);
  --panel-2:rgba(15,29,43,.92);
  --line:rgba(255,255,255,.08);
  --text:#f4f8ff;
  --muted:#a7b5c8;
  --accent:#6ce7ff;
  --accent-2:#a27cff;
  --accent-3:#72f0ad;
  color:var(--text);
  font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
#gcg-game-root *{box-sizing:border-box;}
#gcg-game-root button,#gcg-game-root select{font:inherit;}
#gcg-game-root .bpcf-shell{position:relative;overflow:hidden;border-radius:30px;padding:22px;background:radial-gradient(circle at 20% 0%,rgba(108,231,255,.16),transparent 28%),radial-gradient(circle at 92% 12%,rgba(162,124,255,.18),transparent 24%),linear-gradient(180deg,#08131d,#0b1422 52%,#071019);border:1px solid rgba(255,255,255,.08);box-shadow:0 36px 100px rgba(0,0,0,.38);}
#gcg-game-root .bpcf-shell.theme-crystal{--accent:#6ce7ff;--accent-2:#a27cff;--accent-3:#72f0ad;--glow:108,231,255;}
#gcg-game-root .bpcf-shell.theme-ember{--accent:#ffbd5d;--accent-2:#ff6c7c;--accent-3:#ffe36c;--glow:255,189,93;}
#gcg-game-root .bpcf-shell.theme-aurora{--accent:#7df7ce;--accent-2:#71a8ff;--accent-3:#e18cff;--glow:125,247,206;}
#gcg-game-root .bpcf-shell::before{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(120deg,transparent 0 35%,rgba(255,255,255,.025) 50%,transparent 65% 100%);}
#gcg-game-root .bpcf-hero{display:flex;justify-content:space-between;gap:22px;align-items:flex-start;padding:6px 6px 18px;}
#gcg-game-root .bpcf-kicker{display:inline-flex;padding:6px 10px;border-radius:999px;background:rgba(255,255,255,.055);border:1px solid rgba(255,255,255,.08);color:var(--accent);font-size:12px;font-weight:800;letter-spacing:.09em;text-transform:uppercase;margin-bottom:10px;}
#gcg-game-root .bpcf-hero h1{margin:0;font-size:clamp(29px,4vw,44px);line-height:1.05;font-weight:900;letter-spacing:-.03em;}
#gcg-game-root .bpcf-hero p{margin:10px 0 0;max-width:760px;color:var(--muted);font-size:15px;line-height:1.55;}
#gcg-game-root .bpcf-badges{display:flex;flex-wrap:wrap;gap:10px;justify-content:flex-end;}
#gcg-game-root .bpcf-badges span{padding:10px 13px;border-radius:14px;background:linear-gradient(180deg,rgba(255,255,255,.07),rgba(255,255,255,.035));border:1px solid rgba(255,255,255,.09);font-size:13px;font-weight:700;white-space:nowrap;}
#gcg-game-root .bpcf-topbar{display:flex;justify-content:space-between;gap:16px;align-items:center;margin-bottom:16px;}
#gcg-game-root .bpcf-mode-tabs,#gcg-game-root .bpcf-inline-actions,#gcg-game-root .bpcf-modal-actions{display:flex;gap:10px;flex-wrap:wrap;}
#gcg-game-root .bpcf-mode-tabs button,#gcg-game-root .bpcf-inline-actions button,#gcg-game-root .bpcf-tools button,#gcg-game-root .bpcf-modal-actions button{appearance:none;border:none;cursor:pointer;border-radius:14px;padding:11px 14px;color:var(--text);background:rgba(255,255,255,.055);border:1px solid rgba(255,255,255,.08);box-shadow:0 8px 20px rgba(0,0,0,.17);transition:.18s ease;}
#gcg-game-root .bpcf-mode-tabs button:hover,#gcg-game-root .bpcf-inline-actions button:hover,#gcg-game-root .bpcf-tools button:hover,#gcg-game-root .bpcf-modal-actions button:hover{transform:translateY(-1px);background:rgba(255,255,255,.09);}
#gcg-game-root .bpcf-mode-tabs button.active,#gcg-game-root .bpcf-tools .primary,#gcg-game-root .bpcf-modal-actions .primary{background:linear-gradient(180deg,var(--accent),color-mix(in srgb,var(--accent) 70%,#10536d));color:#06131a;border-color:transparent;font-weight:900;}
#gcg-game-root .bpcf-tools .accent{background:linear-gradient(180deg,var(--accent-3),color-mix(in srgb,var(--accent-3) 70%,#145136));color:#06120d;border-color:transparent;font-weight:900;}
#gcg-game-root .bpcf-layout{display:grid;grid-template-columns:minmax(270px,320px) minmax(0,1fr);gap:18px;align-items:start;}
#gcg-game-root .bpcf-sidebar{display:flex;flex-direction:column;gap:14px;}
#gcg-game-root .bpcf-panel{background:linear-gradient(180deg,rgba(255,255,255,.055),rgba(255,255,255,.028));border:1px solid rgba(255,255,255,.08);border-radius:24px;padding:16px;backdrop-filter:blur(14px);}
#gcg-game-root .bpcf-panel-title{font-size:15px;font-weight:850;margin-bottom:14px;color:#fff;}
#gcg-game-root .bpcf-stat-grid,#gcg-game-root .bpcf-legacy-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;}
#gcg-game-root .bpcf-stat-grid div,#gcg-game-root .bpcf-legacy-grid div{padding:12px;border-radius:16px;background:rgba(255,255,255,.04);border:1px solid rgba(255,255,255,.06);}
#gcg-game-root .bpcf-stat-grid span,#gcg-game-root .bpcf-legacy-grid span{display:block;color:var(--muted);font-size:12px;margin-bottom:6px;}
#gcg-game-root .bpcf-stat-grid strong,#gcg-game-root .bpcf-legacy-grid strong{display:block;font-size:20px;line-height:1;color:#fff;}
#gcg-game-root .bpcf-progress-wrap{margin-top:14px;}
#gcg-game-root .bpcf-progress-label{display:flex;justify-content:space-between;gap:10px;color:var(--muted);font-size:12px;margin-bottom:8px;}
#gcg-game-root .bpcf-progress{height:12px;border-radius:999px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.08);overflow:hidden;}
#gcg-game-root .bpcf-progress i{display:block;height:100%;width:0;border-radius:999px;background:linear-gradient(90deg,var(--accent),var(--accent-2),var(--accent-3));box-shadow:0 0 18px rgba(var(--glow),.34);transition:width .25s ease;}
#gcg-game-root .bpcf-boss-banner{margin-top:12px;padding:11px 12px;border-radius:14px;background:linear-gradient(180deg,rgba(255,82,119,.18),rgba(255,82,119,.08));border:1px solid rgba(255,108,136,.25);color:#ffc3d0;font-size:12px;font-weight:800;}
#gcg-game-root .bpcf-boss-banner.hidden{display:none;}
#gcg-game-root .bpcf-tools{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;}
#gcg-game-root .bpcf-field{display:grid;gap:8px;color:var(--muted);font-size:13px;margin-bottom:12px;}
#gcg-game-root .bpcf-field:last-child{margin-bottom:0;}
#gcg-game-root .bpcf-field select{padding:12px 14px;border-radius:14px;background:rgba(255,255,255,.055);border:1px solid rgba(255,255,255,.09);color:var(--text);}
#gcg-game-root .bpcf-game-panel{min-width:0;background:linear-gradient(180deg,rgba(255,255,255,.055),rgba(255,255,255,.028));border:1px solid rgba(255,255,255,.08);border-radius:28px;padding:16px;overflow:hidden;}
#gcg-game-root .bpcf-board-head{display:flex;justify-content:space-between;gap:14px;align-items:flex-start;flex-wrap:wrap;margin-bottom:12px;}
#gcg-game-root .bpcf-message{padding:12px 14px;border-radius:16px;background:rgba(255,255,255,.055);border:1px solid rgba(255,255,255,.08);font-weight:700;color:#fff;}
#gcg-game-root .bpcf-rule-note{max-width:380px;color:var(--muted);font-size:12px;line-height:1.45;}
#gcg-game-root .bpcf-forge-stage{border-radius:24px;padding:18px;background:radial-gradient(circle at 50% 0%,rgba(var(--glow),.12),transparent 30%),linear-gradient(180deg,#08141e,#08111a);border:1px solid rgba(255,255,255,.06);min-height:650px;}
#gcg-game-root .bpcf-board-wrap{position:relative;width:min(100%,620px);margin:0 auto;}
#gcg-game-root .bpcf-board{display:grid;grid-template-columns:repeat(var(--grid-size),1fr);gap:7px;padding:15px;border-radius:28px;background:linear-gradient(180deg,rgba(255,255,255,.055),rgba(255,255,255,.018));border:1px solid rgba(255,255,255,.07);box-shadow:0 28px 60px rgba(0,0,0,.28),inset 0 1px 0 rgba(255,255,255,.05);touch-action:none;}
#gcg-game-root .bpcf-cell{position:relative;aspect-ratio:1;border:none;padding:0;border-radius:11px;cursor:pointer;background:linear-gradient(180deg,rgba(255,255,255,.075),rgba(255,255,255,.03));border:1px solid rgba(255,255,255,.055);box-shadow:inset 0 1px 0 rgba(255,255,255,.05);overflow:hidden;}
#gcg-game-root .bpcf-cell::before{content:"";position:absolute;inset:3px;border-radius:8px;background:rgba(255,255,255,.018);}
#gcg-game-root .bpcf-board.nine-grid .bpcf-cell:nth-child(3n){box-shadow:inset -2px 0 0 rgba(255,255,255,.08),inset 0 1px 0 rgba(255,255,255,.05);}
#gcg-game-root .bpcf-cell span{position:absolute;inset:3px;border-radius:8px;transition:.18s ease;}
#gcg-game-root .bpcf-cell.filled span{background:linear-gradient(145deg,rgba(255,255,255,.88),rgba(255,255,255,.12) 35%,rgba(0,0,0,.08) 76%),var(--block-color);box-shadow:inset 0 1px 0 rgba(255,255,255,.8),inset 0 -3px 8px rgba(0,0,0,.18),0 0 16px var(--block-glow);}
#gcg-game-root .skin-gem .bpcf-cell.filled span{clip-path:polygon(50% 0,92% 18%,100% 67%,72% 100%,28% 100%,0 67%,8% 18%);border-radius:4px;}
#gcg-game-root .skin-neon .bpcf-cell.filled span{background:rgba(7,18,27,.74);border:2px solid var(--block-color);box-shadow:inset 0 0 12px var(--block-glow),0 0 14px var(--block-glow);}
#gcg-game-root .bpcf-cell.preview{outline:2px solid var(--accent);outline-offset:-2px;background:rgba(var(--glow),.13);}
#gcg-game-root .bpcf-cell.preview::after{content:"";position:absolute;inset:5px;border-radius:7px;background:rgba(var(--glow),.18);}
#gcg-game-root .bpcf-cell.obstacle span{background:repeating-linear-gradient(135deg,#26303b 0 7px,#151d27 7px 14px);box-shadow:inset 0 0 0 2px rgba(255,255,255,.05);}
#gcg-game-root .bpcf-cell.obstacle::after{content:"◆";position:absolute;inset:0;display:grid;place-items:center;color:#718093;font-size:13px;}
#gcg-game-root .bpcf-cell.frozen::after{content:"❄";position:absolute;inset:0;display:grid;place-items:center;color:#e7fbff;text-shadow:0 0 8px #65dfff;font-size:16px;}
#gcg-game-root .bpcf-cell.wild span{filter:saturate(1.35) brightness(1.15);}
#gcg-game-root .bpcf-cell.pulse span{animation:bpcf-pulse .42s ease both;}
#gcg-game-root .color-cyan{--block-color:#47dfff;--block-glow:rgba(71,223,255,.5);}
#gcg-game-root .color-violet{--block-color:#9c73ff;--block-glow:rgba(156,115,255,.5);}
#gcg-game-root .color-rose{--block-color:#ff6f9f;--block-glow:rgba(255,111,159,.5);}
#gcg-game-root .color-amber{--block-color:#ffbd55;--block-glow:rgba(255,189,85,.5);}
#gcg-game-root .color-emerald{--block-color:#5ce59f;--block-glow:rgba(92,229,159,.5);}
#gcg-game-root .color-sapphire{--block-color:#5e8cff;--block-glow:rgba(94,140,255,.5);}
#gcg-game-root .bpcf-paused{position:absolute;inset:0;display:grid;place-items:center;align-content:center;gap:8px;border-radius:28px;background:rgba(5,12,18,.8);backdrop-filter:blur(8px);z-index:8;}
#gcg-game-root .bpcf-paused.hidden{display:none;}
#gcg-game-root .bpcf-paused strong{font-size:28px;}
#gcg-game-root .bpcf-paused span{color:var(--muted);}
#gcg-game-root .bpcf-tray-section{margin-top:18px;padding:16px;border-radius:22px;background:linear-gradient(180deg,rgba(255,255,255,.045),rgba(255,255,255,.02));border:1px solid rgba(255,255,255,.06);}
#gcg-game-root .bpcf-tray-head{display:flex;justify-content:space-between;align-items:center;gap:14px;margin-bottom:14px;}
#gcg-game-root .bpcf-tray-head>div>span,#gcg-game-root .bpcf-move-counter span{display:block;color:var(--muted);font-size:12px;margin-bottom:5px;}
#gcg-game-root .bpcf-tray-head strong{font-size:16px;}
#gcg-game-root .bpcf-tray{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;}
#gcg-game-root .bpcf-piece{position:relative;min-height:150px;border:none;cursor:grab;border-radius:20px;padding:14px;color:var(--text);background:linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.025));border:1px solid rgba(255,255,255,.075);box-shadow:0 12px 28px rgba(0,0,0,.16);display:grid;place-items:center;align-content:center;gap:10px;touch-action:none;transition:.18s ease;}
#gcg-game-root .bpcf-piece:hover,#gcg-game-root .bpcf-piece.selected{transform:translateY(-2px);border-color:rgba(var(--glow),.48);box-shadow:0 16px 34px rgba(0,0,0,.22),0 0 0 2px rgba(var(--glow),.12);}
#gcg-game-root .bpcf-piece.power{background:linear-gradient(180deg,rgba(var(--glow),.12),rgba(255,255,255,.025));}
#gcg-game-root .bpcf-piece.used{opacity:.24;cursor:default;transform:none;}
#gcg-game-root .piece-grid{--mini:24px;position:relative;width:calc(var(--piece-w) * var(--mini));height:calc(var(--piece-h) * var(--mini));}
#gcg-game-root .mini-block{position:absolute;left:calc(var(--x) * var(--mini));top:calc(var(--y) * var(--mini));width:calc(var(--mini) - 3px);height:calc(var(--mini) - 3px);border-radius:7px;background:linear-gradient(145deg,rgba(255,255,255,.82),rgba(255,255,255,.1) 38%,rgba(0,0,0,.08)),var(--block-color);box-shadow:inset 0 1px 0 rgba(255,255,255,.7),0 0 12px var(--block-glow);}
#gcg-game-root .piece-label{font-size:12px;color:var(--muted);font-weight:700;}
#gcg-game-root .bpcf-drag-ghost{--mini:28px;position:fixed;z-index:99999;pointer-events:none;transform:translate(-50%,-70%);width:calc(var(--piece-w) * var(--mini));height:calc(var(--piece-h) * var(--mini));filter:drop-shadow(0 10px 18px rgba(0,0,0,.36));}
#gcg-game-root .bpcf-drag-ghost i{position:absolute;left:calc(var(--x) * var(--mini));top:calc(var(--y) * var(--mini));width:calc(var(--mini) - 3px);height:calc(var(--mini) - 3px);border-radius:8px;background:linear-gradient(145deg,rgba(255,255,255,.85),rgba(255,255,255,.12) 40%,rgba(0,0,0,.1)),var(--block-color);box-shadow:0 0 16px var(--block-glow);}
#gcg-game-root .bpcf-drag-ghost.invalid{filter:grayscale(.8) opacity(.55) drop-shadow(0 8px 14px rgba(0,0,0,.3));}
#gcg-game-root .bpcf-overlay{position:absolute;inset:0;display:grid;place-items:center;padding:24px;background:rgba(4,10,16,.76);backdrop-filter:blur(11px);z-index:50;}
#gcg-game-root .bpcf-overlay.hidden{display:none;}
#gcg-game-root .bpcf-modal{width:min(100%,500px);padding:24px;border-radius:28px;background:linear-gradient(180deg,rgba(14,25,38,.98),rgba(8,17,27,.97));border:1px solid rgba(255,255,255,.09);box-shadow:0 36px 90px rgba(0,0,0,.44);}
#gcg-game-root .bpcf-modal-kicker{display:inline-flex;padding:7px 11px;border-radius:999px;background:rgba(255,255,255,.055);color:var(--accent);font-size:12px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;margin-bottom:10px;}
#gcg-game-root .bpcf-modal h2{margin:0 0 10px;font-size:32px;}
#gcg-game-root .bpcf-modal p{margin:0 0 17px;color:var(--muted);line-height:1.55;}
#gcg-game-root .bpcf-modal-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:18px;}
#gcg-game-root .bpcf-modal-stats div{padding:13px;border-radius:16px;background:rgba(255,255,255,.04);border:1px solid rgba(255,255,255,.06);}
#gcg-game-root .bpcf-modal-stats span{display:block;color:var(--muted);font-size:12px;margin-bottom:6px;}
#gcg-game-root .bpcf-modal-stats strong{display:block;font-size:20px;color:#fff;}
#gcg-game-root .reduced-motion *{animation:none!important;transition:none!important;}
@keyframes bpcf-pulse{0%{transform:scale(1);filter:brightness(1)}50%{transform:scale(.76);filter:brightness(1.8)}100%{transform:scale(1);filter:brightness(1)}}
@media (max-width:1120px){
  #gcg-game-root .bpcf-layout{grid-template-columns:1fr;}
  #gcg-game-root .bpcf-sidebar{order:2;}
  #gcg-game-root .bpcf-game-panel{order:1;}
}
@media (max-width:790px){
  #gcg-game-root .bpcf-shell{padding:16px;border-radius:23px;}
  #gcg-game-root .bpcf-hero,#gcg-game-root .bpcf-topbar,#gcg-game-root .bpcf-board-head{flex-direction:column;align-items:stretch;}
  #gcg-game-root .bpcf-badges{justify-content:flex-start;}
  #gcg-game-root .bpcf-forge-stage{padding:12px;min-height:0;}
  #gcg-game-root .bpcf-tray{gap:9px;}
  #gcg-game-root .bpcf-piece{min-height:122px;padding:9px;}
  #gcg-game-root .piece-grid{--mini:20px;}
}
@media (max-width:560px){
  #gcg-game-root .bpcf-stat-grid,#gcg-game-root .bpcf-legacy-grid,#gcg-game-root .bpcf-tools{grid-template-columns:1fr 1fr;}
  #gcg-game-root .bpcf-board{gap:5px;padding:9px;border-radius:20px;}
  #gcg-game-root .bpcf-cell{border-radius:8px;}
  #gcg-game-root .bpcf-cell span{inset:2px;border-radius:6px;}
  #gcg-game-root .bpcf-tray{grid-template-columns:repeat(3,minmax(0,1fr));}
  #gcg-game-root .bpcf-piece{min-height:108px;border-radius:15px;}
  #gcg-game-root .piece-grid{--mini:17px;}
  #gcg-game-root .piece-label{font-size:10px;}
  #gcg-game-root .bpcf-modal-stats{grid-template-columns:1fr;}
}

/* v1.0.2 — viewport-safe fullscreen system */
#gcg-game-root.bpcf-root{
  position:relative;
  width:100%;
  min-width:0;
}
#gcg-game-root .bpcf-fs-hud{
  display:none;
}

.gcg-game-frame:fullscreen,
.gcg-game-frame:-webkit-full-screen{
  width:100vw!important;
  height:100vh!important;
  min-height:0!important;
  max-height:none!important;
  margin:0!important;
  padding:8px!important;
  border:0!important;
  border-radius:0!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
}
.gcg-game-frame:fullscreen #gcg-game-root,
.gcg-game-frame:-webkit-full-screen #gcg-game-root,
#gcg-game-root.bpcf-fullscreen-root{
  width:100%!important;
  height:100%!important;
  min-height:0!important;
  max-height:100%!important;
  overflow:hidden!important;
}
#gcg-game-root .bpcf-shell.bpcf-fullscreen-active{
  width:100%;
  height:100%;
  min-height:0;
  max-height:100%;
  padding:10px;
  border-radius:0;
  display:flex;
  flex-direction:column;
  overflow:hidden;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-hero{
  flex:0 0 auto;
  min-height:0;
  padding:0 2px 7px;
  gap:12px;
  align-items:center;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-kicker,
#gcg-game-root .bpcf-fullscreen-active .bpcf-hero p,
#gcg-game-root .bpcf-fullscreen-active .bpcf-badges{
  display:none;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-hero h1{
  font-size:clamp(18px,2vw,25px);
  line-height:1;
  white-space:nowrap;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-topbar{
  flex:0 0 auto;
  margin-bottom:8px;
  gap:8px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-mode-tabs,
#gcg-game-root .bpcf-fullscreen-active .bpcf-inline-actions{
  gap:6px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-mode-tabs button,
#gcg-game-root .bpcf-fullscreen-active .bpcf-inline-actions button,
#gcg-game-root .bpcf-fullscreen-active .bpcf-tools button{
  padding:7px 9px;
  min-height:34px;
  border-radius:10px;
  font-size:12px;
  box-shadow:none;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-layout{
  flex:1 1 auto;
  min-height:0;
  height:0;
  grid-template-columns:minmax(210px,245px) minmax(0,1fr);
  gap:10px;
  align-items:stretch;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-sidebar{
  min-height:0;
  height:100%;
  display:grid;
  grid-template-rows:auto auto;
  align-content:start;
  gap:8px;
  overflow:hidden;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-sidebar .bpcf-panel{
  padding:10px;
  border-radius:15px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-sidebar .bpcf-panel:nth-child(3),
#gcg-game-root .bpcf-fullscreen-active .bpcf-sidebar .bpcf-panel:nth-child(4){
  display:none;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-panel-title{
  margin-bottom:7px;
  font-size:12px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-stat-grid{
  gap:5px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-stat-grid div{
  padding:7px;
  border-radius:10px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-stat-grid span{
  margin-bottom:3px;
  font-size:9px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-stat-grid strong{
  font-size:14px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-progress-wrap{
  margin-top:7px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-progress-label{
  margin-bottom:4px;
  font-size:9px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-progress{
  height:8px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-boss-banner{
  margin-top:6px;
  padding:6px 7px;
  font-size:9px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-tools{
  gap:6px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-game-panel{
  height:100%;
  min-height:0;
  padding:8px;
  border-radius:17px;
  display:flex;
  flex-direction:column;
  overflow:hidden;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-board-head{
  flex:0 0 auto;
  margin-bottom:6px;
  gap:6px;
  align-items:center;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-message{
  padding:7px 9px;
  border-radius:10px;
  font-size:11px;
  line-height:1.25;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-rule-note{
  display:none;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-forge-stage{
  flex:1 1 auto;
  min-height:0;
  height:0;
  padding:8px;
  border-radius:16px;
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(210px,285px);
  gap:10px;
  align-items:center;
  overflow:hidden;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-board-wrap{
  width:min(100%,calc(var(--bpcf-frame-height,100vh) - 132px));
  max-width:610px;
  min-width:0;
  margin:auto;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-board{
  gap:5px;
  padding:9px;
  border-radius:18px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-cell{
  border-radius:8px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-cell span{
  inset:2px;
  border-radius:6px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-tray-section{
  min-height:0;
  height:100%;
  margin-top:0;
  padding:9px;
  border-radius:15px;
  display:flex;
  flex-direction:column;
  overflow:hidden;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-tray-head{
  flex:0 0 auto;
  margin-bottom:7px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-tray-head>div>span,
#gcg-game-root .bpcf-fullscreen-active .bpcf-move-counter span{
  margin-bottom:2px;
  font-size:9px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-tray-head strong{
  font-size:12px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-tray{
  flex:1 1 auto;
  min-height:0;
  grid-template-columns:1fr;
  grid-template-rows:repeat(3,minmax(0,1fr));
  gap:7px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-piece{
  min-height:0;
  height:100%;
  padding:6px;
  border-radius:12px;
  gap:4px;
}
#gcg-game-root .bpcf-fullscreen-active .piece-grid{
  --mini:17px;
}
#gcg-game-root .bpcf-fullscreen-active .piece-label{
  font-size:9px;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-overlay{
  position:fixed;
}

@media (max-width:1180px){
  #gcg-game-root .bpcf-fullscreen-active .bpcf-sidebar{
    display:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-layout{
    grid-template-columns:1fr;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud{
    display:grid;
    grid-template-columns:repeat(5,minmax(64px,1fr));
    gap:5px;
    width:100%;
    order:3;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud div{
    padding:5px 7px;
    border-radius:9px;
    background:rgba(255,255,255,.045);
    border:1px solid rgba(255,255,255,.06);
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud span{
    display:block;
    color:var(--muted);
    font-size:8px;
    margin-bottom:2px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud strong{
    display:block;
    font-size:11px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-message{
    width:100%;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-forge-stage{
    grid-template-columns:minmax(0,1fr) minmax(190px,260px);
  }
}

@media (max-width:760px), (orientation:portrait) and (max-width:900px){
  #gcg-game-root .bpcf-shell.bpcf-fullscreen-active{
    padding:6px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-hero{
    display:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-topbar{
    margin-bottom:5px;
    flex-direction:row;
    align-items:center;
    flex-wrap:nowrap;
    overflow-x:auto;
    scrollbar-width:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-topbar::-webkit-scrollbar{
    display:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-mode-tabs,
  #gcg-game-root .bpcf-fullscreen-active .bpcf-inline-actions{
    flex-wrap:nowrap;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-mode-tabs button,
  #gcg-game-root .bpcf-fullscreen-active .bpcf-inline-actions button{
    white-space:nowrap;
    padding:6px 8px;
    min-height:30px;
    font-size:10px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-game-panel{
    padding:5px;
    border-radius:12px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-board-head{
    margin-bottom:4px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-message{
    display:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud{
    grid-template-columns:repeat(5,minmax(48px,1fr));
    gap:3px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud div{
    padding:3px 4px;
    border-radius:7px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud span{
    font-size:7px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-fs-hud strong{
    font-size:9px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-forge-stage{
    padding:5px;
    display:flex;
    flex-direction:column;
    gap:5px;
    align-items:stretch;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-board-wrap{
    flex:1 1 auto;
    min-height:0;
    width:min(100%,calc(var(--bpcf-frame-height,100vh) - 235px));
    max-width:calc(100vw - 28px);
    margin:auto;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-board{
    gap:3px;
    padding:5px;
    border-radius:13px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-tray-section{
    flex:0 0 126px;
    height:126px;
    padding:5px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-tray-head{
    margin-bottom:3px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-tray{
    grid-template-columns:repeat(3,minmax(0,1fr));
    grid-template-rows:1fr;
    gap:4px;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-piece{
    padding:3px;
    gap:2px;
  }
  #gcg-game-root .bpcf-fullscreen-active .piece-grid{
    --mini:13px;
  }
  #gcg-game-root .bpcf-fullscreen-active .piece-label{
    font-size:7px;
  }
}

@media (max-height:620px) and (orientation:landscape){
  #gcg-game-root .bpcf-fullscreen-active .bpcf-hero{
    display:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-sidebar .bpcf-panel:nth-child(2){
    display:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-board-wrap{
    width:min(100%,calc(var(--bpcf-frame-height,100vh) - 82px));
  }
}

/* Exact fullscreen board sizing calculated from the live viewport. */
#gcg-game-root .bpcf-fullscreen-active .bpcf-board-wrap{
  width:var(--bpcf-board-size,min(100%,560px));
  height:var(--bpcf-board-size,min(100%,560px));
  max-width:100%;
  max-height:100%;
  aspect-ratio:1;
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-board{
  width:100%;
  height:100%;
  grid-template-rows:repeat(var(--grid-size),minmax(0,1fr));
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-cell{
  aspect-ratio:auto;
  min-width:0;
  min-height:0;
}
@media (max-height:620px) and (orientation:landscape){
  #gcg-game-root .bpcf-fullscreen-active .bpcf-board-head{
    display:none;
  }
  #gcg-game-root .bpcf-fullscreen-active .bpcf-forge-stage{
    flex:1 1 auto;
  }
}
#gcg-game-root .bpcf-fullscreen-active .bpcf-board-wrap{
  flex:0 0 var(--bpcf-board-size,min(100%,560px));
}
