:root {
--bg: #f9f9f6;
--surface: #ffffff;
--surface-2: #f4f4f1;
--surface-3: #eeeeeb;
--ink: #1a1c1b;
--muted: #444748;
--subtle: #848484;
--line: rgba(196, 199, 199, 0.3);
--line-2: rgba(196, 199, 199, 0.4);
--blue: #294dd6;
--term: #1c1b1b;
--term-bar: #1b1c1c;
--mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
--code: 'Liberation Mono', 'Courier New', ui-monospace, monospace;
--sans: 'Geist', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
--shadow-sm: 0 1px 1px rgba(0, 0, 0, 0.05);
--shadow-term: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
background: var(--bg);
color: var(--ink);
font-family: var(--sans);
font-size: 16px;
line-height: 1.5;
-webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; background: none; border: 0; color: inherit; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: 1152px; margin: 0 auto; padding: 0 32px; }
.mono { font-family: var(--mono); }
.label {
font-family: var(--mono);
font-weight: 500;
font-size: 11px;
letter-spacing: 0.55px;
text-transform: uppercase;
color: var(--muted);
}
.eyebrow { color: var(--blue); }

/* ---------- Header ---------- */
.site-header {
position: fixed;
inset: 0 0 auto 0;
z-index: 50;
background: rgba(249, 249, 246, 0.85);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
box-shadow: 0 1px 8px 0 rgba(0, 0, 0, 0.03);
}
.header-inner {
max-width: 1152px;
margin: 0 auto;
height: 64px;
padding: 0 32px;
display: flex;
align-items: center;
justify-content: space-between;
gap: 24px;
}
.brand { display: flex; align-items: center; gap: 8px; }
.brand-dot {
width: 8px; height: 8px; border-radius: 50%;
background: var(--blue);
box-shadow: 0 0 0 4px rgba(41, 77, 214, 0.15);
}
.brand-name { font-weight: 500; font-size: 18px; letter-spacing: -0.45px; }
.brand-sep {
font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: 0.22px;
color: var(--muted);
border-left: 1px solid var(--line-2);
padding-left: 5px; margin-left: 4px;
}
.nav { display: flex; align-items: center; gap: 24px; }
.nav-links { display: flex; align-items: center; gap: 8px; }
.nav-link {
font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px;
color: var(--muted); padding: 4px 8px; border-radius: 4px;
transition: background 0.2s, color 0.2s;
}
.nav-link:hover { color: var(--ink); }
.nav-link.active { background: var(--surface-3); color: var(--ink); font-family: var(--sans); font-weight: 500; font-size: 15px; }
.btn-dark-sm {
background: #000; color: #fff;
font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px;
padding: 4px 16px; border-radius: 4px; transition: opacity 0.2s;
}
.btn-dark-sm:hover { opacity: 0.85; }
.icon-btn {
width: 32px; height: 32px; border-radius: 12px;
background: #000; color: #fff;
display: none; align-items: center; justify-content: center;
}
.nav-toggle { display: none; }

/* ---------- Shared buttons / fields ---------- */
.btn {
display: inline-flex; align-items: center; justify-content: center; gap: 4px;
font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px;
border-radius: 4px; box-shadow: var(--shadow-sm); transition: transform 0.15s, opacity 0.2s, background 0.2s;
white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: #000; color: #fff; padding: 8px 24px; }
.btn-primary:hover { opacity: 0.88; }
.btn-ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--line-2); padding: 9px 25px; }
.btn-ghost:hover { background: var(--surface-2); }

/* ---------- Hero ---------- */
.hero { padding: 160px 0 128px; }
.hero-grid {
display: grid;
grid-template-columns: repeat(12, minmax(0, 1fr));
gap: 24px;
align-items: center;
}
.hero-copy { grid-column: 1 / span 7; position: relative; }
.status-pill {
display: inline-flex; align-items: center; gap: 8px;
background: var(--surface-3);
border: 1px solid var(--line);
border-radius: 12px;
padding: 5px 9px;
font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: -0.275px;
color: var(--muted);
}
.pulse { position: relative; width: 8px; height: 8px; }
.pulse::before, .pulse::after {
content: ''; position: absolute; inset: 0; border-radius: 50%; background: var(--blue);
}
.pulse::before { opacity: 0.75; animation: ping 2s cubic-bezier(0, 0, 0.2, 1) infinite; }
.pulse::after { position: relative; }
@keyframes ping { 75%, 100% { transform: scale(2); opacity: 0; } }

.subhead { margin-top: 50px; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.subhead .slash { color: #c4c7c7; }
.subhead .accent { color: var(--blue); }

.hero h1 {
margin-top: 40px;
font-weight: 600;
font-size: 48px;
line-height: 56px;
letter-spacing: -1.2px;
color: var(--ink);
max-width: 576px;
}
.hero-lead {
margin-top: 24px;
max-width: 576px;
font-size: 17px;
line-height: 27.63px;
letter-spacing: -0.085px;
color: var(--muted);
}
.hero-actions { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
.hero-actions .btn-primary { padding: 8px 24px; gap: 4px; }
.hero-actions .btn-primary svg { width: 12px; height: 12px; }
.hero-actions .btn-ghost { padding: 9px 25px; }
.hero-social {
margin-top: 40px;
max-width: 576px;
border-top: 1px solid var(--line);
padding-top: 9px;
display: flex; flex-wrap: wrap; gap: 24px; align-items: center;
}
.hero-social a {
display: inline-flex; align-items: center; gap: 4px;
font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: 0.22px;
color: var(--muted); transition: color 0.2s;
}
.hero-social a:hover { color: var(--blue); }
.hero-social svg { width: 16px; height: 16px; }

/* Terminal */
.terminal-wrap { grid-column: 8 / span 5; }
.terminal {
background: var(--term);
border: 1px solid var(--line);
border-radius: 8px;
overflow: hidden;
box-shadow: var(--shadow-term);
}
.term-bar {
background: var(--term-bar);
border-bottom: 1px solid rgba(196, 199, 199, 0.15);
display: flex; align-items: center; justify-content: space-between;
padding: 8px 16px 9px;
}
.lights { display: flex; gap: 8px; }
.lights span { width: 12px; height: 12px; border-radius: 50%; opacity: 0.8; }
.lights span:nth-child(1) { background: #ff5f56; }
.lights span:nth-child(2) { background: #ffbd2e; }
.lights span:nth-child(3) { background: #27c93f; }
.term-title {
display: flex; align-items: center; gap: 4px;
font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: 0.22px;
color: var(--subtle);
}
.term-title svg { width: 11px; height: 9px; }
.term-close { width: 18px; height: 30px; display: flex; align-items: center; justify-content: center; color: var(--subtle); }
.term-body { padding: 24px; display: flex; flex-direction: column; gap: 16px; font-family: var(--code); font-size: 13px; line-height: 21px; }
.t-cmd { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.t-path { color: var(--blue); }
.t-prompt { color: var(--subtle); }
.t-text { color: #fff; }
.t-out { padding-left: 20px; padding-top: 4px; color: #dde1ff; }
.t-out.focus { color: #fffbff; }
.t-out .dot { color: var(--blue); padding: 0 2px; }
.t-active { padding-top: 8px; }
.cursor {
display: inline-block; width: 8px; height: 16px; margin-left: 2px;
background: var(--blue); vertical-align: middle;
animation: blink 1.1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.term-footer {
background: rgba(27, 28, 28, 0.8);
border-top: 1px solid rgba(196, 199, 199, 0.15);
display: flex; align-items: center; justify-content: space-between;
padding: 7px 16px 6px;
}
.term-status { display: flex; align-items: center; gap: 6px; font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: 0.22px; color: var(--subtle); }
.term-status i { width: 6px; height: 6px; border-radius: 50%; background: var(--blue); display: inline-block; }
.term-enc { font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: 0.22px; color: var(--subtle); }

/* ---------- Sections ---------- */
.section { padding: 128px 0; border-top: 1px solid var(--line); }
.section-grid {
display: grid;
grid-template-columns: repeat(12, minmax(0, 1fr));
gap: 24px;
}

/* About */
.about-intro { grid-column: 1 / span 4; display: flex; flex-direction: column; gap: 8px; }
.about-intro h2 { margin-top: 0; }
.about-intro p { max-width: 320px; font-size: 13px; line-height: 19.5px; color: var(--muted); }
.about-body { grid-column: 5 / span 8; display: flex; flex-direction: column; gap: 40px; }
.about-text { display: flex; flex-direction: column; gap: 23px; max-width: 672px; }
.about-text p { font-size: 17px; line-height: 27.63px; letter-spacing: -0.085px; color: var(--muted); }

h2.section-title {
font-weight: 600; font-size: 32px; line-height: 40px; letter-spacing: -0.8px; color: var(--ink);
}

.ledger {
background: var(--surface);
border: 1px solid var(--line);
border-radius: 8px;
overflow: hidden;
box-shadow: var(--shadow-sm);
}
.ledger-head {
background: var(--surface-2);
border-bottom: 1px solid rgba(196, 199, 199, 0.2);
padding: 13px 24px 12px;
}
.ledger-row {
display: grid;
grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
gap: 24px;
padding: 24px;
align-items: start;
}
.ledger-row + .ledger-row { border-top: 1px solid rgba(196, 199, 199, 0.2); }
.ledger-key { display: flex; align-items: center; gap: 4px; font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px; color: var(--muted); }
.ledger-key svg { flex-shrink: 0; }
.ledger-val { font-size: 15px; line-height: 24px; color: var(--ink); }

/* Skills */
.skills-head {
display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap;
}
.skills-intro { max-width: 576px; display: flex; flex-direction: column; gap: 8px; }
.skills-intro p { font-size: 15px; line-height: 24.38px; color: var(--muted); }
.skills-intro .section-title { padding-top: 4px; }
.badge {
display: inline-flex; align-items: center; gap: 4px;
background: var(--surface-2);
border: 1px solid var(--line-2);
border-radius: 2px;
padding: 7px 13px;
font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: 0.22px;
color: var(--muted);
white-space: nowrap;
}
.badge .bdot { width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }

.skills-matrix {
margin-top: 40px;
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 24px;
}
.skill-card {
background: var(--surface);
border: 1px solid var(--line);
border-radius: 8px;
padding: 25px;
box-shadow: var(--shadow-sm);
display: flex; flex-direction: column; gap: 36px;
transition: transform 0.2s, box-shadow 0.2s;
}
.skill-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06); }
.skill-top {
border-bottom: 1px solid rgba(196, 199, 199, 0.2);
padding-bottom: 17px;
display: flex; justify-content: space-between; align-items: center;
}
.skill-top svg { color: var(--muted); }
.skill-body { padding-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.skill-title { font-weight: 500; font-size: 22px; line-height: 30px; letter-spacing: -0.33px; color: var(--ink); }
.skill-desc { font-size: 13px; line-height: 20px; color: var(--muted); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.tag {
background: var(--surface-2);
border: 1px solid var(--line);
border-radius: 2px;
padding: 5px 11px;
font-family: var(--code); font-size: 13px; line-height: 18px; letter-spacing: -0.13px; color: var(--ink);
}
.skills-footer { display: flex; justify-content: center; padding-top: 16px; }
.micro-badge {
display: inline-flex; align-items: center; gap: 8px;
background: var(--surface-3);
border: 1px solid var(--line);
border-radius: 12px;
padding: 9px 17px;
}
.micro-badge i { width: 6px; height: 6px; border-radius: 50%; background: #747878; }
.micro-badge span {
font-family: var(--code); font-size: 13px; letter-spacing: 0.65px; text-transform: uppercase; color: var(--muted); white-space: nowrap;
}

/* Contact */
.contact-left { grid-column: 1 / span 5; display: flex; flex-direction: column; gap: 40px; }
.contact-copy { display: flex; flex-direction: column; gap: 15px; padding-top: 5px; }
.contact-copy p { font-size: 17px; line-height: 27.63px; letter-spacing: -0.085px; color: var(--muted); }
.contact-copy .aside { font-size: 15px; line-height: 24px; color: rgba(68, 71, 72, 0.9); }
.direct { display: flex; flex-direction: column; gap: 8px; padding-top: 16px; }
.email-tile {
background: var(--surface);
border: 1px solid var(--line);
border-radius: 4px;
padding: 17px;
display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.email-tile a { font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px; color: var(--ink); word-break: break-all; }
.copy-btn { padding: 4px; color: var(--muted); transition: color 0.2s; }
.copy-btn:hover { color: var(--blue); }
.network { display: flex; gap: 16px; align-items: center; padding-top: 4px; flex-wrap: wrap; }
.network a {
display: inline-flex; align-items: center; gap: 4px;
font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px; color: var(--ink);
transition: color 0.2s;
}
.network a:hover { color: var(--blue); }
.network .sep { color: #c4c7c7; }

.contact-right { grid-column: 6 / span 7; }
.form-card {
background: var(--surface);
border: 1px solid var(--line);
border-radius: 8px;
padding: 41px;
box-shadow: var(--shadow-sm);
}
.contact-form { display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-head { display: flex; align-items: center; justify-content: space-between; }
.field-label { font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px; color: var(--ink); }
.field-req { font-family: var(--mono); font-size: 11px; letter-spacing: 0.22px; color: var(--muted); }
.field input, .field textarea {
width: 100%;
background: var(--bg);
border: 1px solid var(--line-2);
border-radius: 4px;
padding: 13px 17px 14px;
font-family: var(--sans); font-size: 15px; color: var(--ink);
transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.field input::placeholder, .field textarea::placeholder { color: rgba(68, 71, 72, 0.5); }
.field input:focus, .field textarea:focus {
outline: none;
border-color: var(--blue);
background: var(--surface);
box-shadow: 0 0 0 3px rgba(41, 77, 214, 0.12);
}
.field.invalid input, .field.invalid textarea { border-color: #c0392b; }
.field textarea { min-height: 142px; resize: vertical; line-height: 24px; }
.submit-row { padding-top: 4px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.submit-btn {
background: #000; color: #fff;
font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px;
padding: 8px 40px; border-radius: 4px; box-shadow: var(--shadow-sm);
display: inline-flex; align-items: center; gap: 4px;
transition: opacity 0.2s, transform 0.15s;
}
.submit-btn:hover { opacity: 0.88; }
.submit-btn:active { transform: translateY(1px); }
.submit-btn:disabled { opacity: 0.6; cursor: wait; }
.submit-btn svg { width: 13px; height: 11px; }
.form-status { font-family: var(--mono); font-size: 12px; letter-spacing: 0.2px; color: var(--muted); min-height: 16px; }
.form-status.ok { color: #1e7a46; }
.form-status.err { color: #b03a2e; }

/* ---------- Footer ---------- */
.site-footer { background: var(--surface-2); padding: 40px 64px; }
.footer-inner {
max-width: 1152px; margin: 0 auto; padding: 0 32px;
display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap;
}
.footer-copy { display: flex; flex-direction: column; gap: 4px; }
.footer-copy .name { font-size: 13px; line-height: 20px; color: var(--ink); }
.footer-copy .legal { font-family: var(--mono); font-weight: 500; font-size: 11px; letter-spacing: 0.22px; line-height: 16px; color: var(--muted); }
.footer-links { display: flex; gap: 24px; align-items: center; }
.footer-links a { font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: -0.13px; color: var(--muted); transition: color 0.2s; }
.footer-links a:hover { color: var(--blue); }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
.wrap, .header-inner, .footer-inner { padding: 0 24px; }
.hero { padding: 140px 0 96px; }
.hero h1 { font-size: 42px; line-height: 50px; }
.section { padding: 96px 0; }
}

@media (max-width: 960px) {
.nav-toggle { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; }
.nav {
  position: absolute; top: 64px; left: 0; right: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  flex-direction: column; align-items: stretch; gap: 8px;
  padding: 16px 24px 20px;
  transform: translateY(-8px); opacity: 0; pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
}
.nav.open { transform: none; opacity: 1; pointer-events: auto; }
.nav-links { flex-direction: column; align-items: stretch; gap: 4px; }
.nav-link { padding: 10px 8px; font-size: 14px; }
.nav-link.active { font-size: 14px; }
.nav .btn-dark-sm { text-align: center; padding: 10px 16px; font-size: 14px; }

.hero-grid { grid-template-columns: 1fr; }
.hero-copy, .terminal-wrap { grid-column: 1 / -1; }
.terminal-wrap { margin-top: 24px; }

.section-grid { grid-template-columns: 1fr; gap: 40px; }
.about-intro, .about-body, .contact-left, .contact-right { grid-column: 1 / -1; }
.skills-matrix { grid-template-columns: 1fr; }
.skill-card { gap: 28px; }
.site-footer { padding: 40px 24px; }
}

@media (max-width: 640px) {
.wrap, .header-inner, .footer-inner { padding: 0 20px; }
.brand-sep { display: none; }
.hero { padding: 120px 0 80px; }
.hero h1 { font-size: 36px; line-height: 44px; letter-spacing: -0.9px; }
.hero-lead { font-size: 16px; line-height: 26px; }
.hero-actions .btn { flex: 1 1 auto; }
h2.section-title { font-size: 28px; line-height: 36px; }
.about-text p, .contact-copy p { font-size: 16px; line-height: 26px; }
.ledger-row { grid-template-columns: 1fr; gap: 8px; padding: 20px; }
.form-card { padding: 24px; }
.submit-btn { width: 100%; justify-content: center; }
.skills-head { align-items: flex-start; }
.badge { white-space: normal; }
.micro-badge span { white-space: normal; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
html { scroll-behavior: auto; }
*, *::before, *::after { animation: none !important; transition: none !important; }
.reveal { opacity: 1; transform: none; }
}
