/* The Pocket HR - blog styles. Self-contained; does not affect the 6 core pages.
   Design tokens copied from the main site so the blog matches visually. */

:root {
  --cream: #FAF6EC;
  --cream-deep: #F1E7CE;
  --ink: #263149;
  --ink-soft: #445068;
  --gold: #BC9A46;
  --gold-deep: #9C7E33;
  --sage: #71805C;
  --sage-deep: #4E5B3E;
  --terra: #A85C36;
  --white: #FFFFFF;
  --muted: #5F6370;
  --border: #E7DCC1;
}

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

body {
  font-family: 'DM Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--sage-deep); }

/* --- Nav (matches main site) --- */
nav#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 1rem 2.5rem;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap;
  background: var(--ink);
}
.nav-brand { display: flex; align-items: center; gap: .75rem; }
.nav-brand img { height: 64px; width: auto; display: block; }
.nav-links { display: flex; align-items: center; gap: 2.1rem; list-style: none; }
.nav-links a { text-decoration: none; font-size: .92rem; color: var(--white); opacity: .78; font-weight: 500; }
.nav-links a:hover { opacity: 1; }
.nav-cta {
  background: var(--gold); color: var(--ink) !important; opacity: 1 !important;
  padding: .68rem 1.4rem; border-radius: 3px; font-weight: 700 !important; font-size: .88rem !important;
}
.nav-cta:hover { background: var(--sage-deep); color: var(--white) !important; }
.nav-mobile-cta { display: none; }
.nav-toggle { display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 34px; height: 34px; background: none; border: none; cursor: pointer; padding: 0; }
.nav-toggle span { display: block; width: 100%; height: 2px; background: var(--white); border-radius: 2px;
  transition: transform .25s ease, opacity .25s ease; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 1100px) {
  nav#navbar { padding: .8rem 1.3rem; }
  .nav-brand img { height: 50px; }
  .nav-toggle { display: flex; order: 3; }
  .nav-mobile-cta {
    order: 2; display: inline-flex; align-items: center; background: var(--gold); color: var(--ink);
    text-decoration: none; padding: .55rem 1.05rem; border-radius: 3px; font-weight: 700; font-size: .82rem; white-space: nowrap;
  }
  .nav-links {
    order: 4; flex-basis: 100%; flex-direction: column; align-items: stretch; gap: 0;
    max-height: 0; overflow: hidden; opacity: 0; transition: max-height .3s ease, opacity .25s ease;
  }
  .nav-links.open { max-height: 75vh; opacity: 1; overflow-y: auto; margin-top: 1rem; padding-top: .6rem;
    border-top: 1px solid rgba(255,255,255,.12); }
  .nav-links li { width: 100%; }
  .nav-links a { display: block; padding: .85rem .1rem; border-bottom: 1px solid rgba(255,255,255,.08); opacity: 1; }
  .nav-links .nav-cta { display: inline-block; width: auto; margin: .9rem .1rem .3rem; }
}

/* --- Article layout --- */
.article-wrap { max-width: 760px; margin: 0 auto; padding: 8.5rem 1.5rem 4rem; }
@media (max-width: 900px) { .article-wrap { padding-top: 6.5rem; } }

.crumbs { font-size: .82rem; color: var(--muted); margin-bottom: 1.8rem; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--gold-deep); }
.crumbs span { margin: 0 .35rem; }

.article-head { border-bottom: 1px solid var(--border); padding-bottom: 1.6rem; margin-bottom: 2.2rem; }
.article-head h1 {
  font-family: 'Playfair Display', Georgia, serif; font-weight: 700;
  font-size: clamp(2rem, 4.4vw, 2.9rem); line-height: 1.16; letter-spacing: -.015em; color: var(--ink);
  margin-bottom: .9rem;
}
.article-meta { font-size: .82rem; color: var(--muted); }

.article-body { font-size: 1.02rem; color: var(--ink-soft); }
.article-body > * + * { margin-top: 1.3rem; }
.article-body h2 {
  font-family: 'Playfair Display', Georgia, serif; font-weight: 600; font-size: 1.5rem;
  color: var(--ink); margin-top: 2.6rem; line-height: 1.25;
}
.article-body h3 { font-weight: 700; font-size: 1.12rem; color: var(--ink); margin-top: 1.9rem; }
.article-body ul, .article-body ol { padding-left: 1.4rem; }
.article-body li + li { margin-top: .5rem; }
.article-body a { color: var(--sage-deep); text-underline-offset: 2px; }
.article-body strong { color: var(--ink); }
.article-body blockquote {
  border-left: 3px solid var(--gold); padding-left: 1.1rem; color: var(--muted); font-style: italic;
}

.article-note {
  margin-top: 2.8rem; padding: 1.1rem 1.3rem; background: var(--cream-deep);
  border-radius: 8px; font-size: .86rem; color: var(--ink-soft);
}

.article-cta {
  margin-top: 2.4rem; padding: 1.9rem; background: var(--ink); color: var(--white); border-radius: 10px;
}
.article-cta h2 { font-family: 'Playfair Display', Georgia, serif; font-size: 1.35rem; margin-bottom: .6rem; color: var(--white); }
.article-cta p { font-size: .93rem; color: rgba(255,255,255,.8); }
.article-cta-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.2rem; }
.btn {
  display: inline-flex; align-items: center; text-decoration: none; padding: .85rem 1.5rem;
  font-size: .9rem; font-weight: 600; border-radius: 3px; transition: background .2s, transform .15s;
}
.btn-primary { background: var(--gold); color: var(--ink); }
.btn-primary:hover { background: #E4C878; transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--white); border: 1.5px solid rgba(255,255,255,.3); }
.btn-ghost:hover { border-color: var(--gold); }

/* --- Blog index --- */
.blog-index-head { margin-bottom: 2.6rem; }
.blog-index-head h1 {
  font-family: 'Playfair Display', Georgia, serif; font-weight: 700;
  font-size: clamp(2.2rem, 5vw, 3.2rem); color: var(--ink); margin-bottom: .8rem;
}
.blog-index-head p { color: var(--muted); font-size: 1rem; max-width: 620px; }
.blog-index-h2 { font-family: 'Playfair Display', Georgia, serif; font-weight: 600; font-size: 1.3rem; color: var(--ink); margin-bottom: 1.2rem; }
.post-list { list-style: none; }
.post-card + .post-card { margin-top: 1.1rem; }
.post-card a {
  display: block; padding: 1.5rem 1.6rem; background: var(--white); border: 1px solid var(--border);
  border-radius: 10px; text-decoration: none; transition: border-color .2s, transform .15s;
}
.post-card a:hover { border-color: var(--gold); transform: translateY(-2px); }
.post-card-date { display: block; font-size: .76rem; text-transform: uppercase; letter-spacing: .08em; color: var(--gold-deep); margin-bottom: .5rem; }
.post-card-title { display: block; font-family: 'Playfair Display', Georgia, serif; font-size: 1.28rem; color: var(--ink); margin-bottom: .45rem; line-height: 1.3; }
.post-card-desc { display: block; font-size: .92rem; color: var(--muted); }

/* --- Footer (matches main site) --- */
footer { background: var(--ink); color: rgba(255,255,255,.7); padding: 3.4rem 0 1.5rem; margin-top: 4rem; }
footer .wrap { max-width: 1180px; margin: 0 auto; padding: 0 2rem; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2.4rem; margin-bottom: 2.3rem; }
.footer-brand-row img { height: 40px; width: auto; }
.footer-desc { font-size: .88rem; max-width: 270px; margin-top: .9rem; }
.footer-col-title { font-size: .76rem; letter-spacing: .1em; text-transform: uppercase; color: var(--white); margin-bottom: .9rem; font-weight: 700; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: .55rem; font-size: .88rem; }
.footer-links a { text-decoration: none; color: rgba(255,255,255,.62); font-size: .88rem; }
.footer-links a:hover { color: #E4C878; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 1.4rem; font-size: .8rem; color: rgba(255,255,255,.75); text-align: center; }
.footer-bottom a { color: rgba(255,255,255,.75); }
.footer-insurance { display: flex; align-items: center; justify-content: center; gap: .6rem; padding-top: 1.8rem; }
.footer-insurance img { width: 42px; height: 42px; display: block; flex-shrink: 0; }
.footer-insurance span { font-size: .8rem; color: rgba(255,255,255,.7); }
@media (max-width: 760px) { .footer-top { grid-template-columns: 1fr 1fr; } }

/* --- Article extras: header image, Law / Good practice boxes, tables, checklist, sources --- */
.article-hero { margin: 0 0 1.75rem; }
.article-hero img { display: block; width: 100%; height: auto; border-radius: 12px; }
.article-hero figcaption { font-size: .8rem; color: #6e6350; margin-top: .5rem; }
.article-hero figcaption a { color: inherit; }
.callout { border-radius: 10px; padding: 1rem 1.25rem; margin: 1.25rem 0; border-left: 5px solid; }
.callout p { margin: .4rem 0; }
.callout ul { margin: .5rem 0 .5rem 1.1rem; }
.callout-label { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; padding: .2rem .55rem; border-radius: 4px; margin-bottom: .35rem; }
.callout-title { font-weight: 700; margin: .2rem 0 .4rem; }
.callout-law { background: #eef6ef; border-color: #2e7d4f; }
.callout-law .callout-label { background: #2e7d4f; color: #fff; }
.callout-good { background: #fdf5e6; border-color: #BC9A46; }
.callout-good .callout-label { background: #BC9A46; color: #263149; }
.callout .legal-basis { font-size: .88rem; color: #5D4930; }
.table-wrap { overflow-x: auto; margin: 1.25rem 0; }
.table-wrap table { width: 100%; border-collapse: collapse; font-size: .95rem; }
@media (max-width: 600px) { .table-wrap table { font-size: .88rem; } .table-wrap th, .table-wrap td { padding: .55rem .5rem; } }
:focus-visible { outline: 2px solid #263149; outline-offset: 3px; }
.table-wrap th, .table-wrap td { text-align: left; vertical-align: top; padding: .65rem .75rem; border-bottom: 1px solid #e6dcc6; }
.table-wrap th { background: #263149; color: #FAF6EC; font-weight: 600; }
.table-wrap tr:nth-child(even) td { background: #faf6ec; }
.checklist { list-style: none; padding-left: 0; }
.checklist li { position: relative; padding-left: 1.9rem; margin: .45rem 0; }
.checklist li::before { content: ""; position: absolute; left: 0; top: .2rem; width: 1.05rem; height: 1.05rem; border: 2px solid #BC9A46; border-radius: 4px; }
.article-sources { font-size: .9rem; }
.article-sources li { margin: .3rem 0; }
.source-type { color: #6B5D45; }

/* --- Author box and index photo --- */
.author-box { display: flex; gap: 1.1rem; align-items: center; margin: 2.2rem 0 1.4rem; padding: 1.2rem 1.3rem; background: #fff; border: 1px solid #e6dcc6; border-radius: 10px; }
.author-box img { width: 84px; height: 84px; border-radius: 50%; object-fit: cover; object-position: center 25%; flex-shrink: 0; }
.author-name { font-family: 'Playfair Display', Georgia, serif; font-weight: 700; color: var(--ink, #263149); margin-bottom: .25rem; }
.author-text { font-size: .92rem; color: var(--muted); }
.author-links { font-size: .9rem; margin-top: .35rem; }
.index-photo { margin: 0 0 2rem; }
.index-photo img { display: block; width: 100%; height: clamp(180px, 28vw, 300px); object-fit: cover; object-position: center 30%; border-radius: 12px; }
@media (max-width: 520px) { .author-box { align-items: flex-start; } .author-box img { width: 64px; height: 64px; } }

/* --- ROUND 2: warmer article styling --- */
.callout-law { background: rgba(113,128,92,.10); border-color: #556144; }
.callout-law .callout-label { background: #556144; color: #fff; }
.article-body > p:first-of-type::first-letter { font-family: 'Playfair Display', Georgia, serif; font-size: 3.4rem; float: left; line-height: .9; margin: .3rem .5rem 0 0; color: #9C7E33; }
.article-body blockquote { font-family: 'Playfair Display', Georgia, serif; font-style: italic; font-size: 1.3rem; border-left: 3px solid #BC9A46; padding-left: 1.2rem; color: var(--ink, #263149); }
.meta-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; object-position: center 25%; vertical-align: middle; margin-right: .45rem; }
.nav-cta { white-space: nowrap; }
