/* ==========================================================================
   resume.css — layout for resume.html only.
   Design tokens, fonts, .btn and .footer come from styles.css, loaded first.
   The page is generated by ../../resume/build_resume.js; this file is not.
   ========================================================================== */

.resume-page { background: var(--surface-2); }

/* --------------------------------------------------------------------------
   Top bar
   -------------------------------------------------------------------------- */
.rs-bar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .93); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.rs-bar__inner {
  width: min(100% - 2.5rem, 860px); margin-inline: auto;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  min-height: 60px;
}
.rs-back {
  display: inline-flex; align-items: center; gap: .45rem;
  font-size: .88rem; font-weight: 600; color: var(--ink-2);
}
.rs-back:hover { color: var(--accent-deep); text-decoration: none; }

/* --------------------------------------------------------------------------
   The sheet
   -------------------------------------------------------------------------- */
.rs-sheet {
  width: min(100% - 2.5rem, 860px);
  margin: clamp(1.5rem, 4vw, 2.75rem) auto clamp(2.5rem, 5vw, 4rem);
  padding: clamp(1.75rem, 5vw, 3.25rem);
  background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: var(--shadow);
}

/* --------------------------------------------------------------------------
   Header block
   -------------------------------------------------------------------------- */
.rs-head { text-align: center; padding-bottom: 1.1rem; border-bottom: 2px solid var(--line); }
.rs-head h1 {
  font-size: clamp(1.55rem, 4.4vw, 2.1rem); letter-spacing: .04em;
  margin: 0 0 .35rem;
}
.rs-title { font-size: clamp(.98rem, 2.2vw, 1.08rem); color: var(--ink-2); margin: 0 0 .3rem; font-weight: 500; }
.rs-loc, .rs-contact { font-size: .88rem; color: var(--ink-3); margin: 0 0 .25rem; }
.rs-contact { margin-top: .5rem; word-break: break-word; }
.rs-contact a { color: var(--ink-2); }
.rs-contact a:hover { color: var(--accent-deep); }
.sep { color: var(--line); padding: 0 .2rem; }

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */
.rs { margin-top: clamp(1.4rem, 3vw, 1.9rem); }
.rs > h2 {
  font-size: .82rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent-deep);
  margin: 0 0 .8rem; padding-bottom: .35rem; border-bottom: 1px solid var(--line);
}
.rs p { font-size: .93rem; margin: 0 0 .6rem; }
.rs-summary { text-align: justify; hyphens: auto; text-wrap: pretty; }

/* Competency chips — the ATS keyword block, readable rather than a wall of text */
.rs-tags { display: flex; flex-wrap: wrap; gap: .4rem; }
.rs-tags li {
  font-size: .78rem; font-weight: 500;
  padding: .25rem .62rem; border-radius: 5px;
  background: var(--accent-wash); color: var(--accent-deep); border: 1px solid #bce6f2;
}

/* Label / value pairs: skills and certifications */
.rs-defs { margin: 0; display: grid; grid-template-columns: minmax(160px, 210px) 1fr; gap: .4rem 1.1rem; }
.rs-defs dt { font-size: .88rem; font-weight: 700; color: var(--ink); }
.rs-defs dd { font-size: .9rem; margin: 0; color: var(--ink-2); }

/* Job and school entries */
.rs-entry { margin-top: 1.1rem; }
.rs-entry:first-of-type { margin-top: 0; }
.rs-entry h3 { font-size: 1.02rem; margin: 0 0 .15rem; }
.rs-role { font-family: var(--font-body); font-weight: 500; color: var(--ink-2); }
.rs-role::before { content: "· "; color: var(--ink-3); }
.rs-meta { font-size: .82rem; font-style: italic; color: var(--ink-3); margin: 0 0 .5rem; }

.rs-list { margin: 0 0 .2rem; }
.rs-list li {
  position: relative; padding-left: 1.05rem; margin-bottom: .42rem;
  font-size: .91rem; line-height: 1.62; text-align: justify; hyphens: auto; text-wrap: pretty;
}
.rs-list li::before {
  content: ""; position: absolute; left: .1rem; top: .62em;
  width: 5px; height: 5px; border-radius: 50%; background: var(--accent);
}
.rs-list strong { color: var(--ink); }

.rs-updated {
  margin: 2rem 0 0; padding-top: 1rem; border-top: 1px solid var(--line);
  font-size: .82rem; color: var(--ink-3); text-align: center;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 620px) {
  .rs-defs { grid-template-columns: 1fr; gap: .1rem; }
  .rs-defs dd { margin-bottom: .55rem; }
  .rs-summary, .rs-list li { text-align: left; }
  .rs-bar__inner { min-height: 54px; }
}

/* --------------------------------------------------------------------------
   Print — Ctrl+P gives a clean sheet with no bar and no footer.
   For the ATS-optimised document use the PDF; this is a convenience print.
   -------------------------------------------------------------------------- */
@media print {
  .rs-bar, .footer, .skip-link, .rs-updated { display: none !important; }
  .resume-page { background: #fff; }
  .rs-sheet {
    width: auto; margin: 0; padding: 0;
    border: 0; border-radius: 0; box-shadow: none;
  }
  .rs { margin-top: 1.1rem; break-inside: avoid; }
  .rs-entry, .rs-list li { break-inside: avoid; }
  .rs > h2 { color: #000; }
  .rs-tags li { background: none; border-color: #bbb; color: #000; }
  .rs-contact a { color: #000; text-decoration: none; }
  a[href^="http"]::after, a[href^="mailto"]::after { content: ""; }
  @page { margin: 12mm; }
}

/* Barra del CV: enlace al otro idioma + boton de descarga, juntos a la derecha. */
.rs-bar__right { display: flex; align-items: center; gap: clamp(.6rem, 2vw, 1.1rem); }
@media (max-width: 460px) { .rs-bar__right { gap: .55rem; } }
