*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg:          #0a0a0a;
  --bg2:         #111111;
  --bg3:         #161616;
  --border:      #1e1e1e;
  --border2:     #2a2a2a;
  --text:        #c8c8c8;
  --muted:       #555555;
  --amber:       #e8a020;
  --amber-dim:   #b07818;
  --amber-glow:  rgba(232, 160, 32, 0.08);
  --green:       #3fb950;
  --red:         #f85149;
  --mono:        'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;
  --display:     'Syne', sans-serif;
  --sidebar-w:   220px;
  --transition:  0.15s ease;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 40px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.7;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }

.shell {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  background: var(--bg2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 100;
  transition: transform 0.3s ease;
  overflow-y: auto;
}

.sidebar-chrome {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 14px 16px 12px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dot-red    { background: #ff5f57; }
.dot-yellow { background: #febc2e; }
.dot-green  { background: #28c840; }

.sidebar-title {
  font-size: 11px;
  color: var(--muted);
  margin-left: 6px;
  letter-spacing: 0.02em;
}

.kbd {
  margin-left: auto;
  font-size: 10px;
  color: var(--muted);
  border: 1px solid var(--border2);
  border-radius: 3px;
  padding: 1px 5px;
}

nav {
  flex: 1;
  padding: 12px 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-family: var(--mono);
  letter-spacing: 0.04em;
  transition: color var(--transition), background var(--transition);
  border-left: 2px solid transparent;
}

.nav-item:hover,
.nav-item.active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
}

.nav-item.active {
  color: var(--amber);
  border-left-color: var(--amber);
}

.nav-icon {
  color: var(--amber);
  font-size: 11px;
  opacity: 0.6;
  transition: opacity var(--transition);
}

.nav-item.active .nav-icon,
.nav-item:hover .nav-icon {
  opacity: 1;
}

.nav-arrow {
  margin-left: auto;
  font-size: 12px;
  opacity: 0;
  color: var(--amber);
  transition: opacity var(--transition);
}

.nav-item:hover .nav-arrow,
.nav-item.active .nav-arrow {
  opacity: 1;
}

.sidebar-socials {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

.social-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border: 1px solid var(--border2);
  border-radius: 5px;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
  background: none;
  font-family: var(--mono);
  transition: color var(--transition), border-color var(--transition), background var(--transition);
}

.social-btn:hover {
  color: var(--amber);
  border-color: var(--amber-dim);
  background: var(--amber-glow);
}

.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  padding: 48px 56px 60vh;
  max-width: calc(var(--sidebar-w) + 860px);
}

section {
  margin-bottom: 80px;
}

.cmd-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 28px;
  font-size: 12px;
  color: var(--muted);
  font-family: var(--mono);
}

.cmd-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
  margin-left: 12px;
}

.cmd-label .prompt { color: var(--amber); font-weight: 500; }
.cmd-label .cmd    { color: var(--text);  font-weight: 500; }
.cmd-label .arg    { color: #777; }

.hero-name {
  font-family: var(--display);
  font-size: 68px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.0;
  letter-spacing: -0.025em;
  margin-bottom: 24px;
}

.hero-tagline {
  font-size: 13px;
  line-height: 1.95;
  color: var(--text);
  max-width: 560px;
  margin-bottom: 22px;
}

.hero-tagline strong {
  color: var(--amber);
  font-weight: 500;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  border: 1px solid var(--border2);
  border-radius: 4px;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 28px;
  background: var(--bg2);
  font-style: italic;
  letter-spacing: 0.02em;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 6px var(--green);
  flex-shrink: 0;
  animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 6px var(--green); }
  50%       { opacity: 0.4; box-shadow: 0 0 2px var(--green); }
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 40px;
}

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border: 1px solid var(--border2);
  border-radius: 4px;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  background: none;
  font-family: var(--mono);
  transition: color var(--transition), border-color var(--transition), background var(--transition);
}

.cta-btn:hover {
  color: var(--amber);
  border-color: var(--amber-dim);
  background: var(--amber-glow);
}

.cta-btn.primary {
  border-color: var(--amber-dim);
  color: var(--amber);
  background: var(--amber-glow);
}

.cta-btn.primary:hover {
  background: rgba(232, 160, 32, 0.14);
}

.active-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--amber);
  border-radius: 6px;
  padding: 20px 24px;
  max-width: 580px;
}

.active-card-title {
  font-size: 10px;
  color: var(--amber);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 16px;
  font-weight: 500;
}

.project-line {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
  font-size: 12px;
  line-height: 1.65;
  color: var(--text);
}

.project-line:last-child { margin-bottom: 0; }

.proj-idx {
  color: var(--amber-dim);
  min-width: 28px;
  font-size: 11px;
  padding-top: 1px;
  flex-shrink: 0;
}

.contact-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid var(--border2);
  border-radius: 4px;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  background: none;
  font-family: var(--mono);
  transition: color var(--transition), border-color var(--transition), background var(--transition);
}

.contact-btn:hover {
  color: var(--amber);
  border-color: var(--amber-dim);
  background: var(--amber-glow);
}

.git-section {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 20px 24px;
}

.git-grid {
  display: grid;
  grid-template-columns: repeat(52, 1fr);
  grid-template-rows: repeat(7, 1fr);
  gap: 2.5px;
  margin-bottom: 10px;
}

.git-cell {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 2px;
  transition: opacity 0.1s;
}

.git-cell:hover { opacity: 0.7; }

.git-legend {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  color: var(--muted);
  justify-content: flex-end;
}

.git-legend-cells {
  display: flex;
  gap: 2.5px;
}

.projects-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.proj-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 22px 26px;
  transition: border-color var(--transition), background var(--transition);
}

.proj-card:hover {
  border-color: var(--border2);
  background: #121212;
}

.proj-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
}

.proj-name {
  font-size: 14px;
  color: #ffffff;
  font-weight: 500;
  font-family: var(--mono);
  letter-spacing: -0.01em;
}

.proj-type {
  font-size: 10px;
  padding: 3px 9px;
  border-radius: 3px;
  background: var(--amber-glow);
  color: var(--amber);
  border: 1px solid var(--amber-dim);
  white-space: nowrap;
  letter-spacing: 0.04em;
  flex-shrink: 0;
  margin-top: 1px;
}

.proj-desc {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.75;
  margin-bottom: 16px;
}

.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.proj-tag {
  font-size: 10px;
  color: #4a4a4a;
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 2px 8px;
  background: var(--bg3);
  font-family: var(--mono);
  transition: color var(--transition), border-color var(--transition);
}

.proj-tag:hover {
  color: var(--muted);
  border-color: var(--border2);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
}

.skill-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 18px 20px;
  transition: border-color var(--transition);
}

.skill-card:hover { border-color: var(--border2); }

.skill-category {
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--amber);
  margin-bottom: 12px;
  font-weight: 500;
}

.skill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.skill-tag {
  font-size: 11px;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 3px 9px;
  background: var(--bg3);
  transition: color var(--transition), border-color var(--transition);
  cursor: default;
}

.skill-tag:hover {
  color: var(--text);
  border-color: var(--border2);
}

.exp-list {
  display: flex;
  flex-direction: column;
}

.exp-item {
  display: flex;
  gap: 22px;
  padding: 24px 0;
  border-bottom: 1px solid var(--border);
}

.exp-item:last-child { border-bottom: none; }

.exp-timeline {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 18px;
  padding-top: 5px;
}

.exp-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1.5px solid var(--amber);
  background: var(--bg);
  flex-shrink: 0;
}

.exp-line {
  flex: 1;
  width: 1px;
  background: var(--border);
  margin-top: 7px;
}

.exp-item:last-child .exp-line { display: none; }

.exp-body { flex: 1; }

.exp-role {
  font-size: 14px;
  color: #ffffff;
  font-weight: 500;
  margin-bottom: 3px;
  letter-spacing: -0.01em;
}

.exp-company {
  font-size: 12px;
  color: var(--amber);
  margin-bottom: 4px;
}

.exp-period {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 14px;
  font-style: italic;
}

.exp-bullets {
  list-style: none;
  padding-left: 0;
}

.exp-bullets li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 7px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.7;
}

.exp-bullets li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--amber-dim);
  font-size: 11px;
  top: 1px;
}

.blog-list {
  display: flex;
  flex-direction: column;
}

.blog-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  gap: 14px;
  transition: background var(--transition);
}

.blog-item:last-child { border-bottom: none; }

.blog-title {
  font-size: 13px;
  color: var(--text);
  transition: color var(--transition);
  line-height: 1.5;
}

.blog-item:hover .blog-title { color: var(--amber); }

.blog-tag {
  font-size: 10px;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 2px 8px;
  background: var(--bg3);
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}

.blog-note {
  font-size: 11px;
  color: var(--muted);
  margin-top: 20px;
  font-style: italic;
}

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 200;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--bg2);
  border: 1px solid var(--border2);
  cursor: pointer;
  padding: 0;
}

.hamburger span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--amber);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 90;
  backdrop-filter: blur(2px);
}

.overlay.open { display: block; }

@media (max-width: 900px) {
  .main { padding: 40px 36px 80px; }
  .hero-name { font-size: 54px; }
}

@media (max-width: 700px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.6);
  }
  .main {
    margin-left: 0;
    padding: 28px 22px 90px;
  }
  .hero-name { font-size: 40px; }
  .hamburger { display: flex; }
  .skills-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .hero-name { font-size: 34px; }
  .proj-header { flex-direction: column; gap: 6px; }
  .blog-item { flex-direction: column; gap: 6px; }
}
