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

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

dd {
  margin: 0;
}

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

:root {
  color-scheme: light;
  --ink: #111412;
  --muted: #5b645f;
  --paper: #f5f5f0;
  --surface: #ffffff;
  --surface-soft: #edf1ed;
  --line: #d6ddd7;
  --line-strong: #aeb9b1;
  --accent: #0e695e;
  --shadow: 0 18px 60px rgba(17, 20, 18, 0.08);
  --radius: 8px;
  --max: 1060px;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background:
    linear-gradient(90deg, rgba(17, 20, 18, 0.035) 1px, transparent 1px),
    linear-gradient(180deg, rgba(17, 20, 18, 0.035) 1px, transparent 1px),
    var(--paper);
  background-size: 40px 40px;
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  font-size: 0.96rem;
  line-height: 1.55;
}

a {
  color: inherit;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

.svg-sprite {
  display: none;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent), white 30%);
  outline-offset: 4px;
}

.profile-shell {
  width: min(calc(100% - 2rem), var(--max));
  margin-inline: auto;
  padding-block: 0.9rem 1.5rem;
}

.profile-header,
.brand,
.language-toggle,
.action-row {
  display: flex;
  align-items: center;
}

.profile-header {
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: clamp(1.25rem, 4vw, 2.4rem);
}

.brand {
  gap: 0.65rem;
  font-weight: 850;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 2.05rem;
  aspect-ratio: 1;
  place-items: center;
  border-radius: var(--radius);
  background: var(--ink);
  color: white;
  font-size: 0.76rem;
  letter-spacing: 0.04em;
}

.language-toggle {
  gap: 0.2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.78);
  padding: 0.2rem;
}

.language-toggle button {
  border: 0;
  border-radius: calc(var(--radius) - 2px);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 850;
  padding: 0.34rem 0.52rem;
}

.language-toggle button[aria-pressed="true"] {
  background: var(--ink);
  color: white;
}

.intro-card {
  display: grid;
  grid-template-columns: 12rem minmax(0, 1fr);
  gap: clamp(1.2rem, 4vw, 2.5rem);
  align-items: start;
  margin-bottom: 1rem;
}

.avatar-frame {
  display: grid;
  width: clamp(8.5rem, 18vw, 11.5rem);
  aspect-ratio: 1;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface);
  box-shadow: var(--shadow);
  margin-top: clamp(2.2rem, 5vw, 3.5rem);
}

.avatar-column {
  display: grid;
  justify-items: center;
  gap: 0.65rem;
}

.avatar-frame picture,
.avatar-frame img {
  width: 100%;
  height: 100%;
}

.avatar-frame picture {
  display: block;
}

.avatar-frame img {
  object-fit: cover;
  object-position: center 18%;
  transform: scale(0.94);
  transform-origin: center top;
}

.profile-socials {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.62rem;
}

.brand-social {
  display: grid;
  width: 1.5rem;
  aspect-ratio: 1;
  place-items: center;
  text-decoration: none;
}

.brand-social svg {
  width: 1.32rem;
  height: 1.32rem;
  fill: currentColor;
}

.github-social {
  color: #181717;
}

.linkedin-social {
  border-radius: 4px;
  background: #0a66c2;
  color: white;
}

.linkedin-social svg {
  width: 0.94rem;
  height: 0.94rem;
}

.f6s-social {
  display: grid;
  place-items: center;
  line-height: 0;
}

.f6s-social img {
  width: auto;
  height: 1.32rem;
}

.profile-email {
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 850;
  overflow-wrap: anywhere;
  text-align: center;
  text-decoration-thickness: 0.07em;
}

.intro-copy {
  display: grid;
  gap: 0.8rem;
}

.eyebrow {
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  line-height: 1.08;
  letter-spacing: 0;
  text-wrap: balance;
}

h1 {
  max-width: 20ch;
  font-size: clamp(2rem, 4.4vw, 3.65rem);
}

h2 {
  font-size: clamp(1.35rem, 2.5vw, 2rem);
}

h3 {
  font-size: 1.02rem;
}

.lede,
.panel p,
.panel li {
  color: var(--muted);
}

.lede {
  max-width: 58rem;
  font-size: clamp(1rem, 1.7vw, 1.12rem);
}

.action-row {
  flex-wrap: wrap;
  gap: 0.45rem;
}

.button {
  display: inline-flex;
  min-height: 2.5rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 0.62rem 0.85rem;
  font-weight: 850;
  text-decoration: none;
}

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

.button.secondary {
  background: var(--surface);
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  align-items: start;
  gap: 0.75rem;
  margin-top: clamp(1rem, 4vw, 2rem);
}

.panel {
  display: grid;
  align-content: start;
  gap: 0.65rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  padding: clamp(0.9rem, 2vw, 1.15rem);
  box-shadow: 0 8px 28px rgba(17, 20, 18, 0.035);
}

.span-2 {
  grid-column: span 3;
}

.span-full {
  grid-column: 1 / -1;
}

.panel:not(.span-2) {
  grid-column: span 3;
}

.project-section {
  display: grid;
  gap: 0.75rem;
  margin-block: 0.15rem;
}

.section-heading {
  display: grid;
  gap: 0.4rem;
  max-width: 42rem;
}

.section-heading h2 {
  font-size: clamp(1.25rem, 2.2vw, 1.75rem);
}

.project-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.project-card {
  display: grid;
  align-content: start;
  gap: 0.45rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  padding: 0.85rem;
  box-shadow: 0 8px 28px rgba(17, 20, 18, 0.035);
}

.project-tag {
  color: var(--accent);
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.project-card h3 {
  font-size: 1rem;
}

.project-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.55rem;
  align-items: start;
}

.project-links {
  display: flex;
  gap: 0.25rem;
}

.icon-link {
  display: grid;
  width: 1.65rem;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) - 2px);
  background: color-mix(in srgb, var(--surface), var(--surface-soft) 36%);
  color: var(--ink);
  text-decoration: none;
}

.icon-link:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.icon-link svg {
  width: 1rem;
  height: 1rem;
  fill: currentColor;
}

.project-card h3 a {
  text-decoration: none;
}

.project-card h3 a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.project-card p:not(.project-tag) {
  color: var(--muted);
  font-size: 0.92rem;
}

.employment-section {
  display: grid;
  gap: 0.75rem;
  margin-block: 0.15rem;
}

.employment-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.employment-card {
  display: grid;
  align-content: start;
  gap: 0.55rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  padding: 0.85rem;
  box-shadow: 0 8px 28px rgba(17, 20, 18, 0.035);
}

.employment-card h3 {
  font-size: 0.96rem;
}

.employment-meta {
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 850;
  line-height: 1.35;
}

.experience-story,
.experience-points {
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.46;
}

.experience-points {
  display: grid;
  gap: 0.42rem;
  margin: 0;
  padding-left: 1rem;
}

.experience-points li::marker {
  color: var(--accent);
}

.work-section {
  display: grid;
  gap: 0.75rem;
  margin-block: 0.15rem;
}

.work-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.work-card {
  display: grid;
  align-content: start;
  gap: 0.55rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  padding: 0.85rem;
  box-shadow: 0 8px 28px rgba(17, 20, 18, 0.035);
}

.work-card h3 {
  font-size: 1rem;
}

.work-card p {
  color: var(--muted);
  font-size: 0.92rem;
}

.profile-footer {
  margin-top: 1rem;
  border-top: 1px solid var(--line);
  padding-top: 1rem;
  color: var(--muted);
  font-size: 0.88rem;
}

@media (max-width: 820px) {
  .intro-card {
    grid-template-columns: 1fr;
  }

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

  .span-2,
  .span-full,
  .panel:not(.span-2) {
    grid-column: auto;
  }

  .project-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .employment-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .work-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .profile-shell {
    width: min(calc(100% - 1rem), var(--max));
  }

  .profile-header {
    align-items: flex-start;
  }

  .intro-card {
    gap: 1rem;
  }

  h1 {
    max-width: 100%;
    font-size: clamp(2rem, 10vw, 3rem);
  }

  .avatar-frame {
    width: 8.75rem;
    margin-top: 0;
  }

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

  .button {
    width: 100%;
  }

  .content-grid,
  .span-2 {
    grid-column: auto;
    grid-template-columns: 1fr;
  }

  .project-list {
    grid-template-columns: 1fr;
  }

  .employment-list {
    grid-template-columns: 1fr;
  }

  .work-list {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
  }
}
