/* ============================================
   ABOUT V2 — restrained neo-brutalism
   Loaded after about.css. Same language as home-v2:
   one bordered grid, colour only on small labels.
   ============================================ */

/* ---------- Hero ---------- */
.about-hero {
  display: flex;
  align-items: center;
  gap: 40px;
}

.about-hero-avatar {
  flex-shrink: 0;
  width: 160px;
  height: 160px;
  border: var(--border-width) solid #2B2B2B;
  border-radius: 50%;
  background: var(--label-yellow);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.about-hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-hero-text .handnote {
  display: inline-block;
  transform: rotate(-3deg);
  margin-bottom: 4px;
}

/* ---------- Bordered content grid ---------- */
.about-grid {
  gap: 0;
  background: #fff;
  border: var(--border-width) solid #2B2B2B;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.about-col {
  display: flex;
  flex-direction: column;
}

.about-col:first-child {
  border-right: var(--border-width) solid #2B2B2B;
}

.about-col > .about-block,
.about-col > .frame {
  margin: 0;
  padding: 36px;
  border-bottom: var(--border-width) solid #2B2B2B;
}

.about-col > :last-child {
  border-bottom: none;
  flex: 1;
}

/* Frames lose their own box inside the grid */
.about-grid .frame {
  border-top: none;
  border-left: none;
  border-right: none;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
}

.about-grid .frame-header {
  padding: 0;
  margin-bottom: 24px;
  border-bottom: none;
  background: transparent;
}

.about-grid .frame-body {
  padding: 0;
}

/* Section titles → small coloured pills (same as home PROJECT 01 labels) */
.about-block-title,
.about-grid .frame-label {
  display: inline-block;
  padding: 4px 10px;
  margin-bottom: 24px;
  border: 2px solid #2B2B2B;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #2B2B2B;
}

.about-grid .frame-label { margin-bottom: 0; }
.about-grid .frame-label::before { display: none; }

.about-col:first-child .about-block:nth-child(1) .about-block-title { background: var(--label-green); }
.about-col:first-child .about-block:nth-child(2) .about-block-title { background: var(--label-orange); }
.about-col:last-child .frame:nth-child(1) .frame-label { background: var(--label-cyan); }
.about-col:last-child .frame:nth-child(2) .frame-label { background: var(--label-yellow); }
.about-col:first-child .about-block:nth-child(3) .about-block-title { background: var(--label-pink); }

.about-grid .frame-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

/* Experience list: lighter rows, no outer box */
.about-grid .layer-list {
  border: none;
  border-top: 1.5px solid #2B2B2B;
}

.about-grid .layer-item {
  padding: 14px 0;
  background: transparent;
  font-size: 14px;
}

.about-grid .layer-icon {
  background: #fff;
  border-radius: 4px;
}

.about-grid .layer-item:hover .layer-icon { background: var(--selection-blue); }

/* Skills: outlined pills instead of colour blocks */
.about-grid .skill-block {
  background: #fff;
  color: #2B2B2B;
  border: 1.5px solid #2B2B2B;
  border-radius: 999px;
  box-shadow: none;
  padding: 6px 14px;
  font-size: 11px;
}

.about-grid .award-item:first-child { border-top: 1.5px solid #2B2B2B; }

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .about-hero {
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
  }

  .about-hero-avatar { width: 112px; height: 112px; }

  .about-col:first-child {
    border-right: none;
    border-bottom: var(--border-width) solid #2B2B2B;
  }

  .about-col > .about-block,
  .about-col > .frame { padding: 24px; }
}

/* ---------- Resume-synced content ---------- */
.layer-role {
  margin-left: 8px;
  font-size: 12px;
  color: var(--ink-muted);
}

.skill-group + .skill-group { margin-top: 20px; }

.skill-group-name {
  display: block;
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.about-grid .skills-wrap { gap: 8px; }

.education-item + .education-item {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1.5px solid #2B2B2B;
}

/* ---------- Off the screen (hobbies) ---------- */
.about-offscreen { padding-top: 64px; }

.offscreen-head .handnote { display: inline-block; transform: rotate(-3deg); }
.offscreen-head h2 {
  margin-top: 6px;
  margin-bottom: 28px;
  font-size: clamp(26px, 3.4vw, 36px);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.hobby-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.hobby-card {
  background: #fff;
  border: var(--border-width) solid #2B2B2B;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.hobby-media {
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: var(--border-width) solid #2B2B2B;
  background-color: #F7F7F4;
  background-image: radial-gradient(circle, #D8D8D2 1px, transparent 1px);
  background-size: 16px 16px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-muted);
}

.hobby-media img { width: 100%; height: 100%; object-fit: cover; }
.hobby-card h3 { margin: 16px 20px 4px; font-size: 18px; font-weight: 600; }
.hobby-card p { margin: 0 20px 20px; font-size: 14px; color: var(--ink-light); line-height: 1.55; }

.about-offscreen .draft-note {
  margin-top: 24px;
  padding: 16px 18px;
  background: #FFF7D6;
  border: 2px dashed #B8860B;
  border-radius: 12px;
}
.about-offscreen .draft-note-label { display: inline-block; margin-bottom: 6px; font-family: var(--font-mono); font-size: 11px; font-weight: 700; color: #8A6500; }
.about-offscreen .draft-note p { margin: 0; font-size: 14px; color: #5C4400; }
body.hide-drafts .draft-note { display: none; }

@media (max-width: 768px) { .hobby-grid { grid-template-columns: 1fr; } }

/* About hero (2026-11-17): text on the left, avatar on the right — same layout as the home hero.
   Phones: avatar above the text. */
.about-hero-avatar { order: 2; margin-left: auto; width: 200px; height: 200px; }
.about-hero-text { order: 1; }
@media (max-width: 768px) {
  .about-hero { flex-direction: column; align-items: flex-start; }
  .about-hero-avatar { order: 0; margin-left: 0; width: 140px; height: 140px; }
}
/* Tighter gap between the About hero and the first content box */
.about-hero { padding-bottom: 24px; }
.about-hero + .section { padding-top: 40px; }

/* About avatar as a die-cut sticker (2026-11-17): no circle. A white edge, a thin black
   edge and the hard shadow follow the image's own outline (drop-shadow uses the alpha).
   A cut-out photo becomes a die-cut sticker; a square photo becomes a square sticker —
   just replace the image file. */
.about-hero-avatar {
  width: 220px;
  height: auto;
  border: none;
  border-radius: 0;
  background: none;
  box-shadow: none;
  overflow: visible;
  transform: rotate(-4deg);
}
.about-hero-avatar img {
  display: block;
  width: 100%;
  height: auto;
  filter:
    drop-shadow(4px 0 0 #fff) drop-shadow(-4px 0 0 #fff) drop-shadow(0 4px 0 #fff) drop-shadow(0 -4px 0 #fff)
    drop-shadow(2px 0 0 #2B2B2B) drop-shadow(-2px 0 0 #2B2B2B) drop-shadow(0 2px 0 #2B2B2B) drop-shadow(0 -2px 0 #2B2B2B)
    drop-shadow(6px 6px 0 #2B2B2B);
}
@media (max-width: 768px) {
  .about-hero-avatar { width: 160px; height: auto; }
}

/* About v3 (2026-11-17): open layout — no outer box and no grid lines. Two columns,
   each block led by its coloured label, blocks separated by space. */
.about-grid {
  background: none;
  border: none;
  border-radius: 0;
  box-shadow: none;
  overflow: visible;
  column-gap: 72px;
}
.about-col:first-child { border-right: none; }
.about-col > .about-block,
.about-col > .frame {
  padding: 0 0 56px;
  border-bottom: none;
  background: none;
}
.about-col > .about-block:last-child,
.about-col > .frame:last-child { padding-bottom: 0; }
@media (max-width: 900px) {
  .about-grid { row-gap: 56px; }
  .about-col:first-child { border-bottom: none; }
  .about-col > .about-block,
  .about-col > .frame { padding: 0 0 48px; }
}

/* About v4 (2026-11-18): same reading pattern as the case studies — one section per row,
   title on the left (260px, sticky), content on the right, a rule between sections.
   The two .about-col wrappers dissolve (display: contents), so the order is:
   About me, Experience, Education, Skills, Awards. */
.about-grid { display: block; }
.about-col { display: contents; }

.about-grid .about-block,
.about-grid .frame {
  display: grid;
  grid-template-columns: minmax(0, 260px) minmax(0, 1fr);
  column-gap: 64px;
  align-items: start;
  padding: 48px 0;
  border-top: var(--border-width) solid #2B2B2B;
}
.about-col:first-child > .about-block:first-child {
  border-top: none;
  padding-top: 0;
}
.about-grid .about-block > * { grid-column: 2; }
.about-grid .about-block > .about-block-title {
  grid-column: 1;
  grid-row: 1 / span 30;
  justify-self: start;
  align-self: start;
  position: sticky;
  top: calc(var(--nav-height) + 32px);
  margin: 0;
}
.about-grid .frame > .frame-header {
  grid-column: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  margin: 0;
  position: sticky;
  top: calc(var(--nav-height) + 32px);
}
.about-grid .frame > .frame-body { grid-column: 2; }
.about-grid .about-block p { max-width: 68ch; }

@media (max-width: 900px) {
  .about-grid .about-block,
  .about-grid .frame { grid-template-columns: 1fr; row-gap: 20px; padding: 36px 0; }
  .about-grid .about-block > *,
  .about-grid .about-block > .about-block-title,
  .about-grid .frame > .frame-header,
  .about-grid .frame > .frame-body { grid-column: 1; grid-row: auto; position: static; }
}
/* About v4 fixes: section titles sit at the top of their row; phones keep normal paragraph spacing */
.about-grid .frame > .frame-header,
.about-grid .about-block > .about-block-title { align-self: start; }
@media (max-width: 900px) {
  .about-grid .about-block,
  .about-grid .frame { row-gap: 0; }
  .about-grid .about-block > .about-block-title,
  .about-grid .frame > .frame-header { margin-bottom: 20px; }
}
/* .frame (style.css) clips its content; that made it the sticky container, pushing the
   Skills/Awards titles 120px down. Let it overflow so the titles stick to the page. */
.about-grid .frame { overflow: visible; }

/* About v5 (2026-11-18)
   1) Download resume: as wide as its text (grid items stretch by default)
   2) Lists (Experience, Education, Awards): a line only BETWEEN rows — none above the
      first row, none below the last — and the same padding on every row. */
.about-grid .about-block > .text-arrow-cta { justify-self: start; width: auto; }

.about-grid .layer-list { border: none; }
.about-grid .layer-list > * { border: none; }
.about-grid .layer-list > .layer-item,
.about-grid .layer-list > .experience-link { border-bottom: none; }
.about-grid .layer-list > * + * { border-top: 1.5px solid #2B2B2B; }
.about-grid .layer-item { padding: 14px 0; }
.about-grid .layer-list > :first-child .layer-item,
.about-grid .layer-list > .layer-item:first-child { padding-top: 0; }
.about-grid .layer-list > :last-child .layer-item,
.about-grid .layer-list > .layer-item:last-child { padding-bottom: 0; }

.about-grid .education-item,
.about-grid .education-item + .education-item {
  margin: 0;
  padding: 16px 0;
  border: none;
}
.about-grid .education-item + .education-item { border-top: 1.5px solid #2B2B2B; }
.about-grid .education-item:first-of-type { padding-top: 0; }
.about-grid .education-item:last-of-type { padding-bottom: 0; }
.about-grid .education-item h3 { margin: 0; }
.about-grid .education-item p { margin: 6px 0 0; }

.about-grid .award-item,
.about-grid .award-item:first-child,
.about-grid .award-item:last-of-type { border-top: none; border-bottom: none; }
.about-grid .award-item + .award-item { border-top: 1.5px solid #2B2B2B; }
.about-grid .award-item:first-of-type { padding-top: 0; }
.about-grid .award-item:last-of-type { padding-bottom: 0; }
/* Every About section keeps its bottom space (an old rule removed it from the last block of each former column) */
.about-grid .about-block,
.about-grid .frame,
.about-col > .about-block:last-child,
.about-col > .frame:last-child { padding-bottom: 48px; }
.about-col:last-child > .frame:last-child { padding-bottom: 0; }
@media (max-width: 900px) {
  .about-grid .about-block,
  .about-grid .frame,
  .about-col > .about-block:last-child,
  .about-col > .frame:last-child { padding-bottom: 36px; }
  .about-col:last-child > .frame:last-child { padding-bottom: 0; }
}
.about-grid .layer-list { margin-bottom: 0; }

/* About v6: same title-left / content-right look without a grid. The title floats into
   the block's left padding (negative margin) and is sticky, so it stays in view through
   the whole section without stretching any rows. */
.about-grid .about-block,
.about-grid .frame {
  display: flow-root;
  padding-left: calc(260px + 64px);
}
.about-grid .about-block > *,
.about-grid .frame > .frame-body { grid-column: auto; }
.about-grid .about-block > .about-block-title,
.about-grid .frame > .frame-header {
  float: left;
  grid-row: auto;
  margin-left: calc(-1 * (260px + 64px));
  position: sticky;
  top: calc(var(--nav-height) + 32px);
}
.about-grid .about-block > :nth-child(2) { margin-top: 0; }
@media (max-width: 900px) {
  .about-grid .about-block,
  .about-grid .frame { padding-left: 0; }
  .about-grid .about-block > .about-block-title,
  .about-grid .frame > .frame-header { float: none; margin-left: 0; position: static; display: inline-flex; margin-bottom: 20px; }
  .about-grid .frame > .frame-header { display: flex; }
}

/* Awards: three aligned columns — name | level | link. The link column is always there
   (empty if an award has no link), so every level lines up in the second column. */
.about-grid .award-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 160px 24px;
  align-items: baseline;
  column-gap: 16px;
}
.about-grid .award-level { text-align: left; }
.about-grid .award-link { grid-column: 3; justify-self: end; }

/* Off the screen (2026-11-18): square photos, 3 per row, sticker-like cards */
.hobby-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.hobby-media { aspect-ratio: 1 / 1; height: auto; padding: 0; background: #fff; overflow: hidden; }
.hobby-media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.hobby-card { transition: transform 0.2s ease, box-shadow 0.2s ease; }
.hobby-card:hover { animation: mk-wiggle 0.55s ease-out both; box-shadow: 7px 7px 0 #2B2B2B; }
@media (max-width: 900px) { .hobby-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; } }
@media (max-width: 560px) { .hobby-grid { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .hobby-card:hover { animation: none; } }

/* Hobbies v3: 10 small cards, 5 per row (2 on narrow screens) */
.hobby-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 20px; }
.hobby-card h3 { margin: 12px 14px 2px; font-size: 16px; }
.hobby-card p { margin: 0 14px 14px; font-size: 13px; line-height: 1.45; }
@media (max-width: 1000px) { .hobby-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; } }

/* Hobbies v4: 4 per row; when the last row has 2 cards, center them */
@media (min-width: 1001px) {
  .hobby-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 24px; }
  .hobby-card { grid-column: span 2; }
  .hobby-grid > .hobby-card:nth-child(4n+1):nth-last-child(2) { grid-column: 3 / span 2; }
  .hobby-grid > .hobby-card:nth-child(4n+1):nth-last-child(1) { grid-column: 4 / span 2; }
  .hobby-card h3 { margin: 14px 18px 2px; font-size: 17px; }
  .hobby-card p { margin: 0 18px 16px; font-size: 14px; }
}

/* Hobbies: colored hard shadows (folder palette); row 2 shifted by one so columns don't stripe */
.hobby-grid > .hobby-card:nth-child(8n+1) { box-shadow: 5px 5px 0 #F7BC00; }
.hobby-grid > .hobby-card:nth-child(8n+1):hover { box-shadow: 8px 8px 0 #F7BC00; }
.hobby-grid > .hobby-card:nth-child(8n+2) { box-shadow: 5px 5px 0 #0C8360; }
.hobby-grid > .hobby-card:nth-child(8n+2):hover { box-shadow: 8px 8px 0 #0C8360; }
.hobby-grid > .hobby-card:nth-child(8n+3) { box-shadow: 5px 5px 0 #2E6BFF; }
.hobby-grid > .hobby-card:nth-child(8n+3):hover { box-shadow: 8px 8px 0 #2E6BFF; }
.hobby-grid > .hobby-card:nth-child(8n+4) { box-shadow: 5px 5px 0 #D6336C; }
.hobby-grid > .hobby-card:nth-child(8n+4):hover { box-shadow: 8px 8px 0 #D6336C; }
.hobby-grid > .hobby-card:nth-child(8n+5) { box-shadow: 5px 5px 0 #0C8360; }
.hobby-grid > .hobby-card:nth-child(8n+5):hover { box-shadow: 8px 8px 0 #0C8360; }
.hobby-grid > .hobby-card:nth-child(8n+6) { box-shadow: 5px 5px 0 #2E6BFF; }
.hobby-grid > .hobby-card:nth-child(8n+6):hover { box-shadow: 8px 8px 0 #2E6BFF; }
.hobby-grid > .hobby-card:nth-child(8n+7) { box-shadow: 5px 5px 0 #D6336C; }
.hobby-grid > .hobby-card:nth-child(8n+7):hover { box-shadow: 8px 8px 0 #D6336C; }
.hobby-grid > .hobby-card:nth-child(8n+8) { box-shadow: 5px 5px 0 #F7BC00; }
.hobby-grid > .hobby-card:nth-child(8n+8):hover { box-shadow: 8px 8px 0 #F7BC00; }
