/* AssistCall look for the shared article system (/insights/ and /case-studies/, written by scripts/insights.mjs).
   article.css (ava-growth/tools/articles) reads --ins-* variables that default to an Ava site theme's tokens. AssistCall's own
   tokens use some of the same names for other things (--ink is the brand colour in both themes, --muted is a surface), so the
   --ins-* values are set here directly: Ink, Paper and Volt, Geist, Instrument Serif italic for one word in hub headings.
   Also styles the static mobile menu and the fallback header/footer (used only if the prerendered home
   has no header/footer to copy). Selectors start with :root so they win over article.css whatever the order. */

:root .ins{
  --display:'Geist Variable',ui-sans-serif,system-ui,-apple-system,'Segoe UI',sans-serif;
  --body:var(--display);--heading:var(--display);--label:var(--display);
  --display-weight:600;--display-tracking:-.04em;--display-case:none;--label-tracking:.14em;--btn-radius:9999px;
  --ins-bg:var(--bg);--ins-ink:var(--fg);--ins-ink-2:var(--fg-2);--ins-muted:#5c5f55;
  --ins-line:var(--border);--ins-line-strong:var(--border-strong);
  --ins-accent:#b8d42a;--ins-accent-text:#4c6900;
  --ins-panel:var(--surface);--ins-track:var(--muted);
  --ins-radius:14px;--ins-radius-lg:22px;
  /* charts: ink first (the brand's own chart token), a neutral for "the others", then the validated viz hues */
  --ins-c1:#11140f;--ins-c2:#a9ab9f;--ins-c3:#6c8e03;--ins-c4:#2a78d6;--ins-c5:#eb6834;--ins-c6:#eda100;
  /* closing call to action: an ink panel with a Volt button, like the site's CtaBand */
  --end-bg:var(--ink);--end-ink:var(--paper);--end-muted:rgb(244 243 238 / .72);--end-accent:var(--volt);--end-btn:var(--volt);--end-btn-ink:var(--ink);
  /* text on the accent (lime/Volt in both themes), buttons inside articles (the site's primary button), calculator inputs */
  --accent-ink:#11140f;--btn-bg:var(--primary);--btn-ink:var(--primary-fg);--input-bg:var(--surface);--input-radius:12px;
  font-family:var(--display);
}
:root[data-theme='dark'] .ins{
  --ins-muted:#a3a699;
  --ins-accent:#e4ff54;--ins-accent-text:#e4ff54;
  --ins-c1:#e4ff54;--ins-c2:#6e7266;--ins-c3:#3987e5;--ins-c4:#d95926;--ins-c5:#c98500;--ins-c6:#9085e9;
  --end-bg:var(--surface);--end-ink:var(--fg);--end-muted:var(--fg-2);
}

/* page frame: the same container widths as the site (max-w-7xl, 16/24/32 px gutters) */
:root .ins .ins-wrap{width:min(1216px,calc(100% - 32px))}
@media (min-width:640px){:root .ins .ins-wrap{width:min(1216px,calc(100% - 48px))}}
@media (min-width:1024px){:root .ins .ins-wrap{width:min(1216px,calc(100% - 64px))}}
:root .ins .ins-title{letter-spacing:-.045em;font-weight:600}
:root .ins .ins-head--hub .ins-title,:root .ins .ins-head--topic .ins-title{line-height:.98}
/* one emphasised word in hub headings (Instrument Serif italic, like the site's <Accent>) */
.ins .ac-accent{font-family:'Instrument Serif',ui-serif,Georgia,serif;font-style:italic;font-weight:400;letter-spacing:-.01em}
:root .ins .ins-eyebrow{font-weight:500;font-size:13px}
.ins ::selection{background:var(--volt);color:var(--ink)}
/* Tailwind's preflight removes list markers; put back the ones article.css styles */
.ins ul.ins-list{list-style:disc}
.ins ol.ins-list,.ins .ins-toc ol{list-style:decimal}

/* buttons used by the renderer (.button.primary) */
.ins .button{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;padding:0 24px;border-radius:9999px;font:500 15px/1.2 var(--display);letter-spacing:-.005em;text-decoration:none;white-space:nowrap;transition:background-color .15s,color .15s,transform .15s}
.ins .button.primary{background:var(--primary);color:var(--primary-fg)}
.ins .button:hover{transform:translateY(-1px)}
:root .ins .ins-cta .button.primary:hover{background:var(--volt-strong)}
.ins .button:focus-visible{outline:2px solid var(--ring);outline-offset:2px}

/* closing CTA: rounded ink panel with a soft Volt glow */
:root .ins .ins-cta{position:relative;overflow:hidden;border-radius:32px;border-color:transparent}
:root[data-theme='dark'] .ins .ins-cta{border-color:var(--border)}
.ins .ins-cta::before{content:"";position:absolute;right:-96px;top:-96px;width:320px;height:320px;border-radius:50%;background:var(--volt);opacity:.1;filter:blur(64px);pointer-events:none}
.ins .ins-cta>*{position:relative}

/* cards: white on paper, with the site's hairline borders and soft lift */
:root .ins .ins-card:hover{box-shadow:var(--shadow)}
:root .ins .ins-takeaways{background:var(--surface)}
:root .ins .ins-filter a[aria-current]{background:var(--fg);border-color:var(--fg);color:var(--bg)}
:root .ins .ins-callout{background:color-mix(in srgb,var(--volt) 16%,var(--surface))}
:root[data-theme='dark'] .ins .ins-callout{background:var(--surface)}

/* ---------- page frame without the app ---------- */
.acx-page{display:flex;flex-direction:column;min-height:100vh;min-height:100dvh;overflow-x:clip}
.acx-main{flex:1 0 auto}
.acx-skip{position:absolute;left:-9999px;top:auto;width:1px;height:1px;overflow:hidden}
.acx-skip:focus{position:fixed;left:16px;top:16px;z-index:70;width:auto;height:auto;padding:8px 16px;border-radius:9999px;background:var(--volt);color:var(--ink);font-size:14px;font-weight:500;text-decoration:none}

/* ---------- mobile menu (opened by the header's menu button) ---------- */
.acx-sheet[hidden]{display:none}
.acx-sheet{position:fixed;inset:0;z-index:60}
.acx-sheet-backdrop{position:absolute;inset:0;background:rgb(17 20 15 / .45);opacity:0;transition:opacity .2s ease}
.acx-sheet-panel{position:absolute;top:0;right:0;bottom:0;display:flex;flex-direction:column;width:min(100%,24rem);background:var(--surface);color:var(--fg);border-left:1px solid var(--border);box-shadow:var(--shadow-lg);transform:translateX(100%);transition:transform .25s cubic-bezier(.2,.8,.2,1)}
.acx-sheet.is-open .acx-sheet-backdrop{opacity:1}
.acx-sheet.is-open .acx-sheet-panel{transform:none}
.acx-sheet-head{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:64px;padding:0 12px 0 20px;border-bottom:1px solid var(--border)}
.acx-sheet-body{flex:1;overflow-y:auto;padding:4px 20px 20px;overscroll-behavior:contain}
.acx-sheet-nav ul{margin:0;padding:0;list-style:none}
.acx-sheet-nav a{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 0;border-bottom:1px solid var(--border);font-size:20px;font-weight:500;letter-spacing:-.02em;color:var(--fg);text-decoration:none}
.acx-sheet-nav svg{flex:none;width:16px;height:16px;color:var(--fg-3)}
.acx-sheet-group{margin-top:32px}
.acx-sheet-group h2{margin:0;font-size:12.5px;font-weight:500;letter-spacing:.12em;text-transform:uppercase;color:var(--fg-3)}
.acx-sheet-group ul{display:grid;column-gap:16px;margin-top:8px}
.acx-sheet-group--2 ul{grid-template-columns:repeat(2,minmax(0,1fr))}
.acx-sheet-nav .acx-sheet-group a{justify-content:flex-start;gap:6px;padding:10px 0;border-bottom:0;font-size:16px;letter-spacing:-.01em}
.acx-sheet-group a span{min-width:0}
.acx-sheet-group svg{width:14px;height:14px}
.acx-sheet-foot{display:grid;gap:8px;padding:16px 20px calc(16px + env(safe-area-inset-bottom));border-top:1px solid var(--border)}
.acx-icon-btn{display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;border:0;border-radius:9999px;background:transparent;color:var(--fg);cursor:pointer}
.acx-icon-btn:hover{background:var(--muted)}
.acx-icon-btn svg{width:20px;height:20px}
.acx-btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;padding:0 20px;border:1px solid transparent;border-radius:9999px;font-size:15px;font-weight:500;letter-spacing:-.005em;text-decoration:none;white-space:nowrap;font-variant-numeric:tabular-nums;transition:background-color .15s,border-color .15s}
.acx-btn svg{width:16px;height:16px}
.acx-btn--primary{background:var(--primary);color:var(--primary-fg)}
.acx-btn--secondary{background:var(--surface);color:var(--fg);border-color:var(--border)}
.acx-btn--secondary:hover{border-color:var(--border-strong)}
.acx-btn--ghost{background:transparent;color:var(--fg)}
.acx-btn--ghost:hover{background:var(--muted)}
.acx-lock{overflow:hidden}

/* ---------- newsletter form status (footer) ---------- */
.acx-note{margin:6px 0 0;font-size:13px;color:var(--fg-2)}
.acx-note--error{color:var(--danger)}

/* ---------- fallback header and footer (only when the prerendered home has none to copy) ---------- */
.acx-wrap{width:100%;max-width:80rem;margin-inline:auto;padding-inline:16px}
@media (min-width:640px){.acx-wrap{padding-inline:24px}}
@media (min-width:1024px){.acx-wrap{padding-inline:32px}}
.acx-header{position:sticky;top:0;z-index:40;border-bottom:1px solid transparent;transition:background-color .3s,border-color .3s}
.acx-header.is-scrolled{border-bottom-color:var(--border);background:color-mix(in srgb,var(--bg) 85%,transparent);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px)}
.acx-header-row{display:flex;align-items:center;justify-content:space-between;gap:16px;height:64px}
.acx-logo{display:inline-flex;align-items:center;gap:8px;color:var(--fg);text-decoration:none;border-radius:8px}
.acx-logo svg{width:28px;height:28px}
.acx-logo span{font-size:17px;font-weight:600;letter-spacing:-.03em}
.acx-nav{display:none}
.acx-nav ul{display:flex;align-items:center;margin:0;padding:0;list-style:none}
.acx-nav a{display:block;padding:8px 14px;border-radius:9999px;font-size:14px;font-weight:500;color:var(--fg-2);text-decoration:none}
.acx-nav a:hover,.acx-nav a[aria-current]{color:var(--fg)}
.acx-actions{display:flex;align-items:center;gap:8px}
.acx-actions .acx-btn{min-height:40px;padding:0 16px;font-size:14px}
.acx-hide-sm{display:none}
@media (min-width:640px){.acx-hide-sm{display:inline-flex}.acx-only-sm{display:none}}
@media (min-width:1024px){.acx-nav{display:block}.acx-only-md{display:none}}
.acx-footer{border-top:1px solid var(--border);background:var(--surface-2);color:var(--fg)}
.acx-footer-grid{display:grid;gap:48px;padding-block:64px}
@media (min-width:1024px){.acx-footer-grid{grid-template-columns:1.3fr 2fr}}
.acx-footer-brand p{max-width:20rem;margin:24px 0 0;font-size:15px;line-height:1.6;color:var(--fg-2)}
.acx-footer-cols{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:40px}
@media (min-width:640px){.acx-footer-cols{grid-template-columns:repeat(3,minmax(0,1fr))}}
.acx-footer h2{margin:0;font-size:13px;font-weight:500;letter-spacing:.12em;text-transform:uppercase;color:var(--fg-3)}
.acx-footer ul{display:flex;flex-direction:column;gap:10px;margin:16px 0 0;padding:0;list-style:none}
.acx-footer a{font-size:15px;color:var(--fg-2);text-decoration:none}
.acx-footer a:hover{color:var(--fg)}
.acx-footer-base{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:16px;padding-block:32px;border-top:1px solid var(--border);font-size:14px;color:var(--fg-3)}
.acx-footer-base p{margin:0}
.acx-footer-base nav{display:flex;align-items:center;gap:20px}
.acx-theme{display:inline-flex;padding:2px;border:1px solid var(--border);border-radius:9999px;background:var(--surface)}
.acx-theme button{display:inline-flex;padding:6px;border:0;border-radius:9999px;background:transparent;color:var(--fg-3);cursor:pointer}
.acx-theme button[aria-checked='true']{background:var(--muted);color:var(--fg)}
.acx-theme svg{width:14px;height:14px}

@media (prefers-reduced-motion:reduce){.acx-sheet-backdrop,.acx-sheet-panel,.ins .button{transition:none}}
@media print{.acx-header,.acx-footer,.acx-sheet,header[data-acx-header],footer[data-acx-footer]{display:none}}
