/* ascendant — generated by tools/generate-tokens.mjs from
   clients/ascendant/contract.tokens.json. DO NOT EDIT: change the contract
   and regenerate. `node tools/generate-tokens.mjs ascendant --check` fails
   when this file and the contract disagree. */

:root {
  /* Brand palette: private. Only the roles below may use these. */
  --_kadence-900:           #1A202C;
  --_kadence-800:           #2D3748;
  --_kadence-700:           #4A5568;
  --_kadence-500:           #718096;
  --_kadence-100:           #EDF2F7;
  --_kadence-50:            #F7FAFC;
  --_ink:                   #201640;
  --_ink-raised:            #2E2260;
  --_ink-deep:              #341D7D;
  --_ink-60:                #3C2B70;
  --_lime:                  #D7EB0C;
  --_lime-deep:             #D0DF3D;
  --_violet:                #7F5AFF;
  --_violet-deep:           #6B52D9;
  --_violet-light:          #9F86FF;
  --_lavender-pale:         #F2F1FF;
  --_lavender:              #EDEEFF;
  --_grey-pale:             #F6F5F9;
  --_hairline:              #EAE4FF;
  --_hairline-cool:         #E9E5F6;
  --_body:                  #5B5470;
  --_body-muted:            #75699F;
  --_on-dark-soft:          #D7CCFF;
  --_on-accent-soft:        #EFE9FF;
  --_white:                 #FFFFFF;

  /* fg */
  --fg-strong:              var(--_ink);
  --fg-medium:              var(--_ink);
  --fg-secondary:           var(--_ink-60);
  --fg-muted:               var(--_body-muted);
  --fg-on-dark:             var(--_white);
  --fg-on-dark-soft:        var(--_on-dark-soft);
  --fg-on-accent:           var(--_white);
  --fg-on-accent-soft:      var(--_on-accent-soft);
  --fg-eyebrow:             var(--_violet-deep);
  --fg-emphasis-on-dark:    var(--_lime);
  --fg-link:                var(--_violet-deep);
  --fg-link-on-dark:        var(--_violet-light);
  --fg-on-badge:            var(--_ink);

  /* surface */
  --surface-page:           var(--_white);
  --surface-raised:         var(--_lavender-pale);
  --surface-sunken:         var(--_grey-pale);
  --surface-inverse:        var(--_ink);
  --surface-inverse-raised: var(--_ink-raised);
  --surface-accent:         var(--_violet-deep);
  --surface-marker:         var(--_lavender);
  --surface-badge:          var(--_lime);

  /* ground */
  --ground-text:            var(--fg-strong);

  /* gradient */
  --gradient-hero:          linear-gradient(180deg, var(--_ink) 4%, var(--_ink-deep) 100%);

  /* action */
  --action-primary-bg:      var(--_ink);
  --action-primary-fg:      var(--_white);
  --action-on-dark-bg:      var(--_lime);
  --action-on-dark-fg:      var(--_ink);
  --action-on-accent-bg:    var(--_lime);
  --action-on-accent-fg:    var(--_ink);
  --action-ghost-border:    var(--_white);
  --action-ghost-fg:        var(--_white);
  --action-ghost-light-border: var(--_ink);
  --action-ghost-light-fg:  var(--_ink);
  --action-primary-bg-hover: var(--_ink-deep);
  --action-on-dark-bg-hover: var(--_lime-deep);
  --action-radius:          8px;
  --action-border-width:    2px;

  /* border */
  --border-faint:           var(--_hairline);
  --border-card:            var(--_hairline-cool);
  --border-soft:            var(--_lavender);
  --border-on-dark:         rgba(255, 255, 255, .14);
  --border-accent:          var(--_lime);
  --border-accent-on-dark:  rgba(215, 235, 12, .5);

  /* tracking */
  --tracking-tight:         0.03em;

  /* font */
  --font-body:              'DM Sans', sans-serif;
  --font-heading:           'Chivo', Arial, sans-serif;

  /* hairline */
  --hairline:               1px;

  /* radius */
  --radius-sm:              6px;
  --radius-md:              10px;
  --radius-lg:              12px;
  --radius-pill:            999px;
  --radius-xs:              3px;
  --radius-org:             100px 10px 10px 10px;

  /* shadow */
  --shadow-card-tinted:     0 2px 4px 0 #39296D;
  --shadow-card-sm:         0 2px 4px rgba(57, 41, 109, .12);
  --shadow-card-md:         0 8px 24px rgba(57, 41, 109, .14);
  --shadow-card-lg:         0 12px 32px rgba(57, 41, 109, .2);
  --shadow-image:           5px 9px 7px 0 rgba(51, 36, 98, .55);

  /* t */
  --t-hero:                 clamp(34px, 22.4px + 2.6vw, 52px);
  --t-section:              clamp(24px, 20.3px + 0.95vw, 34px);
  --t-h3:                   clamp(22px, 19.8px + 0.57vw, 28px);
  --t-card-title:           19px;
  --t-lead:                 clamp(17px, 16px + 0.35vw, 19px);
  --t-body:                 18px;
  --t-small:                17px;
  --t-eyebrow:              13px;
  --t-stat:                 clamp(32px, 24px + 1.8vw, 44px);
  --t-label:                15px;
  --t-tag:                  12px;
  --t-action:               1rem;

  /* lh */
  --lh-tight:               1.12;
  --lh-snug:                1.2;
  --lh-normal:              1.45;
  --lh-relaxed:             1.45;

  /* fw */
  --fw-regular:             400;
  --fw-semi:                600;
  --fw-bold:                700;

  /* space */
  --space-0:                0;
  --space-1:                4px;
  --space-2:                8px;
  --space-3:                12px;
  --space-4:                16px;
  --space-5:                20px;
  --space-6:                24px;
  --space-7:                32px;
  --space-8:                40px;
  --space-9:                48px;
  --space-10:               56px;
  --space-11:               72px;
  --space-12:               96px;

  /* measure */
  --measure-site:           1800px;
  --measure-banner:         1410px;
  --measure-content:        calc(var(--measure-banner) - var(--gutter) - var(--measure-banner) * 0.23 - var(--sidebar-gap));
  --measure-prose:          41em;
  --measure-prose-tight:    35.6em;

  /* gutter */
  --gutter:                 var(--space-5);

  /* breakpoint */
  --breakpoint-mobile:      48em;

  /* sidebar */
  --sidebar-width:          23%;
  --sidebar-gap:            30px;

  /* main */
  --main-basis:             480px;

  /* banner */
  --banner-art-cap:         600px;
}

@media (min-width: 48em) {
  :root {
    --gutter:               var(--space-8);
  }
}

body:not(.has-sidebar) { --measure-content: var(--measure-banner); }

.c-ground--sunken { background: var(--surface-sunken); }

.c-ground--raised {
  background: var(--surface-raised);
  --fg-muted:           var(--fg-medium);
  color: var(--ground-text);
}

.c-ground--inverse {
  background: var(--surface-inverse);
  --ground-text:        var(--fg-on-dark);
  background-image: var(--gradient-hero);
  --fg-strong:          var(--fg-on-dark);
  --fg-medium:          var(--fg-on-dark-soft);
  --fg-secondary:       var(--fg-on-dark-soft);
  --fg-muted:           var(--fg-on-dark-soft);
  --fg-eyebrow:         var(--fg-emphasis-on-dark);
  --fg-link:            var(--fg-link-on-dark);
  --border-faint:       var(--border-on-dark);
  --border-card:        var(--border-on-dark);
  --surface-raised:     var(--surface-inverse-raised);
  --shadow-card-tinted: none;
  color: var(--ground-text);
}

.c-ground--accent {
  background: var(--surface-accent);
  --ground-text:        var(--fg-on-accent);
  --fg-strong:          var(--fg-on-accent);
  --fg-medium:          var(--fg-on-accent-soft);
  --fg-secondary:       var(--fg-on-accent-soft);
  --fg-muted:           var(--fg-on-accent-soft);
  --fg-eyebrow:         var(--fg-on-accent-soft);
  --fg-link:            var(--fg-on-accent);
  --border-faint:       var(--border-on-dark);
  --border-card:        var(--border-on-dark);
  --shadow-card-tinted: none;
  color: var(--ground-text);
}

.c-ground--page {
  background: var(--surface-page);
  --fg-muted:           var(--_body-muted);
  --ground-text:        var(--_ink);
  --fg-strong:          var(--_ink);
  --fg-medium:          var(--_ink);
  --fg-secondary:       var(--_ink-60);
  --fg-eyebrow:         var(--_violet-deep);
  --fg-link:            var(--_violet-deep);
  --border-faint:       var(--_hairline);
  --border-card:        var(--_hairline-cool);
  --surface-raised:     var(--_lavender-pale);
  --shadow-card-tinted: 0 2px 4px 0 #39296D;
  --action-primary-bg:  var(--_ink);
  --action-primary-fg:  var(--_white);
  --action-primary-bg-hover: var(--_ink-deep);
  --action-ghost-border: var(--_white);
  --action-ghost-fg:    var(--_white);
  color: var(--ground-text);
}

/* The sidebar beside the content, from the site's own breakpoint.

   Source for tools/generate-tokens.mjs, which writes this into each client's
   tokens.css with 1025px replaced by the contract's
   breakpoint.sidebar (1025px, Kadence's own, when the contract leaves it
   empty). A media query cannot read a custom property, so the value is
   written in. Moved here from components/_frame.scss and _banner.scss on
   30 October 2026, where 1025px was fixed.

   Below the breakpoint the sidebar drops under the content and the banner's
   quick menu takes its place; on a phone the quick menu is all there is
   (Matt, 6 October 2026). Kadence makes the content and sidebar a grid from
   its own 1025px, so the grid is switched on and off here at the site's
   value instead. Plain CSS: no Sass reaches this file. */

@media screen and (width < 1025px) {
	/* Below the site's breakpoint the sidebar stacks, even where Kadence
	   would still put it beside the content. */
	:root .cw-frame.has-sidebar .content-container {
		display: block;
	}
}

@media screen and (min-width: 1025px) {
	/* From the site's breakpoint the sidebar sits beside the content, even
	   where Kadence would not yet. */
	:root .cw-frame.has-sidebar .content-container {
		display: grid;
	}

	:root .cw-frame.has-sidebar .content-container {
		column-gap: var(--sidebar-gap);
		grid-template-columns: minmax(0, 1fr) var(--sidebar-width);
	}

	:root .cw-frame.has-left-sidebar .content-container {
		grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
	}

	/* sidebar.divider: rule. A hairline in border.soft down the sidebar's
	   content-side edge, then the gap (Thain Wildbur's service pages, whose
	   sidebar is on the left). A right sidebar's text keeps a little room
	   from its rule. */
	:root .cw-sidebar-divider--rule.has-sidebar #secondary {
		border-inline-start: var(--hairline) solid var(--border-soft);
		padding-inline-start: var(--space-6);
	}

	:root .cw-sidebar-divider--rule.has-left-sidebar #secondary {
		border-inline-start: 0;
		border-inline-end: var(--hairline) solid var(--border-soft);
		padding-inline: 0 var(--space-6);
	}

	:root .cw-frame.has-sidebar .entry-content > :is(.c-stack-prose, .c-inset-quotes) {
		padding-inline: var(--page-edge) max(var(--page-edge), 100% - var(--page-edge) - var(--measure-prose));
	}

	/* One left edge beside a sidebar. Grounds, a full-width band or a panel's
	   own box, fill the content column; everything printed on the page or on
	   a ground starts at the page edge inside it, where the reading panels'
	   text starts. Text stops at the measure; grids and cards run on to the
	   same edge on the right. */
	:root .cw-frame.has-sidebar .entry-content > :is(.c-grid-facts, .c-cards-guides, .c-cards-hubs, .c-cards-cases, .c-split-cases, .c-rows-stories, .c-cards-people, .c-strip-facts:not(.c-strip-facts--inverse)) {
		padding-inline: var(--page-edge);
	}

	:root .cw-frame.has-sidebar .entry-content :is(.c-inset-facts__ground, .c-rows-quotes__ground, .c-strip-facts__ground) {
		padding-inline: var(--page-edge);
	}

	:root .cw-frame.has-sidebar .entry-content > * {
		--reading-measure: var(--measure-prose);
	}

	/* The figure's frame fills the content column like a ground; its caption
	   is text, so it starts on the page edge with the rest. */
	:root .cw-frame.has-sidebar .entry-content .c-inset-figure__caption {
		padding-inline: var(--page-edge);
		max-width: calc(var(--reading-measure) + 2 * var(--page-edge));
	}

	/* The panel's own lines of text, not those in its cards or grid: straight
	   in the panel or its ground, or in the inner container a classic theme
	   wraps round each Group's content (panels/_classic-groups.scss). */
	:root .cw-frame.has-sidebar .entry-content :is(.c-grid-facts, .c-cards-guides, .c-cards-hubs, .c-cards-cases, .c-split-cases, .c-rows-stories, .c-cards-people, .c-strip-facts, .c-inset-facts__ground, .c-rows-quotes__ground, .c-strip-facts__ground) > :is(.c-head, .c-eyebrow, .c-title, .c-lead, .c-sub, .c-body),
	:root .cw-frame.has-sidebar .entry-content :is(.c-grid-facts, .c-cards-guides, .c-cards-hubs, .c-cards-cases, .c-split-cases, .c-rows-stories, .c-cards-people, .c-strip-facts, .c-inset-facts__ground, .c-rows-quotes__ground, .c-strip-facts__ground) > :is(.c-measure, .wp-block-group__inner-container) > :is(.c-head, .c-eyebrow, .c-title, .c-lead, .c-sub, .c-body),
	:root .cw-frame.has-sidebar .entry-content .c-strip-facts > .wp-block-group__inner-container > .c-measure > .wp-block-group__inner-container > .c-head {
		max-width: var(--reading-measure);
	}

	.c-banner-menu {
		display: none;
	}

	/* panels/_article.scss: the reading panels beside a sidebar */
	:root:root .has-sidebar :is(.c-stack-prose, .c-inset-quotes) {
		padding-inline: var(--gutter) max(var(--gutter), 100% - var(--gutter) - var(--measure-prose));
	}

	/* panels/_split-prose.scss: its reading column at the measure beside a sidebar */
	@container c-split-prose (max-width: 863.98px) {
		:root:root .cw-frame.has-sidebar :is(.c-split-prose__grid, .c-split-prose__grid > .wp-block-group__inner-container) > :is(.c-head, .c-split-prose__body) {
			max-width: var(--reading-measure);
		}
	}

	/* panels/_inset-quotes.scss: a pair of quotes beside a sidebar (after article, so it wins) */
	:root:root .has-sidebar .c-inset-quotes--2 {
		padding-inline: var(--gutter);
	}

	:root .cw-frame.has-sidebar .entry-content > .c-inset-quotes--2 {
		padding-inline: var(--page-edge);
	}

	/* panels/_inset-video.scss: its text on the page edge beside a sidebar */
	:root .cw-frame.has-sidebar .entry-content .c-inset-video > :is(.c-title, .c-lead, .c-inset-video__caption),
	:root .cw-frame.has-sidebar .entry-content .c-inset-video > .wp-block-group__inner-container > :is(.c-title, .c-lead, .c-inset-video__caption) {
		padding-inline: var(--page-edge);
		max-width: calc(var(--reading-measure) + 2 * var(--page-edge));
	}

	/* panels/_section-menu.scss: the menu level with the content (sidebar.top) */
	body:not(.cw-sidebar-top--align-top) #secondary .c-context-menu:has(> .c-context-menu__heading) {
		padding-block-start: 45px;
	}

	body:not(.cw-sidebar-top--align-top).has-sidebar:has(.single-content > :is(.c-cards-cases, .c-rows-quotes, .c-rows-stories, .c-inset-facts, .c-grid-facts, .c-cards-guides):first-child) #secondary .c-context-menu:has(> .c-context-menu__heading) {
		padding-block-start: calc(var(--space-7) + 45px);
	}

	/* Content that opens with the dark facts strip: level with the strip's box,
	   which sits the Panel's wide-screen top padding down. */
	body:not(.cw-sidebar-top--align-top).has-sidebar:has(.single-content > .c-strip-facts--inverse:first-child) #secondary .c-context-menu:has(> .c-context-menu__heading) {
		padding-block-start: calc(var(--space-11) + 45px);
	}

	.cw-sidebar-top--align-top.has-sidebar :is(.entry-content, .single-content) > :first-child {
		margin-block-start: 0;
	}

	.cw-sidebar-top--align-top.has-sidebar :is(.entry-content, .single-content) > :first-child:not([class*="c-ground--"]) {
		padding-block-start: 0;
	}

	/* A Panel on its own ground keeps a box around its text: as much space
	   above as at its sides, not a full section's worth. */
	.cw-sidebar-top--align-top.has-sidebar :is(.entry-content, .single-content) > :first-child[class*="c-ground--"] {
		padding-block-start: var(--space-9);
	}
}
