/* ==========================================================================
   CV Styles — screen + print
   ========================================================================== */

:root {
  --cv-font-body: "Inter", system-ui, -apple-system, sans-serif;
  --cv-font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --cv-accent: #2563eb;
  --cv-accent-light: #dbeafe;
  --cv-text: #1e293b;
  --cv-text-muted: #64748b;
  --cv-border: #e2e8f0;
}

/* --- Screen layout --- */

article.cv {
  max-width: 760px;
  margin: 0 auto;
  padding: 2.5rem 2.5rem;
  font-family: var(--cv-font-body);
  font-size: 0.925rem;
  line-height: 1.6;
  color: var(--cv-text);
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
  border-radius: 4px;
  margin-top: 2rem;
  margin-bottom: 2rem;
}

/* Header */

article.cv .cv-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
  padding-bottom: 1.25rem;
  margin-bottom: 1.5rem;
  border-bottom: 3px solid var(--cv-accent);
}

article.cv .cv-name-title h1 {
  font-family: var(--cv-font-display);
  font-size: 2rem;
  font-weight: 700;
  margin: 0 0 0.3rem 0;
  letter-spacing: -0.02em;
  color: var(--cv-text);
  line-height: 1.2;
}

article.cv .cv-headline {
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--cv-text-muted);
  margin: 0;
}

article.cv .cv-contact {
  text-align: right;
  font-size: 0.82rem;
  line-height: 1.7;
  font-style: normal;
  white-space: nowrap;
  flex-shrink: 0;
}

article.cv .cv-contact-item {
  display: block;
}

article.cv .cv-contact a {
  color: var(--cv-accent);
  text-decoration: none;
  border-bottom: none;
}

article.cv .cv-contact a:hover {
  text-decoration: underline;
}

/* Body content */

article.cv .cv-body h2 {
  font-family: var(--cv-font-body) !important;
  font-size: 0.75rem !important;
  font-weight: 600 !important;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cv-accent) !important;
  border-bottom: 1px solid var(--cv-border);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  padding-left: 0.75rem;
  position: relative;
}

article.cv .cv-body h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--cv-accent);
  border-radius: 2px;
}

article.cv .cv-body h3 {
  font-family: var(--cv-font-body) !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  margin: 1.25rem 0 0.1rem 0;
  color: var(--cv-text);
}

article.cv .cv-body h4 {
  font-size: 0.85rem !important;
  font-weight: 500 !important;
  color: var(--cv-text-muted) !important;
  margin: 0 0 0.5rem 0;
  font-family: var(--cv-font-body) !important;
}

article.cv .cv-body ul {
  margin: 0.4rem 0 1rem 0;
  padding-left: 1.2rem;
}

article.cv .cv-body li {
  margin-bottom: 0.35rem;
  font-size: 0.925rem;
}

article.cv .cv-body li::marker {
  color: var(--cv-accent);
}

article.cv .cv-body p {
  margin: 0.4rem 0;
}

article.cv .cv-body strong {
  font-weight: 600;
  color: var(--cv-text);
}

/* Skills tags */

article.cv .cv-body .skills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  list-style: none;
  padding: 0;
  margin: 0.5rem 0;
}

article.cv .cv-body .skills li {
  background: var(--cv-accent-light) !important;
  color: #1e40af !important;
  padding: 0.2rem 0.65rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
  margin: 0;
}

/* Footer */

article.cv .cv-footer {
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--cv-border);
  font-size: 0.82rem;
  color: var(--cv-text-muted);
}

article.cv .cv-footer a {
  color: var(--cv-accent);
  text-decoration: none;
}

article.cv .cv-footer a:hover {
  text-decoration: underline;
}

article.cv .cv-variants a {
  margin-right: 0.8rem;
}

article.cv .cv-pdf-link {
  font-weight: 600;
}


/* ==========================================================================
   Print styles
   ========================================================================== */

@media print {
  @page {
    size: A4;
    margin: 15mm 18mm;
  }

  :root {
    --cv-accent: #1e40af;
  }

  body {
    font-size: 9.5pt !important;
    line-height: 1.4 !important;
  }

  article.cv {
    max-width: none;
    margin: 0;
    padding: 0;
    background: none;
    box-shadow: none;
    border-radius: 0;
  }

  header:not(.cv-header),
  nav,
  footer:not(.cv-footer),
  .sidebar,
  .no-print {
    display: none !important;
  }

  article.cv .cv-header {
    padding-bottom: 8pt;
    margin-bottom: 10pt;
    border-bottom-width: 2px;
  }

  article.cv .cv-name-title h1 {
    font-size: 16pt !important;
  }

  article.cv .cv-headline {
    font-size: 10pt;
  }

  article.cv .cv-contact {
    font-size: 8pt;
  }

  article.cv .cv-contact a {
    color: var(--cv-text) !important;
  }

  article.cv .cv-body h2 {
    font-size: 8pt !important;
    margin-top: 12pt;
    margin-bottom: 4pt;
    page-break-after: avoid;
  }

  article.cv .cv-body h3 {
    font-size: 9.5pt !important;
    page-break-after: avoid;
  }

  article.cv .cv-body h4 {
    font-size: 8.5pt !important;
  }

  article.cv .cv-body ul {
    margin: 2pt 0 6pt 0;
  }

  article.cv .cv-body li {
    margin-bottom: 1pt;
  }

  h2, h3, h4 {
    page-break-after: avoid;
  }

  li, p {
    orphans: 2;
    widows: 2;
  }

  a {
    color: var(--cv-text) !important;
    text-decoration: none !important;
  }

  article.cv .cv-contact a::after {
    content: none;
  }

  article.cv .cv-body .skills li {
    background: none !important;
    border: 1px solid #94a3b8;
    color: var(--cv-text) !important;
    font-size: 7.5pt;
    padding: 0.5pt 4pt;
  }
}
