:root {
  --paper: #f7f6f3;
  --paper-raised: #ffffff;
  --ink: #0a0a0a;

  --text: #17171a;
  --text-soft: rgba(10, 10, 10, 0.62);
  --text-dim: rgba(10, 10, 10, 0.42);

  --surface: rgba(255, 255, 255, 0.72);
  --surface-hover: rgba(255, 255, 255, 0.92);
  --surface-sunken: #f1efeb;
  --line: rgba(10, 10, 10, 0.09);
  --line-strong: rgba(10, 10, 10, 0.18);

  --blur: saturate(120%) blur(18px);
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;

  --shadow-soft: 0 12px 40px rgba(18, 18, 24, 0.07);
  --shadow-lift: 0 26px 60px rgba(18, 18, 24, 0.14);
  --shadow-panel: -24px 0 80px rgba(18, 18, 24, 0.18);

  --font-ui: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Instrument Serif', 'Times New Roman', Georgia, serif;

  --shell: 1180px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--paper);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.is-locked {
  overflow: hidden;
}

h1,
h2,
h3,
h4,
p,
figure,
dl,
dd {
  margin: 0;
}

h1,
h2,
h3,
h4 {
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

/* Serif accent used inside headings for the aesthetic words */
.accent {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

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

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

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection {
  background: var(--ink);
  color: #ffffff;
}

kbd {
  display: inline-block;
  padding: 0.1em 0.45em;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: var(--paper-raised);
  font-family: var(--font-ui);
  font-size: 0.74em;
  letter-spacing: 0.02em;
}

/* Layout ------------------------------------------------------------------ */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 40px);
}

main.shell {
  padding-bottom: 96px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 12px;
  z-index: 60;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: #ffffff;
  font-weight: 500;
}

.skip-link:focus {
  left: 20px;
}

/* Typography ------------------------------------------------------------- */

.eyebrow {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.section-title {
  font-size: clamp(1.8rem, 3.6vw, 2.4rem);
  font-weight: 600;
}

.section-title .accent {
  font-size: 1.12em;
  color: var(--text-soft);
}

.section-sub {
  margin-top: 4px;
  color: var(--text-soft);
  font-size: 0.92rem;
  font-weight: 300;
}

/* Top bar ---------------------------------------------------------------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid var(--line);
  background: rgba(250, 249, 247, 0.78);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand__logo {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: cover;
  mix-blend-mode: multiply;
}

.brand__text {
  display: flex;
  align-items: baseline;
  gap: 7px;
}

.brand__name {
  font-size: 1.16rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.brand__sub {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.16rem;
  color: var(--text-soft);
}

.topbar__nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.topbar__link {
  padding: 9px 14px;
  border-radius: 999px;
  color: var(--text-soft);
  font-size: 0.88rem;
  font-weight: 400;
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
}

.topbar__link:hover {
  color: var(--ink);
  background: var(--surface-sunken);
}

.topbar__credit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding-left: 14px;
  margin-left: 6px;
  border-left: 1px solid var(--line);
  color: var(--text-dim);
  font-size: 0.78rem;
  font-weight: 300;
  white-space: nowrap;
}

.topbar__credit a {
  color: var(--text);
  font-weight: 500;
}

.topbar__credit a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Social links ----------------------------------------------------------- */

.social {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.social__link {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid transparent;
  border-radius: 50%;
  color: var(--text-soft);
  transition: color 0.25s var(--ease), background 0.25s var(--ease),
    border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.social__link:hover {
  color: var(--ink);
  background: var(--paper-raised);
  border-color: var(--line);
  transform: translateY(-1px);
}

.social__link svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

.social--footer .social__link {
  width: 32px;
  height: 32px;
}

/* Footer ----------------------------------------------------------------- */

.footer {
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-top: 28px;
  padding-bottom: 28px;
}

.footer__credit {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-soft);
  font-weight: 300;
}

.footer__credit strong {
  color: var(--ink);
  font-weight: 500;
}

.footer__note {
  font-size: 0.82rem;
  font-weight: 300;
  color: var(--text-dim);
}

@media (max-width: 900px) {
  .topbar__credit,
  .topbar__link {
    display: none;
  }
}

@media (max-width: 620px) {
  .topbar__inner {
    min-height: 66px;
  }

  .brand__logo {
    width: 36px;
    height: 36px;
  }

  .social {
    display: none;
  }

  .footer__inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
