/* A self-contained, static project journal. No framework or external fonts. */
:root {
  color-scheme: light;
  --background: #f7f9f4;
  --paper: #ffffff;
  --ink: #243b33;
  --body: #5d7066;
  --muted: #8b9a8e;
  --green: #277e6a;
  --green-dark: #1b6655;
  --green-pale: #e6f0e8;
  --line: #dfe8de;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", "Noto Sans SC Variable", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 28px; }
body { margin: 0; background: var(--background); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }
img, svg { display: block; }
[hidden] { display: none !important; }
::selection { color: #173d32; background: #cfe9d7; }
:focus-visible { outline: 3px solid #278a73; outline-offset: 4px; }

.site-shell { width: min(100% - 104px, 1300px); margin: 0 auto; }
.skip-link { position: fixed; z-index: 100; top: 10px; left: 10px; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; background: var(--ink); color: white; border-radius: 7px; }
.skip-link:focus { width: auto; height: auto; margin: 0; padding: 10px 15px; overflow: visible; clip-path: none; }
.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; }

/* Header */
.site-header { height: 93px; display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-mark { display: grid; place-items: center; width: 39px; height: 39px; color: #f4faf2; background: var(--green); border-radius: 12px; }
.brand-mark svg { width: 22px; height: 22px; }
.brand-copy { display: flex; flex-direction: column; gap: 2px; line-height: 1; }
.brand-copy strong { font-size: 19px; font-weight: 800; letter-spacing: -.055em; }
.brand-copy strong span { color: var(--green); }
.brand-copy small { color: #607264; font: 700 8px/1 var(--mono); letter-spacing: .13em; }
.main-nav { display: flex; align-items: center; gap: 42px; margin-left: auto; }
.main-nav a { color: #607264; font-size: 13px; font-weight: 600; transition: color .2s ease; }
.main-nav a:hover { color: var(--green); }
.header-github { display: inline-flex; align-items: center; gap: 8px; margin-left: 45px; padding: 10px 13px; border: 1px solid #d4e0d5; border-radius: 9px; background: rgba(255,255,255,.62); color: #40574b; font-size: 12px; font-weight: 700; transition: background .2s ease, border-color .2s ease; }
.header-github:hover { background: #fff; border-color: #a4c1ad; }
.github-icon { width: 16px; height: 16px; }
.external-arrow { margin-left: 3px; font-size: 14px; }

/* Introduction */
.hero { display: grid; grid-template-columns: minmax(0, 1.03fr) minmax(0, .9fr); gap: clamp(45px, 6.2vw, 100px); align-items: center; padding: 52px 0; }
.hero-copy { padding: 8px 0 0; }
.eyebrow, .section-kicker, .cover-caption, .hero-signature, .hero-figure figcaption, .section-divider, .project-total span, .about-annotation, .footer-bottom, .footer-brand small { font-family: var(--mono); font-weight: 700; letter-spacing: .1em; }
.eyebrow { display: flex; align-items: center; gap: 11px; color: #607264; font-size: 10px; line-height: 1.5; }
.eyebrow-line { display: block; width: 28px; height: 1px; background: #77a592; }
.hero h1 { margin: 25px 0 20px; color: #243e34; font-size: clamp(42px, 4.7vw, 67px); font-weight: 760; letter-spacing: -.06em; line-height: 1.25; }
.hero h1 span { color: var(--green); }
.hero h1 b { color: #9bbb91; font-weight: inherit; }
.hero-description { max-width: 445px; margin: 0; color: var(--body); font-size: 15px; line-height: 2; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 31px; }
.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 28px; padding: 0 19px; border-radius: 9px; font-size: 13px; font-weight: 700; transition: transform .2s ease, background .2s ease, color .2s ease; }
.button:hover { transform: translateY(-2px); }
.button-primary { min-width: 140px; color: #fff; background: var(--green); box-shadow: 0 7px 18px rgba(47, 113, 90, .13); }
.button-primary:hover { background: var(--green-dark); }
.button-primary span, .button-text span { font-size: 16px; line-height: 1; }
.button-text { gap: 12px; color: #567264; }
.button-text:hover { color: var(--green); }
.hero-signature { display: flex; align-items: center; gap: 10px; margin-top: 40px; color: #607264; font-size: 9px; line-height: 1.5; }
.hero-signature span { color: #80a791; font-size: 18px; }
.hero-figure { min-width: 0; margin: 0; }
.hero-image-wrap { overflow: hidden; border: 1px solid #e6ece1; border-radius: 17px; background: #eef1e7; }
.hero-image { width: 100%; height: auto; aspect-ratio: 1.4; object-fit: cover; }
.hero-figure figcaption { display: flex; justify-content: space-between; gap: 15px; padding: 13px 2px 0; color: #607264; font-size: 8px; line-height: 1.5; }
.section-divider { display: flex; align-items: center; gap: 12px; color: #607264; font-size: 9px; white-space: nowrap; }
.section-divider > span:first-child { color: #6f9d83; font-size: 17px; }
.divider-line { width: 100%; height: 1px; background: var(--line); }

/* Project collection */
.projects-section { padding: 72px 0 105px; }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; }
.section-kicker { margin: 0 0 14px; color: #587061; font-size: 10px; }
.section-kicker span { color: #276f5d; }
.section-heading h2, .about-intro h2 { margin: 0; color: #253e33; font-size: clamp(31px, 3vw, 43px); font-weight: 750; line-height: 1.3; letter-spacing: -.045em; }
.heading-dot { color: #62a681; }
.section-description { max-width: 580px; margin: 11px 0 0; color: var(--body); font-size: 13px; line-height: 1.8; }
.project-total { display: flex; align-items: center; gap: 11px; padding-bottom: 3px; color: #607264; }
.project-total strong { color: #75937e; font-size: 39px; line-height: 1; font-weight: 400; letter-spacing: -.08em; }
.project-total span { font-size: 8px; line-height: 1.6; white-space: nowrap; }
.project-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin: 31px 0 20px; }
.filter-group { display: flex; flex-wrap: wrap; gap: 6px; }
.filter-button { min-height: 36px; padding: 0 15px; border: 1px solid transparent; border-radius: 8px; background: transparent; color: #61776a; font-size: 12px; font-weight: 650; transition: background .2s ease, color .2s ease, border-color .2s ease; }
.filter-button:hover { color: var(--green); background: #edf4eb; }
.filter-button.is-active { border-color: #deebe0; background: #e7f0e7; color: var(--green-dark); }
.toolbar-right { display: flex; align-items: center; gap: 14px; }
.search-box { display: flex; align-items: center; gap: 8px; width: 170px; height: 38px; padding: 0 11px; border: 1px solid #e0e9df; border-radius: 8px; background: #fff; color: #91a398; }
.search-box:focus-within { border-color: #76aa8d; box-shadow: 0 0 0 3px #dfeee1; }
.search-box svg { width: 16px; height: 16px; flex: 0 0 auto; }
.search-box input { width: 100%; min-width: 0; padding: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 12px; }
.search-box input::placeholder { color: #718779; }
.visible-count { min-width: 50px; color: #607264; font-size: 11px; white-space: nowrap; text-align: right; }
.project-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.project-card { min-width: 0; border: 1px solid #e1e9df; border-radius: 14px; background: var(--paper); box-shadow: 0 4px 20px rgba(43, 77, 53, .035); transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease; }
.project-card:hover, .project-card:focus-within { transform: translateY(-4px); border-color: #c6dccb; box-shadow: 0 14px 32px rgba(51, 91, 62, .09); }
.project-link { display: flex; flex-direction: column; height: 100%; border-radius: inherit; }
.project-cover { position: relative; overflow: hidden; height: 177px; margin: 9px 9px 0; border-radius: 9px; }
.cover-data { background: #e8f2e9; }
.cover-api { background: #edf2e9; }
.cover-radio { background: #e5f0e9; }
.cover-markdown { background: #eff3e9; }
.cover-gallery { background: #edf1e8; }
.cover-learn { background: #e7f1e9; }
.cover-caption { position: absolute; top: 13px; right: 14px; left: 14px; display: flex; justify-content: space-between; color: #587061; font-size: 8px; }
.cover-caption span:last-child { font-size: 14px; line-height: .7; }
.project-cover > svg { position: absolute; right: 0; bottom: 0; left: 0; width: 100%; height: 143px; transition: transform .3s ease; }
.project-card:hover .project-cover > svg { transform: translateY(-3px); }
.project-body { display: flex; flex: 1; flex-direction: column; min-height: 190px; padding: 21px 21px 0; }
.project-meta { display: flex; align-items: center; gap: 8px; color: #61776a; font-size: 10px; font-weight: 650; }
.project-meta > span:last-child { padding-left: 9px; border-left: 1px solid #e1e9e1; }
.language { display: inline-flex; align-items: center; gap: 6px; color: #61776a; }
.language-dot { width: 7px; height: 7px; border-radius: 50%; background: #74aa8e; }
.dot-java { background: #bd9074; }
.dot-js { background: #d1bb68; }
.dot-vue { background: #57ac83; }
.dot-css { background: #7ba2b1; }
.project-body h3 { margin: 12px 0 8px; color: #2c4438; font-size: 17px; font-weight: 750; letter-spacing: -.025em; line-height: 1.35; overflow-wrap: anywhere; }
.project-body p { margin: 0; color: var(--body); font-size: 12.5px; line-height: 1.8; }
.project-footer { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: auto; padding: 15px 0 16px; border-top: 1px solid #edf2eb; color: #587061; font-size: 11px; font-weight: 700; }
.project-footer span:last-child { font-size: 16px; line-height: 1; transition: transform .2s ease; }
.project-card:hover .project-footer span:last-child { transform: translate(2px, -2px); }
.empty-results { margin: 0; padding: 55px 20px; border: 1px dashed #d2e1d3; border-radius: 12px; color: #829587; background: #fff; font-size: 14px; text-align: center; }
.projects-bottom { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding-top: 25px; }
.projects-bottom p { margin: 0; color: #607264; font-size: 12px; }
.projects-bottom p span { margin-left: 5px; color: #82aa90; }
.projects-bottom a, .about-copy a { color: var(--green); font-size: 12px; font-weight: 750; }
.projects-bottom a span, .about-copy a span { margin-left: 8px; font-size: 15px; }
.about-copy a { color: #276f5d; }
.projects-bottom a:hover, .about-copy a:hover { color: var(--green-dark); text-decoration: underline; text-underline-offset: 4px; }

/* About and footer */
.about-section { position: relative; display: grid; grid-template-columns: 1.1fr .8fr; gap: 80px; align-items: center; overflow: hidden; padding: 65px 67px 72px; border: 1px solid #e0ebde; border-radius: 16px; background: #edf4e9; }
.about-intro h2 { font-size: clamp(29px, 3vw, 40px); line-height: 1.45; }
.about-intro h2 span { color: #5a987a; }
.about-copy { max-width: 390px; }
.about-spark { color: #78a78a; font-size: 24px; }
.about-copy p { margin: 13px 0 19px; color: var(--body); font-size: 13px; line-height: 2; }
.about-annotation { position: absolute; right: 19px; bottom: 17px; display: flex; align-items: center; gap: 7px; color: #587061; font-size: 8px; }
.about-annotation span:nth-child(2) { font-size: 12px; }
.site-footer { position: relative; padding: 64px 0 25px; }
.footer-brand { display: flex; align-items: center; gap: 7px; font-size: 19px; font-weight: 800; letter-spacing: -.05em; }
.footer-brand > span:first-child { color: var(--green); font-size: 21px; }
.footer-dot { margin-left: -7px; color: var(--green); }
.footer-brand small { margin-left: 8px; color: #607264; font-size: 8px; letter-spacing: .1em; }
.site-footer > p { margin: 10px 0 39px; color: #607264; font-size: 12px; }
.back-to-top { position: absolute; top: 70px; right: 0; color: #607264; font-size: 12px; font-weight: 700; }
.back-to-top:hover { color: var(--green); }
.footer-bottom { display: flex; justify-content: space-between; gap: 20px; padding-top: 19px; border-top: 1px solid var(--line); color: #607264; font-size: 8px; line-height: 1.5; }

@media (max-width: 1050px) {
  .site-shell { width: min(100% - 72px, 1300px); }
  .hero { gap: 42px; }
  .hero h1 { font-size: clamp(38px, 5vw, 55px); }
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-section { gap: 45px; padding-right: 45px; padding-left: 45px; }
}
@media (max-width: 720px) {
  .site-shell { width: calc(100% - 40px); }
  .site-header { height: 76px; }
  .main-nav { gap: 22px; }
  .header-github { margin-left: 22px; }
  .hero { grid-template-columns: 1fr; gap: 30px; padding: 55px 0 48px; }
  .hero-copy { padding: 0; }
  .hero h1 { margin-top: 19px; font-size: clamp(38px, 8vw, 52px); }
  .hero-description { font-size: 14px; }
  .hero-signature { margin-top: 32px; }
  .hero-image { max-height: 320px; aspect-ratio: 1.5; object-position: center 52%; }
  .projects-section { padding: 70px 0 75px; }
  .project-toolbar { flex-wrap: wrap; gap: 14px; }
  .toolbar-right { flex: 1 1 100%; }
  .search-box { flex: 1; width: auto; }
  .about-section { gap: 28px; padding: 40px 32px 65px; }
}
@media (max-width: 520px) {
  .site-shell { width: calc(100% - 36px); }
  .main-nav { display: none; }
  .header-github { margin-left: auto; }
  .hero { padding-top: 45px; }
  .hero h1 { font-size: clamp(36px, 9.1vw, 47px); }
  .hero-description { max-width: 330px; }
  .hero-actions { margin-top: 24px; }
  .hero-figure figcaption { font-size: 7px; }
  .section-divider { gap: 8px; font-size: 8px; }
  .section-divider > span:last-child { display: none; }
  .section-heading { align-items: start; }
  .section-description { max-width: 270px; }
  .project-total { padding-top: 19px; }
  .project-total strong { font-size: 32px; }
  .project-total span { font-size: 7px; }
  .project-grid { grid-template-columns: 1fr; gap: 14px; }
  .project-cover { height: 185px; }
  .project-cover > svg { height: 150px; }
  .project-body { min-height: 178px; }
  .filter-button { padding: 0 11px; }
  .projects-bottom { align-items: start; flex-direction: column; gap: 12px; }
  .about-section { grid-template-columns: 1fr; gap: 21px; padding: 35px 27px 66px; }
  .about-copy p { margin-top: 8px; }
  .site-footer { padding-top: 52px; }
  .back-to-top { top: 58px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
