.ds-hero-company-profile,
.cp-footer-profile {
  --cp-profile-blue: #183461;
  --cp-profile-deep: #162f58;
  --cp-profile-muted: #dbe6f6;
  --cp-profile-line: #ffffff42;
}

.ds-hero.ds-hero-company-profile {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(52px, 6vw, 90px) 0 clamp(44px, 5vw, 70px);
  background: linear-gradient(115deg, var(--cp-profile-deep), var(--cp-profile-blue));
  color: #fff;
}

.cp-profile-background {
  position: absolute;
  z-index: -1;
  inset: 0;
  opacity: .18;
  background-repeat: no-repeat;
}

.cp-builder .ds-hero-company-profile .cp-profile-intro {
  width: min(100% - 44px, 1120px);
  margin-inline: auto;
  padding-inline: 0;
  text-align: center;
}

/* Match the same title measure in the builder and the showcase. */
.cp-builder .ds-hero-company-profile .cp-profile-intro h1 {
  max-width: 1080px;
  margin: 0 auto 16px;
  color: #fff;
  font-size: clamp(30px, 4vw, 54px) !important;
  font-weight: 750;
  line-height: 1.22 !important;
  letter-spacing: -.025em;
  overflow-wrap: anywhere;
  text-wrap: wrap;
}

.cp-profile-intro h1 > span { display: inline-block; max-width: 100%; }

.cp-profile-summary {
  max-width: 880px;
  margin: 0 auto 16px;
  color: var(--cp-profile-muted);
  font-size: 16px;
  line-height: 1.8;
}

.cp-profile-offerings {
  display: inline-block;
  margin: 0;
  padding: 8px 16px;
  border: 1px solid var(--cp-profile-line);
  border-radius: 24px;
  background: #ffffff12;
  color: #fff;
  font-size: 14px;
  line-height: 1.6;
}

.cp-profile-tags,
.cp-profile-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 9px;
}

.cp-profile-tags {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.cp-profile-tags li {
  padding: 4px 12px;
  border: 1px solid var(--cp-profile-line);
  border-radius: 18px;
  background: #ffffff12;
  color: var(--cp-profile-muted);
  font-size: 13px;
}

.cp-profile-actions {
  margin: 22px 0 0;
}

.cp-profile-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 8px 18px;
  border: 1px solid #ffffff66;
  border-radius: 24px;
  color: #fff;
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
}

.cp-profile-actions .cp-profile-primary {
  background: #fff;
  color: var(--cp-profile-deep);
}

.cp-profile-actions a:hover { box-shadow: inset 0 0 0 1px currentColor; }

.cp-profile-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 24px auto 0;
  text-align: left;
}

.cp-profile-facts > div {
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--cp-profile-line);
  border-radius: 11px;
  background: #ffffff20;
}

.cp-profile-facts dt { color: var(--cp-profile-muted); font-size: 12px; }
.cp-profile-facts dd {
  margin: 3px 0 0;
  color: #fff;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.cp-profile-section .ds-heading { margin-bottom: 24px; }
.cp-profile-section .ds-heading p { color: var(--cp-soft); line-height: 1.7; }
.cp-profile-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  gap: 14px;
}
.cp-profile-section .ds-facts + .cp-profile-card-grid { margin-top: 18px; }
.cp-profile-card-grid article {
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--cp-line);
  border-radius: 12px;
  overflow-wrap: anywhere;
}
.cp-profile-card-grid h3 { margin: 0 0 8px; font-size: 18px; }
.cp-profile-card-grid h3 a { color: inherit; text-underline-offset: 3px; }
.cp-profile-card-grid p { margin: 0; color: var(--cp-soft); line-height: 1.7; }
.cp-profile-record-fields { margin: 14px 0 0; font-size: 13px; }
.cp-profile-record-fields > div { display: flex; flex-wrap: wrap; gap: 3px 12px; }
.cp-profile-record-fields dd { margin: 0; font-weight: 600; }
.cp-profile-region-grid {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) minmax(0, 2fr);
  gap: 24px 40px;
  align-items: start;
}
.cp-profile-region-grid ul {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 138px), 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.cp-profile-region-grid li a {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--cp-line);
  border-radius: 8px;
  color: var(--cp-ink);
  font-size: 14px;
  text-decoration: none;
}
.cp-profile-region-grid li a:hover { border-color: var(--cp-accent); }

body.cp-builder .cp-footer-shell.cp-footer-profile .site-footer {
  padding: 52px 0 0;
  border: 0;
  background: var(--cp-profile-deep) !important;
  color: var(--cp-profile-muted) !important;
}

.cp-footer-profile .site-footer > .container,
.cp-footer-profile .footer-bottom > .container {
  width: min(100% - 44px, 1360px);
  margin-inline: auto;
  padding-inline: 0;
}

.cp-builder .cp-footer-profile .site-footer .footer-grid {
  display: grid;
  grid-template-columns: 1.35fr .85fr 1.2fr;
  gap: clamp(24px, 5vw, 80px);
  padding-bottom: 34px;
}

.cp-footer-profile .footer-col { min-width: 0; overflow-wrap: anywhere; }
body.cp-builder .cp-footer-shell.cp-footer-profile .site-footer :is(h3, a, summary) { color: #fff !important; }
body.cp-builder .cp-footer-shell.cp-footer-profile .site-footer :is(p, small, .label) { color: var(--cp-profile-muted) !important; }
.cp-footer-profile .footer-col h3 { margin: 0 0 14px; font-size: 15px; }
.cp-footer-profile .footer-col :is(p, li) { font-size: 14px; line-height: 1.8; }
.cp-footer-profile .footer-col p { margin: 0 0 12px; }
.cp-footer-profile .footer-col li { margin-bottom: 8px; }
.cp-builder .cp-footer-profile .site-footer .footer-col:nth-child(2) ul { display: block; }
.cp-footer-profile .footer-col .label { margin-right: 7px; }
.cp-footer-profile a:hover { text-decoration: underline; text-underline-offset: 4px; }

.cp-footer-profile .ga-footer-directory {
  border-top: 1px solid var(--cp-profile-line);
  padding-block: 17px 22px;
}

.cp-footer-profile .ga-footer-directory summary { cursor: pointer; font-weight: 650; }
.cp-footer-profile .ga-footer-directory .footer-stations {
  max-width: none;
  padding: 16px 0 0;
  margin: 0;
}

.cp-footer-profile .footer-bottom {
  margin: 0;
  padding: 18px 0;
  border-top: 1px solid #ffffff24;
  background: transparent;
  color: #c4d4ec;
  font-size: 12px;
  line-height: 1.7;
  text-align: center;
}

.cp-footer-profile .footer-bottom .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 10px;
}

:is(.ds-hero-company-profile, .cp-footer-profile) :is(a, summary):focus-visible {
  outline: 2px solid #b8d4ff;
  outline-offset: 4px;
}

@media (max-width: 760px) {
  .cp-builder .ds-hero-company-profile .cp-profile-intro h1 { text-wrap: balance; }
  .cp-profile-region-grid { grid-template-columns: 1fr; }
  .cp-profile-region-grid .ds-heading { margin-bottom: 0; }
  .cp-profile-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cp-builder .cp-footer-profile .site-footer .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  body.cp-builder .cp-footer-shell.cp-footer-profile .site-footer { padding-top: 34px; }
}

@media (max-width: 360px) {
  .cp-profile-facts { grid-template-columns: 1fr; }
}
