/* The entrance's own Latin pixels, paired with a complete Korean pixel font. */
@font-face {
  font-family: "Galmuri11";
  src: url("assets/fonts/Galmuri11.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  /* Match the 7-row Yebbi capitals without making Korean syllables oversized. */
  size-adjust: 80%;
}
@font-face {
  font-family: "Galmuri11";
  src: url("assets/fonts/Galmuri11-Bold.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  size-adjust: 80%;
}

body:not([data-view="landing"]) {
  --sans: "Yebbi Pixel", "Galmuri11", ui-monospace, monospace;
  --mono: var(--sans);
  font-family: var(--sans);
  font-size: 1.25rem;
  line-height: 1.8;
  letter-spacing: 0;
  font-synthesis: none;
  -webkit-font-smoothing: auto;
}

/* Earlier component styles still use --sans; keep their type on this same grid. */
body:not([data-view="landing"]) #portfolio,
body:not([data-view="landing"]) #portfolio :is(h1, h2, h3, h4, p, dl, dt, dd, li, span, small, a, button, input, textarea, select, summary, code, pre, kbd, samp) {
  font-family: var(--sans);
  font-weight: 400;
  letter-spacing: 0;
}

body:not([data-view="landing"]) .page-header nav a {
  font-size: 1.25rem;
  line-height: 1.5;
}
body:not([data-view="landing"]) .profile-copy h1,
body:not([data-view="landing"]) .about-profile .profile-copy h2 {
  font-size: 2.25rem;
  line-height: 1.35;
}
body:not([data-view="landing"]) .section-header h2,
body:not([data-view="landing"]) .about-page-header h1,
body:not([data-view="landing"]) .about-content > h1 {
  font-size: 1.875rem;
  line-height: 1.5;
}
body:not([data-view="landing"]) #work-list .project-card h3 {
  font-size: 1.5rem;
  line-height: 1.65;
  overflow-wrap: anywhere;
}

body:not([data-view="landing"]) #portfolio :is(p, dt, dd, li),
body:not([data-view="landing"]) #work-list .project-card .work-intro,
body:not([data-view="landing"]) #portfolio .profile-links .profile-link,
body:not([data-view="landing"]) #portfolio .award-title,
body:not([data-view="landing"]) #portfolio .note-title,
body:not([data-view="landing"]) #portfolio .about-research h2,
body:not([data-view="landing"]) #portfolio .work-detail h4 {
  font-size: 1.25rem;
  line-height: 1.8;
}
body:not([data-view="landing"]) #portfolio :is(.hacker-handle, .blog-link, .about-preview-link, .award-event, .award-year, .note-kind),
body:not([data-view="landing"]) #work-list .project-card .work-index > span,
body:not([data-view="landing"]) #work-list .project-card .work-tags span {
  font-size: 1.125rem;
  line-height: 1.8;
}
body:not([data-view="landing"]) #portfolio .note-kind {
  width: 8.75rem;
}
body:not([data-view="landing"]) #portfolio .note-content {
  padding-left: calc(8.75rem + 24px);
}
body:not([data-view="landing"]) #portfolio :is(.about-intro, .about-facts dd, .about-research p, .note-title, .profile-bio) {
  overflow-wrap: anywhere;
}
body:not([data-view="landing"]) #portfolio .profile-links {
  gap: 8px 24px;
}

@media (max-width: 800px) {
  body:not([data-view="landing"]) #portfolio .note-content { padding-left: 0; }
}

@media (max-width: 600px) {
  html:has(body:not([data-view="landing"])) { scroll-padding-top: 132px; }
  body:not([data-view="landing"]) #portfolio :is(.profile-section, .about-preview, .awards-section, .works-section, .notes-section) {
    scroll-margin-top: 0;
  }
  /* A full menu row keeps the wider pixel letters clear of the motion control. */
  body:not([data-view="landing"]) .page-header {
    height: auto;
    min-height: 112px;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    justify-items: start;
    gap: 8px;
    padding: 14px 22px 12px;
  }
  body:not([data-view="landing"]) .page-header .home-button { width: 28px; height: 28px; }
  body:not([data-view="landing"]) .page-header nav {
    width: 100%;
    justify-content: space-between;
    gap: 8px;
  }
  body:not([data-view="landing"]) .page-header nav a {
    font-size: 1.125rem;
    padding: 7px 0;
  }
  body:not([data-view="landing"]) .profile-copy h1,
  body:not([data-view="landing"]) .about-profile .profile-copy h2 { font-size: 2rem; }
  body:not([data-view="landing"]) .section-header h2,
  body:not([data-view="landing"]) .about-page-header h1,
  body:not([data-view="landing"]) .about-content > h1 { font-size: 1.875rem; }
  body:not([data-view="landing"]) #portfolio .profile-links {
    gap: 8px;
  }
  body:not([data-view="landing"]) #portfolio .profile-links .profile-link {
    flex-direction: column;
    gap: 7px;
    min-height: 68px;
    font-size: 1.125rem;
    line-height: 1.5;
    padding: 8px 0;
  }
  body:not([data-view="landing"]) #portfolio .note-entry summary {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 20px;
    gap: 6px 16px;
  }
  body:not([data-view="landing"]) #portfolio .note-kind { width: auto; }
  body:not([data-view="landing"]) #portfolio .note-title { min-width: 0; }
}
