:root {
  --ac-black: #050506;
  --ac-ink: #efe7dc;
  --ac-muted: #b6a994;
  --ac-faint: #897c6d;
  --ac-pink: #df7e9e;
  --ac-pink-bright: #ff9fbd;
  --ac-gold: #c09a6b;
  --ac-line: rgba(239, 231, 220, .14);
  --ac-line-soft: rgba(239, 231, 220, .08);
  --ac-panel: rgba(255, 255, 255, .035);
  --ac-ui: "Hanken Grotesk", system-ui, sans-serif;
  --ac-display: "Playfair Display", Georgia, serif;
}

* { box-sizing: border-box; }

html { min-width: 320px; scroll-behavior: smooth; }

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ac-ink);
  background:
    radial-gradient(70% 50% at 100% 0, rgba(223, 126, 158, .14), transparent 68%),
    radial-gradient(45% 38% at 0 100%, rgba(192, 154, 107, .09), transparent 72%),
    var(--ac-black);
  font: 16px/1.62 var(--ac-ui);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }

button { font: inherit; }

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

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--ac-pink-bright);
  outline-offset: 4px;
}

.wrap {
  width: min(calc(100% - 56px), 1180px);
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 20;
  padding: 11px 16px;
  border-radius: 999px;
  color: var(--ac-black);
  background: var(--ac-ink);
  transform: translateY(-180%);
}

.skip-link:focus { transform: none; }

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 92px;
  padding: 14px 0;
  border-bottom: 1px solid var(--ac-line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
}

.brand-mark {
  display: grid;
  width: 62px;
  height: 62px;
  flex: none;
  place-items: center;
  filter: drop-shadow(0 0 15px rgba(223, 126, 158, .38));
}

.brand-mark img { width: 100%; height: 100%; object-fit: contain; }

.brand-copy { display: block; }

.wordmark {
  display: block;
  color: var(--ac-ink);
  font: 600 24px/.94 var(--ac-display);
  letter-spacing: .16em;
}

.est {
  display: block;
  margin-top: 6px;
  color: var(--ac-faint);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .28em;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lang-switch {
  display: flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--ac-line);
  border-radius: 999px;
  background: rgba(255, 255, 255, .025);
}

.lang-switch a,
.back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 999px;
  color: var(--ac-muted);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .1em;
}

.lang-switch a:hover,
.lang-switch a[aria-current="page"] {
  color: #1a0d12;
  background: linear-gradient(180deg, #f6a4bd, var(--ac-pink));
}

.back {
  border: 1px solid var(--ac-line);
  border-radius: 8px;
  color: var(--ac-ink);
  letter-spacing: .03em;
}

.back:hover { border-color: var(--ac-pink); color: var(--ac-pink-bright); }

.eyebrow,
.route-kicker {
  margin: 0;
  color: var(--ac-pink);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .25em;
  text-transform: uppercase;
}

/* About and contribution pages */
.about-contact-page .hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--ac-line);
}

.about-contact-page .hero::after {
  content: "";
  position: absolute;
  right: -12rem;
  bottom: -19rem;
  width: min(48vw, 36rem);
  aspect-ratio: 1;
  border: 1px solid rgba(223, 126, 158, .24);
  border-radius: 50%;
  box-shadow: 0 0 0 2rem rgba(192, 154, 107, .035), 0 0 0 5rem rgba(223, 126, 158, .025);
  pointer-events: none;
}

.about-contact-page .hero .wrap {
  position: relative;
  z-index: 1;
  padding-block: clamp(4.5rem, 9vw, 7.5rem) clamp(3.5rem, 7vw, 5.5rem);
}

.about-contact-page h1 {
  max-width: 850px;
  margin: 18px 0 22px;
  color: var(--ac-ink);
  font: 600 clamp(2.8rem, 6vw, 5.2rem)/.99 var(--ac-display);
  letter-spacing: -.035em;
}

.lede {
  max-width: 68ch;
  margin: 0;
  color: var(--ac-muted);
  font-size: clamp(1.08rem, 1.7vw, 1.28rem);
  line-height: 1.58;
}

.status,
.callout {
  max-width: 70ch;
  margin-top: 30px;
  padding: 20px 22px;
  border-left: 2px solid var(--ac-pink);
  background: linear-gradient(110deg, rgba(223, 126, 158, .11), rgba(255, 255, 255, .025));
}

.status strong {
  display: block;
  color: var(--ac-ink);
  font-family: var(--ac-display);
  font-size: 1.22rem;
  line-height: 1.2;
}

.status p,
.callout { margin-bottom: 0; color: var(--ac-muted); }

.section {
  padding: clamp(3.6rem, 7vw, 6.5rem) 0;
  border-bottom: 1px solid var(--ac-line);
}

.section h2 {
  max-width: 25ch;
  margin: 12px 0 28px;
  color: var(--ac-ink);
  font: 600 clamp(2rem, 4vw, 3.5rem)/1.04 var(--ac-display);
  letter-spacing: -.025em;
}

.section > p { max-width: 70ch; color: var(--ac-muted); }

.route-grid {
  display: grid;
  gap: 14px;
}

.about-route-grid,
.contact-route-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.route-card {
  display: flex;
  min-height: 236px;
  flex-direction: column;
  padding: 26px;
  border: 1px solid var(--ac-line);
  border-top: 2px solid var(--ac-pink);
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(255, 255, 255, .055), rgba(255, 255, 255, .012));
  transition: border-color .2s, background .2s, transform .2s, box-shadow .2s;
}

.route-card:nth-child(2n) { border-top-color: var(--ac-gold); }
.route-card:nth-child(3n) { border-top-color: #80beb3; }
.route-card:nth-child(4n) { border-top-color: #9c8bcd; }

.route-card:hover,
.route-card:focus-visible {
  border-color: var(--ac-pink);
  background: rgba(223, 126, 158, .08);
  box-shadow: 0 18px 44px rgba(0, 0, 0, .2);
  transform: translateY(-3px);
}

.route-card h3 {
  max-width: 22ch;
  margin: 12px 0 10px;
  color: var(--ac-ink);
  font: 600 clamp(1.35rem, 2.5vw, 1.85rem)/1.1 var(--ac-display);
}

.route-card p,
.principle span,
.prep span { color: var(--ac-muted); }

.route-card p { margin: 0; }

.route-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 22px;
  color: var(--ac-pink-bright);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.route-card:hover .route-link { color: var(--ac-ink); }

.principles,
.prep-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.principle,
.prep {
  min-height: 150px;
  padding: 22px;
  border: 1px solid var(--ac-line-soft);
  background: var(--ac-panel);
}

.principle b,
.prep b {
  display: block;
  margin-bottom: 12px;
  color: var(--ac-ink);
  font: 600 1.25rem/1.15 var(--ac-display);
}

.section .callout { margin-top: 0; }

.section .back,
.section > p > a:not(.back) {
  display: inline-flex;
  margin-top: 14px;
  border-bottom: 1px solid var(--ac-pink);
  border-radius: 0;
  color: var(--ac-pink-bright);
  font-weight: 800;
}

.about-contact-page footer,
.site-footer { border-top: 1px solid var(--ac-line); }

.about-contact-page footer .wrap {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding-block: 24px 34px;
  color: var(--ac-faint);
  font-size: 12px;
}

.footer-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.footer-links a:hover { color: var(--ac-pink-bright); }

/* Not-found recovery page */
.recovery-page .error-hero {
  display: grid;
  grid-template-columns: minmax(280px, .78fr) minmax(0, 1.22fr);
  align-items: center;
  gap: clamp(44px, 8vw, 100px);
  padding: clamp(60px, 10vw, 116px) 0 76px;
}

.error-art {
  position: relative;
  display: grid;
  min-height: 380px;
  place-items: center;
}

.error-art::before,
.error-art::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(192, 154, 107, .28);
  border-radius: 50%;
}

.error-art::before {
  width: min(36vw, 350px);
  height: min(36vw, 350px);
  box-shadow: 0 0 70px rgba(223, 126, 158, .14), inset 0 0 44px rgba(192, 154, 107, .08);
}

.error-art::after {
  width: min(27vw, 252px);
  height: min(27vw, 252px);
  border-color: rgba(223, 126, 158, .3);
  transform: rotate(28deg);
}

.error-art img {
  position: relative;
  width: min(24vw, 220px);
  height: min(24vw, 220px);
  object-fit: contain;
  filter: drop-shadow(0 0 25px rgba(223, 126, 158, .38));
  animation: ac-breathe 5.5s ease-in-out infinite;
}

.error-code {
  position: absolute;
  right: 1%;
  bottom: 4px;
  color: rgba(239, 231, 220, .08);
  font: 600 clamp(100px, 17vw, 190px)/.8 var(--ac-display);
  letter-spacing: -.08em;
}

.error-copy { max-width: 680px; }
.error-copy h1 {
  max-width: 680px;
  margin: 16px 0 20px;
  color: var(--ac-ink);
  font: 600 clamp(2.9rem, 6.5vw, 5.15rem)/.97 var(--ac-display);
  letter-spacing: -.035em;
}

.error-copy .lede { max-width: 590px; }

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 52px;
  padding: 13px 20px;
  border: 0;
  border-radius: 9px;
  font: 800 12px var(--ac-ui);
  letter-spacing: .12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform .2s, border-color .2s, background .2s;
}

.button-primary {
  color: #1a0d12;
  background: linear-gradient(180deg, #f6a4bd, var(--ac-pink));
  box-shadow: 0 14px 32px rgba(223, 126, 158, .16);
}

.button-secondary {
  border: 1px solid rgba(192, 154, 107, .6);
  color: var(--ac-ink);
  background: rgba(255, 255, 255, .025);
}

.button:hover { border-color: var(--ac-pink); transform: translateY(-2px); }
.back-note { margin: 15px 0 0; color: var(--ac-faint); font-size: 13px; }

.route-panel {
  padding: 26px 0 78px;
  border-top: 1px solid var(--ac-line);
}

.recovery-page .route-kicker { margin-bottom: 18px; color: var(--ac-gold); }
.recovery-page .route-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.recovery-page .route-link {
  display: flex;
  min-height: 150px;
  flex-direction: column;
  justify-content: space-between;
  padding: 17px;
  border: 1px solid var(--ac-line);
  border-radius: 11px;
  background: linear-gradient(145deg, rgba(255, 255, 255, .055), rgba(255, 255, 255, .012));
  transition: border-color .2s, background .2s, transform .2s;
}

.recovery-page .route-link:hover,
.recovery-page .route-link:focus-visible {
  border-color: var(--ac-pink);
  background: rgba(223, 126, 158, .08);
  transform: translateY(-3px);
}

.route-number { color: var(--ac-gold); font: 800 13px var(--ac-ui); letter-spacing: .15em; }
.recovery-page .route-link strong { font: 600 clamp(1.1rem, 1.8vw, 1.45rem)/1.1 var(--ac-display); }
.route-arrow { align-self: flex-end; color: var(--ac-pink); font-size: 22px; }

.site-footer { color: var(--ac-faint); font-size: 12px; }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 20px; padding: 22px 0 30px; }
.site-footer a { color: var(--ac-muted); font-weight: 700; }
.site-footer a:hover { color: var(--ac-pink); }

@keyframes ac-breathe {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-7px) rotate(2deg); }
}

@media (max-width: 820px) {
  .recovery-page .route-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .recovery-page .error-hero { gap: 30px; }
  .error-art { min-height: 300px; }
  .error-art::before { width: min(48vw, 300px); height: min(48vw, 300px); }
  .error-art::after { width: min(36vw, 225px); height: min(36vw, 225px); }
  .error-art img { width: min(31vw, 190px); height: min(31vw, 190px); }
}

@media (max-width: 640px) {
  .wrap { width: min(calc(100% - 28px), 520px); }
  .nav { align-items: flex-start; flex-wrap: wrap; }
  .nav-actions { width: 100%; justify-content: space-between; }
  .brand-mark { width: 54px; height: 54px; }
  .wordmark { font-size: 21px; }
  .est { font-size: 13px; }
  .about-contact-page .hero .wrap { padding-block: 3.5rem 3rem; }
  .about-contact-page .hero::after { right: -13rem; bottom: -16rem; }
  .about-contact-page .about-route-grid,
  .about-contact-page .contact-route-grid,
  .principles,
  .prep-grid { grid-template-columns: 1fr; }
  .route-card { min-height: 0; padding: 21px; }
  .status,
  .callout { padding: 18px; }
  .recovery-page .error-hero { display: block; padding: 48px 0 54px; }
  .error-art { min-height: 210px; margin-bottom: 38px; }
  .error-art::before { width: 210px; height: 210px; }
  .error-art::after { width: 155px; height: 155px; }
  .error-art img { width: 145px; height: 145px; }
  .error-code { right: 8%; bottom: -3px; font-size: 100px; }
  .actions { display: grid; }
  .button { width: 100%; }
  .recovery-page .route-link { min-height: 126px; padding: 14px; }
  .recovery-page .route-link strong { font-size: 1.2rem; }
  .about-contact-page footer .wrap,
  .site-footer .wrap { display: block; }
  .about-contact-page footer .wrap { padding-block: 22px 30px; }
  .site-footer a { display: inline-block; margin-top: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
  .button:hover,
  .route-card:hover,
  .recovery-page .route-link:hover { transform: none; }
}
