:root {
  --home-ink: #101418;
  --home-muted: #687176;
  --home-line: #dce2e2;
  --home-accent: #13a896;
  --home-accent-dark: #0a746b;
  --home-blue: #2875e8;
  --home-coral: #ff6b52;
  --home-surface: #f4f7f6;
  --home-dark: #0b1015;
}

body.home-page {
  overflow-x: hidden;
  background: #ffffff;
  color: var(--home-ink);
}

body.home-page::before {
  display: none;
  content: none;
}

.home-page .site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 68px;
  padding: 9px clamp(18px, 3.2vw, 52px);
  border-bottom: 1px solid rgba(16, 20, 24, 0.09);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(18px);
}

.home-page .brand {
  gap: 10px;
}

.home-page .brand-logo {
  width: 42px;
  height: 42px;
  filter: none;
}

.home-page .brand strong {
  font-size: 19px;
  font-weight: 900;
  line-height: 1.05;
}

.home-page .brand small {
  margin-top: 4px;
  color: #778086;
  font-size: 9px;
  letter-spacing: 0.14em;
}

.home-page .nav {
  align-items: center;
  gap: clamp(16px, 2.4vw, 34px);
  font-size: 13px;
}

.home-page .nav > a {
  position: relative;
  color: #596166;
}

.home-page .nav > a::after {
  position: absolute;
  right: 0;
  bottom: 3px;
  left: 0;
  height: 2px;
  background: var(--home-accent);
  content: "";
  opacity: 0;
  transform: scaleX(0.45);
  transition: opacity 160ms ease, transform 160ms ease;
}

.home-page .nav > a:hover::after {
  opacity: 1;
  transform: scaleX(1);
}

.home-page .account-menu-trigger,
.home-page .account-avatar,
.home-page .account-menu-panel {
  border-radius: 8px;
}

.home-page main {
  width: 100%;
}

.home-command {
  min-height: calc(100svh - 190px);
  padding: clamp(22px, 2.5vw, 34px) clamp(18px, 3.2vw, 52px) 24px;
  background-color: var(--home-dark);
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 36px 36px;
  color: #ffffff;
}

.command-head {
  display: flex;
  max-width: 1580px;
  min-height: 92px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin: 0 auto 20px;
}

.command-copy {
  min-width: 0;
}

.command-kicker {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 7px;
  color: #9ba6aa;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.command-kicker span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #32d6b8;
  box-shadow: 0 0 0 5px rgba(50, 214, 184, 0.12);
}

.command-copy h1 {
  max-width: none;
  margin: 0;
  color: #ffffff;
  font-size: clamp(30px, 2.6vw, 42px);
  font-weight: 760;
  line-height: 1.08;
}

.command-copy > p:last-child {
  margin: 8px 0 0;
  color: #aab3b6;
  font-size: 14px;
}

.command-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
}

.command-button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 18px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  padding: 0 17px;
  background: rgba(255, 255, 255, 0.05);
  color: #f6f8f8;
  font-size: 13px;
  font-weight: 760;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.command-button:hover {
  border-color: rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.command-button-primary {
  border-color: #25bda8;
  background: #25bda8;
  color: #061513;
}

.command-button-primary:hover {
  border-color: #42d3bd;
  background: #42d3bd;
}

.capability-mosaic {
  display: grid;
  max-width: 1580px;
  height: clamp(360px, calc(100svh - 280px), 450px);
  min-height: 360px;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 auto;
}

.feature-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: #161c22;
  color: #ffffff;
  isolation: isolate;
  transition: border-color 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.feature-card::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(4, 8, 12, 0.04) 10%, rgba(4, 8, 12, 0.84) 100%);
  content: "";
}

.feature-card:hover {
  z-index: 3;
  border-color: rgba(66, 211, 189, 0.72);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.28);
  transform: translateY(-3px);
}

.feature-card > img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.8;
  transition: transform 360ms ease, opacity 180ms ease;
}

.feature-card:hover > img {
  opacity: 0.92;
  transform: scale(1.025);
}

.feature-copy {
  position: absolute;
  right: 17px;
  bottom: 15px;
  left: 17px;
  z-index: 2;
  display: block;
  padding-right: 34px;
}

.feature-copy strong,
.feature-copy small {
  display: block;
  overflow-wrap: anywhere;
}

.feature-copy strong {
  font-size: clamp(16px, 1.25vw, 20px);
  line-height: 1.15;
}

.feature-copy small {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 11px;
}

.feature-arrow {
  position: absolute;
  right: 15px;
  bottom: 15px;
  z-index: 2;
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.22);
  color: #ffffff;
  font-size: 15px;
  transition: background 160ms ease, color 160ms ease;
}

.feature-card:hover .feature-arrow {
  background: #42d3bd;
  color: #071713;
}

.feature-index {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  color: rgba(255, 255, 255, 0.7);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.feature-code {
  grid-column: 1 / span 5;
  grid-row: 1 / span 3;
}

.feature-code::after {
  background: linear-gradient(
    180deg,
    rgba(4, 8, 12, 0.02) 0%,
    rgba(4, 8, 12, 0.02) 72%,
    rgba(4, 8, 12, 0.5) 86%,
    rgba(4, 8, 12, 0.94) 100%
  );
}

.feature-code > img {
  opacity: 1;
  object-position: center;
}

.feature-code .feature-copy {
  right: 24px;
  bottom: 24px;
  left: 24px;
}

.feature-code .feature-copy strong {
  font-size: clamp(27px, 2.3vw, 38px);
}

.feature-code .feature-copy small {
  margin-top: 6px;
  font-size: 13px;
}

.feature-code .feature-arrow {
  right: 23px;
  bottom: 25px;
  width: 34px;
  height: 34px;
}

.feature-digital {
  grid-column: 6 / span 4;
  grid-row: 1;
}

.feature-digital > img {
  object-position: center 68%;
}

.feature-mcp {
  grid-column: 10 / span 3;
  grid-row: 1;
}

.feature-media {
  grid-column: 6 / span 4;
  grid-row: 2;
}

.feature-media > img {
  object-position: center 58%;
}

.feature-platform {
  grid-column: 10 / span 3;
  grid-row: 2;
}

.feature-connector {
  grid-column: 6 / span 4;
  grid-row: 3;
}

.feature-connector > img {
  object-position: center;
}

.feature-api {
  grid-column: 10 / span 3;
  grid-row: 3;
}

.feature-icon-card {
  background-color: #15231f;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 26px 26px;
}

.feature-api {
  background-color: #182137;
}

.feature-icon-card::after {
  background: linear-gradient(90deg, rgba(6, 14, 14, 0.18), rgba(6, 14, 14, 0.68));
}

.feature-icon-card > img {
  top: 18px;
  right: 18px;
  bottom: auto;
  left: auto;
  z-index: 1;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  padding: 8px;
  background: rgba(255, 255, 255, 0.94);
  opacity: 1;
  object-fit: contain;
}

.feature-icon-card:hover > img {
  opacity: 1;
  transform: none;
}

.command-footer {
  display: flex;
  max-width: 1580px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 13px auto 0;
}

.command-status {
  display: flex;
  align-items: center;
  gap: 22px;
  margin: 0;
  color: #818c90;
  font-size: 10px;
  font-weight: 700;
}

.command-status span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.status-live {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #32d6b8;
}

.command-jump-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 9px;
}

.command-button-compact {
  min-height: 42px;
  gap: 18px;
  padding: 0 17px;
  font-size: 13px;
}

.home-landing .billing-band,
.home-landing .connector-band,
.home-landing #workspace,
.home-landing #tools {
  display: none;
}

.home-page .billing-band,
.home-page .connector-band,
.home-page .section,
.home-page .tool-workspace,
.home-page .footer {
  padding-right: clamp(18px, 3.2vw, 52px);
  padding-left: clamp(18px, 3.2vw, 52px);
}

.home-page .billing-band {
  grid-template-columns: minmax(260px, 0.7fr) minmax(620px, 1.3fr);
  padding-top: 34px;
  padding-bottom: 34px;
  border-color: var(--home-line);
  background: #f4f7f6;
}

.home-page .billing-copy .eyebrow,
.home-page .connector-copy .eyebrow,
.home-page .section-heading .eyebrow,
.home-page .contact .eyebrow {
  color: var(--home-accent-dark);
  letter-spacing: 0.08em;
}

.home-page .plan-tile,
.home-page .service-card,
.home-page .connector-status-card,
.home-page .connector-download-card,
.home-page .connector-rules article {
  border-radius: 8px;
}

.home-page .plan-tile {
  border-color: rgba(16, 20, 24, 0.1);
  background: #ffffff;
  box-shadow: none;
}

.home-page .plan-tile:hover,
.home-page .plan-tile.featured {
  border-color: rgba(19, 168, 150, 0.55);
  box-shadow: 0 12px 28px rgba(16, 20, 24, 0.08);
}

.home-page .connector-band {
  border-color: var(--home-line);
}

.home-page .section {
  border-bottom: 1px solid var(--home-line);
}

.home-page .service-card {
  border-color: rgba(16, 20, 24, 0.1);
  box-shadow: none;
}

.home-page .footer {
  background: #10151a;
  color: #ffffff;
}

.home-page .footer-main,
.home-page .footer-report,
.home-page .footer-support-copy,
.home-page .footer-support-copy span,
.home-page .footer-support figure,
.home-page .footer a {
  color: #ffffff;
}

@media (max-width: 980px) {
  .command-head {
    align-items: flex-start;
  }

  .capability-mosaic {
    height: 490px;
    min-height: 490px;
  }

  .feature-code {
    grid-column: 1 / span 6;
  }

  .feature-digital,
  .feature-media,
  .feature-connector {
    grid-column: 7 / span 3;
  }

  .feature-mcp,
  .feature-platform,
  .feature-api {
    grid-column: 10 / span 3;
  }

  .home-page .billing-band {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .home-page .site-header {
    position: sticky;
    min-height: 62px;
    flex-direction: row;
    align-items: center;
    padding: 8px 14px;
  }

  .home-page .brand-logo {
    width: 38px;
    height: 38px;
  }

  .home-page .brand strong {
    font-size: 17px;
  }

  .home-page .brand small,
  .home-page .nav > a {
    display: none;
  }

  .home-page .nav {
    width: auto;
    padding: 0;
  }

  .home-page .account-menu {
    width: auto;
  }

  .home-page .account-menu-trigger {
    width: auto;
    min-height: 40px;
    padding: 4px 7px;
  }

  .home-page .account-trigger-copy {
    display: none;
  }

  .home-page .account-menu-panel {
    right: 0;
    left: auto;
    width: min(300px, calc(100vw - 28px));
  }

  .home-command {
    min-height: 0;
    padding: 18px 14px 16px;
  }

  .command-head {
    min-height: 0;
    align-items: stretch;
    flex-direction: column;
    gap: 13px;
    margin-bottom: 14px;
  }

  .command-copy h1 {
    font-size: 27px;
  }

  .command-copy > p:last-child {
    max-width: 92%;
    margin-top: 6px;
    font-size: 12px;
    line-height: 1.45;
  }

  .command-actions {
    gap: 8px;
  }

  .command-button {
    min-height: 36px;
    gap: 12px;
    padding: 0 13px;
    font-size: 12px;
  }

  .capability-mosaic {
    height: auto;
    min-height: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: 200px repeat(3, 86px);
    gap: 8px;
  }

  .feature-code {
    grid-column: 1 / span 2;
    grid-row: 1;
  }

  .feature-digital,
  .feature-mcp,
  .feature-media,
  .feature-platform,
  .feature-connector,
  .feature-api {
    grid-column: auto;
    grid-row: auto;
  }

  .feature-copy {
    right: 10px;
    bottom: 9px;
    left: 10px;
    padding-right: 26px;
  }

  .feature-copy strong {
    font-size: 13px;
  }

  .feature-copy small {
    display: none;
  }

  .feature-arrow {
    right: 8px;
    bottom: 8px;
    width: 22px;
    height: 22px;
    font-size: 12px;
  }

  .feature-code .feature-copy {
    right: 16px;
    bottom: 15px;
    left: 16px;
  }

  .feature-code .feature-copy strong {
    font-size: 23px;
  }

  .feature-code .feature-copy small {
    display: block;
    font-size: 11px;
  }

  .feature-code .feature-arrow {
    right: 14px;
    bottom: 15px;
    width: 30px;
    height: 30px;
  }

  .feature-index {
    top: 12px;
    left: 12px;
  }

  .feature-icon-card > img {
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
    padding: 6px;
  }

  .command-footer {
    gap: 8px;
    margin-top: 10px;
  }

  .command-status {
    flex: 0 1 auto;
    gap: 0;
    font-size: 8px;
  }

  .command-status span:not(:first-child) {
    display: none;
  }

  .command-jump-actions {
    gap: 6px;
  }

  .command-button-compact {
    min-height: 30px;
    gap: 6px;
    padding: 0 9px;
    font-size: 9px;
  }

  .home-page .billing-band,
  .home-page .connector-band,
  .home-page .section,
  .home-page .tool-workspace,
  .home-page .footer {
    grid-template-columns: minmax(0, 1fr);
    padding-right: 16px;
    padding-left: 16px;
  }

  .home-page .footer-support {
    width: 100%;
    margin-left: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .feature-card,
  .feature-card > img,
  .feature-arrow,
  .command-button {
    transition: none;
  }
}

/* Dedicated portal pages */
.home-page .nav > a[aria-current="page"] {
  color: var(--home-accent-dark);
  font-weight: 800;
}

.home-page .nav > a[aria-current="page"]::after {
  opacity: 1;
  transform: scaleX(1);
}

.portal-section-page {
  background: #f4f7f6;
}

.portal-section-page main {
  min-height: calc(100vh - 68px);
}

.portal-page-hero {
  display: flex;
  min-height: 210px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  padding: 42px clamp(18px, 3.2vw, 52px) 38px;
  background-color: var(--home-dark);
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 36px 36px;
  color: #ffffff;
}

.portal-page-hero > div:first-child {
  max-width: 760px;
}

.portal-page-hero h1 {
  max-width: none;
  margin: 0;
  color: #ffffff;
  font-size: clamp(32px, 2.8vw, 44px);
  font-weight: 760;
  line-height: 1.08;
}

.portal-page-hero p:last-child {
  margin: 10px 0 0;
  color: #aab3b6;
  font-size: 14px;
}

.portal-page-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
}

.portal-section-page .billing-band,
.portal-section-page .connector-band,
.portal-section-page .section {
  max-width: none;
  margin: 0;
}

.portal-section-page .billing-band {
  padding-top: 44px;
  padding-bottom: 44px;
  background: #f4f7f6;
}

.portal-section-page .connector-band {
  padding-top: 40px;
  padding-bottom: 46px;
  background: #ffffff;
}

.portal-section-page .section {
  padding-top: 46px;
  padding-bottom: 52px;
  background: #ffffff;
}

.portal-section-page .footer {
  margin-top: 0;
}

@media (max-width: 720px) {
  .portal-page-hero {
    min-height: 0;
    align-items: stretch;
    flex-direction: column;
    gap: 20px;
    padding: 30px 16px 28px;
  }

  .portal-page-hero h1 {
    font-size: 30px;
  }

  .portal-page-hero p:last-child {
    font-size: 12px;
    line-height: 1.55;
  }

  .portal-page-actions {
    width: 100%;
  }

  .portal-page-actions .command-button {
    flex: 1 1 0;
    padding: 0 10px;
  }

  .portal-section-page .billing-band,
  .portal-section-page .connector-band,
  .portal-section-page .section {
    padding-top: 30px;
    padding-bottom: 34px;
  }
}
