:root {
  --color-bg: #161826;
  --color-surface: #232532;
  --color-text: #e9e9ed;
  --color-accent: #9184d9;
  --color-divider: color-mix(in srgb, var(--color-text) 16%, transparent);

  --color-neutral-100: #f3f5fe;
  --color-neutral-200: #e4e7f5;
  --color-neutral-300: #cfd3e5;
  --color-neutral-400: #b2b6ca;
  --color-neutral-500: #9397ab;
  --color-neutral-800: #3f424d;
  --color-accent-100: #f5f4ff;
  --color-accent-200: #e7e5fe;
  --color-accent-300: #d2cefd;
  --color-accent-800: #423a6a;

  --font-heading: "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-heading-weight: 500;

  --base-font-size: 112.5%; /** 18px */
  --font-xs: calc((2/3) * 1rem);
  --font-sm: calc((7/9) * 1rem);
  --font-md: 1rem;
  --font-lg: calc((11/9) * 1rem);
  --font-xl: calc((16/9) * 1rem);

  --layout-max-width: 1120px;
  --default-spacing: 28px;

  --radius-md: 8px;
  --shadow-sm: 0 0 0 1px #3f424d;
}

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

html {
  font-size: var(--base-font-size);
}

html,
body {
  height: 100%;
  margin: 0;
}

body {
  line-height: 1.55;
  font-weight: 400;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 4px;
}

p {
  margin: 0 0 12px;
}

a {
  color: var(--color-accent);
  text-underline-offset: 4px;
}

site-nav,
hero-section,
hero-image,
bio-section,
experience-section,
site-footer,
project-card {
  display: block;
}

site-nav {
  min-height: 72px;
}

hero-section {
  min-height: 420px;
}

bio-section,
experience-section {
  min-height: 280px;
}

site-footer {
  min-height: 220px;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.kicker {
  font-family: var(--font-body);
  font-size: var(--font-sm);
  line-height: 1.55;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-accent-300);
  font-weight: 500;
  margin: 0 0 16px;
}

.layout {
  display: flex;
  flex-direction: column;
}

/** layout-section */

.layout-section {
  margin: 0 auto;
  max-width: var(--layout-max-width);
  padding-left: clamp(20px, 4vw, 40px);
  padding-right: clamp(20px, 4vw, 40px);
}

.layout-section--hero {
  min-height: clamp(420px, 42vw, 560px);
  padding-top: clamp(50px, 8vw, 100px);
  padding-bottom: clamp(50px, 8vw, 100px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 52px;
}

.layout-section--bio {
  min-height: 340px;
  display: flex;
  align-items: flex-start;
  gap: 64px;
}

.layout-section--projects,
.layout-section--bio {
  padding-top: clamp(30px, 8vw, 60px);
  padding-bottom: clamp(30px, 8vw, 60px);
}


@media (width <= 767px) {
  .layout-section--hero {
    flex-direction: column-reverse;
    align-items: flex-start;
    gap: 32px;
  }

  .layout-section--bio {
    flex-direction: column;
    gap: 40px;
  }
}

.layout-section--hero > hero-section {
  flex: 1 1 640px;
  min-width: 0;
}

.layout-section--hero > hero-image {
  flex: 0 0 280px;
}

@media (width <= 767px) {
  .layout-section--hero > hero-section,
  .layout-section--hero > hero-image {
    width: 100%;
    flex: 1 1 auto;
  }
}

/** Bio Layout **/ 

.layout-section--bio > bio-section {
  flex: 1.1;
  min-width: 0;
}

.layout-section--bio > experience-section {
  flex: 0.9;
  min-width: 0;
}

@media (width <= 767px) {
  .layout-section--bio > bio-section,
  .layout-section--bio > experience-section {
    width: 100%;
  }
}

/** Projects Layout **/

.layout--project-cards {
  display: flex;
  flex-wrap: wrap;
  gap: var(--default-spacing);
}

.layout--project-cards > project-card {
  flex: 0 1 calc((100% - var(--default-spacing)) / 2);
  min-width: 300px;
}

@media (width <= 767px) {
  .layout--project-cards > project-card {
    flex: 1 1 100%;
    min-width: 0;
  }
}

.layout--footer {
  background: var(--color-surface);
  padding: 60px 0;
}

/** Style-Only Components */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  text-decoration: none;
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  font-size: var(--font-sm);
  line-height: 1.2;
  color: var(--color-text);
  background: transparent;
  border: 1px solid transparent;
  padding: 6px 10px;
  border-radius: var(--radius-md);
}

.btn-primary {
  color: var(--color-accent);
  border-color: var(--color-accent);
}

.btn-secondary {
  border-color: var(--color-divider);
}

.tag {
  display: inline-flex;
  align-items: center;
  font-size: var(--font-xs);
  letter-spacing: 0.02em;
  padding: 4px 12px;
  border-radius: calc(var(--radius-md) * 0.75);
}

.tag-accent {
  background: var(--color-accent-800);
  color: var(--color-accent-100);
}

.tag-neutral {
  background: var(--color-neutral-800);
  color: var(--color-neutral-100);
}

.tag-outline {
  border: 1px solid var(--color-accent);
  color: var(--color-accent);
}

/** Web Components */

.bio {
  width: 100%;
}

.bio--wrapper {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.bio--contents {
  font-size: var(--font-md);
  color: var(--color-neutral-200);
  max-width: 560px;
}

.bio--button-row {
  width: 100%;
}

.bio--button {
  display: flex;
  gap: 12px;
  margin-top: var(--default-spacing);
  flex-wrap: wrap;
}

.experience {
  width: 100%;
}

.experience--sidebar {
  display: flex;
  flex-direction: column;
  gap: var(--default-spacing);
}

.experience--heading {
  font-size: var(--font-md);
  color: var(--color-neutral-400);
  margin-bottom: 16px;
}

.experience-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.experience--job-title {
  display: flex;
  justify-content: space-between;
  font-size: var(--font-sm);
}

.experience--employer {
  font-size: var(--font-sm);
  color: var(--color-neutral-500);
}

.skills--heading {
  font-size: var(--font-md);
  color: var(--color-neutral-400);
  margin: var(--default-spacing) 0 0;
}

.skills--container {
  box-sizing: border-box;
  display: flex;
  flex-direction: row;
  gap: 20px;
  justify-content: flex-start;
  align-items: center;
  margin-bottom: 12px;
  margin-top: 8px;
}

.skills--key {
  box-sizing: border-box;
  display: flex;
  flex-direction: row;
  gap: 8px;
  justify-content: normal;
  align-items: center;
}

.skills--key-circle {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.skills--key-circle__is-core {
  background-color: rgb(65, 58, 106);
}

.skills--key-circle__is-secondary {
  background-color: rgb(63, 66, 77);
}

.skills--key-circle__is-studying {
  border-width: 1px;
  border-style: solid;
  border-color: rgb(145, 132, 217);
}

.skills--key-text {
  font-size: var(--font-sm);
  color: var(--color-neutral-400);
}

.skills--list {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.footer--header {
  /** ch = 19.5px */
  margin-bottom: var(--default-spacing);
  font-size: var(--font-xl);
  max-width: clamp(21ch, 66vw, 28ch);
  white-space: normal;
  overflow-wrap: normal;
  word-break: normal;
  text-wrap: pretty;
}

@media (width <= 520px) {
  .footer--header {
    font-size: clamp(24px, 6.8vw, 30px);
    max-width: 24ch;
  }
}

.footer--buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: flex-start;
  margin-bottom: 40px;
}

.footer--buttons__are-primary,
.footer--buttons__are-secondary {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: flex-start;
}

.footer--buttons__are-primary {
  white-space: nowrap;
  flex: 0 0 auto;
}

.footer--buttons__are-secondary {
  flex: 1 1 320px;
}

.footer--fade-rule {
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    var(--color-divider) 48px,
    var(--color-divider) calc(100% - 48px),
    transparent
  );
}

.hero {
  width: 100%;
}

.hero--name {
  font-size: clamp(34px, 9.2vw, 56px);
  max-width: 620px;
  line-height: 0.95;
  white-space: nowrap;
}

.hero--summary {
  font-size: var(--font-md);
  max-width: 520px;
  color: var(--color-neutral-200);
  margin-bottom: 32px;
}

.hero--headings-container {
  display: flex;
  gap: 32px;
  margin-bottom: 40px;
  flex-wrap: nowrap;
  align-items: center;
}

.hero--fact {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 44px;
  flex: 1 1 0;
  min-width: 0;
  max-width: none;
}

.hero--heading {
  font-family: var(--font-heading);
  font-size: var(--font-lg);
  color: var(--color-text);
  white-space: nowrap;
}

.u-phone-only {
  display: none;
}

.u-phone-hidden {
  display: inline;
}

.hero--subheading {
  font-size: var(--font-sm);
  color: var(--color-neutral-500);
  white-space: normal;
}

.hero--divider {
  width: 1px;
  height: 36px;
  background: var(--color-divider);
}

.hero--terminal {
  background: var(--color-surface);
  border-color: rgb(55, 37, 182);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: var(--font-sm);
  max-width: 420px;
  box-shadow: var(--shadow-sm);
}

.hero--terminal-text {
  color: var(--color-accent-300);
}

.hero--terminal-text__is_muted {
  color: var(--color-neutral-500);
}

.hero--terminal-text__is_strong {
  color: var(--color-accent);
  font-weight: 400;
}

.hero--terminal-text__is_offset {
  margin-bottom: 8px;
}

@media (width <= 900px) {
  .hero--bio {
    display: flex;
    flex-direction: column;
  }

  .hero--name {
    order: -1;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
  }

  .hero--headings-container {
    gap: 12px;
  }

  .hero--headings-container .hero--fact:last-of-type {
    align-items: flex-end;
    text-align: right;
  }

  .hero--heading {
    line-height: 1.15;
  }
}

@media (width <= 540px), (768px <= width <= 900px) {
  .u-phone-only {
    display: inline;
  }

  .u-phone-hidden {
    display: none;
  }
}

@media (width <= 767px) {
  .kicker--is-hidden-mobile {
    display: none;
  }
  .kicker--is-hidden-desktop {
    text-align: center;
  }
  .hero--summary {
    text-align: center;
    font-size: var(--font-md);
  }
}

@media (width >= 768px) {
  .kicker--is-hidden-desktop {
    display: none;
  }
}

.hero--image-section {
  flex: 0 0 280px;
}

.hero--photo-wrapper {
  display: flex;
  justify-content: flex-end;
}

.hero--photo {
  width: 220px;
  height: 220px;
  min-height: 220px;
  aspect-ratio: 1;
  border-width: 6px;
  border-style: solid;
  border-color: transparent;
  border-radius: 100%;
  outline: rgb(55, 37, 182) solid 2px;
  overflow: hidden;
}

.hero--photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (width <= 900px) {
  .hero--image-section {
    flex: 1 1 auto;
    width: 100%;
  }

  .hero--photo-wrapper {
    justify-content: center;
  }
}

/** inline styles */
.navigation {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: color-mix(in srgb, var(--color-bg) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: none;
}

.navigation--wrapper {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: var(--layout-max-width);
  margin: 0 auto;
  padding: 0;
}

.navigation--brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-right: auto;
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  font-size: var(--font-md);
  text-decoration: none;
  color: var(--color-text);
}

.navigation--link {
  color: inherit;
  text-decoration: none;
  font-size: var(--font-sm);
}

.navigation--link:hover,
.navigation--link[aria-current="page"] {
  color: var(--color-accent);
}

.navigation--logo {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--color-accent-800);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: var(--font-sm);
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--color-accent-200);
}

.navigation--buttons {
  display: flex;
  align-items: center;
  gap: var(--default-spacing);
  margin-left: var(--default-spacing);
}

.navigation--links {
  display: flex;
  align-items: center;
  gap: var(--default-spacing);
  margin-left: auto;
}

.navigation--button {
  margin-left: 4px;
}

@media (width <= 900px) {
  .navigation--links {
    display: none !important;
  }

  .navigation--buttons {
    margin-left: auto !important;
  }
}

.project-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-radius: var(--radius-md);
  background: var(--color-surface);
  box-shadow: var(--shadow-sm);
  padding: 0;
  overflow: hidden;
}

.project-card--image-frame {
  height: 200px;
  overflow: hidden;
}

.project-card--image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-card--tag {
  margin-top: 12px;
  flex-wrap: wrap;
}

.project-card--footer {
  display: flex;
  gap: 16px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--color-divider);
}

.project-card--container {
  padding: 20px;
}

.project-card--title {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  font-size: var(--font-md);
  line-height: 1.2;
  margin: 0;
}

.project-card--description {
  margin: 0;
  font-size: var(--font-sm);
  opacity: 0.8;
  flex: 1;
}

.project-card--skills {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}

.project-card--attribution {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.project-card--header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}
.project-card--footer-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--font-sm);
  color: var(--color-neutral-300);
  text-decoration: none;
}

.project-card--logo {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.project-card--logo-image {
  width: 80%;
  height: 80%;
}
.project-card--logo-text {
  font-size: var(--font-sm);
  color: var(--color-neutral-400);
}
