:root {
  color-scheme: light;
  --ink: #14233b;
  --muted: #53647b;
  --blue: #1768d2;
  --blue-dark: #0b2c63;
  --paper: #f7f9fc;
  --line: #e2e8f0;
  --content-width: 1160px;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --ink: #e8eef8;
  --muted: #b0bfd5;
  --blue: #79b2ff;
  --blue-dark: #08172e;
  --paper: #111e31;
  --line: #2a3a50;
  --pengoworks-logo-ink: #e8eef8;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

a:focus-visible {
  outline: 3px solid #4693ff;
  outline-offset: 4px;
  border-radius: 3px;
}

.container {
  width: min(var(--content-width), calc(100% - 48px));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 3;
  padding: 8px 12px;
  transform: translateY(-150%);
  background: #fff;
  color: var(--ink);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: relative;
  z-index: 1;
  border-bottom: 1px solid rgba(20, 35, 59, .08);
  background: rgba(255, 255, 255, .92);
}

.header-inner {
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.brand {
  display: inline-flex;
  flex: 0 1 270px;
  align-items: center;
}

.brand img,
.brand svg {
  display: block;
  width: 100%;
  height: auto;
}

.theme-toggle {
  position: absolute;
  top: 50%;
  right: 16px;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}

.theme-toggle:hover {
  background: rgba(23, 104, 210, .08);
}

.theme-toggle::before {
  width: 19px;
  height: 19px;
  background-color: currentColor;
  -webkit-mask: url("theme-moon.svg") center / contain no-repeat;
  mask: url("theme-moon.svg") center / contain no-repeat;
  content: "";
}

html[data-theme="dark"] .theme-toggle::before {
  -webkit-mask-image: url("theme-sun.svg");
  mask-image: url("theme-sun.svg");
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 3vw, 36px);
  padding-right: 56px;
  font-size: 14px;
  font-weight: 600;
}

.site-nav a {
  text-decoration: none;
}

.site-nav a:not(.nav-cta):hover {
  color: var(--blue);
}

.nav-cta,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid var(--blue);
  border-radius: 7px;
  background: var(--blue);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: background-color .18s ease, transform .18s ease;
}

.nav-cta:hover,
.button:hover {
  transform: translateY(-1px);
  background: #0e56b6;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(72px, 10vw, 132px) 0 clamp(80px, 10vw, 132px);
  background:
    radial-gradient(ellipse at 85% 50%, rgba(35, 122, 242, .10), transparent 38%),
    linear-gradient(180deg, #fbfcfe 0%, var(--paper) 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, .95fr);
  align-items: center;
  gap: clamp(48px, 8vw, 104px);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 0 0 22px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 25px;
  height: 2px;
  background: currentColor;
  content: "";
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 660px;
  margin-bottom: 23px;
  font-size: clamp(44px, 6vw, 72px);
  font-weight: 750;
  letter-spacing: -.055em;
  line-height: 1.04;
}

h1 span {
  color: var(--blue);
}

.hero-copy > p:not(.eyebrow) {
  max-width: 590px;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: clamp(17px, 1.7vw, 19px);
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px 24px;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.text-link:hover {
  color: var(--blue);
}

.hero-art {
  position: relative;
  min-height: 398px;
  display: grid;
  place-items: center;
  isolation: isolate;
}

.art-orbit {
  position: absolute;
  z-index: -1;
  width: min(100%, 410px);
  aspect-ratio: 1;
  border: 1px solid rgba(23, 104, 210, .16);
  border-radius: 50%;
}

.art-orbit::before,
.art-orbit::after {
  position: absolute;
  border: 1px solid rgba(23, 104, 210, .12);
  border-radius: 50%;
  content: "";
}

.art-orbit::before {
  inset: 12%;
}

.art-orbit::after {
  inset: 25%;
}

.art-orbit-dot {
  position: absolute;
  top: 16%;
  right: 15%;
  width: 13px;
  height: 13px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: #3a8df5;
  box-shadow: 0 0 0 5px rgba(58, 141, 245, .16);
}

.concept-card {
  width: min(100%, 340px);
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 16px;
  background: linear-gradient(145deg, #143f83, #092754);
  box-shadow: 0 28px 70px rgba(11, 44, 99, .22);
  color: #fff;
  transform: rotate(-3deg);
}

.concept-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .18);
  color: #c9dcf9;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.concept-card-top span:first-child {
  display: flex;
  gap: 5px;
}

.concept-card-top i {
  width: 6px;
  height: 6px;
  display: block;
  border-radius: 50%;
  background: #6eaafa;
}

.concept-card h2 {
  margin: 25px 0 8px;
  font-size: 32px;
  letter-spacing: -.04em;
  line-height: 1.15;
}

.concept-card p {
  margin: 0 0 25px;
  color: #c4d5ef;
  font-size: 14px;
}

.concept-row {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-top: 10px;
  padding: 11px 13px;
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 8px;
  background: rgba(255, 255, 255, .07);
  color: #e6effc;
  font-size: 12px;
  font-weight: 600;
}

.concept-row b {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #5da4ff;
}

.art-note {
  position: absolute;
  right: 0;
  bottom: 12%;
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(25, 45, 80, .1);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  transform: rotate(4deg);
}

.art-note strong {
  display: block;
  margin-top: 3px;
  color: var(--ink);
  font-size: 14px;
}

.section {
  padding: clamp(76px, 9vw, 112px) 0;
}

.section-heading {
  max-width: 700px;
  margin-bottom: 42px;
}

.section-heading .eyebrow {
  margin-bottom: 16px;
}

.section-heading h2 {
  max-width: 680px;
  margin-bottom: 14px;
  font-size: clamp(32px, 4vw, 48px);
  letter-spacing: -.04em;
  line-height: 1.14;
}

.section-heading > p:last-child {
  max-width: 630px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 17px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.feature-card {
  min-height: 230px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.feature-number {
  display: inline-block;
  margin-bottom: 28px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .1em;
}

.feature-card h3 {
  margin-bottom: 10px;
  font-size: 19px;
  letter-spacing: -.02em;
}

.feature-card p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 14px;
}

.story {
  background: var(--paper);
}

.story-grid {
  display: grid;
  grid-template-columns: .8fr 1.2fr;
  align-items: start;
  gap: clamp(40px, 9vw, 120px);
}

.story h2 {
  margin-bottom: 0;
  font-size: clamp(30px, 4vw, 44px);
  letter-spacing: -.04em;
  line-height: 1.18;
}

.story-copy {
  max-width: 620px;
  color: var(--muted);
  font-size: 17px;
}

.story-copy p:last-child {
  margin-bottom: 0;
}

.contact {
  padding: clamp(64px, 8vw, 94px) 0;
  background:
    radial-gradient(circle at 85% 10%, rgba(73, 143, 240, .28), transparent 34%),
    var(--blue-dark);
  color: #fff;
}

.contact-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.contact h2 {
  margin-bottom: 8px;
  font-size: clamp(31px, 4vw, 46px);
  letter-spacing: -.04em;
  line-height: 1.15;
}

.contact p {
  margin-bottom: 0;
  color: #ccdaf0;
  font-size: 16px;
}

.contact .button {
  flex: 0 0 auto;
  border-color: #fff;
  background: #fff;
  color: var(--blue-dark);
}

.contact .button:hover {
  background: #e9f2ff;
}

.site-footer {
  padding: 23px 0;
  background: #071d40;
  color: #b7c8e1;
  font-size: 12px;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.site-footer p {
  margin: 0;
}

.footer-mark {
  color: #fff;
  font-weight: 700;
  letter-spacing: .02em;
}

.error-header {
  min-height: 92px;
}

.error-page {
  min-height: 60vh;
  display: flex;
  align-items: center;
}

.error-page .hero-copy > p.archive-note {
  margin: 28px 0 0;
  font-size: 14px;
}

html[data-theme="dark"] body {
  background: #0b1424;
}

html[data-theme="dark"] .site-header {
  border-bottom-color: rgba(255, 255, 255, .1);
  background: rgba(11, 20, 36, .94);
}

html[data-theme="dark"] .hero {
  background:
    radial-gradient(ellipse at 85% 50%, rgba(35, 122, 242, .16), transparent 38%),
    linear-gradient(180deg, #0d182a 0%, #111e31 100%);
}

html[data-theme="dark"] .feature-card {
  background: #111b2b;
}

html[data-theme="dark"] .art-note {
  border-color: #31435c;
  background: #17263c;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .28);
}

html[data-theme="dark"] .nav-cta,
html[data-theme="dark"] .button:not(.contact .button) {
  border-color: #1768d2;
  background: #1768d2;
  color: #fff;
}

html[data-theme="dark"] .nav-cta:hover,
html[data-theme="dark"] .button:not(.contact .button):hover {
  background: #0e56b6;
}

@media (max-width: 800px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 38px;
  }

  .hero-copy {
    max-width: 660px;
  }

  .hero-art {
    min-height: 340px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .feature-card {
    min-height: 0;
  }

  .feature-number {
    margin-bottom: 17px;
  }

  .story-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }
}

@media (max-width: 580px) {
  .container {
    width: min(var(--content-width), calc(100% - 36px));
  }

  .header-inner {
    min-height: 76px;
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    gap: 11px;
    padding-block: 13px;
  }

  .error-header {
    align-items: flex-start;
  }

  .error-header .theme-toggle {
    top: 50%;
    bottom: auto;
    transform: translateY(-50%);
  }

  .brand {
    flex-basis: auto;
    width: 190px;
  }

  .site-nav {
    width: 100%;
    justify-content: space-between;
    gap: 6px;
    padding-right: 0;
    font-size: 11px;
  }

  .site-nav > a,
  .theme-toggle {
    flex-shrink: 0;
    white-space: nowrap;
  }

  .nav-cta {
    min-height: 34px;
    gap: 5px;
    padding-inline: 8px;
  }

  .theme-toggle {
    top: auto;
    bottom: 13px;
    width: 34px;
    height: 34px;
    transform: none;
  }

  .hero {
    padding-block: 68px 74px;
  }

  h1 {
    font-size: clamp(42px, 12vw, 58px);
  }

  .hero-art {
    min-height: 310px;
  }

  .concept-card {
    width: min(88%, 340px);
    padding: 23px;
  }

  .art-note {
    right: -2px;
    bottom: 4%;
  }

  .contact-inner,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: .01ms !important;
  }
}
