/* ponytail: full 352 KB variable font; subset to Latin + Latin Ext (~100 KB) with pyftsubset if page weight matters */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/InterVariable.woff2") format("woff2");
}

:root {
  --bg: #0f172a;
  --text: #94a3b8;
  /* slate-500 (#64748b) fails WCAG AA on --bg (3.75:1); this is 4.92:1 */
  --text-muted: #7a879e;
  --text-strong: #e2e8f0;
  --accent: #5eead4;
  --chip-bg: rgba(45, 212, 191, 0.1);
  --spotlight: rgba(29, 78, 216, 0.15);
  --gutter: 24px;
}

/* Base */

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

html {
  font-family:
    "Inter",
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    "Helvetica Neue",
    Arial,
    sans-serif;
  font-feature-settings: "ss03", "cv02", "cv11";
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  line-height: 1.625;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
p,
ul {
  margin: 0;
}

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

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

a:hover {
  color: var(--accent);
}

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

::selection {
  background: var(--accent);
  color: #134e4a;
}

@media (prefers-reduced-motion: no-preference) {
  a {
    transition: color 150ms cubic-bezier(0.4, 0, 0.2, 1);
  }
}

/* Spotlight: desktop only, off under reduced motion */

.spotlight {
  display: none;
}

@media (min-width: 1024px) and (prefers-reduced-motion: no-preference) {
  .spotlight {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 30;
    pointer-events: none;
    background: radial-gradient(
      600px circle at var(--x, -100vw) var(--y, -100vh),
      var(--spotlight),
      transparent 80%
    );
  }
}

/* Layout */

.container {
  max-width: 1280px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 48px var(--gutter);
}

.content {
  padding-top: 96px;
}

.section {
  margin-bottom: 64px;
}

/* Header */

h1 {
  color: var(--text-strong);
  font-size: 2.25rem;
  line-height: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.025em;
}

.headline {
  margin-top: 12px;
  color: var(--text-strong);
  font-size: 1.125rem;
  line-height: 1.75rem;
  font-weight: 500;
  letter-spacing: -0.025em;
}

.tagline {
  max-width: 20rem;
  margin-top: 16px;
  line-height: 1.5;
}

.social {
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 32px 0 0 4px;
}

.social a,
.social svg {
  display: block;
}

/* Sections */

.section-title {
  position: sticky;
  top: 0;
  z-index: 20;
  margin: 0 calc(-1 * var(--gutter)) 16px;
  padding: 20px var(--gutter);
  background: rgba(15, 23, 42, 0.75);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.section-title h2 {
  color: var(--text-strong);
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.strong {
  color: var(--text-strong);
}

/* Skills */

.group-label {
  margin-top: 28px;
  color: var(--text-muted);
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

.section-title + .group-label {
  margin-top: 0;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 6px;
  margin-top: 12px;
}

.chips li {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 9999px;
  background: var(--chip-bg);
  color: var(--accent);
  font-size: 0.75rem;
  line-height: 1.25rem;
  font-weight: 500;
}

.resume {
  margin-top: 48px;
}

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

.resume a:hover {
  color: var(--accent);
}

/* Footer */

.footer {
  max-width: 28rem;
  padding-bottom: 64px;
  color: var(--text-muted);
  font-size: 0.875rem;
  line-height: 1.25rem;
}

/* 404 page */

.not-found {
  display: grid;
  place-content: center;
  min-height: 100vh;
  padding: 0 var(--gutter);
  text-align: center;
}

.not-found .tagline a {
  color: var(--text-strong);
}

.not-found .tagline a:hover {
  color: var(--accent);
}

/* Breakpoints (mobile-first) */

@media (min-width: 640px) {
  h1 {
    font-size: 3rem;
    line-height: 1;
  }

  .headline {
    font-size: 1.25rem;
  }

  .footer {
    padding-bottom: 0;
  }
}

@media (min-width: 768px) {
  :root {
    --gutter: 48px;
  }

  .container {
    padding: 64px var(--gutter);
  }

  .section {
    margin-bottom: 96px;
  }
}

@media (min-width: 1024px) {
  .container {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0 var(--gutter);
  }

  .header {
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 48%;
    max-height: 100vh;
    padding: 96px 0;
  }

  .content {
    width: 52%;
    padding: 96px 0;
  }

  .section {
    margin-bottom: 144px;
  }

  /* Section titles are for screen readers only on desktop (same as the reference design) */
  .section-title {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
}
