:root {
  color-scheme: light;
  --bg: #f5f8fc;
  --paper: #ffffff;
  --ink: #102033;
  --muted: #617083;
  --line: #d9e4f2;
  --blue: #0f5ea8;
  --blue-dark: #08365f;
  --blue-soft: #e7f1fb;
  --accent: #1b8fd6;
  --shadow: 0 18px 54px rgba(15, 58, 96, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(231, 241, 251, 0.85) 0%, rgba(245, 248, 252, 0) 360px),
    var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
}

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

a {
  color: var(--blue);
  text-decoration-color: rgba(15, 94, 168, 0.35);
  text-underline-offset: 0.18em;
}

a:hover,
a:focus-visible {
  color: var(--blue-dark);
  text-decoration-color: currentColor;
}

.page {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 48px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: end;
  padding: 32px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.15;
}

h1 {
  max-width: 11ch;
  font-size: 5.75rem;
  letter-spacing: 0;
}

.role {
  margin: 16px 0 0;
  color: var(--blue-dark);
  font-size: 1.7rem;
  font-weight: 700;
}

.summary {
  max-width: 720px;
  margin: 22px 0 0;
  color: #304156;
  font-size: 1.04rem;
}

.profile-card {
  width: min(100%, 300px);
  justify-self: end;
}

.profile-card img {
  width: 300px;
  height: 300px;
  margin-left: auto;
  border: 6px solid var(--blue-soft);
  border-radius: 50%;
  object-fit: cover;
}

.contact {
  display: grid;
  gap: 10px;
  margin-top: 24px;
  padding: 18px;
  background: var(--blue-soft);
  border-radius: 8px;
  color: var(--blue-dark);
  font-size: 0.95rem;
}

.contact span {
  color: var(--muted);
}

.quick-nav,
.social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.quick-nav a,
.social a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 13px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--blue-dark);
  font-weight: 700;
  text-decoration: none;
}

.quick-nav a:hover,
.quick-nav a:focus-visible,
.social a:hover,
.social a:focus-visible {
  border-color: var(--accent);
  color: var(--blue);
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  align-items: start;
  margin-top: 28px;
}

.main,
.side {
  display: grid;
  gap: 22px;
}

.section {
  padding: 28px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.section h2 {
  margin-bottom: 22px;
  color: var(--blue-dark);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.intro p,
.experience p,
.note p {
  margin: 0 0 12px;
}

.intro p:last-child,
.experience p:last-child,
.note p:last-child {
  margin-bottom: 0;
}

.experience {
  position: relative;
  display: grid;
  gap: 26px;
}

.job {
  display: grid;
  grid-template-columns: 168px minmax(0, 1fr);
  gap: 24px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
}

.job:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.job-meta {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.job-meta strong {
  display: block;
  color: var(--blue);
  font-size: 1rem;
}

.job h3 {
  margin-bottom: 8px;
  font-size: 1.18rem;
}

ul {
  margin: 10px 0 0;
  padding-left: 1.1rem;
}

li {
  margin-bottom: 8px;
}

li:last-child {
  margin-bottom: 0;
}

.side .section {
  padding: 24px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tag-list li {
  margin: 0;
  padding: 7px 10px;
  background: var(--blue-soft);
  border: 1px solid #c8def4;
  border-radius: 8px;
  color: var(--blue-dark);
  font-size: 0.92rem;
  font-weight: 700;
}

.plain-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.plain-list li + li {
  margin-top: 12px;
}

.plain-list strong {
  display: block;
  color: var(--ink);
}

.plain-list span {
  display: block;
}

.muted {
  color: var(--muted);
}

.footer {
  display: grid;
  gap: 18px;
  margin-top: 28px;
  padding: 28px;
  background: var(--blue-dark);
  border-radius: 8px;
  color: #dcecff;
}

.footer a {
  color: #ffffff;
  text-decoration-color: rgba(255, 255, 255, 0.45);
}

.footer .social a {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.footer small {
  color: #b7cee8;
}

.error-panel {
  min-height: calc(100vh - 80px);
  display: grid;
  place-items: center;
}

.error-panel .section {
  width: min(680px, 100%);
  box-shadow: var(--shadow);
}

@media (max-width: 900px) {
  .hero,
  .layout,
  .job {
    grid-template-columns: 1fr;
  }

  .hero {
    align-items: start;
  }

  .profile-card {
    width: 100%;
    justify-self: stretch;
  }

  .profile-card img {
    width: 200px;
    height: 200px;
    margin: auto;
  }

  .contact {
    max-width: 100%;
  }

  h1 {
    font-size: 4rem;
  }

  .role {
    font-size: 1.45rem;
  }
}

@media (max-width: 560px) {
  .page {
    width: min(100% - 20px, 1180px);
    padding-top: 10px;
  }

  .hero,
  .section,
  .side .section,
  .footer {
    padding: 20px;
  }

  h1 {
    font-size: 2.45rem;
  }

  .role {
    font-size: 1.2rem;
  }

  .quick-nav a,
  .social a {
    width: 100%;
    justify-content: center;
  }
}
