.hgo { max-width: 1180px; margin: 0 auto; padding: 28px 0 56px; color: #eef7ff; }
.hgo-header { padding: 30px 0 24px; max-width: 860px; }
.hgo-header h1 { margin: 6px 0 10px; font-size: clamp(2rem, 5vw, 3.2rem); line-height: 1.08; letter-spacing: 0; }
.hgo-header > p:not(.eyebrow) { color: #a9bed0; font-size: 1.05rem; }
.hgo-steps { display: flex; flex-wrap: wrap; gap: 10px; padding: 0; margin: 22px 0 0; list-style: none; }
.hgo-steps li { display: flex; align-items: center; gap: 8px; color: #c7d8e5; font-weight: 700; }
.hgo-steps strong { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid #4facc8; border-radius: 50%; color: #7de3ff; }
.hgo-section, .hgo-results { margin-top: 18px; padding: 22px; border: 1px solid rgba(125,211,252,.18); border-radius: 8px; background: rgba(7,17,31,.78); box-shadow: 0 14px 42px rgba(0,0,0,.2); }
.hgo-section__heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 18px; margin-bottom: 18px; }
.hgo-section__heading h2 { margin: 3px 0 0; font-size: 1.35rem; letter-spacing: 0; }
.hgo-section__heading p { color: #9db2c4; margin: 5px 0 0; }
.hgo-quick-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.hgo-quick-actions button, .hgo-dialog button { min-height: 42px; }
.hgo-quick-actions .secondary, .hgo-dialog .secondary { border: 1px solid #34556b; background: transparent; color: #d6e7f1; }
.hgo-board { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 14px; }
.hgo-troop { min-width: 0; }
.hgo-troop__title { margin: 0 0 10px; padding-bottom: 9px; border-bottom: 2px solid var(--troop-color); color: #fff; font-size: 1rem; }
.hgo-troop__pieces { display: grid; gap: 9px; }
.hgo-piece { display: grid; grid-template-columns: 52px minmax(0,1fr) 36px; gap: 11px; align-items: center; min-height: 82px; width: 100%; padding: 10px; border: 1px solid rgba(148,163,184,.18); border-radius: 7px; background: rgba(12,28,45,.82); color: inherit; text-align: left; cursor: pointer; }
.hgo-piece:hover, .hgo-piece:focus-visible { border-color: var(--troop-color); box-shadow: 0 0 18px color-mix(in srgb, var(--troop-color) 22%, transparent); }
.hgo-piece img { width: 48px; height: 48px; object-fit: contain; }
.hgo-piece__placeholder { display: grid; place-items: center; width: 48px; height: 48px; border: 1px dashed #486176; border-radius: 5px; color: #7f96a8; font-size: .62rem; line-height: 1.05; text-align: center; }
.hgo-piece__copy { min-width: 0; }
.hgo-piece__copy strong, .hgo-piece__copy span { display: block; }
.hgo-piece__copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hgo-piece__copy span { margin-top: 3px; color: #9eb4c5; font-size: .78rem; line-height: 1.3; }
.hgo-piece__edit { font-size: 1.1rem; color: #7de3ff; text-align: center; }
.hgo-resource-grid { display: grid; grid-template-columns: 2fr repeat(3,minmax(0,1fr)); gap: 12px; align-items: stretch; }
.hgo-resource-grid label, .hgo-dialog label { display: grid; gap: 7px; color: #c9d9e5; font-weight: 700; }
.hgo-resource-grid input, .hgo-dialog input, .hgo-dialog select { width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid #314c62; border-radius: 6px; background: #091827; color: #fff; font: inherit; }
.hgo-xp-calculator { min-width: 0; margin: 0; padding: 14px; border: 1px solid #2d4d62; border-radius: 7px; background: rgba(10,27,42,.75); }
.hgo-xp-calculator legend { padding: 0 5px; color: #e7f4fb; font-weight: 900; }
.hgo-xp-modes { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 12px; }
.hgo-xp-modes label { position: relative; display: block; cursor: pointer; }
.hgo-xp-modes input { position: absolute; opacity: 0; pointer-events: none; }
.hgo-xp-modes span { display: block; padding: 7px 9px; border: 1px solid #38566b; border-radius: 5px; color: #a9bfcd; font-size: .75rem; }
.hgo-xp-modes input:checked + span { border-color: #4ce3b6; background: rgba(76,227,182,.1); color: #83ebcc; }
.hgo-xp-modes input:focus-visible + span { outline: 3px solid rgba(125,211,252,.7); outline-offset: 2px; }
.hgo-xp-items { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
.hgo-resource-grid .hgo-xp-item { display: grid; grid-template-columns: 42px minmax(0,1fr); gap: 8px 10px; align-items: center; padding: 10px; border: 1px solid rgba(148,163,184,.14); border-radius: 6px; background: #091827; }
.hgo-xp-item__icon { grid-row: 1 / 3; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 6px; color: #fff; font-size: .72rem; font-weight: 900; box-shadow: inset 0 0 0 1px rgba(255,255,255,.22); }
.hgo-xp-item__icon.is-green { background: #217b55; }
.hgo-xp-item__icon.is-purple { background: #684aa2; }
.hgo-xp-item__copy strong, .hgo-xp-item__copy small { display: block; }
.hgo-xp-item__copy small { margin-top: 2px; color: #8fa7b7; font-size: .7rem; }
.hgo-xp-item input { grid-column: 1 / -1; }
.hgo-xp-total { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-top: 1px solid rgba(125,211,252,.18); color: #a9bdca; }
.hgo-xp-total strong { color: #87ebcd; font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.hgo-resource-grid .hgo-xp-manual { display: grid; }
.hgo-xp-items[hidden], .hgo-xp-manual[hidden] { display: none !important; }
.hgo-xp-error { margin: 9px 0 0; color: #fecaca; font-size: .78rem; }
.hgo-xp-calculator input[aria-invalid="true"] { border-color: #f87171; }
.hgo-note, .hgo-after { margin-top: 14px; color: #a9bdcb; }
.hgo-note summary, .hgo-after summary { cursor: pointer; color: #d8e8f2; font-weight: 800; }
.hgo-profile-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.hgo-profile { position: relative; display: block; padding: 14px; border: 1px solid #2d465a; border-radius: 7px; background: #0b1b2a; cursor: pointer; }
.hgo-profile input { position: absolute; opacity: 0; pointer-events: none; }
.hgo-profile strong, .hgo-profile span { display: block; }
.hgo-profile span { margin-top: 5px; color: #9fb4c4; font-size: .84rem; }
.hgo-profile:has(input:checked) { border-color: #4ce3b6; box-shadow: inset 3px 0 #4ce3b6; }
.hgo-submit-wrap { display: grid; justify-items: center; gap: 10px; padding: 24px 0 6px; }
.hgo-submit { width: min(100%,460px); min-height: 58px; border: 0; border-radius: 7px; background: #4ce3b6; color: #06151a; font-size: 1.08rem; font-weight: 900; cursor: pointer; }
.hgo-submit[disabled] { opacity: .6; cursor: wait; }
.hgo-error { color: #fecaca; text-align: center; }
.hgo-best { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px 18px; padding: 20px; border-left: 4px solid #f1c75b; border-radius: 6px; background: rgba(241,199,91,.08); }
.hgo-best h3 { margin: 0 0 7px; }
.hgo-best p { margin: 5px 0; color: #cad9e3; }
.hgo-best > .eyebrow, .hgo-best > h3, .hgo-best > .hgo-best__target, .hgo-best > .hgo-best__reason, .hgo-best > .hgo-action-cost, .hgo-best > .hgo-best__includes, .hgo-best > .hgo-stat-gains { grid-column: 1 / -1; }
.hgo-best__target { color: #fff !important; font-size: 1.18rem; font-weight: 900; }
.hgo-best__context { padding: 11px 12px; border: 1px solid rgba(125,211,252,.18); border-radius: 6px; background: rgba(7,19,31,.55); }
.hgo-best__context span, .hgo-best__context strong { display: block; }
.hgo-best__context span { margin-bottom: 4px; color: #91a9b9; font-size: .72rem; font-weight: 800; text-transform: uppercase; }
.hgo-best__includes { padding: 10px 12px; border-left: 2px solid rgba(241,199,91,.55); }
.hgo-best__includes ul { display: grid; gap: 4px; margin: 7px 0 0; padding-left: 20px; color: #c9d9e4; }
.hgo-costs { display: flex; flex-wrap: wrap; gap: 8px; }
.hgo-cost { padding: 7px 10px; border: 1px solid rgba(125,211,252,.22); border-radius: 5px; background: rgba(125,211,252,.1); color: #e9faff; font-size: .82rem; font-weight: 800; }
.hgo-action-cost { display: grid; gap: 6px; margin-top: 12px; }
.hgo-action-cost__label { color: #91a8b8; font-size: .74rem; font-weight: 800; text-transform: uppercase; }
.hgo-stat-gains { display: grid; gap: 7px; margin-top: 12px; }
.hgo-stat-gains__label { color: #91a8b8; font-size: .74rem; font-weight: 800; text-transform: uppercase; }
.hgo-stat-gains__list { display: flex; flex-wrap: wrap; gap: 7px; }
.hgo-stat-gains__group { display: grid; gap: 5px; }
.hgo-stat-gains__source { color: #a8bdca; font-size: .7rem; font-weight: 800; text-transform: uppercase; }
.hgo-stat-gain { padding: 7px 9px; border: 1px solid rgba(76,227,182,.25); border-radius: 5px; background: rgba(76,227,182,.09); color: #8ff0d1; font-size: .8rem; }
.hgo-stat-gains__empty { margin: 0; color: #a9bdca; font-size: .8rem; line-height: 1.4; }
.hgo-result-panel { margin-top: 14px; padding: 18px; border: 1px solid rgba(148,163,184,.15); border-radius: 7px; background: #091827; }
.hgo-result-panel h3 { margin-top: 0; }
.hgo-result-panel__intro { margin: -4px 0 14px; color: #93a9b9; font-size: .82rem; }
.hgo-plan-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.hgo-plan-filters { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.hgo-filter { min-height: 36px; padding: 7px 10px; border: 1px solid #34556b; border-radius: 5px; background: transparent; color: #b9cfdd; font-weight: 800; cursor: pointer; }
.hgo-filter.is-active { border-color: #4ce3b6; background: rgba(76,227,182,.12); color: #7cebc9; }
.hgo-filter:focus-visible, .hgo-after summary:focus-visible, .hgo-raw-details summary:focus-visible { outline: 3px solid rgba(125,211,252,.7); outline-offset: 2px; }
.hgo-timeline { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; margin: 14px 0 0; padding: 0; list-style: none; counter-reset: hgo-plan; }
.hgo-action-card { position: relative; min-width: 0; padding: 15px 15px 15px 48px; border: 1px solid rgba(148,163,184,.16); border-radius: 7px; background: rgba(13,31,47,.72); }
.hgo-action-card__number { position: absolute; top: 14px; left: 14px; display: grid; place-items: center; width: 25px; height: 25px; border-radius: 50%; background: #183b4c; color: #8debd0; font-size: .75rem; font-weight: 900; }
.hgo-action-card small { display: block; color: #98adbd; margin-top: 5px; }
.hgo-action-card__piece, .hgo-action-card__target { display: block; }
.hgo-action-card__piece { color: #f4f9fc; font-size: .96rem; }
.hgo-action-card__target { margin-top: 4px; color: #a9c3d3; font-size: .84rem; font-weight: 700; }
.hgo-action-card__reason { margin-top: 12px; padding-top: 10px; border-top: 1px solid rgba(148,163,184,.12); }
.hgo-action-card__reason span { color: #91a8b8; font-size: .72rem; font-weight: 800; text-transform: uppercase; }
.hgo-action-card__reason p { margin: 4px 0 0; color: #b9ccd8; font-size: .8rem; line-height: 1.45; }
.hgo-timeline__heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.hgo-timeline__count { flex: 0 0 auto; padding: 3px 6px; border-radius: 4px; background: rgba(76,227,182,.1); color: #78e8c6; font-size: .68rem; font-weight: 800; }
.hgo-resource-summary { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 9px; }
.hgo-resource-card { display: grid; grid-template-columns: 1fr auto; gap: 7px 12px; padding: 12px; border: 1px solid rgba(125,211,252,.14); border-radius: 6px; background: rgba(12,29,45,.72); }
.hgo-resource-card__name { grid-column: 1 / -1; padding-bottom: 6px; border-bottom: 1px solid rgba(148,163,184,.12); color: #e7f4fb; }
.hgo-resource-card__metric { display: contents; }
.hgo-resource-card__metric span { color: #8fa7b7; font-size: .74rem; }
.hgo-resource-card__metric strong { color: #fff; font-variant-numeric: tabular-nums; text-align: right; }
.hgo-resource-card__origin { grid-column: 1 / -1; padding-top: 6px; border-top: 1px solid rgba(148,163,184,.1); color: #8fa7b7; font-size: .68rem; }
.hgo-after .hgo-board { margin-top: 14px; }
.hgo-board--preview .hgo-piece.is-unchanged { opacity: .48; }
.hgo-board--preview .hgo-piece.is-changed { border-color: rgba(76,227,182,.55); box-shadow: inset 3px 0 #4ce3b6; }
.hgo-piece__change { color: #75ddbf !important; font-size: .68rem !important; white-space: normal; }
.hgo-piece__changed-label { display: inline-block !important; width: fit-content; margin-top: 4px; padding: 2px 5px; border-radius: 3px; background: rgba(76,227,182,.12); color: #88e9cc; font-size: .62rem; text-transform: uppercase; }
.hgo-plan-empty { margin-top: 12px; padding: 14px; border: 1px dashed #3b596d; border-radius: 6px; color: #b5c9d5; text-align: center; }
.hgo-plan-empty p { margin: 0 0 4px; font-weight: 800; }
.hgo-plan-empty small { display: block; margin-bottom: 10px; color: #8fa6b5; }
.hgo-preview-legend { color: #91a8b8; font-size: .78rem; }
.hgo-raw-details { margin-top: 14px; padding: 14px; border: 1px solid rgba(148,163,184,.15); border-radius: 7px; background: rgba(9,24,39,.75); }
.hgo-raw-details summary { cursor: pointer; color: #d8e8f2; font-weight: 800; }
.hgo-raw-list { display: grid; gap: 8px; margin: 12px 0; padding: 0; list-style: none; }
.hgo-raw-action { padding: 11px; border: 1px solid rgba(148,163,184,.12); border-radius: 6px; background: rgba(13,31,47,.7); }
.hgo-raw-action .hgo-stat-gains, .hgo-raw-action .hgo-action-cost { margin-top: 8px; }
.hgo-warnings { margin-top: 14px; color: #f7d68a; }
.hgo-disclaimer { margin: 18px 0 0; padding: 12px; color: #8299aa; font-size: .78rem; text-align: center; }
.hgo-dialog { width: min(92vw,500px); max-height: 90vh; padding: 0; border: 1px solid #3b6278; border-radius: 8px; background: #07131f; color: #fff; }
.hgo-dialog::backdrop { background: rgba(1,7,13,.78); backdrop-filter: blur(4px); }
.hgo-dialog__panel { display: grid; gap: 14px; padding: 20px; }
.hgo-dialog__header { display: flex; justify-content: space-between; align-items: flex-start; }
.hgo-dialog__header h2 { margin: 2px 0 0; }
.hgo-dialog__close { width: 44px; padding: 0; border: 0; background: transparent; color: #cde5f3; font-size: 1.8rem; cursor: pointer; }
.hgo-editor-help { margin: 0; min-height: 20px; color: #8fb0c3; font-size: .82rem; }
.hgo-dialog__actions { display: flex; justify-content: flex-end; gap: 9px; }

@media (max-width: 800px) {
  .hgo { padding-top: 12px; }
  .hgo-section, .hgo-results { padding: 16px; }
  .hgo-section__heading { align-items: flex-start; flex-direction: column; }
  .hgo-board, .hgo-profile-grid, .hgo-timeline { grid-template-columns: 1fr; }
  .hgo-plan-heading { align-items: flex-start; flex-direction: column; }
  .hgo-plan-filters { justify-content: flex-start; }
  .hgo-resource-summary { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .hgo-troop__pieces { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .hgo-resource-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .hgo-xp-calculator { grid-column: 1 / -1; }
}
@media (max-width: 520px) {
  .hgo-troop__pieces, .hgo-resource-grid { grid-template-columns: 1fr; }
  .hgo-xp-items { grid-template-columns: 1fr; }
  .hgo-best { grid-template-columns: 1fr; }
  .hgo-best > * { grid-column: 1 !important; }
  .hgo-resource-summary { grid-template-columns: 1fr; }
  .hgo-quick-actions { width: 100%; }
  .hgo-quick-actions button { flex: 1 1 100%; }
  .hgo-dialog { width: 100%; max-width: none; margin: auto 0 0; border-radius: 8px 8px 0 0; }
  .hgo-dialog__panel { padding: 18px 16px max(18px,env(safe-area-inset-bottom)); }
}
