.hero-workbench {
  position: relative;
  isolation: isolate;
  min-height: calc(100svh - var(--header-height) - 64px);
  display: grid;
  align-content: center;
  justify-items: center;
  padding-top: 20px;
  padding-bottom: 0;
  overflow-x: clip;
}

.hero-workbench__grid {
  position: absolute;
  inset: 0 0 auto;
  z-index: -1;
  height: 66%;
  pointer-events: none;
  background-image:
    linear-gradient(var(--color-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-grid) 1px, transparent 1px);
  background-position: center top;
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 54% 74% at 50% 32%, var(--color-text) 0%, var(--color-veil) 48%, transparent 100%);
  mask-image: radial-gradient(ellipse 54% 74% at 50% 32%, var(--color-text) 0%, var(--color-veil) 48%, transparent 100%);
}

.hero-workbench__copy {
  display: flex;
  max-width: 840px;
  align-items: center;
  flex-direction: column;
  text-align: center;
}

.hero-eyebrow {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 10px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  color: var(--color-muted);
  box-shadow: 0 1px 2px var(--color-shadow-soft);
  font-size: 13px;
  font-weight: 550;
}

.hero-eyebrow__dot {
  position: relative;
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
}

.hero-eyebrow__dot::after {
  position: absolute;
  inset: -4px;
  border: 1.5px solid var(--color-accent);
  border-radius: var(--radius-pill);
  content: "";
  opacity: 0;
  animation: badge-breathe 2.6s ease-out infinite;
}

@keyframes badge-breathe {
  0% {
    opacity: 0.7;
    transform: scale(0.55);
  }

  70%,
  100% {
    opacity: 0;
    transform: scale(1.35);
  }
}

.hero-workbench__title {
  margin: 22px 0 16px;
  font-size: clamp(34px, 3.6vw, 48px);
  line-height: 1.16;
  letter-spacing: -0.02em;
}

.hero-workbench__title span {
  display: block;
}

.hero-workbench__title .accent-line {
  color: var(--color-accent);
}

.hero-workbench__lead {
  max-width: 660px;
  margin-bottom: 0;
  color: var(--color-muted);
  font-size: 17px;
  line-height: 1.72;
}

.hero-workbench__lead strong {
  color: var(--color-text);
}

.hero-workbench .button-row {
  justify-content: center;
  margin-top: 28px;
}

.platform-row,
.fact-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 0;
  padding: 0;
  list-style: none;
}

.platform-row {
  gap: 10px;
  margin-top: 30px;
}

.platform-chip {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 11px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  color: var(--color-muted);
  font-size: 13px;
  font-weight: 550;
  transition: color var(--transition-fast), border-color var(--transition-fast);
}

.platform-chip svg {
  width: 15px;
  height: 15px;
  color: var(--color-text);
}

.platform-chip:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-dark);
}

.platform-chip:hover svg {
  color: var(--color-accent);
}

.fact-row {
  gap: 8px;
  margin-top: 12px;
}

.hero-stage {
  display: flex;
  width: 100%;
  max-width: 940px;
  align-items: flex-end;
  justify-content: center;
  gap: 28px;
  margin-top: 46px;
  padding-bottom: 22px;
}

.hero-stage__panel {
  position: relative;
  width: 288px;
  height: 220px;
  flex: 0 0 auto;
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow-panel);
}

.hero-stage__panel--mint {
  background: var(--color-mint);
  color: var(--color-text);
  transform: rotate(-1.5deg);
}

.hero-stage__panel--apricot {
  background: var(--color-apricot);
  color: var(--color-text);
  transform: translateY(-14px);
}

.hero-stage__panel--mist {
  background: var(--color-mist);
  color: var(--color-text);
  transform: rotate(1.5deg);
}

.mini-interface {
  position: absolute;
  top: 26px;
  right: 26px;
  left: 26px;
  display: flex;
  min-height: 210px;
  flex-direction: column;
  padding: 14px 16px 16px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: var(--shadow-card);
  text-align: left;
}

.mini-interface__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-muted);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.mini-interface__note {
  margin-top: auto;
  margin-bottom: 0;
  padding-top: 10px;
  color: var(--color-muted);
  font-size: 11.5px;
  line-height: 1.5;
}

.mini-code {
  margin: 0;
  padding: 0;
  color: var(--color-text);
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.95;
  list-style: none;
}

.mini-code li {
  display: flex;
  align-items: center;
  gap: 9px;
  white-space: nowrap;
}

.code-dot,
.tab-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
}

.code-dot--proxy {
  background: var(--color-accent);
}

.code-dot--direct {
  background: var(--color-warning);
}

.code-dot--match {
  background: var(--color-success);
}

.token-key,
.token-comment {
  color: var(--color-muted);
}

.token-value {
  color: var(--color-text);
}

.token-policy {
  color: var(--color-accent-dark);
  font-weight: 700;
}

.window-chrome {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--color-border);
}

.window-chrome i {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
  background: var(--color-chrome);
}

.window-chrome__file {
  margin-right: auto;
  margin-left: auto;
  padding-right: 42px;
  color: var(--color-muted);
  font-family: var(--font-mono);
  font-size: 11.5px;
}

.mode-segment {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  padding: 4px;
  border-radius: var(--radius-control);
  background: var(--color-panel);
  color: var(--color-muted);
}

.mode-segment span {
  padding: 8px 0;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.mode-segment .is-active {
  background: var(--color-accent);
  color: var(--color-on-accent);
  box-shadow: var(--shadow-segment);
}

.mode-state {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  color: var(--color-muted);
  font-size: 12.5px;
}

.mode-state .code-dot {
  background: var(--color-accent);
}

.mode-state strong {
  color: var(--color-text);
}

.tabs-shell {
  display: grid;
  grid-template-columns: minmax(190px, 0.34fr) minmax(0, 1fr);
  gap: 34px;
  align-items: stretch;
}

.tab-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.tab-button {
  position: relative;
  display: flex;
  min-height: 52px;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 14px 15px 18px;
  border-radius: var(--radius-control);
  background: transparent;
  color: var(--color-muted);
  cursor: pointer;
  text-align: left;
}

.tab-button::before {
  position: absolute;
  top: 10px;
  bottom: 10px;
  left: 0;
  width: 3px;
  border-radius: var(--radius-pill);
  background: transparent;
  content: "";
}

.tab-button::after {
  position: absolute;
  right: 14px;
  bottom: 7px;
  left: 18px;
  height: 2px;
  border-radius: var(--radius-pill);
  background: transparent;
  content: "";
  transform-origin: left;
}

.tab-button[aria-selected="true"] {
  background: var(--color-panel);
  color: var(--color-text);
  font-weight: 750;
}

.tab-button[aria-selected="true"]::before {
  background: var(--color-accent);
}

.tab-button[data-autoplay="true"][aria-selected="true"]::after {
  background: var(--color-accent);
  animation: tab-progress 8s linear both;
}

@keyframes tab-progress {
  from {
    transform: scaleX(0);
  }

  to {
    transform: scaleX(1);
  }
}

.tab-dot--mint {
  background: var(--color-accent);
}

.tab-dot--apricot {
  background: var(--color-warning);
}

.tab-dot--mist {
  background: var(--color-success);
}

.tab-dot--neutral {
  background: var(--color-muted);
}

.tab-panel {
  min-height: 420px;
  padding: clamp(24px, 5vw, 52px);
  border-radius: var(--radius-panel);
  color: var(--color-text);
}

.tab-panel--mint {
  background: var(--color-mint);
}

.tab-panel--apricot {
  background: var(--color-apricot);
}

.tab-panel--mist {
  background: var(--color-mist);
}

.tab-panel--neutral {
  background: var(--color-panel);
}

.tab-panel[hidden] {
  display: none;
}

.tab-panel__inner {
  padding: 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: var(--shadow-card);
}

.toc-tabs {
  position: sticky;
  top: 12px;
  z-index: 20;
  display: flex;
  gap: 8px;
  max-width: 100%;
  margin-bottom: 36px;
  padding: 8px;
  overflow-x: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: 0 1px 2px var(--color-shadow-soft);
  scrollbar-width: thin;
}

.toc-tabs a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  color: var(--color-muted);
  font-size: 14px;
  font-weight: 650;
}

.toc-tabs a:hover {
  background: var(--color-mint);
  color: var(--color-accent-dark);
}

.faq-list {
  display: grid;
  gap: 12px;
}

.faq-item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: 0 1px 2px var(--color-shadow-soft);
}

.faq-item summary {
  position: relative;
  display: flex;
  min-height: 60px;
  align-items: center;
  padding: 16px 54px 16px 20px;
  cursor: pointer;
  font-weight: 750;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  position: absolute;
  right: 20px;
  color: var(--color-accent-dark);
  content: "+";
  font-family: var(--font-mono);
  font-size: 22px;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item__answer {
  padding: 0 20px 20px;
  color: var(--color-muted);
}

.faq-item__answer p:last-child {
  margin-bottom: 0;
}

.term-grid,
.post-grid,
.client-grid {
  display: grid;
  gap: 22px;
}

.term-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.post-grid,
.client-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.term-card,
.post-card,
.client-card {
  min-width: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: var(--shadow-card);
}

.term-card {
  padding: 22px;
}

.term-card dt {
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 800;
}

.term-card dd {
  margin: 0;
  color: var(--color-muted);
}

.post-card,
.client-card {
  display: flex;
  flex-direction: column;
  padding: 26px;
}

.post-card__meta,
.client-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--color-muted);
  font-size: 13px;
}

.post-card h3,
.client-card h3 {
  font-size: 22px;
}

.post-card p,
.client-card p {
  margin-top: 12px;
  color: var(--color-muted);
}

.post-card__link,
.client-card__actions {
  margin-top: auto;
  padding-top: 12px;
}

.client-card--featured {
  border-color: var(--color-accent);
}

.client-card--archived {
  background: var(--color-panel);
  color: var(--color-text);
}

.client-card__head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.client-card__icon {
  width: 52px;
  height: 52px;
  flex: 0 0 auto;
}

.version-slot:empty {
  display: none;
}

.callout {
  margin: 28px 0;
  padding: 20px 22px;
  border-left: 4px solid var(--color-accent);
  border-radius: 0 var(--radius-card) var(--radius-card) 0;
  background: var(--color-mint);
  color: var(--color-text);
}

.callout--warning {
  border-left-color: var(--color-warning);
  background: var(--color-apricot);
  color: var(--color-text);
}

.callout--info {
  border-left-color: var(--color-accent-dark);
  background: var(--color-mist);
  color: var(--color-text);
}

.callout--error {
  border-left-color: var(--color-error);
  background: var(--color-panel);
  color: var(--color-text);
}

.callout__title {
  margin-bottom: 6px;
  font-weight: 800;
}

.callout p:last-child {
  margin-bottom: 0;
}

.article-download-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  margin-top: 48px;
  padding: 28px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-panel);
  background: var(--color-mint);
  color: var(--color-text);
  box-shadow: var(--shadow-card);
}

.article-download-card p {
  margin: 8px 0 0;
  color: var(--color-muted);
}

.dl-fab {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  bottom: max(18px, env(safe-area-inset-bottom));
  z-index: 80;
  display: inline-flex;
  min-height: 58px;
  align-items: center;
  gap: 11px;
  max-width: calc(100vw - 36px);
  padding: 10px 18px 10px 11px;
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: var(--shadow-card);
}

.dl-fab__icon {
  display: inline-flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  color: var(--color-on-accent);
}

.dl-fab__icon svg {
  width: 18px;
  height: 18px;
}

.dl-fab__text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.dl-fab__text strong {
  font-size: 14px;
}

.dl-fab__text small {
  color: var(--color-muted);
  font-size: 11px;
}

.prose > .data-table {
  display: block;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 1100px) {
  .hero-stage__panel {
    width: 260px;
    height: 210px;
  }

  .mini-interface {
    top: 22px;
    right: 22px;
    left: 22px;
  }
}

@media (max-width: 900px) {
  .hero-stage {
    max-width: 600px;
    flex-wrap: wrap;
    gap: 24px;
  }

  .hero-stage__panel--apricot {
    transform: none;
  }

  .term-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tabs-shell {
    grid-template-columns: 1fr;
  }

  .tab-list {
    flex-direction: row;
    max-width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .tab-button {
    min-width: max-content;
    width: auto;
    flex: 0 0 auto;
  }
}

@media (max-width: 768px) {
  .hero-workbench {
    min-height: auto;
    padding-top: 42px;
  }

  .hero-workbench__title {
    font-size: clamp(26px, 7vw, 30px);
  }

  .hero-workbench__lead {
    font-size: 15.5px;
  }

  .post-grid,
  .client-grid {
    grid-template-columns: 1fr;
  }

  .article-download-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .hero-stage {
    gap: 20px;
  }

  .hero-stage__panel--mint,
  .hero-stage__panel--mist {
    transform: none;
  }

  .term-grid {
    grid-template-columns: 1fr;
  }

  .tab-panel {
    min-height: auto;
    padding: 18px;
  }

  .tab-panel__inner {
    padding: 18px;
  }

  .toc-tabs {
    top: 8px;
    border-radius: var(--radius-card);
  }

  .dl-fab {
    right: 12px;
    bottom: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-eyebrow__dot::after,
  .tab-button[data-autoplay="true"][aria-selected="true"]::after {
    animation: none;
  }
}