/* Hux home command bridge + dashboard continuity v40 */

.dashboard-section {
  --home-command-border: #333338;
  --home-command-surface: #121213;
  --home-command-surface-strong: #171719;
  --home-command-surface-hover: #1d1d20;
  --home-command-text: #f3f3f4;
  --home-command-secondary: #aaaab0;
  --home-command-muted: #77777e;
  --home-command-accent: #ff4d4d;
  --home-command-ease: cubic-bezier(0.33, 1, 0.68, 1);
  --home-command-duration: 460ms;
  gap: 28px;
}

.agent-onboarding-slot {
  margin-bottom: 0;
}

.agent-copy-launcher-home {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(340px, 0.86fr) minmax(520px, 1.14fr);
  align-content: stretch;
  justify-items: stretch;
  min-height: 270px;
  padding: 0;
  border: 1px solid var(--home-command-border);
  background: var(--home-command-surface);
  color: var(--home-command-text);
  container-type: inline-size;
  isolation: isolate;
  opacity: 0;
  transform: translate3d(0, clamp(8px, 1cqw, 14px), 0);
  transition:
    opacity var(--home-command-duration) var(--home-command-ease),
    transform var(--home-command-duration) var(--home-command-ease);
}

.agent-copy-launcher-home::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(112deg, rgb(255 77 77 / 8%), transparent 28%),
    linear-gradient(270deg, rgb(255 255 255 / 2%), transparent 42%);
  content: "";
  pointer-events: none;
}

.agent-bridge-ready .agent-copy-launcher-home {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.agent-bridge-intro,
.agent-bridge-console {
  min-width: 0;
}

.agent-bridge-intro {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 38px 42px 36px;
  border-right: 1px solid var(--home-command-border);
  background:
    linear-gradient(130deg, rgb(255 77 77 / 7%), transparent 44%),
    #111112;
}

.agent-bridge-kicker {
  color: var(--home-command-accent);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.19em;
  line-height: 1.4;
}

.agent-bridge-intro h3 {
  max-width: 12em;
  margin: 16px 0 0;
  color: var(--home-command-text);
  font-family: var(--font-heading);
  font-size: clamp(32px, 3.05cqw, 42px);
  font-weight: 570;
  letter-spacing: -0.035em;
  line-height: 1.08;
  text-wrap: balance;
}

.agent-bridge-intro > p {
  max-width: 31em;
  margin: 16px 0 0;
  color: var(--home-command-secondary);
  font-size: 16px;
  line-height: 1.65;
}

.agent-bridge-steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.agent-bridge-steps::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 1px;
  background: #414146;
  content: "";
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 540ms var(--home-command-ease) 180ms;
}

.agent-bridge-ready .agent-bridge-steps::before {
  transform: scaleX(1);
}

.agent-bridge-steps li {
  position: relative;
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 14px 10px 0 0;
  opacity: 0;
  transform: translate3d(0, 8px, 0);
  transition:
    opacity 340ms var(--home-command-ease),
    transform 340ms var(--home-command-ease);
  transition-delay: calc(220ms + var(--agent-index) * 60ms);
}

.agent-bridge-ready .agent-bridge-steps li {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.agent-bridge-steps li::before {
  position: absolute;
  top: -3px;
  left: 0;
  width: 7px;
  height: 7px;
  background: var(--home-command-accent);
  content: "";
}

.agent-bridge-steps span {
  color: var(--home-command-accent);
  font-family: var(--font-din-numerals), "Arial Narrow", sans-serif;
  font-size: 17px;
  font-weight: 560;
  letter-spacing: 0.02em;
  line-height: 1;
  font-variant-numeric: tabular-nums lining-nums;
}

.agent-bridge-steps strong {
  overflow: hidden;
  color: #b9b9be;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.agent-bridge-console {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 36px 42px 34px;
}

.agent-console-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 24px;
}

.agent-console-heading > span:last-child {
  color: var(--home-command-muted);
  font-size: 12px;
  line-height: 1.5;
  text-align: right;
}

.agent-console-state {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #d0d0d4;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.4;
}

.agent-console-state i {
  width: 8px;
  height: 8px;
  background: var(--home-command-accent);
  box-shadow: 0 0 0 4px rgb(255 77 77 / 9%);
}

.agent-copy-launcher-home .agent-copy-tip {
  position: static;
  justify-content: flex-start;
  width: 100%;
  min-height: 0;
  margin: 23px 0 10px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: #898990;
  font-size: 13px;
}

.agent-copy-launcher-home .agent-copy-tip::after {
  display: none;
}

.agent-copy-launcher-home .agent-copy-tip img {
  width: 16px;
  height: 16px;
  opacity: 0.78;
}

.agent-copy-launcher-home .agent-copy-pill {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 50px;
  gap: 14px;
  width: 100%;
  min-width: 0;
  min-height: 78px;
  padding: 8px 8px 8px 10px;
  border: 1px solid #55555c;
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgb(255 255 255 / 4%), transparent 46%),
    var(--home-command-surface-strong);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 4%);
  color: var(--home-command-text);
  text-align: left;
  transition:
    border-color 180ms var(--home-command-ease),
    background-color 180ms var(--home-command-ease),
    box-shadow 180ms var(--home-command-ease);
}

.agent-copy-launcher-home .agent-copy-pill:hover,
.agent-copy-launcher-home .agent-copy-pill:focus-visible {
  border-color: #86868d;
  background:
    linear-gradient(180deg, rgb(255 255 255 / 5%), transparent 48%),
    var(--home-command-surface-hover);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 6%),
    0 14px 32px rgb(0 0 0 / 18%);
  transform: none;
}

.agent-copy-launcher-home .agent-copy-pill:active {
  border-color: #96969d;
  background: #202023;
}

.agent-copy-launcher-home .agent-copy-pill:focus-visible {
  outline: 2px solid var(--home-command-accent);
  outline-offset: 3px;
}

.agent-copy-launcher-home.copied .agent-copy-pill {
  border-color: rgb(255 77 77 / 72%);
  background:
    linear-gradient(90deg, rgb(255 77 77 / 10%), transparent 44%),
    #1c1c1f;
}

.agent-copy-glyph {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid #414147;
  background: #111113;
  color: #b8b8bd;
}

.agent-copy-glyph img {
  width: 21px;
  height: 21px;
  filter: invert(74%);
}

.agent-copy-copy {
  display: grid;
  align-content: center;
  gap: 5px;
  min-width: 0;
}

.agent-copy-launcher-home .agent-copy-label {
  overflow: hidden;
  color: var(--home-command-text);
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 650;
  letter-spacing: -0.015em;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.agent-copy-copy small {
  overflow: hidden;
  color: #85858c;
  font-size: 13px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.agent-copy-launcher-home .agent-copy-status {
  display: grid;
  width: 50px;
  height: 48px;
  place-items: center;
  border-left: 1px solid #49494f;
  color: #b8b8bd;
}

.agent-copy-launcher-home .agent-copy-status img {
  width: 19px;
  height: 19px;
  filter: invert(72%);
}

.agent-copy-launcher-home.copied .agent-copy-status {
  color: var(--home-command-accent);
}

.agent-copy-launcher-home.copied .agent-client-mark {
  animation: none;
  transform: none;
}

.agent-console-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-top: 18px;
}

.agent-supported-clients {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.agent-supported-label {
  color: #73737a;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.08em;
  line-height: 1.35;
  text-transform: uppercase;
}

.agent-copy-launcher-home .agent-client-strip-labelled {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 16px;
  padding: 0;
}

.agent-client-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  opacity: 0;
  transform: translate3d(0, 6px, 0);
  transition:
    opacity 320ms var(--home-command-ease),
    transform 320ms var(--home-command-ease);
  transition-delay: calc(260ms + var(--agent-index) * 60ms);
}

.agent-bridge-ready .agent-client-item {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.agent-copy-launcher-home .agent-client-item .agent-client-mark {
  width: 24px;
  height: 26px;
  opacity: 0.92;
  transform: none;
  transition: opacity 150ms ease;
}

.agent-copy-launcher-home .agent-client-item:hover .agent-client-mark {
  opacity: 1;
  transform: none;
}

.agent-copy-launcher-home .agent-client-mark[data-client="claude"] img,
.agent-copy-launcher-home .agent-client-mark[data-client="codex"] img {
  width: 20px;
  height: 20px;
}

.agent-copy-launcher-home .agent-client-mark[data-client="cursor"] img {
  width: 18px;
  height: 20px;
}

.agent-client-name {
  color: #9b9ba1;
  font-size: 12px;
  font-weight: 580;
  line-height: 1;
}

.agent-copy-launcher-home .agent-copy-config {
  display: inline-flex;
  min-width: 148px;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 16px;
  border: 1px solid #45454a;
  background: #111113;
  color: #c4c4c8;
  font-size: 13px;
  font-weight: 650;
}

.agent-copy-launcher-home .agent-copy-config img {
  width: 17px;
  height: 17px;
  filter: invert(72%);
}

.agent-copy-launcher-home .agent-copy-config:hover,
.agent-copy-launcher-home .agent-copy-config:focus-visible {
  border-color: #74747b;
  background: #1a1a1c;
  color: #f0f0f1;
}

.agent-copy-launcher-home .agent-copy-config:focus-visible {
  outline: 2px solid var(--home-command-accent);
  outline-offset: 2px;
}

.agent-copy-launcher-home > .agent-copy-dismiss {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 3;
  width: 44px;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  color: #77777e;
}

.agent-copy-launcher-home > .agent-copy-dismiss img {
  width: 17px;
  height: 17px;
  filter: invert(56%);
}

.agent-copy-launcher-home > .agent-copy-dismiss:hover,
.agent-copy-launcher-home > .agent-copy-dismiss:focus-visible {
  border-color: #4a4a50;
  background: #19191b;
}

.dashboard-heading {
  background:
    linear-gradient(90deg, rgb(255 77 77 / 3.5%), transparent 24%),
    var(--dashboard-surface);
}

.dashboard-metrics,
.dashboard-panel,
.dashboard-heading,
.agent-copy-launcher-home {
  box-shadow: 0 18px 44px rgb(0 0 0 / 7%);
}

.dashboard-metrics article,
.dashboard-panel,
.dashboard-heading {
  transition-property: background-color, border-color, box-shadow, opacity, transform;
}

@media (max-width: 1120px) {
  .agent-copy-launcher-home {
    grid-template-columns: minmax(300px, 0.78fr) minmax(460px, 1.22fr);
  }

  .agent-bridge-intro,
  .agent-bridge-console {
    padding-inline: 30px;
  }

  .agent-console-heading > span:last-child {
    max-width: 25em;
  }

  .agent-client-name {
    display: none;
  }
}

@media (max-width: 960px) {
  .agent-copy-launcher-home {
    grid-template-columns: 1fr;
  }

  .agent-bridge-intro {
    padding: 32px 28px 30px;
    border-right: 0;
    border-bottom: 1px solid var(--home-command-border);
  }

  .agent-bridge-intro h3 {
    max-width: 13em;
    font-size: 36px;
  }

  .agent-bridge-console {
    padding: 30px 28px 28px;
  }

  .agent-client-name {
    display: inline;
  }
}

@media (max-width: 560px) {
  .dashboard-section {
    gap: 22px;
  }

  .agent-bridge-intro {
    padding: 28px 22px 26px;
  }

  .agent-bridge-kicker {
    padding-right: 38px;
    font-size: 12px;
  }

  .agent-bridge-intro h3 {
    max-width: 9em;
    margin-top: 13px;
    font-size: 32px;
    line-height: 1.1;
  }

  .agent-bridge-intro > p {
    margin-top: 13px;
    font-size: 15px;
    line-height: 1.6;
  }

  .agent-bridge-steps {
    margin-top: 24px;
  }

  .agent-bridge-steps li {
    gap: 5px;
    padding-right: 6px;
  }

  .agent-bridge-steps span {
    font-size: 16px;
  }

  .agent-bridge-steps strong {
    font-size: 12px;
    white-space: normal;
  }

  .agent-bridge-console {
    padding: 26px 22px 24px;
  }

  .agent-console-heading {
    align-items: flex-start;
  }

  .agent-console-heading > span:last-child {
    max-width: 12em;
    font-size: 12px;
  }

  .agent-copy-launcher-home .agent-copy-tip {
    margin-top: 20px;
    font-size: 12px;
    text-align: left;
  }

  .agent-copy-launcher-home .agent-copy-pill {
    grid-template-columns: 42px minmax(0, 1fr) 40px;
    gap: 10px;
    min-height: 72px;
    padding-left: 8px;
    border-radius: 12px;
  }

  .agent-copy-glyph {
    width: 42px;
    height: 42px;
  }

  .agent-copy-glyph img {
    width: 19px;
    height: 19px;
  }

  .agent-copy-launcher-home .agent-copy-label {
    font-size: 16px;
    white-space: normal;
  }

  .agent-copy-copy small {
    display: none;
  }

  .agent-copy-launcher-home .agent-copy-status {
    width: 40px;
    height: 42px;
  }

  .agent-console-footer {
    display: grid;
    gap: 16px;
    align-items: stretch;
  }

  .agent-copy-launcher-home .agent-client-strip-labelled {
    justify-content: space-between;
    gap: 10px;
  }

  .agent-client-name {
    font-size: 12px;
  }

  .agent-copy-launcher-home .agent-copy-config {
    width: 100%;
    min-height: 48px;
  }

  .agent-copy-launcher-home > .agent-copy-dismiss {
    top: 12px;
    right: 12px;
  }

  .dashboard-metrics,
  .dashboard-panel,
  .dashboard-heading,
  .agent-copy-launcher-home {
    box-shadow: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .agent-copy-launcher-home,
  .agent-bridge-steps::before,
  .agent-bridge-steps li,
  .agent-client-item {
    opacity: 1;
    transform: none;
    transition: none !important;
  }

  .agent-bridge-steps::before {
    transform: scaleX(1);
  }

  .agent-copy-launcher-home .agent-copy-pill,
  .agent-copy-launcher-home .agent-copy-config,
  .agent-copy-launcher-home > .agent-copy-dismiss {
    transition: none;
  }
}
