@import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,400;0,500;0,700;1,400&family=Roboto+Mono:wght@400;500&display=swap");

:root {
  color-scheme: dark;
  --fk-cobalt: #315cff;
  --fk-emerald: #00b884;
  --fk-deep-black: #010611;
  --fk-midnight-navy: #021125;
  --fk-deep-blue: #07274a;
  --fk-near-black: #101318;
  --fk-soft-white: #fcfcfc;
  --fk-cool-silver: #bec6cd;
  --fk-steel-gray: #73777f;
  --cobalt: var(--fk-cobalt);
  --emerald: var(--fk-emerald);
  --deep-black: var(--fk-deep-black);
  --midnight: var(--fk-midnight-navy);
  --near-black: var(--fk-near-black);
  --soft-white: var(--fk-soft-white);
  --silver: var(--fk-cool-silver);
  --steel: var(--fk-steel-gray);
  --rule: rgba(190, 198, 205, 0.2);
  --surface-raised: rgba(7, 39, 74, 0.2);
  --max-width: 1440px;
  --gutter: 80px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --ease-mech: cubic-bezier(0.2, 0, 0, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--deep-black);
  color: var(--soft-white);
  font-family: Roboto, Arial, Helvetica, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  background: var(--soft-white);
  color: var(--deep-black);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

:focus-visible {
  outline: 3px solid var(--emerald);
  outline-offset: 4px;
}

.container {
  width: min(100% - (var(--gutter) * 2), var(--max-width));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--rule);
  background: rgba(1, 6, 17, 0.92);
  backdrop-filter: blur(18px) saturate(1.35);
  -webkit-backdrop-filter: blur(18px) saturate(1.35);
}

.nav-row {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.brand::before {
  content: "";
  display: inline-block;
  width: 24px;
  height: 6px;
  margin-right: 12px;
  background: var(--cobalt);
  vertical-align: 2px;
}

.brand span {
  color: var(--silver);
  font-weight: 400;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.88rem;
}

.nav-links a {
  color: var(--silver);
  text-decoration: none;
  transition: color 180ms var(--ease-mech);
}

.nav-links a:hover {
  color: var(--soft-white);
}

.nav-links .nav-action {
  padding: 9px 12px;
  border: 1px solid var(--rule);
  border-radius: var(--radius-sm);
  color: var(--soft-white);
}

.nav-links .nav-action:hover {
  border-color: var(--silver);
  background: rgba(190, 198, 205, 0.06);
}

.hero {
  padding: 94px 0 78px;
  overflow: hidden;
  border-bottom: 1px solid var(--rule);
  background: var(--midnight);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 64px;
  align-items: end;
}

.eyebrow,
.section-label,
.meta {
  margin: 0;
  color: var(--silver);
  font-family: "Roboto Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 0.75rem;
  line-height: 1.5;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.eyebrow {
  color: #9eb1ff;
}

.section-label {
  color: #9eb1ff;
}

h1 {
  max-width: 820px;
  margin: 18px 0 20px;
  font-size: 4rem;
  line-height: 1.04;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 720px;
  margin: 0;
  color: var(--silver);
  font-size: 1.12rem;
}

.archive-count {
  min-width: 170px;
  padding-left: 24px;
  border-left: 2px solid var(--cobalt);
}

.archive-count strong {
  display: block;
  font-size: 3.5rem;
  line-height: 1;
}

.archive-count span {
  display: block;
  margin-top: 10px;
  color: var(--silver);
  font-size: 0.85rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border: 1px solid rgba(252, 252, 252, 0.38);
  border-radius: var(--radius-sm);
  color: var(--soft-white);
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  transition:
    background 180ms var(--ease-mech),
    border-color 180ms var(--ease-mech),
    color 180ms var(--ease-mech);
}

.button-primary {
  border-color: var(--cobalt);
  background: var(--cobalt);
}

.button:hover {
  border-color: var(--soft-white);
  background: var(--soft-white);
  color: var(--deep-black);
}

.gallery-section {
  padding: 82px 0 94px;
}

.section-head {
  display: grid;
  gap: 18px;
  max-width: 780px;
  margin-bottom: 46px;
}

h2 {
  margin: 0;
  font-size: 2.75rem;
  line-height: 1.08;
  letter-spacing: 0;
}

h3 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.3;
  letter-spacing: 0;
}

.section-intro {
  margin: 0;
  color: var(--silver);
  font-size: 1.05rem;
}

.certificate-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.certificate-card {
  min-width: 0;
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  background: var(--near-black);
  overflow: hidden;
  transition:
    background 420ms var(--ease-mech),
    border-color 420ms var(--ease-mech);
}

.certificate-card::before {
  content: "";
  display: block;
  width: 38%;
  height: 1px;
  background: linear-gradient(90deg, var(--cobalt), transparent);
  transition: width 420ms var(--ease-mech);
}

.certificate-card:hover {
  border-color: var(--cobalt);
  background: var(--surface-raised);
}

.certificate-card:hover::before {
  width: 100%;
}

.certificate-link {
  height: 100%;
  display: flex;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
}

.certificate-image {
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 10px;
  background: #eef1f5;
}

.certificate-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.certificate-copy {
  min-height: 154px;
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 16px;
}

.certificate-copy h3 {
  min-height: 2.6em;
}

.certificate-issuer {
  margin: 10px 0 0;
  overflow-wrap: anywhere;
  color: var(--silver);
  font-size: 0.76rem;
  line-height: 1.4;
}

.certificate-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 14px;
  color: var(--steel);
  font-family: "Roboto Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 0.68rem;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.certificate-meta span:last-child {
  color: #9eb1ff;
  white-space: nowrap;
}

.closing {
  padding: 84px 0;
  background: var(--soft-white);
  color: var(--near-black);
}

.closing-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: end;
}

.closing h2 {
  max-width: 720px;
}

.closing .section-label {
  margin-bottom: 16px;
  color: #4d535a;
}

.closing .button {
  border-color: var(--near-black);
  color: var(--near-black);
}

.closing .button-primary {
  border-color: var(--cobalt);
  color: var(--soft-white);
}

.site-footer {
  padding: 40px 0;
  border-top: 3px solid var(--cobalt);
  background: var(--near-black);
}

.footer-row {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  align-items: flex-start;
}

.footer-brand {
  margin: 0;
  font-weight: 700;
}

.footer-brand span {
  display: block;
  margin-top: 5px;
  color: var(--steel);
  font-size: 0.82rem;
  font-weight: 400;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px 22px;
  font-size: 0.88rem;
}

.footer-links a {
  color: var(--silver);
  text-underline-offset: 4px;
}

@media (max-width: 960px) {
  :root {
    --gutter: 40px;
  }

  .certificate-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero-grid,
  .closing-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .nav-links .section-nav {
    display: none;
  }
}

@media (max-width: 620px) {
  :root {
    --gutter: 20px;
  }

  body {
    font-size: 16px;
  }

  .nav-row {
    min-height: 64px;
  }

  .brand span {
    display: none;
  }

  .brand::before {
    width: 18px;
    margin-right: 8px;
  }

  .nav-links {
    gap: 9px;
    font-size: 0.78rem;
  }

  .nav-links .nav-action {
    padding: 8px 9px;
  }

  .hero {
    padding: 72px 0 58px;
  }

  h1 {
    font-size: 2.55rem;
  }

  .hero-copy {
    font-size: 1rem;
  }

  .archive-count {
    min-width: 0;
  }

  .actions {
    align-items: stretch;
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .gallery-section,
  .closing {
    padding: 64px 0;
  }

  h2 {
    font-size: 2rem;
  }

  .section-head {
    margin-bottom: 34px;
  }

  .certificate-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .certificate-image {
    padding: 6px;
  }

  .certificate-copy {
    min-height: 140px;
    padding: 12px;
  }

  .certificate-copy h3 {
    min-height: 3.8em;
    font-size: 0.82rem;
  }

  .certificate-issuer {
    font-size: 0.68rem;
  }

  .certificate-meta {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
    font-size: 0.64rem;
  }

  .footer-row {
    flex-direction: column;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

/* Simplified learning archive */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.brand {
  width: 42px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  flex: none;
}

.brand::before {
  content: none;
}

.brand img {
  width: 42px;
  height: auto;
}

.hero {
  padding: 88px 0 72px;
}

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

.gallery-section {
  padding-top: 72px;
}

.certificate-copy {
  min-height: 132px;
}

.certificate-meta {
  justify-content: flex-start;
}

.certificate-meta span {
  color: #9eb1ff;
  white-space: nowrap;
}

@media (max-width: 620px) {
  .brand,
  .brand img {
    width: 34px;
  }

  .certificate-meta {
    display: block;
  }
}

/* Shared personal-site navigation and archive controls */
.brand {
  width: auto;
  gap: 12px;
  font-weight: 700;
}

.brand img {
  width: 34px;
}

.brand span {
  color: var(--soft-white);
  font-weight: 700;
}

main section[id] {
  scroll-margin-top: 72px;
}

.hero h1 {
  max-width: 960px;
}

.archive-badge {
  width: fit-content;
  margin: 24px 0 0;
  padding: 8px 12px;
  border: 1px solid rgba(49, 92, 255, 0.5);
  border-radius: var(--radius-sm);
  background: rgba(49, 92, 255, 0.08);
  color: #9eb1ff;
  font-family: "Roboto Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.page-scroll {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 40;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: 1px solid rgba(252, 252, 252, 0.3);
  border-radius: var(--radius-sm);
  background: rgba(1, 6, 17, 0.9);
  color: var(--soft-white);
  font-family: "Roboto Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 0.7rem;
  cursor: pointer;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  transition:
    border-color 180ms var(--ease-mech),
    background 180ms var(--ease-mech);
}

.page-scroll:hover {
  border-color: var(--cobalt);
  background: var(--midnight);
}

.page-scroll__arrow {
  color: #9eb1ff;
  font-size: 1rem;
  transition: transform 180ms var(--ease-mech);
}

.page-scroll.is-at-end .page-scroll__arrow {
  transform: rotate(180deg);
}

.footer-brand {
  font-size: 1rem;
}

.footer-brand span {
  color: var(--silver);
}

@media (max-width: 960px) {
  .nav-links {
    gap: 13px;
    font-size: 0.8rem;
  }
}

@media (max-width: 620px) {
  main section[id] {
    scroll-margin-top: 64px;
  }

  .brand,
  .brand img {
    width: auto;
  }

  .brand img {
    width: 28px;
  }

  .brand span {
    display: inline;
  }

  .optional-nav {
    display: none;
  }

  .page-scroll {
    right: 16px;
    bottom: 16px;
  }
}
