:root {
  --ink: #222b28;
  --paper: #f8f8f0;
  --accent: #2f806e;
  --mint: #dcebe1;
  --line: rgba(34, 43, 40, 0.14);
  --muted: #68716d;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Noto Sans SC", sans-serif;
  transition: background .25s, color .25s;
}
body.dark { --ink: #eef3ef; --paper: #1d2823; --mint: #355e4e; --line: rgba(238,243,239,.18); --muted: #b4bdb7; }
a { color: inherit; text-decoration: none; }

.site-header, footer { width: min(1100px, calc(100% - 48px)); margin: auto; display: flex; align-items: center; justify-content: space-between; }
.site-header { height: 88px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font: 600 18px/1 "Noto Serif SC", serif; letter-spacing: 1px; }.brand span, em, .section-index { color: var(--accent); }
.brand-avatar { width: 42px; height: 42px; flex: 0 0 42px; object-fit: cover; border: 2px solid var(--mint); border-radius: 50%; box-shadow: 0 2px 6px rgba(34, 43, 40, .16); }
nav { position: absolute; left: 50%; transform: translateX(-50%); display: flex; gap: 42px; font-size: 14px; font-weight: 600; }
nav a { position: relative; }
nav a::after { content: ""; position: absolute; right: 0; bottom: -5px; left: 0; height: 2px; background: var(--accent); transform: scaleX(0); transition: transform .2s; }
nav a:hover::after { transform: scaleX(1); }
.theme-toggle { cursor: pointer; border: 1px solid var(--line); border-radius: 99px; background: transparent; color: var(--ink); width: 42px; height: 31px; font-size: 16px; }

.section { width: min(1100px, calc(100% - 48px)); margin: auto; }
.hero { min-height: 700px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 30px; text-align: center; }
.eyebrow, .section-index { margin: 0 0 25px; font: 12px/1.3 "DM Mono", monospace; letter-spacing: .4px; }.eyebrow { color: var(--muted); }
h1, h2, h3, p { margin-top: 0; }
h1, h2 { font-family: "Noto Serif SC", serif; font-weight: 500; letter-spacing: -3px; line-height: 1.25; }
h1 { margin-bottom: 20px; font-size: clamp(43px, 5.4vw, 70px); }.hero h1 span { color: var(--accent); }
.hero-intro { max-width: 600px; color: var(--muted); font-size: 16px; line-height: 1.9; }
.hero-actions { display: flex; justify-content: center; align-items: center; gap: 28px; margin-top: 28px; }
.button { display: inline-flex; align-items: center; gap: 22px; padding: 14px 20px; font-size: 14px; font-weight: 700; transition: transform .2s, background .2s; }
.button:hover { transform: translateY(-3px); }.button span { font-size: 19px; line-height: .8; }
.button-primary { border-radius: 4px; background: var(--accent); color: white; }.text-link { border-bottom: 1px solid var(--ink); padding-bottom: 4px; font-weight: 700; font-size: 14px; }

.portrait-wrap { width: min(335px, 75vw); aspect-ratio: 1.04; position: relative; display: grid; place-items: center; }
.hero-illustration { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 12px 12px rgba(34, 43, 40, .16)); }
.orbit { position: absolute; border: 1px solid var(--ink); border-radius: 50%; opacity: .36; }.orbit-one { width: 95%; height: 57%; transform: rotate(-20deg); }.orbit-two { width: 60%; height: 94%; transform: rotate(40deg); }
.portrait-wrap p { position: absolute; right: 0; bottom: 8px; z-index: 2; margin: 0; color: var(--accent); font: 11px/1.5 "DM Mono", monospace; letter-spacing: .5px; }

.about { padding: 115px 0; border-top: 1px solid var(--line); }.about-content { display: grid; grid-template-columns: 1fr 1fr; gap: 90px; }
h2 { margin-bottom: 0; font-size: clamp(36px, 5vw, 59px); }.about h2 span { display: inline-block; padding: 0 5px; color: var(--accent); }
.about-content div { padding-top: 8px; color: var(--muted); font-size: 16px; line-height: 1.9; }.about-content p + p { margin-top: 17px; }
.skills { padding: 0 0 115px; }.skills-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.skill-card { min-height: 235px; padding: 29px; border: 1px solid var(--line); border-radius: 6px; background: rgba(255,255,255,.28); }.skill-number { color: var(--accent); font: 12px "DM Mono", monospace; }
h3 { margin: 44px 0 12px; font-size: 25px; letter-spacing: -1px; }.skill-card p { margin: 0; color: var(--muted); line-height: 1.7; font-size: 14px; }
.ip-gallery { padding: 0 0 115px; }.ip-gallery-heading { display: grid; grid-template-columns: 1fr 1fr; gap: 90px; margin-bottom: 36px; }.ip-gallery-heading p { margin-bottom: 0; }.ip-gallery-heading h2 { margin-bottom: 16px; }.ip-gallery-heading h2 span { color: var(--accent); }.ip-gallery-heading div > p { max-width: 410px; margin: 0; color: var(--muted); line-height: 1.8; }
.ip-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }.ip-card { min-height: 355px; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; padding: 28px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255,255,255,.32); }.ip-card:nth-child(2) { background: rgba(220,235,225,.62); }.ip-card:nth-child(3) { background: rgba(239,229,207,.5); }.ip-card:nth-child(4) { background: rgba(226,234,224,.55); }
.ip-card img { width: min(72%, 285px); max-height: 270px; object-fit: contain; filter: drop-shadow(0 10px 10px rgba(34, 43, 40, .12)); transition: transform .3s ease; }.ip-card:hover img { transform: scale(1.045) rotate(-1deg); }.ip-card > div { position: absolute; left: 25px; bottom: 22px; }.ip-card span { color: var(--accent); font: 11px "DM Mono", monospace; }.ip-card h3 { margin: 6px 0 3px; font-size: 20px; }.ip-card p { margin: 0; color: var(--muted); font-size: 13px; }
.contact { padding: 0 0 90px; }.contact-card { text-align: center; padding: clamp(38px, 6vw, 76px); border-radius: 6px; background: var(--mint); }.contact-card h2 { margin-bottom: 35px; }.button-light { border-radius: 4px; background: var(--paper); }
footer { min-height: 82px; border-top: 1px solid var(--line); color: var(--muted); font: 10px "DM Mono", monospace; letter-spacing: .5px; }
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }.reveal.visible { opacity: 1; transform: translateY(0); }

@media (max-width: 700px) {
  .site-header, footer, .section { width: min(100% - 32px, 1100px); }.site-header { height: 70px; }.brand { gap: 8px; font-size: 16px; }.brand-avatar { width: 36px; height: 36px; flex-basis: 36px; } nav { display: none; }
  .hero { min-height: auto; padding: 78px 0 88px; gap: 22px; }.portrait-wrap { width: min(260px, 72vw); margin-top: 4px; }.portrait-wrap p { right: -10px; }
  .about { padding: 75px 0; }.about-content { grid-template-columns: 1fr; gap: 30px; }.skills, .ip-gallery { padding-bottom: 75px; }.skills-grid, .ip-grid, .ip-gallery-heading { grid-template-columns: 1fr; }.ip-gallery-heading { gap: 20px; margin-bottom: 25px; }.ip-card { min-height: 300px; }.ip-card img { max-height: 235px; }.skill-card, .skill-card:first-child { min-height: auto; padding: 25px; } h3 { margin-top: 25px; } .ip-card h3 { margin-top: 6px; } footer { padding: 22px 0; align-items: flex-start; gap: 10px; flex-direction: column; }
}
