/* =====================================================================
   DEVFOLIO — Developer Portfolio Template
   Plain HTML5 + CSS3 + vanilla JS. No frameworks. No external images.
   Every visual is a CSS gradient, inline SVG, or emoji.
   ---------------------------------------------------------------------
   REBRAND TIP: All colors and fonts live in the :root block below.
   Change them once and the whole site updates. Update the Google Fonts
   <link> in each HTML <head> if you swap font families.
   ===================================================================== */

:root {
  /* --- Brand palette (edit these to rebrand) --- */
  --bg:      #0d1117;                 /* page background (GitHub dark)   */
  --ink:     #e6edf3;                 /* primary text                    */
  --accent:  #58a6ff;                 /* primary accent (links / blue)   */
  --accent2: #39d353;                 /* secondary accent (green)        */
  --muted:   #8b949e;                 /* muted / secondary text          */
  --surface: #161b22;                 /* cards & raised surfaces         */
  --line:    rgba(255, 255, 255, .09);/* borders / dividers              */

  /* --- Derived tints --- */
  --surface-2: #1c232c;               /* slightly lighter surface        */
  --accent-soft: rgba(88, 166, 255, .12);
  --accent2-soft: rgba(57, 211, 83, .12);

  /* --- Fonts --- */
  --font-head: 'Space Grotesk', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'Courier New', monospace;
  --font-body: 'Inter', system-ui, sans-serif;

  /* --- Shape & motion --- */
  --radius:    16px;
  --radius-sm: 10px;
  --shadow:    0 10px 30px rgba(0, 0, 0, .35);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, .5);
  --ease:      .35s cubic-bezier(.4, 0, .2, 1);

  /* --- Layout --- */
  --maxw: 1180px;
  --gutter: 24px;
}

/* ---------------------------------------------------------------------
   RESET / BASE
   --------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 .5em;
  font-weight: 700;
  letter-spacing: -.02em;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1rem; }

a { color: var(--accent); text-decoration: none; transition: color var(--ease); }
a:hover { color: #79b8ff; }

img, svg { max-width: 100%; display: block; }

ul { margin: 0; padding: 0; list-style: none; }

code, .mono { font-family: var(--font-mono); }

::selection { background: var(--accent-soft); color: #fff; }

/* ---------------------------------------------------------------------
   LAYOUT HELPERS
   --------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section { padding: 92px 0; }
.section--soft { background: var(--surface); }
.section--tight { padding: 64px 0; }

.section-head {
  max-width: 720px;
  margin: 0 auto 56px;
  text-align: center;
}
.section-head--left { margin-left: 0; text-align: left; }

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .08em;
  color: var(--accent2);
  background: var(--accent2-soft);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.eyebrow::before { content: "// "; opacity: .65; }

.lead { font-size: 1.12rem; color: var(--muted); }
.muted { color: var(--muted); }

/* ---------------------------------------------------------------------
   BUTTONS
   --------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .96rem;
  padding: 13px 24px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform var(--ease), box-shadow var(--ease), background var(--ease), color var(--ease), border-color var(--ease);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--accent);
  color: #08111f;
  box-shadow: 0 8px 22px rgba(88, 166, 255, .28);
}
.btn-primary:hover { background: #79b8ff; color: #08111f; box-shadow: 0 12px 30px rgba(88, 166, 255, .4); }

.btn-ghost {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.btn-code {
  background: transparent;
  color: var(--accent2);
  border-color: rgba(57, 211, 83, .4);
  font-family: var(--font-mono);
}
.btn-code:hover { background: var(--accent2-soft); color: var(--accent2); }

/* ---------------------------------------------------------------------
   HEADER / NAV  (shared, identical IDs on every page)
   --------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 17, 23, .82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--ink);
  letter-spacing: -.02em;
}
.brand:hover { color: var(--ink); }
.brand .logo-mark {
  width: 36px; height: 36px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  display: grid; place-items: center;
  box-shadow: 0 6px 16px rgba(88, 166, 255, .3);
}
.brand .logo-mark span {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1rem;
  color: #08111f;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-links a {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: .9rem;
  color: var(--muted);
  padding: 8px 13px;
  border-radius: 8px;
  transition: background var(--ease), color var(--ease);
}
.nav-links a:hover { background: var(--surface); color: var(--ink); }
.nav-links a.active { color: var(--accent); background: var(--accent-soft); }

.nav-cta { margin-left: 8px; }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px; height: 44px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 20px; height: 2px;
  margin: 0 auto;
  background: var(--ink);
  border-radius: 2px;
  transition: transform var(--ease), opacity var(--ease);
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------------------------------------------------------------------
   HERO (home)
   --------------------------------------------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 500px at 88% -10%, rgba(88, 166, 255, .14), transparent 60%),
    radial-gradient(700px 500px at 0% 110%, rgba(57, 211, 83, .08), transparent 55%);
  padding: 86px 0 92px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 52px;
  align-items: center;
}
.hero h1 { margin-bottom: 18px; }
.hero h1 span { color: var(--accent); }
.hero .lead { max-width: 540px; margin-bottom: 30px; color: var(--muted); }
.hero-role {
  font-family: var(--font-mono);
  color: var(--accent2);
  font-size: .95rem;
  margin-bottom: 14px;
}
.hero-role .cursor {
  display: inline-block;
  width: 9px;
  background: var(--accent2);
  margin-left: 2px;
  animation: blink 1.1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 34px; }
.hero-meta { display: flex; gap: 32px; flex-wrap: wrap; }
.hero-meta div strong {
  font-family: var(--font-head);
  font-size: 1.7rem;
  color: var(--ink);
  display: block;
  line-height: 1;
}
.hero-meta div span { font-size: .85rem; color: var(--muted); font-family: var(--font-mono); }

/* Hero visual — pure CSS terminal / code block */
.terminal {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--line);
}
.terminal-bar i { width: 12px; height: 12px; border-radius: 50%; display: block; }
.terminal-bar i:nth-child(1) { background: #ff5f56; }
.terminal-bar i:nth-child(2) { background: #ffbd2e; }
.terminal-bar i:nth-child(3) { background: #27c93f; }
.terminal-bar .tb-title {
  margin-left: 10px;
  font-family: var(--font-mono);
  font-size: .8rem;
  color: var(--muted);
}
.terminal-body {
  padding: 22px 22px 26px;
  font-family: var(--font-mono);
  font-size: .9rem;
  line-height: 1.85;
  color: var(--ink);
  overflow-x: auto;
}
.terminal-body .ln { display: block; white-space: pre; }
.terminal-body .c-key { color: #ff7b72; }
.terminal-body .c-fn  { color: #d2a8ff; }
.terminal-body .c-str { color: var(--accent2); }
.terminal-body .c-var { color: var(--accent); }
.terminal-body .c-com { color: var(--muted); }
.terminal-body .c-num { color: #f0b72f; }

/* ---------------------------------------------------------------------
   TECH-STACK CHIPS STRIP
   --------------------------------------------------------------------- */
.stack-strip { padding: 40px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stack-strip p {
  text-align: center;
  font-family: var(--font-mono);
  font-size: .78rem;
  letter-spacing: .06em;
  color: var(--muted);
  margin-bottom: 22px;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}
.chip {
  font-family: var(--font-mono);
  font-size: .85rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 8px 15px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: border-color var(--ease), color var(--ease), transform var(--ease);
}
.chip:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }

/* ---------------------------------------------------------------------
   CARDS / GRIDS
   --------------------------------------------------------------------- */
.grid { display: grid; gap: 26px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ---------------------------------------------------------------------
   PROJECT CARDS (repo-style)
   --------------------------------------------------------------------- */
.work-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }

.work-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease);
}
.work-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: rgba(88, 166, 255, .35); }

.work-thumb {
  height: 160px;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
.work-thumb::after {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(300px 200px at 80% 10%, rgba(255,255,255,.18), transparent 60%);
}
.work-thumb .emoji { font-size: 2.6rem; position: relative; z-index: 1; transition: transform var(--ease); }
.work-card:hover .work-thumb .emoji { transform: scale(1.15) rotate(-5deg); }

.thumb-1 { background: linear-gradient(135deg, #1f6feb, #58a6ff); }
.thumb-2 { background: linear-gradient(135deg, #238636, #39d353); }
.thumb-3 { background: linear-gradient(135deg, #8957e5, #bc8cff); }
.thumb-4 { background: linear-gradient(135deg, #db6d28, #f0b72f); }
.thumb-5 { background: linear-gradient(135deg, #cf222e, #ff7b72); }
.thumb-6 { background: linear-gradient(135deg, #1b1f24, #3d444d); }
.thumb-7 { background: linear-gradient(135deg, #0d9488, #2dd4bf); }
.thumb-8 { background: linear-gradient(135deg, #be185d, #f472b6); }
.thumb-9 { background: linear-gradient(135deg, #4338ca, #818cf8); }

.work-body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.work-body h3 { font-size: 1.15rem; margin-bottom: 6px; display: flex; align-items: center; gap: 8px; }
.work-body h3 .repo-ic { color: var(--muted); font-family: var(--font-mono); font-weight: 400; }
.work-body > p { color: var(--muted); font-size: .94rem; margin-bottom: 16px; flex: 1; }

.tags { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 18px; }
.tags span {
  font-family: var(--font-mono);
  font-size: .74rem;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 4px 10px;
  border-radius: 999px;
}

.work-links { display: flex; gap: 16px; }
.work-links a {
  font-family: var(--font-mono);
  font-size: .82rem;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.work-links a:hover { color: var(--accent); }

/* ---------------------------------------------------------------------
   PROJECT FILTERS
   --------------------------------------------------------------------- */
.work-filters { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 44px; }
.filter-chip {
  font-family: var(--font-mono);
  font-size: .85rem;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 9px 18px;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--ease);
}
.filter-chip:hover { border-color: var(--accent); color: var(--accent); }
.filter-chip.is-active { background: var(--accent); border-color: var(--accent); color: #08111f; }

.work-card.is-hidden { display: none; }

/* ---------------------------------------------------------------------
   ABOUT TEASER (home) / SPLIT
   --------------------------------------------------------------------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 52px;
  align-items: center;
}
.split--reverse .split-media { order: 2; }
.split-media {
  border-radius: var(--radius);
  min-height: 360px;
  background: linear-gradient(150deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  padding: 32px;
}
.split-media::after {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(400px 300px at 80% 15%, rgba(88,166,255,.16), transparent 60%);
}
.avatar-block { position: relative; z-index: 1; text-align: center; }
.avatar-block .av {
  width: 120px; height: 120px;
  margin: 0 auto 16px;
  border-radius: 24px;
  display: grid; place-items: center;
  font-size: 3.4rem;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  box-shadow: var(--shadow);
}

.feature { display: flex; gap: 16px; align-items: flex-start; }
.feature .tick {
  flex: 0 0 auto;
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent2);
  display: grid; place-items: center;
  font-family: var(--font-mono);
  font-weight: 700;
}
.feature h3 { font-size: 1.08rem; margin-bottom: 4px; }
.feature p { margin-bottom: 0; font-size: .96rem; color: var(--muted); }

/* ---------------------------------------------------------------------
   STATS BAND
   --------------------------------------------------------------------- */
.stats-band { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; text-align: center; }
.stat strong {
  font-family: var(--font-head);
  font-size: clamp(2.2rem, 4vw, 3rem);
  display: block;
  line-height: 1;
  background: linear-gradient(120deg, var(--accent), var(--accent2));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.stat span { color: var(--muted); font-size: .9rem; font-family: var(--font-mono); }

/* ---------------------------------------------------------------------
   TESTIMONIALS
   --------------------------------------------------------------------- */
.quote-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px 32px;
}
.quote-card .stars { color: #f0b72f; margin-bottom: 14px; letter-spacing: 2px; }
.quote-card blockquote {
  margin: 0 0 22px;
  font-size: 1.06rem;
  color: var(--ink);
  line-height: 1.55;
}
.quote-author { display: flex; align-items: center; gap: 14px; }
.q-avatar {
  width: 46px; height: 46px;
  border-radius: 12px;
  display: grid; place-items: center;
  color: #08111f;
  font-family: var(--font-head);
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
}
.quote-author b { display: block; font-family: var(--font-head); color: var(--ink); }
.quote-author span { font-size: .85rem; color: var(--muted); font-family: var(--font-mono); }

/* ---------------------------------------------------------------------
   CTA BAND
   --------------------------------------------------------------------- */
.cta-band {
  background:
    radial-gradient(600px 400px at 90% 10%, rgba(88,166,255,.18), transparent 60%),
    linear-gradient(135deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 58px 48px;
  text-align: center;
  box-shadow: var(--shadow);
}
.cta-band h2 { color: var(--ink); }
.cta-band p { color: var(--muted); max-width: 560px; margin: 0 auto 28px; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------------------------------------------------------------------
   PAGE BANNER (inner pages)
   --------------------------------------------------------------------- */
.page-banner {
  background:
    radial-gradient(700px 400px at 85% -20%, rgba(88,166,255,.14), transparent 60%),
    var(--surface);
  padding: 60px 0 52px;
  border-bottom: 1px solid var(--line);
}
.page-banner h1 { margin-bottom: 10px; }
.page-banner p { max-width: 640px; color: var(--muted); margin-bottom: 0; }
.breadcrumb {
  font-family: var(--font-mono);
  font-size: .82rem;
  color: var(--muted);
  margin-bottom: 16px;
}
.breadcrumb a { color: var(--accent); }
.breadcrumb span { margin: 0 8px; opacity: .6; }

/* ---------------------------------------------------------------------
   SKILLS (about + resume)
   --------------------------------------------------------------------- */
.skill-group {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 26px;
}
.skill-group h3 { font-size: 1.05rem; margin-bottom: 18px; display: flex; align-items: center; gap: 9px; }
.skill-group h3 .ic { font-size: 1.2rem; }
.skill-row { margin-bottom: 16px; }
.skill-row:last-child { margin-bottom: 0; }
.skill-row .sk-top {
  display: flex; justify-content: space-between;
  font-family: var(--font-mono); font-size: .82rem; margin-bottom: 7px;
}
.skill-row .sk-top span:last-child { color: var(--accent2); }
.skill-bar { height: 7px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.skill-bar i {
  display: block; height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
}

/* ---------------------------------------------------------------------
   TIMELINE (experience / education)
   --------------------------------------------------------------------- */
.timeline { position: relative; padding-left: 34px; }
.timeline::before {
  content: "";
  position: absolute; left: 8px; top: 6px; bottom: 6px;
  width: 2px; background: var(--line);
}
.tl-item { position: relative; padding-bottom: 38px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: "";
  position: absolute; left: -34px; top: 4px;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--bg);
  border: 3px solid var(--accent);
}
.tl-item.green::before { border-color: var(--accent2); }
.tl-date {
  font-family: var(--font-mono);
  font-size: .8rem;
  color: var(--accent);
  margin-bottom: 4px;
}
.tl-item h3 { font-size: 1.15rem; margin-bottom: 2px; }
.tl-role { font-family: var(--font-mono); font-size: .85rem; color: var(--muted); margin-bottom: 10px; }
.tl-item p { color: var(--muted); margin-bottom: 0; }

/* Values cards */
.value-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 26px;
  transition: transform var(--ease), border-color var(--ease);
}
.value-card:hover { transform: translateY(-5px); border-color: rgba(88,166,255,.3); }
.value-card .ic {
  width: 50px; height: 50px;
  border-radius: 12px;
  background: var(--accent-soft);
  display: grid; place-items: center;
  font-size: 1.5rem;
  margin-bottom: 16px;
}
.value-card h3 { margin-bottom: 6px; }
.value-card p { color: var(--muted); margin-bottom: 0; font-size: .95rem; }

/* ---------------------------------------------------------------------
   RESUME specifics
   --------------------------------------------------------------------- */
.resume-head {
  display: flex; flex-wrap: wrap; gap: 24px;
  align-items: center; justify-content: space-between;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 32px;
  margin-bottom: 44px;
}
.resume-head .ident h2 { margin-bottom: 4px; }
.resume-head .ident p { color: var(--muted); margin-bottom: 0; font-family: var(--font-mono); font-size: .9rem; }
.resume-cols { display: grid; grid-template-columns: 1.6fr 1fr; gap: 44px; align-items: start; }
.resume-block { margin-bottom: 44px; }
.resume-block:last-child { margin-bottom: 0; }
.resume-block > h2 {
  font-size: 1.3rem; margin-bottom: 22px;
  padding-bottom: 12px; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 10px;
}
.resume-block > h2 .ic { font-size: 1.1rem; }
.info-list li {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 10px 0; border-bottom: 1px solid var(--line);
  font-size: .92rem;
}
.info-list li:last-child { border-bottom: none; }
.info-list li .ic { flex: 0 0 auto; }
.info-list li b { font-family: var(--font-head); display: block; color: var(--ink); }
.info-list li span { color: var(--muted); font-family: var(--font-mono); font-size: .82rem; }

/* ---------------------------------------------------------------------
   CONTACT
   --------------------------------------------------------------------- */
.contact-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 44px; align-items: start; }
.form-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px;
}
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: .82rem;
  color: var(--ink);
  margin-bottom: 7px;
}
.field input, .field select, .field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  padding: 12px 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg);
  transition: border-color var(--ease), box-shadow var(--ease);
}
.field input::placeholder, .field textarea::placeholder { color: #586069; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.field select { color: var(--ink); }
.field select option { background: var(--surface); color: var(--ink); }
.field textarea { resize: vertical; min-height: 130px; }
.field .error-msg { color: #ff7b72; font-size: .8rem; margin-top: 5px; display: none; font-family: var(--font-mono); }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #ff7b72; }
.field.invalid .error-msg { display: block; }
.form-note { font-size: .82rem; color: var(--muted); margin-top: 8px; font-family: var(--font-mono); }
.form-status {
  display: none;
  margin-top: 18px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  background: var(--accent2-soft);
  border: 1px solid rgba(57, 211, 83, .4);
  color: var(--accent2);
  font-weight: 500;
}
.form-status.show { display: block; }

.info-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  margin-bottom: 22px;
}
.info-row { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 20px; }
.info-row:last-child { margin-bottom: 0; }
.info-row .info-ic {
  width: 44px; height: 44px; flex: 0 0 auto;
  border-radius: 12px; background: var(--bg);
  border: 1px solid var(--line);
  display: grid; place-items: center; font-size: 1.3rem;
}
.info-row b { font-family: var(--font-head); color: var(--ink); display: block; }
.info-row span { font-size: .92rem; color: var(--muted); }
.info-row span a { color: var(--accent); }

.social { display: flex; gap: 10px; }
.social a {
  width: 42px; height: 42px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid var(--line);
  display: grid; place-items: center;
  font-size: 1rem;
  color: var(--ink);
  font-family: var(--font-mono);
  transition: all var(--ease);
}
.social a:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }

/* ---------------------------------------------------------------------
   FOOTER (shared)
   --------------------------------------------------------------------- */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--line);
  color: var(--muted);
  padding: 60px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 44px;
}
.site-footer .brand { color: var(--ink); margin-bottom: 14px; }
.site-footer .brand:hover { color: var(--ink); }
.footer-about p { font-size: .94rem; color: var(--muted); max-width: 320px; }
.footer-about .social { margin-top: 16px; }
.footer-col h4 {
  color: var(--ink); font-size: .78rem; letter-spacing: .08em;
  text-transform: uppercase; margin-bottom: 16px; font-family: var(--font-mono);
}
.footer-col a { display: block; color: var(--muted); padding: 5px 0; font-size: .94rem; }
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: .85rem;
  color: var(--muted);
  font-family: var(--font-mono);
}
.footer-bottom a { color: var(--muted); }
.footer-bottom a:hover { color: var(--accent); }

/* ---------------------------------------------------------------------
   SCROLL-REVEAL
   --------------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
  will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: .08s; }
.reveal[data-delay="2"] { transition-delay: .16s; }
.reveal[data-delay="3"] { transition-delay: .24s; }
.no-io .reveal { opacity: 1; transform: none; }

/* ---------------------------------------------------------------------
   RESPONSIVE
   --------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .work-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .terminal { max-width: 520px; }
  .resume-cols { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 768px) {
  .section { padding: 64px 0; }

  /* Mobile nav */
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute;
    top: 72px; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    padding: 14px var(--gutter) 22px;
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--ease), transform var(--ease);
  }
  .nav-links.open { transform: none; opacity: 1; pointer-events: auto; }
  .nav-links a { padding: 12px 14px; }
  .nav-cta { margin: 8px 0 0; }
  .nav-cta .btn { width: 100%; justify-content: center; }

  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .work-grid { grid-template-columns: 1fr; }
  .split, .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .split--reverse .split-media { order: 0; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .cta-band { padding: 44px 26px; }
}

@media (max-width: 360px) {
  .stats-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-meta { gap: 22px; }
}
