/* CV viewer (EN and ES). Same system as the rest of the site: tokens, type, bar, footer. The sheet is paper: always white. */
@font-face { font-family: "Schibsted Grotesk"; src: url("/fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: "Spline Sans Mono"; src: url("/fonts/spline-sans-mono-latin-wght-normal.woff2") format("woff2"); font-weight: 300 700; font-display: swap; }

:root {
  --bg: #f6f7f8; --band: #ffffff; --ink: #0b0d10; --muted: #5b6570; --line: #dde1e5; --ctl-line: #7b868f;
  --text-2: #3d454e; --ok: #0f6c80; --solid-ink: #ffffff; --solid-hover: #22272d; --line-hover: #eceef0;
  --desk: #e9ecef; --sheet-shadow: 0 1px 2px rgb(11 13 16 / .08), 0 8px 28px rgb(11 13 16 / .08);
  --sans: "Schibsted Grotesk", ui-sans-serif, system-ui, sans-serif;
  --mono: "Spline Sans Mono", ui-monospace, Menlo, monospace;
  --ease: cubic-bezier(.23, 1, .32, 1);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0b0d10; --band: #0f1216; --ink: #e8ecef; --muted: #8f99a3; --line: #20262d; --ctl-line: #5e6872;
  --text-2: #b9c1c8; --ok: #7fd0e2; --solid-ink: #0b0d10; --solid-hover: #ffffff; --line-hover: #171b20;
  --desk: #07090b; --sheet-shadow: 0 0 0 1px rgb(255 255 255 / .06), 0 10px 32px rgb(0 0 0 / .5);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0d10; --band: #0f1216; --ink: #e8ecef; --muted: #8f99a3; --line: #20262d; --ctl-line: #5e6872;
    --text-2: #b9c1c8; --ok: #7fd0e2; --solid-ink: #0b0d10; --solid-hover: #ffffff; --line-hover: #171b20;
    --desk: #07090b; --sheet-shadow: 0 0 0 1px rgb(255 255 255 / .06), 0 10px 32px rgb(0 0 0 / .5);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; margin: 0; }
html { background: var(--bg); }
body { background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-underline-offset: .2em; text-decoration-thickness: 1px; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 3px; }
.wrap { width: min(1280px, 100% - 48px); margin-inline: auto; }
.mono { font-family: var(--mono); font-size: .75rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* bar: identical to the other pages */
.bar { display: flex; align-items: center; gap: 28px; height: 60px; }
.bar .mark { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; text-decoration: none; font-weight: 600; letter-spacing: -.01em; }
.bar .mark .logo { width: 21px; height: 21px; }
.bar ul { display: flex; gap: 24px; list-style: none; padding: 0; margin-left: auto; }
.bar ul a { color: var(--muted); text-decoration: none; font-size: .9375rem; transition: color .16s var(--ease); }
.bar ul a:hover { color: var(--ink); }
.logo { width: 1.25em; height: 1.25em; fill: currentColor; flex: none; }
.theme { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 999px; border: 1px solid var(--ctl-line); background: none; color: var(--ink); cursor: pointer; transition: transform .16s var(--ease), border-color .16s var(--ease); }
.theme:hover { border-color: var(--muted); }
.theme:active { transform: scale(.94); }
.theme svg { width: 18px; height: 18px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 10; background: var(--ink); color: var(--bg); padding: 10px 14px; border-radius: 6px; text-decoration: none; }
.skip:focus { top: 10px; }

/* viewer: toolbar on top, the desk with the sheets below. It fills the screen under the bar. */
.viewer { display: flex; flex-direction: column; height: calc(100dvh - 60px); border-top: 1px solid var(--line); }
.tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px 14px; padding: 8px 12px; background: var(--band); border-bottom: 1px solid var(--line); }
.grp { display: flex; align-items: center; gap: 2px; }
.grp + .grp { padding-left: 14px; border-left: 1px solid var(--line); }
.tb { min-width: 40px; height: 40px; display: inline-grid; place-items: center; padding: 0 8px; border: 0; border-radius: 8px; background: none; color: var(--ink); font: 500 .8125rem/1 var(--mono); text-decoration: none; cursor: pointer; transition: background-color .16s var(--ease), transform .16s var(--ease), opacity .16s var(--ease); }
.tb:hover { background: var(--line-hover); }
.tb:active { transform: scale(.94); }
.tb:disabled { opacity: .35; cursor: default; transform: none; background: none; }
.tb svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.tb[aria-pressed="true"] { background: var(--ink); color: var(--solid-ink); }
.tb[aria-pressed="true"]:hover { background: var(--solid-hover); }
.tb.level { min-width: 58px; font-variant-numeric: tabular-nums; }
.pg { display: inline-flex; align-items: center; gap: 6px; padding: 0 4px; font: 500 .8125rem/1 var(--mono); color: var(--muted); font-variant-numeric: tabular-nums; }
.pg input { width: 3.2ch; height: 32px; padding: 0 4px; text-align: center; border: 1px solid var(--ctl-line); border-radius: 6px; background: var(--bg); color: var(--ink); font: inherit; -moz-appearance: textfield; }
.pg input::-webkit-inner-spin-button, .pg input::-webkit-outer-spin-button { -webkit-appearance: none; }
.seg { display: inline-flex; padding: 2px; border: 1px solid var(--ctl-line); border-radius: 10px; gap: 2px; }
.seg .tb { height: 34px; min-width: 40px; border-radius: 7px; }
.tb.dl { gap: 6px; grid-auto-flow: column; }

.stage { position: relative; flex: 1; min-height: 0; overflow: auto; background: var(--desk); overscroll-behavior: contain; touch-action: pan-x pan-y; outline-offset: -3px; }
.stage.hand { cursor: grab; }
.stage.hand.grabbing { cursor: grabbing; }
.stage.hand .textLayer, .stage.hand .textLayer span { cursor: inherit; -webkit-user-select: none; user-select: none; }
.pages { --total-scale-factor: 1; display: flex; flex-direction: column; align-items: center; gap: 20px; width: max-content; min-width: 100%; padding: 24px 24px 48px; }
.page { --scale-round-x: 1px; --scale-round-y: 1px; position: relative; flex: none; width: calc(var(--total-scale-factor) * var(--pw)); height: calc(var(--total-scale-factor) * var(--ph)); background: #fff; box-shadow: var(--sheet-shadow); border-radius: 2px; overflow: hidden; }
.page canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.status { position: absolute; inset: 0; display: grid; place-content: center; gap: 8px; padding: 24px; text-align: center; color: var(--muted); font: 500 .8125rem/1.5 var(--mono); }
.status[hidden] { display: none; }

/* PDF.js text layer (from pdf_viewer.css 6.5.438, trimmed to what this page uses) */
.textLayer { color-scheme: only light; position: absolute; text-align: initial; inset: 0; overflow: clip; opacity: 1; line-height: 1; letter-spacing: normal; word-spacing: normal; text-size-adjust: none; -webkit-text-size-adjust: none; forced-color-adjust: none; transform-origin: 0 0; caret-color: CanvasText; z-index: 0;
  --min-font-size: 1; --text-scale-factor: calc(var(--total-scale-factor) * var(--min-font-size)); --min-font-size-inv: calc(1 / var(--min-font-size)); }
.textLayer :is(span, br) { color: transparent; position: absolute; white-space: pre; cursor: text; transform-origin: 0% 0%; -webkit-user-select: text; user-select: text; }
.textLayer > :not(.markedContent), .textLayer .markedContent span:not(.markedContent) { z-index: 1; --font-height: 0; font-size: calc(var(--text-scale-factor) * var(--font-height)); --scale-x: 1; --rotate: 0deg; transform: rotate(var(--rotate)) scaleX(var(--scale-x)) scale(var(--min-font-size-inv)); }
.textLayer .markedContent { display: contents; }
.textLayer ::selection { background: color-mix(in srgb, #0f6c80, transparent 70%); color: transparent; }
.textLayer br::selection { background: transparent; }
.textLayer .endOfContent { display: block; position: absolute; inset: 100% 0 0; z-index: 0; cursor: default; user-select: none; }

/* Keywords: on paper, so the accent is the light one in both themes. Only transform and opacity move. */
.textLayer mark.kw { position: relative; display: inline; color: transparent; background: none; --kw: #0f6c80; }
.textLayer mark.kw::before, .textLayer mark.kw::after { content: ""; position: absolute; pointer-events: none; }
.textLayer mark.kw::before { inset: -.12em -.18em; border-radius: .22em; background: color-mix(in srgb, var(--kw), transparent 78%); opacity: 0; transform: scale(.9); }
.textLayer mark.kw::after { left: 0; right: 0; bottom: -.06em; height: max(1px, .085em); border-radius: 1px; background: var(--kw); opacity: .7; transform-origin: 0 50%; transform: scaleX(0); }
/* The key button: each press, the keywords in view pulse twice and their underline flashes, then everything fades. */
@media (prefers-reduced-motion: no-preference) {
  .page.beat mark.kw::before { animation: kw-beat .62s var(--ease) 2 both; }
  .page.beat mark.kw::after { animation: kw-flash 2.4s var(--ease) both; }
}
@media (prefers-reduced-motion: reduce) {
  .page.beat mark.kw::after { transform: scaleX(1); }
}
@keyframes kw-beat { 0% { opacity: 0; transform: scale(.9); } 40% { opacity: 1; transform: scale(1.06); } 100% { opacity: 0; transform: scale(1); } }
@keyframes kw-flash { 0% { transform: scaleX(0); opacity: .7; } 25% { transform: scaleX(1); opacity: .7; } 75% { transform: scaleX(1); opacity: .7; } 100% { transform: scaleX(1); opacity: 0; } }

footer { border-top: 1px solid var(--line); padding: 24px 0 40px; color: var(--muted); }
.foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 24px; }
.foot .c { display: inline-flex; align-items: center; gap: 8px; }
.foot .logo { width: 16px; height: 16px; }
.fallback { margin-top: 6px; }

@media (max-width: 1080px) { .bar ul { display: none; } .bar .theme { margin-left: auto; } }
@media (max-width: 720px) {
  .wrap { width: min(1280px, 100% - 32px); }
  .tools { gap: 4px 8px; padding: 6px 8px; }
  .grp + .grp { padding-left: 8px; }
  .grp.lang-grp { order: -1; }
  .tb { min-width: 38px; padding: 0 6px; }
  .tb.level { min-width: 50px; }
  .tb.dl .t { display: none; }
  .pages { padding: 12px 8px 32px; gap: 12px; }
}
@media (max-width: 720px) and (pointer: coarse) { .tb.pan { display: none; } }
@media (prefers-reduced-motion: reduce) {
  .tb, .theme { transition: none; }
}

/* Phone (Gus, 11/11/2026): only page, key and «⋯»; the rest unfolds from «⋯». */
.tb.more { display: none; }
@media (max-width: 720px) {
  .tb.more { display: inline-grid; }
  .tools:not(.open) .x-zoom, .tools:not(.open) .x-lang, .tools:not(.open) .x-dl { display: none; }
  .tools.open .x-zoom, .tools.open .x-lang { flex-basis: 100%; justify-content: center; padding-left: 0; border-left: 0; padding-top: 6px; border-top: 1px solid var(--line); }
  .tools > .grp:first-child { order: 0; }
  .tools .x-key { order: 1; }
  .tools .tb.more { order: 2; }
  .tools .x-zoom { order: 3; }
  .tools .x-lang { order: 4; }
  .tb.more[aria-expanded="true"] { background: color-mix(in srgb, var(--ink), transparent 88%); }
}
