/* AI analysis page layout and board refinements. */
/* AI analysis page reference layout */
body:not(:has(#authOverlay:not(.hidden))) .app-shell {
  background: #f7f4ed;
}

.workspace {
  max-width: none !important;
  display: grid;
  grid-template-areas:
    "nav nav nav"
    "left board analysis";
  align-items: start;
  gap: 22px 28px;
  padding: 0 28px 32px;
}

.topbar {
  grid-area: nav;
  min-height: 86px !important;
  display: grid !important;
  align-items: center !important;
  gap: 28px;
  margin: 0 -28px 4px !important;
  padding: 0 28px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(68, 88, 100, 0.18) !important;
  border-radius: 0 !important;
  background: rgba(255, 253, 248, 0.94) !important;
  box-shadow: none !important;
}

.analysis-brand {
  margin: 0 !important;
}

.analysis-brand img {
  width: 208px;
  max-height: 66px;
  display: block;
  object-fit: contain;
  object-position: left center;
}

.topbar > div:first-child p {
  display: none;
}

.topbar-actions {
  display: contents !important;
}

.topbar-primary-nav {
  justify-self: center;
  display: flex !important;
  gap: 38px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

.topbar-primary-nav button,
.topbar-actions .topbar-primary-nav button,
.topbar-actions .topbar-primary-nav button:nth-of-type(1),
.topbar-actions .topbar-primary-nav button:nth-of-type(2) {
  min-height: 86px !important;
  padding: 0 2px !important;
  border: 0 !important;
  border-bottom: 4px solid transparent !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #17231d !important;
  font-size: 18px !important;
  font-weight: 800 !important;
}

.topbar-primary-nav button.active,
.topbar-actions .topbar-primary-nav button.active,
.topbar-actions .topbar-primary-nav button.active:nth-of-type(1) {
  color: var(--brand-green) !important;
  border-bottom-color: var(--brand-green) !important;
  background: transparent !important;
  box-shadow: none !important;
}

.topbar-utility-actions {
  display: none !important;
}

.account-menu {
  justify-self: end;
}

.account-menu-button {
  min-height: 50px !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #17231d !important;
  font-size: 15px !important;
  font-weight: 900 !important;
}
#editorModeBtn {
  display: none !important;
}

.main-grid {
  display: contents !important;
}

.side-panel {
  grid-area: analysis;
  display: flex !important;
  flex-direction: column;
  align-self: start;
  min-width: 0;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

#analysisRightStack {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* board-panel: カードボックスを除去（DOM順=header→seekbar→board→tree を維持） */
.board-panel {
  grid-area: board;
  align-self: start;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* board-header: 幅制限・中央配置 */
.board-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: min(100%, 646px) !important;
  margin: 0 auto 10px !important;
}

.board-status-row,
.board-actions,
.board-hint,
#queueStatus {
  display: none !important;
}

.board-move-status {
  display: none !important;
}
.study-panel,
.editor-panel {
  grid-area: analysis;
}


.tab-guide {
  display: none !important;
}

.analysis-result-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 8px !important;
  color: #17231d;
  font-size: 22px !important;
  font-weight: 600 !important;
}

.analysis-result-title::before {
  content: "AI";
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 2px solid #2f86d5;
  border-radius: 7px;
  color: #2f86d5;
  font-family: var(--body-font);
  font-size: 14px;
  font-weight: 900;
}

.position-summary {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 0 !important;
  padding: 16px !important;
  border: 1px solid rgba(68, 88, 100, 0.16) !important;
  border-radius: 7px !important;
  background: #fff !important;
}

.position-summary div {
  border-right: 1px solid rgba(68, 88, 100, 0.12);
  text-align: center;
}
.position-summary div:last-child { border-right: 0; }
.position-summary dt { color: #53616b; font-size: 13px; }
.position-summary dd { color: #111814; font-size: 28px; font-weight: 600; }

.candidate-section {
  padding: 0 !important;
  border: 1px solid rgba(68, 88, 100, 0.16) !important;
  border-radius: 7px !important;
  background: #fff !important;
  overflow-x: hidden;
  overflow-y: visible;
}

.candidate-section h3 {
  margin: 0 !important;
  padding: 8px 28px 8px 10px !important;
  border-bottom: 1px solid rgba(68, 88, 100, 0.12);
  color: #17231d;
  font-size: 15px !important;
  font-weight: 700 !important;
}

.candidate-table-head {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 58px 54px 54px;
  min-width: 0;
  align-items: center;
  gap: 6px;
}

.candidate-table-head span:not(:first-child) {
  color: #53616b;
  font-size: 12px;
  font-weight: 500;
  text-align: right;
}

.candidate-list {
  display: block !important;
  min-width: 0;
  max-height: 230px;
  overflow-x: hidden;
  overflow-y: auto;
  gap: 0 !important;
}

.candidate-list-shell {
  display: grid;
  min-width: 0;
}

.candidate-list-top {
  max-height: none !important;
  overflow: visible !important;
}

.candidate-list-scroll {
  max-height: clamp(92px, 13vh, 110px);
  overflow-x: hidden;
  overflow-y: auto;
}

.candidate-list-scroll:empty {
  display: none !important;
}

#candidateTopList,
#candidateList {
  display: block !important;
  grid-template-columns: none !important;
  margin: 0 !important;
  padding-left: 0 !important;
  list-style: none !important;
}

.candidate-list li {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 58px 54px 54px;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 5px 10px !important;
  border-bottom: 1px solid rgba(68, 88, 100, 0.1) !important;
  border-radius: 0 !important;
  background: #fff !important;
}

.candidate-list li:last-child {
  border-bottom: 0 !important;
}


.candidate-list strong {
  display: grid !important;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 8px !important;
  row-gap: 2px;
  align-items: center;
  min-width: 0;
  color: #17231d;
  font-size: 14px;
  font-weight: 500 !important;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.candidate-move-text {
  color: inherit !important;
  font-size: inherit !important;
  margin: 0 !important;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.candidate-best-label {
  grid-column: 2;
  grid-row: 2;
  justify-self: start;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--brand-green);
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.candidate-metrics-row {
  display: contents !important;
  min-width: 0;
}

.candidate-rate,
.candidate-lead,
.candidate-complexity {
  color: #17231d !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  line-height: 1.2;
  margin: 0 !important;
  min-width: 0;
  overflow-wrap: anywhere;
  text-align: right;
  white-space: normal;
}



.game-review-panel.hidden {
  display: none !important;
}

.score-graph {
  min-height: 180px !important;
  grid-column: 1;
  padding: 14px !important;
  border: 1px solid rgba(68, 88, 100, 0.16);
  border-radius: 7px;
  background: #fff !important;
}

@media (max-width: 1180px) {
  .workspace {
    grid-template-columns: 1fr !important;
    grid-template-areas:
      "nav"
      "left"
      "board"
      "analysis";
  }

  .topbar {
    grid-template-columns: 1fr !important;
    height: auto;
    padding-top: 12px !important;
    padding-bottom: 12px !important;
  }

  .topbar-primary-nav {
    justify-self: start;
    flex-wrap: wrap;
  }
}

/* Keep displayed Go stones exactly on line intersections. */
.point > .stone,
.qa-stone,
.point > .last-move-ring,
.point > .candidate,
.point.star::after,
.qa-point.star::after {
  left: 50% !important;
  top: 50% !important;
  transform: translate(-50%, -50%) !important;
}

.auth-mini-board .stone,
.auth-mini-board .candidate-dot,
.auth-mini-board .star-point {
  left: calc(((var(--x) + 0.5) * 100%) / 19) !important;
  top: calc(((var(--y) + 0.5) * 100%) / 19) !important;
  transform: translate(-50%, -50%) !important;
}

/* Main AI board overlays are positioned against board intersections. */
.goban > .stone,
.goban > .last-move-ring,
.goban > .candidate {
  pointer-events: none;
  transform: translate(-50%, -50%) !important;
}

.goban > .stone {
  width: calc(97% / var(--board-size)) !important;
  height: calc(97% / var(--board-size)) !important;
  max-width: 44px;
  max-height: 44px;
}

.goban > .last-move-ring {
  width: calc(45% / var(--board-size)) !important;
  height: calc(45% / var(--board-size)) !important;
}

.goban > .candidate {
  width: calc(90% / var(--board-size)) !important;
  height: calc(90% / var(--board-size)) !important;
}

/* Keep the first-click confirmation stone above AI candidate evaluation labels. */
.goban > .stone.move-confirmation-stone {
  z-index: 7 !important;
}



.position-summary dd {
  font-size: 30px !important;
}

.candidate-list li {
  min-height: 32px !important;
}

/* この局面を質問するボタン */
.analysis-qa-section {
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 0;
}

#askQaWithPositionBtn.analysis-qa-action {
  display: block !important;
  width: 100% !important;
  min-height: 64px !important;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: #0f6842 !important;
  color: #fff !important;
  font-size: 20px !important;
  font-weight: 400 !important;
  box-shadow: 0 4px 0 rgba(22, 34, 42, 0.16), 0 8px 16px rgba(15, 104, 66, 0.20) !important;
  cursor: pointer !important;
}

#askQaWithPositionBtn.analysis-qa-action:hover {
  background: #0d5c3a !important;
}

#leftNav .analysis-left-qa-section {
  margin: 10px 0 2px;
}

#leftNav #askQaWithPositionBtn.analysis-qa-action {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 38px !important;
  padding: 7px 10px !important;
  border-radius: 7px !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  line-height: 1.4;
  box-shadow: 0 2px 0 rgba(22, 34, 42, 0.14), 0 5px 12px rgba(15, 104, 66, 0.16) !important;
}

#leftNav #askQaWithPositionBtn.analysis-qa-action svg {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
}

.analysis-header-search {
  justify-self: end;
  width: 320px;
  min-height: 38px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1px solid rgba(68, 88, 100, 0.22);
  border-radius: 8px;
  background: #fffdfa;
  color: #17231d;
}

.analysis-header-search input {
  min-width: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: #17231d;
  font: inherit;
  font-size: 14px;
  outline: none;
}

.analysis-header-search span {
  font-size: 24px;
  line-height: 1;
}

@media (max-width: 1180px) {
  .analysis-header-search {
    justify-self: start;
    width: min(100%, 360px);
  }
}

/* Keep header search compact so the user menu does not wrap. */
.analysis-header-search {
  width: clamp(210px, 19vw, 270px) !important;
  min-height: 40px !important;
  padding: 0 12px !important;
}

.analysis-header-search input {
  font-size: 13px !important;
}

.analysis-header-search span {
  font-size: 21px !important;
}

.account-menu,
.account-menu-button,
#accountMenuUser {
  white-space: nowrap !important;
}

.account-menu-button {
  min-width: max-content !important;
}

/* Left menu structure: AI analysis, SGF tools, editor entry. */
#editorModeBtn {
  display: flex !important;
  margin-top: 10px !important;
  border-top: 1px solid rgba(68, 88, 100, 0.14) !important;
  background: #fffdfa !important;
  color: #17231d !important;
}

#editorModeBtn.editor-menu-action {
  min-height: 56px !important;
}

#editorModeBtn.editor-menu-action::before {
  content: "";
}

/* Use stable inline SVG icons for move navigation. */
#firstMoveBtn::before,
#firstMoveBtn::after,
#prevMoveBtn::before,
#prevMoveBtn::after,
#nextMoveBtn::before,
#nextMoveBtn::after,
#lastMoveBtn::before,
#lastMoveBtn::after {
  content: none !important;
  display: none !important;
}

/* Keep the header search from pushing the user menu onto two lines. */
.topbar {
  grid-template-columns: 250px minmax(430px, 1fr) clamp(190px, 16vw, 235px) 44px max-content !important;
  gap: 18px !important;
}

.topbar-primary-nav {
  justify-self: center !important;
  gap: clamp(22px, 3vw, 38px) !important;
}

.analysis-header-search {
  justify-self: start !important;
  width: 100% !important;
  max-width: 235px !important;
  min-width: 190px !important;
}

.account-menu {
  justify-self: end !important;
  min-width: max-content !important;
}

.account-menu-button {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  white-space: nowrap !important;
  min-width: max-content !important;
  max-width: none !important;
}

#accountMenuUser {
  display: inline-block !important;
  max-width: 8.5em;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
  white-space: nowrap !important;
}
.candidate-section .candidate-table-head-main {
  grid-template-columns: minmax(0, 1fr) 58px 54px 54px;
  min-width: 0;
}

.candidate-section .candidate-list {
  min-width: 0;
}

.candidate-section .candidate-list li {
  grid-template-columns: minmax(0, 1fr) 58px 54px 54px;
}

.candidate-reload-btn {
  min-height: 24px;
  padding: 3px 8px;
  border: 1px solid rgba(15, 104, 66, 0.38);
  border-radius: 999px;
  background: #fff;
  color: #0f6842;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.candidate-reload-btn:hover {
  background: rgba(15, 104, 66, 0.08);
  border-color: #0f6842;
}
.candidate-head-main-label {
  display: inline-flex !important;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  min-width: 0;
}

/* ─── 横向き棋譜ツリー（シークバー下） ─── */
.game-tree-panel {
  display: block !important;
  width: min(100%, 646px);
  margin: 10px auto 0;
}

.board-panel .game-tree {
  max-height: 160px;
  overflow-x: auto;
  overflow-y: auto;
  overscroll-behavior-x: contain;
  overscroll-behavior-y: contain;
  touch-action: auto;
}

/* ─── 棋譜解析パネル (kap-panel) ─────────────────────────── */

body:not([data-mode="analysis"]) .result-panel.kap-panel {
  display: none;
}

/* 右バーUIとして再構成: .analysis-review-card スコープで上書きなし設計 */

.analysis-review-card.result-panel.kap-panel {
  display: block;
  padding: 0;
  gap: 0;
  overflow: visible;
  border: 1px solid rgba(68, 88, 100, 0.18);
  border-radius: 10px;
  background: #fffdfa;
  box-shadow: 0 2px 0 rgba(22, 34, 42, 0.08), 0 4px 12px rgba(31, 45, 55, 0.06);
}

/* ヘッダー */
.analysis-review-card .kap-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid rgba(68, 88, 100, 0.10);
}

.analysis-review-card .kap-header-icon {
  flex-shrink: 0;
  line-height: 0;
}

.analysis-review-card .kap-header-icon svg {
  width: 32px;
  height: 32px;
  display: block;
}

.analysis-review-card .kap-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #17231d;
}

/* 説明文 */
.analysis-review-card .kap-desc {
  margin: 0;
  padding: 12px 18px 14px;
  color: #53616b;
  font-size: 13px;
  line-height: 1.65;
}

/* グループ区切り線 */
.analysis-review-card .kap-divider {
  height: 1px;
  background: rgba(68, 88, 100, 0.09);
  margin: 0;
}

.analysis-review-card .kap-divider.kap-hidden {
  display: none;
}

/* グループ */
.analysis-review-card .kap-group {
  padding: 14px 18px;
}

.analysis-review-card .kap-group.kap-hidden {
  display: none;
}

.analysis-review-card .kap-group-label {
  display: block;
  margin-bottom: 10px;
  color: #17231d;
  font-size: 14px;
  font-weight: 700;
}

/* 総解析ボタン */
.analysis-review-card .kap-analyze-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}

.analysis-review-card .kap-analyze-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 9px !important;
  width: 100% !important;
  height: 48px !important;
  min-height: 48px !important;
  padding: 0 !important;
  border: none !important;
  border-radius: 10px !important;
  background: #0f6842 !important;
  color: #fff !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  cursor: pointer !important;
  box-shadow: 0 2px 0 rgba(15, 104, 66, 0.18), 0 4px 10px rgba(15, 104, 66, 0.18) !important;
  transition: background 0.15s !important;
}

.analysis-review-card .kap-analyze-btn:hover:not(:disabled) {
  background: #0d5c3a !important;
}

.analysis-review-card .kap-analyze-btn:disabled {
  background: rgba(68, 88, 100, 0.25) !important;
  box-shadow: none !important;
  cursor: not-allowed !important;
}

.analysis-review-card .kap-analyze-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.analysis-review-card .kap-cancel-btn {
  align-self: center;
  height: 30px !important;
  min-height: 30px !important;
  padding: 0 12px !important;
  border: 1px solid rgba(68, 88, 100, 0.22) !important;
  border-radius: 8px !important;
  background: #fff !important;
  color: #53616b !important;
  font-size: 12.5px !important;
  font-weight: 500 !important;
  cursor: pointer !important;
  box-shadow: none !important;
}

/* 解析対象カード */
.analysis-review-card .kap-target-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(15, 104, 66, 0.18);
  border-radius: 8px;
  background: rgba(15, 104, 66, 0.04);
  color: #233039;
  font-size: 13.5px;
  font-weight: 500;
}

.analysis-review-card .kap-target-card svg {
  flex-shrink: 0;
  width: 17px;
  height: 17px;
  color: #0f6842;
}

/* 区切りボタン */
.analysis-review-card .kap-range-btns {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
}

.analysis-review-card .kap-range-btn {
  height: 34px !important;
  min-height: 34px !important;
  padding: 0 12px !important;
  border: 1px solid rgba(68, 88, 100, 0.22) !important;
  border-radius: 8px !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #34444e !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: border-color 0.12s, color 0.12s, background 0.12s !important;
}

.analysis-review-card .kap-range-btn.active {
  border-color: #0f6842 !important;
  background: rgba(15, 104, 66, 0.08) !important;
  color: #0f6842 !important;
}

.analysis-review-card .kap-range-btn:hover:not(.active) {
  border-color: #0f6842 !important;
  color: #0f6842 !important;
}

/* 解析で表示するもの */
.analysis-review-card .kap-display-list {
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.analysis-review-card .kap-display-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border-bottom: 1px solid rgba(68, 88, 100, 0.08);
  cursor: pointer;
  transition: background 0.1s;
}

.analysis-review-card .kap-display-item:last-child {
  border-bottom: none;
}

.analysis-review-card .kap-display-item:hover {
  background: rgba(15, 104, 66, 0.04);
}

.analysis-review-card .kap-display-item svg {
  flex-shrink: 0;
  width: 17px;
  height: 17px;
  color: #5a6471;
}

.analysis-review-card .kap-display-item span {
  flex: 1;
  color: #233039;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
}

.analysis-review-card .kap-display-item input[type="checkbox"] {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  margin: 0;
  cursor: pointer;
  accent-color: #0f6842;
}

/* 未実行プレースホルダー */
.analysis-review-card .kap-empty {
  margin: 0;
  padding: 24px 18px 22px;
  text-align: center;
}

.analysis-review-card .kap-empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(15, 104, 66, 0.09);
  margin-bottom: 10px;
}

.analysis-review-card .kap-empty-icon svg {
  width: 22px;
  height: 22px;
  color: #0f6842;
}

.analysis-review-card .kap-empty-title {
  margin: 0 0 5px;
  color: #17231d;
  font-size: 13.5px;
  font-weight: 700;
}

.analysis-review-card .kap-empty-body {
  margin: 0;
  color: #53616b;
  font-size: 12.5px;
  line-height: 1.55;
}

/* ─── kap 解析後 (kap-post-section) ────────────────────── */

.analysis-review-card .kap-post-section {
  display: block;
}

.analysis-review-card .kap-result-badge-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(68, 88, 100, 0.09);
}

.analysis-review-card .kap-result-badge {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 10px;
  border: 1.5px solid #0f6842;
  border-radius: 6px;
  color: #0f6842;
  font-size: 12px;
  font-weight: 600;
}

.analysis-review-card .kap-reanalyze-btn {
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  margin-left: auto !important;
  height: 30px !important;
  padding: 0 11px !important;
  border: 1.5px solid rgba(15, 104, 66, 0.35) !important;
  border-radius: 7px !important;
  background: #fff !important;
  color: #0f6842 !important;
  font-size: 12.5px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  box-shadow: none !important;
  transition: border-color 0.12s, background 0.12s !important;
}

.analysis-review-card .kap-reanalyze-btn:hover {
  border-color: #0f6842 !important;
  background: rgba(15, 104, 66, 0.05) !important;
}

.analysis-review-card .kap-reanalyze-btn svg {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

/* 解析範囲ボタン */
.analysis-review-card .kap-result-range-btns {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.analysis-review-card .kap-result-range-btn {
  height: 32px !important;
  padding: 0 10px !important;
  border: 1px solid rgba(68, 88, 100, 0.20) !important;
  border-radius: 7px !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #34444e !important;
  font-size: 12.5px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: border-color 0.12s, background 0.12s, color 0.12s !important;
}

.analysis-review-card .kap-result-range-btn.active {
  border-color: transparent !important;
  background: #0f6842 !important;
  color: #fff !important;
}

.analysis-review-card .kap-result-range-btn:hover:not(.active) {
  border-color: #0f6842 !important;
  color: #0f6842 !important;
}

/* 形勢推移 */
.analysis-review-card .kap-result-th-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.analysis-review-card .kap-winrate-summary {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
}

.analysis-review-card .kap-wr-bar-wrap {
  width: 64px;
  height: 7px;
  background: #e0e3e8;
  border-radius: 4px;
  overflow: hidden;
}

.analysis-review-card .kap-wr-bar-black {
  height: 100%;
  background: #1a1a1a;
  border-radius: 4px;
}

.analysis-review-card .kap-wr-black { color: #1a1a1a; font-weight: 600; }
.analysis-review-card .kap-wr-white { color: #6a7480; font-weight: 500; }

.analysis-review-card .kap-score-graph-wrap {
  margin-top: 6px;
  overflow: hidden;
  border-radius: 6px;
}

.analysis-review-card .kap-score-graph {
  width: 100%;
  height: auto;
  display: block;
  cursor: crosshair;
  touch-action: manipulation;
}

.analysis-review-card .kap-score-graph:focus-visible {
  outline: 2px solid #1d6fd0;
  outline-offset: -2px;
}

.analysis-review-card .kap-score-graph-hint {
  margin: 5px 0 0;
  color: #738079;
  font-size: 11px;
  line-height: 1.4;
  text-align: center;
}

/* スコアグラフ SVG クラス */
.analysis-review-card .kap-graph-bg { fill: #f8fafc; }
.analysis-review-card .kap-graph-grid { stroke: #dde1e8; stroke-width: 0.5; }
.analysis-review-card .kap-graph-zero { stroke: #888e96; stroke-width: 1; }
.analysis-review-card .kap-graph-area-black { fill: rgba(29, 111, 208, 0.12); }
.analysis-review-card .kap-graph-area-white { fill: rgba(30, 180, 100, 0.12); }
.analysis-review-card .kap-graph-line { stroke: #1d6fd0; stroke-width: 1.6; fill: none; stroke-linejoin: round; stroke-linecap: round; }
.analysis-review-card .kap-graph-current-marker { pointer-events: none; }
.analysis-review-card .kap-graph-current-marker[hidden] { display: none; }
.analysis-review-card .kap-graph-current-line {
  stroke: #d97706;
  stroke-width: 1.5;
  stroke-dasharray: 4 3;
  vector-effect: non-scaling-stroke;
}
.analysis-review-card .kap-graph-current-dot {
  fill: #d97706;
  stroke: #fff;
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
}
.analysis-review-card .kap-graph-y-label { font-size: 9.5px; fill: #8a9299; text-anchor: end; }
.analysis-review-card .kap-graph-x-label { font-size: 9.5px; fill: #8a9299; text-anchor: middle; }
.analysis-review-card .kap-graph-side-label { font-size: 9.5px; font-weight: 600; }
.analysis-review-card .kap-black-label { fill: #1d6fd0; }
.analysis-review-card .kap-white-label { fill: #1eb86a; }
.analysis-review-card .kap-graph-empty { color: #8a9299; font-size: 13px; text-align: center; padding: 18px; margin: 0; }

/* 評価変動ランキング */
.analysis-review-card .kap-rank-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(68, 88, 100, 0.16);
  margin-bottom: 8px;
}

.analysis-review-card .kap-rank-tab {
  height: 38px !important;
  border: none !important;
  background: rgba(68, 88, 100, 0.06) !important;
  color: #34444e !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  transition: background 0.12s, color 0.12s !important;
}

.analysis-review-card .kap-rank-tab.active {
  background: #0f6842 !important;
  color: #fff !important;
}

.analysis-review-card .kap-rank-tab:hover:not(.active) {
  background: rgba(15, 104, 66, 0.08) !important;
  color: #0f6842 !important;
}

.analysis-review-card .kap-rank-list {
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
  overflow: hidden;
}

.analysis-review-card .kap-rank-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(68, 88, 100, 0.07);
}

.analysis-review-card .kap-rank-row:last-child { border-bottom: none; }

.analysis-review-card .kap-rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  color: #fff;
  font-size: 11.5px;
  font-weight: 700;
  flex-shrink: 0;
}

.analysis-review-card .kap-rank-gold { background: #c9960d; }
.analysis-review-card .kap-rank-silver { background: #7e8c98; }
.analysis-review-card .kap-rank-bronze { background: #a96c2b; }

.analysis-review-card .kap-rank-move {
  flex: 1;
  color: #233039;
  font-size: 13px;
  font-weight: 500;
}

.analysis-review-card .kap-rank-diff {
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}

.analysis-review-card .kap-diff-bad { color: #d32f2f; }
.analysis-review-card .kap-diff-good { color: #0f6842; }

.analysis-review-card .kap-open-move-btn {
  height: 28px !important;
  min-height: 28px !important;
  padding: 0 9px !important;
  border: 1px solid rgba(15, 104, 66, 0.30) !important;
  border-radius: 6px !important;
  background: #fff !important;
  color: #0f6842 !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  white-space: nowrap !important;
  flex-shrink: 0;
  box-shadow: none !important;
}

.analysis-review-card .kap-open-move-btn:hover {
  background: rgba(15, 104, 66, 0.06) !important;
  border-color: #0f6842 !important;
}

.analysis-review-card .kap-rank-empty {
  padding: 14px;
  text-align: center;
  color: #8a9299;
  font-size: 13px;
  margin: 0;
}

/* AI一致度 評価内訳テーブル */
.analysis-review-card .kap-mq-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.analysis-review-card .kap-mq-title-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.analysis-review-card .kap-mq-subtitle {
  color: #6a7480;
  font-size: 12px;
}

.analysis-review-card .kap-mq-table-outer {
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
  overflow: hidden;
}

.analysis-review-card .kap-mq-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 12px;
}

.analysis-review-card .kap-mq-th {
  padding: 7px 6px;
  background: rgba(68, 88, 100, 0.05);
  color: #34444e;
  font-weight: 600;
  font-size: 11.5px;
  border-bottom: 1px solid rgba(68, 88, 100, 0.10);
  white-space: nowrap;
}

.analysis-review-card .kap-mq-th-grade {
  width: 58px;
  text-align: left;
  padding-left: 10px;
}

.analysis-review-card .kap-mq-th-count {
  width: 44px;
  text-align: right;
  padding-right: 4px;
}

.analysis-review-card .kap-mq-th-ratio {
  text-align: left;
  padding-left: 4px;
}

.analysis-review-card .kap-mq-stone {
  width: 11px;
  height: 11px;
  vertical-align: middle;
  margin-right: 3px;
  flex-shrink: 0;
}

.analysis-review-card .kap-mq-row {
  border-bottom: 1px solid rgba(68, 88, 100, 0.07);
}

.analysis-review-card .kap-mq-row:last-child {
  border-bottom: none;
}

.analysis-review-card .kap-mq-td {
  padding: 6px 6px;
  vertical-align: middle;
  color: #233039;
}

.analysis-review-card .kap-mq-td-grade {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 500;
  padding-left: 8px;
  white-space: nowrap;
}

.analysis-review-card .kap-mq-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}

.analysis-review-card .kap-mq-td-count {
  text-align: right;
  font-size: 12.5px;
  font-weight: 700;
  padding-right: 4px;
  white-space: nowrap;
}

.analysis-review-card .kap-mq-td-ratio {
  padding-left: 4px;
}

.analysis-review-card .kap-mq-pct {
  display: block;
  font-size: 11px;
  color: #5a6471;
  white-space: nowrap;
  line-height: 1.2;
}

.analysis-review-card .kap-mq-bar-wrap {
  display: block;
  width: 100%;
  height: 5px;
  background: #e0e3e8;
  border-radius: 3px;
  overflow: hidden;
  margin-top: 2px;
}

.analysis-review-card .kap-mq-bar {
  display: block;
  height: 100%;
  border-radius: 3px;
  min-width: 0;
  max-width: 100%;
}

.analysis-review-card .kap-group-last {
  padding-bottom: 20px;
}

/* 総解析 v2: 形勢・候補比較・局所継続・6軸・終盤予算 */
.analysis-review-card .kap-display-item {
  cursor: default;
}

.analysis-review-card .kap-display-item small {
  flex-shrink: 0;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(15, 104, 66, 0.09);
  color: #0f6842;
  font-size: 10px;
  font-weight: 700;
}

.analysis-review-card .kap-analysis-warning {
  display: grid;
  gap: 3px;
  margin: 12px 18px 0;
  padding: 10px 12px;
  border: 1px solid rgba(194, 120, 3, 0.28);
  border-radius: 8px;
  background: #fff8e8;
  color: #6f4807;
  font-size: 12px;
  line-height: 1.5;
}

.analysis-review-card .kap-metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.analysis-review-card .kap-metric-card {
  display: grid;
  gap: 3px;
  padding: 10px 11px;
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
  background: #fff;
}

.analysis-review-card .kap-metric-card strong {
  color: #17231d;
  font-size: 19px;
}

.analysis-review-card .kap-metric-card small,
.analysis-review-card .kap-metric-label {
  color: #66727b;
  font-size: 11px;
}

.analysis-review-card .kap-band-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-top: 9px;
}

.analysis-review-card .kap-band-item {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 8px;
  border-radius: 7px;
  background: #f5f6f7;
  color: #52606a;
  font-size: 10.5px;
}

.analysis-review-card .kap-band-item strong {
  color: #25313a;
  white-space: nowrap;
}

.analysis-review-card .kap-section-note,
.analysis-review-card .kap-section-empty {
  margin: 0 0 9px;
  color: #69747d;
  font-size: 11px;
  line-height: 1.55;
}

.analysis-review-card .kap-section-empty {
  padding: 10px;
  border-radius: 7px;
  background: #f5f6f7;
}

.analysis-review-card .kap-detail-scroll {
  display: grid;
  gap: 7px;
  max-height: 430px;
  overflow-y: auto;
  padding-right: 3px;
  overscroll-behavior: contain;
}

.analysis-review-card .kap-comparison-row {
  padding: 9px;
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
  background: #fff;
}

.analysis-review-card .kap-comparison-head {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 7px;
  color: #243139;
  font-size: 11.5px;
}

.analysis-review-card .kap-comparison-head .kap-open-move-btn {
  margin-left: auto;
}

.analysis-review-card .kap-loss-pill {
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(204, 62, 62, 0.09);
  color: #a62e2e;
  font-size: 10px;
  font-weight: 700;
}

.analysis-review-card .kap-comparison-cells {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.analysis-review-card .kap-comparison-cells > div {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 7px;
  border-radius: 6px;
  background: #f6f7f7;
}

.analysis-review-card .kap-comparison-cells span,
.analysis-review-card .kap-comparison-cells small {
  overflow: hidden;
  color: #6a757d;
  font-size: 9.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analysis-review-card .kap-comparison-cells strong {
  color: #17231d;
  font-size: 14px;
}

.analysis-review-card .kap-mini-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.analysis-review-card .kap-mini-summary > span {
  padding: 5px 8px;
  border-radius: 999px;
  background: #eef1f1;
  color: #52606a;
  font-size: 10.5px;
}

.analysis-review-card .kap-continuation-row {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 5px 7px;
  padding: 8px 9px;
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
  background: #fff;
  color: #53616a;
  font-size: 10.5px;
}

.analysis-review-card .kap-continuation-row .kap-open-move-btn {
  justify-self: end;
}

.analysis-review-card .kap-move-index {
  color: #243139;
  font-weight: 700;
}

.analysis-review-card .kap-judgment-badge {
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 700;
  white-space: nowrap;
}

.analysis-review-card .kap-judgment-continue {
  background: rgba(37, 99, 235, 0.1);
  color: #2454b8;
}

.analysis-review-card .kap-judgment-tenuki {
  background: rgba(22, 163, 74, 0.1);
  color: #16763a;
}

.analysis-review-card .kap-judgment-uncertain {
  background: rgba(100, 116, 139, 0.11);
  color: #566372;
}

.analysis-review-card .kap-warning-text {
  grid-column: 1 / -1;
  color: #a15a08;
  font-size: 10px;
}

.analysis-review-card .kap-style-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.analysis-review-card .kap-style-card {
  min-width: 0;
  padding: 9px;
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
  background: #fff;
}

.analysis-review-card .kap-style-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 5px;
  margin-bottom: 8px;
}

.analysis-review-card .kap-style-title h4,
.analysis-review-card .kap-style-card h4 {
  margin: 0;
  color: #1f2c33;
  font-size: 12px;
}

.analysis-review-card .kap-style-title small {
  color: #707b82;
  font-size: 8.5px;
}

.analysis-review-card .kap-axis-row {
  margin-top: 7px;
}

.analysis-review-card .kap-axis-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px;
  color: #5e6971;
  font-size: 9px;
}

.analysis-review-card .kap-axis-heading > span {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  color: #26343b;
  font-weight: 700;
}

.analysis-review-card .kap-axis-heading > span small {
  color: #7a858c;
  font-size: 8px;
  font-weight: 500;
}

.analysis-review-card .kap-axis-heading strong {
  font-size: 9px;
}

.analysis-review-card .kap-axis-heading strong.positive {
  color: #177247;
}

.analysis-review-card .kap-axis-heading strong.negative {
  color: #b6533d;
}

.analysis-review-card .kap-axis-heading strong.neutral {
  color: #66737b;
}

.analysis-review-card .kap-tendency-meta {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin-top: 2px;
  color: #738087;
  font-size: 7.5px;
  line-height: 1.35;
}

.analysis-review-card .kap-tendency-meta span:last-child {
  text-align: right;
}

.analysis-review-card .kap-style-radar {
  margin: 2px 0 9px;
  padding: 5px 4px 6px;
  border: 1px solid rgba(68, 88, 100, 0.10);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(247, 250, 249, 0.82), #fff);
}

.analysis-review-card .kap-style-radar svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 250px;
  overflow: visible;
}

.analysis-review-card .kap-radar-grid polygon {
  fill: none;
  stroke: rgba(74, 91, 101, 0.16);
  stroke-width: 1;
}

.analysis-review-card .kap-radar-grid line {
  stroke: rgba(74, 91, 101, 0.13);
  stroke-width: 1;
}

.analysis-review-card .kap-radar-grid .kap-radar-human {
  fill: rgba(76, 102, 116, 0.035);
  stroke: #667983;
  stroke-width: 1.8;
  stroke-dasharray: 4 3;
}

.analysis-review-card .kap-radar-player {
  fill: rgba(28, 128, 87, 0.18);
  stroke: #1c8057;
  stroke-width: 2.2;
  stroke-linejoin: round;
}

.analysis-review-card .kap-style-radar-white .kap-radar-player {
  fill: rgba(45, 111, 191, 0.16);
  stroke: #2d6fbf;
}

.analysis-review-card .kap-radar-markers circle {
  fill: #fff;
  stroke: #1c8057;
  stroke-width: 1.8;
}

.analysis-review-card .kap-style-radar-white .kap-radar-markers circle {
  stroke: #2d6fbf;
}

.analysis-review-card .kap-radar-labels text {
  fill: #405058;
  font-size: 9px;
  font-weight: 650;
}

.analysis-review-card .kap-radar-scale text {
  fill: #859098;
  font-size: 7px;
}

.analysis-review-card .kap-radar-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 5px 10px;
  color: #66737b;
  font-size: 8px;
}

.analysis-review-card .kap-radar-legend span::before {
  display: inline-block;
  width: 12px;
  height: 3px;
  margin-right: 4px;
  border-radius: 2px;
  content: "";
  vertical-align: middle;
}

.analysis-review-card .kap-radar-legend .human::before {
  border-top: 2px dashed #667983;
}

.analysis-review-card .kap-radar-legend .player::before {
  background: #1c8057;
}

.analysis-review-card .kap-style-radar-white .kap-radar-legend .player::before {
  background: #2d6fbf;
}

.analysis-review-card .kap-radar-legend small {
  flex-basis: 100%;
  text-align: center;
  font-size: 7.5px;
}

.analysis-review-card .kap-radar-empty {
  margin: 4px 0 8px;
  padding: 12px;
  border-radius: 7px;
  background: rgba(100, 116, 139, 0.06);
  color: #6f7b82;
  font-size: 9px;
  text-align: center;
}

.analysis-review-card .kap-style-radar-compact {
  margin: 7px 0 6px;
  padding: 3px 2px 5px;
  background: #fbfcfc;
}

.analysis-review-card .kap-style-radar-compact svg {
  max-height: 205px;
}

.analysis-review-card .kap-style-radar-compact .kap-radar-labels text {
  font-size: 8.2px;
}

.analysis-review-card .kap-style-radar-compact .kap-radar-legend {
  gap: 4px 8px;
  font-size: 7.5px;
}

.analysis-review-card .kap-style-radar-compact .kap-radar-legend small {
  font-size: 7px;
}

.analysis-review-card .kap-style-diagnosis {
  margin: 0 0 9px;
  padding: 8px 9px;
  border-radius: 7px;
  background: rgba(26, 111, 77, 0.06);
  color: #40524a;
  font-size: 9px;
  line-height: 1.55;
}

.analysis-review-card .kap-style-diagnosis-muted {
  background: rgba(100, 116, 139, 0.07);
  color: #657179;
}

.analysis-review-card .kap-style-phase-details {
  margin-top: 10px;
  border: 1px solid rgba(68, 88, 100, 0.13);
  border-radius: 8px;
  background: #fff;
}

.analysis-review-card .kap-style-phase-details > summary {
  cursor: pointer;
  padding: 9px 11px;
  color: #2d4940;
  font-size: 10px;
  font-weight: 800;
}

.analysis-review-card .kap-style-phase-details[open] > summary {
  border-bottom: 1px solid rgba(68, 88, 100, 0.1);
}

.analysis-review-card .kap-style-phase-details > .kap-section-note {
  margin: 8px 10px;
}

.analysis-review-card .kap-style-phase-range-overview {
  margin: 8px 9px;
  padding: 8px;
  border: 1px solid rgba(44, 104, 78, 0.14);
  border-radius: 7px;
  background: rgba(28, 128, 87, 0.045);
}

.analysis-review-card .kap-style-phase-range-overview > h4 {
  margin: 0 0 6px;
  color: #29463a;
  font-size: 9px;
}

.analysis-review-card .kap-style-phase-range-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 5px;
}

.analysis-review-card .kap-style-phase-range-grid > div {
  min-width: 0;
  padding: 6px 4px;
  border-radius: 6px;
  background: #fff;
  text-align: center;
}

.analysis-review-card .kap-style-phase-range-grid span,
.analysis-review-card .kap-style-phase-range-grid strong {
  display: block;
}

.analysis-review-card .kap-style-phase-range-grid span {
  color: #68766f;
  font-size: 8px;
}

.analysis-review-card .kap-style-phase-range-grid strong {
  margin-top: 2px;
  color: #1f5e43;
  font-size: 9px;
}

.analysis-review-card .kap-style-phase-heatmaps {
  margin: 8px 9px;
  padding: 9px;
  border: 1px solid rgba(68, 88, 100, 0.13);
  border-radius: 8px;
  background: #f8faf9;
}

.analysis-review-card .kap-style-heatmap-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.analysis-review-card .kap-style-heatmap-heading > h4,
.analysis-review-card .kap-style-heatmap-panel > h4 {
  margin: 0;
  color: #29463a;
  font-size: 9px;
}

.analysis-review-card .kap-style-heatmap-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 3px 8px;
  color: #66737b;
  font-size: 7.5px;
}

.analysis-review-card .kap-style-heatmap-legend span::before {
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-right: 3px;
  border-radius: 2px;
  content: "";
  vertical-align: -1px;
}

.analysis-review-card .kap-style-heatmap-legend .negative::before {
  background: rgba(180, 80, 57, 0.58);
}

.analysis-review-card .kap-style-heatmap-legend .neutral::before {
  border: 1px solid rgba(100, 116, 139, 0.2);
  background: rgba(100, 116, 139, 0.08);
}

.analysis-review-card .kap-style-heatmap-legend .positive::before {
  background: rgba(27, 125, 83, 0.58);
}

.analysis-review-card .kap-style-heatmap-legend small {
  flex-basis: 100%;
  text-align: right;
  font-size: 7px;
}

.analysis-review-card .kap-style-heatmap-panels {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.analysis-review-card .kap-style-heatmap-panel {
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(68, 88, 100, 0.1);
  border-radius: 7px;
  background: #fff;
}

.analysis-review-card .kap-style-heatmap-scroll {
  margin-top: 6px;
  overflow-x: auto;
}

.analysis-review-card .kap-style-heatmap-grid {
  display: grid;
  grid-template-columns: minmax(58px, 0.9fr) repeat(6, minmax(43px, 1fr));
  gap: 3px;
  min-width: 365px;
}

.analysis-review-card .kap-style-heatmap-row {
  display: contents;
}

.analysis-review-card .kap-style-heatmap-corner,
.analysis-review-card .kap-style-heatmap-axis {
  display: flex;
  min-height: 25px;
  align-items: center;
  justify-content: center;
  padding: 3px;
  color: #62716a;
  font-size: 7px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}

.analysis-review-card .kap-style-heatmap-phase {
  display: flex;
  min-height: 34px;
  flex-direction: column;
  justify-content: center;
  padding: 4px 5px;
  border-radius: 5px;
  background: #f3f6f4;
}

.analysis-review-card .kap-style-heatmap-phase strong {
  color: #31483e;
  font-size: 8px;
}

.analysis-review-card .kap-style-heatmap-phase small {
  margin-top: 1px;
  color: #7a8580;
  font-size: 6.5px;
}

.analysis-review-card .kap-style-heatmap-cell {
  display: flex;
  min-height: 34px;
  align-items: baseline;
  justify-content: center;
  padding: 7px 2px 5px;
  border: 1px solid rgba(71, 91, 101, 0.08);
  border-radius: 5px;
  color: #4b585f;
  background: rgba(100, 116, 139, 0.08);
  font-variant-numeric: tabular-nums;
}

.analysis-review-card .kap-style-heatmap-cell strong {
  font-size: 9px;
}

.analysis-review-card .kap-style-heatmap-cell small {
  margin-left: 1px;
  font-size: 6px;
}

.analysis-review-card .kap-style-heatmap-cell.positive {
  color: #0d4e34;
  background: rgb(27 125 83 / var(--kap-heat-alpha));
}

.analysis-review-card .kap-style-heatmap-cell.negative {
  color: #743523;
  background: rgb(180 80 57 / var(--kap-heat-alpha));
}

.analysis-review-card .kap-style-heatmap-cell.unavailable {
  color: #9aa3a0;
  background: repeating-linear-gradient(
    135deg,
    rgba(100, 116, 139, 0.035),
    rgba(100, 116, 139, 0.035) 4px,
    rgba(100, 116, 139, 0.085) 4px,
    rgba(100, 116, 139, 0.085) 5px
  );
}

.analysis-review-card .kap-style-phase-numeric-details {
  margin: 0 9px 9px;
  border-top: 1px solid rgba(68, 88, 100, 0.1);
}

.analysis-review-card .kap-style-phase-numeric-details > summary {
  cursor: pointer;
  padding: 8px 1px;
  color: #53635c;
  font-size: 8px;
  font-weight: 700;
}

.analysis-review-card .kap-style-phase-list {
  display: grid;
  gap: 8px;
  padding: 0 0 1px;
}

.analysis-review-card .kap-style-phase-card {
  min-width: 0;
  padding: 8px;
  border-radius: 7px;
  background: #f7f9f8;
}

.analysis-review-card .kap-style-phase-card > h4,
.analysis-review-card .kap-style-phase-color > h5 {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px;
  margin: 0;
  color: #293c35;
  font-size: 10px;
}

.analysis-review-card .kap-style-phase-card > h4 small,
.analysis-review-card .kap-style-phase-color > h5 small {
  color: #77817d;
  font-size: 8px;
  font-weight: 500;
}

.analysis-review-card .kap-style-phase-colors {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 7px;
}

.analysis-review-card .kap-style-phase-color {
  min-width: 0;
  padding: 7px;
  border: 1px solid rgba(68, 88, 100, 0.1);
  border-radius: 6px;
  background: #fff;
}

.analysis-review-card .kap-style-phase-axis {
  display: grid;
  grid-template-columns: minmax(105px, 1fr) repeat(3, minmax(48px, auto));
  gap: 5px;
  align-items: baseline;
  margin-top: 5px;
  color: #68736e;
  font-size: 8px;
}

.analysis-review-card .kap-style-phase-axis > span {
  color: #405048;
}

.analysis-review-card .kap-style-phase-axis > strong {
  color: #236c4b;
}

@media (max-width: 720px) {
  .analysis-review-card .kap-style-grid,
  .analysis-review-card .kap-style-phase-colors,
  .analysis-review-card .kap-style-heatmap-panels {
    grid-template-columns: 1fr;
  }

  .analysis-review-card .kap-style-heatmap-heading {
    display: block;
  }

  .analysis-review-card .kap-style-heatmap-legend {
    justify-content: flex-start;
    margin-top: 5px;
  }

  .analysis-review-card .kap-style-heatmap-legend small {
    text-align: left;
  }

  .analysis-review-card .kap-style-phase-axis {
    grid-template-columns: minmax(90px, 1fr) repeat(3, minmax(44px, auto));
  }

  .analysis-review-card .kap-style-phase-range-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.analysis-review-card .kap-endgame-card {
  display: grid;
  gap: 5px;
  padding: 10px 11px;
  border: 1px solid rgba(15, 104, 66, 0.17);
  border-radius: 8px;
  background: rgba(15, 104, 66, 0.045);
}

.analysis-review-card .kap-endgame-card .kap-group-label {
  margin: 0;
  font-size: 11px;
}

.analysis-review-card .kap-endgame-card strong {
  color: #20342a;
  font-size: 12px;
}

.analysis-review-card .kap-endgame-card small {
  color: #607068;
  font-size: 10px;
  line-height: 1.45;
}

.analysis-review-card .kap-budget-table {
  margin-top: 8px;
  overflow: hidden;
  border: 1px solid rgba(68, 88, 100, 0.12);
  border-radius: 8px;
}

.analysis-review-card .kap-budget-phase-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 7px;
  padding: 7px 9px;
  border-bottom: 1px solid rgba(68, 88, 100, 0.08);
  color: #58646c;
  font-size: 10px;
}

.analysis-review-card .kap-budget-phase-row:last-child {
  border-bottom: none;
}

.analysis-review-card .kap-budget-phase-row strong {
  color: #253239;
  text-align: right;
}

@media (max-width: 760px) {
  .analysis-review-card .kap-style-grid,
  .analysis-review-card .kap-metric-grid {
    grid-template-columns: 1fr;
  }

  .analysis-review-card .kap-comparison-cells {
    grid-template-columns: 1fr;
  }
}
/* The Park watch popup keeps only the embedded study workspace. */
body.park-embed-study :is(.guest-footer,.analysis-workspace-nav-head,.analysis-workspace-sibling-link,.study-desktop-hero,.study-desktop-character-tip,#askQaWithPositionBtn),html.park-embed-study-root .site-boot-screen { display:none!important; }
body.park-embed-study .app-shell { margin-top:0!important; padding-top:8px!important; }
body.park-embed-study #leftNav :is(a[href^="/"],a[href^="https://"],a[href^="http://"]) { display:none!important; }

/* Dedicated standalone Go board. */
/* Design presets are scoped to this tool; the shared board and stone assets retain their colors. */
/* Standalone game-style board; shared board assets and other pages are unchanged. */
.standalone-go-board { margin:0; color:#f3ead0; background:radial-gradient(ellipse at 15% 0%,#16453655,transparent 52%),radial-gradient(ellipse at 100% 80%,#46603a33,transparent 50%),#041c19; font:15px/1.6 system-ui,sans-serif; }
.standalone-go-board * { box-sizing:border-box; }
.standalone-go-board .gb-shell { max-width:1500px; margin:auto; padding:14px 24px; }
.standalone-go-board .gb-header { display:flex; justify-content:space-between; align-items:center; gap:20px; margin-bottom:12px; flex-wrap:wrap; }
.standalone-go-board .gb-heading { display:flex; align-items:center; flex-wrap:wrap; gap:14px; }
.standalone-go-board h1,.standalone-go-board h2 { font-family:'Yu Mincho','Hiragino Mincho ProN',serif; font-weight:700; letter-spacing:.04em; }
.standalone-go-board h1 { font-size:34px; margin:0; }
.standalone-go-board h2 { font-size:25px; margin:0 0 16px; }
.standalone-go-board h3 { font-size:14px; margin:18px 0 8px; }
.standalone-go-board p { margin:8px 0; }
.standalone-go-board .gb-header-captures { font-size:13px; color:#c3c8b7; white-space:nowrap; }
.standalone-go-board .gb-move-status { padding:0 8px; color:#f3dda3; white-space:nowrap; font-size:13px; }
.standalone-go-board .gb-preview-label { position:absolute; width:1px; height:1px; margin:0; padding:0; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.standalone-go-board .gb-candidate[role=button] { cursor:pointer; border-radius:4px; padding:2px 3px; }
.standalone-go-board .gb-candidate[role=button]:is(:hover,:focus-visible) { background:#174c3a; outline:1px solid #80d3b3; outline-offset:1px; }
.standalone-go-board button,.standalone-go-board select { font:inherit; border:1px solid #ac9965; border-radius:7px; background:#16392f; color:#f3ead0; padding:10px 14px; min-height:44px; cursor:pointer; box-shadow:inset 0 1px 1px #f8e4ad24,0 2px 5px #0003; }
.standalone-go-board .gb-icon { display:block; width:24px; height:24px; flex:none; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; pointer-events:none; }
.standalone-go-board .gb-brand-mark { display:block; width:40px; height:40px; flex:none; fill:none; stroke:#e6c277; stroke-width:1.25; filter:drop-shadow(0 2px 3px #000); }
.standalone-go-board :is(#cameraOpen,#analyze,#reset,#sgfOpen,#export,.gb-navigation button) { display:inline-flex; align-items:center; justify-content:center; gap:10px; }
.standalone-go-board #modePlay .gb-icon { fill:#f5f2e8; stroke:#f5f2e8; width:22px; height:25px; }
.standalone-go-board #modeErase .gb-icon { width:25px; height:25px; }
.standalone-go-board .gb-header-captures { border-left:1px solid #a99363; padding-left:14px; }
.standalone-go-board button:hover { background:#164534; border-color:#dec585; }
.standalone-go-board button:disabled { opacity:.45; cursor:default; }
.standalone-go-board :is(button,select,textarea,input,summary):focus-visible { outline:3px solid #63e9ba; outline-offset:3px; }
.standalone-go-board .gb-primary { background:linear-gradient(135deg,#174d35,#063125 72%,#041e19); border-color:#e9d294; color:#ffe7ae; width:100%; box-shadow:inset 0 0 0 2px #163e31,inset 0 0 0 3px #e7d08c55,0 3px 7px #0005; font-weight:700; }
.standalone-go-board .gb-primary:hover { background:#0c7353; }
.standalone-go-board .gb-layout { display:grid; grid-template-columns:minmax(0,1fr) minmax(420px,.72fr); gap:18px; align-items:start; }
.standalone-go-board .gb-board-panel { min-width:0; }
.standalone-go-board .gb-board { width:min(100%,calc(100dvh - 185px)); margin:auto; background:linear-gradient(100deg,#deb77c40,#9a612610,#f5d59830),repeating-linear-gradient(90deg,#d8aa69 0%,#e1b777 .5%,#d5a668 .833333%,#ddb176 2%,#d9af71 4.166667%); border:0; border-radius:0; box-shadow:none; }
.standalone-go-board .gb-board svg { display:block; width:100%; height:auto; aspect-ratio:1; }
.standalone-go-board .gb-navigation,.standalone-go-board .gb-controls { display:flex; flex-wrap:wrap; gap:8px; }
.standalone-go-board .gb-navigation { align-items:center; justify-content:center; width:fit-content; max-width:100%; margin:12px auto 0; padding:7px; background:#08251e; border:1px solid #ad945e; border-radius:8px; }
.standalone-go-board .gb-navigation button { min-width:58px; color:#eed293; }
.standalone-go-board .gb-navigation .gb-icon { width:23px; height:23px; stroke-width:2.2; }
.standalone-go-board .gb-tools>.gb-navigation { width:100%;margin:0; }
.standalone-go-board .gb-tools>.gb-navigation button { flex:1;min-width:40px;padding:8px; }
.standalone-go-board .gb-tools { display:grid; gap:10px; min-width:0; }
.standalone-go-board .gb-tools section { min-width:0; background:radial-gradient(ellipse at 45% 0%,#28554125,transparent 65%),linear-gradient(145deg,#0b2c24,#031b17 80%); border:1px solid #c5ad75; border-radius:11px; padding:14px; }
.standalone-go-board label { display:grid; gap:5px; font-size:13px; }
.standalone-go-board .gb-position-controls { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr) clamp(54px,12%,80px) clamp(76px,16%,96px); gap:8px; align-items:end; }
.standalone-go-board .gb-position-controls label[hidden] { display:none; }
.standalone-go-board select { width:100%; min-width:0; }
.standalone-go-board :is(select,textarea,input) { color-scheme:dark; }
.standalone-go-board :is(option,optgroup) { color:#f3ead0;background-color:#0b3027; }
.standalone-go-board option:disabled { color:#a9bbad; }
.standalone-go-board .gb-reset-row { margin-top:8px; }
.standalone-go-board textarea { width:100%; resize:vertical; padding:10px; margin:8px 0 10px; font:13px/1.5 monospace; border:1px solid #8d815c; border-radius:5px; }
.standalone-go-board .gb-file { margin-bottom:8px; }
.standalone-go-board input[type=file] { max-width:100%; width:100%; font:12px system-ui,sans-serif; }
.standalone-go-board input[type=file]::file-selector-button { border:1px solid #8d815c; border-radius:5px; padding:10px; margin-right:6px; color:#f3ead0; background:#174032; cursor:pointer; }
.standalone-go-board .gb-help { font-size:12px; color:#adbfb1; }
.standalone-go-board .gb-error { color:#ff9690; }
.standalone-go-board #notice { margin:0; min-height:0; font-size:13px; line-height:16px; }
.standalone-go-board #notice:empty { display:none; }
.standalone-go-board #settingsOpen { display:inline-flex; align-items:center; justify-content:center; padding:10px; color:#eed293; }
.standalone-go-board .gb-settings { width:min(520px,calc(100vw - 24px)); max-height:calc(100dvh - 24px); margin:auto; padding:20px; border:1px solid #c5ad75; border-radius:12px; color:#f3ead0; background:linear-gradient(145deg,#10392e,#031b17); box-shadow:inset 0 0 0 4px #06251e,inset 0 0 0 5px #8a774d,0 16px 60px #0009; overflow:auto; }
.standalone-go-board .gb-settings::backdrop { background:#001611bb; backdrop-filter:blur(3px); }
.standalone-go-board .gb-settings header { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:12px; }
.standalone-go-board .gb-settings h2 { margin:0; }
.standalone-go-board .gb-settings fieldset { min-width:0; margin:0 0 14px; padding:12px; border:1px solid #8a774d; border-radius:8px; }
.standalone-go-board .gb-settings legend { padding:0 8px; color:#eed293; font-weight:700; }
.standalone-go-board .gb-settings label { margin:6px 0; }
.standalone-go-board .gb-settings .gb-setting-check { display:flex; justify-content:space-between; align-items:center; gap:12px; min-height:32px; cursor:pointer; }
.standalone-go-board .gb-settings input[type=checkbox] { width:20px; height:20px; flex-shrink:0; accent-color:#20b885; }
.standalone-go-board .gb-settings input[type=range] { width:100%; margin:8px 0 12px; accent-color:#20b885; }
.standalone-go-board .gb-settings footer { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; }
.standalone-go-board #settingsStatus { margin:0; color:#b8cdbf; font-size:12px; }
@media(max-width:760px) { .standalone-go-board #settingsOpen { flex:0 0 44px; } .standalone-go-board .gb-settings { padding:16px; } }
.standalone-go-board .gb-continuous-control { display:flex; align-items:center; gap:8px; margin:0 0 14px; }
.standalone-go-board .gb-continuous-control label { font-size:13px; }
.standalone-go-board .gb-continuous-control output { font-size:14px; min-width:30px; }
.standalone-go-board .gb-continuous-switch { width:76px; min-width:76px; height:36px; min-height:36px; padding:4px; border:1px solid #8d815c; border-radius:22px; background:#576d61; display:flex; align-items:center; cursor:pointer; }
.standalone-go-board .gb-continuous-switch[aria-checked=true] { background:#087853; }
.standalone-go-board .gb-switch-thumb { display:block; height:26px; width:26px; border-radius:50%; background:#f3ead0; box-shadow:0 1px 4px #0005; pointer-events:none; }
.standalone-go-board .gb-continuous-switch[aria-checked=true] .gb-switch-thumb { margin-left:auto; }
.standalone-go-board .gb-analysis-status { background:#0d3027; border-radius:5px; padding:5px 8px; font-size:12px; color:#b9d0bc; min-height:30px; }
.standalone-go-board #analysis { margin-top:0; overflow-wrap:anywhere; }
.standalone-go-board .gb-ranking-heading { display:flex; align-items:baseline; gap:6px; flex-wrap:wrap; margin-bottom:8px; }
.standalone-go-board .gb-ranking-heading h3 { margin:0; font-size:14px; white-space:nowrap; }
.standalone-go-board #analysisConditions { font-size:11px; color:#b8c4b4; line-height:1.25; overflow-wrap:anywhere; }
.standalone-go-board .gb-candidates { list-style:none; padding:0; margin:6px 0 0; }
.standalone-go-board .gb-candidate { display:flex; align-items:center; gap:7px; margin:4px 0; font-size:11px; line-height:1.3; }
.standalone-go-board .gb-candidate-rank { color:#092d23; display:grid; place-items:center; width:23px; height:23px; flex:none; border-radius:50%; background:radial-gradient(circle at 35% 25%,#fff0b3,#d7bf79 65%,#b49a52); font-weight:700; border:1px solid #e8da9c; box-shadow:0 0 0 2px #21604a,0 2px 5px #0006; }
.standalone-go-board .gb-candidate-move { font-weight:600; min-width:35px; }
.standalone-go-board .gb-candidate-value { margin-left:auto; color:#f3ead0; text-align:right; }
.standalone-go-board .gb-sgf-text { border-top:1px solid #776d48; padding-top:4px; margin-top:6px; }
.standalone-go-board summary { cursor:pointer; font-size:13px; padding:4px 0; }
.standalone-go-board .gb-camera { width:min(1120px,96vw); height:88dvh; max-height:92dvh; padding:16px; border:1px solid #d4b879; border-radius:11px; background:linear-gradient(145deg,#10392e,#031b17); color:#f3ead0; box-shadow:inset 0 0 0 4px #06251e,inset 0 0 0 5px #8a774d,0 16px 60px #0009; }
.standalone-go-board .gb-camera::backdrop,.standalone-go-board .gb-confirm::backdrop { background:#163329a8; }
.standalone-go-board .gb-camera header { display:flex; justify-content:space-between; align-items:center; gap:10px; }
.standalone-go-board .gb-camera[open] { display:flex;flex-direction:column;overflow:hidden; }
.standalone-go-board .gb-camera header { flex-shrink:0; }
.standalone-go-board .gb-camera header h2 { margin:0; }
.standalone-go-board .gb-camera iframe { display:block; width:100%; flex:1;min-height:0;height:auto;border:0; margin-top:12px; }
.standalone-go-board .gb-confirm { max-width:min(440px,94vw); padding:24px; border:1px solid #8d815c; border-radius:8px; color:#f3ead0; background:#082b25; }
.standalone-go-board .gb-confirm .gb-controls { justify-content:flex-end; margin-top:20px; }
.standalone-go-board [hidden] { display:none !important; }
.standalone-go-board .gb-tools section,.standalone-go-board .gb-navigation { box-shadow:inset 0 0 0 2px #031a15,inset 0 0 0 3px #c4aa7066,inset 0 1px 10px #eddb9d12,0 7px 20px #0006; }
.standalone-go-board h1,.standalone-go-board h2,.standalone-go-board h3 { color:#f3dda3; text-shadow:0 2px 3px #000; }
.standalone-go-board .gb-evaluation-badge { box-sizing:border-box;height:36px;padding:5px 12px;border:1px solid #ac9965;border-radius:6px;background:#0b3026;box-shadow:none;font:600 20px/24px system-ui,sans-serif;font-variant-numeric:tabular-nums;color:#ffe7ae;white-space:nowrap;text-shadow:none; }
.standalone-go-board .gb-ai-heading { display:flex; align-items:center; justify-content:space-between; gap:8px; flex-wrap:nowrap; }
.standalone-go-board .gb-ai-heading h2,.standalone-go-board .gb-continuous-control { margin-bottom:10px; }
.standalone-go-board .gb-analysis-grid { display:grid; grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr); gap:8px; margin-top:8px; }
.standalone-go-board .gb-analysis-grid>div { border:1px solid #796f4f; border-radius:6px; padding:8px; min-width:0; }
.standalone-go-board .gb-analysis-grid h3 { margin:0 0 10px; font-size:15px; }
.standalone-go-board #analysis>p { font-size:10px; line-height:1.25; margin:3px 0; }
.standalone-go-board .gb-winrate-meter { height:24px; margin:8px 0 6px; background:#f6f5f0; border:1px solid #e9d99b; border-radius:20px; overflow:hidden; box-shadow:0 2px 5px #0006; }
.standalone-go-board .gb-winrate-meter span { display:block; height:100%; background:linear-gradient(#292d2b,#010706); }
.standalone-go-board .gb-winrate-meter.gb-unanalysed { background:#344840; }
.standalone-go-board .gb-winrate-labels { display:grid; grid-template-columns:1fr auto 1fr; align-items:center; gap:6px; font-size:14px; font-variant-numeric:tabular-nums; }
.standalone-go-board .gb-mode-buttons { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:6px; margin-bottom:12px; }
.standalone-go-board .gb-mode-buttons button { padding:8px 5px; font-size:11px; display:flex; align-items:center; justify-content:center; gap:6px; }
.standalone-go-board .gb-mode-buttons [aria-pressed=true] { background:#176f50; border-color:#9cffe0; box-shadow:inset 0 0 0 2px #0c3e2e,inset 0 0 0 3px #58cb9e,0 0 9px #56e8ad77; }
.standalone-go-board .gb-mode-stone { width:24px; height:24px; border-radius:50%; display:inline-block; flex:none; background-position:center; background-size:contain; background-repeat:no-repeat; filter:drop-shadow(0 2px 2px #0006); }
.standalone-go-board .gb-black-stone { background-image:url('/assets/go-stones/black-stone.svg'); }
.standalone-go-board .gb-white-stone { background-image:url('/assets/go-stones/white-stone.svg'); }
.standalone-go-board .gb-tools section>h2 { margin-bottom:10px; }
.standalone-go-board .gb-tree-viewport { width:100%; height:160px; min-height:160px; overflow-x:auto; overflow-y:auto; overscroll-behavior-x:contain; overscroll-behavior-y:auto; border:1px solid #86794d; border-radius:6px; background:#031b16; margin-bottom:12px; }
.standalone-go-board .gb-tree-canvas { position:relative; }
.standalone-go-board .gb-tree-edge { position:absolute; border-top:2px solid #b39c5e; border-right:2px solid #b39c5e; pointer-events:none; }
.standalone-go-board .gb-tree-edge-up { border-top:0; border-bottom:2px solid #b39c5e; }
.standalone-go-board .tree-node { position:absolute; display:grid; place-items:center; width:22px; height:22px; min-height:0; padding:0; border:1px solid #887452; border-radius:50%; font:800 10px/1 system-ui,sans-serif; font-variant-numeric:tabular-nums; transform:translate(-50%,-50%); box-shadow:0 3px 7px #0005; z-index:1; }
.standalone-go-board .tree-node.black-node { border-color:#0f0f10; background:radial-gradient(circle at 34% 26%,#656668 0 6%,#303133 34%,#101112 76%,#050505 100%); color:#fff; }
.standalone-go-board .tree-node.white-node { border-color:#a79b96; background:radial-gradient(circle at 34% 26%,#fff 0 9%,#f6f4f1 40%,#e8e5e1 76%,#d5d0ca 100%); color:#4b2928; }
.standalone-go-board .tree-node.root-node { width:24px; height:24px; border-radius:8px; background:#fff3f2; color:#74433f; }
.standalone-go-board .tree-node.edit-node { border-radius:5px; background:#325646; color:#ffe3a0; }
.standalone-go-board .tree-node.current { z-index:5; outline:2px solid #ef6570; outline-offset:3px; box-shadow:0 0 0 5px #ef65701f,0 3px 8px #64363a33; }
.standalone-go-board .board-tree-current-label { position:absolute; top:calc(100% + 8px); left:50%; display:block; min-width:34px; padding:3px 6px; border-radius:7px; background:linear-gradient(135deg,#f47781,#e65b68); color:#fff; font:800 9px/1.1 'Yu Gothic',sans-serif; transform:translateX(-50%); pointer-events:none; }
.standalone-go-board .gb-ai-heading h2 { flex:none; font-size:24px; margin:0; }
.standalone-go-board .gb-ai-heading .gb-continuous-control { margin:0; }
.standalone-go-board .gb-ai-heading .gb-primary { width:auto; flex:1; white-space:nowrap; padding:8px; }
.standalone-go-board .gb-position-controls button { font-size:12px; padding:10px 6px; white-space:nowrap; flex-wrap:nowrap; }
.standalone-go-board #reset { gap:5px; }
.standalone-go-board #reset .gb-icon { width:20px;height:20px;flex-shrink:0; }
.standalone-go-board .gb-tree-card .gb-help { margin:4px 0 0; font-size:10px; }
.standalone-go-board .gb-tree-card h2 { margin:0 0 8px; }
.standalone-go-board .gb-tree-card .gb-tree-viewport { height:120px; margin-bottom:6px; }
.standalone-go-board .gb-tree-card .gb-file { display:block; font-size:11px; margin-bottom:4px; }
.standalone-go-board .gb-tree-card input[type=file] { width:auto; max-width:100%; font-size:10px; }
.standalone-go-board .gb-tree-card input[type=file]::file-selector-button { padding:6px; }
.standalone-go-board .gb-tree-card #export { padding:6px 12px; min-height:34px; font-size:12px; }
.standalone-go-board .gb-tree-heading { display:flex; align-items:center; justify-content:space-between; gap:8px; flex-wrap:wrap; margin-bottom:8px; }
.standalone-go-board .gb-tree-heading h2 { margin:0; font-size:23px; }
.standalone-go-board .gb-tree-heading button { min-height:36px; padding:6px 9px; font-size:11px; }
.standalone-go-board .gb-tree-heading .gb-icon { width:20px; height:20px; }
.standalone-go-board .tree-node::before { content:''; position:absolute; width:44px; height:44px; top:50%; left:50%; transform:translate(-50%,-50%); }
@media(max-width:760px) {
.standalone-go-board .gb-shell { padding:16px 12px; }
 .standalone-go-board .gb-header { flex-direction:column; align-items:stretch; gap:12px; margin-bottom:16px; }
 .standalone-go-board .gb-heading { gap:4px; display:block; }
 .standalone-go-board h1 { font-size:27px; }
 .standalone-go-board h2 { font-size:23px; }
 .standalone-go-board .gb-header-captures { display:block; font-size:12px; margin-top:2px; }
 .standalone-go-board .gb-header button { font-size:13px; min-height:40px; }
 .standalone-go-board .gb-layout { grid-template-columns:minmax(0,1fr); gap:10px; }
 .standalone-go-board .gb-analysis-grid { grid-template-columns:minmax(0,1fr); }
 .standalone-go-board .gb-board { width:100%; }
 .standalone-go-board .gb-navigation { width:100%; gap:5px; padding:5px; margin-top:12px; }
 .standalone-go-board .gb-move-status { width:100%; order:1; text-align:center; }
 .standalone-go-board .gb-navigation button { flex:1; min-width:0; padding:8px 6px; font-size:13px; }
 .standalone-go-board .gb-tools { gap:12px; }
 .standalone-go-board .gb-tools section { padding:16px; }
 .standalone-go-board .gb-ai-card h2 { margin-bottom:12px; }
 .standalone-go-board .gb-camera { width:100%; padding:8px; }
}
@media(max-width:1000px) and (min-width:761px) {
.standalone-go-board .gb-layout { grid-template-columns:minmax(0,1fr) minmax(320px,.8fr); } .standalone-go-board .gb-analysis-grid { grid-template-columns:1fr; }
}
@media(max-width:760px) {
.standalone-go-board .gb-header { flex-direction:row; } .standalone-go-board .gb-heading { width:100%; } .standalone-go-board .gb-evaluation-badge { font-size:20px; padding:2px 14px; } .standalone-go-board .gb-header button { flex:1; padding:8px; } .standalone-go-board .gb-layout { grid-template-columns:minmax(0,1fr); } .standalone-go-board .gb-board { width:100%; } .standalone-go-board .gb-mode-buttons { grid-template-columns:repeat(2,minmax(0,1fr)); } .standalone-go-board .gb-analysis-grid>div { padding:8px; } .standalone-go-board .gb-winrate-labels { font-size:12px; }
}
@media(max-width:1100px) {
.standalone-go-board .gb-ai-heading { flex-wrap:wrap; } .standalone-go-board .gb-ai-heading .gb-primary { flex-basis:100%; }
}
@media(max-width:760px) {
.standalone-go-board .gb-board { width:100%; } .standalone-go-board .gb-ai-heading .gb-primary { flex-basis:auto; } .standalone-go-board .gb-ai-heading h2 { font-size:22px; } .standalone-go-board .gb-tree-card .gb-tree-viewport { height:160px; }
}
@media(max-width:760px) {
.standalone-go-board .gb-shell { padding:12px; } .standalone-go-board .gb-tree-card .gb-tree-viewport { height:160px; } .standalone-go-board .gb-tree-heading { align-items:flex-start; }
.standalone-go-board .gb-heading { display:grid; grid-template-columns:34px minmax(0,1fr); column-gap:10px; }
.standalone-go-board .gb-brand-mark { width:32px; height:32px; grid-row:1 / 3; }
.standalone-go-board .gb-heading h1,.standalone-go-board .gb-header-captures { grid-column:2; }
.standalone-go-board .gb-header-captures { border:0; padding-left:0; }
.standalone-go-board .gb-tree-heading .gb-controls { gap:6px; }
.standalone-go-board .gb-tree-heading button { gap:5px; }
}

/* Light preset: ivory paper, pale wood and jade. */
.standalone-go-board[data-design-preset=light] { color:#263c35;background:#faf8f0; }
.standalone-go-board[data-design-preset=light] :is(h1,h2,h3) { color:#234f40;text-shadow:none; }
.standalone-go-board[data-design-preset=light] .gb-brand-mark { stroke:#658364;filter:none; }
.standalone-go-board[data-design-preset=light] :is(button:not(.tree-node),select,textarea,input) { color:#294c3f;background:#fffef9;border-color:#b4beaa;box-shadow:inset 0 1px 0 #fff,0 2px 4px #62725714;color-scheme:light; }
.standalone-go-board[data-design-preset=light] button:not(.tree-node):hover { background:#e3eee1;border-color:#719d83; }
.standalone-go-board[data-design-preset=light] :is(option,optgroup) { color:#294c3f;background:#fffdf7; }
.standalone-go-board[data-design-preset=light] option:disabled { color:#6c7b70; }
.standalone-go-board[data-design-preset=light] :is(button,select,textarea,input,summary):focus-visible { outline-color:#287b5d; }
.standalone-go-board[data-design-preset=light] :is(.gb-tools section,.gb-navigation) { background:linear-gradient(145deg,#fffef8,#f6f7ee);border-color:#b3bda4;box-shadow:inset 0 0 0 2px #fffdf5,inset 0 0 0 3px #bdc9b166,0 5px 15px #45604812; }
.standalone-go-board[data-design-preset=light] :is(.gb-header-captures,.gb-help,#analysisConditions,#settingsStatus) { color:#526b5a; }
.standalone-go-board[data-design-preset=light] .gb-header-captures { border-color:#b7bea9; }
.standalone-go-board[data-design-preset=light] :is(.gb-move-status,.gb-navigation button,#settingsOpen,.gb-candidate-value) { color:#294c3f; }
.standalone-go-board[data-design-preset=light] button.gb-primary { background:#39896b;border-color:#346f55;color:#fffdf1;box-shadow:inset 0 0 0 2px #ffffff22,0 3px 7px #38634622; }
.standalone-go-board[data-design-preset=light] button.gb-primary:hover { background:#215d45;color:#fffdf1; }
.standalone-go-board[data-design-preset=light] .gb-evaluation-badge { background:#eef3e9;color:#294c3f;border-color:#b4beaa;box-shadow:none;text-shadow:none; }

.standalone-go-board[data-design-preset=light] .gb-analysis-grid>div { border-color:#c3cbb8;background:#fffef855; }
.standalone-go-board[data-design-preset=light] .gb-analysis-status { background:#e9f0e3;color:#3f624f; }
.standalone-go-board[data-design-preset=light] .gb-winrate-meter { border-color:#9fab94;box-shadow:0 2px 4px #46574020; }
.standalone-go-board[data-design-preset=light] .gb-winrate-meter.gb-unanalysed { background:#c8d4bf; }
.standalone-go-board[data-design-preset=light] button.gb-continuous-switch { background:#c9d4bf;box-shadow:inset 0 1px 3px #61745433; }
.standalone-go-board[data-design-preset=light] button.gb-continuous-switch[aria-checked=true] { background:#2a8760; }
.standalone-go-board[data-design-preset=light] .gb-mode-buttons button[aria-pressed=true] { background:#e4f1dc;color:#1b5439;border-color:#559373;box-shadow:inset 0 0 0 2px #fff9,0 0 0 1px #7cae82,0 2px 7px #5e8c4d22; }
.standalone-go-board[data-design-preset=light] #modePlay .gb-icon { fill:currentColor;stroke:currentColor; }
.standalone-go-board[data-design-preset=light] .gb-candidate[role=button]:is(:hover,:focus-visible) { background:#deecd5;outline-color:#689e79; }
.standalone-go-board[data-design-preset=light] .gb-candidate-rank { box-shadow:0 0 0 2px #b6c7a7,0 2px 4px #52674322; }
.standalone-go-board[data-design-preset=light] .gb-tree-viewport { background:#f3f6eb;border-color:#b4bea4; }
.standalone-go-board[data-design-preset=light] .gb-tree-edge { border-color:#8aa276; }
.standalone-go-board[data-design-preset=light] .gb-sgf-text { border-color:#c0c8b1; }
.standalone-go-board[data-design-preset=light] :is(.gb-settings,.gb-camera,.gb-confirm) { color:#294c3f;background:linear-gradient(145deg,#fffdf6,#f1f4e7);border-color:#a8b68f;box-shadow:inset 0 0 0 4px #fffdf6,inset 0 0 0 5px #c2cbae,0 16px 60px #344c3940; }
.standalone-go-board[data-design-preset=light] :is(.gb-settings,.gb-camera,.gb-confirm)::backdrop { background:#3d504066; }
.standalone-go-board[data-design-preset=light] .gb-settings fieldset { border-color:#bcc7aa; }
.standalone-go-board[data-design-preset=light] .gb-settings legend { color:#2d6247; }
.standalone-go-board[data-design-preset=light] .gb-error { color:#a32c28; }
.standalone-go-board[data-design-preset=light] #login { color:#196640; }

/* Luminous game tree and contextual editing commands. */
.standalone-go-board .gb-tree-card .gb-tree-viewport { height:160px;background:radial-gradient(ellipse at 65% 0%,#14473433,transparent 75%),#031b16; }
.standalone-go-board .gb-tree-edge { height:0;border-top:2px solid #ddc17d;border-right:0;transform-origin:0 50%;box-shadow:0 0 4px #e5c77d55; }
.standalone-go-board .gb-tree-mainline { border-top-color:#59d6a2;box-shadow:0 0 5px #43d39b55; }
.standalone-go-board .gb-tree-edge.active-path { border-top-color:#62efb6;box-shadow:0 0 7px #52efb999; }
.standalone-go-board .tree-node { width:36px;height:36px;font-size:14px;border-color:#bfa56d;box-shadow:0 0 0 1px #d6c49433,0 3px 7px #0006; }
.standalone-go-board .tree-node.white-node { color:#222; }
.standalone-go-board .tree-node.root-node { width:27px;height:27px;font-size:11px; }
.standalone-go-board .tree-node.current { outline:3px solid #6ef5ba;outline-offset:4px;box-shadow:0 0 0 2px #2f7453,0 0 14px 6px #52eea955; }
.standalone-go-board .board-tree-current-label { top:-24px;min-width:80px;white-space:nowrap;padding:3px 9px;border-radius:6px;border:1px solid #6fce9b;background:linear-gradient(135deg,#164a35ee,#05271fee);color:#eaffed;font:600 11px/1.1 system-ui,sans-serif;box-shadow:0 0 7px #50e89944; }
.standalone-go-board .board-tree-current-label::after { content:'';position:absolute;left:50%;bottom:-5px;width:8px;height:8px;transform:translateX(-50%) rotate(45deg);background:#0b3426;border-right:1px solid #6fce9b;border-bottom:1px solid #6fce9b; }
.standalone-go-board .gb-context-menu { position:fixed;z-index:5000;display:grid;gap:3px;min-width:190px;max-width:calc(100vw - 16px);padding:6px;border:1px solid #a9c091;border-radius:9px;background:#082b23;box-shadow:0 9px 24px #0006; }
.standalone-go-board .gb-context-menu button { min-height:40px;text-align:left;padding:8px 12px;border:0;box-shadow:none;background:transparent; }
.standalone-go-board .gb-context-menu button:hover { background:#1a513d; }
.standalone-go-board[data-design-preset=light] .gb-tree-card .gb-tree-viewport { background:radial-gradient(ellipse at 65% 0%,#d7e8c944,transparent 75%),#f3f6eb; }
.standalone-go-board[data-design-preset=light] .gb-tree-edge { border-color:#b7a25d;box-shadow:0 0 3px #b7a25d33; }
.standalone-go-board[data-design-preset=light] .gb-tree-mainline { border-color:#69a880;box-shadow:0 0 4px #72b98a44; }
.standalone-go-board[data-design-preset=light] .gb-tree-edge.active-path { border-color:#35aa70;box-shadow:0 0 6px #3abf6b55; }
.standalone-go-board[data-design-preset=light] .tree-node.current { outline-color:#3ebd7c;box-shadow:0 0 0 2px #f2fff3,0 0 13px 5px #38c57155; }
.standalone-go-board[data-design-preset=light] .gb-context-menu { background:#fffdf5;border-color:#99b18b;box-shadow:0 9px 24px #49614533; }
.standalone-go-board[data-design-preset=light] .gb-context-menu button:hover { background:#e0eed7; }
.standalone-go-board .tree-node.root-node .board-tree-current-label { left:0;transform:none; }
.standalone-go-board .tree-node.root-node .board-tree-current-label::after { left:13px; }

.standalone-go-board .gb-operation-heading { display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin-bottom:10px; }
.standalone-go-board .gb-operation-heading h2 { margin:0; }
.standalone-go-board .gb-history-actions { display:flex;gap:6px; }
.standalone-go-board .gb-history-actions button { display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:34px;padding:6px 10px;font-size:12px; }
.standalone-go-board .gb-history-actions .gb-icon { width:18px;height:18px; }
@media(max-width:760px) {
 .standalone-go-board .gb-operation-heading { gap:6px; }
 .standalone-go-board .gb-tools>.gb-history-actions { justify-content:flex-end; }
 .standalone-go-board .gb-history-actions button { min-height:44px;padding:8px 14px;font-size:13px; }
}

/* Reserve room below the desktop board for move navigation. */
@media(min-width:1001px) {
 .standalone-go-board .gb-shell { display:flex;flex-direction:column;height:100dvh;max-width:none;padding:12px 16px; }
 .standalone-go-board .gb-layout { display:flex;flex:1;min-height:0;container-type:size;align-items:stretch; }
 .standalone-go-board .gb-board-panel { flex:1;min-width:0;min-height:0; }
 .standalone-go-board .gb-board { width:min(100%,calc(100cqh - 110px)); }
 .standalone-go-board .gb-tools { flex:0 0 620px;width:620px;min-width:0;min-height:0;overflow:auto;align-content:start;padding:2px; }
}

/* Usage plans reuse the settings dialog and both existing design presets. */
.standalone-go-board .gb-plans { width:min(740px,calc(100vw - 24px)); }
.standalone-go-board #plansDialog { --plan-ink:#fff5d9;--plan-muted:#bed0c2;--plan-gold:#efd28a;--plan-line:#7ba28a66;--plan-card:#031f1b88;box-sizing:border-box;width:min(820px,calc(100vw - 32px));max-width:none;max-height:calc(100dvh - 32px);padding:clamp(18px,2.5vw,28px);border:1px solid #7ba28a99;border-radius:18px;box-shadow:0 24px 90px #0008;background:linear-gradient(130deg,#0a332b,#031d19);color:var(--plan-ink);font-family:system-ui,-apple-system,"Noto Sans JP",sans-serif; }
.standalone-go-board #plansDialog header { position:static;margin:0 0 18px;padding:0;background:transparent; }
.standalone-go-board #plansDialog h2 { font-family:"Yu Mincho","Hiragino Mincho ProN",serif;font-size:clamp(22px,2.6vw,28px);font-weight:700;letter-spacing:.06em;line-height:1.5; }
.standalone-go-board #plansClose { display:grid;place-items:center;flex:none;width:44px;height:44px;min-height:44px;padding:0;border:1px solid var(--plan-line);border-radius:9px;font:32px/1 system-ui;color:var(--plan-ink);background:transparent; }
.standalone-go-board #plansDialog .gb-plan-icon { flex:none;width:25px;height:25px; }
.standalone-go-board #plansDialog .gb-plan-usage { display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:18px;padding:12px 14px;border:1px solid var(--plan-line);border-radius:9px;background:#2857441a; }
.standalone-go-board #plansDialog .gb-plan-usage-title { display:flex;align-items:center;gap:10px;white-space:nowrap;font-size:15px;font-weight:600; }
.standalone-go-board #plansDialog .gb-plan-usage-title small { display:block;max-width:160px;white-space:normal;margin-top:3px;color:var(--plan-muted);font-size:11px;font-weight:400; }
.standalone-go-board #plansDialog .gb-plan-usage-item { display:flex;align-items:center;gap:7px;min-width:0;padding-left:18px;border-left:1px solid var(--plan-line);font-size:14px;white-space:nowrap; }
.standalone-go-board #plansDialog .gb-plan-usage-item strong { color:var(--plan-gold);font-size:25px;font-variant-numeric:tabular-nums; }
.standalone-go-board #plansDialog .gb-plan-usage-item .gb-plan-icon { width:22px;height:22px; }
.standalone-go-board #plansDialog .gb-plan-message { margin:0 0 18px;color:var(--plan-gold);font-size:14px;line-height:1.7; }
.standalone-go-board #plansDialog .gb-plan-status-sr { position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap; }
.standalone-go-board #plansDialog .gb-plan-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px; }
.standalone-go-board #plansDialog .gb-plan-card { min-width:0;padding:20px;border:1px solid var(--plan-line);border-radius:14px;background:var(--plan-card); }
.standalone-go-board #plansDialog .gb-plan-card-paid { border:2px solid var(--plan-gold);padding:19px;background:linear-gradient(140deg,#315f4226,#08251e66); }
.standalone-go-board #plansDialog h3 { margin:0;font-size:clamp(19px,2vw,22px);font-weight:700;letter-spacing:.025em; }
.standalone-go-board #plansDialog .gb-plan-card-paid h3 { color:var(--plan-gold); }
.standalone-go-board #plansDialog .gb-plan-price { display:flex;align-items:baseline;flex-wrap:wrap;gap:12px;margin:12px 0 18px;line-height:1.2; }
.standalone-go-board #plansDialog .gb-plan-price strong { font-size:clamp(40px,4.5vw,50px);font-weight:750;letter-spacing:-.04em; }
.standalone-go-board #plansDialog .gb-plan-price span { font-size:15px;white-space:nowrap; }
.standalone-go-board #plansDialog .gb-plan-card ul { display:grid;gap:15px;list-style:none;margin:0;padding:18px 0 0;border-top:1px solid var(--plan-line); }
.standalone-go-board #plansDialog .gb-plan-card li { display:flex;align-items:center;gap:12px;margin:0;font-size:15px;line-height:1.6; }
.standalone-go-board #plansDialog .gb-plan-check { display:grid;place-items:center;flex:none;width:27px;height:27px;border-radius:50%;background:var(--plan-gold);color:#082b25; }
.standalone-go-board #plansDialog .gb-plan-check .gb-plan-icon { width:21px;height:21px;stroke-width:2.2; }
.standalone-go-board #plansDialog .gb-plan-join { display:flex;align-items:center;justify-content:center;width:100%;min-height:48px;margin-top:20px;padding:10px;border:1px solid #ffe2a0;border-radius:9px;background:#f4dd99;color:#082b25;font-size:16px;font-weight:750;box-shadow:0 3px 14px #0002;cursor:pointer; }
.standalone-go-board #plansDialog .gb-plan-join:hover { filter:brightness(1.07); }
.standalone-go-board #plansDialog :is(.gb-plan-join,#plansClose):focus-visible { outline:3px solid var(--plan-ink);outline-offset:4px; }
.standalone-go-board #plansDialog .gb-plan-login-hint { display:flex;align-items:center;justify-content:center;gap:8px;margin:10px 0 0;color:var(--plan-muted);font-size:12px;line-height:1.6; }
.standalone-go-board #plansDialog .gb-plan-login-hint .gb-plan-icon { width:15px;height:15px; }
.standalone-go-board #plansDialog .gb-plan-notes { margin-top:16px;text-align:center;color:var(--plan-muted);font-size:13px;line-height:1.8; }
.standalone-go-board #plansDialog .gb-plan-notes p { margin:2px 0; }
.standalone-go-board #plansDialog details { margin-top:8px; }
.standalone-go-board #plansDialog summary { cursor:pointer;text-underline-offset:3px; }
.standalone-go-board #plansDialog details[open] p { max-width:660px;margin:12px auto 0;text-align:left; }
.standalone-go-board[data-design-preset=light] #plansDialog { --plan-ink:#234b3b;--plan-muted:#476455;--plan-gold:#805c17;--plan-line:#8ea18b88;--plan-card:#fffef8;background:linear-gradient(135deg,#fffdf6,#f0f3e8);border-color:#a8b68f;box-shadow:0 24px 80px #344c3940; }
.standalone-go-board[data-design-preset=light] #plansDialog .gb-plan-card-paid { background:linear-gradient(140deg,#fff7df,#fffdf5); }
.standalone-go-board[data-design-preset=light] #plansDialog .gb-plan-check { background:#f1d38b; }
@media(max-width:760px) {
 .standalone-go-board #plansDialog { width:calc(100vw - 24px);max-height:calc(100dvh - 24px);padding:18px; }
 .standalone-go-board #plansDialog header { margin-bottom:18px;gap:8px; }
 .standalone-go-board #plansDialog h2 { font-size:22px;letter-spacing:.02em; }
 .standalone-go-board #plansDialog .gb-plan-usage { flex-wrap:wrap;gap:8px;padding:12px 14px; }
 .standalone-go-board #plansDialog .gb-plan-usage-title { width:100%;padding-bottom:3px; }
 .standalone-go-board #plansDialog .gb-plan-usage-item { width:100%;padding:6px 0 0;border-left:0;border-top:1px solid var(--plan-line); }
 .standalone-go-board #plansDialog .gb-plan-usage-item strong { margin-left:auto; }
 .standalone-go-board #plansDialog .gb-plan-grid { grid-template-columns:minmax(0,1fr);gap:16px; }
 .standalone-go-board #plansDialog .gb-plan-card { padding:18px; }
 .standalone-go-board #plansDialog .gb-plan-card-paid { padding:17px; }
 .standalone-go-board #plansDialog .gb-plan-card ul { gap:14px;padding-top:16px; }
 .standalone-go-board #plansDialog .gb-plan-card li { font-size:15px;gap:12px; }
 .standalone-go-board #plansDialog .gb-plan-join { font-size:17px; }
 .standalone-go-board #plansDialog .gb-plan-notes { font-size:12px; }
}

.standalone-go-board .gb-plans header { position:sticky;top:-20px;z-index:1;padding:8px 0;background:#082b25; }
.standalone-go-board[data-design-preset=light] .gb-plans header { background:#fffdf6; }
@media(max-width:760px) { .standalone-go-board .gb-plans header { top:-16px; } }

.standalone-go-board .gb-rewarded a { color:#9ce7d0;text-decoration:underline; }
.standalone-go-board[data-design-preset=light] .gb-rewarded a { color:#146347; }
.standalone-go-board #cameraAdStatus { min-height:1.6em;padding:12px 0; }
.standalone-go-board #cameraAdInfo { margin-top:12px;display:block; }

/* Keep related header actions together instead of distributing their gaps. */
.standalone-go-board .gb-header-actions { display:flex;align-items:center;justify-content:flex-end;gap:8px;margin-left:auto; }
.standalone-go-board .gb-header-actions button { flex:none;height:44px;min-height:44px;padding-block:8px;white-space:nowrap; }
.standalone-go-board .gb-header-actions #settingsOpen { width:44px;height:44px;padding:9px; }
@media(max-width:760px) {
 .standalone-go-board .gb-header { display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px 12px;align-items:center; }
 .standalone-go-board .gb-header .gb-heading { width:auto;min-width:0; }
 .standalone-go-board .gb-header h1 { font-size:clamp(18px,5vw,24px);white-space:nowrap; }
 .standalone-go-board .gb-header-captures { font-size:11px; }
 .standalone-go-board .gb-evaluation-badge { font-size:18px;padding-inline:10px; }
 .standalone-go-board .gb-header-actions { grid-column:1/-1;width:100%;margin-left:0; }
 .standalone-go-board .gb-header-actions #cameraOpen { flex:1;min-width:0; }
 .standalone-go-board .gb-header-actions #plansOpen { padding-inline:16px; }
}

/* Dedicated board: mobile position summary and shared touch zoom. */
.standalone-go-board .gb-mobile-evaluation,.standalone-go-board .gb-mobile-captures { display:none; }
.standalone-go-board .gb-board-viewport { overflow:hidden; }
.standalone-go-board .salon-board-pinch { transform-origin:0 0; }
.standalone-go-board .salon-board-zoom-reset { display:block;margin:6px auto; }
.standalone-go-board .salon-board-zoom-reset[hidden] { display:none; }
@media(max-width:760px) {
 .standalone-go-board .gb-header-captures,.standalone-go-board .gb-header>.gb-evaluation-badge,.standalone-go-board .gb-winrate-panel { display:none; }
 .standalone-go-board .gb-board-viewport { margin-inline:-10px; }
 .standalone-go-board .gb-mobile-evaluation { display:block;padding:0 8px 10px; }
 .standalone-go-board .gb-mobile-evaluation .gb-winrate-meter { height:18px;margin:0 0 7px; }
 .standalone-go-board .gb-mobile-evaluation-labels { display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:8px;font-size:13px;font-variant-numeric:tabular-nums; }
 .standalone-go-board .gb-mobile-evaluation-labels strong { color:inherit;font-size:20px; }
 .standalone-go-board .gb-mobile-evaluation-labels>span:last-child { text-align:right; }
 .standalone-go-board .gb-mobile-captures { display:flex;justify-content:space-between;padding:10px 12px;font-size:14px; }
 .standalone-go-board .gb-mobile-captures>span { display:flex;align-items:center;gap:8px; }
 .standalone-go-board .gb-mobile-captures .gb-mode-stone { width:20px;height:20px; }
 .standalone-go-board .gb-analysis-grid { grid-template-columns:minmax(0,1fr); }
 .standalone-go-board .gb-board.salon-board-pinch,.standalone-go-board .gb-board.salon-board-pinch * { touch-action:none; }
 .standalone-go-board .gb-heading { flex:1; }
 .standalone-go-board .gb-header { grid-template-columns:minmax(0,1fr); }
}

@media(max-width:760px) {
 .standalone-go-board[data-tap-zoom=false] .gb-board.salon-board-pinch[data-board-zoom="1"],
 .standalone-go-board[data-tap-zoom=false] .gb-board.salon-board-pinch[data-board-zoom="1"] * { touch-action:pan-y; }
}

/* Draw complete checkbox borders consistently across mobile browsers. */
.standalone-go-board .gb-settings input[type=checkbox] { appearance:none;-webkit-appearance:none;display:grid;place-content:center;box-sizing:border-box;padding:0;margin:0;border:1.5px solid #a9bcac;border-radius:4px;background:#092b23;box-shadow:none;cursor:pointer; }
.standalone-go-board .gb-settings input[type=checkbox]::before { content:"";width:5px;height:10px;border:solid #fff;border-width:0 2px 2px 0;transform:translateY(-1px) rotate(45deg);visibility:hidden; }
.standalone-go-board .gb-settings input[type=checkbox]:checked { background:#238460;border-color:#238460; }
.standalone-go-board .gb-settings input[type=checkbox]:checked::before { visibility:visible; }
.standalone-go-board[data-design-preset=light] .gb-settings input[type=checkbox] { background:#fffef9;border-color:#7c9684;box-shadow:none; }
.standalone-go-board[data-design-preset=light] .gb-settings input[type=checkbox]:checked { background:#238460;border-color:#238460; }

/* Settings concept: preview cards, grouped rows and direct choices. */
.standalone-go-board #settingsDialog { color-scheme:dark;--settings-paper:#09291f;--settings-card:#10382c;--settings-tint:#1c4537;--settings-line:#416053;--settings-muted:#b0c4b5;--settings-ink:#f0ead9;--settings-accent:#31795f;width:min(820px,calc(100vw - 24px));padding:24px;color:var(--settings-ink);background:var(--settings-paper);border:1px solid var(--settings-line);border-radius:16px;box-shadow:0 18px 70px #001c2940; }
.standalone-go-board[data-design-preset=light] #settingsDialog { color-scheme:light;--settings-paper:#faf8f1;--settings-card:#fffef9;--settings-tint:#edf0e5;--settings-line:#d9ddce;--settings-muted:#68796d;--settings-ink:#233e33;--settings-accent:#31795f; }
.standalone-go-board #settingsDialog .gb-settings-heading { position:sticky;top:-24px;z-index:2;margin:-24px -24px 20px;padding:22px 24px 16px;background:var(--settings-paper);border-bottom:1px solid var(--settings-line); }
.standalone-go-board #settingsDialog h2 { font-size:clamp(24px,4vw,34px);line-height:1.3;letter-spacing:.06em;color:var(--settings-ink); }
.standalone-go-board #settingsDialog .gb-settings-heading p { margin:6px 0 0;color:var(--settings-muted);font-size:14px;letter-spacing:.05em; }
.standalone-go-board #settingsDialog #settingsClose { display:grid;place-items:center;align-self:flex-start;width:44px;height:44px;padding:10px;border:0;background:transparent;box-shadow:none;color:var(--settings-ink); }
.standalone-go-board #settingsDialog .gb-setting-card { padding:0;margin:0 0 16px;border:1px solid var(--settings-line);border-radius:12px;background:var(--settings-card);box-shadow:0 2px 5px #122b1d05;overflow:hidden; }
.standalone-go-board #settingsDialog .gb-setting-card-heading { display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 18px;background:var(--settings-tint); }
.standalone-go-board #settingsDialog h3 { margin:0;font-size:21px;line-height:1.4;letter-spacing:.04em;color:var(--settings-ink); }
.standalone-go-board #settingsDialog .gb-setting-card-heading p { margin:0;font-size:12px;color:var(--settings-muted); }
.standalone-go-board #settingsDialog .gb-setting-card-content { padding:0 18px 12px; }
.standalone-go-board #settingsDialog .gb-help { margin:0;padding:8px 0 0;color:var(--settings-muted);font-size:12px;line-height:1.7; }
.standalone-go-board #settingsDialog .gb-setting-check,.standalone-go-board #settingsDialog .gb-setting-row { display:flex;align-items:center;justify-content:space-between;gap:20px;min-height:62px;margin:0;padding:12px 0;font-size:16px;border-bottom:1px solid var(--settings-line); }
.standalone-go-board #settingsDialog .gb-setting-check:last-child,.standalone-go-board #settingsDialog .gb-setting-row:last-child { border-bottom:0; }
.standalone-go-board #settingsDialog .gb-setting-row>label { margin:0; }
.standalone-go-board #settingsDialog .gb-setting-row>select { width:48%;min-width:0;margin:0;min-height:44px; }
.standalone-go-board #settingsDialog .gb-setting-row>div { flex:0 1 340px;min-width:0; }
.standalone-go-board #settingsDialog .gb-setting-segments { display:flex;min-width:0;border:1px solid var(--settings-line);border-radius:8px;overflow:hidden; }
.standalone-go-board #settingsDialog .gb-setting-segments button { flex:1;min-width:0;min-height:42px;padding:8px 12px;border:0;border-right:1px solid var(--settings-line);border-radius:0;background:transparent;box-shadow:none;color:var(--settings-ink);font-size:15px;white-space:nowrap; }
.standalone-go-board #settingsDialog .gb-setting-segments button:last-child { border-right:0; }
.standalone-go-board #settingsDialog .gb-setting-segments button[aria-pressed=true] { background:var(--settings-accent);color:#fff;box-shadow:inset 0 1px 2px #143e2b30; }
.standalone-go-board #settingsDialog .gb-zoom-options { display:flex;align-items:center;gap:10px; }
.standalone-go-board #settingsDialog .gb-zoom-options .gb-setting-segments { flex:1; }
.standalone-go-board #settingsDialog .gb-zoom-options button { padding-inline:9px; }
.standalone-go-board #settingsDialog .gb-design-options { display:grid;grid-template-columns:1fr 1fr;gap:14px;padding:16px; }
.standalone-go-board #settingsDialog .gb-design-option { position:relative;display:flex;align-items:center;justify-content:flex-start;gap:16px;min-width:0;padding:16px;border:2px solid transparent;border-radius:10px;box-shadow:inset 0 0 0 1px #869a8740;text-align:left;font-size:18px; }
.standalone-go-board #settingsDialog .gb-design-light { background:#faf7ec;color:#294c3f; }
.standalone-go-board #settingsDialog .gb-design-dark { background:linear-gradient(130deg,#183b2f,#102a23);color:#f0e9d0; }
.standalone-go-board #settingsDialog .gb-design-option[aria-pressed=true] { border-color:#398567;box-shadow:0 0 0 1px #39856722; }
.standalone-go-board #settingsDialog .gb-design-option i { display:none;position:absolute;right:8px;top:8px;place-items:center;width:24px;height:24px;border-radius:50%;font:700 16px system-ui;background:#398567;color:white; }
.standalone-go-board #settingsDialog .gb-design-option[aria-pressed=true] i { display:grid; }
.standalone-go-board #settingsDialog .gb-design-preview { flex:none;width:100px;height:100px;filter:drop-shadow(0 2px 3px #0002); }
.standalone-go-board #settingsDialog .gb-design-preview rect { fill:#dfb572;stroke:#c59958; }
.standalone-go-board #settingsDialog .gb-design-preview path { fill:none;stroke:#806034;stroke-width:.7; }
.standalone-go-board #settingsDialog .gb-design-dark .gb-design-preview rect { fill:#214334;stroke:#ad985e; }
.standalone-go-board #settingsDialog .gb-design-dark .gb-design-preview path { stroke:#bca268; }
.standalone-go-board #settingsDialog .gb-preview-black { fill:#17211e;stroke:#40524a;stroke-width:.7; }
.standalone-go-board #settingsDialog .gb-preview-white { fill:#fcfcf5;stroke:#bebfb3;stroke-width:.7; }
.standalone-go-board #settingsDialog input[type=checkbox] { width:24px;height:24px;border-radius:5px; }
.standalone-go-board #settingsDialog .gb-setting-volume { display:grid;grid-template-columns:auto minmax(0,1fr) auto auto;align-items:center;gap:16px;padding:14px 0 0; }
.standalone-go-board #settingsDialog .gb-setting-volume input { min-width:0;width:100%;margin:0;accent-color:#31795f; }
.standalone-go-board #settingsDialog .gb-setting-volume label { margin:0;font-size:16px; }
.standalone-go-board #settingsDialog .gb-setting-volume output { font-variant-numeric:tabular-nums;color:var(--settings-muted); }
.standalone-go-board #settingsDialog :is(#soundPreview,#kmSoundPreview) { display:flex;align-items:center;gap:7px;min-height:42px;padding:8px 12px;background:transparent;border:1px solid var(--settings-line);box-shadow:none;color:var(--settings-ink);white-space:nowrap; }
.standalone-go-board #settingsDialog .gb-settings-note { text-align:right; }
.standalone-go-board #settingsDialog footer { display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;margin-top:20px;padding-bottom:4px; }
.standalone-go-board #settingsDialog #settingsReset { padding:4px 0;min-height:40px;border:0;background:transparent;box-shadow:none;color:var(--settings-ink);text-decoration:underline;text-underline-offset:4px; }
.standalone-go-board #settingsDialog #settingsStatus { margin:0;font-size:12px;color:var(--settings-muted); }
@media(max-width:600px) {
 .standalone-go-board #settingsDialog { padding:14px;border-radius:12px; }
 .standalone-go-board #settingsDialog .gb-settings-heading { top:-14px;margin:-14px -14px 16px;padding:16px 14px 12px; }
 .standalone-go-board #settingsDialog .gb-setting-card-heading { padding:12px;flex-wrap:wrap;gap:3px; }
 .standalone-go-board #settingsDialog h3 { font-size:18px; }
 .standalone-go-board #settingsDialog .gb-setting-card-heading p { font-size:11px; }
 .standalone-go-board #settingsDialog .gb-setting-card-content { padding:0 12px 10px; }
 .standalone-go-board #settingsDialog .gb-setting-check,.standalone-go-board #settingsDialog .gb-setting-row { gap:12px;font-size:14px;min-height:56px; }
 .standalone-go-board #settingsDialog .gb-design-options { gap:8px;padding:12px; }
 .standalone-go-board #settingsDialog .gb-design-option { flex-direction:column;gap:10px;padding:14px 8px;font-size:14px;text-align:center; }
 .standalone-go-board #settingsDialog .gb-design-preview { width:76px;height:76px; }
 .standalone-go-board #settingsDialog .gb-setting-input-row { display:block; }
 .standalone-go-board #settingsDialog .gb-setting-input-row>div { margin-top:10px; }
 .standalone-go-board #settingsDialog .gb-setting-segments button { padding-inline:8px;font-size:14px; }
 .standalone-go-board #settingsDialog .gb-setting-volume { grid-template-columns:auto minmax(0,1fr) auto;gap:10px; }
 .standalone-go-board #settingsDialog :is(#soundPreview,#kmSoundPreview) { grid-column:2/-1;justify-self:end; }
 .standalone-go-board #settingsDialog .gb-settings-note { text-align:left; }
 .standalone-go-board #settingsDialog footer { display:block; }
 .standalone-go-board #settingsDialog #settingsStatus { margin-top:8px; }
}

.standalone-go-board #settingsDialog .gb-setting-segments button:focus-visible { position:relative;z-index:1;outline:3px solid #72b797;outline-offset:-4px; }
@media(max-width:380px) {
 .standalone-go-board #settingsDialog .gb-setting-row:not(.gb-setting-input-row) { display:block; }
 .standalone-go-board #settingsDialog .gb-setting-row>select { width:100%;margin-top:8px; }
}

.standalone-go-board #settingsDialog .gb-setting-segments button[aria-pressed=true] { font-weight:700;text-decoration:underline;text-underline-offset:4px;text-decoration-thickness:2px; }
@media(forced-colors:active) {
 .standalone-go-board #settingsDialog .gb-setting-segments button[aria-pressed=true],
 .standalone-go-board #settingsDialog .gb-design-option[aria-pressed=true] { outline:2px solid Highlight;outline-offset:-4px; }
}

.standalone-go-board .gb-winrate-labels>span { white-space:nowrap; }
.standalone-go-board .gb-winrate-labels>span:last-child { text-align:right; }
.standalone-go-board #desktopEvaluation { text-align:center;font-size:14px;white-space:nowrap; }

/* SGF import choices and text-first export share the existing dialog theme. */
.standalone-go-board .gb-sgf-dialog { width:min(640px,calc(100vw - 24px)); }
.standalone-go-board .gb-sgf-choices { display:flex;gap:10px;flex-wrap:wrap;margin:16px 0; }
.standalone-go-board .gb-sgf-choices button { flex:1;min-height:44px; }
.standalone-go-board .gb-sgf-dialog textarea { display:block;box-sizing:border-box;width:100%;min-height:180px;max-height:45dvh;resize:vertical;margin:8px 0 14px;padding:12px;font:13px/1.6 monospace;overflow-wrap:anywhere; }
.standalone-go-board .gb-sgf-dialog [role=alert]:empty { display:none; }

@media(max-width:760px) {
 .standalone-go-board .gb-camera { box-sizing:border-box;width:100vw;max-width:none;height:100dvh;max-height:100dvh;margin:0;padding:6px;border-radius:0; }
 .standalone-go-board .gb-camera iframe { margin-top:6px; }
}

/* Position history uses cached evaluations on the selected variation only. */
.standalone-go-board .gb-evaluation-history { margin-top:8px;padding-top:8px;border-top:1px solid #ad945c66; }
.standalone-go-board .gb-history-heading { display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap; }
.standalone-go-board .gb-history-heading h3 { margin:0; }
.standalone-go-board #historyCurrent { font-size:11px;color:#f0d48b;white-space:nowrap; }
.standalone-go-board .gb-history-chart { cursor:pointer; }
.standalone-go-board .gb-winrate-panel>#evaluationSource { display:none; }
.standalone-go-board .gb-candidate-panel .gb-candidate { min-height:34px;margin:2px 0; }
.standalone-go-board .gb-history-chart svg { display:block;width:100%;height:auto;overflow:visible; }
.standalone-go-board .gb-history-axis { font-size:12px;fill:#bacfc5; }
.standalone-go-board .gb-history-grid { stroke:#bacfc533;stroke-dasharray:3 4; }
.standalone-go-board .gb-history-zero { stroke:#bfa76a;stroke-width:1; }
.standalone-go-board .gb-history-segment { stroke:#67ddbc;stroke-width:2;stroke-linecap:round; }
.standalone-go-board .gb-history-dot { fill:transparent;stroke:none;cursor:pointer;pointer-events:all; }
.standalone-go-board .gb-history-dot.current { fill:#fff7dd;stroke:#ddbd72;stroke-width:2; }
.standalone-go-board .gb-history-dot:focus-visible { outline:none;stroke:#fff;stroke-width:4; }
.standalone-go-board .gb-history-cursor { stroke:#ddbd72;stroke-width:1;stroke-dasharray:3 3; }
.standalone-go-board .gb-history-legend { font-size:11px;color:#bacfc5;margin:4px 0 0; }
.standalone-go-board[data-design-preset=light] .gb-history-axis { fill:#49675b; }
.standalone-go-board[data-design-preset=light] .gb-history-legend { color:#49675b; }
.standalone-go-board[data-design-preset=light] #historyCurrent { color:#476339; }
.standalone-go-board[data-design-preset=light] .gb-history-segment { stroke:#28826a; }
.standalone-go-board[data-design-preset=light] .gb-history-dot:focus-visible { stroke:#176247;stroke-width:4; }
@media(max-width:760px) {
 .standalone-go-board .gb-winrate-panel { display:block; }
 .standalone-go-board .gb-winrate-panel>h3,.standalone-go-board .gb-winrate-panel>.gb-winrate-meter,.standalone-go-board .gb-winrate-panel>.gb-winrate-labels,.standalone-go-board .gb-winrate-panel>#evaluationSource { display:none; }
 .standalone-go-board .gb-evaluation-history { border-top:0;margin-top:0;padding-top:0; }
}

/* Landscape tablets reserve screen height for the board and scroll only the sidebar. */
@media(orientation:landscape) and (min-width:761px) and (max-width:1439px) {
 .standalone-go-board .gb-shell { display:flex;flex-direction:column;box-sizing:border-box;height:100dvh;max-width:none;padding:8px; }
 .standalone-go-board .gb-header { display:flex;flex-direction:row;flex-wrap:nowrap;align-items:center;gap:10px;margin-bottom:10px;min-width:0; }
 .standalone-go-board .gb-heading { display:flex;align-items:center;flex:none;gap:8px;width:auto;min-width:0;white-space:nowrap; }
 .standalone-go-board .gb-heading h1 { font-size:clamp(18px,2.3vw,29px);line-height:1.2;margin:0;white-space:nowrap; }
 .standalone-go-board .gb-brand-mark { width:30px;height:30px; }
 .standalone-go-board .gb-header-captures { display:inline;font-size:10px;padding-left:8px;white-space:nowrap; }
 .standalone-go-board .gb-header>.gb-evaluation-badge { display:block;flex:none;font-size:20px;line-height:24px;padding:5px 12px; }
 .standalone-go-board .gb-header-actions { display:flex;flex:none;gap:6px;width:auto;grid-column:auto;margin-left:auto; }
 .standalone-go-board .gb-header-actions button { min-height:38px;height:38px;padding:6px 10px;font-size:12px; }
 .standalone-go-board .gb-header-actions #settingsOpen { width:38px;height:38px;padding:8px; }
 .standalone-go-board .gb-header-actions .gb-icon { width:19px;height:19px; }
 .standalone-go-board .gb-layout { display:flex;flex:1;min-height:0;min-width:0;gap:8px;align-items:stretch;container-type:size; }
 .standalone-go-board .gb-board-panel { flex:1;min-width:0;min-height:0; }
 .standalone-go-board .gb-board { width:min(100%,calc(100cqh - 110px));margin:auto; }
 .standalone-go-board .gb-tools { flex:0 0 clamp(270px,30vw,360px);width:clamp(270px,30vw,360px);min-width:0;min-height:0;overflow:auto;align-content:start;padding:2px;gap:8px; }
 .standalone-go-board .gb-tools section { padding:10px; }
 .standalone-go-board .gb-tools h2 { font-size:19px; }
 .standalone-go-board .gb-ai-heading { flex-wrap:wrap;gap:6px; }
 .standalone-go-board .gb-ai-heading h2,.standalone-go-board .gb-continuous-control { margin-bottom:4px; }
 .standalone-go-board .gb-ai-heading .gb-primary { flex-basis:100%;min-height:38px; }
 .standalone-go-board .gb-analysis-grid { grid-template-columns:minmax(0,1fr); }
 .standalone-go-board .gb-mode-buttons { grid-template-columns:repeat(2,minmax(0,1fr)); }
 .standalone-go-board .gb-position-controls { gap:6px; }
 .standalone-go-board .gb-position-controls label { flex:1;min-width:0; }
 .standalone-go-board .gb-position-controls select { width:100%; }
 .standalone-go-board .gb-navigation { gap:4px;padding:6px;flex-wrap:wrap; }
 .standalone-go-board .gb-navigation button { min-width:30px;padding:6px; }
 .standalone-go-board .gb-navigation .gb-move-status { font-size:12px; }
 .standalone-go-board .gb-tree-heading { flex-wrap:wrap;gap:6px; }
 .standalone-go-board .gb-tree-heading .gb-controls { gap:6px; }
 .standalone-go-board .gb-tree-heading button { padding:6px 8px;font-size:11px; }
}

.standalone-go-board .gb-analysis-status.gb-error { color:#ff9690; }
.standalone-go-board[data-design-preset=light] .gb-analysis-status.gb-error { color:#a32c28; }

/* Keep the common-account entry compact beside the standalone board controls. */
.standalone-go-board .gb-header #accountOpen { max-width:110px;overflow:hidden;text-overflow:ellipsis; }
@media(max-width:760px) {
 .standalone-go-board .gb-header-actions { gap:6px; }
 .standalone-go-board .gb-header #accountOpen { max-width:90px;padding-inline:8px;font-size:12px; }
 .standalone-go-board .gb-header-actions #plansOpen { padding-inline:10px; }
 .standalone-go-board .gb-header-actions #cameraOpen { padding-inline:8px;font-size:12px;gap:5px; }
 .standalone-go-board .gb-header-actions #cameraOpen span { min-width:0;overflow:hidden;text-overflow:ellipsis; }
}

/* Put account access next to the board title, including the first mobile row. */
.standalone-go-board .gb-header #accountOpen { flex:none;min-height:38px;white-space:nowrap; }
@media(max-width:760px) {
 .standalone-go-board .gb-header { grid-template-columns:minmax(0,1fr) auto; }
 .standalone-go-board .gb-header>.gb-heading { grid-column:1;grid-row:1; }
 .standalone-go-board .gb-header>.gb-account { grid-column:2;grid-row:1; }
 .standalone-go-board .gb-header-actions { grid-row:2; }
}

/* On wide screens account access sits immediately before the camera controls. */
@media(min-width:761px) {
 .standalone-go-board .gb-header { column-gap:8px; }
 .standalone-go-board .gb-header>.gb-heading { order:0; }
 .standalone-go-board .gb-header>.gb-evaluation-badge { order:1; }
 .standalone-go-board .gb-header>.gb-account { order:2;margin-left:auto; }
 .standalone-go-board .gb-header>.gb-header-actions { order:3;margin-left:0; }
}

/* Captures and edit history share one compact mobile row. */
@media(max-width:760px) {
 .standalone-go-board .gb-mobile-captures { align-items:center;flex-wrap:nowrap;gap:6px;padding:8px 4px;font-size:12px; }
 .standalone-go-board .gb-mobile-captures>span { flex:none;gap:4px;white-space:nowrap; }
 .standalone-go-board .gb-mobile-captures>span:first-child { order:0; }
 .standalone-go-board .gb-mobile-captures>.gb-history-actions { order:1;flex:none;gap:4px; }
 .standalone-go-board .gb-mobile-captures>span:last-of-type { order:2; }
 .standalone-go-board .gb-mobile-captures .gb-history-actions button { min-height:40px;padding:6px;font-size:11px;gap:3px;white-space:nowrap; }
 .standalone-go-board .gb-mobile-captures .gb-history-actions .gb-icon { width:16px;height:16px; }
 .standalone-go-board .gb-mobile-captures .gb-mode-stone { width:18px;height:18px; }
}

/* Playback matches the Apple board: buttons above the position and seek slider. */
.standalone-go-board #webNavigation { display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) minmax(104px,1.4fr) minmax(0,1fr) minmax(0,1fr);width:100%;gap:6px;margin:0;padding:0;border:0;border-radius:0;background:transparent;box-shadow:none;box-sizing:border-box; }
.standalone-go-board #webNavigation button { min-width:0;padding:8px; }

.standalone-go-board #webNavigationHome:empty,.standalone-go-board #webNavigationSlot:empty { display:none; }
.standalone-go-board #webNavigation .gb-seek-row { grid-column:1/-1;grid-row:2;display:flex;align-items:center;gap:14px;min-width:0;padding:2px 12px;box-sizing:border-box; }
.standalone-go-board #webNavigation .gb-move-status { width:auto;order:0;flex:none;white-space:nowrap;font-size:15px;text-align:left; }
.standalone-go-board #webMoveSeek { display:block;flex:1;min-width:0;width:100%;min-height:44px;margin:0;accent-color:#d5b571;touch-action:pan-y; }
.standalone-go-board[data-design-preset=light] #webMoveSeek { accent-color:#32735e; }
@media(max-width:760px) {
 .standalone-go-board #webNavigationSlot { padding:0 0 8px; }
}

.standalone-go-board #boardPurchaseDialog [hidden] { display:none!important; }
.standalone-go-board #boardLoginForm label { display:grid;gap:6px;margin:16px 0; }
.standalone-go-board #boardLoginForm input { width:100%;box-sizing:border-box;min-height:44px;font-size:16px; }
.standalone-go-board #boardPurchaseDialog a { color:inherit;text-decoration:underline; }
.standalone-go-board #boardPurchaseDialog button { min-height:44px;margin-top:10px; }
.standalone-go-board #boardPurchaseAgreeRow { display:flex;gap:10px;align-items:flex-start;font-size:13px;line-height:1.7;cursor:pointer; }
.standalone-go-board #boardPurchaseAgreeRow input { flex:none;width:20px;height:20px;margin:1px 0 0;accent-color:#cba65c; }

.standalone-go-board #boardPurchaseClose { flex-shrink:0;white-space:nowrap; }

/* 上部ログインは検討盤内の専用画面で完結する。 */
.standalone-go-board #boardPurchaseDialog.gb-login-only { box-sizing:border-box;width:min(460px,calc(100vw - 28px));padding:28px;border-radius:16px;box-shadow:0 18px 70px #0007; }
.standalone-go-board #boardPurchaseDialog.gb-login-only header { position:static;margin-bottom:20px;padding:0;background:transparent; }
.standalone-go-board #boardPurchaseDialog.gb-login-only h2 { font-size:23px;line-height:1.5; }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardPurchaseStatus { font-size:14px;line-height:1.8; }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardLoginForm label { font-size:14px;gap:8px; }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardLoginForm input { min-height:46px;padding:10px 12px;border-radius:8px; }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardLoginSubmit { width:100%;min-height:48px;margin-top:8px;border:1px solid #ffe1a1;border-radius:8px;background:#f4dd99;color:#082b25;font-size:16px;font-weight:700; }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardLoginForm p { font-size:13px;line-height:1.9; }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardLoginForm p:first-child { display:grid;gap:8px; }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardLoginForm p:first-child:has(#boardLogingoogle[hidden]):has(#boardLoginline[hidden]):has(#boardLoginx[hidden]) { display:none; }
.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers { display:grid;gap:12px; }
.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers a:not([hidden]) { display:flex;align-items:center;justify-content:center;gap:12px;min-height:48px;padding:10px 16px;border:1px solid #747775;border-radius:8px;box-sizing:border-box;text-decoration:none;font:600 16px/1.4 Arial,sans-serif;background:#fff;color:#1f1f1f; }
.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers .gb-login-line:not([hidden]) { background:#06c755;color:#fff;border-color:#06c755; }
.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers img { flex-shrink:0;object-fit:contain; }
.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers a:focus-visible { outline:3px solid #187bba;outline-offset:3px; }
.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers a:hover { filter:brightness(.94); }
.standalone-go-board #boardPurchaseDialog.gb-login-only #boardPurchaseRetry { font-size:12px; }
@media(max-width:480px) { .standalone-go-board #boardPurchaseDialog.gb-login-only { padding:22px; } .standalone-go-board #boardPurchaseDialog.gb-login-only h2 { font-size:21px; } }

/* アカウントの入口はページ移動ではなくメニューを開閉する。 */
.standalone-go-board .gb-account { position:relative;flex:none;min-width:0;z-index:30; }
.standalone-go-board .gb-header #accountOpen { display:grid;place-items:center;width:44px;min-width:44px;height:44px;padding:8px;border-radius:50%; }
.standalone-go-board .gb-header #accountOpen { padding:3px;overflow:hidden; }
.standalone-go-board #accountOpen .gb-account-icon { display:block;width:26px;height:26px; }
.standalone-go-board #accountOpen img { width:36px;height:36px;border-radius:50%;object-fit:cover; }
.standalone-go-board #accountInitial { font:600 20px/1 system-ui; }
.standalone-go-board #accountOpen [hidden] { display:none!important; }
.standalone-go-board .gb-account-menu { position:absolute;right:0;top:calc(100% + 8px);width:min(260px,calc(100vw - 28px));max-height:min(420px,calc(100dvh - 96px));overflow-y:auto;box-sizing:border-box;padding:9px;border:1px solid #779783;border-radius:10px;background:#0a2e25;color:#f3ead0;box-shadow:0 14px 35px #0006; }
.standalone-go-board .gb-account-menu[hidden],.standalone-go-board .gb-account-menu [hidden] { display:none!important; }
.standalone-go-board .gb-account-menu strong { display:block;padding:9px 10px 12px;overflow-wrap:anywhere;border-bottom:1px solid #77978366;font-size:14px; }
.standalone-go-board .gb-account-menu :is(a,button) { display:flex;align-items:center;width:100%;min-height:44px;padding:10px;border:0;border-radius:6px;background:transparent;color:inherit;font:14px/1.5 system-ui;text-decoration:none;text-align:left;cursor:pointer; }
.standalone-go-board .gb-account-menu :is(a,button):hover { background:#47795d55; }
.standalone-go-board .gb-account-menu :is(a,button):focus-visible { outline:2px solid #efd28a;outline-offset:0; }
.standalone-go-board .gb-account-menu #accountLogout { color:#f2bf9f; }
.standalone-go-board[data-design-preset=light] .gb-account-menu { background:#fffdf6;color:#294c3f;border-color:#b4c5ac;box-shadow:0 12px 32px #294c3f33; }
.standalone-go-board[data-design-preset=light] .gb-account-menu #accountLogout { color:#9a4035; }

/* 購入条件と同意を有料プランの中にまとめ、確認ダイアログを挟まない。 */
.standalone-go-board #plansDialog .gb-plan-grid { align-items:stretch; }
.standalone-go-board #plansDialog .gb-plan-purchase { margin-top:18px;padding-top:16px;border-top:1px solid var(--plan-line);font-size:12px;line-height:1.75; }
.standalone-go-board #plansDialog .gb-plan-purchase h4 { margin:10px 0;font-size:14px;color:var(--plan-gold); }
.standalone-go-board #plansDialog .gb-plan-renewal { margin:0;color:var(--plan-muted); }
.standalone-go-board #plansDialog .gb-purchase-facts { margin:0 0 12px; }
.standalone-go-board #plansDialog .gb-purchase-facts>div { display:grid;grid-template-columns:90px minmax(0,1fr);gap:8px;padding:6px 0;border-bottom:1px solid var(--plan-line); }
.standalone-go-board #plansDialog .gb-purchase-facts dt { color:var(--plan-muted); }
.standalone-go-board #plansDialog .gb-purchase-facts dd { margin:0;overflow-wrap:anywhere; }
.standalone-go-board #plansDialog .gb-purchase-details { border:1px solid var(--plan-line);border-radius:8px;padding:9px 11px; }
.standalone-go-board #plansDialog .gb-purchase-details summary { line-height:1.8; }
.standalone-go-board #plansDialog .gb-purchase-details>div { max-height:220px;overflow:auto;overscroll-behavior:contain; }
.standalone-go-board #plansDialog .gb-purchase-details p { margin:10px 0;max-width:none;line-height:1.8; }
.standalone-go-board #plansDialog .gb-purchase-links { display:flex;flex-wrap:wrap;gap:8px 14px;margin:12px 0; }
.standalone-go-board #plansDialog .gb-purchase-links a { color:inherit;text-underline-offset:3px; }
.standalone-go-board #plansDialog #planPurchaseStatus { margin:10px 0;color:var(--plan-gold);font-size:13px; }
.standalone-go-board #plansDialog #planPurchaseStatus:empty { display:none; }
.standalone-go-board #plansDialog .gb-plan-join { margin-top:14px; }
.standalone-go-board #plansDialog .gb-plan-join:disabled { opacity:.6;cursor:wait; }
@media(max-width:650px) {
 .standalone-go-board #plansDialog .gb-plan-card-paid { order:-1; }
 .standalone-go-board #plansDialog .gb-purchase-facts>div { grid-template-columns:84px minmax(0,1fr); }
}

.standalone-go-board #plansDialog .gb-plan-card ul { gap:10px;padding-top:14px; }
.standalone-go-board #plansDialog .gb-plan-card li { min-height:28px;font-size:14px; }
.standalone-go-board #plansDialog .gb-plan-card-paid .gb-plan-check { width:24px;height:24px; }
.standalone-go-board #plansDialog .gb-plan-card .gb-plan-price { min-height:60px;margin:12px 0 14px; }
.standalone-go-board #plansDialog .gb-plan-purchase { margin-top:14px;padding-top:12px; }

@font-face {
  font-family: 'Noto Serif JP';
  font-style: normal;
  font-weight: 400;
  src: url(/fonts/quota-mincho-0.woff2) format('truetype');
}
@font-face {
  font-family: 'Noto Serif JP';
  font-style: normal;
  font-weight: 600;
  src: url(/fonts/quota-mincho-1.woff2) format('truetype');
}
@font-face {
  font-family: 'Noto Serif JP';
  font-style: normal;
  font-weight: 700;
  src: url(/fonts/quota-mincho-2.woff2) format('truetype');
}

/* Analysis-limit dialog: preserve the reference composition rather than compressing its content. */
.standalone-go-board #analysisLimitDialog { box-sizing:border-box; position:relative; width:min(520px,calc(100vw - 28px)); max-height:calc(100dvh - 28px); margin:auto; padding:51px 30px 18px; border:1px solid #ebc87c; border-radius:17px; color:#f8f0d9; background:radial-gradient(ellipse at 50% 42%,#0b3328 0%,#03271f 72%); box-shadow:0 16px 45px #0007; font-family:"Noto Serif JP",serif; }
.standalone-go-board #analysisLimitDialog::backdrop { background:#00161180; backdrop-filter:blur(3px); }
.standalone-go-board #analysisLimitDialog header { display:flex; align-items:center; justify-content:center; gap:10px; margin:0 0 8px; }
.standalone-go-board #analysisLimitDialog .gb-limit-mark { width:70px; height:70px; flex:0 0 70px; color:#edc878; }
.standalone-go-board #analysisLimitDialog h2 { flex:0 1 auto; margin:0; font:700 28px/1.4 "Noto Serif JP",serif; color:#fff6df; letter-spacing:.01em; }
.standalone-go-board #analysisLimitClose { position:absolute; top:14px; right:14px; min-width:38px; width:38px; height:38px; padding:0; font:29px/1 sans-serif; color:#efd18d; background:transparent; border:1px solid #b39c61; border-radius:9px; box-shadow:inset 0 0 0 1px #e2c57315; }
.standalone-go-board #analysisLimitDialog p { margin:0 0 20px; text-align:center; font-size:19px; line-height:1.6; color:inherit; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer { display:flex; flex-direction:column; align-items:center; gap:0; padding:12px 12px 14px; margin:0 0 16px; border:1px solid #6c8a635e; border-radius:9px; background:#d4e6b60b; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer[hidden] { display:none; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer>span { width:56%; padding-bottom:6px; border-bottom:1px solid #ac9b6877; text-align:center; font-size:20px; font-weight:700; line-height:1.5; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer strong { display:flex; align-items:baseline; justify-content:center; gap:7px; margin:4px 0; font-weight:500; line-height:1.15; color:#edc778; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer strong b { font:600 64px/1.15 "Noto Serif JP",serif; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer strong .gb-limit-yen { font-size:38px; color:#edc778; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer strong span { font-size:24px; font-weight:400; color:#fff4da; }
.standalone-go-board #analysisLimitDialog .gb-limit-offer small { font-size:19px; line-height:1.6; color:#fff5e1; }
.standalone-go-board #analysisLimitPlans { position:relative; width:100%; min-height:62px; padding:12px 30px 12px 14px; font:700 21px/1.5 "Noto Serif JP",serif; color:#fff8e5; background:#289775; border:1px solid #3daa7c; border-radius:10px; box-shadow:inset 0 1px 2px #a3ffcc30,0 4px 10px #0004; }
.standalone-go-board #analysisLimitPlans::after { content:'›'; position:absolute; right:15px; top:50%; transform:translateY(-50%); font:30px/1 "Noto Serif JP",serif; }
.standalone-go-board #analysisLimitDismiss { display:block; margin:16px auto 0; min-height:36px; padding:4px 12px; border:0; background:transparent; box-shadow:none; color:#c7d0c0; font:16px/1.5 "Noto Serif JP",serif; text-decoration:underline; text-underline-offset:4px; }
.standalone-go-board #analysisLimitDialog .gb-limit-reset { display:block; margin-top:13px; text-align:center; font-size:12px; line-height:1.7; color:#bac6b8; }
@media(max-width:480px) {
 .standalone-go-board #analysisLimitDialog { padding:54px 20px 18px; }
 .standalone-go-board #analysisLimitDialog header { gap:8px; }
 .standalone-go-board #analysisLimitDialog .gb-limit-mark { width:40px; height:40px; flex-basis:40px; }
 .standalone-go-board #analysisLimitDialog h2 { font-size:18px; }
 .standalone-go-board #analysisLimitDialog p { font-size:13px; margin-bottom:16px; }
 .standalone-go-board #analysisLimitDialog .gb-limit-offer>span { width:72%; font-size:17px; }
 .standalone-go-board #analysisLimitDialog .gb-limit-offer strong b { font-size:55px; }
 .standalone-go-board #analysisLimitDialog .gb-limit-offer small { font-size:14px; }
 .standalone-go-board #analysisLimitPlans { font-size:16px; min-height:52px; }
 .standalone-go-board #analysisLimitDialog .gb-limit-reset { font-size:10px; }
}

/* Board SGF sharing: emerald/gold reference design. */
.standalone-go-board #boardShareDialog { box-sizing:border-box; width:min(620px,calc(100vw - 28px)); padding:30px; max-height:calc(100dvh - 28px); overflow:auto; border:1px solid #e4bf6d; border-radius:18px; outline:0; background:#062d26; color:#f3f3e8; box-shadow:0 18px 70px #0008; font-family:system-ui,sans-serif; }
#boardShareDialog::backdrop { background:#0016119e; backdrop-filter:blur(5px); }
.standalone-go-board #boardShareDialog .gb-share-heading { display:flex; align-items:center; gap:20px; padding:0; margin:0 0 24px; border:0; }
#boardShareDialog .gb-share-heading h2 { margin:0; color:#f1cc7b; font:600 clamp(25px,3vw,34px)/1.3 "Yu Mincho","Noto Serif JP",serif; }
#boardShareDialog .gb-share-heading p { margin:8px 0 0; color:#b8ccc6; font-size:15px; }
#boardShareDialog .gb-share-emblem { width:64px; height:64px; flex-shrink:0; display:grid; place-items:center; border:1px solid #547963; border-radius:16px; background:#173e30; color:#8ee4b0; }
#boardShareDialog .gb-share-emblem svg { width:36px; height:36px; fill:currentColor; stroke:currentColor; stroke-width:1.5; }
.standalone-go-board #boardShareClose { align-self:flex-start; margin:-12px -12px 0 auto; padding:0; width:36px; height:36px; min-height:36px; border:0; box-shadow:none; background:transparent; color:#a7bdb5; font:32px/1 sans-serif; }
#boardShareDialog .gb-share-saved { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:10px; padding:14px; border:1px solid #4d8962; border-radius:10px; background:#123e2d; font-size:14px; margin-bottom:22px; }
#boardShareDialog .gb-share-saved[hidden],#boardShareLinks[hidden] { display:none; }
#boardShareDialog .gb-share-saved a { color:#b8e2b9; text-underline-offset:4px; }
#boardShareDialog .gb-share-check { display:inline-grid; place-items:center; width:23px; height:23px; border-radius:50%; background:#67d77f; color:#123828; margin-right:5px; font-weight:bold; }
#boardShareDialog #boardShareStatus { color:#c0d3cb; font-size:13px; line-height:1.5; margin:0 0 16px; }
#boardShareDialog #boardShareStatus:empty { display:none; }
#boardShareDialog label,#boardShareDialog .gb-share-label { color:#f3f3e8; font-size:15px; font-weight:500; }
#boardShareDialog .gb-share-url-row { display:flex; gap:8px; margin:10px 0 24px; }
.standalone-go-board #boardShareUrl { flex:1; min-width:0; width:100%; box-sizing:border-box; padding:12px; border:1px solid #59776d; border-radius:9px; background:#05221e; color:#e0ebe7; font:14px/1.5 system-ui,sans-serif; }
.standalone-go-board #boardShareCopy { display:flex; align-items:center; justify-content:center; gap:8px; width:auto; flex:0 0 112px; padding:10px; border:1px solid #48b88d; border-radius:9px; color:#f7fff7; background:#12835e; box-shadow:none; font:600 15px/1.4 system-ui,sans-serif; }
#boardShareCopy svg { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:1.6; }
#boardShareDialog .gb-share-label { margin:0 0 10px; }
#boardShareDialog .gb-share-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.standalone-go-board #boardShareDialog .gb-share-actions>a,.standalone-go-board #boardShareDialog .gb-share-actions>button { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:10px; min-width:0; padding:16px 8px; border:1px solid #46675c; border-radius:11px; color:#f2f5ee; background:#0c3029; text-decoration:none; box-shadow:none; font:15px/1.4 system-ui,sans-serif; cursor:pointer; }
#boardShareDialog .gb-share-actions svg { width:38px; height:38px; }
#boardShareX svg,#boardShareNative svg { fill:none; stroke:currentColor; stroke-width:1.5; stroke-linejoin:round; stroke-linecap:round; }
#boardShareDialog a:hover,#boardShareDialog button:hover { filter:brightness(1.15); }
#boardShareDialog :focus-visible { outline:2px solid #f1cc7b; outline-offset:3px; }
.standalone-go-board #boardShareDialog .gb-share-footer { display:block; margin:24px 0 0; padding:16px 0 0; border-top:1px solid #456357; color:#afc6bc; }
#boardShareDialog .gb-share-footer p { margin:0; display:flex; align-items:center; gap:8px; font-size:13px; line-height:1.6; }
#boardShareDialog .gb-share-footer p+p { margin-top:10px; font-size:12px; }
#boardShareDialog .gb-share-footer svg { width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.6; }
.standalone-go-board .gb-tree-heading .gb-controls { flex-wrap:wrap; }
.standalone-go-board #boardShareOpen { display:inline-flex; align-items:center; gap:8px; white-space:nowrap; background:#176b50; border-color:#7dd6ae; color:#fff8df; font-weight:700; box-shadow:0 0 0 1px #7dd6ae33,0 2px 6px #0002; }
.standalone-go-board #boardShareOpen:hover { background:#207d5f; border-color:#a1ebc8; }
.standalone-go-board #boardShareOpen:focus-visible { outline:2px solid #b0efd2; outline-offset:3px; }
.standalone-go-board[data-design-preset=light] #boardShareOpen { background:#226c51; border-color:#277958; color:#fff; }
@media(max-width:480px) {
 .standalone-go-board #boardShareDialog { padding:22px 18px; }
 .standalone-go-board #boardShareDialog .gb-share-heading { gap:12px; }
 #boardShareDialog .gb-share-emblem { width:46px; height:46px; border-radius:12px; }
 #boardShareDialog .gb-share-emblem svg { width:27px; height:27px; }
 #boardShareDialog .gb-share-heading h2 { font-size:24px; }
 #boardShareDialog .gb-share-heading p { font-size:12px; }
 .standalone-go-board #boardShareCopy { flex-basis:84px; font-size:13px; gap:4px; }
 .standalone-go-board #boardShareUrl { font-size:12px; padding:10px; }
 #boardShareDialog .gb-share-saved { font-size:12px; }
}

.standalone-go-board .gb-save-choices { display:grid; grid-template-columns:1.35fr 1fr; gap:10px; margin:12px 0; }
.standalone-go-board .gb-save-choices button { min-height:52px; white-space:normal; }
@media(max-width:480px) { .standalone-go-board .gb-save-choices { grid-template-columns:1fr; } }

.standalone-go-board .gb-sgf-drop-zone { display:none; }
@media (any-pointer:fine) {
 .standalone-go-board .gb-sgf-drop-zone { display:flex; flex-direction:column; align-items:center; gap:8px; margin:16px 0; padding:26px 16px; border:2px dashed #758f7c; border-radius:12px; color:inherit; transition:background .15s,border-color .15s; }
 .standalone-go-board .gb-sgf-drop-zone .gb-icon { width:28px; height:28px; }
 .standalone-go-board .gb-sgf-drop-zone span { font-size:12px; opacity:.75; }
 .standalone-go-board .gb-sgf-drop-zone.is-dragging { background:#37886230; border-color:#81cfac; }
}

/* Standalone record actions, outside the variation tree. */
.standalone-go-board .gb-record-actions { display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;width:100%;box-sizing:border-box; }
.standalone-go-board .gb-record-actions button { display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;min-width:0;padding:10px 2px;font-size:clamp(10px,1.5vw,12px);white-space:nowrap; }
.standalone-go-board .gb-record-actions .gb-icon { width:20px;height:20px;flex-shrink:0; }
.standalone-go-board .gb-players-dialog { width:min(480px,calc(100vw - 24px)); }
.standalone-go-board .gb-player-fields { display:grid;grid-template-columns:2fr 1fr;gap:16px 12px;margin:20px 0; }
.standalone-go-board .gb-player-fields label { display:flex;flex-direction:column;gap:8px;min-width:0; }
.standalone-go-board .gb-player-fields input { box-sizing:border-box;width:100%;min-width:0;padding:10px;font:inherit; }
.standalone-go-board #playersForm > button { width:100%;min-height:44px; }

.standalone-go-board .gb-mode-buttons.gb-mark-toolbar { grid-template-columns:repeat(9,minmax(0,42px));gap:3px;justify-content:start; }
.standalone-go-board .gb-mark-toolbar button { width:100%;min-width:0;height:38px;min-height:38px;padding:4px;font-size:26px;line-height:1;background:#0b372c;color:#e2efdc;border-color:#537f69;border-radius:6px; }
.standalone-go-board .gb-mark-toolbar #modeLabel { font-size:13px;font-weight:700; }
.standalone-go-board .gb-mark-toolbar .gb-icon { width:23px;max-width:100%;height:23px; }
.standalone-go-board .gb-pair-stones { position:relative;display:block;width:29px;height:27px; }
.standalone-go-board .gb-pair-stones i { position:absolute;left:0;top:0;width:19px;height:19px; }
.standalone-go-board .gb-pair-stones i+ i { left:10px;top:9px; }
.standalone-go-board .gb-mark-label-control:not([hidden]) { display:flex;gap:9px;align-items:center;flex-wrap:wrap;margin:0 0 12px;font-size:12px; }
.standalone-go-board .gb-mark-label-control select { min-width:68px;min-height:38px; }
.standalone-go-board[data-design-preset=light] .gb-mark-toolbar button { background:#ecf3e9;color:#225d43;border-color:#91ab91; }

@media (max-width:480px) {
  .standalone-go-board .gb-mark-toolbar button { padding:2px;font-size:22px; }
  .standalone-go-board .gb-mark-toolbar #modeLabel { font-size:10px; }
  .standalone-go-board .gb-mark-toolbar .gb-pair-stones { transform:scale(.8);transform-origin:center; }
}

/* Board image sharing: compose, preview and portable fallbacks. */
#boardShareDialog .gb-share-compose{display:grid;gap:10px;margin:18px 0}
#boardShareDialog select,#boardShareDialog textarea{width:100%;box-sizing:border-box;font:inherit;color:inherit;background:transparent;border:1px solid #658778;border-radius:8px;padding:10px}
#boardShareDialog select option{color:#123a30;background:#fff}
#boardShareDialog textarea{resize:vertical;min-height:80px}
#boardShareDialog p{font-size:13px;line-height:1.7}
#boardSharePreview{display:block;width:100%;max-width:340px;aspect-ratio:1;margin:16px auto;border-radius:8px}
#boardShareDialog .gb-share-export{display:flex;gap:10px;flex-wrap:wrap;margin:12px 0}
#boardShareDialog .gb-share-export a{border:1px solid #658778;border-radius:8px;padding:10px;color:inherit;text-decoration:none}
#boardSharePrepare:disabled{opacity:.55}

/* Shared-position quiz. Answer and distribution arrive only after submission. */
#boardQuizDialog{width:560px;max-width:calc(100vw - 28px);max-height:calc(100dvh - 28px);overflow:auto;box-sizing:border-box}
#boardQuizDialog header{display:flex;align-items:center;justify-content:space-between;gap:12px}
#boardQuizBoard{max-width:420px;margin:12px auto;background:#dbaf6c;border-radius:8px;color:#352516;--board-line-color:#644220;--board-star-color:#48351d}
#boardQuizBoard svg{display:block;width:100%;height:auto;touch-action:manipulation}
#boardQuizDialog .gb-quiz-input{display:flex;gap:8px;margin:8px 0}
#boardQuizAnswer{min-width:0;width:100%;flex:1;text-transform:uppercase}
#boardQuizDialog p{font-size:13px;line-height:1.7}
#boardQuizCounts{padding:0;list-style:none;display:grid;gap:10px}
#boardQuizCounts li{display:grid;gap:4px}
#boardQuizCounts progress{width:100%;height:10px;accent-color:#45c99a}
#boardQuizVerdict{font-size:18px;line-height:1.6}

/* Answer result and share composer */
#boardQuizDialog .gb-quiz-result-card{text-align:center;padding:22px 14px;margin:16px 0;border:1px solid #9b8752;border-radius:14px;background:rgba(59,145,111,.12)}
#boardQuizVerdict{font-size:32px;margin:0 0 8px;color:#dfc27c}
#boardQuizResults[data-correct="true"] #boardQuizVerdict{color:#53d7a5}
#boardQuizRate{display:block;font-size:44px;line-height:1.2;font-variant-numeric:tabular-nums;color:#dfc27c}
#boardQuizDialog .gb-quiz-share{margin:20px 0;padding-top:16px;border-top:1px solid #587368}
#boardQuizDialog .gb-quiz-share label{display:block;margin:10px 0 6px}
#boardQuizDialog .gb-quiz-share :is(select,input,textarea){width:100%;min-width:0;box-sizing:border-box}
#boardQuizShareText{font-size:13px;line-height:1.6;resize:vertical}
#boardQuizDialog .gb-quiz-share-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:12px}
#boardQuizDialog .gb-quiz-share-actions button{min-width:0;white-space:normal}
#boardQuizContinue{width:100%}
.standalone-go-board[data-design-preset=light] :is(#boardQuizVerdict,#boardQuizRate){color:#745019}
.standalone-go-board[data-design-preset=light] #boardQuizResults[data-correct="true"] #boardQuizVerdict{color:#126346}

#boardQuizProblemId{overflow-wrap:anywhere;font-family:monospace}

.standalone-go-board .gb-recent-actions{display:flex;flex-wrap:wrap;gap:8px;margin:0}
.standalone-go-board .gb-recent-actions:not(:has(button:not([hidden]))){display:none}
#recentDialog{width:520px;max-width:calc(100vw - 24px);max-height:80dvh;overflow:auto;box-sizing:border-box}
#recentDialog header{display:flex;justify-content:space-between;align-items:center;gap:12px}
#recentDialog p{font-size:13px;line-height:1.7}
#recentList{display:grid;gap:8px}
#recentList button{text-align:left;white-space:normal;overflow-wrap:anywhere;padding:12px}

#boardShareDialog select{width:100%;min-width:0;box-sizing:border-box;margin:4px 0 10px}
#boardShareChoiceBoard{max-width:420px;margin:12px auto;background:#dbaf6c;color:#352516;--board-line-color:#644220;--board-star-color:#48351d}
#boardShareChoiceBoard svg{display:block;width:100%;height:auto;touch-action:manipulation}
#boardQuizChoices{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:12px 0}
#boardQuizChoices[hidden]{display:none}
#boardQuizChoices button{min-width:0;padding:12px 4px}
#boardQuizChoices button[aria-pressed=true]{background:#176b50;color:white;border-color:#8fe0ba}
#boardQuizSubmit{width:100%;margin:8px 0}

.standalone-go-board #boardShareNative { display:flex; align-items:center; justify-content:center; gap:12px; width:100%; min-height:58px; padding:14px; margin:18px 0 8px; border:1px solid #66d7aa; border-radius:12px; background:#198c64; color:#fff; font:700 18px/1.4 system-ui,sans-serif; box-shadow:0 3px 12px #0003; }
#boardShareNative svg { width:28px; height:28px; flex-shrink:0; }
#boardShareDialog .gb-share-send-help { margin:8px 0 20px; font-size:13px; }
#boardShareDialog .gb-share-alternatives { border-top:1px solid #46675c; padding-top:14px; }
#boardShareDialog .gb-share-alternatives summary { cursor:pointer; color:inherit; font-size:14px; padding:6px 0; }
.standalone-go-board #boardShareDesktopX { display:flex; align-items:center; justify-content:center; width:100%; min-height:58px; margin:18px 0 8px; padding:14px; border:1px solid #66d7aa; border-radius:12px; background:#198c64; color:#fff; font:700 18px/1.4 system-ui,sans-serif; }
.standalone-go-board #boardShareDesktopX[hidden] { display:none; }
.standalone-go-board #boardShareNative.gb-share-secondary { min-height:42px; margin-top:10px; background:#0c3029; border-color:#46675c; font-size:14px; box-shadow:none; }
#boardShareDesktopTarget[hidden] { display:none; }
#boardShareDesktopTarget { margin-top:18px; }
#boardShareSocial { display:block; width:100%; min-height:44px; margin:8px 0; padding:8px 12px; border:1px solid #59776d; border-radius:8px; background:#0c3029; color:#f2f5ee; font:inherit; }
#boardShareDestination { display:inline-block; padding:4px 0; color:#b7e6cf; font-size:13px; }
#boardReplyEditor[hidden],#boardReplySend[hidden] { display:none; }
#boardReplyBoard { max-width:420px; margin:12px auto; background:#dfb574; }
#boardReplyBoard svg { display:block; width:100%; height:auto; }
#boardReplyEditor input,#boardReplyEditor select { box-sizing:border-box; width:100%; padding:10px; margin:6px 0 12px; background:#0c3029; color:#f2f5ee; border:1px solid #59776d; border-radius:8px; }
.gb-reply-controls { display:flex; gap:8px; align-items:center; margin:12px 0; }
.standalone-go-board #boardReplySend { width:100%; margin:12px 0; padding:14px; background:#176b50; color:#fff; border:1px solid #66d7aa; }

.standalone-go-board .gb-reply-toolbar { margin:12px 0; }
.standalone-go-board .gb-reply-toolbar #boardReplyToolLB { font-size:13px;font-weight:700; }

/* Reply composer: board and comment, followed by one copy action. */
#boardShareDialog .gb-reply-only { display:none; }
.standalone-go-board #boardShareDialog[data-reply=true] { width:min(980px,calc(100vw - 28px));border-radius:9px;padding:28px 30px;background:linear-gradient(130deg,#06362b,#03261f); }
#boardShareDialog[data-reply=true] .gb-share-emblem,
#boardShareDialog[data-reply=true] .gb-share-compose > label,
#boardShareDialog[data-reply=true] #boardShareKind,
#boardShareDialog[data-reply=true] .gb-share-compose > p,
#boardShareDialog[data-reply=true] #boardSharePrepare,
#boardShareDialog[data-reply=true] #boardShareLinks,
#boardShareDialog[data-reply=true] .gb-share-footer,
#boardShareDialog[data-reply=true] #boardReplyEditor > p { display:none; }
#boardShareDialog[data-reply=true] .gb-share-heading { margin-bottom:18px;align-items:start; }
#boardShareDialog[data-reply=true] .gb-share-compose { display:grid;grid-template-columns:minmax(0,1.4fr) minmax(0,1fr);column-gap:28px;grid-template-rows:auto 1fr; }
#boardShareDialog[data-reply=true] #boardReplyEditor { grid-column:1;grid-row:1 / 3;min-width:0; }
#boardShareDialog[data-reply=true] #boardShareCommentFields { grid-column:2;grid-row:1;min-width:0; }
#boardShareDialog[data-reply=true] #boardReplyPostFields { grid-column:2;grid-row:2;padding-top:22px;min-width:0; }
#boardShareDialog[data-reply=true] #boardReplyBoard { max-width:none;margin:0; }
#boardShareDialog[data-reply=true] #boardShareComment { width:100%;min-height:190px;box-sizing:border-box;margin:12px 0 0;resize:vertical; }
#boardShareDialog[data-reply=true] .gb-reply-only { display:block;font-size:13px;color:#a7c4b8;line-height:1.6; }
#boardShareDialog[data-reply=true] #boardReplyPost { width:100%;box-sizing:border-box;margin:12px 0;padding:12px;background:#082d25;color:#f3f3e8;border:1px solid #59776d;border-radius:7px; }
#boardShareDialog[data-reply=true] .gb-reply-toolbar { grid-template-columns:repeat(9,minmax(0,1fr));gap:5px;margin:10px 0; }
#boardShareDialog[data-reply=true] .gb-reply-toolbar button { height:42px; }
#boardShareDialog[data-reply=true] .gb-reply-controls { gap:6px;flex-wrap:wrap;font-size:12px;margin:10px 0 0;padding-top:10px;border-top:1px solid #366052; }
#boardShareDialog[data-reply=true] .gb-reply-controls button { padding:7px 10px;min-height:36px; }
#boardShareDialog[data-reply=true] #boardReplyCount { margin-left:auto; }
#boardShareDialog[data-reply=true] #boardReplyClearMarks { font-size:11px;min-height:26px;padding:3px 7px; }
#boardReplyActions { border-top:1px solid #9c8752;margin-top:20px;padding-top:18px;text-align:center; }
#boardReplyActions[hidden],#boardReplyPostFields[hidden],#boardReplyCopyFallback[hidden] { display:none; }
.standalone-go-board #boardReplyCopy { width:100%;min-height:48px;border:1px solid #65dfb8;background:#118c6c;border-radius:7px;color:#fff;font:600 17px/1.5 system-ui,sans-serif; }
#boardReplyActions p { font-size:12px;color:#a7c4b8;line-height:1.6;margin:10px 0; }
#boardReplyCopyFallback { width:100%;box-sizing:border-box;min-height:100px; }
#boardShareDialog[data-reply=true] #boardShareStatus { margin:12px 0 0; }
#boardReplyLabelControls[hidden] { display:none; }
@media(max-width:640px) {
 .standalone-go-board #boardShareDialog[data-reply=true] { width:calc(100vw - 16px);padding:18px 14px;max-height:calc(100dvh - 16px); }
 #boardShareDialog[data-reply=true] .gb-share-compose { display:flex;flex-direction:column;gap:18px; }
 #boardShareDialog[data-reply=true] #boardReplyEditor { order:0; }
 #boardShareDialog[data-reply=true] #boardShareCommentFields { order:1; }
 #boardShareDialog[data-reply=true] #boardReplyPostFields { order:2;padding-top:0; }
 #boardShareDialog[data-reply=true] #boardShareComment { min-height:120px; }
 #boardShareDialog[data-reply=true] .gb-reply-toolbar { gap:3px; }
 #boardShareDialog[data-reply=true] .gb-reply-toolbar button { height:36px;min-height:36px; }
 #boardShareDialog[data-reply=true] .gb-share-heading p { font-size:12px; }
}

@media(min-width:900px) and (max-height:850px) {
 .standalone-go-board #boardShareDialog[data-reply=true] { width:min(920px,calc((100dvh - 340px)*1.75 + 90px));padding:18px 22px; }
 #boardShareDialog[data-reply=true] .gb-share-heading { margin-bottom:12px; }
 #boardShareDialog[data-reply=true] .gb-share-heading h2 { font-size:27px; }
 #boardShareDialog[data-reply=true] .gb-share-heading p { font-size:12px;margin-top:4px; }
 #boardShareDialog[data-reply=true] .gb-share-compose { column-gap:18px; }
 #boardShareDialog[data-reply=true] #boardShareComment { min-height:120px; }
 #boardShareDialog[data-reply=true] #boardReplyPostFields { padding-top:10px; }
 #boardShareDialog[data-reply=true] .gb-reply-toolbar { gap:3px;margin:7px 0; }
 #boardShareDialog[data-reply=true] .gb-reply-toolbar button { height:34px;min-height:34px;font-size:20px; }
 #boardShareDialog[data-reply=true] #boardReplyToolLB { font-size:10px; }
 #boardShareDialog[data-reply=true] .gb-pair-stones { transform:scale(.75);transform-origin:center; }
 #boardShareDialog[data-reply=true] #boardReplyActions { margin-top:12px;padding-top:12px; }
 #boardShareDialog[data-reply=true] #boardReplyActions p { font-size:11px;margin:7px 0; }
}

.standalone-go-board #boardShareDialog[data-reply=true] { color:#f3f3e8; }
.standalone-go-board #boardShareDialog[data-reply=true] textarea { background:#082d25;color:#f3f3e8;border-color:#59776d; }
.standalone-go-board #boardShareDialog[data-reply=true] .gb-share-heading h2 { color:#f1cc7b; }

/* Self sharing: image preview with a compact SNS composer. */
#boardShareDialog[data-reply=true] #boardShareVisual,
#boardShareDialog[data-reply=true] #boardShareTabs,
#boardShareDialog[data-reply=true] #boardShareNewActions { display:none; }
.standalone-go-board #boardShareDialog[data-reply=false] { width:min(1060px,calc(100vw - 28px));padding:0;background:#faf8f2;color:#24433b;border-radius:14px; }
#boardShareDialog[data-reply=false][open] { display:grid;grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);column-gap:28px; }
#boardShareDialog[data-reply=false] .gb-share-heading { grid-column:1 / -1;background:linear-gradient(120deg,#0b382e,#23493b);padding:24px 30px;margin:0 0 26px; }
#boardShareDialog[data-reply=false] .gb-share-emblem,
#boardShareDialog[data-reply=false] .gb-share-compose > label,
#boardShareDialog[data-reply=false] #boardShareKind,
#boardShareDialog[data-reply=false] #boardSharePrepare,
#boardShareDialog[data-reply=false] .gb-share-compose > p,
#boardShareDialog[data-reply=false] #boardShareLinks,
#boardShareDialog[data-reply=false] .gb-share-footer { display:none; }
#boardShareDialog[data-reply=false] .gb-share-compose { grid-column:2;grid-row:2;margin:0 28px 12px 0;min-width:0; }
#boardShareVisual { grid-column:1;grid-row:2 / 5;margin:0 0 28px 28px;min-width:0; }
#boardShareBoardPreview { background:#dfb574;border:1px solid #cca260;box-shadow:0 3px 10px #38220f24;border-radius:8px;overflow:hidden; }
#boardShareBoardPreview svg { display:block;width:100%;height:auto; }
#boardShareVisual p { color:#69766d;font-size:12px;text-align:center;line-height:1.7; }
#boardShareTabs { display:grid;grid-template-columns:1fr 1fr;gap:0;margin-bottom:22px; }
.standalone-go-board #boardShareTabs button { border:1px solid #d8d5c7;background:#efede5;color:#34443c;min-height:46px;border-radius:0;font-size:15px; }
#boardShareTabs button:first-child { border-radius:8px 0 0 8px; }
#boardShareTabs button:last-child { border-radius:0 8px 8px 0; }
.standalone-go-board #boardShareTabs button[aria-pressed=true] { background:#184e3e;color:#f5df9d;border-color:#bb9d55; }
#boardShareDialog[data-reply=false] label { color:#34443c;font-weight:600; }
#boardShareDialog[data-reply=false] textarea,#boardShareDialog[data-reply=false] select { box-sizing:border-box;width:100%;border:1px solid #d3d5ce;border-radius:8px;background:#fffefa;color:#29463c;padding:10px;font:14px/1.6 system-ui,sans-serif; }
#boardShareDialog[data-reply=false] #boardShareComment { min-height:145px;margin:10px 0 16px;resize:vertical;border:1px solid #739588;border-radius:8px; }
#boardShareComment::placeholder { color:currentColor;opacity:.45; }
#boardShareDialog[data-reply=false] #boardShareQuizOptions p { color:#59675f;font-size:12px;line-height:1.6; }
#boardShareDialog .gb-target-label { margin:0 0 9px;font-size:14px;color:#59675f; }
.gb-share-targets { display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px; }
.standalone-go-board .gb-share-targets button { display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;min-width:0;min-height:78px;background:#fffefa;border:1px solid #739588;border-radius:8px;color:#183d31;padding:8px 2px;font:11px/1.4 system-ui,sans-serif; }
.gb-share-targets svg { width:30px;height:30px; }
#boardShareNewActions #boardShareDestination { display:block;margin:8px 0 0;font-size:12px;color:#26674e;text-align:right; }
.standalone-go-board #boardShareMain { display:flex;align-items:center;justify-content:center;width:100%;min-height:52px;margin:16px 0 8px;border:1px solid #43866a;border-radius:8px;background:#195d48;color:#fff;font:600 18px/1.5 system-ui,sans-serif; }
#boardShareDialog .gb-share-hint { font-size:11px;line-height:1.6;color:#727b73;text-align:center;margin:8px 0 12px; }
.gb-share-copy-row { display:grid;grid-template-columns:1fr 1fr;gap:8px; }
#boardShareLineSteps:not([hidden]) { display:grid;gap:8px;margin:12px 0;padding:12px;border:1px solid #668f7b;border-radius:8px;background:#eaf5ee;color:#174632; }
#boardShareLineSteps p { margin:0;font-size:12px;line-height:1.6; }
#boardShareLineText { display:flex;align-items:center;justify-content:center;min-height:44px;padding:6px 10px;border-radius:6px;background:#06763b;color:#fff;font:600 14px/1.5 system-ui,sans-serif;text-decoration:none; }
.standalone-go-board .gb-share-copy-row button { background:transparent;color:#245b46;border:1px solid #668f7b;border-radius:6px;min-height:42px;padding:8px 3px;font-size:12px; }
.standalone-go-board #boardShareImageSave { display:block;margin:8px auto 0;min-height:34px;background:transparent;border:0;color:#245b46;font-size:13px; }
#boardShareTextFallback[hidden] { display:none; }
#boardShareDialog[data-reply=false] #boardShareStatus { grid-column:2;grid-row:3;margin:0 28px 20px 0;color:#23543f; }
#boardShareDialog[data-reply=false] #boardShareClose { margin-left:auto;align-self:flex-start;color:#e6cc86; }
@media(max-width:680px) {
 #boardShareDialog[data-reply=false][open] { display:block; }
 #boardShareDialog[data-reply=false] .gb-share-heading { padding:18px;margin-bottom:18px; }
 #boardShareVisual { margin:0 18px 20px; }
 #boardShareDialog[data-reply=false] .gb-share-compose { margin:0 18px 18px; }
 #boardShareDialog[data-reply=false] #boardShareStatus { margin:0 18px 18px; }
 .gb-share-targets { gap:4px; }
 .standalone-go-board .gb-share-targets button { font-size:9px; }
}

#boardShareNewActions #boardShareDestination[hidden] { display:none; }

@media(min-width:900px) and (max-height:850px) {
 .standalone-go-board #boardShareDialog[data-reply=false] { width:min(840px,calc(100vw - 28px)); }
 #boardShareDialog[data-reply=false] .gb-share-heading { padding:16px 24px;margin-bottom:18px; }
 #boardShareDialog[data-reply=false] .gb-share-heading h2 { font-size:28px; }
 #boardShareDialog[data-reply=false] .gb-share-heading p { font-size:12px;margin-top:4px; }
 #boardShareDialog[data-reply=false] #boardShareTabs { margin-bottom:12px; }
 #boardShareDialog[data-reply=false] #boardShareTabs button { min-height:38px;font-size:13px; }
 #boardShareDialog[data-reply=false] #boardShareComment { min-height:95px;margin:6px 0 10px; }
 #boardShareDialog[data-reply=false] .gb-share-targets button { min-height:64px;font-size:10px; }
 #boardShareDialog[data-reply=false] .gb-share-targets svg { width:25px;height:25px; }
 #boardShareDialog[data-reply=false] #boardShareMain { min-height:44px;margin-top:10px;font-size:16px; }
 #boardShareDialog[data-reply=false] .gb-share-hint { margin:6px 0;font-size:10px; }
 #boardShareDialog[data-reply=false] #boardShareImageSave { margin-top:4px;min-height:28px; }
}

/* Optional quiz explanation editor and post-answer playback. */
#boardExplanationBoard,#boardQuizExplanationBoard{max-width:420px;margin:12px auto;background:#dbaf6c;--board-line-color:#644220;--board-star-color:#48351d}
#boardExplanationBoard svg,#boardQuizExplanationBoard svg{display:block;width:100%;height:auto;touch-action:manipulation}
#boardExplanationEditor,#boardQuizExplanation{margin-top:14px;padding-top:12px;border-top:1px solid #94ad9e}
#boardExplanationEditor[hidden],#boardQuizExplanation[hidden],#boardQuizExplanationContent[hidden]{display:none}
.gb-explanation-controls{display:flex;flex-wrap:wrap;align-items:center;gap:6px}
#boardExplanationComment{width:100%;box-sizing:border-box}
#boardQuizExplanationComment{white-space:pre-wrap;overflow-wrap:anywhere}

/* Current-node comment in the board sidebar. */
.standalone-go-board .gb-tools section.gb-move-comment { min-width:0;padding:0;border:0;border-radius:0;background:transparent;box-shadow:none; }
.standalone-go-board #moveComment { display:block;box-sizing:border-box;width:100%;min-height:100px;padding:12px;border:1px solid #b29b62;border-radius:8px;background:transparent;color:#f7edcf;font:14px/1.65 system-ui,sans-serif;resize:vertical; }
.standalone-go-board #moveComment::placeholder { color:currentColor;opacity:.45; }
.standalone-go-board #moveComment:focus { outline:none; }
.standalone-go-board[data-design-preset=light] #moveComment { background:transparent;color:#29463c; }
.standalone-go-board[data-design-preset=light] #moveComment::placeholder { color:#526b5a;opacity:1; }

/* Keep playback aligned with the board, with no enclosing frame. */
.standalone-go-board #webNavigationSlot { margin:10px auto 0; }
@media(min-width:1001px), (orientation:landscape) and (min-width:761px) {
 .standalone-go-board #webNavigationSlot { width:min(100%,calc(100cqh - 110px)); }
}


/* Use the former heading and card padding space for the tree itself. */
.standalone-go-board .gb-tools section.gb-tree-card { padding:0;border:0;border-radius:0;background:transparent;box-shadow:none; }
.standalone-go-board .gb-tools .gb-tree-card .gb-tree-viewport { height:210px;margin:0;box-sizing:border-box; }

.standalone-go-board .gb-playback-controls { display:flex;align-items:center;justify-content:center;gap:0;min-width:0;min-height:44px;box-sizing:border-box;border:1px solid #ac9965;border-radius:6px;background:#143b30; }
.standalone-go-board #webNavigation #autoPlay { flex:1 1 40px;min-height:42px;padding:6px 3px;border:0;border-radius:5px 0 0 5px;background:transparent;box-shadow:none;font-size:18px; }
.standalone-go-board #autoPlayInterval { flex:0 1 52px;width:52px;max-width:52px;min-width:0;box-sizing:border-box;height:42px;min-height:42px;margin:0;padding:4px 2px;border:0;border-left:1px solid #ac996550;border-radius:0 5px 5px 0;background-color:transparent;box-shadow:none;font-size:13px;text-align:right;text-align-last:right;cursor:pointer; }
.standalone-go-board .gb-playback-controls:focus-within { outline:2px solid #65c2a0;outline-offset:2px; }
.standalone-go-board[data-design-preset=light] .gb-playback-controls { background:#fffdf5;border-color:#b5a376; }

/* Collapse analysis details while retaining the win-rate display. */
.standalone-go-board .gb-ai-heading h2 { display:flex;align-items:center;gap:4px;white-space:nowrap; }
.standalone-go-board .gb-ai-heading #analysisDetailsToggle { display:flex;align-items:center;justify-content:flex-start;gap:6px;min-height:44px;margin:0;padding:6px 0;font:inherit;border:0;border-radius:0;background:transparent;box-shadow:none;cursor:pointer; }
.standalone-go-board #analysisDetailsAction { font:11px/1.3 system-ui,sans-serif;white-space:nowrap; }
.standalone-go-board #analysisDetailsToggle:hover { background:#b8d8c428; }
.standalone-go-board #analysisDetailsToggle:focus-visible { outline:2px solid #65c2a0;outline-offset:2px; }
@media(max-width:1439px) {
 .standalone-go-board .gb-ai-heading #analysisDetailsToggle { font-size:17px;gap:6px;padding:6px 0; }
}
.standalone-go-board #analysisDetails.gb-details-collapsed { grid-template-columns:minmax(0,1fr); }
.standalone-go-board #analysisDetails.gb-details-collapsed .gb-evaluation-history,
.standalone-go-board #analysisDetails.gb-details-collapsed .gb-candidate-panel { display:none; }
@media(max-width:760px) {
 .standalone-go-board #analysisDetails.gb-details-collapsed { display:none; }
}

/* Desktop win rate is centered above the board. */
.standalone-go-board .gb-header-winrate { display:none; }
@media(min-width:761px) {
 .standalone-go-board .gb-header-winrate { display:block;order:1;flex:0 1 220px;width:220px;min-width:130px;margin:0; }
 .standalone-go-board .gb-header-winrate .gb-winrate-meter { height:20px;margin:0 0 4px; }
 .standalone-go-board .gb-header-winrate .gb-winrate-labels { margin:0;font-size:12px;gap:6px; }
 .standalone-go-board .gb-winrate-panel .gb-evaluation-history { margin-top:0;padding-top:0;border-top:0; }
 .standalone-go-board #analysisDetails.gb-details-collapsed { display:none; }
}

/* Keep the desktop title, win rate, score and actions on one header row. */
@media(min-width:761px) {
 .standalone-go-board .gb-header { flex-wrap:nowrap; }
 .standalone-go-board .gb-header>.gb-evaluation-badge { order:2; }
 .standalone-go-board .gb-header>.gb-account { order:3; }
 .standalone-go-board .gb-header>.gb-header-actions { order:4; }
}

/* Vertical desktop win-rate rail beside the board. */
.standalone-go-board .gb-vertical-winrate { display:none; }
.standalone-go-board .gb-capture-count { display:inline-flex;align-items:center;gap:5px;margin-left:9px; }
.standalone-go-board .gb-capture-count .gb-mode-stone { width:18px;height:18px; }
@media(min-width:761px) {
 .standalone-go-board .gb-board-row { display:flex;align-items:stretch;gap:10px;width:min(100%,calc(100dvh - 180px + 68px));margin:auto; }
 .standalone-go-board .gb-board-row .gb-board-viewport { flex:1;min-width:0; }
 .standalone-go-board .gb-board-row .gb-board { width:100%; }
 .standalone-go-board .gb-vertical-winrate { display:flex;flex-direction:column;align-items:center;gap:6px;flex:0 0 58px;font:600 17px/1.3 system-ui,sans-serif;font-variant-numeric:tabular-nums; }
 .standalone-go-board .gb-vertical-winrate .gb-winrate-meter { flex:1;min-height:0;width:20px;height:auto;margin:0;border-radius:12px; }
 .standalone-go-board .gb-vertical-winrate #blackWinrateFill { display:block;width:100%; }
 .standalone-go-board #captures { display:inline-flex;align-items:center;white-space:nowrap; }
}
@media(min-width:1001px), (orientation:landscape) and (min-width:761px) {
 .standalone-go-board .gb-board-row { width:min(100%,calc(100cqh - 110px + 68px)); }
}

@media(max-width:1439px) {
 .standalone-go-board .gb-ai-heading { display:grid;grid-template-columns:minmax(0,1fr) auto; }
 .standalone-go-board .gb-ai-heading h2 { min-width:0;margin:0; }
 .standalone-go-board .gb-ai-heading #analysisDetailsToggle { width:100%; }
 .standalone-go-board .gb-ai-heading .gb-continuous-control { gap:4px;font-size:11px;margin:0; }
 .standalone-go-board .gb-ai-heading .gb-continuous-switch { width:50px;min-width:50px; }
 .standalone-go-board .gb-ai-heading #analyze { grid-column:1/-1;width:100%; }
}

.standalone-go-board .gb-position-controls label { min-width:0; }
.standalone-go-board .gb-position-controls select { min-width:0;width:100%;box-sizing:border-box; }
.standalone-go-board .gb-position-controls :is(select,#pass,#reset) { height:44px;min-height:44px;box-sizing:border-box; }
.standalone-go-board .gb-position-controls :is(#pass,#reset) { width:100%;min-width:0;padding:8px 6px; }

/* Compact mobile board-size and turn selectors, keeping touch height. */
@media(max-width:760px) {
 .standalone-go-board .gb-position-controls { grid-template-columns:minmax(0,1fr) minmax(0,1fr) clamp(54px,17%,72px) clamp(76px,22%,90px);gap:6px;width:100%;justify-content:stretch; }
 .standalone-go-board .gb-position-controls label { margin:0;font-size:11px; }
 .standalone-go-board .gb-position-controls select { padding:6px 3px;min-height:44px;margin-top:3px;font-size:12px; }
}

#boardReplyActions .gb-share-targets { margin-top:16px; }

.standalone-go-board label.gb-komi-control { display:inline-flex;align-items:center;gap:6px;margin:0;font-size:12px;white-space:nowrap; }
.standalone-go-board .gb-komi-control input { box-sizing:border-box;width:64px;min-width:0;height:36px;min-height:36px;padding:5px 6px;border:1px solid #ac9965;border-radius:6px;background:#082d25;color:#f3ead0;font:500 14px/24px system-ui,sans-serif;font-variant-numeric:tabular-nums;text-align:center; }
.standalone-go-board[data-design-preset=light] .gb-komi-control input { background:#fffef8;color:#29463c; }
@media(max-width:760px) {
 .standalone-go-board .gb-mobile-captures { flex-wrap:wrap; }
 .standalone-go-board #komiControl { display:none; }
 .standalone-go-board .gb-komi-control input { min-height:44px;width:60px; }
}

/* Go-board stone designs reuse the Michishirube stone assets. */
.standalone-go-board #settingsDialog .gb-stone-row{display:grid;grid-template-columns:64px 42px minmax(0,1fr);align-items:center;gap:12px;}
.standalone-go-board #settingsDialog .gb-stone-row>select{width:100%;min-width:0;margin:0;}
.standalone-go-board #settingsDialog .gb-stone-row>img{display:block;width:42px;height:42px;object-fit:contain;}

.standalone-go-board #playersKomiSlot { margin-top:20px; }

/* Readable desktop board status without changing mobile controls. */
@media(min-width:761px) {
 .standalone-go-board .gb-header-captures { font-size:16px; }
 .standalone-go-board #komiControl { font-size:16px; }
 .standalone-go-board #komiControl input { font-size:18px;font-weight:600; }
 .standalone-go-board .gb-header>.gb-evaluation-badge { font-size:24px;line-height:28px;height:40px; }
 .standalone-go-board #accountInitial { font-size:24px; }
}

.standalone-go-board .gb-analysis-actions { display:flex;flex-wrap:nowrap;align-items:center;gap:6px;grid-column:1/-1;min-width:0; }
.standalone-go-board .gb-analysis-actions #analyze { flex:1;min-width:0; }

.standalone-go-board .gb-candidate-checkbox { display:inline-flex;flex:0 0 28px;align-items:center;justify-content:center;min-height:36px;margin:0;cursor:pointer; }
.standalone-go-board .gb-candidate-checkbox input { width:16px;height:16px;min-height:0;margin:0;accent-color:#248365;cursor:pointer; }

/* One visible analysis button with an independent candidate checkbox at its end. */
.standalone-go-board .gb-analysis-actions { gap:0;border:1px solid #ac9965;border-radius:6px;background:#164e3d;overflow:hidden; }
.standalone-go-board .gb-analysis-actions #analyze { border:0;border-radius:0;background:transparent;box-shadow:none; }
.standalone-go-board .gb-analysis-actions .gb-candidate-checkbox { flex:0 0 auto;align-self:stretch;min-height:0;gap:6px;padding:0 10px;border-left:1px solid #ac9965;color:#fff4cf;font-size:13px;font-weight:600;white-space:nowrap; }
.standalone-go-board[data-design-preset=light] .gb-analysis-actions .gb-candidate-checkbox { border-left-color:#b4beaa;color:#234f40; }
.standalone-go-board[data-design-preset=light] .gb-analysis-actions { background:#eef3e9;border-color:#b4beaa; }
.standalone-go-board[data-design-preset=light] .gb-analysis-actions #analyze { color:#234f40; }
.standalone-go-board[data-design-preset=light] .gb-analysis-actions #analyze:hover { color:#173e30;background:#e3eee1; }


.standalone-go-board .gb-record-index { border:1px solid #ac9965;border-radius:8px;padding:14px;min-width:0; }
.standalone-go-board .gb-record-index summary { cursor:pointer;font-weight:600;font-size:16px;padding:2px 0 12px;border-bottom:1px solid #8caa9644; }
.standalone-go-board .gb-index-toolbar { display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;margin:12px 0; }
.standalone-go-board .gb-index-tabs { display:flex;overflow:hidden;border:1px solid #559d7f77;border-radius:6px; }
.standalone-go-board .gb-index-tabs button { border:0;border-radius:0;background:transparent;padding:7px 12px;min-height:34px;font-size:12px; }
.standalone-go-board .gb-index-tabs button+button { border-left:1px solid #559d7f44; }
.standalone-go-board .gb-index-tabs button[aria-pressed=true] { background:#27634e;color:#fff; }
.standalone-go-board #recordIndexStats { margin:0;font-size:11px; }
.standalone-go-board #recordIndexList { max-height:360px;overflow:auto;scrollbar-width:thin;scrollbar-color:#678c7c #11382d; }
.standalone-go-board .gb-index-item { padding:12px 6px;display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:8px;border-top:1px solid #8caa9633; }
.standalone-go-board .gb-index-item[data-current=true] { background:#63b99212;box-shadow:inset 3px 0 #65c2a0; }
.standalone-go-board .gb-index-item button { border:0;background:transparent;box-shadow:none;min-height:34px;padding:4px;text-align:left;font-size:12px; }
.standalone-go-board .gb-index-jump { display:flex;align-items:center;gap:8px;min-width:0;order:0; }
.standalone-go-board .gb-index-move { flex-shrink:0;border:1px solid #ac996588;border-radius:5px;padding:5px 8px;font-weight:600; }
.standalone-go-board .gb-index-route { min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;opacity:.7; }
.standalone-go-board .gb-index-branch { grid-column:2;order:1;white-space:nowrap;color:#e9cc85; }
.standalone-go-board .gb-index-item .gb-index-comment { grid-column:1/-1;order:2;white-space:pre-wrap;overflow-wrap:anywhere;min-width:0;line-height:1.6;opacity:.85; }
.standalone-go-board .gb-index-item button:hover { background:#74b79516; }
.standalone-go-board[data-design-preset=light] .gb-index-branch { color:#526c36; }

.standalone-go-board #sgfLibraryDialog { --library-surface:#092820;--library-field:#123a30;--library-text:#f4e8c5;--library-muted:#c4d0bf;--library-border:#8b8057;--library-accent:#64d7aa;--library-selected:#1d4938; }
.standalone-go-board[data-design-preset=light] #sgfLibraryDialog { --library-surface:#fffdf7;--library-field:#fff;--library-text:#173e30;--library-muted:#576d5d;--library-border:#b5c0a3;--library-accent:#21664d;--library-selected:#edf5e8; }
/* Saved-game picker: board previews and match metadata. */
.standalone-go-board #sgfLibraryDialog { width:min(640px,calc(100vw - 32px)); max-width:640px; padding:16px; box-sizing:border-box;max-height:calc(100dvh - 24px);overflow:hidden;background:var(--library-surface);color:var(--library-text); }
.standalone-go-board #sgfLibraryDialog[open] { display:flex;flex-direction:column; }
.standalone-go-board #sgfLibraryDialog>header { flex-shrink:0;gap:12px; }
.standalone-go-board #sgfLibraryDialog :is(h2,button,strong) { text-shadow:none;box-shadow:none;background-image:none; }
.standalone-go-board #sgfLibraryDialog h2 { color:var(--library-text);font-size:20px; }
.standalone-go-board #sgfLibraryDialog #sgfLibraryClose { color:var(--library-text);background:var(--library-field); }
.standalone-go-board #sgfLibraryList { display:grid;gap:8px;max-height:52vh;min-height:0;flex:1 1 auto;overflow:auto;margin:10px 0; padding:2px; }
.standalone-go-board #sgfLibraryList button { display:grid;grid-template-columns:120px minmax(0,1fr);gap:14px;align-items:center;width:100%;text-align:left;white-space:normal;overflow-wrap:anywhere;padding:10px;border-radius:8px;background:var(--library-surface);color:var(--library-text);border:1px solid var(--library-border); }
.standalone-go-board #sgfLibraryList button[aria-pressed=true] { border:2px solid var(--library-accent);padding:9px;background:var(--library-selected); }
.standalone-go-board #sgfLibrarySearch { width:100%;box-sizing:border-box;min-height:38px;flex-shrink:0;background:var(--library-field);color:var(--library-text);border:1px solid var(--library-border);border-radius:8px;padding:8px 10px; }
.standalone-go-board #sgfLibrarySearch::placeholder { color:var(--library-muted);opacity:1; }
.standalone-go-board .gb-library-preview { display:grid;place-items:center;aspect-ratio:1;width:100%;min-width:0;overflow:hidden;border-radius:4px;background:#dab071;color:#3d321f;font-size:13px; }
.standalone-go-board .gb-library-preview svg { display:block;width:100%;height:auto;pointer-events:none; }
.standalone-go-board .gb-library-details { display:flex;flex-direction:column;gap:4px;min-width:0; }
.standalone-go-board .gb-library-details strong { font-size:16px;line-height:1.4;margin-bottom:2px; }
.standalone-go-board .gb-library-player { font-size:14px;line-height:1.4; }
.standalone-go-board .gb-library-result { font-size:14px;font-weight:700; }
.standalone-go-board .gb-library-meta { font-size:12px;line-height:1.4;color:var(--library-muted); }
.standalone-go-board .gb-library-footer { display:flex;flex-shrink:0;align-items:center;gap:12px;border-top:1px solid var(--library-border);padding-top:10px; }
.standalone-go-board #sgfLibrarySelected { flex:1;min-width:0;overflow-wrap:anywhere;font-size:14px; }
.standalone-go-board #sgfLibraryCancel { background:var(--library-surface);color:var(--library-text); }
.standalone-go-board #sgfLibraryLoad { background:#21664d;color:#fff;min-height:40px; }
@media(max-width:600px) {
 .standalone-go-board #sgfLibraryDialog { width:calc(100vw - 20px);padding:12px; }
 .standalone-go-board #sgfLibraryList { max-height:55dvh; }
 .standalone-go-board #sgfLibraryList button { grid-template-columns:100px minmax(0,1fr);gap:10px;padding:8px; }
 .standalone-go-board #sgfLibraryList button[aria-pressed=true] { padding:7px; }
 .standalone-go-board #sgfLibraryList button[aria-pressed=true] .gb-library-preview { max-width:100%;justify-self:center; }
 .standalone-go-board .gb-library-details strong { font-size:14px; }
 .standalone-go-board .gb-library-player { font-size:14px; }
 .standalone-go-board .gb-library-footer { flex-wrap:wrap;gap:8px; }
 .standalone-go-board #sgfLibrarySelected { flex-basis:100%; }
 .standalone-go-board #sgfLibraryLoad { flex:1; }
}

.standalone-go-board .gb-heading h1 .gb-brand-home { display:inline-block;margin-left:8px;font:400 12px/1.4 system-ui,sans-serif;color:inherit;text-decoration:none;vertical-align:middle; }
.standalone-go-board .gb-brand-home:hover { text-decoration:underline;text-underline-offset:3px; }
.standalone-go-board .gb-brand-home:focus-visible { outline:2px solid currentColor;outline-offset:3px;border-radius:2px; }
@media(max-width:760px) { .standalone-go-board .gb-heading h1 .gb-brand-home { font-size:10px;margin-left:5px; } }

@media(max-width:760px) {
 .standalone-go-board .gb-ai-heading .gb-continuous-switch { width:76px;min-width:76px;flex:0 0 76px; }
}

/* Home-screen install action follows the existing header and dialog styles. */
.standalone-go-board #homeInstallOpen { display:inline-flex;align-items:center;justify-content:center;gap:6px; }
.standalone-go-board #homeInstallOpen[hidden] { display:none; }
.standalone-go-board .gb-install-dialog ol { padding-left:24px;line-height:1.8; }
.standalone-go-board .gb-install-dialog li+li { margin-top:8px; }
@media(max-width:1200px) {
 .standalone-go-board .gb-header { flex-wrap:wrap; }
 .standalone-go-board .gb-header-actions { flex-wrap:wrap; }
 .standalone-go-board #homeInstallOpen { width:44px;padding:9px; }
 .standalone-go-board #homeInstallOpen span { display:none; }
}

/* Mobile move status and seek bar: one row, full available width. */
@media(max-width:760px) {
 .standalone-go-board #webNavigationSlot { width:100%;min-width:0;padding:0 0 8px;box-sizing:border-box; }
 .standalone-go-board #webNavigation .gb-seek-row { flex-direction:row;align-items:center;gap:8px;padding:2px 0; }
 .standalone-go-board #webNavigation .gb-move-status { white-space:nowrap; }
 .standalone-go-board #webMoveSeek { flex:1;min-width:0;width:100%; }
}

/* Mobile stone modes beside the operation heading; desktop retains the toolbar. */
.standalone-go-board .gb-mobile-stone-modes[hidden] { display:none; }
@media(max-width:760px) {
 .standalone-go-board .gb-operation-heading { flex-wrap:nowrap; }
 .standalone-go-board .gb-operation-heading h2 { white-space:nowrap; }
 .standalone-go-board .gb-mode-buttons.gb-mobile-stone-modes { display:grid;grid-template-columns:repeat(3,44px);flex:none;gap:4px;margin:0; }
 .standalone-go-board .gb-mobile-stone-modes button { height:44px;min-height:44px; }
 .standalone-go-board .gb-mobile-stone-modes .gb-pair-stones { width:30px;height:29px;transform:none; }
 .standalone-go-board .gb-mobile-stone-modes .gb-pair-stones i { width:20px;height:20px; }
 .standalone-go-board .gb-mode-buttons.gb-mark-toolbar:not(.gb-mobile-stone-modes) { grid-template-columns:repeat(6,minmax(0,42px)); }
}

@media(max-width:760px) {
 .standalone-go-board .gb-header-actions #boardShareOpen { flex:0 0 44px;width:44px;height:44px;min-height:44px;justify-content:center;padding:9px;gap:0; }
 .standalone-go-board .gb-header-actions #boardShareOpen span { display:none; }
 .standalone-go-board .gb-header-actions #boardShareOpen .gb-icon { width:22px;height:22px; }
 .standalone-go-board .gb-record-actions { grid-template-columns:repeat(3,minmax(0,1fr)); }
}

@media(max-width:760px) {
 .standalone-go-board .gb-header>.gb-account { display:flex;align-items:center;gap:6px; }
 .standalone-go-board .gb-account>#settingsOpen { display:inline-flex;align-items:center;justify-content:center;flex:0 0 44px;width:44px;height:44px;min-height:44px;padding:9px; }
 .standalone-go-board .gb-account>#settingsOpen .gb-icon { width:22px;height:22px; }
}

/* English controls need room for longer labels without widening the viewport. */
html:not([lang=ja]) .standalone-go-board .gb-header { flex-wrap:wrap; }
html:not([lang=ja]) .standalone-go-board .gb-heading { min-width:0; }
html:not([lang=ja]) .standalone-go-board .gb-record-actions button { white-space:normal;overflow-wrap:anywhere; }
html:not([lang=ja]) .standalone-go-board .gb-setting-row { gap:12px; }
html:not([lang=ja]) .standalone-go-board .gb-setting-row label { min-width:0; }
@media(max-width:760px) {
 html:not([lang=ja]) .standalone-go-board .gb-move-status { font-size:12px; }
 html:not([lang=ja]) .standalone-go-board .gb-operation-heading h2 { font-size:20px; }
 html:not([lang=ja]) .standalone-go-board .gb-ai-heading h2 { font-size:18px; }
 html:not([lang=ja]) .standalone-go-board .gb-header-captures { font-size:12px; }
}

html[lang=ko] .standalone-go-board :is(h1,h2,h3,label,button,p) { word-break:keep-all;overflow-wrap:break-word; }

/* Quiz composition: explicit confirmation before sharing. */
#boardShareQuizSteps { display:flex;flex-wrap:wrap;gap:6px;list-style:none;padding:0;margin:12px 0;font-size:13px; }
#boardShareQuizSteps li { flex:1;min-width:90px;padding:10px 6px;text-align:center;border-bottom:2px solid #9cae9f;opacity:.7; }
#boardShareQuizSteps li[aria-current=step] { opacity:1;font-weight:700;border-color:#248165; }
#boardShareQuizReady { padding:14px;margin:12px 0;border:1px solid currentColor;border-radius:8px; }
#boardShareQuizReady strong { font-size:17px; }
#boardShareChoiceConfirm { width:100%;margin-top:12px; }
#boardShareQuizSteps[hidden],#boardShareQuizReady[hidden],#boardShareNewActions[hidden],#boardShareCommentFields[hidden] { display:none; }

.gb-quiz-picker-heading { display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:12px 0; }
.gb-quiz-picker-heading h3 { margin:0;font-size:22px; }
#boardShareChoiceCount { padding:4px 10px;border:1px solid #819b80;border-radius:18px;font-size:13px; }
#boardShareChoicePicker .gb-quiz-answer-card { display:flex;align-items:center;gap:12px;padding:12px;border:1px solid #819b80;border-radius:8px; }
#boardShareChoicePicker .gb-quiz-check { display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:#21735a;color:white; }
#boardShareCorrectValue { font:700 24px/1.2 system-ui,sans-serif;flex:1; }
#boardShareChoicePicker #boardShareManualChange { padding:6px 14px;min-height:36px; }
#boardShareChoicePicker #boardShareManualControls { margin:12px 0; }
.gb-quiz-coordinate-row { display:flex;gap:8px; }
#boardShareChoicePicker #boardShareManualAnswer { flex:1;min-width:0;background:transparent;color:inherit;border:1px solid #819b80;border-radius:6px;padding:8px;font:inherit; }
#boardShareChoicePicker .gb-quiz-option-card { border:1px solid #819b80;border-radius:8px;padding:12px;margin-top:12px; }
#boardShareChoicePicker .gb-quiz-option-card header { display:flex;align-items:center;gap:12px;margin:0 0 10px; }
#boardShareCandidateChips { display:flex;flex-wrap:wrap;gap:8px; }
#boardShareChoicePicker .gb-quiz-choice-chip { background:#e9f3ff;color:#124c86;border:1px solid #4184bd;border-radius:6px;padding:8px 12px;font:600 16px/1.3 system-ui,sans-serif;min-height:40px; }
.gb-quiz-option-card small { display:block;text-align:right;margin-top:8px;opacity:.8; }
#boardShareChoiceHelp { font-size:13px;line-height:1.6; }
#boardShareChoicePicker .gb-quiz-sr-only { position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap; }
#boardShareChoicePicker [hidden] { display:none; }

.standalone-go-board #boardShareDialog[data-quiz-editor=true] { width:min(640px,calc(100vw - 28px)); }
#boardShareDialog[data-reply=false][data-quiz-editor=true][open] { grid-template-columns:minmax(0,1fr); }
#boardShareDialog[data-quiz-editor=true] #boardShareVisual { display:none; }
#boardShareDialog[data-reply=false][data-quiz-editor=true] .gb-share-compose { grid-column:1;margin:0 20px 20px; }
#boardShareDialog[data-reply=false][data-quiz-editor=true] #boardShareStatus { grid-column:1;margin:0 20px 20px; }

.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers .gb-login-x:not([hidden]) { background:#0f1419;background-image:none;color:#fff;border-color:#536471;box-shadow:none; }
.standalone-go-board #boardPurchaseDialog #boardLoginForm .gb-login-providers .gb-login-x:hover { background:#272c30;filter:none; }
.standalone-go-board #boardLoginx .auth-x-mark { width:20px;height:20px;flex:0 0 20px;display:block; }
