@import url("https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700&family=Inter:wght@400;500;600;700&display=swap");

:root {
  --bg: #0d1117;
  --bg-soft: #161b22;
  --bg-raised: #1c232c;
  --ink: #e6edf3;
  --muted: #8b949e;
  --dim: #6e7681;
  --accent: #7ee787;       /* terminal green */
  --accent-strong: #58a6ff; /* prompt blue */
  --accent-warn: #ffa657;   /* yellow-orange */
  --accent-err: #ff7b72;
  --border: #30363d;
  --border-soft: #21262d;
  --shadow: rgba(0, 0, 0, 0.5);
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--ink);
  background: var(--bg);
  background-image:
    radial-gradient(circle at 15% 0%, rgba(88, 166, 255, 0.08), transparent 40%),
    radial-gradient(circle at 90% 100%, rgba(126, 231, 135, 0.06), transparent 45%);
  line-height: 1.65;
  min-height: 100vh;
  font-size: 15px;
}

/* subtle scanline texture */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.012) 0px,
    rgba(255, 255, 255, 0.012) 1px,
    transparent 1px,
    transparent 3px
  );
}

h1, h2, h3, h4 {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-weight: 600;
  margin: 0 0 0.5rem;
  color: var(--ink);
  letter-spacing: -0.01em;
}

h2::before {
  content: "$ ";
  color: var(--accent);
  font-weight: 600;
}

h3 { color: var(--accent-strong); }

p { margin: 0 0 1rem; color: var(--muted); }

a { color: var(--accent-strong); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 0.25em; }

code {
  background: var(--bg-raised);
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-size: 0.92em;
  color: var(--accent);
  border: 1px solid var(--border-soft);
}

strong { color: var(--ink); font-weight: 600; }
img { max-width: 100%; height: auto; }

.container { width: min(1100px, 92vw); margin: 0 auto; }

@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

.caret {
  display: inline-block;
  width: 0.55em;
  height: 1em;
  background: var(--accent);
  vertical-align: text-bottom;
  margin-left: 0.15em;
  animation: blink 1.05s steps(1) infinite;
}

.site { min-height: 100vh; display: flex; flex-direction: column; }

.site-header {
  width: min(1100px, 92vw);
  margin: 0 auto;
  padding: 1.25rem 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(13, 17, 23, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav-brand { display: flex; flex-direction: column; gap: 0.15rem; }

.brand-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
}
.brand-name::before {
  content: "~/";
  color: var(--accent);
  font-weight: 500;
}
.brand-name:hover { text-decoration: none; color: var(--accent); }

.brand-subtitle {
  font-size: 0.78rem;
  color: var(--dim);
  font-weight: 400;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  font-size: 0.82rem;
  font-weight: 500;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  border: 1px solid transparent;
  transition: all 0.15s ease;
}
.nav-links a::before { content: "/"; color: var(--dim); margin-right: 0.15em; }
.nav-links a:hover {
  color: var(--accent);
  border-color: var(--border);
  background: var(--bg-soft);
  text-decoration: none;
}

.content {
  width: min(1100px, 92vw);
  margin: 1.5rem auto 4rem;
  flex: 1;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0 2.5rem;
  background: var(--bg-soft);
}

.footer-inner {
  width: min(1100px, 92vw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.82rem;
  color: var(--dim);
}

.footer-left { display: flex; flex-direction: column; gap: 0.2rem; }
.footer-right { display: flex; gap: 1.2rem; flex-wrap: wrap; }

.page { animation: rise 0.4s ease both; }
.page-header { margin: 1rem 0 2rem; }
.page-subtitle { font-size: 0.95rem; color: var(--muted); max-width: 720px; }

@media (max-width: 820px) {
  .site-header { flex-direction: column; align-items: flex-start; }
  .nav-links { gap: 0.25rem; }
}

/* ---------- cards / panels ---------- */
.hero {
  display: grid;
  grid-template-columns: 2.1fr 1fr;
  gap: 1.5rem;
  margin: 1rem 0 2.5rem;
  align-items: start;
  animation: rise 0.5s ease both;
}

.hero-card,
.card,
.stat {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.5rem;
  box-shadow: 0 8px 24px var(--shadow);
  position: relative;
}

/* terminal window chrome — titlebar with traffic lights */
.hero-card::before,
.card.terminal::before {
  content: "● ● ●";
  display: block;
  letter-spacing: 0.35em;
  color: #ff5f56;
  text-shadow:
    1.1em 0 0 #ffbd2e,
    2.2em 0 0 #27c93f;
  font-size: 0.6rem;
  margin: -0.5rem 0 0.9rem -0.3rem;
  opacity: 0.85;
}

.eyebrow {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 0.6rem;
}
.eyebrow::before { content: "# "; color: var(--dim); }

.hero-card h1 {
  font-size: 2.2rem;
  line-height: 1.15;
  margin-bottom: 0.6rem;
  color: var(--ink);
  font-weight: 700;
}
.hero-card h1::before {
  content: "$ whoami → ";
  color: var(--accent);
  font-size: 0.95rem;
  font-weight: 500;
  display: block;
  margin-bottom: 0.3rem;
}

.hero-card .lead { font-size: 0.98rem; color: var(--muted); }

.hero-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 1rem 0; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.82rem;
  font-weight: 500;
  border: 1px solid var(--border);
  transition: all 0.15s ease;
  cursor: pointer;
}
.btn::before { content: "> "; color: var(--accent); }

.btn-primary {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
}
.btn-primary::before { content: "$ "; color: var(--bg); }
.btn-primary:hover { text-decoration: none; background: #9af0a3; transform: translateY(-1px); }

.btn-ghost {
  background: var(--bg-raised);
  color: var(--accent-strong);
  border-color: var(--border);
}
.btn-ghost:hover { text-decoration: none; border-color: var(--accent-strong); transform: translateY(-1px); }

.profile-card { display: flex; flex-direction: column; gap: 1rem; align-items: stretch; }
.profile-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center top;
  border-radius: 8px;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  display: block;
}

.profile-meta { display: grid; gap: 0.4rem; font-size: 0.85rem; color: var(--muted); }
.profile-meta strong { color: var(--accent); font-weight: 500; }

.section { margin-bottom: 2.5rem; }

.section-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px dashed var(--border);
}
.section-title h2 { font-size: 1.3rem; }
.section-title a { font-size: 0.8rem; font-weight: 500; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.2rem;
}

.card h3 { margin-bottom: 0.35rem; font-size: 1rem; }
.card h3::before { content: "▸ "; color: var(--accent); }
.card .card-meta {
  font-size: 0.78rem;
  color: var(--dim);
  margin-bottom: 0.65rem;
}

.tag-list { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.6rem; }

.tag {
  padding: 0.15rem 0.55rem;
  border-radius: 4px;
  background: rgba(126, 231, 135, 0.08);
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 500;
  border: 1px solid rgba(126, 231, 135, 0.25);
  font-family: "JetBrains Mono", monospace;
}
.tag.alt {
  background: rgba(88, 166, 255, 0.08);
  color: var(--accent-strong);
  border-color: rgba(88, 166, 255, 0.3);
}
.tag:hover { text-decoration: none; filter: brightness(1.15); }

.list-plain {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 0;
  display: grid;
  gap: 0.4rem;
  font-size: 0.88rem;
  color: var(--muted);
}
.list-plain li::before { content: "─ "; color: var(--dim); }

.timeline {
  list-style: none;
  padding: 0 0 0 0.5rem;
  margin: 0;
  display: grid;
  gap: 1.2rem;
  border-left: 2px solid var(--border);
}
.timeline li { position: relative; padding-left: 1.2rem; }
.timeline li::before {
  content: "●";
  color: var(--accent);
  position: absolute;
  left: -0.5rem;
  top: 0;
  font-size: 0.8rem;
  background: var(--bg);
  line-height: 1;
}

.callout {
  background: rgba(88, 166, 255, 0.06);
  border-radius: 6px;
  padding: 0.9rem 1.1rem;
  border: 1px solid rgba(88, 166, 255, 0.25);
  border-left: 3px solid var(--accent-strong);
  color: var(--ink);
  font-size: 0.88rem;
}
.callout::before { content: "ℹ INFO  "; color: var(--accent-strong); font-weight: 600; font-size: 0.78rem; }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1rem; }
.stat-number { font-size: 1.6rem; font-family: "JetBrains Mono", monospace; color: var(--accent); margin-bottom: 0.2rem; font-weight: 600; }
.stat-label { font-size: 0.72rem; color: var(--dim); text-transform: uppercase; letter-spacing: 0.1em; }

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; }
  .hero-card h1 { font-size: 1.8rem; }
}

/* ---------- interactive terminal widget ---------- */
.terminal-widget {
  background: #010409;
  border: 1px solid var(--border);
  border-radius: 10px;
  margin: 1rem 0 2.5rem;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.88rem;
  box-shadow: 0 8px 30px var(--shadow);
  overflow: hidden;
}
.terminal-titlebar {
  background: var(--bg-raised);
  border-bottom: 1px solid var(--border);
  padding: 0.5rem 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  color: var(--dim);
}
.terminal-dots { display: inline-flex; gap: 0.35rem; margin-right: 0.6rem; }
.terminal-dots span {
  width: 11px; height: 11px; border-radius: 50%;
}
.terminal-dots span:nth-child(1) { background: #ff5f56; }
.terminal-dots span:nth-child(2) { background: #ffbd2e; }
.terminal-dots span:nth-child(3) { background: #27c93f; }
.terminal-title { flex: 1; text-align: center; }
.terminal-hint { color: var(--dim); font-size: 0.72rem; }

.terminal-body {
  padding: 1rem 1.1rem;
  height: 280px;
  overflow-y: auto;
  color: var(--ink);
  line-height: 1.55;
}
.terminal-body::-webkit-scrollbar { width: 8px; }
.terminal-body::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

.term-line { white-space: pre-wrap; word-break: break-word; margin: 0; }
.term-line.cmd { color: var(--ink); }
.term-line.cmd .prompt { color: var(--accent); margin-right: 0.4em; }
.term-line.out { color: var(--muted); }
.term-line.ok { color: var(--accent); }
.term-line.warn { color: var(--accent-warn); }
.term-line.err { color: var(--accent-err); }
.term-line.hdr { color: var(--accent-strong); font-weight: 600; }
.term-line a { color: var(--accent-strong); }

.term-input-row {
  display: flex;
  align-items: center;
  padding: 0.6rem 1.1rem 0.9rem;
  border-top: 1px solid var(--border);
  background: var(--bg-soft);
}
.term-prompt { color: var(--accent); margin-right: 0.5em; user-select: none; }
.term-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--ink);
  font-family: inherit;
  font-size: inherit;
  caret-color: var(--accent);
}
