/* Next Role Studio — Blog (blog.nextrole.studio)
   Adapted from the family site.css (jobsearch.nextrole.studio): same
   palette, header, nav, buttons and footer; trimmed to what a blog
   needs, extended with post-card and article typography.

   Palette sampled from the sign-in / admin portal theme:
   deep indigo #1e1b4b → #2b2585 → #3730a3, bright indigo #6366f1,
   coral #e8445f / #d12f4c — same values across every property. */
:root {
  --paper: #f4f4fa;
  --paper-2: #eceaf6;
  --card: #ffffff;
  --ink: #16132b;
  --ink-soft: #454166;
  --muted: #5f5b78;
  --line: #ddd9ee;
  --line-strong: #c6c1e0;
  --accent: #3730a3;
  --accent-deep: #2b2585;
  --accent-bright: #6366f1;
  --accent-wash: #eceaf6;
  --coral: #e8445f;
  --coral-deep: #d12f4c;
  --coral-wash: #fdeef1;
  --sage: #15803d;
  --sage-wash: #e8f5ec;
  --indigo-deep: #1e1b4b;
  --hero-gradient:
    radial-gradient(120% 180% at 90% -30%, rgba(99, 102, 241, 0.5) 0%, rgba(99, 102, 241, 0) 55%),
    linear-gradient(120deg, #1e1b4b 0%, #2b2585 60%, #3730a3 100%);
  --shadow: 0 18px 40px -22px rgba(30, 27, 75, 0.28);
  --radius: 10px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0d0b1a;
    --paper-2: #141126;
    --card: #191630;
    --ink: #f0eefc;
    --ink-soft: #c3bff0;
    --muted: #a7a3c8;
    --line: #322e5c;
    --line-strong: #4a4580;
    --accent: #a5b4fc;
    --accent-deep: #c7d2fe;
    --accent-wash: #232046;
    --coral: #fb8fa5;
    --coral-deep: #fda4b8;
    --sage: #4ade80;
    --sage-wash: #173324;
    --shadow: 0 18px 40px -22px rgba(0, 0, 0, 0.65);
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Public Sans", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
h1, h2, h3 { font-family: "Newsreader", Georgia, serif; font-weight: 500; line-height: 1.12; letter-spacing: -0.01em; margin: 0; }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); margin-bottom: 14px; }
h3 { font-size: 1.35rem; }
p { margin: 0; }
a { color: var(--accent-deep); }
:focus-visible { outline: 3px solid var(--accent-bright); outline-offset: 3px; }
.skip-link {
  position: absolute; left: 16px; top: -72px; z-index: 100;
  background: var(--indigo-deep); color: #fff; padding: 12px 18px;
  border-radius: 0 0 8px 8px; font-weight: 700; text-decoration: none;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 0; color: #fff; }
.mono { font-family: "IBM Plex Mono", ui-monospace, monospace; }
.sec-label { font-family: "IBM Plex Mono", monospace; font-size: 0.82rem; color: var(--accent-deep); margin-bottom: 10px; }
section { padding: 64px 0; }
section.band { background: var(--paper-2); }

/* ---------- site head: brand lockup + nav ---------- */
.site-head {
  display: flex; align-items: center; justify-content: space-between; gap: 28px;
  padding: 20px 0 4px; flex-wrap: wrap;
}
.brand {
  display: flex; align-items: center; gap: 12px; flex: none;
  text-decoration: none; line-height: 1.15;
}
.brand .tile { height: 46px; width: auto; display: block; flex: none; }
.brand .wordmark {
  font-family: "Public Sans", system-ui, sans-serif; font-weight: 700;
  font-size: 1.28rem; letter-spacing: -0.02em; color: var(--ink); display: block;
}
.brand .wordmark .accent-word { color: var(--accent-deep); }
.brand .tagline {
  font-family: "IBM Plex Mono", monospace; font-size: 0.68rem;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); display: block;
}
.topnav {
  display: flex; justify-content: flex-end; align-items: center; gap: 26px;
  flex-wrap: wrap;
  font-size: 0.92rem; font-weight: 500;
}
.topnav a { color: var(--ink-soft); text-decoration: none; }
.topnav a:hover { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 4px; }
.topnav a.nav-current { color: var(--accent-deep); font-weight: 700; text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--coral); text-decoration-thickness: 2px; }
.topnav a.nav-current:hover { color: var(--accent-deep); }
.topnav a.nav-cta {
  color: #fff; background: var(--hero-gradient); padding: 8px 16px; border-radius: 6px;
  box-shadow: 0 8px 20px -10px rgba(30, 27, 75, 0.6);
}
.topnav a.nav-cta:hover { color: #fff; text-decoration: none; filter: brightness(1.3); }
.topnav a.nav-signin {
  color: var(--accent-deep); background: transparent; padding: 7px 14px; border-radius: 6px;
  border: 1.5px solid var(--accent); box-shadow: none;
}
.topnav a.nav-signin:hover { color: var(--accent-deep); background: var(--accent-wash); text-decoration: none; }
.nav-beta-chip { background: #d12f4c; color: #fff; font-size: .62rem; font-weight: 800; letter-spacing: .08em; padding: .15rem .45rem; border-radius: 999px; }

/* ---------- dropdown menu ---------- */
.nav-drop { position: relative; }
.nav-drop-btn { font: inherit; font-weight: 500; color: var(--ink-soft); background: none; border: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; padding: 6px 2px; }
.nav-drop-btn:hover { color: var(--accent-deep); }
.nav-caret { font-size: .68rem; transition: transform .18s ease; }
.nav-drop.open .nav-caret, .nav-drop:hover .nav-caret { transform: rotate(180deg); }
.nav-drop-panel { position: absolute; top: calc(100% + 10px); left: 50%; transform: translate(-50%, 6px); min-width: 248px; border-radius: 14px; box-shadow: 0 24px 48px -16px rgba(13, 11, 26, .35); padding: 8px; opacity: 0; visibility: hidden; transition: opacity .18s ease, transform .18s ease, visibility .18s; z-index: 80; }
.nav-drop:hover .nav-drop-panel, .nav-drop:focus-within .nav-drop-panel, .nav-drop.open .nav-drop-panel { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.nav-drop-panel a { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 9px; font-weight: 600; text-decoration: none; white-space: nowrap; }
/* Dropdown final treatment — pinned colors so the menu reads identically in light and dark mode, on every property. */
.nav-drop-panel { background: #ffffff; border: 1px solid #ddd9ee; }
.nav-drop-panel a { color: #16132b; }
.nav-drop-panel a:hover { background: #eceaf6; color: #2b2585; text-decoration: none; }
.nav-drop-panel a.drop-featured { background: #eceaf6; color: #2b2585; }
.nav-drop-panel a.drop-featured:hover { background: #e2def7; filter: none; }

/* ---------- hero + buttons ---------- */
.hero {
  padding: 56px 0 64px;
  background: radial-gradient(90% 340px at 50% -80px, rgba(99, 102, 241, 0.16) 0%, rgba(99, 102, 241, 0) 70%);
}
.hero h1 { font-size: clamp(2.5rem, 5.4vw, 4rem); margin-bottom: 20px; }
.hero h1 em { font-style: italic; color: var(--accent-deep); }
.hero .lead { font-size: 1.13rem; color: var(--ink-soft); max-width: 36em; margin-bottom: 28px; }
.hero .lead strong { color: var(--ink); }
.cta-row { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.btn {
  display: inline-block; font-weight: 600; font-size: 1rem; text-decoration: none;
  padding: 13px 24px; border-radius: 6px; border: 1px solid var(--indigo-deep);
  background: var(--hero-gradient); color: #fff; cursor: pointer; font-family: inherit;
  box-shadow: 0 12px 26px -12px rgba(30, 27, 75, 0.55);
}
.btn:hover { border-color: var(--accent); color: #fff; filter: brightness(1.3); }
.btn-ghost { background: transparent; color: var(--accent-deep); box-shadow: none; border-color: var(--accent); }
.btn-ghost:hover { background: var(--accent-wash); color: var(--accent-deep); filter: none; }
.hero-note { margin-top: 18px; font-size: 0.92rem; color: var(--muted); }

/* ---------- blog home: post cards ---------- */
.post-cat {
  font-family: "IBM Plex Mono", monospace; font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--coral-deep);
  display: inline-block; margin-bottom: 12px;
}
.post-meta {
  font-family: "IBM Plex Mono", monospace; font-size: 0.8rem; color: var(--muted);
  display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center;
}
.post-meta .dot { color: var(--line-strong); }
.featured-card {
  display: block; text-decoration: none; color: inherit;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: var(--shadow); padding: 38px 40px; margin-bottom: 26px;
  border-top: 6px solid var(--coral);
}
.featured-card:hover { border-color: var(--line-strong); }
.featured-card h2 { max-width: 18em; }
.featured-card h2 a { color: var(--ink); text-decoration: none; }
.featured-card h2 a:hover { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 4px; }
.featured-card .dek { font-size: 1.06rem; color: var(--ink-soft); max-width: 42em; margin-bottom: 18px; }
.read-link { font-weight: 700; color: var(--accent-deep); text-decoration: none; }
.read-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.post-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.post-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  padding: 30px 32px; display: flex; flex-direction: column;
}
.post-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow); }
.post-card h3 { font-size: 1.5rem; margin-bottom: 10px; }
.post-card h3 a { color: var(--ink); text-decoration: none; }
.post-card h3 a:hover { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 4px; }
.post-card .dek { color: var(--ink-soft); font-size: 0.99rem; margin-bottom: 18px; }
.post-card .post-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; }

/* ---------- CTA band ---------- */
.cta-band {
  background:
    radial-gradient(120% 200% at 90% -40%, rgba(99, 102, 241, 0.55) 0%, rgba(99, 102, 241, 0) 55%),
    linear-gradient(120deg, #1e1b4b 0%, #2b2585 60%, #3730a3 100%);
  color: #f4f2ff; border-radius: 20px; padding: 42px 44px;
  box-shadow: var(--shadow);
}
.cta-band h2 { color: #ffffff; max-width: 20em; }
.cta-band p { color: #c3bff0; max-width: 40em; margin-bottom: 24px; }
.cta-band .btn-ghost { color: #fff; border-color: rgba(255, 255, 255, 0.65); }
.cta-band .btn-ghost:hover { background: rgba(255, 255, 255, 0.12); color: #fff; }

/* ---------- article pages ---------- */
.article-wrap { max-width: 760px; margin: 0 auto; padding: 0 24px; }
.article-head { padding: 48px 0 8px; }
.back-link { font-size: 0.92rem; font-weight: 600; text-decoration: none; display: inline-block; margin-bottom: 26px; }
.back-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.article-head h1 { font-size: clamp(2.1rem, 4.6vw, 3.1rem); margin-bottom: 16px; }
.article-head .standfirst { font-size: 1.14rem; color: var(--ink-soft); margin-bottom: 22px; }
.article-meta {
  display: flex; flex-wrap: wrap; gap: 8px 18px; align-items: center;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  padding: 14px 0; margin-bottom: 36px;
  font-family: "IBM Plex Mono", monospace; font-size: 0.82rem; color: var(--muted);
}
.article-meta .byline { color: var(--ink-soft); }
.article { font-size: 1.06rem; line-height: 1.72; color: var(--ink); padding-bottom: 8px; }
.article p { margin: 0 0 1.35em; }
.article p:last-child { margin-bottom: 0; }
.article h2 { font-size: 1.75rem; margin: 1.7em 0 0.55em; }
.article h3 { font-size: 1.3rem; margin: 1.5em 0 0.5em; }
.article ul, .article ol { margin: 0 0 1.35em; padding-left: 1.35em; display: grid; gap: 0.45em; }
.article li { line-height: 1.6; }
.article a { text-decoration: underline; text-underline-offset: 3px; }
.article strong { font-weight: 700; }
.article blockquote {
  margin: 2em 0; padding: 6px 0 6px 26px;
  border-left: 4px solid var(--coral);
  font-family: "Newsreader", Georgia, serif; font-size: 1.42rem; font-style: italic;
  line-height: 1.35; color: var(--accent-deep);
}
.article blockquote p { margin: 0; }
.article .checklist { list-style: none; padding-left: 0; }
.article .checklist li { display: flex; gap: 11px; }
.article .checklist .mark { color: var(--sage); font-family: "IBM Plex Mono", monospace; flex: none; }
.article-cta { margin: 44px 0 8px; }
.more-notes { padding: 8px 0 64px; }
.more-notes .post-grid { margin-top: 8px; }

/* ---------- footer ---------- */
footer {
  padding: 37px 0 44px; color: #c3bff0;
  background:
    linear-gradient(90deg, #6366f1, #3730a3 55%, #e8445f) top left / 100% 3px no-repeat,
    radial-gradient(120% 200% at 90% -40%, rgba(99, 102, 241, 0.55) 0%, rgba(99, 102, 241, 0) 55%),
    linear-gradient(120deg, #1e1b4b 0%, #2b2585 60%, #3730a3 100%);
}
.foot-row { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: 0.92rem; color: #c3bff0; }
.foot-row strong { color: #f4f2ff; font-family: "Newsreader", Georgia, serif; font-size: 1.05rem; }
footer a { color: #fda4b8; }
footer a:hover { color: #ffffff; }
.foot-projects { border-top: 1px solid rgba(195, 191, 240, .25); margin-top: 10px; padding-top: 12px; }
.fp-label { font-family: "IBM Plex Mono", monospace; font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: #c3bff0; }

/* ---------- responsive ---------- */
.nav-toggle { display: none; }
@media (max-width: 900px) {
  .post-grid { grid-template-columns: 1fr; }
  .featured-card { padding: 28px 24px; }
  .post-card { padding: 24px; }
  .cta-band { padding: 32px 24px; }
  .hero { padding: 36px 0 52px; }
  section { padding: 52px 0; }
  .topnav { width: 100%; justify-content: flex-start; gap: 10px 14px; }
  .site-head { display: block; gap: 16px; }
  .brand { margin-bottom: 14px; }
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center; gap: 9px;
    min-height: 48px; padding: 0 16px; border: 1.5px solid var(--accent);
    border-radius: 8px; background: var(--card); color: var(--accent-deep);
    font: inherit; font-weight: 700; cursor: pointer;
  }
  .nav-toggle .nav-toggle-icon { font-size: 1.15rem; line-height: 1; }
  .topnav a { display: inline-flex; align-items: center; min-height: 48px; padding: 10px 8px; }
  .topnav a.section-link { display: none; }
  .topnav.is-open a.section-link { display: inline-flex; }
  .topnav a.nav-cta { padding: 12px 16px; }
  .topnav a.nav-signin { padding: 11px 14px; }
  .topnav .nav-drop { display: none; width: 100%; }
  .topnav.is-open .nav-drop { display: block; }
  .nav-drop-btn { width: 100%; justify-content: space-between; min-height: 48px; padding: 10px 8px; font-weight: 600; }
  .nav-drop-panel { position: static; transform: none; opacity: 1; visibility: visible; display: none; box-shadow: none; border: 0; background: transparent; padding: 0 0 8px 16px; min-width: 0; }
  .nav-drop.open .nav-drop-panel { display: block; background: #ffffff; border: 1px solid #ddd9ee; border-radius: 12px; padding: 6px; }
  .nav-drop-panel a { min-height: 48px; padding: 10px 8px; }
  .brand .tile { height: 40px; }
  .brand .wordmark { font-size: 1.12rem; }
  .article blockquote { font-size: 1.25rem; padding-left: 20px; }
}
@media (max-width: 520px) {
  .topnav a.nav-signin { border: 1.5px solid var(--accent); padding: 11px 14px; background: transparent; }
  .topnav a.nav-signin:hover { background: var(--accent-wash); text-decoration: none; }
}
