:root {
  color-scheme: light dark;
  --page: #eef3f8;
  --surface: #f8fafc;
  --surface-strong: #e7eef5;
  --ink: #0a1728;
  --muted: #516073;
  --line: rgba(14, 38, 64, 0.13);
  --accent: #008fb8;
  --accent-strong: #006d8f;
  --shadow: rgba(27, 56, 82, 0.15);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--page);
}

body {
  min-height: 100dvh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 82% 12%, rgba(0, 168, 213, 0.10), transparent 28rem),
    linear-gradient(150deg, var(--page), var(--surface-strong));
  font-family: ui-rounded, "SF Pro Rounded", "SF Pro Display", -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

.portal-shell {
  width: min(1240px, calc(100% - 48px));
  min-height: 100dvh;
  margin: 0 auto;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.portal-header {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  font-size: 18px;
  font-weight: 720;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 10px;
  background: rgba(0, 143, 184, 0.11);
}

.brand-mark img {
  width: 24px;
  height: 24px;
}

.header-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 640;
}

.portal-hero {
  align-self: center;
  padding: 32px 0 36px;
}

.hero-copy {
  max-width: 700px;
  margin-bottom: 24px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1 {
  max-width: 620px;
  margin: 0;
  font-size: clamp(48px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.055em;
}

.intro {
  max-width: 600px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.45;
}

.path-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 18px;
}

.path-card {
  position: relative;
  isolation: isolate;
  min-height: 280px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(248, 250, 252, 0.77);
  box-shadow: 0 22px 70px var(--shadow);
  text-decoration: none;
  transition:
    transform 220ms cubic-bezier(0.16, 1, 0.3, 1),
    border-color 220ms ease,
    box-shadow 220ms ease;
}

.path-card:hover,
.path-card:focus-visible {
  transform: translateY(-4px);
  border-color: rgba(0, 143, 184, 0.46);
  box-shadow: 0 30px 84px rgba(0, 91, 124, 0.19);
  outline: none;
}

.path-card:active {
  transform: translateY(-1px) scale(0.995);
}

.card-copy {
  position: relative;
  z-index: 2;
  width: min(100%, 520px);
  min-height: 280px;
  padding: 30px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.card-kicker {
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.card-title {
  margin-top: 12px;
  font-size: clamp(31px, 4vw, 48px);
  font-weight: 760;
  line-height: 1;
  letter-spacing: -0.04em;
}

.card-description {
  max-width: 420px;
  margin-top: 15px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
}

.card-action {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-strong);
  font-size: 15px;
  font-weight: 720;
}

.card-action span {
  transition: transform 220ms cubic-bezier(0.16, 1, 0.3, 1);
}

.path-card:hover .card-action span,
.path-card:focus-visible .card-action span {
  transform: translateX(4px);
}

.card-visual {
  position: absolute;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.card-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-visual-docs {
  right: -76px;
  bottom: -92px;
  width: 270px;
  height: 270px;
  opacity: 0.52;
  transform: rotate(-5deg);
}

.path-card-docs .card-copy {
  padding-right: 74px;
}

.path-card-academy {
  background: #071827;
  border-color: rgba(77, 210, 240, 0.23);
  color: #edf7fb;
}

.path-card-academy .card-description {
  color: #afc2ce;
}

.path-card-academy .card-kicker,
.path-card-academy .card-action {
  color: #41c1df;
}

.path-card-academy .card-copy {
  width: 54%;
  background: linear-gradient(90deg, #071827 76%, rgba(7, 24, 39, 0));
}

.card-visual-academy {
  inset: 0 0 0 42%;
}

.card-visual-academy::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, #071827 0%, rgba(7, 24, 39, 0.74) 24%, rgba(7, 24, 39, 0.14) 70%),
    linear-gradient(0deg, rgba(7, 24, 39, 0.28), transparent);
}

.card-visual-academy img {
  object-position: top left;
  transform: scale(1.03);
}

.portal-footer {
  min-height: 72px;
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.portal-footer a {
  flex: 0 0 auto;
  color: var(--accent-strong);
  font-weight: 680;
  text-decoration: none;
}

.portal-footer a:hover,
.portal-footer a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 4px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --page: #050c16;
    --surface: #0a1624;
    --surface-strong: #0d1c2b;
    --ink: #e9f2f7;
    --muted: #9aafbc;
    --line: rgba(180, 218, 234, 0.13);
    --accent: #31b8d8;
    --accent-strong: #50c7e2;
    --shadow: rgba(0, 6, 14, 0.38);
  }

  body {
    background:
      radial-gradient(circle at 82% 12%, rgba(29, 176, 211, 0.13), transparent 30rem),
      linear-gradient(150deg, var(--page), var(--surface-strong));
  }

  .brand-mark {
    background: rgba(49, 184, 216, 0.13);
  }

  .path-card {
    background: rgba(10, 22, 36, 0.80);
  }

  .path-card-academy {
    background: #071827;
  }
}

@media (max-width: 860px) {
  .portal-shell {
    width: min(100% - 32px, 680px);
  }

  .portal-hero {
    padding: 34px 0;
  }

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

  .path-card {
    min-height: 286px;
  }

  .card-copy {
    min-height: 286px;
  }
}

@media (max-width: 560px) {
  .portal-shell {
    width: min(100% - 24px, 480px);
  }

  .portal-header {
    height: 62px;
  }

  .header-label {
    display: none;
  }

  .portal-hero {
    padding: 34px 0 28px;
  }

  .hero-copy {
    margin-bottom: 26px;
  }

  h1 {
    font-size: clamp(44px, 15vw, 62px);
  }

  .intro {
    margin-top: 16px;
    font-size: 17px;
  }

  .path-card,
  .card-copy {
    min-height: 292px;
  }

  .card-copy {
    width: 100%;
    padding: 24px;
  }

  .path-card-docs .card-copy {
    padding-right: 24px;
  }

  .path-card-docs .card-description {
    max-width: 23ch;
  }

  .card-visual-docs {
    right: -126px;
  }

  .path-card-academy .card-copy {
    width: 100%;
    background: linear-gradient(90deg, #071827 0%, rgba(7, 24, 39, 0.92) 78%, rgba(7, 24, 39, 0.56));
  }

  .card-visual-academy {
    inset: 0 0 0 34%;
    opacity: 0.58;
  }

  .card-description {
    max-width: 32ch;
  }

  .portal-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .path-card,
  .card-action span {
    transition: none;
  }
}
