/* cristisoare.ro — public site
   No external fonts or libraries: system font stacks only. */

:root {
  --bg: #0a0d12;
  --bg-2: #0d1218;
  --panel: #111821;
  --line: #1e2734;
  --line-2: #2b3747;
  --text: #e2e8f0;
  --soft: #b8c2d0;
  --muted: #8d9aae;
  --dim: #5b687c;
  --green: #56e39f;
  --green-ink: #06281a;
  --amber: #f2b84b;
  --blue: #6cb6ff;
  --red: #ff6b6b;
  --grid: 32px;
  --mono: ui-monospace, "Cascadia Code", "JetBrains Mono", "SF Mono", Menlo, Consolas, "Liberation Mono", "DejaVu Sans Mono", monospace;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Rack-panel dot grid plus two soft light sources. The canvas draws packets on the same grid. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(60rem 40rem at 85% -10%, rgba(86, 227, 159, .09), transparent 60%),
    radial-gradient(50rem 36rem at -10% 60%, rgba(108, 182, 255, .07), transparent 60%),
    radial-gradient(circle at 1px 1px, rgba(255, 255, 255, .055) 1px, transparent 1.5px) 0 0 / var(--grid) var(--grid);
}

.bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--green); color: var(--green-ink); }

:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  width: min(1120px, 100% - 40px);
  margin-inline: auto;
}

.mono { font-family: var(--mono); }
.ico { width: 1em; height: 1em; flex: none; }

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: 8px;
  background: var(--green);
  color: var(--green-ink);
  font-weight: 600;
  text-decoration: none;
}
.skip:focus { top: 12px; }

/* ── Status bar (tmux) ───────────────────────────────────────────────────── */

.bar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 18px;
  height: 44px;
  padding: 0 max(20px, calc((100% - 1120px) / 2));
  background: rgba(10, 13, 18, .8);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  backdrop-filter: blur(12px) saturate(140%);
  border-bottom: 1px solid var(--line);
  font: 500 .8rem/1 var(--mono);
  white-space: nowrap;
}

.bar-session {
  color: var(--green);
  text-decoration: none;
  font-weight: 700;
}

.bar-nav {
  display: flex;
  gap: 4px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.bar-nav::-webkit-scrollbar { display: none; }

.bar-nav a {
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--muted);
  text-decoration: none;
  transition: color .2s, background-color .2s;
}
.bar-nav a:hover { color: var(--text); }
.bar-nav a.is-active { color: var(--green-ink); background: var(--green); }
.bar-nav a.is-active::after { content: "*"; }
.bar-idx { opacity: .65; }

.bar-right {
  margin-left: auto;
  color: var(--dim);
}

/* ── Prompt pieces ───────────────────────────────────────────────────────── */

.p-user { color: var(--green); }
.p-path { color: var(--blue); }
.p-cmd { color: var(--text); }

.caret {
  display: inline-block;
  width: .6em;
  height: 1.15em;
  margin-left: 2px;
  vertical-align: text-bottom;
  background: var(--green);
  animation: blink 1.1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ── Hero ────────────────────────────────────────────────────────────────── */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
  min-height: min(100vh, 900px);
  padding-block: 112px 64px;
}

/* Small screens only: the terminal (and its photo) sits below the fold there. */
.hero-avatar {
  display: none;
  width: 92px;
  height: 92px;
  margin-bottom: 22px;
  border: 1px solid var(--line-2);
  border-radius: 16px;
  object-fit: cover;
  box-shadow: 0 0 0 4px rgba(86, 227, 159, .12);
}

.prompt {
  margin-bottom: 18px;
  font: 500 .88rem/1.4 var(--mono);
  color: var(--muted);
}

h1 {
  font-size: clamp(2.7rem, 6.4vw, 4.7rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.roles {
  min-height: 1.6em;
  margin-top: 18px;
  font: 500 clamp(1rem, 1.6vw, 1.15rem)/1.6 var(--mono);
  color: var(--green);
}
.roles .caret { display: none; }
.js .roles .caret { display: inline-block; }

.bio {
  max-width: 60ch;
  margin-top: 22px;
  color: var(--soft);
  font-size: 1.02rem;
  text-wrap: pretty;
}

.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 40px;
  margin-top: 30px;
  padding-top: 26px;
  border-top: 1px dashed var(--line-2);
}
.stats div { display: flex; flex-direction: column; }
.stats dd {
  font: 700 2rem/1.1 var(--mono);
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}
.stats dt {
  order: 2;
  margin-top: 6px;
  font: 500 .72rem/1.3 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 32px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line-2);
  border-radius: 9px;
  background: rgba(17, 24, 33, .7);
  font: 600 .84rem/1 var(--mono);
  text-decoration: none;
  cursor: pointer;
  transition: border-color .2s, color .2s, background-color .2s, transform .2s var(--ease);
}
.btn:hover { border-color: var(--green); color: var(--green); transform: translateY(-2px); }
.btn-primary { border-color: var(--green); background: var(--green); color: var(--green-ink); }
.btn-primary:hover { background: #7cf0b9; color: var(--green-ink); }
.btn-icon { width: 42px; padding: 0; justify-content: center; font-size: 1.05rem; }

/* ── Terminal window ─────────────────────────────────────────────────────── */

.term {
  border: 1px solid var(--line-2);
  border-radius: 12px;
  background: var(--bg-2);
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .9), 0 0 0 1px rgba(255, 255, 255, .02), 0 0 90px -40px rgba(86, 227, 159, .35);
  overflow: hidden;
}

.term-bar {
  position: relative;
  display: flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  background: var(--panel);
}
.term-bar i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--line-2);
}
.term-bar i:nth-child(1) { background: #ff5f57; }
.term-bar i:nth-child(2) { background: #febc2e; }
.term-bar i:nth-child(3) { background: #28c840; }
.term-bar span {
  position: absolute;
  inset: 0 90px;
  display: grid;
  place-items: center;
  overflow: hidden;
  font: 500 .74rem/1 var(--mono);
  color: var(--muted);
  white-space: nowrap;
}

.term-body {
  padding: 18px 20px 20px;
  font: 400 .84rem/1.75 var(--mono);
}
.term-line { color: var(--muted); }

.fetch {
  display: grid;
  grid-template-columns: clamp(120px, 34%, 184px) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
  margin: 14px 0;
}

.fetch-photo {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--line-2);
  background: var(--panel);
}

.fetch-info { min-width: 0; }
.fetch-head { font-weight: 700; }
.fetch-rule {
  height: 1px;
  margin: 6px 0 8px;
  background: repeating-linear-gradient(90deg, var(--dim) 0 6px, transparent 6px 10px);
}
.fetch-row { display: flex; gap: 8px; line-height: 1.6; }
.fetch-row dt { flex: none; color: var(--green); font-weight: 700; }
.fetch-row dt::after { content: ":"; }
.fetch-row dd { min-width: 0; color: var(--soft); overflow-wrap: anywhere; }

.swatches { display: flex; gap: 0; margin-top: 12px; }
.swatches i { width: 26px; height: 14px; }
.swatches i:nth-child(1) { background: #1e2734; }
.swatches i:nth-child(2) { background: var(--red); }
.swatches i:nth-child(3) { background: var(--green); }
.swatches i:nth-child(4) { background: var(--amber); }
.swatches i:nth-child(5) { background: var(--blue); }
.swatches i:nth-child(6) { background: #c792ea; }
.swatches i:nth-child(7) { background: #5fd7d7; }
.swatches i:nth-child(8) { background: var(--text); }

.js [data-boot] .boot-item { opacity: 0; transform: translateY(5px); }
.js [data-boot].is-booted .boot-item {
  opacity: 1;
  transform: none;
  transition: opacity .35s ease, transform .35s var(--ease);
  transition-delay: calc(var(--i, 0) * 65ms);
}

/* ── Sections ────────────────────────────────────────────────────────────── */

.section { padding-block: clamp(64px, 9vw, 104px); }

.section-head { margin-bottom: 40px; }
.eyebrow {
  margin-bottom: 10px;
  font: 500 .82rem/1.4 var(--mono);
  color: var(--green);
  overflow-wrap: anywhere;
}
h2 {
  font-size: clamp(1.9rem, 3.8vw, 2.7rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -.03em;
}

.js .reveal { opacity: 0; transform: translateY(20px); }
.js .reveal.is-in {
  opacity: 1;
  transform: none;
  transition: opacity .6s ease, transform .6s var(--ease);
}

/* ── Timeline ────────────────────────────────────────────────────────────── */

.timeline {
  position: relative;
  padding-left: 40px;
}
.timeline::before,
.timeline::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 10px;
  width: 2px;
  border-radius: 2px;
}
.timeline::before { bottom: 0; background: var(--line); }
.timeline::after {
  height: calc((100% - 10px) * var(--progress, 0));
  background: linear-gradient(var(--green), rgba(86, 227, 159, .25));
  box-shadow: 0 0 12px rgba(86, 227, 159, .5);
}

.job { position: relative; }
.job + .job { margin-top: 28px; }

.job-node {
  position: absolute;
  left: -39px;
  top: 26px;
  z-index: 1;
  width: 14px;
  height: 14px;
  border: 2px solid var(--line-2);
  border-radius: 50%;
  background: var(--bg);
  transition: border-color .4s, background-color .4s;
}
.job.is-in .job-node { border-color: var(--green); }
.job.is-current .job-node { background: var(--green); border-color: var(--green); }
.job.is-current .job-node::after {
  content: "";
  position: absolute;
  inset: -6px;
  border: 2px solid var(--green);
  border-radius: 50%;
  animation: ping 2.2s var(--ease) infinite;
}
@keyframes ping {
  from { transform: scale(.6); opacity: .9; }
  to { transform: scale(1.5); opacity: 0; }
}

.job article,
.card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  transition: border-color .25s;
}
.job article { padding: 22px 26px 24px; }
.job article:hover,
.card:hover { border-color: var(--line-2); }

.job-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
  margin-bottom: 10px;
  font: 500 .76rem/1.5 var(--mono);
  color: var(--muted);
}
.job-meta span + span::before { content: "·"; margin: 0 9px; color: var(--dim); }
.job-status { color: var(--green); }
.job-note { color: var(--amber); }

h3 {
  font-size: 1.22rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -.01em;
}

.job-co {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 12px;
  margin-top: 4px;
  color: var(--amber);
  font-weight: 600;
}
.job-co a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.job-co a:hover { border-bottom-color: currentColor; }
.job-co .ico { font-size: .8em; opacity: .8; }
.job-loc { color: var(--muted); font-weight: 400; font-size: .92rem; }

.job-sum { margin-top: 14px; color: var(--soft); font-size: .96rem; }

.job-list {
  display: grid;
  gap: 7px;
  margin-top: 16px;
}
.job-list li {
  position: relative;
  padding-left: 20px;
  color: var(--soft);
  font-size: .95rem;
  line-height: 1.55;
}
.job-list li::before {
  content: "›";
  position: absolute;
  left: 3px;
  top: -.06em;
  color: var(--green);
  font: 700 1.05em/1.55 var(--mono);
}
.job-list.is-collapsed li:nth-child(n+7) { display: none; }

.more {
  margin-top: 12px;
  padding: 6px 0;
  border: 0;
  background: none;
  color: var(--green);
  font: 600 .8rem/1 var(--mono);
  cursor: pointer;
}
.more:hover { text-decoration: underline; }

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 18px;
}
.tags li {
  padding: 3px 9px;
  border: 1px solid var(--line-2);
  border-radius: 6px;
  color: var(--muted);
  font: 500 .74rem/1.5 var(--mono);
  transition: border-color .2s, color .2s;
}
.tags li:hover { border-color: var(--green); color: var(--green); }

/* ── Skills ──────────────────────────────────────────────────────────────── */

.skills-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 28px;
  align-items: start;
}

.meters { display: grid; gap: 13px; }
.meter {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 12px;
  align-items: baseline;
}
.meter-name { grid-area: 1 / 1; color: var(--text); }
.meter-val { grid-area: 1 / 2; color: var(--muted); font-variant-numeric: tabular-nums; }
.meter-bar {
  grid-area: 2 / 1 / 3 / -1;
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--dim);
}
.meter-bar::before { content: "["; }
.meter-bar::after { content: "]"; }
.meter-bar svg { flex: 1; width: 100%; height: 12px; }
.meter-bar line {
  stroke: var(--green);
  stroke-width: 2;
  stroke-dasharray: .85 .55;
}
.js .meter-bar svg { clip-path: inset(0 100% 0 0); }
.js .is-in .meter-bar svg {
  clip-path: inset(0);
  transition: clip-path 1.2s var(--ease);
  transition-delay: calc(var(--i, 0) * 70ms);
}

.keys {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.keys .card { padding: 18px 20px; }
.keys h3 { font-size: 1rem; }
.keys p { margin-top: 6px; color: var(--muted); font-size: .9rem; line-height: 1.55; }

/* Pointer-follow highlight; the position comes from site.js. */
.glow::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), rgba(86, 227, 159, .1), transparent 70%);
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
}
.glow:hover::before { opacity: 1; }

/* ── Profile cards ───────────────────────────────────────────────────────── */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(235px, 1fr));
  gap: 16px;
}
.cards .card { padding: 22px 24px 24px; }

.card-label {
  margin-bottom: 16px;
  font: 600 .72rem/1 var(--mono);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--green);
}

.plain { display: grid; gap: 16px; }
.plain li { display: grid; gap: 1px; }
.plain strong { font-weight: 650; }
.plain span { color: var(--muted); font-size: .92rem; }
.plain .mono { color: var(--amber); font-size: .78rem; margin-top: 3px; }

.pairs { display: grid; gap: 12px; }
.pairs li { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pill {
  padding: 2px 10px;
  border: 1px solid rgba(86, 227, 159, .3);
  border-radius: 20px;
  background: rgba(86, 227, 159, .08);
  color: var(--green);
  font: 500 .72rem/1.6 var(--mono);
}

.checks { display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 26px; }
.checks li::before {
  content: "[✓]";
  position: absolute;
  left: -2px;
  top: .2em;
  color: var(--green);
  font: 700 .74rem/1.65 var(--mono);
  letter-spacing: -.08em;
}
.cards .tags { margin-top: 0; }

/* ── Contact ─────────────────────────────────────────────────────────────── */

.contact-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 14px;
}
.contact-item {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 100%;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  text-decoration: none;
  transition: border-color .2s, transform .2s var(--ease);
}
a.contact-item:hover { border-color: var(--green); transform: translateY(-2px); }
.contact-item .ico {
  width: 40px;
  height: 40px;
  padding: 10px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  color: var(--green);
}
.contact-item span { display: grid; min-width: 0; }
.contact-item small {
  font: 500 .7rem/1.5 var(--mono);
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact-item b { font-weight: 600; overflow-wrap: anywhere; }

/* ── Footer ──────────────────────────────────────────────────────────────── */

.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-block: 28px 40px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font: 400 .78rem/1.5 var(--mono);
}

/* ── Small screens ───────────────────────────────────────────────────────── */

@media (max-width: 920px) {
  .hero { grid-template-columns: minmax(0, 1fr); min-height: 0; padding-top: 96px; }
  .hero-avatar { display: block; }
  .fetch { grid-template-columns: minmax(0, 1fr); }
  .fetch-photo { display: none; }
  .skills-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 760px) {
  .bar { gap: 8px; padding-inline: 14px; }
  .bar-right { display: none; }
}

@media (max-width: 560px) {
  .wrap { width: calc(100% - 32px); }
  .term-body { padding: 14px 14px 16px; font-size: .78rem; }
  .timeline { padding-left: 28px; }
  .timeline::before, .timeline::after { left: 4px; }
  .job-node { left: -30px; }
  .job article { padding: 18px 18px 20px; }
  .keys { grid-template-columns: minmax(0, 1fr); }
  .stats { gap: 14px 28px; }
  .stats dd { font-size: 1.7rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal, .js [data-boot] .boot-item { opacity: 1; transform: none; }
  .js .meter-bar svg { clip-path: none; }
}

/* ── Print: a clean paper CV ─────────────────────────────────────────────── */

@media print {
  :root {
    --bg: #fff; --bg-2: #fff; --panel: #fff;
    --line: #cfd4dc; --line-2: #b9c0cb;
    --text: #111; --soft: #222; --muted: #444; --dim: #777;
    --green: #0a6b3f; --amber: #7a4d00; --blue: #0b4f9c;
  }
  @page { margin: 14mm 13mm; }
  body { font-size: 10.5pt; line-height: 1.45; }
  body::before, .bg, .bar, .skip, .actions, .eyebrow, .prompt, .term-bar, .term-line, .hero-avatar,
  .swatches, .more, .caret, .job-node, .timeline::before, .timeline::after { display: none !important; }
  .wrap { width: 100%; }
  .hero { display: block; min-height: 0; padding: 0; }
  .hero-term { margin-top: 14px; }
  .term, .job article, .card, .contact-item { border-color: var(--line); background: none; box-shadow: none; }
  .fetch { grid-template-columns: 30mm 1fr; margin: 0; }
  .fetch-photo { display: block; }
  .term-body { padding: 10px 12px; font-size: 9pt; }
  h1 { font-size: 26pt; }
  h2 { font-size: 15pt; }
  h3 { font-size: 11.5pt; }
  .stats { margin-top: 10px; padding-top: 10px; }
  .stats dd { font-size: 14pt; }
  .section { padding-block: 16px 0; }
  .section-head { margin-bottom: 10px; }
  .timeline { padding-left: 0; }
  .job + .job { margin-top: 10px; }
  .job article { padding: 10px 12px; break-inside: avoid-page; }
  .job-list { gap: 2px; margin-top: 8px; }
  .job-list li { font-size: 9.5pt; }
  .job-list.is-collapsed li:nth-child(n+7) { display: list-item; display: block; }
  .tags { margin-top: 8px; gap: 4px; }
  .tags li { padding: 0 6px; font-size: 8pt; }
  .skills-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .keys { grid-template-columns: 1fr; gap: 6px; }
  .keys .card, .cards .card { padding: 8px 10px; break-inside: avoid; }
  .contact-item { padding: 8px 10px; }
  .contact-item .ico { width: 26px; height: 26px; padding: 5px; }
  .card, .contact-list li { break-inside: avoid; }
  .js .reveal, .js [data-boot] .boot-item { opacity: 1 !important; transform: none !important; }
  .js .meter-bar svg { clip-path: none !important; }
  .foot { padding-block: 12px 0; margin-top: 16px; }
  a { text-decoration: none; }
}
