.hub-app {
  --hub-bg: var(--wb-bg);
  --hub-surface: var(--wb-surface);
  --hub-surface-strong: var(--wb-surface-strong);
  --hub-ink: var(--wb-ink);
  --hub-muted: var(--wb-muted);
  --hub-faint: var(--wb-faint);
  --hub-line: var(--wb-line);
  --hub-line-strong: var(--wb-line-strong);
  --hub-accent: var(--wb-accent);
  --hub-accent-soft: var(--wb-accent-soft);
  --hub-mint: var(--wb-mint);
  --hub-mint-soft: var(--wb-mint-soft);
  --hub-coral: var(--wb-coral);
  --hub-coral-soft: var(--wb-coral-soft);
  background: var(--hub-bg);
}

.hub-app .wb-topbar { border-bottom-color: var(--hub-line); background: color-mix(in srgb, var(--hub-bg) 94%, transparent); }
.hub-app .wb-topbar-inner { width: min(1420px, calc(100% - 56px)); min-height: 72px; }
.hub-app .wb-nav-link.is-active { color: var(--hub-ink); border: 1px solid var(--hub-line); background: var(--hub-surface); }
.hub-app .wb-main { width: min(1420px, calc(100% - 56px)); padding-top: 54px; }
.hub-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(210px, 270px); align-items: end; gap: 40px; padding-bottom: 42px; border-bottom: 1px solid var(--hub-line); }
.hub-title { max-width: 760px; margin: 0; color: var(--hub-ink); font: 600 clamp(2.5rem, 5vw, 4.5rem)/1.08 Sora, "Noto Sans SC", sans-serif; }
.hub-subtitle { max-width: 650px; margin: 16px 0 0; color: var(--hub-muted); font-size: .94rem; line-height: 1.8; }
.hub-hero-status { display: grid; justify-items: end; gap: 5px; padding: 17px 18px; border: 1px solid var(--hub-line-strong); background: var(--hub-surface); text-align: right; }
.hub-status-line { display: inline-flex; align-items: center; gap: 8px; color: var(--hub-muted); font-size: .68rem; }
.hub-hero-status strong { color: var(--hub-ink); font: 600 1.7rem/1.15 Sora, sans-serif; font-variant-numeric: tabular-nums; }
.hub-hero-status small { color: var(--hub-faint); font-size: .65rem; }
.hub-hero-status a { color: var(--hub-accent); font-size: .7rem; font-weight: 760; text-decoration: none; }
.hub-route { display: grid; grid-template-columns: 1fr 48px 1fr 48px 1fr; align-items: center; gap: 12px; padding: 20px 0 26px; }
.hub-route > i { height: 1px; background: var(--hub-line-strong); }
.hub-route-step { display: grid; grid-template-columns: auto 1fr; column-gap: 10px; align-items: baseline; min-width: 0; color: var(--hub-faint); }
.hub-route-step > span { grid-row: span 2; color: var(--hub-faint); font: 700 .66rem/1 Sora, sans-serif; }
.hub-route-step strong { overflow: hidden; color: var(--hub-muted); font-size: .75rem; text-overflow: ellipsis; white-space: nowrap; }
.hub-route-step small { overflow: hidden; color: var(--hub-faint); font-size: .65rem; text-overflow: ellipsis; white-space: nowrap; }
.hub-route-step.is-current > span, .hub-route-step.is-current strong { color: var(--hub-accent); }
.hub-section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 15px; }
.hub-section-heading h2 { margin: 5px 0 0; color: var(--hub-ink); font: 600 1.32rem/1.2 Sora, "Noto Sans SC", sans-serif; }
.hub-route-badge { max-width: 48%; overflow: hidden; padding: 7px 9px; border: 1px solid var(--hub-line); color: var(--hub-muted); background: var(--hub-surface); font-size: .64rem; text-overflow: ellipsis; white-space: nowrap; }
.hub-route-badge.is-ready { color: var(--hub-mint); border-color: color-mix(in srgb, var(--hub-mint) 40%, var(--hub-line)); background: var(--hub-mint-soft); }
.hub-route-badge.is-warn { color: var(--hub-coral); border-color: color-mix(in srgb, var(--hub-coral) 35%, var(--hub-line)); background: var(--hub-coral-soft); }
.hub-tool-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 12px; }
.hub-tool { position: relative; display: flex; min-width: 0; min-height: 194px; grid-column: span 3; flex-direction: column; justify-content: space-between; gap: 24px; padding: 20px; border: 1px solid var(--hub-line); color: var(--hub-ink); background: var(--hub-surface); text-decoration: none; transition: border-color .18s ease, transform .18s ease, background-color .18s ease; }
.hub-tool:hover { border-color: var(--hub-line-strong); background: var(--hub-surface-strong); transform: translateY(-3px); }
.hub-tool.is-featured { grid-column: span 6; min-height: 238px; background: var(--hub-surface-strong); }
.hub-tool-number { color: var(--hub-accent); font: 700 .66rem/1 Sora, sans-serif; }
.hub-tool-copy { display: grid; min-width: 0; gap: 7px; }
.hub-tool-copy small { color: var(--hub-faint); font: 700 .58rem/1 Sora, sans-serif; letter-spacing: .08em; }
.hub-tool-copy strong { color: var(--hub-ink); font: 600 1.25rem/1.25 Sora, "Noto Sans SC", sans-serif; }
.hub-tool.is-featured .hub-tool-copy strong { font-size: 1.8rem; }
.hub-tool-copy > span { max-width: 36ch; color: var(--hub-muted); font-size: .72rem; line-height: 1.6; }
.hub-tool-action { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px solid var(--hub-line); color: var(--hub-accent); font-size: .68rem; font-weight: 800; }
.hub-tool-action b { font-size: 1rem; font-weight: 500; }
.hub-tool-chat { border-color: color-mix(in srgb, var(--hub-accent) 38%, var(--hub-line)); }
.hub-tool-image .hub-tool-number, .hub-tool-image .hub-tool-action { color: var(--hub-mint); }
.hub-tool-site .hub-tool-number, .hub-tool-site .hub-tool-action { color: var(--hub-coral); }
.hub-lower { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(280px, .85fr); gap: 18px; align-items: start; padding-top: 48px; }
.hub-account-wrap .wb-account-panel { box-shadow: none; }
.hub-principles { min-width: 0; padding: 20px 0 0; border-top: 1px solid var(--hub-line-strong); }
.hub-principles h2 { max-width: 15ch; margin: 9px 0 13px; color: var(--hub-ink); font: 600 1.35rem/1.3 Sora, "Noto Sans SC", sans-serif; }
.hub-principles > p:not(.wb-panel-index) { max-width: 42ch; margin: 0; color: var(--hub-muted); font-size: .75rem; line-height: 1.75; }
.hub-principle-list { display: grid; gap: 0; margin-top: 25px; border-top: 1px solid var(--hub-line); }
.hub-principle-list > div { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 7px; padding: 12px 0; border-bottom: 1px solid var(--hub-line); }
.hub-principle-list span { color: var(--hub-accent); font: 700 .65rem/1 Sora, sans-serif; }
.hub-principle-list strong { color: var(--hub-ink); font-size: .74rem; }
.hub-principle-list small { grid-column: 2; color: var(--hub-faint); font-size: .67rem; line-height: 1.5; }
.hub-experiment { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 22px; padding: 11px 0; border-bottom: 1px solid var(--hub-line); color: var(--hub-muted); font-size: .68rem; text-decoration: none; }
.hub-experiment:hover { color: var(--hub-accent); }
.hub-retention-note { display: grid; gap: 5px; margin-top: 20px; padding: 12px 13px; border-left: 2px solid var(--hub-accent); background: color-mix(in srgb, var(--hub-accent) 6%, transparent); color: var(--hub-muted); font-size: .68rem; line-height: 1.6; }
.hub-retention-note strong { color: var(--hub-ink); font-size: .72rem; }
.hub-login { margin: 68px auto; }
.hub-login h1 { font-size: 2.2rem; }
.hub-login .wb-button { display: inline-flex; width: max-content; align-items: center; gap: 8px; text-decoration: none; }

@media (max-width: 980px) {
  .hub-hero { grid-template-columns: 1fr; gap: 22px; }
  .hub-hero-status { justify-items: start; width: max-content; max-width: 100%; text-align: left; }
  .hub-tool.is-featured { grid-column: span 12; }
  .hub-tool:not(.is-featured) { grid-column: span 6; }
  .hub-lower { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .hub-app .wb-topbar-inner, .hub-app .wb-main { width: min(100% - 28px, 1420px); }
  .hub-app .wb-topbar-inner { min-height: 60px; }
  .hub-app .wb-main { padding-top: 34px; }
  .hub-title { font-size: 2.5rem; }
  .hub-subtitle { font-size: .82rem; }
  .hub-route { grid-template-columns: 1fr; gap: 9px; padding: 18px 0 25px; }
  .hub-route > i { width: 1px; height: 18px; margin-left: 13px; }
  .hub-route-step { grid-template-columns: 27px minmax(0, 1fr); }
  .hub-tool.is-featured, .hub-tool:not(.is-featured) { grid-column: span 12; min-height: 170px; }
  .hub-tool.is-featured { min-height: 205px; }
  .hub-section-heading { align-items: start; flex-direction: column; gap: 12px; }
  .hub-route-badge { max-width: 100%; }
  .hub-login { margin: 42px auto; padding: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  .hub-tool { transition: none; }
  .hub-tool:hover { transform: none; }
}

/* v2: a calm launch surface for the three connected workspaces. */
.wb-shell.hub-app .wb-main {
  width: min(1280px, calc(100% - 48px));
  padding-top: 48px;
}

.wb-shell.hub-app .hub-hero {
  grid-template-columns: minmax(0, 1fr) 250px;
  gap: 48px;
  padding-bottom: 36px;
  border-bottom-color: var(--hub-line);
}

.wb-shell.hub-app .hub-title {
  max-width: 720px;
  font-family: inherit;
  font-size: 3rem;
  font-weight: 650;
  line-height: 1.12;
  letter-spacing: 0;
}

.wb-shell.hub-app .hub-subtitle {
  max-width: 620px;
  margin-top: 14px;
  font-size: .88rem;
  line-height: 1.72;
}

.wb-shell.hub-app .hub-hero-status {
  gap: 5px;
  border-color: var(--hub-line);
  border-radius: 8px;
  padding: 16px;
  background: var(--hub-surface);
}

.wb-shell.hub-app .hub-hero-status strong {
  font-family: inherit;
  font-size: 1.55rem;
  font-weight: 650;
}

.wb-shell.hub-app .hub-route { padding: 17px 0 28px; }
.wb-shell.hub-app .hub-route-step > span { font-family: inherit; font-weight: 650; }
.wb-shell.hub-app .hub-section-heading h2,
.wb-shell.hub-app .hub-principles h2 {
  font-family: inherit;
  font-weight: 650;
  letter-spacing: 0;
}

.wb-shell.hub-app .hub-route-badge {
  border-radius: 999px;
  padding: 6px 9px;
  background: var(--hub-surface-strong);
}

.wb-shell.hub-app .hub-tool-grid { gap: 12px; }

.wb-shell.hub-app .hub-tool {
  min-height: 184px;
  border-color: var(--hub-line);
  border-radius: 8px;
  padding: 19px;
  background: var(--hub-surface);
  transition: border-color .16s ease, transform .16s ease, background-color .16s ease;
}

.wb-shell.hub-app .hub-tool:hover {
  border-color: var(--hub-line-strong);
  background: var(--hub-surface-strong);
  transform: translateY(-2px);
}

.wb-shell.hub-app .hub-tool.is-featured {
  min-height: 222px;
  border-color: var(--hub-ink);
  color: var(--hub-bg);
  background: var(--hub-ink);
}

.wb-shell.hub-app .hub-tool.is-featured:hover {
  border-color: var(--hub-ink);
  background: color-mix(in srgb, var(--hub-ink) 92%, var(--hub-accent));
}

.wb-shell.hub-app .hub-tool-number,
.wb-shell.hub-app .hub-tool-copy small {
  font-family: inherit;
  letter-spacing: 0;
}

.wb-shell.hub-app .hub-tool-copy strong {
  font-family: inherit;
  font-size: 1.18rem;
  font-weight: 650;
  letter-spacing: 0;
}

.wb-shell.hub-app .hub-tool.is-featured .hub-tool-copy strong { font-size: 1.65rem; }
.wb-shell.hub-app .hub-tool.is-featured .hub-tool-number,
.wb-shell.hub-app .hub-tool.is-featured .hub-tool-copy small,
.wb-shell.hub-app .hub-tool.is-featured .hub-tool-copy strong,
.wb-shell.hub-app .hub-tool.is-featured .hub-tool-copy > span,
.wb-shell.hub-app .hub-tool.is-featured .hub-tool-action { color: var(--hub-bg); }
.wb-shell.hub-app .hub-tool.is-featured .hub-tool-action { border-top-color: color-mix(in srgb, var(--hub-bg) 22%, transparent); }
.wb-shell.hub-app .hub-tool-action { font-size: .67rem; }
.wb-shell.hub-app .hub-lower { gap: 24px; padding-top: 44px; }
.wb-shell.hub-app .hub-principles { border-top-color: var(--hub-line); }
.wb-shell.hub-app .hub-principle-list span { font-family: inherit; }

@media (max-width: 980px) {
  .wb-shell.hub-app .hub-hero { grid-template-columns: 1fr; gap: 24px; }
  .wb-shell.hub-app .hub-hero-status { justify-items: start; width: min(100%, 280px); text-align: left; }
}

@media (max-width: 700px) {
  .wb-shell.hub-app .wb-main { width: calc(100% - 24px); padding-top: 30px; }
  .wb-shell.hub-app .hub-title { font-size: 2.2rem; }
  .wb-shell.hub-app .hub-route { gap: 8px; }
  .wb-shell.hub-app .hub-tool.is-featured,
  .wb-shell.hub-app .hub-tool:not(.is-featured) { min-height: 164px; }
  .wb-shell.hub-app .hub-tool.is-featured { min-height: 190px; }
}

/* v4: the hub follows the conversation shell and makes the next action explicit. */
.wb-shell.hub-app .wb-main { padding-top: 38px; }
.wb-shell.hub-app .hub-hero { grid-template-columns: minmax(0, 1fr) 230px; gap: 32px; padding-bottom: 24px; }
.wb-shell.hub-app .hub-title { max-width: 650px; font-family: inherit; font-size: 2.25rem; font-weight: 650; line-height: 1.15; }
.wb-shell.hub-app .hub-subtitle { max-width: 600px; margin-top: 11px; font-size: .82rem; line-height: 1.7; }
.wb-shell.hub-app .hub-hero-status { gap: 4px; border-color: var(--hub-line); border-radius: 12px; padding: 14px; }
.wb-shell.hub-app .hub-hero-status strong { font-family: inherit; font-size: 1.38rem; }
.wb-shell.hub-app .hub-route { padding: 14px 0 20px; }
.wb-shell.hub-app .hub-section-heading { margin-bottom: 12px; }
.wb-shell.hub-app .hub-section-heading h2, .wb-shell.hub-app .hub-principles h2 { font-family: inherit; font-weight: 650; letter-spacing: 0; }
.wb-shell.hub-app .hub-route-badge { border-radius: 999px; }
.wb-shell.hub-app .hub-tool { min-height: 166px; border-radius: 14px; padding: 17px; }
.wb-shell.hub-app .hub-tool.is-featured { min-height: 194px; }
.wb-shell.hub-app .hub-tool.is-featured .hub-tool-copy strong { font-size: 1.45rem; }
.wb-shell.hub-app .hub-lower { gap: 20px; padding-top: 34px; }
.hub-guide { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 0 0 28px; padding: 14px 16px; border: 1px solid var(--hub-line); border-radius: 12px; background: var(--hub-surface); }
.hub-guide-copy { display: grid; min-width: 0; gap: 3px; }
.hub-guide-copy .wb-panel-index { margin-bottom: 2px; }
.hub-guide-copy h2 { margin: 0; color: var(--hub-ink); font-size: .92rem; font-weight: 700; }
.hub-guide-copy p:not(.wb-panel-index) { margin: 0; color: var(--hub-muted); font-size: .72rem; line-height: 1.55; }
.hub-guide-action { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 7px; width: auto; text-decoration: none; }

@media (max-width: 780px) {
  .wb-shell.hub-app .wb-main { padding-top: 28px; }
  .wb-shell.hub-app .hub-hero { grid-template-columns: 1fr; gap: 17px; }
  .wb-shell.hub-app .hub-hero-status { width: min(100%, 260px); }
  .wb-shell.hub-app .hub-title { font-size: 2rem; }
  .hub-guide { align-items: stretch; flex-direction: column; gap: 12px; margin-bottom: 22px; }
  .hub-guide-action { justify-content: center; }
}
