/* Portada: versión "Logros". Tokens y cabecera/pie compartidos con el blog (blog.css se apoya en esta hoja). */

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

:root {
  --paper: #f4f4f2;
  --card: #ffffff;
  --ink: #1a1a1a;
  --ink-2: #44443f;
  --muted: #66665f;
  --line: #d9d9d4;
  --accent: #b3410e;
  --accent-ink: #8f3309;
  --term-bg: #0b0f14;
  --term-line: #3b2f6b;
  --term-text: #c9d1dc;
  --term-accent: #b49cff;
  --font: 'Manrope', 'Segoe UI', system-ui, Arial, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, Menlo, Consolas, monospace;
  --r: 8px;
  --gutter: clamp(16px, 4vw, 64px);
}

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font);
  background: var(--paper);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.55;
  min-height: 100vh;
  overflow-x: hidden;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

h1, h2, h3 { line-height: 1.15; }
h2 { font-size: 1.35rem; font-weight: 700; margin-bottom: 14px; }
ul { padding-left: 18px; }
li { margin-bottom: 4px; }

.skip-link { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 12px; border-radius: 6px; z-index: 10; }
.skip-link:focus { left: 8px; }

.wrap { max-width: 1312px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

/* Cabecera */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding-top: 18px; padding-bottom: 18px;
}
.top .name { font-weight: 700; color: var(--ink); }
.top nav { display: flex; gap: 10px; flex-wrap: wrap; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 8px 16px; border-radius: 6px;
  font: inherit; font-weight: 600; font-size: 14px; cursor: pointer;
  background: var(--ink); color: #fff; border: 1px solid var(--ink);
}
.btn:hover { text-decoration: none; background: #000; }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: rgba(0,0,0,0.05); }

/* Hero */
.hero { display: flex; gap: 40px; align-items: flex-start; padding-top: 40px; }
.hero img { width: 150px; height: 150px; object-fit: cover; border-radius: 10px; flex-shrink: 0; }
.hero .kicker { font-size: 15px; font-weight: 600; color: var(--accent); margin-bottom: 10px; }
.hero h1 {
  font-size: clamp(1.9rem, 3.2vw, 2.6rem); font-weight: 800; letter-spacing: -0.02em;
  max-width: 24ch; text-wrap: balance;
}
.hero .lead { font-size: 16px; color: var(--ink-2); max-width: 70ch; margin-top: 10px; }

/* Reclamo SignalFractureCore */
.sfc-call {
  margin-top: 36px;
  background: var(--term-bg); color: var(--term-text);
  border: 1px solid var(--term-line); border-radius: var(--r);
  padding: 22px 26px;
  display: grid; grid-template-columns: 1fr auto; gap: 18px 32px; align-items: center;
  font-family: var(--mono);
}
.sfc-call .prompt { font-size: 15px; display: flex; gap: 10px; align-items: baseline; min-height: 24px; }
.sfc-call .prompt .caret { color: var(--term-accent); font-weight: 700; }
.sfc-call .prompt .typed::after {
  content: ""; display: inline-block; width: 9px; height: 17px; margin-left: 3px; vertical-align: -3px;
  background: var(--term-accent); animation: blink 1.1s steps(1) infinite;
}
.sfc-call .pitch { font-family: var(--font); font-size: 17px; color: #eef2f7; margin-top: 10px; max-width: 60ch; }
.sfc-call .pitch strong { color: var(--term-accent); }
.sfc-call .go {
  font-family: var(--font); background: var(--term-accent); color: #0b0f14; border-color: var(--term-accent);
  white-space: nowrap;
}
.sfc-call .go:hover { background: #c9b8ff; }
.sfc-call .go .hint { font-weight: 500; opacity: 0.8; }
@keyframes blink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .sfc-call .prompt .typed::after { animation: none; } }

/* Cifras */
.facts {
  margin-top: 36px;
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 20px;
}
.facts .n { font-size: 2.4rem; font-weight: 800; line-height: 1; letter-spacing: -0.02em; }
.facts .n em { font-style: normal; color: var(--accent); }
.facts .l { font-size: 13.5px; color: var(--muted); margin-top: 6px; }

/* Cuerpo */
.body { margin-top: 44px; display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 48px; }

.job { display: grid; grid-template-columns: 200px 1fr; gap: 6px 28px; padding: 18px 0; border-top: 1px solid var(--line); }
.job:last-child { border-bottom: 1px solid var(--line); }
.job h3 { font-size: 15.5px; font-weight: 700; }
.job .d { color: var(--muted); font-size: 13.5px; display: block; margin-top: 2px; }
.job ul { margin-top: 2px; }
.job .stack { font-size: 13px; color: var(--muted); margin-top: 8px; line-height: 1.5; }

.profile { margin-bottom: 36px; }
.profile p { max-width: 78ch; }
.profile p + p { margin-top: 10px; }
.skills p { font-size: 14px; line-height: 1.6; }
.skills p + p { margin-top: 8px; }
.pubs { font-size: 14px; line-height: 1.6; padding-left: 18px; }
.pubs li { margin-bottom: 8px; }

.aside { display: flex; flex-direction: column; gap: 28px; }
.why { background: var(--card); border-radius: 10px; padding: 22px 24px; }
.why h2 { margin-bottom: 8px; }
.why p { font-size: 14.5px; margin-top: 8px; }
.aside p.list { font-size: 14px; line-height: 1.7; }

/* Pie */
footer.foot { margin-top: 56px; padding-top: 22px; padding-bottom: 40px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13.5px; display: flex; gap: 16px; flex-wrap: wrap; justify-content: space-between; }

/* Responsive */
@media (max-width: 980px) {
  .body { grid-template-columns: 1fr; gap: 36px; }
  .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .hero { flex-direction: column; gap: 20px; padding-top: 24px; }
  .hero img { width: 110px; height: 110px; }
  .sfc-call { grid-template-columns: 1fr; padding: 18px; }
  .sfc-call .go { width: 100%; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .facts .n { font-size: 2rem; }
  .job { grid-template-columns: 1fr; gap: 4px; }
  .top nav .btn { padding: 8px 12px; }
}

/* Impresión: una columna, sin reclamo ni botones. Es el PDF que lee un ATS. */
@media print {
  @page { margin: 16mm; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .wrap { max-width: none; padding: 0; }
  .top nav, .sfc-call, .skip-link, footer.foot, .hero img { display: none !important; }
  .top { padding: 0 0 6pt 0; }
  .hero { padding-top: 6pt; gap: 0; }
  .hero h1 { font-size: 18pt; max-width: none; }
  .print-contact { display: block !important; font-size: 10pt; color: #333; margin-top: 6pt; }
  .facts { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10pt; margin-top: 12pt; }
  .job .stack { font-size: 9.5pt; color: #333; }
  .facts .n { font-size: 16pt; }
  .body { grid-template-columns: 1fr; gap: 14pt; margin-top: 14pt; }
  .job { grid-template-columns: 1fr; gap: 2pt; padding: 8pt 0; break-inside: avoid; }
  .why { background: none; padding: 0; }
  a { color: #000; }
  h2 { font-size: 13pt; margin-bottom: 6pt; }
}
.print-contact { display: none; }
