/* Ghid NexiBook — PRINT-ONLY stylesheet.
   Linked with media="print" from guide-template.html; the browser/screen
   rendering of index.html never loads this file, only ghid-style.css does
   (linked media="screen"). This file is what wkhtmltopdf reads when
   /opt/scripts/regenerate-studio-start-guides.sh's consumers render the PDF
   with `--print-media-type` (see Ghid-NexiBook-Configurare-Studio.pdf).

   Split out 2026-08-31 from the old combined ghid-style.css, which was this
   exact print stylesheet being reused on screen — hence the guide looking
   like a different product from nexigrow's "hârtie" pages. Content below is
   carried over unchanged except one thing removed: the old `@media screen`
   mobile-padding tweak, which was a screen concern misplaced in the print
   file — screen/mobile is now ghid-style.css's job (.pg-wrap + its own
   @media (max-width:640px) block), modelled on nexigrow/ghid-style.css.

   Rules of the road, unchanged: wkhtmltopdf 0.12.6 bundles an old Qt WebKit
   engine (~2013 vintage) with NO support for CSS custom properties (var())
   and shaky-to-absent flexbox/grid support. So this file stays
   custom-property-free, flexbox-free, grid-free, block/inline-block/table
   layout only — plain hex colours, no var(--pg-*) tokens (those live only
   in ghid-style.css, which this engine never loads). @page sets size only;
   margins come from the wkhtmltopdf CLI flags, not from here.
*/

@page {
  size: A4;
  margin: 0;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "DejaVu Sans", Arial, sans-serif;
  font-size: 12.5pt;
  line-height: 1.5;
  color: #1a1a1a;
  background: #ffffff;
}

/* ---------- Cover / title ---------- */

h1 {
  font-size: 30pt;
  font-weight: 800;
  color: #1a1a1a;
  letter-spacing: -0.01em;
  margin: 0 0 6px 0;
  padding-bottom: 12px;
  border-bottom: 4px solid #c9a227;
}

h1 + h3 {
  margin-top: 10px;
}

/* ---------- Section headings ---------- */

h2 {
  page-break-before: always;
  page-break-inside: avoid;
  font-size: 20pt;
  font-weight: 800;
  color: #1a1a1a;
  margin: 0 0 14px 0;
  padding: 18px 0 10px 0;
  border-bottom: 3px solid #c9a227;
}

/* first h2 in the document (right after cover content) should not
   force a break before content that is already meant to start fresh —
   wkhtmltopdf still respects the rule below since the cover is on the
   same page as the title by construction (no h2 appears until section 1) */

h3 {
  font-size: 14pt;
  font-weight: 700;
  color: #8a7010;
  margin: 18px 0 8px 0;
  page-break-inside: avoid;
}

h1 ~ h3:first-of-type {
  font-size: 15pt;
  font-weight: 600;
  color: #5c5c63;
  text-transform: none;
  border: none;
  margin-top: 4px;
}

p {
  margin: 0 0 10px 0;
}

strong {
  color: #1a1a1a;
  font-weight: 700;
}

a {
  color: #8a7010;
  text-decoration: underline;
}

hr {
  border: none;
  border-top: 1px solid #e8e8ea;
  margin: 22px 0;
}

/* ---------- Part label (small marker inside a section, right after h2) ---------- */

.part-label {
  display: block;
  font-size: 10.5pt;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #8a7010;
  background: #fff8e1;
  border-left: 4px solid #c9a227;
  padding: 6px 12px;
  margin: 0 0 16px 0;
}

/* ---------- Lists ---------- */

ul, ol {
  margin: 0 0 12px 0;
  padding-left: 1.4rem;
}

li {
  margin-bottom: 6px;
  page-break-inside: avoid;
}

ol > li {
  padding-left: 2px;
}

/* ---------- Images ---------- */

img {
  page-break-inside: avoid;
  border: 1px solid #ddd;
}

img.phone {
  max-width: 190px;
  max-height: 120mm;
  display: block;
  margin: 10px auto;
  border: 1px solid #ddd;
  border-radius: 10px;
}

img.wide {
  max-width: 100%;
  max-height: 130mm;
  display: block;
  margin: 10px auto;
  border: 1px solid #ddd;
}

figure {
  margin: 10px 0;
  page-break-inside: avoid;
  text-align: center;
}

figcaption {
  font-size: 10.5pt;
  color: #5c5c63;
  margin-top: 6px;
}

/* ---------- Callout boxes (blockquotes) ---------- */

/* Default callout: info / tip / "Regula de aur" boxes (💡, 💻, and the
   plain '> **Regula de aur:**' markdown blockquotes) — warm gold theme,
   matching the NexiBook brand accent used across the app. */
blockquote {
  page-break-inside: avoid;
  margin: 14px 0;
  padding: 12px 16px;
  background: #fff8e1;
  border-left: 5px solid #c9a227;
  border-radius: 4px;
}

blockquote p {
  margin: 0;
}

/* Warning boxes (⚠️): written as raw HTML <blockquote class="warning"> in
   the markdown source, since plain CSS cannot select by text content. */
blockquote.warning {
  background: #fdecec;
  border-left-color: #c0392b;
}

/* ---------- Tables (the test-card table, and any other table) ---------- */

table {
  page-break-inside: avoid;
  width: 100%;
  border-collapse: collapse;
  margin: 14px 0;
  border: 2px solid #c9a227;
}

thead th {
  background: #c9a227;
  color: #ffffff;
  font-size: 12pt;
  font-weight: 700;
  text-align: left;
  padding: 10px 14px;
  border: 1px solid #c9a227;
}

td {
  font-size: 13pt;
  padding: 10px 14px;
  border: 1px solid #e8e8ea;
  vertical-align: middle;
}

tr:nth-child(even) td {
  background: #fbf7ea;
}

td code {
  font-family: "DejaVu Sans Mono", Consolas, monospace;
  font-size: 13pt;
  font-weight: 700;
  color: #1a1a1a;
  background: #f0f0f2;
  padding: 2px 6px;
  border-radius: 4px;
}

code {
  font-family: "DejaVu Sans Mono", Consolas, monospace;
  background: #f0f0f2;
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 0.95em;
}

/* ---------- Checklist (section 13 uses literal "- ☐ " list items, not gfm task lists) ---------- */

li {
  font-size: 12.5pt;
}
