/* pwp-authored-additional-v1-20261028: technical foundation only */
@layer pwp-runtime-foundation {
  :root {
    --bg:#0F172A; --text:#FFFFFF;
    --surface:#192134; --text-muted:#94A3B8;
    --primary:#1E40AF; --primary-fg:#FFFFFF;
    --border:rgba(255,255,255,0.08);
  }
  *, *::before, *::after { box-sizing:border-box; }
  html { scroll-behavior:smooth; }
  body { margin:0; background:var(--bg); color:var(--text); }
  img, video { max-inline-size:100%; block-size:auto; }
  button, input, select, textarea { font:inherit; }
  button, summary { cursor:pointer; }
  :where(a,button,input,select,textarea,summary):focus-visible { outline:2px solid currentColor; outline-offset:4px; }
  .skip { position:fixed; inset-block-start:-10rem; inset-inline-start:1rem; z-index:10000; padding:.75rem; background:var(--bg); color:var(--text); }
  .skip:focus { inset-block-start:1rem; }
  /* Legal prose is a separate utility; never constrain the author's main site. */
  .legal-container { max-inline-size:76ch; margin-inline:auto; padding:clamp(1rem,4vw,3rem); }
  .legal-body { line-height:1.7; overflow-wrap:anywhere; }
  .legal-body p + p, .legal-body section + section { margin-block-start:1.25em; }
  .legal-body table { display:block; overflow-x:auto; max-inline-size:100%; }
  .legal-body h1, .legal-body h2, .legal-body h3, .legal-title { line-height:1.2; }
  .cookie-banner { position:fixed; inset-inline:1rem; inset-block-end:1rem; z-index:9999; max-inline-size:34rem; padding:1rem; border:1px solid var(--border); background:var(--bg); color:var(--text); }
  .cookie-text { font:14px/1.5 system-ui,sans-serif; }
  .cookie-actions { display:flex; flex-wrap:wrap; gap:.75rem; margin-block-start:.75rem; }
  .cookie-actions button { min-block-size:44px; padding:.6rem 1rem; border:1px solid var(--border); background:var(--surface); color:var(--text); }
  .cookie-actions [data-action="accept-cookie"] { background:var(--primary); color:var(--primary-fg); }
}
/* Required state, not a visual layout. Expanded pages may be grid/flex/block. */
[hidden], .cookie-banner.hidden { display:none !important; }
@media(prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  *, *::before, *::after { animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}

/* === AUTHOR-OWNED SITE STYLES === */
:root {
    --ink: #10233f;
    --ink-deep: #09182d;
    --paper: #f5f2eb;
    --paper-bright: #fbfaf6;
    --blue: #1e40af;
    --blue-soft: #dbe6ff;
    --green: #087f5b;
    --green-soft: #dff3e9;
    --sand: #d9c9ad;
    --line: #d7d9dc;
    --muted: #5d6877;
    --white: #ffffff;
    --shadow: 0 18px 45px rgba(16, 35, 63, .12);
    --serif: "IBM Plex Serif", Georgia, serif;
    --sans: "DM Sans", Arial, sans-serif;
    --mono: "JetBrains Mono", monospace;
  }

  * { box-sizing: border-box; }

  html { scroll-behavior: smooth; }

  body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: var(--sans);
    line-height: 1.6;
    overflow-x: hidden;
  }

  img { display: block; max-width: 100%; }

  a {
    color: inherit;
    text-decoration-thickness: .08em;
    text-underline-offset: .18em;
  }

  a:hover { color: var(--blue); }

  :focus-visible {
    outline: 3px solid #f0a530;
    outline-offset: 4px;
  }

  .site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: rgba(251, 250, 246, .97);
    border-bottom: 1px solid var(--line);
  }

  .header-inner {
    width: min(100% - 40px, 1260px);
    margin: 0 auto;
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 26px;
  }

  .brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    text-decoration: none;
    white-space: nowrap;
  }

  .brand-mark {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    background: var(--ink);
    color: var(--paper);
    border-radius: 50%;
    font-family: var(--serif);
    font-size: 18px;
    font-weight: 600;
  }

  .brand-name {
    font-family: var(--serif);
    font-size: 1.3rem;
    letter-spacing: -.03em;
    font-weight: 600;
  }

  .brand-note {
    display: block;
    color: var(--muted);
    font-size: .69rem;
    line-height: 1.1;
    letter-spacing: .08em;
    text-transform: uppercase;
  }

  .main-nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 7px 18px;
    flex-wrap: wrap;
  }

  .main-nav a,
  .language-nav a {
    font-size: .86rem;
    text-decoration: none;
  }

  .main-nav a {
    padding: 8px 0;
    color: var(--ink);
  }

  .main-nav a:hover,
  .main-nav a[aria-current="page"] {
    color: var(--blue);
  }

  .language-nav {
    display: flex;
    gap: 8px;
    padding-left: 12px;
    border-left: 1px solid var(--line);
  }

  .language-nav a {
    color: var(--muted);
  }

  .language-nav a[aria-current="true"] {
    color: var(--ink);
    font-weight: 700;
  }

  .page {
    min-height: 60vh;
  }

  .page[hidden] { display: none; }

  .wrap {
    width: min(100% - 40px, 1260px);
    margin: 0 auto;
  }

  .eyebrow {
    margin: 0 0 14px;
    color: var(--green);
    font-family: var(--mono);
    font-size: .72rem;
    letter-spacing: .1em;
    text-transform: uppercase;
  }

  h1, h2, h3, p { margin-top: 0; }

  h1, h2, h3 {
    font-family: var(--serif);
    font-weight: 500;
    letter-spacing: -.045em;
    line-height: 1.05;
  }

  h1 {
    max-width: 850px;
    margin-bottom: 25px;
    font-size: clamp(2.8rem, 6.5vw, 6.5rem);
  }

  h2 {
    margin-bottom: 20px;
    font-size: clamp(2rem, 4vw, 4.2rem);
  }

  h3 {
    margin-bottom: 12px;
    font-size: 1.45rem;
  }

  .lead {
    max-width: 670px;
    color: #445267;
    font-size: clamp(1.08rem, 1.7vw, 1.35rem);
    line-height: 1.55;
  }

  .button-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 11px 20px;
    background: var(--ink);
    color: var(--white);
    text-decoration: none;
    border: 1px solid var(--ink);
    border-radius: 2px;
    font-size: .9rem;
    font-weight: 700;
    transition: background-color .2s ease, transform .2s ease;
  }

  .button-link:hover {
    background: var(--blue);
    color: var(--white);
    transform: translateY(-2px);
  }

  .button-link.secondary {
    background: transparent;
    color: var(--ink);
  }

  .button-link.secondary:hover {
    color: var(--blue);
    background: var(--blue-soft);
  }

  .hero {
    padding: clamp(60px, 9vw, 130px) 0 90px;
    background:
      linear-gradient(90deg, rgba(245,242,235,1) 0 52%, rgba(245,242,235,.15) 100%),
      var(--paper);
  }

  .hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, .95fr);
    gap: clamp(38px, 8vw, 110px);
    align-items: center;
  }

  .hero-copy { position: relative; z-index: 1; }

  .hero-copy h1 em {
    color: var(--blue);
    font-style: normal;
  }

  .hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 34px;
  }

  .hero-figure {
    position: relative;
    margin: 0;
  }

  .hero-figure img {
    width: 100%;
    aspect-ratio: 1 / 1.08;
    object-fit: cover;
    filter: saturate(.8);
  }

  .figure-caption {
    position: absolute;
    right: -18px;
    bottom: 24px;
    width: min(240px, 52%);
    padding: 16px 18px;
    background: var(--green);
    color: var(--white);
    font-family: var(--serif);
    font-size: 1.05rem;
    line-height: 1.25;
    box-shadow: var(--shadow);
  }

  .figure-caption small {
    display: block;
    margin-top: 10px;
    color: #d6f4e8;
    font-family: var(--sans);
    font-size: .7rem;
    line-height: 1.4;
  }

  .section {
    padding: clamp(70px, 9vw, 125px) 0;
  }

  .section-dark {
    background: var(--ink);
    color: var(--white);
  }

  .section-dark .eyebrow { color: #89d2b3; }
  .section-dark .lead { color: #c5d0df; }

  .section-heading {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    align-items: end;
    margin-bottom: 42px;
  }

  .section-heading h2 { max-width: 650px; margin-bottom: 0; }

  .topic-list {
    border-top: 1px solid var(--line);
  }

  .topic-item {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr) auto;
    align-items: center;
    gap: 24px;
    padding: 24px 0;
    border-bottom: 1px solid var(--line);
  }

  .topic-no {
    color: var(--green);
    font-family: var(--mono);
    font-size: .78rem;
  }

  .topic-item h3 { margin-bottom: 5px; }
  .topic-item p { margin-bottom: 0; color: var(--muted); max-width: 690px; }
  .topic-arrow { color: var(--blue); font-size: 1.5rem; }

  .reading-band {
    display: grid;
    grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr);
    align-items: stretch;
    gap: 0;
  }

  .reading-image img {
    width: 100%;
    height: 100%;
    min-height: 460px;
    object-fit: cover;
  }

  .reading-copy {
    padding: clamp(35px, 6vw, 78px);
    background: var(--blue-soft);
  }

  .reading-copy p { max-width: 570px; }
  .reading-copy .source-note {
    margin-top: 28px;
    color: #4a5c76;
    font-size: .85rem;
  }

  .faq {
    max-width: 900px;
    margin-top: 36px;
    border-top: 1px solid rgba(255,255,255,.22);
  }

  .faq details {
    border-bottom: 1px solid rgba(255,255,255,.22);
  }

  .faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: 70px;
    padding: 16px 0;
    cursor: pointer;
    list-style: none;
    font-size: 1.06rem;
    font-weight: 700;
  }

  .faq summary::-webkit-details-marker { display: none; }
  .faq summary::after {
    content: "+";
    flex: 0 0 auto;
    color: #93d5ba;
    font-size: 1.5rem;
    font-weight: 400;
  }

  .faq details[open] summary::after { content: "−"; }

  .faq-answer {
    max-width: 760px;
    padding: 0 50px 24px 0;
    color: #c5d0df;
  }

  .page-intro {
    padding: clamp(65px, 9vw, 120px) 0 65px;
    border-bottom: 1px solid var(--line);
  }

  .page-intro h1 { max-width: 900px; }

  .article-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: clamp(45px, 9vw, 130px);
    padding: 70px 0 110px;
  }

  .article-body {
    max-width: 760px;
    font-size: 1.08rem;
  }

  .article-body p { margin-bottom: 24px; }
  .article-body h2 { margin-top: 48px; font-size: 2.2rem; }
  .article-body h3 { margin-top: 38px; }

  .article-body ul {
    padding-left: 1.25rem;
    margin: 10px 0 28px;
  }

  .article-body li { margin: 9px 0; }

  .article-aside {
    align-self: start;
    position: sticky;
    top: 110px;
  }

  .aside-image {
    margin: 0 0 22px;
  }

  .aside-image img {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
  }

  .aside-note {
    padding-top: 18px;
    border-top: 2px solid var(--green);
    color: var(--muted);
    font-size: .9rem;
  }

  .source-list {
    margin-top: 38px;
    padding: 22px 24px;
    background: var(--paper-bright);
    border-left: 3px solid var(--green);
    font-size: .9rem;
  }

  .source-list strong {
    display: block;
    margin-bottom: 8px;
  }

  .source-list a { color: var(--blue); }

  .table-wrap {
    overflow-x: auto;
    margin: 30px 0;
  }

  table {
    width: 100%;
    min-width: 570px;
    border-collapse: collapse;
    font-size: .96rem;
  }

  th, td {
    padding: 15px 14px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--line);
  }

  th {
    background: var(--ink);
    color: var(--white);
    font-weight: 700;
  }

  .contact-grid {
    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(300px, 1.1fr);
    gap: clamp(45px, 9vw, 130px);
    padding: 70px 0 120px;
  }

  .contact-panel {
    padding: clamp(28px, 5vw, 58px);
    background: var(--ink);
    color: var(--white);
  }

  .contact-panel h2 { font-size: clamp(2rem, 4vw, 3.5rem); }
  .contact-panel .eyebrow { color: #93d5ba; }

  .contact-detail {
    padding: 20px 0;
    border-top: 1px solid rgba(255,255,255,.2);
  }

  .contact-detail strong {
    display: block;
    margin-bottom: 4px;
    color: #a8b8cb;
    font-size: .75rem;
    letter-spacing: .08em;
    text-transform: uppercase;
  }

  .contact-detail a { color: var(--white); }
  .contact-detail a:hover { color: #9ee4c8; }

  .contact-copy { max-width: 620px; }
  .contact-copy h2 { margin-bottom: 30px; }
  .contact-copy p { font-size: 1.1rem; }

  .site-footer {
    padding: 52px 0 28px;
    background: #071529;
    color: #e8edf5;
  }

  .footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 38px;
    padding-bottom: 40px;
  }

  .footer-brand .brand-name { color: var(--white); }
  .footer-brand p { max-width: 330px; color: #a9b8ca; font-size: .9rem; }

  .footer-heading {
    margin: 0 0 13px;
    color: #9ee4c8;
    font-family: var(--mono);
    font-size: .7rem;
    letter-spacing: .08em;
    text-transform: uppercase;
  }

  .footer-links {
    display: grid;
    gap: 8px;
    font-size: .86rem;
  }

  .footer-links a { color: #d7e0eb; }
  .footer-links a:hover { color: #9ee4c8; }

  .footer-bottom {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding-top: 22px;
    border-top: 1px solid rgba(255,255,255,.16);
    color: #a9b8ca;
    font-size: .78rem;
  }

  @media (max-width: 820px) {
    .header-inner {
      align-items: flex-start;
      flex-direction: column;
      padding: 16px 0;
      gap: 12px;
    }

    .main-nav {
      width: 100%;
      justify-content: flex-start;
      gap: 3px 16px;
    }

    .language-nav {
      position: absolute;
      right: 20px;
      top: 19px;
    }

    .hero-grid,
    .reading-band,
    .contact-grid,
    .article-layout {
      grid-template-columns: 1fr;
    }

    .hero {
      padding-top: 65px;
    }

    .hero-figure {
      max-width: 620px;
    }

    .article-aside {
      position: static;
      max-width: 360px;
      order: -1;
    }

    .aside-image img {
      aspect-ratio: 16 / 9;
    }

    .section-heading {
      display: block;
    }

    .section-heading .lead {
      margin-top: 20px;
    }

    .footer-grid {
      grid-template-columns: 1fr 1fr;
    }
  }

  @media (max-width: 540px) {
    .wrap,
    .header-inner {
      width: min(100% - 28px, 1260px);
    }

    .language-nav {
      right: 14px;
    }

    .brand-note { display: none; }

    h1 { font-size: clamp(2.65rem, 14vw, 4.3rem); }

    .hero-figure img { aspect-ratio: 1 / 1.12; }
    .figure-caption { right: -4px; bottom: 14px; width: 58%; }

    .topic-item {
      grid-template-columns: 38px minmax(0, 1fr) 20px;
      gap: 12px;
      align-items: start;
    }

    .topic-item p { font-size: .92rem; }
    .topic-arrow { padding-top: 2px; }

    .reading-image img { min-height: 280px; }
    .reading-copy { padding: 36px 24px; }

    .article-layout,
    .contact-grid {
      padding-top: 46px;
      padding-bottom: 78px;
    }

    .footer-grid {
      grid-template-columns: 1fr;
      gap: 30px;
    }

    .footer-bottom {
      display: block;
    }

    .footer-bottom span {
      display: block;
      margin-top: 8px;
    }
  }

  @media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
      transition-duration: .01ms !important;
    }
  }

/* === OPEN NAVIGATION SURFACE SAFETY === */
/* Position, shadows, borders and scroll treatment belong to the author.
   Only an OPEN mobile menu gets a mandatory opaque readable surface. */
header.site-header[data-pwp-nav-open] {
  background-color: var(--bg, #ffffff) !important;
  isolation: isolate;
}
[data-pwp-mobile-menu][data-pwp-menu-open] {
  background-color: var(--bg, #ffffff);
  color: var(--text, #0f172a);
  max-block-size: var(--pwp-nav-available-height, calc(100dvh - 6rem));
  overflow-y: auto;
  overscroll-behavior: contain;
}
.pwp-source-note {
  margin-block-start: 1rem;
  font-size: .875em;
  line-height: 1.5;
}
.pwp-source-note a { text-decoration: underline; text-underline-offset: .2em; }
