/* ==========================================================================
   tgx.css : ToneGrid foundation for the tonegrid.pro rebuild (Hume rhythm,
   ToneGrid brand). Plan and API: /root/tg-hume-rebuild/specs/FOUNDATION.md.
   Token source of truth: specs/tokens.css (values copied verbatim; the
   context classes are renamed .tgx-dark / .tgx-light).

   Scope: <html class="tgx">. Light (white body) is the default context;
   .tgx-dark marks black bands and dark islands; .tgx-light marks a white
   island inside a dark band (the hero demo card).

   No @layer on purpose: the Tailwind Play CDN injects unlayered utilities at
   the end of <head>, and unlayered rules beat every layered rule. The file
   sections below are the layers, in cascade order:
     1 fonts   2 tokens   3 base   4 type roles   5 layout and frames
     6 components   7 chrome   8 consent and plan modal
     9 long-tail compatibility   10 reduced motion and print
   No gradients anywhere: flat fills, hairlines, color-mix tints and the
   specified hairline shadows only. No font-weight 500 or 600: Aeonik ships
   300/400/700; "medium" is 400 plus a 0.3px text stroke.
   ========================================================================== */


/* 1. Fonts ----------------------------------------------------------------
   Aeonik: the served files are the TRIAL cut (66 glyphs per face). Every
   other character comes from the next family in --tg-font-sans, which was
   picked to match Aeonik's width and x-height. swap, not block. */
@font-face { font-family: "Aeonik"; src: url("/fonts/Aeonik/Aeonik-Light.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: swap; }
@font-face { font-family: "Aeonik"; src: url("/fonts/Aeonik/Aeonik-LightItalic.woff2") format("woff2"); font-weight: 300; font-style: italic; font-display: swap; }
@font-face { font-family: "Aeonik"; src: url("/fonts/Aeonik/Aeonik-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Aeonik"; src: url("/fonts/Aeonik/Aeonik-RegularItalic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Aeonik"; src: url("/fonts/Aeonik/Aeonik-Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Aeonik"; src: url("/fonts/Aeonik/Aeonik-BoldItalic.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: swap; }
/* JetBrains Mono 2.211 (SIL OFL 1.1), self-hosted variable subsets. */
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/JetBrainsMono/JetBrainsMono-vietnamese.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap;
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/JetBrainsMono/JetBrainsMono-latin-ext.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/JetBrainsMono/JetBrainsMono-latin.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }


/* 2. Tokens ----------------------------------------------------------------- */
/* 2.1 Primitives (tokens.css section 2) */
:root {
  --tg-violet-50:  #F5F3FF;  --tg-violet-100: #EDE9FE;  --tg-violet-200: #DDD6FE;
  --tg-violet-300: #C4B5FD;  --tg-violet-400: #A78BFA;  --tg-violet-500: #8B5CF6;
  --tg-violet-600: #7C3AED;  --tg-violet-700: #6D28D9;  --tg-violet-800: #5B21B6;
  --tg-violet-900: #4C1D95;  --tg-violet-950: #2E1065;

  --tg-gray-0:   #FFFFFF;  --tg-gray-25:  #FBFBFD;  --tg-gray-50:  #F5F5F7;
  --tg-gray-100: #E8E8ED;  --tg-gray-200: #D2D2D7;  --tg-gray-300: #B4B4B9;
  --tg-gray-400: #A1A1A6;  --tg-gray-500: #86868B;  --tg-gray-600: #6E6E73;
  --tg-gray-700: #424245;  --tg-gray-800: #2C2C2F;  --tg-gray-850: #1F1F22;
  --tg-gray-900: #161618;  --tg-gray-950: #0B0B0D;  --tg-gray-1000: #000000;

  --tg-black:      var(--tg-gray-950);   /* nav, hero, feature bands, final CTA */
  --tg-black-deep: var(--tg-gray-1000);  /* footer, code wells */
  --tg-white:      var(--tg-gray-0);     /* body sections, cards */

  --tg-live-500:     #3B9F6D;            /* status hues: mockups + form errors only */
  --tg-pending-500:  #B97F2B;
  --tg-rejected-500: #D15C53;

  /* Announcement bar (brand-system 4.4) */
  --tgx-announce-bg:       var(--tg-violet-900);
  --tgx-announce-bg-hover: var(--tg-violet-950);

  /* Page scrim behind an open header flyout (F-11, D26): flat, no blur */
  --tg-scrim: rgba(0, 0, 0, 0.65);
}

/* 2.2 Semantic color tokens by context (tokens.css section 3), plus
   - --tgc-*: "R G B" channels behind the legacy Tailwind color names
     (head.php maps surface*, on-surface*, outline*, primary, white, black...
     to rgb(var(--tgc-x) / <alpha-value>)), so 3,600+ legacy utility uses
     follow the context they sit in;
   - --tgx-*: component tokens that differ by context (buttons, chips).
   Every context re-declares every token: a custom property that references
   another is resolved where it is declared, never re-evaluated downstream. */
html.tgx,
html.tgx .tgx-light,
html.tgx .tg-modal-card {
  color-scheme: light;
  --tg-canvas:           var(--tg-white);
  --tg-canvas-alt:       var(--tg-gray-25);
  --tg-surface:          var(--tg-white);
  --tg-surface-sunken:   var(--tg-gray-50);
  --tg-surface-raised:   var(--tg-white);
  --tg-surface-hover:    rgba(11, 11, 13, 0.04);
  --tg-surface-pressed:  rgba(11, 11, 13, 0.07);
  --tg-surface-selected: #F2F0FF;
  --tg-surface-inverse:  var(--tg-gray-950);
  --tg-ink:          var(--tg-gray-950);
  --tg-ink-2:        var(--tg-gray-700);
  --tg-ink-3:        var(--tg-gray-600);
  --tg-ink-disabled: var(--tg-gray-400);
  --tg-ink-inverse:  var(--tg-gray-50);
  --tg-frame:       var(--tg-gray-100);
  --tg-line:        var(--tg-gray-100);
  --tg-line-strong: var(--tg-gray-200);
  --tg-line-field:  var(--tg-gray-500);
  --tg-action:         var(--tg-violet-600);
  --tg-action-hover:   var(--tg-violet-700);
  --tg-action-active:  var(--tg-violet-800);
  --tg-action-ink:     #FFFFFF;
  --tg-link:           var(--tg-violet-700);
  --tg-link-hover:     var(--tg-violet-800);
  --tg-brand-ink:      var(--tg-violet-700);
  --tg-brand-strong:   var(--tg-violet-500);
  --tg-brand-soft:     #F2F0FF;
  --tg-brand-soft-ink: var(--tg-violet-800);
  --tg-focus:          var(--tg-violet-600);
  --tg-focus-halo:     #E0DAFF;
  --tg-selection-bg:   var(--tg-violet-200);
  --tg-selection-ink:  var(--tg-gray-950);
  --tg-live:         var(--tg-live-500);
  --tg-live-ink:     #186B45;
  --tg-live-bg:      #E9F3ED;
  --tg-pending:      var(--tg-pending-500);
  --tg-pending-ink:  #8D5D1C;
  --tg-pending-bg:   #F7EFE7;
  --tg-rejected:     var(--tg-rejected-500);
  --tg-rejected-ink: #A83630;
  --tg-rejected-bg:  #FCECE9;
  --tg-shadow-edge:       0 1px 2px 1px rgba(11, 11, 13, 0.05), 0 0 1px 0 rgba(11, 11, 13, 0.35);
  --tg-shadow-card:       0 1px 2px 1px rgba(11, 11, 13, 0.05), 0 0 1px 0 rgba(11, 11, 13, 0.25);
  --tg-shadow-card-hover: 0 2px 4px 1px rgba(11, 11, 13, 0.05), 0 12px 24px -12px rgba(11, 11, 13, 0.18), 0 0 1px 0 rgba(11, 11, 13, 0.30);
  --tg-shadow-pop:        0 16px 40px -12px rgba(11, 11, 13, 0.22), 0 2px 6px 0 rgba(11, 11, 13, 0.06), 0 0 1px 0 rgba(11, 11, 13, 0.30);
  --tg-shadow-panel:      0 2px 8px 2px rgba(11, 11, 13, 0.15), 0 0 1px 0 rgba(11, 11, 13, 0.30);
  --tg-shadow-demo:       0 0 0 1px rgba(11, 11, 13, 0.08);   /* hairline ring only (RULINGS: hairline-only elevation) */
  --tg-image-outline:     rgba(0, 0, 0, 0.10);
  --tg-lh-bump:    0;
  --tg-icon-grade: 0;

  --tgx-btn2-bg:   var(--tg-white);      --tgx-btn2-bg-h: var(--tg-gray-50);   --tgx-btn2-bg-a: var(--tg-gray-100);
  --tgx-btn2-ring: var(--tg-shadow-edge);
  --tgx-btn3-bg:   var(--tg-gray-950);   --tgx-btn3-bg-h: var(--tg-gray-800); --tgx-btn3-bg-a: var(--tg-gray-700);
  --tgx-btn3-ink:  #FFFFFF;
  --tgx-chip-bg:   var(--tg-gray-50);    --tgx-chip-bg-h: var(--tg-gray-100); --tgx-chip-ink: var(--tg-gray-700);
  --tgx-badge-bg:  var(--tg-gray-50);

  --tgc-bg: 255 255 255;  --tgc-s1: 245 245 247;  --tgc-s2: 255 255 255;  --tgc-s3: 245 245 247;  --tgc-s4: 232 232 237;
  --tgc-fg: 11 11 13;     --tgc-fg2: 66 66 69;    --tgc-line: 134 134 139;
  --tgc-accent: 109 40 217;   /* #6D28D9: purple text on white, 7.10:1 */
  --tgc-err: 168 54 48;
  --tgc-white: 11 11 13;  --tgc-black: 255 255 255;   /* legacy literal white/black invert on white */
}

html.tgx .tgx-dark,
html.tgx main:not(.tgx-main) > section:first-of-type:not(:only-of-type),
html.tgx :is(main:not(.tgx-main) > section:only-of-type > div > .grid > div > .mb-12:first-child:has(> h1)),   /* F-15 heads (compat 9.8b); :is() keeps the list valid without :has() */
html.tgx :is(main:not(.tgx-main).flex.items-center.justify-center),
html.tgx :is(main:not(.tgx-main) > section:only-of-type:has(> h1:first-child)),
html.tgx :is(main:not(.tgx-main):not(:has(> section)):has(> h1:first-child)),
html.tgx main:not(.tgx-main) [class*="bg-[#0"],
html.tgx .prose-content > div[style]:not([class]),
html.tgx div.kinetic-gradient.text-center,
html.tgx main:not(.tgx-main) pre,
html.tgx #api-console,
html.tgx .tg-consent-card {
  color-scheme: dark;
  --tg-canvas:           var(--tg-black);
  --tg-canvas-alt:       var(--tg-black-deep);
  --tg-surface:          var(--tg-gray-900);
  --tg-surface-sunken:   var(--tg-black-deep);
  --tg-surface-raised:   var(--tg-gray-900);
  --tg-surface-hover:    rgba(255, 255, 255, 0.06);
  --tg-surface-pressed:  rgba(255, 255, 255, 0.10);
  --tg-surface-selected: #28233B;
  --tg-surface-inverse:  var(--tg-gray-50);
  --tg-ink:          var(--tg-gray-50);
  --tg-ink-2:        var(--tg-gray-300);
  --tg-ink-3:        var(--tg-gray-500);
  --tg-ink-disabled: var(--tg-gray-600);
  --tg-ink-inverse:  var(--tg-gray-950);
  --tg-frame:       rgba(255, 255, 255, 0.08);
  --tg-line:        rgba(255, 255, 255, 0.08);
  --tg-line-strong: rgba(255, 255, 255, 0.14);
  --tg-line-field:  var(--tg-gray-600);
  --tg-action:         var(--tg-violet-600);
  --tg-action-hover:   #7431E3;
  --tg-action-active:  var(--tg-violet-700);
  --tg-action-ink:     #FFFFFF;
  --tg-link:           var(--tg-violet-400);
  --tg-link-hover:     var(--tg-violet-300);
  --tg-brand-ink:      var(--tg-violet-400);
  --tg-brand-strong:   var(--tg-violet-400);
  --tg-brand-soft:     #1E1930;
  --tg-brand-soft-ink: var(--tg-violet-300);
  --tg-focus:          var(--tg-violet-400);
  --tg-focus-halo:     #322754;
  --tg-selection-bg:   var(--tg-violet-700);
  --tg-selection-ink:  #FFFFFF;
  --tg-live:         var(--tg-live-500);
  --tg-live-ink:     #7DD3A3;
  --tg-live-bg:      #202E28;
  --tg-pending:      var(--tg-pending-500);
  --tg-pending-ink:  #EEC474;
  --tg-pending-bg:   #322920;
  --tg-rejected:     var(--tg-rejected-500);
  --tg-rejected-ink: #F7958A;
  --tg-rejected-bg:  #372424;
  --tg-shadow-edge:       0 1px 2px 1px rgba(255, 255, 255, 0.05), 0 0 1px 0 rgba(255, 255, 255, 0.25);
  --tg-shadow-card:       inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  --tg-shadow-card-hover: inset 0 0 0 1px rgba(255, 255, 255, 0.14);
  --tg-shadow-pop:        0 2px 8px 2px rgba(0, 0, 0, 0.15), 0 24px 48px -12px rgba(0, 0, 0, 0.60), 0 1px 2px 1px rgba(255, 255, 255, 0.05), 0 0 1px 0 rgba(255, 255, 255, 0.25);
  --tg-shadow-panel:      0 2px 8px 2px rgba(0, 0, 0, 0.15), 0 1px 2px 1px rgba(255, 255, 255, 0.05), 0 0 1px 0 rgba(255, 255, 255, 0.25);   /* hume.ai's flyout panel: a contact shadow plus two hairlines */
  --tg-shadow-demo:       0 0 0 1px rgba(255, 255, 255, 0.10), 0 32px 64px -24px rgba(0, 0, 0, 0.60);
  --tg-image-outline:     rgba(255, 255, 255, 0.10);
  --tg-lh-bump:    0.04;
  --tg-icon-grade: 0;

  --tgx-btn2-bg:   var(--tg-gray-850);   --tgx-btn2-bg-h: var(--tg-gray-800); --tgx-btn2-bg-a: var(--tg-gray-700);   /* #1F1F22, hover #2C2C2F (D23) */
  --tgx-btn2-ring: var(--tg-shadow-edge);   /* a white 5% ring and a 25% hairline */
  --tgx-btn3-bg:   #FFFFFF;              --tgx-btn3-bg-h: var(--tg-gray-100); --tgx-btn3-bg-a: var(--tg-gray-200);
  --tgx-btn3-ink:  var(--tg-gray-950);
  --tgx-chip-bg:   rgba(255, 255, 255, 0.06); --tgx-chip-bg-h: rgba(255, 255, 255, 0.10); --tgx-chip-ink: var(--tg-gray-300);
  --tgx-badge-bg:  rgba(255, 255, 255, 0.06);

  --tgc-bg: 11 11 13;     --tgc-s1: 0 0 0;        --tgc-s2: 22 22 24;     --tgc-s3: 31 31 34;     --tgc-s4: 44 44 47;
  --tgc-fg: 245 245 247;  --tgc-fg2: 180 180 185; --tgc-line: 134 134 139;
  --tgc-accent: 167 139 250;  /* #A78BFA: purple text on black, 7.23:1 */
  --tgc-err: 247 149 138;
  --tgc-white: 255 255 255;  --tgc-black: 0 0 0;
}

/* Purple fills keep literal white labels in every context. */
html.tgx :is(.bg-primary, a.kinetic-gradient, button.kinetic-gradient, span.kinetic-gradient,
             div.kinetic-gradient:not(.text-center), .tgx-btn--primary) {
  --tgc-white: 255 255 255;
  --tgc-fg: 255 255 255;
  --tgc-fg2: 237 233 254;
}

/* The context class paints its canvas and sets the text color. Zero
   specificity: the hero overrides the paint (see 5.4). */
:where(html.tgx) :where(.tgx-light, .tgx-dark) {
  background-color: var(--tg-canvas);
  color: var(--tg-ink);
}

/* 2.3 Type, space, shape, motion and component tokens (tokens.css 4 to 7) */
:root {
  --tg-font-sans: "Aeonik", "Helvetica Neue", "Segoe UI", Helvetica, Arial, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic Medium", "Yu Gothic", YuGothic, Meiryo, sans-serif;
  --tg-font-mono: "JetBrains Mono", ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", "Hiragino Sans", "Noto Sans JP", "Yu Gothic Medium", monospace;
  --tg-fw-light:   300;
  --tg-fw-regular: 400;
  --tg-fw-bold:    700;
  --tg-fw-medium:  400;          /* synthetic medium: 400 + stroke */
  --tg-medium-stroke:   0.3px;
  --tg-medium-stroke-l: 0.4px;

  /* Display roles (D15, D21, F-14): weight 300 (never below 28px), line-height
     1.15 on both grounds, as on hume.ai. display-p is Hume's title-xl (product
     and policy H1s), display-m its title-lg (section H2s); both reach their
     desktop size at 640, where Hume steps up. */
  --tg-fs-display-xl: clamp(2.375rem, 1.911rem + 1.905vw, 4.5rem);   /* 38 at 390, 58 at 1440 */
  --tg-fs-display-l:  clamp(2rem, 1.629rem + 1.524vw, 3.25rem);      /* 32 at 390, 48 at 1440 */
  --tg-fs-display-p:  clamp(2.125rem, 0.955rem + 4.8vw, 2.875rem);   /* 34 at 390, 46 from 640 */
  --tg-fs-display-m:  clamp(2rem, 1.415rem + 2.4vw, 2.375rem);       /* 32 at 390, 38 from 640 */
  --tg-fs-stat:       clamp(2.25rem, 1.971rem + 1.143vw, 3.25rem);
  --tg-fs-title-l:    clamp(1.5rem, 1.407rem + 0.381vw, 1.75rem);
  --tg-fs-title-m:    1.375rem;
  --tg-fs-title-s:    1.125rem;
  --tg-fs-body-l:     clamp(1.125rem, 1.0786rem + 0.1905vw, 1.25rem);
  --tg-fs-body-m:     1.125rem;
  --tg-fs-body-s:     1rem;
  --tg-fs-caption:    0.9375rem;
  --tg-fs-label:      0.8125rem;
  --tg-fs-label-s:    0.75rem;
  --tg-fs-data:       0.875rem;
  --tg-fs-data-s:     0.8125rem;
  --tg-fs-code:       0.875rem;
  --tg-fs-button-l:   1.0625rem;
  --tg-fs-button-m:   1rem;
  --tg-fs-button-s:   0.9375rem;
  --tg-fs-nav:        0.9375rem;   /* 15: header triggers (desktop critic 26) */

  --tg-lh-display-xl: 1.15;  --tg-lh-display-l: 1.15;  --tg-lh-display-p: 1.15;  --tg-lh-display-m: 1.15;  --tg-lh-stat: 1;
  --tg-lh-title: 1.25;  --tg-lh-body-l: 1.5;  --tg-lh-body: 1.6;  --tg-lh-body-s: 1.55;
  --tg-lh-caption: 1.45;  --tg-lh-label: 1.34;  --tg-lh-data: 1.45;  --tg-lh-code: 1.7;
  --tg-lh-ui: 1;          /* one-line controls (buttons, nav, chips, badges): the control sets the height */

  --tg-ls-display-xl: -0.022em;  --tg-ls-display-l: -0.02em;  --tg-ls-display-p: -1px;  --tg-ls-display-m: -1px;
  --tg-ls-title: -0.01em;  --tg-ls-body: 0em;  --tg-ls-label: 0.08em;  --tg-ls-ui: 0em;
  --tg-ff-display: normal;

  --tg-space-0-5: 0.125rem; --tg-space-1: 0.25rem; --tg-space-1-5: 0.375rem; --tg-space-2: 0.5rem;
  --tg-space-3: 0.75rem;    --tg-space-4: 1rem;    --tg-space-5: 1.25rem;    --tg-space-6: 1.5rem;
  --tg-space-8: 2rem;       --tg-space-10: 2.5rem; --tg-space-12: 3rem;      --tg-space-16: 4rem;
  --tg-space-20: 5rem;      --tg-space-24: 6rem;   --tg-space-32: 8rem;      --tg-space-40: 10rem;

  --tg-section-y:     4rem;
  --tg-section-y-lg:  5rem;
  --tg-stack-head:    2.5rem;
  --tg-stack-stage:   2.5rem;   /* product hero: copy to stage (.tgx-hero__stage); not the section head gap */
  --tg-hero-pt:       clamp(3.5rem, 2.2rem + 5.333vw, 8rem);
  --tg-hero-straddle: clamp(4rem, 3.605rem + 1.619vw, 5.5rem);
  --tg-hero-gap:      clamp(2.5rem, 1.757rem + 3.048vw, 4.5rem);   /* product hero, copy to object: 40 at 390, 72 at 1440 */
  --tg-hero-edge:     clamp(5rem, 4.814rem + 0.762vw, 5.5rem);     /* product hero, black into the object: 80 at 390, 88 at 1440 (D18) */

  --tg-gutter:     1.5rem;     /* 24 at every width, as on hume.ai (D28) */
  --tg-w-frame:    81rem;
  --tg-w-content:  72rem;
  --tg-w-narrow:   48rem;
  --tg-w-prose:    40rem;
  --tg-frame-pad:  1.5rem;     /* inside the frame lines: 24, then 48 from 1024 and 72 from 1280 */
  --tg-frame-line: 1px;        /* frame lines stay on phones, as on hume.ai */

  --tg-announce-h: 2.25rem;
  --tg-header-h:   3.5rem;

  --tg-radius-xs: 4px;  --tg-radius-sm: 6px;  --tg-radius-md: 8px;  --tg-radius-lg: 12px;
  --tg-radius-xl: 16px; --tg-radius-pill: 999px;

  --tg-z-base: 0;  --tg-z-raised: 1;  --tg-z-sticky: 20;  --tg-z-scrim: 40;  --tg-z-header: 50;  --tg-z-sheet: 60;
  --tg-z-consent: 70;  --tg-z-overlay: 80;  --tg-z-modal: 90;  --tg-z-toast: 100;  --tg-z-tooltip: 110;

  --tg-dur-fast: 150ms;
  --tg-dur-base: 220ms;
  --tg-dur-slow: 400ms;
  --tg-ease-out-quint: cubic-bezier(0.22, 1, 0.36, 1);
  --tg-ease-standard:  cubic-bezier(0.2, 0, 0, 1);
  --tg-press-scale: 0.96;
  --tg-focus-width: 2px;
  --tg-focus-offset: 2px;

  --tg-btn-h-l: 2.5rem;     --tg-btn-px-l: 1.5rem;     /* 40: page pills (D29) */
  --tg-btn-h-m: 2.5rem;     --tg-btn-px-m: 1.25rem;    /* 40 */
  --tg-btn-h-s: 2rem;       --tg-btn-px-s: 0.875rem;   /* 32: header and forms; touch adds a 44 px hit area */
  --tg-btn-gap: 0.5rem;
  --tg-chip-h: 2rem;        --tg-chip-px: 0.875rem;
  --tg-tab-h: 2rem;         --tg-tab-track-pad: 0.25rem;
  --tg-badge-h: 1.25rem;    --tg-badge-px: 0.375rem;
  --tg-field-h: 3rem;       --tg-field-px: 1rem;
  --tg-nav-link-h: 2.25rem; --tg-nav-link-px: 0.75rem;
  --tg-card-pad: 1.5rem;
  --tg-demo-pad: 0.5rem;
  --tg-code-head-h: 2.75rem; --tg-code-pad: 1.25rem;
  --tg-row-h: 3.25rem;
  --tg-hit-min: 2.75rem;
  --tg-icon-xs: 1rem;  --tg-icon-s: 1.125rem;  --tg-icon-m: 1.25rem;  --tg-icon-l: 1.5rem;
}
@media (min-width: 40rem) {
  :root { --tg-section-y: 5rem; --tg-section-y-lg: 6rem; --tg-stack-head: 3rem; --tg-stack-stage: 3rem; }
}
@media (min-width: 64rem) {
  :root { --tg-section-y: 6rem; --tg-section-y-lg: 8rem; --tg-stack-head: 4rem; --tg-stack-stage: 3.5rem; --tg-frame-pad: 3rem; --tg-card-pad: 2rem; }
}
@media (min-width: 80rem) {
  :root { --tg-frame-pad: 4.5rem; }
}
/* From 1440 the hero grows with the screen, so 1920 reads as Hume's (top 251, H1 77): 112 px of
   --tg-hero-pt and 58 px of display-xl at 1440 (as before), about 214 and 76 at 1920 (FND-10) */
@media (min-width: 90rem) {
  :root {
    --tg-hero-pt: min(13.375rem, calc(7rem + (100vw - 90rem) * 0.2125));
    --tg-fs-display-xl: clamp(3.625rem, 0.25rem + 3.75vw, 4.9rem);
  }
}
:root:lang(ja) {
  --tg-fs-display-xl: clamp(1.875rem, 1.457rem + 1.714vw, 3.25rem);
  --tg-fs-display-l:  clamp(1.75rem, 1.471rem + 1.143vw, 2.625rem);
  --tg-fs-display-p:  clamp(1.75rem, 0.775rem + 4vw, 2.375rem);      /* 28 at 390, 38 from 640 */
  --tg-fs-display-m:  clamp(1.75rem, 1.36rem + 1.6vw, 2rem);         /* 28 at 390, 32 from 640: weight 300 starts at 28 */
  --tg-lh-display-xl: 1.32;  --tg-lh-display-l: 1.36;  --tg-lh-display-p: 1.36;  --tg-lh-display-m: 1.4;
  --tg-lh-title: 1.45;  --tg-lh-body-l: 1.8;  --tg-lh-body: 1.85;  --tg-lh-body-s: 1.8;  --tg-lh-caption: 1.7;
  --tg-ls-display-xl: 0.02em;  --tg-ls-display-l: 0.02em;  --tg-ls-display-p: 0.02em;  --tg-ls-display-m: 0.02em;
  --tg-ls-title: 0.02em;  --tg-ls-body: 0.02em;  --tg-ls-label: 0.04em;
  --tg-ff-display: "palt" 1;
}
:root:lang(vi) {
  --tg-lh-display-xl: 1.2;  --tg-lh-display-l: 1.22;  --tg-lh-display-p: 1.22;  --tg-lh-display-m: 1.24;
  --tg-lh-title: 1.32;  --tg-lh-body: 1.68;
}
@media (prefers-reduced-motion: reduce) {
  :root { --tg-dur-fast: 1ms; --tg-dur-base: 1ms; --tg-dur-slow: 1ms; --tg-press-scale: 1; }
}


/* 3. Base ------------------------------------------------------------------- */
html.tgx {
  overflow-x: clip;   /* the layout viewport never widens past the screen, so fixed bars (consent) stay inside it at 200% text (FND-3) */
  background-color: var(--tg-black);   /* overscroll above the black header and below the footer */
  scroll-padding-top: calc(var(--tg-header-h) + 1rem);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
@media (prefers-reduced-motion: no-preference) {
  html.tgx { scroll-behavior: smooth; }
}
html.tgx body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--tg-canvas);
  color: var(--tg-ink);
  font-family: var(--tg-font-sans);
  font-size: var(--tg-fs-body-m);
  font-weight: var(--tg-fw-regular);
  line-height: var(--tg-lh-body);
  font-kerning: normal;
  overflow-x: clip;   /* never "hidden": clip keeps position: sticky working */
  /* No -webkit-font-smoothing: antialiased. It thins Aeonik on dark
     (Eric, Oct 2026: "texts too thin"). */
}
html.tgx ::selection { background-color: var(--tg-selection-bg); color: var(--tg-selection-ink); }
html.tgx :focus-visible {
  outline: var(--tg-focus-width) solid var(--tg-focus);
  outline-offset: var(--tg-focus-offset);
}
html.tgx :focus:not(:focus-visible) { outline: none; }

/* Legacy pills often transition every property. Keyboard focus needs its full
   outline on the first frame, even if the background or text is fading. */
html.tgx main:not(.tgx-main) :is(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  transition-property: color, background-color, border-color, opacity, transform;
}
html.tgx main video[controls]:focus-within, html.tgx main audio[controls]:focus-within {
  outline: var(--tg-focus-width) solid var(--tg-focus);
  outline-offset: var(--tg-focus-offset);
  transition-property: opacity, transform;
}

html.tgx [hidden]:not([hidden="until-found"]) { display: none !important; }
html.tgx img, html.tgx svg, html.tgx video { max-width: 100%; }
html.tgx img, html.tgx video { height: auto; }

/* 3.1 Reset for pages that skip the utility runtime ($tgx_pure in head.php
   adds html.tgx-pure). A zero-specificity port of the utility preflight
   (v3.4), so tgx and kit classes, which were written against that reset,
   render the same with or without the runtime, and every class still wins. */
:where(html.tgx-pure) *, :where(html.tgx-pure) ::before, :where(html.tgx-pure) ::after {
  box-sizing: border-box;
  border: 0 solid var(--tg-line);
}
:where(html.tgx-pure) :where(hr) { height: 0; color: inherit; border-top-width: 1px; }
:where(html.tgx-pure) :where(abbr[title]) { text-decoration: underline dotted; }
:where(html.tgx-pure) :where(h1, h2, h3, h4, h5, h6) { font-size: inherit; font-weight: inherit; }
:where(html.tgx-pure) :where(a) { color: inherit; text-decoration: inherit; }
:where(html.tgx-pure) :where(b, strong) { font-weight: 700; }
:where(html.tgx-pure) :where(code, kbd, samp, pre) { font-family: var(--tg-font-mono); font-size: 1em; }
:where(html.tgx-pure) :where(small) { font-size: 80%; }
:where(html.tgx-pure) :where(sub, sup) { font-size: 75%; line-height: 0; position: relative; vertical-align: baseline; }
:where(html.tgx-pure) :where(sub) { bottom: -0.25em; }
:where(html.tgx-pure) :where(sup) { top: -0.5em; }
:where(html.tgx-pure) :where(table) { text-indent: 0; border-color: inherit; border-collapse: collapse; }
:where(html.tgx-pure) :where(button, input, optgroup, select, textarea) {
  margin: 0;
  padding: 0;
  color: inherit;
  font-family: inherit;
  font-feature-settings: inherit;
  font-variation-settings: inherit;
  font-size: 100%;
  font-weight: inherit;
  line-height: inherit;
  letter-spacing: inherit;
}
:where(html.tgx-pure) :where(button, select) { text-transform: none; }
:where(html.tgx-pure) :where(button, input[type="button"], input[type="reset"], input[type="submit"]) {
  -webkit-appearance: button;
  background-color: transparent;
  background-image: none;
}
:where(html.tgx-pure) :where(blockquote, dl, dd, h1, h2, h3, h4, h5, h6, hr, figure, p, pre) { margin: 0; }
:where(html.tgx-pure) :where(fieldset) { margin: 0; padding: 0; }
:where(html.tgx-pure) :where(legend) { padding: 0; }
:where(html.tgx-pure) :where(ol, ul, menu) { margin: 0; padding: 0; list-style: none; }
:where(html.tgx-pure) :where(textarea) { resize: vertical; }
:where(html.tgx-pure) :where(input, textarea)::placeholder { opacity: 1; color: var(--tg-ink-3); }
:where(html.tgx-pure) :where(button, [role="button"]) { cursor: pointer; }
:where(html.tgx-pure) :where(:disabled) { cursor: default; }
:where(html.tgx-pure) :where(img, svg, video, canvas, audio, iframe, embed, object) { display: block; vertical-align: middle; }
:where(html.tgx-pure) :where(summary) { display: list-item; }

/* Visually hidden, still read by screen readers and kept by the i18n pass.
   html.tgx (0,2,1) out-ranks a utility or a component's own position. */
html.tgx .tgx-sr {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
/* Skip link: hidden until focused */
.tgx-skip {
  position: absolute;
  left: var(--tg-space-4);
  top: var(--tg-space-2);
  z-index: calc(var(--tg-z-header) + 1);
  padding: var(--tg-space-2) var(--tg-space-4);
  border-radius: var(--tg-radius-pill);
  background-color: #FFFFFF;
  color: var(--tg-gray-950);
  font-size: var(--tg-fs-button-s);
  line-height: var(--tg-lh-ui);
  text-decoration: none;
  transform: translateY(-200%);
}
.tgx-skip:focus-visible { transform: none; outline-color: var(--tg-violet-400); }
@media (pointer: coarse) { .tgx-skip { display: inline-flex; align-items: center; box-sizing: border-box; min-height: var(--tg-hit-min); } }   /* 44px on touch (QA T14) */

/* Material Symbols: one optical setting everywhere (head.php keeps the
   fonts-loaded fade-in). Icons always carry aria-hidden="true". This rule
   (0,2,1) out-ranks a component's own font-variation-settings on purpose; a
   component changes an axis through the variables instead, on the icon or on
   any ancestor: --tg-icon-fill (0 or 1), --tg-icon-wght (100 to 700),
   --tg-icon-opsz (20 to 48); --tg-icon-grade comes from the band. */
html.tgx .material-symbols-outlined {
  font-variation-settings: "FILL" var(--tg-icon-fill, 0), "wght" var(--tg-icon-wght, 400), "GRAD" var(--tg-icon-grade, 0), "opsz" var(--tg-icon-opsz, 24);
  line-height: var(--tg-lh-ui);
  user-select: none;
}
/* Without JS nothing adds .fonts-loaded (head.php), so the icons show at once;
   font-display: block still keeps them blank while the font loads (QA T17). */
html.tgx:not(.js) .material-symbols-outlined { opacity: 1; }


/* 4. Type roles ---------------------------------------------------------------
   One class of specificity, on purpose. The utility CDN injects its reset
   after this file (h1-h6 { font-size: inherit }, p { margin: 0 },
   * { border-width: 0 }, a { color: inherit }), and a zero-specificity
   :where() helper loses to every one of those. A single class beats the
   reset, while utilities and page CSS, which load later, still win. */
.tgx-t-display-xl, .tgx-t-display-l, .tgx-t-display-p, .tgx-t-display-m, .tgx-t-stat {
  font-family: var(--tg-font-sans);
  font-weight: var(--tg-fw-light);
  font-feature-settings: var(--tg-ff-display);
  text-wrap: balance;
  overflow-wrap: break-word;
  margin: 0;
}
/* Headlines: line-height 1.15 on both grounds (no dark bump), as on hume.ai.
   display-p: product and policy H1s; display-m: section H2s. */
.tgx-t-display-xl { font-size: var(--tg-fs-display-xl); line-height: var(--tg-lh-display-xl); letter-spacing: var(--tg-ls-display-xl); }
.tgx-t-display-l  { font-size: var(--tg-fs-display-l);  line-height: var(--tg-lh-display-l);  letter-spacing: var(--tg-ls-display-l); }
.tgx-t-display-p  { font-size: var(--tg-fs-display-p);  line-height: var(--tg-lh-display-p);  letter-spacing: var(--tg-ls-display-p); }
.tgx-t-display-m  { font-size: var(--tg-fs-display-m);  line-height: var(--tg-lh-display-m);  letter-spacing: var(--tg-ls-display-m); }
.tgx-t-stat       { font-size: var(--tg-fs-stat);       line-height: var(--tg-lh-stat); letter-spacing: var(--tg-ls-display-l); }
.tgx-t-title-l {
  font-family: var(--tg-font-sans);
  font-weight: var(--tg-fw-regular);
  font-size: var(--tg-fs-title-l);
  line-height: calc(var(--tg-lh-title) + var(--tg-lh-bump));
  letter-spacing: var(--tg-ls-title);
  text-wrap: balance;
  margin: 0;
}
.tgx-t-title-m, .tgx-t-title-s {
  font-family: var(--tg-font-sans);
  font-weight: var(--tg-fw-medium);
  -webkit-text-stroke: var(--tg-medium-stroke-l) currentColor;
  paint-order: stroke fill;
  line-height: calc(var(--tg-lh-title) + var(--tg-lh-bump));
  letter-spacing: var(--tg-ls-title);
  text-wrap: balance;
  margin: 0;
}
.tgx-t-title-m { font-size: var(--tg-fs-title-m); }
.tgx-t-title-s { font-size: var(--tg-fs-title-s); -webkit-text-stroke-width: var(--tg-medium-stroke); }
.tgx-t-body-l, .tgx-t-body-m, .tgx-t-body-s, .tgx-t-caption {
  font-family: var(--tg-font-sans);
  font-weight: var(--tg-fw-regular);
  letter-spacing: var(--tg-ls-body);
  text-wrap: pretty;
}
.tgx-t-body-l  { font-size: var(--tg-fs-body-l);  line-height: calc(var(--tg-lh-body-l) + var(--tg-lh-bump)); }
.tgx-t-body-m  { font-size: var(--tg-fs-body-m);  line-height: calc(var(--tg-lh-body) + var(--tg-lh-bump)); }
.tgx-t-body-s  { font-size: var(--tg-fs-body-s);  line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump)); }
.tgx-t-caption { font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); }
.tgx-t-label, .tgx-t-label-s {
  font-family: var(--tg-font-mono);
  font-weight: var(--tg-fw-regular);
  line-height: var(--tg-lh-label);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  font-variant-ligatures: none;
}
.tgx-t-label   { font-size: var(--tg-fs-label); }
.tgx-t-label-s { font-size: var(--tg-fs-label-s); }
.tgx-t-data, .tgx-t-data-s, .tgx-t-code {
  font-family: var(--tg-font-mono);
  font-weight: var(--tg-fw-regular);
  font-variant-ligatures: none;
}
.tgx-t-data   { font-size: var(--tg-fs-data);   line-height: var(--tg-lh-data); }
.tgx-t-data-s { font-size: var(--tg-fs-data-s); line-height: var(--tg-lh-data); }
.tgx-t-code   { font-size: var(--tg-fs-code);   line-height: var(--tg-lh-code); tab-size: 2; }
/* Synthetic medium for UI text in Aeonik */
.tgx-medium, .tgx-t-button, .tgx-t-nav {
  font-family: var(--tg-font-sans);
  font-weight: var(--tg-fw-medium);
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  letter-spacing: var(--tg-ls-ui);
}
:where(html.tgx:lang(ja)) :where(.tgx-t-display-xl, .tgx-t-display-l, .tgx-t-display-p, .tgx-t-display-m, .tgx-t-title-l, .tgx-t-title-m) {
  word-break: auto-phrase;
}
/* Ink helpers */
.tgx-ink   { color: var(--tg-ink); }
.tgx-ink-2 { color: var(--tg-ink-2); }
.tgx-ink-3 { color: var(--tg-ink-3); }
.tgx-brand { color: var(--tg-brand-ink); }   /* a purple word in running text: flat, never gradient text */
/* Headings are one colour (D27, F-24). A heading made of two full sentences
   prints the second in ink-3 (.tgx-tone; the dark ink-3 on black), and a
   .tgx-brand word inside a heading takes the heading's colour, so purple
   never appears in a heading. */
.tgx-tone { color: var(--tg-ink-3); }
:is(h1, h2, h3, h4, h5, h6, [class*="tgx-t-display"], [class*="tgx-t-title"]) .tgx-brand { color: inherit; }


/* 5. Layout and frames ------------------------------------------------------
   Structure, as on hume.ai:
     <section class="tgx-band tgx-light tgx-rule-top">  full-bleed band
       <div class="tgx-wrap">                          max 1296 + gutters
         <div class="tgx-frame">                       side hairlines + padding
   Unframed bands put their padding on .tgx-band and use .tgx-wrap-content. */
.tgx-wrap {
  box-sizing: border-box;
  width: 100%;
  max-width: calc(var(--tg-w-frame) + 2 * var(--tg-gutter));
  margin-inline: auto;
  padding-inline: var(--tg-gutter);
}
.tgx-wrap-content {
  box-sizing: border-box;
  width: 100%;
  max-width: calc(var(--tg-w-content) + 2 * var(--tg-gutter));
  margin-inline: auto;
  padding-inline: var(--tg-gutter);
}
.tgx-narrow { max-width: var(--tg-w-narrow); margin-inline: auto; }
.tgx-prose  { max-width: var(--tg-w-prose); }
.tgx-frame {
  box-sizing: border-box;
  border-inline: var(--tg-frame-line) solid var(--tg-frame);
  padding-inline: var(--tg-frame-pad);
  padding-block: var(--tg-section-y);
}
.tgx-frame--lg    { padding-block: var(--tg-section-y-lg); }
.tgx-frame--flush { padding-inline: 0; }
.tgx-rule-top     { border-top: 1px solid var(--tg-frame); }
.tgx-rule-bottom  { border-bottom: 1px solid var(--tg-frame); }

/* 5.2 Bands: full-bleed sections. Padding lives here unless the band is framed. */
.tgx-band {
  position: relative;
  padding-block: var(--tg-section-y);
}
.tgx-band--lg     { padding-block: var(--tg-section-y-lg); }
.tgx-band--framed { padding-block: 0; }   /* the .tgx-frame inside carries it */
.tgx-band--sunken { background-color: var(--tg-surface-sunken); }
.tgx-band--deep   { background-color: var(--tg-black-deep); }

/* 5.3 Section heading block */
.tgx-head { margin-bottom: var(--tg-stack-head); }
.tgx-head--center { text-align: center; margin-inline: auto; max-width: var(--tg-w-narrow); }
.tgx-head > * + * { margin-top: var(--tg-space-6); }
@media (min-width: 64rem) {
  .tgx-head--split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--tg-space-6);
    align-items: end;
  }
  .tgx-head--split > * + * { margin-top: 0; }
}

/* 5.4 Hero with the straddling demo card (brand-system 4.5). The black block
   is a flat ::before that stops --tg-hero-straddle above the section bottom,
   so the card's lower part sits on white. No gradient anywhere. */
.tgx-hero {
  position: relative;
  isolation: isolate;
  margin-top: calc(-1 * var(--tg-header-h));
  padding-top: calc(var(--tg-header-h) + var(--tg-hero-pt));
  padding-bottom: 0;
  background-color: var(--tg-white);
}
.tgx-hero::before {
  content: "";
  position: absolute;
  inset: 0 0 var(--tg-hero-straddle) 0;
  background-color: var(--tg-black);
  z-index: -1;
}
.tgx-hero--compact { padding-bottom: var(--tg-section-y); background-color: var(--tg-black); }
.tgx-hero--compact::before { inset: 0; }
.tgx-hero__copy { max-width: var(--tg-w-narrow); margin-inline: auto; text-align: center; }
.tgx-hero__stage { position: relative; margin-top: var(--tg-stack-stage); }
.tgx-demo {
  position: relative;
  z-index: var(--tg-z-raised);
  max-width: var(--tg-w-content);
  margin-inline: auto;
  padding: var(--tg-demo-pad);
  border-radius: var(--tg-radius-xl);
  background-color: var(--tg-surface-sunken);
  box-shadow: var(--tg-shadow-demo);
}
/* 5.5 Product hero (D18, F-23; DESIGN 3.2 H-P and H-C). Two grid rows: row 1
   holds everything on black (the split head), row 2 the object that
   straddles the edge. The black is the ::before on row 1, pulled up over
   the header padding and down through the row gap plus --tg-hero-edge, so
   it ends that far into the top of the object whatever the object's
   height. The homepage hero and --tg-hero-straddle are not involved.
     <section class="tgx-hero tgx-dark tgx-hero--product" id="hero">
       <div class="tgx-wrap-content"><div class="tgx-head tgx-head--split">
         <div> eyebrow, h1.tgx-t-display-p </div>
         <div> lede (tgx-t-body-l), .tgx-cta-row </div>
       </div></div>
       <div class="tgx-wrap-content tgx-light"> the object </div>
     </section>
   A context class on a row switches the tokens and never paints over the
   black. A hero with nothing to straddle ends on the edge, as
   .tgx-hero--compact does. A page that changes the hero's top padding sets
   --tgx-hero-top instead, so the black still starts at the top. */
.tgx-hero--product {
  --tgx-hero-top: calc(var(--tg-header-h) + var(--tg-hero-pt));
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  row-gap: var(--tg-hero-gap);
  align-content: start;
  padding-top: var(--tgx-hero-top);
  padding-bottom: 0;
  background-color: var(--tg-white);
}
.tgx-hero--product::before {
  position: static;                          /* a grid item on row 1 */
  grid-row: 1;
  grid-column: 1;
  margin-top: calc(-1 * var(--tgx-hero-top));
  margin-bottom: calc(-1 * (var(--tg-hero-gap) + var(--tg-hero-edge)));
}
.tgx-hero--product > :first-child { grid-row: 1; grid-column: 1; }
.tgx-hero--product > * { min-width: 0; }
.tgx-hero--product > :first-child,
.tgx-hero--product > :first-child > :last-child { margin-bottom: 0; }   /* the row gap is the only space above the object */
:where(.tgx-hero--product) > :where(.tgx-light, .tgx-dark) { background-color: transparent; }
.tgx-hero--product:not(:has(> * + *)) { padding-bottom: var(--tg-section-y); background-color: var(--tg-black); }
.tgx-hero--product:not(:has(> * + *))::before { margin-bottom: 0; }
/* Split row (Hume 14.1): H1 column up to 600 px, lede and pills up to 440 */
@media (min-width: 64rem) {
  .tgx-hero--product .tgx-head--split > :first-child { max-width: 37.5rem; }
  .tgx-hero--product .tgx-head--split > :last-child { max-width: 27.5rem; }
}
/* Long-tail pages slide nothing under the header; rebuilt pages opt in. */


/* 6. Components --------------------------------------------------------------- */
/* 6.1 Buttons (brand-system 4.1). One primary per view. */
.tgx-btn {
  --tgx-btn-h: var(--tg-btn-h-m);
  --tgx-btn-px: var(--tg-btn-px-m);
  --tgx-btn-fs: var(--tg-fs-button-m);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--tg-btn-gap);
  box-sizing: border-box;
  min-height: var(--tgx-btn-h);
  max-inline-size: 100%;                  /* never wider than its row (QA T23: fr at 320) */
  padding: 0.375rem var(--tgx-btn-px);    /* room for a second line; one line stays at min-height */
  border: 0;
  border-radius: var(--tg-radius-pill);
  font-family: var(--tg-font-sans);
  font-size: var(--tgx-btn-fs);
  font-weight: var(--tg-fw-medium);
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  line-height: var(--tg-lh-ui);
  letter-spacing: var(--tg-ls-ui);
  text-align: center;
  text-wrap: balance;                     /* the label wraps only when the pill would overflow */
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition-property: background-color, box-shadow, color, scale;
  transition-duration: var(--tg-dur-fast);
  transition-timing-function: var(--tg-ease-standard);
}
.tgx-btn:active { scale: var(--tg-press-scale); }
.tgx-btn .material-symbols-outlined { font-size: var(--tg-icon-s); }
.tgx-btn--l { --tgx-btn-h: var(--tg-btn-h-l); --tgx-btn-px: var(--tg-btn-px-l); --tgx-btn-fs: var(--tg-fs-button-l); }
.tgx-btn--s { --tgx-btn-h: var(--tg-btn-h-s); --tgx-btn-px: var(--tg-btn-px-s); --tgx-btn-fs: var(--tg-fs-button-s); }
.tgx-btn--block { display: flex; width: 100%; }
.tgx-btn--primary { background-color: var(--tg-action); color: var(--tg-action-ink); }
.tgx-btn--secondary { background-color: var(--tgx-btn2-bg); box-shadow: var(--tgx-btn2-ring); color: var(--tg-ink); }
.tgx-btn--inverse { background-color: var(--tgx-btn3-bg); color: var(--tgx-btn3-ink); }
/* Hover only where a pointer hovers, so a tap leaves no colour behind:
   primary #6D28D9 on white and #7431E3 on black, dark secondary #2C2C2F. */
@media (hover: hover) and (pointer: fine) {
  .tgx-btn--primary:hover { background-color: var(--tg-action-hover); }
  .tgx-btn--secondary:hover { background-color: var(--tgx-btn2-bg-h); }
  .tgx-btn--inverse:hover { background-color: var(--tgx-btn3-bg-h); }
}
.tgx-btn--primary:active { background-color: var(--tg-action-active); }
.tgx-btn--secondary:active { background-color: var(--tgx-btn2-bg-a); }
.tgx-btn--inverse:active { background-color: var(--tgx-btn3-bg-a); }
.tgx-btn[aria-disabled="true"], .tgx-btn:disabled {
  background-color: var(--tg-surface-sunken);
  color: var(--tg-ink-muted, var(--tg-ink-2));
  box-shadow: none;
  cursor: not-allowed;
  scale: 1;
}
/* CTA row. A pill keeps its own width (hume.ai); below 640 two pills share the row
   while both fit, else they wrap one under the other, and below 360 they take the
   full width (DESIGN 3.9, FND-2). */
.tgx-cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--tg-space-3); }   /* each pill keeps its own height */
.tgx-cta-row--center { justify-content: center; }
@media (max-width: 39.99rem) {
  .tgx-cta-row > .tgx-btn { flex: 0 1 auto; }   /* hume.ai: an auto-width pill at every width (FND-2) */
}
@media (max-width: 22.49rem) {
  .tgx-cta-row > .tgx-btn { flex: 1 1 auto; }   /* 320: the pair shares the row or stacks full width (DESIGN 3.9) */
}
/* Touch: every button and arrow link gets a 44 px hit area centred on it;
   the pill keeps its 40 or 32 px (D29, K14). */
@media (pointer: coarse) {
  .tgx-btn::after,
  .tgx-arrow::after {
    content: "";
    position: absolute;
    inset-block: min(0px, calc((100% - var(--tg-hit-min)) / 2));
    inset-inline: min(0px, calc((100% - var(--tg-hit-min)) / 2));
  }
}

/* 6.2 Links */
.tgx-link {
  color: var(--tg-link);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color var(--tg-dur-fast) var(--tg-ease-standard);
}
@media (hover: hover) and (pointer: fine) { .tgx-link:hover { color: var(--tg-link-hover); } }
.tgx-arrow {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--tg-space-1-5);
  color: var(--tg-ink);
  font-weight: var(--tg-fw-medium);
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  text-decoration: none;
}
.tgx-arrow .material-symbols-outlined {
  font-size: var(--tg-icon-s);
  transition: translate var(--tg-dur-fast) var(--tg-ease-standard);
}
@media (hover: hover) and (pointer: fine) {
  .tgx-arrow:hover .material-symbols-outlined { translate: 2px 0; }
}

/* 6.3 Eyebrow (one mono kicker per section head, never decoration) */
.tgx-eyebrow {
  display: inline-block;
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-label);
  font-weight: var(--tg-fw-regular);
  line-height: var(--tg-lh-label);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  font-variant-ligatures: none;
  color: var(--tg-ink-3);
}
/* Ring (F-6, D7): opt-in, and only in a stats intro (Hume's intro cell
   carries an 18 px ring before its eyebrow, 8 px gap); every other eyebrow
   stays plain. Flat: a 3 px band in the strong line around a 12 px dot in
   the card surface with a hairline edge; the context tokens flip it on
   black. Decoration only, so it is a pseudo-element with empty content. */
.tgx-eyebrow--ring {
  display: inline-flex;
  align-items: center;
  gap: var(--tg-space-2);
}
.tgx-eyebrow--ring::before {
  content: "";
  flex: none;
  box-sizing: border-box;
  inline-size: var(--tg-icon-s);
  block-size: var(--tg-icon-s);
  border: 3px solid var(--tg-line-strong);
  border-radius: var(--tg-radius-pill);
  background-color: var(--tg-surface);
  box-shadow: inset 0 0 0 1px var(--tg-line);
}

/* 6.4 Chips (filters, aria-pressed) and static tags */
.tgx-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--tg-space-1-5);
  min-height: var(--tg-chip-h);
  padding: 0 var(--tg-chip-px);
  border: 0;
  border-radius: var(--tg-radius-pill);
  background-color: var(--tgx-chip-bg);
  color: var(--tgx-chip-ink);
  font-family: var(--tg-font-sans);
  font-size: var(--tg-fs-button-s);
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  line-height: var(--tg-lh-ui);
  text-decoration: none;
  transition-property: background-color, color, scale;
  transition-duration: var(--tg-dur-fast);
  transition-timing-function: var(--tg-ease-standard);
}
button.tgx-chip { cursor: pointer; }
button.tgx-chip::after { content: ""; position: absolute; inset: -6px 0; }
@media (hover: hover) and (pointer: fine) { button.tgx-chip:hover { background-color: var(--tgx-chip-bg-h); color: var(--tg-ink); } }
button.tgx-chip:active { scale: var(--tg-press-scale); }
.tgx-chip[aria-pressed="true"], .tgx-chip[aria-selected="true"] { background-color: var(--tg-brand-soft); color: var(--tg-brand-soft-ink); }

/* 6.5 Badges: static, 20px, radius 4 (never mistaken for a pill button) */
.tgx-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--tg-space-1-5);
  min-height: var(--tg-badge-h);
  padding: 0 var(--tg-badge-px);
  border-radius: var(--tg-radius-xs);
  background-color: var(--tgx-badge-bg);
  color: var(--tg-ink-2);
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-label-s);
  line-height: var(--tg-lh-ui);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  white-space: nowrap;
}
.tgx-badge--brand    { background-color: var(--tg-brand-soft); color: var(--tg-brand-soft-ink); }
.tgx-badge--live     { background-color: var(--tg-live-bg); color: var(--tg-live-ink); }
.tgx-badge--pending  { background-color: var(--tg-pending-bg); color: var(--tg-pending-ink); }
.tgx-badge--rejected { background-color: var(--tg-rejected-bg); color: var(--tg-rejected-ink); }
.tgx-badge > .tgx-dot { width: 6px; height: 6px; border-radius: 50%; background-color: currentColor; }

/* 6.6 Cards */
.tgx-card {
  position: relative;
  border-radius: var(--tg-radius-lg);
  background-color: var(--tg-surface);
  box-shadow: var(--tg-shadow-card);
  padding: var(--tg-card-pad);
}
.tgx-card--link { transition: box-shadow var(--tg-dur-fast) var(--tg-ease-standard); }
@media (hover: hover) and (pointer: fine) { .tgx-card--link:hover { box-shadow: var(--tg-shadow-card-hover); } }
.tgx-icon-tile {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--tg-radius-md);
  background-color: var(--tg-surface-sunken);
  color: var(--tg-ink-2);
}
.tgx-icon-tile .material-symbols-outlined { font-size: var(--tg-icon-l); }   /* weight 400 like every icon (its old "wght 300" never applied) */

/* 6.7 Form fields (white sections; the tokens re-point inside .tgx-dark).
   The html.tgx prefix out-ranks the forms plugin, whose [type] rules and
   blue :focus ring load after this file. */
.tgx-label { display: block; margin-bottom: var(--tg-space-2); color: var(--tg-ink); font-size: var(--tg-fs-body-s); line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump)); -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill; }
html.tgx .tgx-input {
  box-sizing: border-box;
  display: block;
  width: 100%;
  min-height: var(--tg-field-h);
  padding: 0 var(--tg-field-px);
  border: 1px solid var(--tg-line-field);
  border-radius: var(--tg-radius-md);
  background-color: var(--tg-surface);
  box-shadow: none;
  color: var(--tg-ink);
  font-family: var(--tg-font-sans);
  font-size: var(--tg-fs-body-m);
  line-height: var(--tg-lh-body);
  transition: border-color var(--tg-dur-fast) var(--tg-ease-standard), box-shadow var(--tg-dur-fast) var(--tg-ease-standard);
}
html.tgx .tgx-input::placeholder { color: var(--tg-ink-3); opacity: 1; }
@media (hover: hover) and (pointer: fine) { html.tgx .tgx-input:hover { border-color: var(--tg-gray-600); } }
html.tgx .tgx-input:focus, html.tgx .tgx-input:focus-visible { outline: none; border-color: var(--tg-focus); box-shadow: 0 0 0 3px var(--tg-focus-halo); }
html.tgx .tgx-input[aria-invalid="true"] { border-color: var(--tg-rejected-ink); }
html.tgx .tgx-input:disabled { background-color: var(--tg-surface-sunken); color: var(--tg-ink-disabled); cursor: not-allowed; }
html.tgx textarea.tgx-input { min-height: 9rem; padding-block: var(--tg-space-3); resize: vertical; }
html.tgx select.tgx-input { padding-right: 2.75rem; background-position: right 0.875rem center; background-size: 1.25rem 1.25rem; }

/* 6.8 Shared behaviours (js/tgx.js 1.4.0, F-21; FOUNDATION.md 4.1). The
   script writes the state attributes; these rules draw them, so a resize
   needs no script. */
/* [data-tgx-more]: below 640 the rows past N wait behind the button; from
   640 every row shows and the button is not drawn. */
@media (max-width: 39.99rem) {
  html.tgx [data-tgx-more-st="cut"] [data-tgx-more-cut] { display: none; }
}
@media (min-width: 40rem) {
  html.tgx [data-tgx-more] [data-tgx-more-btn] { display: none; }
}
/* [data-tgx-collapse] at 640 (the default) and 1024: from the first paint
   until the script closes it, a details it will close already looks closed
   (content hidden, the summary icon at rest), so closing it on load shifts
   nothing. If the script has not run 3 s after the head, head.php sets
   html[data-tgx-late] and the content shows. Without JS (no html.js) the
   details is simply open. */
@media (max-width: 39.99rem) {
  html.js:not([data-tgx-ready]):not([data-tgx-late]) :is(details[data-tgx-collapse=""], details[data-tgx-collapse="640"], [data-tgx-collapse=""] details, [data-tgx-collapse="640"] details)[open] > :not(summary) { display: none; }
  html.js:not([data-tgx-ready]):not([data-tgx-late]) :is(details[data-tgx-collapse=""], details[data-tgx-collapse="640"], [data-tgx-collapse=""] details, [data-tgx-collapse="640"] details)[open] > summary .material-symbols-outlined { rotate: none; transform: none; transition: none; }
}
@media (max-width: 63.99rem) {
  html.js:not([data-tgx-ready]):not([data-tgx-late]) :is(details[data-tgx-collapse="1024"], [data-tgx-collapse="1024"] details)[open] > :not(summary) { display: none; }
  html.js:not([data-tgx-ready]):not([data-tgx-late]) :is(details[data-tgx-collapse="1024"], [data-tgx-collapse="1024"] details)[open] > summary .material-symbols-outlined { rotate: none; transform: none; transition: none; }
}


/* 7. Chrome ---------------------------------------------------------------- */
/* Icons in the chrome keep a fixed 1em box, so nothing shifts while the icon
   font is still loading (head.php fades icons in on html.fonts-loaded). */
:where(.tgx-header, .tgx-sheet, .tgx-announce, .tgx-footer) .material-symbols-outlined {
  flex: none;
  width: 1em;
  height: 1em;
  overflow: hidden;
}

/* 7.1 Header (brand-system 4.3). A sticky black 56px bar that never changes
   on scroll: no frost, no blur, no hairline, no hide. */
.tgx-header {
  position: sticky;
  top: 0;
  z-index: var(--tg-z-header);
  height: var(--tg-header-h);
  background-color: var(--tg-black);
  color: var(--tg-ink);
  font-family: var(--tg-font-sans);
  line-height: var(--tg-lh-title);
}
.tgx-header__row {
  position: relative;                       /* containing block of every flyout */
  display: grid;
  grid-template-columns: 1fr auto 1fr;      /* the groups sit on the true center while there is room */
  align-items: center;
  column-gap: var(--tg-space-4);
  height: 100%;
}
.tgx-header__logo {
  grid-column: 1;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  height: var(--tg-hit-min);
  border-radius: var(--tg-radius-sm);
}
html.tgx .tgx-header__logo img { display: block; width: auto; height: 1.5rem; max-width: none; }   /* out-ranks the base img rule */
.tgx-header__end {
  grid-column: 3;
  justify-self: end;
  display: flex;
  align-items: center;
  gap: var(--tg-space-2);
  height: 100%;
}
.tgx-header__cta { display: none; }
@media (min-width: 40rem) { .tgx-header__cta { display: inline-flex; } }
/* Chrome buttons carry their own reset: nothing here waits for a preflight */
.tgx-lang__btn, .tgx-burger {
  -webkit-appearance: none;
  appearance: none;
  background-color: transparent;
  font: inherit;
}

/* Groups (F-22, the disclosure pattern): one button per flyout group, and
   the Pricing link, drawn as the same 36px pill. 15px, #E8E8ED at rest,
   white on hover, while open and on the current group (desktop critic 26);
   the colour fades with the fill (motion critic M13). */
.tgx-nav { grid-column: 2; display: none; height: 100%; }
@media (min-width: 64rem) { .tgx-nav { display: block; } }
.tgx-nav__list {
  display: flex;
  align-items: stretch;
  gap: var(--tg-space-0-5);
  height: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}
.tgx-nav__group { display: flex; align-items: center; height: 100%; }   /* full bar height: the pointer never falls in a gap */
.tgx-nav__trigger {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--tg-space-1);
  box-sizing: border-box;
  height: var(--tg-nav-link-h);
  margin: 0;
  padding: 0 var(--tg-nav-link-px);
  border: 0;
  border-radius: var(--tg-radius-pill);
  background-color: transparent;
  color: var(--tg-gray-100);
  font: inherit;
  font-size: var(--tg-fs-nav);
  line-height: var(--tg-lh-ui);
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--tg-dur-fast) var(--tg-ease-standard), color var(--tg-dur-fast) var(--tg-ease-standard);
}
button.tgx-nav__trigger { -webkit-appearance: none; appearance: none; padding-right: var(--tg-space-2); }
.tgx-nav__trigger::after { content: ""; position: absolute; inset: -4px 0; }   /* a 44px hit area */
.tgx-nav__chev.material-symbols-outlined {
  font-size: var(--tg-icon-xs);
  color: var(--tg-ink-2);
  -webkit-text-stroke: 0;
  transition: rotate var(--tg-dur-fast) var(--tg-ease-standard), color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-nav__group:is([data-tgx-current], [data-tgx-open]) > .tgx-nav__trigger { color: var(--tg-gray-0); }
.tgx-nav__group[data-tgx-open] > .tgx-nav__trigger { background-color: var(--tg-surface-hover); }
.tgx-nav__group[data-tgx-open] .tgx-nav__chev { rotate: 180deg; color: var(--tg-ink); }
@media (hover: hover) and (pointer: fine) {
  .tgx-nav__trigger:hover { background-color: var(--tg-surface-hover); color: var(--tg-gray-0); }
  .tgx-nav__trigger:hover .tgx-nav__chev { color: var(--tg-ink); }
}
/* 1024 to 1151: the same bar, a little tighter, so the longest translated
   labels still fit beside the logo and the pill */
@media (min-width: 64rem) and (max-width: 71.99rem) {
  .tgx-header__row { column-gap: var(--tg-space-3); }
  .tgx-nav__list { gap: 0; }
  .tgx-nav__trigger { padding-inline: var(--tg-space-2); }
  button.tgx-nav__trigger { padding-right: var(--tg-space-1-5); }
}

/* 7.2 Flyouts (F-11 to F-13). .tgx-fly spans the content box under the bar;
   its ::before is a spacer as wide as the trigger's offset (--tgx-fly-x, set
   by tgx.js) that shrinks first, so the panel is left-aligned to its trigger
   and can never leave the content box. A closed flyout is display: none:
   nothing in it lays out, takes focus or loads (the card's cover is lazy).
   The panel sits flush under the bar, radius 8, hume.ai's panel shadow and
   hairlines, at most 780px wide (Resources). Its columns carry mono heads,
   items are text rows (44px for a label alone, about 60px with a one-line
   description, both 15px; a longer description takes a second line rather
   than being cut), the last column is the featured card. */
.tgx-fly {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  display: none;
  padding-inline: var(--tg-gutter);
  pointer-events: none;
  transition: display var(--tg-dur-fast) allow-discrete;    /* stays laid out while the panel fades out */
}
.tgx-fly::before { content: ""; flex: 0 1 var(--tgx-fly-x, 0px); }
.tgx-nav__group[data-tgx-open] > .tgx-fly { display: flex; }
html:not([data-tgx-ready]) .tgx-nav__group:is(:hover, :focus-within) > .tgx-fly { display: flex; }
.tgx-fly__panel {
  position: relative;
  flex: 0 0 auto;                            /* the spacer gives way first */
  box-sizing: border-box;
  display: grid;                             /* one column per child: the panel is exactly as wide as its columns */
  grid-auto-flow: column;
  align-items: stretch;
  gap: var(--tg-space-2);
  min-width: 0;
  max-width: 100%;
  padding: var(--tg-space-2);
  border-radius: var(--tg-radius-md);
  background-color: var(--tg-surface-raised);
  box-shadow: var(--tg-shadow-panel);
  color: var(--tg-ink);
  pointer-events: auto;
  opacity: 0;
  transition: opacity var(--tg-dur-fast) var(--tg-ease-standard), transform var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-nav__group[data-tgx-open] > .tgx-fly > .tgx-fly__panel {
  opacity: 1;
  transform: none;
  transition-duration: var(--tg-dur-base);
  transition-timing-function: var(--tg-ease-out-quint);
}
html:not([data-tgx-ready]) .tgx-nav__group:is(:hover, :focus-within) > .tgx-fly > .tgx-fly__panel { opacity: 1; transform: none; }
@starting-style {
  .tgx-nav__group[data-tgx-open] > .tgx-fly > .tgx-fly__panel { opacity: 0; }
  html:not([data-tgx-ready]) .tgx-nav__group:is(:hover, :focus-within) > .tgx-fly > .tgx-fly__panel { opacity: 0; }
}
/* Moving from one open group to the next, and every keyboard open, is instant */
html.tgx .tgx-header[data-tgx-instant] :is(.tgx-fly, .tgx-fly__panel, .tgx-lang__menu) { transition-duration: 0s; transition-delay: 0s; }

/* Columns: a mono head, then text rows (no icon tiles). 336px holds what
   hume.ai's 287px column holds at its 12px descriptions (about 45 characters)
   at our 15px floor; the Company column fits its longest label (ja) */
.tgx-fly__col { display: flex; flex-direction: column; width: 21rem; min-width: 0; }
.tgx-fly__col--sub { width: 9.25rem; }
.tgx-fly__head,
.tgx-fly__cardhead {
  color: var(--tg-ink-3);                    /* #86868B: 4.99:1 on the panel, 5.43:1 on the card */
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-label-s);
  line-height: var(--tg-lh-label);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  font-variant-ligatures: none;
}
.tgx-fly__head { display: block; padding: var(--tg-space-2) var(--tg-space-3) var(--tg-space-1); }
.tgx-fly__items { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; }
.tgx-fly__item {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-sizing: border-box;
  min-height: var(--tg-hit-min);             /* 44: a label alone */
  padding: var(--tg-space-2) var(--tg-space-3);   /* about 60 with a one-line description, 83 with two */
  border-radius: var(--tg-radius-xs);
  color: var(--tg-ink);
  text-decoration: none;
  transition: background-color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-fly__item[aria-current] { background-color: var(--tg-surface-hover); }
.tgx-fly__label {
  display: flex;
  align-items: center;
  gap: var(--tg-space-1);
  color: var(--tg-gray-100);
  font-size: var(--tg-fs-caption);
  line-height: calc(var(--tg-lh-caption) + var(--tg-lh-bump));
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  transition: color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-fly__item[aria-current] .tgx-fly__label { color: var(--tg-gray-0); }
.tgx-fly__desc {
  display: block;                            /* never clamped: the REUSED copy shows whole. One line in most
                                                rows (as on hume.ai); a longer one takes a second, balanced line */
  color: var(--tg-ink-2);                    /* #B4B4B9: 8.75:1 on the panel, 7.7:1 on the hover fill */
  font-size: var(--tg-fs-caption);
  line-height: calc(var(--tg-lh-caption) + var(--tg-lh-bump));
  text-wrap: balance;
}
:where(html.tgx:lang(ja)) .tgx-fly__desc { word-break: auto-phrase; }   /* break between phrases, not mid-word */
/* The arrow after a row's label and a card's link: it slides in on hover
   (hume.ai 13.10) and stays on a link that opens a new tab. Drawn from the
   icon font in CSS with empty alternative text, so no icon name lands in a
   link's text or accessible name. */
.tgx-fly__label::after,
.tgx-fly__clink::after {
  content: "arrow_forward" / "";
  flex: none;
  display: inline-block;
  width: 1em;
  height: 1em;
  overflow: hidden;
  color: var(--tg-ink-2);
  font-family: "Material Symbols Outlined";
  font-size: var(--tg-icon-xs);
  font-weight: normal;
  font-style: normal;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 20;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  font-feature-settings: "liga";
  -webkit-text-stroke: 0;
  opacity: 0;
  translate: -4px 0;
  transition: opacity var(--tg-dur-fast) var(--tg-ease-standard), translate var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-fly__item[target="_blank"] .tgx-fly__label::after { content: "arrow_outward" / ""; color: var(--tg-ink-3); opacity: 1; translate: none; }
.tgx-fly__item:focus-visible .tgx-fly__label::after,
.tgx-fly__card:focus-within .tgx-fly__clink::after { opacity: 1; translate: none; }
html:not(.fonts-loaded) :is(.tgx-fly__label, .tgx-fly__clink)::after { visibility: hidden; }   /* never the icon's name in the fallback font */
@media (hover: hover) and (pointer: fine) {
  .tgx-fly__item:hover { background-color: var(--tg-surface-hover); }
  .tgx-fly__item:hover .tgx-fly__label { color: var(--tg-gray-0); }
  .tgx-fly__item:hover .tgx-fly__label::after,
  .tgx-fly__card:hover .tgx-fly__clink::after { opacity: 1; translate: none; }
}

/* Featured card (the last column): the bar's black inside the raised panel,
   radius 4 as on hume.ai. Its one link stretches over the whole card. */
.tgx-fly__card {
  position: relative;
  box-sizing: border-box;
  width: 16.5rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--tg-space-3);
  min-width: 0;
  padding: var(--tg-space-4);
  border-radius: var(--tg-radius-xs);
  background-color: var(--tg-black);
  color: var(--tg-ink);
  transition: box-shadow var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-fly__cardhead { display: flex; align-items: center; justify-content: space-between; gap: var(--tg-space-2); align-self: stretch; min-height: var(--tg-badge-h); }
.tgx-fly__cover {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 40 / 21;                     /* the covers are 1200 x 630 */
  object-fit: cover;
  border-radius: var(--tg-radius-xs);
  background-color: var(--tg-surface-raised);
  outline: 1px solid var(--tg-image-outline);
  outline-offset: -1px;
}
.tgx-fly__ctitle {
  color: var(--tg-ink);
  font-size: var(--tg-fs-caption);
  line-height: calc(var(--tg-lh-caption) + var(--tg-lh-bump));
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  text-wrap: balance;
}
.tgx-fly__clink {
  color: var(--tg-gray-100);
  font-size: var(--tg-fs-caption);
  line-height: calc(var(--tg-lh-caption) + var(--tg-lh-bump));
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  text-decoration: none;
  text-wrap: pretty;
  transition: color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-fly__clink::before { content: ""; position: absolute; inset: 0; border-radius: inherit; }   /* the whole card is the target */
.tgx-fly__clink::after { margin-left: var(--tg-space-1); vertical-align: -0.2em; }
html.tgx .tgx-fly__clink:focus-visible { outline: none; }
html.tgx .tgx-fly__clink:focus-visible::before { outline: var(--tg-focus-width) solid var(--tg-focus); outline-offset: var(--tg-focus-offset); }
.tgx-fly__cdesc {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  color: var(--tg-ink-2);
  font-size: var(--tg-fs-caption);
  line-height: calc(var(--tg-lh-caption) + var(--tg-lh-bump));
}
.tgx-fly__card--code .tgx-fly__clink { margin-top: auto; }
.tgx-fly__card--code .tgx-fly__clink::after { opacity: 1; translate: none; }
.tgx-fly__code {
  max-width: 100%;
  padding: var(--tg-space-1-5) var(--tg-space-2);
  border-radius: var(--tg-radius-xs);
  background-color: rgba(255, 255, 255, 0.06);
  color: var(--tg-ink);
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-data-s);
  line-height: var(--tg-lh-data);
  font-variant-ligatures: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tgx-fly__code > span { color: var(--tg-brand-ink); }
@media (hover: hover) and (pointer: fine) {
  .tgx-fly__card:hover { box-shadow: inset 0 0 0 1px var(--tg-line-strong); }
  .tgx-fly__card:hover .tgx-fly__clink { color: var(--tg-gray-0); }
}

/* 7.2b Page scrim behind an open flyout (F-11, D26): flat black at 65%, no
   blur, under the header (40 < 50) and over the page, the announcement bar
   included; 150ms fade; a click on it closes the flyout (tgx.js). Desktop
   only: below 1024 the sheet covers the page. */
.tgx-scrim {
  position: fixed;
  inset: 0;
  z-index: var(--tg-z-scrim);
  display: none;
  background-color: var(--tg-scrim);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--tg-dur-fast) var(--tg-ease-standard), visibility 0s linear var(--tg-dur-fast);
}
@media (min-width: 64rem) { .tgx-scrim { display: block; } }
html[data-tgx-scrim] .tgx-scrim { opacity: 1; visibility: visible; transition-delay: 0s; }
html:not([data-tgx-ready]) .tgx-header:has(.tgx-nav__group:is(:hover, :focus-within) > .tgx-fly) ~ .tgx-scrim { opacity: 1; visibility: visible; transition-delay: 0s; }
html.tgx .tgx-header[data-tgx-instant] ~ .tgx-scrim { transition-duration: 0s; transition-delay: 0s; }

/* 7.3 Language menu: globe plus the current code; native names, no flags */
.tgx-lang { position: relative; display: none; align-items: center; height: 100%; }
@media (min-width: 64rem) { .tgx-lang { display: flex; } }
.tgx-lang__btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--tg-space-1);
  height: var(--tg-nav-link-h);
  margin: 0;
  padding: 0 0.625rem;
  border: 0;
  border-radius: var(--tg-radius-pill);
  color: var(--tg-ink-2);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--tg-dur-fast) var(--tg-ease-standard), color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-lang__btn::after { content: ""; position: absolute; inset: -4px 0; }
.tgx-lang__btn .material-symbols-outlined { font-size: var(--tg-icon-m); }
.tgx-lang__code {
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-label);
  line-height: var(--tg-lh-ui);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  font-variant-ligatures: none;
}
.tgx-lang[data-tgx-open] > .tgx-lang__btn { background-color: var(--tg-surface-hover); color: var(--tg-ink); }
@media (hover: hover) and (pointer: fine) {
  .tgx-lang__btn:hover { background-color: var(--tg-surface-hover); color: var(--tg-ink); }
}
.tgx-lang__menu {
  position: absolute;
  top: 100%;
  right: 0;
  box-sizing: border-box;
  min-width: 12rem;
  margin: var(--tg-space-2) 0 0;
  padding: var(--tg-space-1);
  border-radius: var(--tg-radius-lg);
  background-color: var(--tg-surface-raised);
  box-shadow: var(--tg-shadow-pop);
  list-style: none;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity var(--tg-dur-fast) var(--tg-ease-standard), transform var(--tg-dur-fast) var(--tg-ease-standard), visibility 0s linear var(--tg-dur-fast);
}
.tgx-lang[data-tgx-open] > .tgx-lang__menu {
  visibility: visible;
  opacity: 1;
  transform: none;
  transition-duration: var(--tg-dur-base), var(--tg-dur-base), 0s;
  transition-timing-function: var(--tg-ease-out-quint), var(--tg-ease-out-quint), linear;
  transition-delay: 0s;
}
/* Before the script runs, and without JS, the list opens on hover or focus, as the flyouts do (QA T17) */
html:not([data-tgx-ready]) .tgx-lang:is(:hover, :focus-within) > .tgx-lang__menu { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
.tgx-lang__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--tg-space-3);
  min-height: 2.5rem;
  padding-inline: var(--tg-space-3);
  border-radius: var(--tg-radius-md);       /* 12 = 8 + 4 */
  color: var(--tg-ink-2);
  font-size: var(--tg-fs-body-s);
  line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump));
  text-decoration: none;
  transition: background-color var(--tg-dur-fast) var(--tg-ease-standard), color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-lang__item .material-symbols-outlined { font-size: var(--tg-icon-s); }
.tgx-lang__item[aria-current] { color: var(--tg-ink); }
@media (hover: hover) and (pointer: fine) {
  .tgx-lang__item:hover { background-color: var(--tg-surface-hover); color: var(--tg-ink); }
}

/* 7.4 Burger and mobile sheet (under 1024). The bars are drawn in CSS so the
   button shows before the icon font arrives. */
.tgx-burger {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--tg-hit-min);
  height: var(--tg-hit-min);
  margin: 0 -0.75rem 0 0;                    /* the bars end on the content edge */
  padding: 0;
  border: 0;
  border-radius: var(--tg-radius-pill);
  color: var(--tg-ink);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
@media (min-width: 64rem) { .tgx-burger { display: none; } }
html:not(.js) .tgx-burger { display: none; }   /* without JS the footer columns are the menu */
/* Without JS (QA T17) a plain link to those columns stands in for the burger
   (includes/nav.php), and below 64rem the language list shows as well. */
.tgx-header__menu { display: none; }
@media (max-width: 63.99rem) {
  html:not(.js) .tgx-header__menu { display: inline-flex; }
  html:not(.js) .tgx-lang { display: flex; }
}
.tgx-burger__box { position: relative; display: block; width: 1.25rem; height: 0.875rem; }
.tgx-burger__box > i {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  border-radius: 1px;
  background-color: currentColor;
  transition: transform var(--tg-dur-fast) var(--tg-ease-standard), opacity var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-burger__box > i:nth-child(1) { top: 0; }
.tgx-burger__box > i:nth-child(2) { top: 6px; }
.tgx-burger__box > i:nth-child(3) { top: 12px; }
.tgx-burger[aria-expanded="true"] .tgx-burger__box > i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.tgx-burger[aria-expanded="true"] .tgx-burger__box > i:nth-child(2) { opacity: 0; }
.tgx-burger[aria-expanded="true"] .tgx-burger__box > i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.tgx-sheet {
  position: fixed;
  inset: var(--tgx-sheet-top, var(--tg-header-h)) 0 0 0;   /* tgx.js measures the header bottom at open */
  z-index: var(--tg-z-sheet);
  display: flex;
  flex-direction: column;
  background-color: var(--tg-black);
  color: var(--tg-ink);
  font-family: var(--tg-font-sans);
  opacity: 0;
  transition: opacity var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-sheet[data-tgx-open] { opacity: 1; }
@media (min-width: 64rem) { .tgx-sheet { display: none; } }
html[data-tgx-lock] { overflow: hidden; scrollbar-gutter: stable; }
.tgx-sheet__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 0 var(--tg-gutter) var(--tg-space-8);
}
.tgx-sheet__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--tg-space-3);
  min-height: 3.5rem;
  border-bottom: 1px solid var(--tg-line);
  color: var(--tg-ink);
  font-size: var(--tg-fs-title-s);
  line-height: calc(var(--tg-lh-title) + var(--tg-lh-bump));
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  text-decoration: none;
  list-style: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.tgx-sheet__row::-webkit-details-marker { display: none; }
.tgx-sheet__row .material-symbols-outlined {
  font-size: var(--tg-icon-l);
  color: var(--tg-ink-2);
  -webkit-text-stroke: 0;
  transition: rotate var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-sheet__group[open] { border-bottom: 1px solid var(--tg-line); }
.tgx-sheet__group[open] > .tgx-sheet__row { border-bottom-color: transparent; }
.tgx-sheet__group[open] > .tgx-sheet__row .material-symbols-outlined { rotate: 180deg; }
.tgx-sheet__items { margin: 0; padding: 0 0 var(--tg-space-3); list-style: none; }
.tgx-sheet__item {
  display: flex;                            /* a label-only row is 44px tall, its label centered */
  flex-direction: column;
  justify-content: center;
  box-sizing: border-box;
  min-height: var(--tg-hit-min);
  margin-inline: calc(-1 * var(--tg-space-3));
  padding: 0.625rem var(--tg-space-3);
  border-radius: var(--tg-radius-md);
  color: var(--tg-ink);
  text-decoration: none;
}
.tgx-sheet__item[aria-current] { background-color: var(--tg-surface-hover); }
@media (hover: hover) and (pointer: fine) {
  .tgx-sheet__item:hover { background-color: var(--tg-surface-hover); }
}
.tgx-sheet__label { display: block; font-size: var(--tg-fs-body-s); line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump)); }
.tgx-sheet__desc { display: block; color: var(--tg-ink-2); font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); }
.tgx-sheet__sublabel {
  margin: var(--tg-space-3) 0 var(--tg-space-1);
  color: var(--tg-ink-3);
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-label);
  line-height: var(--tg-lh-label);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  font-variant-ligatures: none;
}
.tgx-sheet__langs { padding-top: var(--tg-space-6); }
.tgx-sheet__langs > .tgx-sheet__sublabel { margin: 0 0 var(--tg-space-3); }
.tgx-sheet__langlist { display: flex; flex-wrap: wrap; gap: var(--tg-space-2); margin: 0; padding: 0; list-style: none; }
.tgx-sheet__lang {
  display: inline-flex;
  align-items: center;
  min-height: var(--tg-hit-min);
  padding-inline: var(--tg-space-4);
  border-radius: var(--tg-radius-pill);
  background-color: rgba(255, 255, 255, 0.06);
  color: var(--tg-ink-2);
  font-size: var(--tg-fs-button-s);
  line-height: var(--tg-lh-ui);
  text-decoration: none;
}
.tgx-sheet__lang[aria-current] { background-color: var(--tgx-btn3-bg); color: var(--tgx-btn3-ink); }
.tgx-sheet__cta {
  flex: none;
  padding: var(--tg-space-3) var(--tg-gutter) calc(var(--tg-space-3) + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--tg-line);
  background-color: var(--tg-black);
}
@media (prefers-reduced-motion: reduce) {
  .tgx-fly__panel, .tgx-lang__menu { transform: none; }   /* opacity only */
  .tgx-fly__label::after, .tgx-fly__clink::after { translate: none; }
}
/* Header motion, motion.md 5.14 (taken from the motion spec's proposal,
   checked on its bench N2 to N5). Only with motion allowed; the reduced
   motion rule above keeps opacity only.
   1. Flyouts grow from their trigger: the panel opens from 98%, its x
      origin at the trigger's center (tgx.js place() writes --tgx-fly-ox)
      and its y origin on its own top edge, so the flush top never moves
      (F-12 dropped the 4px rise). It waits for data-tgx-ready, so the
      CSS-only hover fallback only fades. The instant rule is unchanged.
   2. The language menu grows from its button, top right, from 97%.
   3. The sheet box only fades (it stays flush under the bar); its body
      rises 8px, 220ms out-quint in, the built 150ms out.
   4. Sheet groups open with their height where the browser can
      interpolate to auto, at once elsewhere. */
@media (prefers-reduced-motion: no-preference) {
  html[data-tgx-ready] .tgx-fly__panel {
    transform: scale(.98);
    transform-origin: var(--tgx-fly-ox, 3.625rem) 0;
  }
  @starting-style {
    html[data-tgx-ready] .tgx-nav__group[data-tgx-open] > .tgx-fly > .tgx-fly__panel { transform: scale(.98); }
  }
  .tgx-lang__menu {
    transform: translateY(-4px) scale(.97);
    transform-origin: calc(100% - 2rem) 0;
  }
  .tgx-sheet[data-tgx-open] {
    transition-duration: var(--tg-dur-base);
    transition-timing-function: var(--tg-ease-out-quint);
  }
  .tgx-sheet__body {
    transform: translateY(8px);
    transition: transform var(--tg-dur-fast) var(--tg-ease-standard);
  }
  .tgx-sheet[data-tgx-open] > .tgx-sheet__body {
    transform: none;
    transition-duration: var(--tg-dur-base);
    transition-timing-function: var(--tg-ease-out-quint);
  }
  @supports (interpolate-size: allow-keywords) {
    .tgx-sheet__group { interpolate-size: allow-keywords; }
    .tgx-sheet__group::details-content {
      block-size: 0;
      overflow: visible clip;               /* only the height: an item's highlight runs 12px past the list */
      transition: block-size var(--tg-dur-base) var(--tg-ease-out-quint),
                  content-visibility var(--tg-dur-base) allow-discrete;
    }
    .tgx-sheet__group[open]::details-content { block-size: auto; }
  }
}

/* 7.5 Announcement bar (brand-system 4.4, F-18, D19): one full-width link
   above the header, read as a tag line: the "New" chip, the newest entry's
   title and an arrow, 13px, centred (the entry's description is not shown).
   36px on fine pointers, the title on one line (an ellipsis when it is too
   long; the full title is the span's title attribute); 44px on coarse
   pointers, where the title may take two lines. It scrolls away; the header
   under it is the sticky part. */
.tgx-announce {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--tg-space-2);
  box-sizing: border-box;
  height: var(--tg-announce-h);
  padding: 0 var(--tg-gutter);
  background-color: var(--tgx-announce-bg);
  color: #FFFFFF;
  font-family: var(--tg-font-sans);
  font-size: var(--tg-fs-label);
  line-height: var(--tg-lh-label);
  text-decoration: none;
  transition: background-color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-announce::after {                       /* the arrow, drawn in CSS: no icon name in the link text */
  content: "arrow_forward" / "";
  flex: none;
  display: inline-block;
  width: 1em;
  height: 1em;
  overflow: hidden;
  font-family: "Material Symbols Outlined";
  font-size: var(--tg-icon-s);
  font-weight: normal;
  font-style: normal;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 20;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  font-feature-settings: "liga";
  transition: translate var(--tg-dur-fast) var(--tg-ease-standard);
}
html.tgx .tgx-announce:focus-visible { outline: 2px solid #FFFFFF; outline-offset: -4px; }   /* the ring turns white on violet */
.tgx-announce__chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  height: var(--tg-badge-h);
  padding: 0 var(--tg-badge-px);
  border-radius: var(--tg-radius-xs);
  background-color: #FFFFFF;
  color: var(--tg-gray-950);
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-label-s);
  line-height: var(--tg-lh-ui);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  font-variant-ligatures: none;
  white-space: nowrap;
}
.tgx-announce__title {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
}
/* Touch: a 44px bar, still ONE line with an ellipsis (hume.ai: one line) */
@media (pointer: coarse) {
  .tgx-announce { height: var(--tg-hit-min); }
}
@media (hover: hover) and (pointer: fine) {
  .tgx-announce:hover { background-color: var(--tgx-announce-bg-hover); }
  .tgx-announce:hover::after { translate: 2px 0; }
}

/* The skip link lands on <main>; a programmatic focus there draws no ring */
html.tgx main:focus { outline: none; }

/* 7.6 Footer (brand-system 4.13, teardown 12.9). True black, one step below
   the bands, as hume.ai's footer steps down from its own. Not framed, but the
   content sits on the frame lines (.tgx-wrap, the 1296 box at 1440).
   Self-contained: no rule here waits for the utility reset. */
.tgx-footer {
  position: relative;
  padding: var(--tg-section-y) 0 var(--tg-space-12);
  background-color: var(--tg-black-deep);
  color: var(--tg-ink-2);
  font-family: var(--tg-font-sans);
  font-size: var(--tg-fs-body-s);
  line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump));
}
/* zero-specificity resets: they beat the UA defaults and lose to every class below */
:where(.tgx-footer) :where(h2, p, ul) { margin: 0; }
:where(.tgx-footer) :where(ul) { padding: 0; list-style: none; }
.tgx-footer__top {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  row-gap: var(--tg-space-12);
}
@media (min-width: 64rem) {
  .tgx-footer__top {
    grid-template-columns: minmax(0, 18.5rem) minmax(0, 1fr);   /* hume.ai: a 295px column, then 64 */
    column-gap: var(--tg-space-16);
  }
}
.tgx-footer__news { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; max-width: 27.5rem; }
.tgx-footer__logo { display: inline-flex; margin-bottom: var(--tg-space-8); border-radius: var(--tg-radius-sm); }
html.tgx .tgx-footer__logo img { display: block; width: auto; height: 1.75rem; max-width: none; }
/* The newsletter line in two tones, as on hume.ai, in the title-l role
   (brand-system 2.4, "newsletter heading"): regular, since weight 300
   starts at 28px (D15) */
.tgx-footer__pitch {
  color: var(--tg-ink);
  font-family: var(--tg-font-sans);
  font-size: var(--tg-fs-title-l);
  font-weight: var(--tg-fw-regular);
  line-height: calc(var(--tg-lh-title) + var(--tg-lh-bump));
  letter-spacing: var(--tg-ls-title);
  text-wrap: balance;
}
.tgx-footer__pitch--2 { color: var(--tg-ink-2); }
:where(html.tgx:lang(ja)) .tgx-footer__pitch { word-break: auto-phrase; font-size: 1.5rem; }   /* 12 glyphs fit the 296 px column on one line */
.tgx-footer__fine {
  margin-top: var(--tg-space-3);
  color: var(--tg-ink-3);
  font-size: var(--tg-fs-caption);
  line-height: var(--tg-lh-caption);
  text-wrap: pretty;
}
/* The Privacy Policy link that ends the fine print: kept on one line, with a
   24px target (44 on coarse pointers, below) from a centred ::after, so the
   line box and the text stay where they are (F-17) */
.tgx-footer__fine .tgx-link { position: relative; white-space: nowrap; }
.tgx-footer__fine .tgx-link::after { content: ""; position: absolute; inset-inline: 0; inset-block: min(0px, calc((100% - 1.5rem) / 2)); }

/* Newsletter group (brand-system 4.10): a 48px pill with the button inside */
.tgx-news { position: relative; width: 100%; margin-top: var(--tg-space-6); }
.tgx-news__group {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--tg-space-1);
  box-sizing: border-box;
  height: var(--tg-field-h);
  padding: var(--tg-space-1);
  border-radius: var(--tg-radius-pill);
  background-color: rgba(255, 255, 255, 0.06);              /* #0F0F0F on the footer */
  box-shadow: inset 0 0 0 1px var(--tg-gray-600);           /* 4.14:1: the field edge meets 3:1 */
  transition: box-shadow var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-news__group:focus-within { outline: var(--tg-focus-width) solid var(--tg-focus); outline-offset: var(--tg-focus-offset); }
@supports selector(:has(*)) {
  /* the ring follows the field; the button keeps its own ring */
  .tgx-news__group:focus-within { outline: none; }
  .tgx-news__group:has(.tgx-news__input:focus) { outline: var(--tg-focus-width) solid var(--tg-focus); outline-offset: var(--tg-focus-offset); }
}
html.tgx .tgx-news__input {
  flex: 1 1 auto;
  min-width: 0;
  height: 100%;
  margin: 0;
  padding: 0 0 0 var(--tg-space-4);                          /* 4 + 16: text starts 20px in */
  border: 0;
  border-radius: var(--tg-radius-pill);
  background-color: transparent;
  box-shadow: none;
  color: var(--tg-ink);
  caret-color: var(--tg-brand-ink);
  font-family: var(--tg-font-sans);
  font-size: var(--tg-fs-body-s);                            /* 16px: no zoom on iOS */
  line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump));
  outline: none;
}
html.tgx .tgx-news__input::placeholder { color: var(--tg-ink-3); opacity: 1; }
html.tgx .tgx-news__input:focus { outline: none; box-shadow: none; }
html.tgx .tgx-news__input:-webkit-autofill {                /* no light autofill slab on black */
  -webkit-text-fill-color: var(--tg-ink);
  box-shadow: inset 0 0 0 3rem #0F0F0F;
  transition: background-color 600000s 0s;
}
.tgx-news__btn {
  --tgx-btn-h: 2.5rem;
  --tgx-btn-px: var(--tg-space-5);
  --tgx-btn-fs: var(--tg-fs-button-s);
  flex: none;
}
.tgx-news__btn::after { content: ""; position: absolute; inset: calc(-1 * var(--tg-space-1)); }   /* 48px hit area */
.tgx-news__btn > span { transition: opacity var(--tg-dur-fast) var(--tg-ease-standard); }
.tgx-news[data-tgx-busy] .tgx-news__btn { cursor: progress; }
.tgx-news[data-tgx-busy] .tgx-news__btn > span { opacity: 0; }
.tgx-news[data-tgx-busy] .tgx-news__btn::before {             /* the label holds the width; a ring spins in its place */
  content: "";
  position: absolute;
  inset: 0;
  box-sizing: border-box;
  width: 1rem;
  height: 1rem;
  margin: auto;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #FFFFFF;
  border-radius: 50%;
  animation: tgx-spin 700ms linear infinite;
}
@keyframes tgx-spin { to { transform: rotate(360deg); } }
.tgx-news[data-tgx-st="invalid"] .tgx-news__group,
.tgx-news[data-tgx-st="error"] .tgx-news__group { box-shadow: inset 0 0 0 1px var(--tg-rejected-ink); outline-color: var(--tg-rejected-ink); }
/* Bait field (bots fill it): outside the box tree, so it is no target and no
   autofill reaches it; a field without a box is still posted with its form (F-17) */
html.tgx .tgx-hp { display: none; }
/* Result line: a polite live region; tgx.js copies a server-rendered message in */
.tgx-news__out {
  margin-top: var(--tg-space-3);
  color: var(--tg-ink-2);
  font-size: var(--tg-fs-caption);
  line-height: var(--tg-lh-caption);
}
.tgx-news__out:empty { margin-top: 0; }
.tgx-news[data-tgx-st="invalid"] .tgx-news__out,
.tgx-news[data-tgx-st="error"] .tgx-news__out { color: var(--tg-rejected-ink); }        /* #F7958A, 9.62:1 */
.tgx-news[data-tgx-st] .tgx-news__out:not(:empty)::before {
  display: inline-block;
  margin-right: var(--tg-space-1-5);
  font-family: "Material Symbols Outlined";
  font-size: var(--tg-icon-s);
  font-weight: normal;
  font-style: normal;
  line-height: var(--tg-lh-ui);
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  font-feature-settings: "liga";
  vertical-align: -0.22em;
}
.tgx-news[data-tgx-st="ok"] .tgx-news__out:not(:empty)::before { content: "check" / ""; }
.tgx-news[data-tgx-st="invalid"] .tgx-news__out:not(:empty)::before,
.tgx-news[data-tgx-st="error"] .tgx-news__out:not(:empty)::before { content: "error" / ""; }
/* Under 360: the button drops below the field at full width */
@media (max-width: 22.49rem) {
  .tgx-news__group { flex-direction: column; align-items: stretch; height: auto; padding: 0; gap: var(--tg-space-2); background-color: transparent; box-shadow: none; border-radius: 0; }
  .tgx-news__group:is(:focus-within, :has(.tgx-news__input:focus)) { outline: none; }
  html.tgx .tgx-news__input { height: var(--tg-field-h); padding-inline: var(--tg-space-5); background-color: rgba(255, 255, 255, 0.06); box-shadow: inset 0 0 0 1px var(--tg-gray-600); }
  html.tgx .tgx-news__input:focus { outline: var(--tg-focus-width) solid var(--tg-focus); outline-offset: var(--tg-focus-offset); }
  .tgx-news[data-tgx-st="invalid"] .tgx-news__input, .tgx-news[data-tgx-st="error"] .tgx-news__input { box-shadow: inset 0 0 0 1px var(--tg-rejected-ink); }
  .tgx-news__btn { --tgx-btn-h: var(--tg-btn-h-l); }
}

/* Link columns (F-17, D16): mono heads in white, links in ink-2 (hume.ai's
   hierarchy). Each column is a <details> with its head twice, as the same
   text: the <summary> (.tgx-footer__head) is the disclosure below 640,
   closed: 48px rows between hairlines, the chevron turning as in the menu
   sheet. From 640 the columns are open (footer.php's inline script) under a
   plain label (.tgx-footer__title, which also names the list), and the
   summary leaves the box tree, so it is neither a Tab stop nor a target.
   Without JS the columns stay open under the plain label.
   Columns: 3 from 640, 5 from 768 while the newsletter sits above them,
   3 from 1024 beside it, 5 from 1280. */
.tgx-footer__cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
  border-top: 1px solid var(--tg-line);
}
.tgx-footer__col { min-width: 0; border-bottom: 1px solid var(--tg-line); }
.tgx-footer__head,
.tgx-footer__title {
  color: var(--tg-ink);
  font-family: var(--tg-font-mono);
  font-size: var(--tg-fs-label);
  line-height: var(--tg-lh-label);
  letter-spacing: var(--tg-ls-label);
  text-transform: uppercase;
  font-variant-ligatures: none;
}
.tgx-footer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--tg-space-3);
  min-height: 3rem;
  list-style: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.tgx-footer__title { display: none; margin: 0 0 var(--tg-space-4); }
.tgx-footer__head::-webkit-details-marker { display: none; }
.tgx-footer__head::after {                   /* drawn in CSS with empty alternative text: no icon name in the head */
  content: "expand_more" / "";
  flex: none;
  display: inline-block;
  width: 1em;
  height: 1em;
  overflow: hidden;
  color: var(--tg-ink-2);
  font-family: "Material Symbols Outlined";
  font-size: var(--tg-icon-m);
  font-weight: normal;
  font-style: normal;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 20;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  font-feature-settings: "liga";
  transition: rotate var(--tg-dur-fast) var(--tg-ease-standard), color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-footer__col[open] > .tgx-footer__head::after { rotate: 180deg; }
.tgx-footer__list {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--tg-space-1);                    /* 24 + 4: hume.ai's 28px link pitch */
  padding: var(--tg-space-1) 0 var(--tg-space-4);   /* room for the first link's focus ring */
}
@media (min-width: 40rem) {
  .tgx-footer__cols { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--tg-space-10) var(--tg-space-6); border-top: 0; }
  .tgx-footer__col { border-bottom: 0; }
  .tgx-footer__head { display: none; }
  .tgx-footer__title { display: block; }
  .tgx-footer__list { padding: 0; }
}
/* Without JS (no html.js) the columns stay open: below 640 they keep two columns, as before F-17 */
@media (max-width: 39.99rem) {
  html:not(.js) .tgx-footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--tg-space-10) var(--tg-space-6); border-top: 0; }
  html:not(.js) .tgx-footer__col { border-bottom: 0; }
  html:not(.js) .tgx-footer__head { display: none; }
  html:not(.js) .tgx-footer__title { display: block; }
  html:not(.js) .tgx-footer__list { padding: 0; }
}
@media (min-width: 48rem) and (max-width: 63.99rem) {
  /* min-content first: a long head word (es, pt "Developers") widens its own column, never overflows it */
  .tgx-footer__cols { grid-template-columns: repeat(5, minmax(min-content, 1fr)); }
}
@media (min-width: 80rem) { .tgx-footer__cols { grid-template-columns: repeat(5, minmax(0, 1fr)); column-gap: var(--tg-space-8); } }
.tgx-footer__link {
  display: inline-flex;
  align-items: center;
  gap: var(--tg-space-1);
  box-sizing: border-box;
  min-height: 1.5rem;                        /* a 24px target on fine pointers; 44 on coarse (below) */
  max-width: 100%;
  border-radius: var(--tg-radius-xs);
  color: var(--tg-ink-2);                    /* 10.17:1 on #000 */
  font-size: var(--tg-fs-caption);
  line-height: calc(var(--tg-lh-caption) + var(--tg-lh-bump));
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-footer__link[target="_blank"]::after {  /* new tab: the arrow is drawn in CSS, so its name stays out of the link text */
  content: "arrow_outward" / "";
  flex: none;
  display: inline-block;
  width: 1em;
  height: 1em;
  overflow: hidden;
  color: var(--tg-ink-3);
  font-family: "Material Symbols Outlined";
  font-size: var(--tg-icon-xs);
  font-weight: normal;
  font-style: normal;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 20;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  font-feature-settings: "liga";
}
.tgx-footer__link[aria-current] { color: var(--tg-ink); }
:where(html.tgx:lang(ja)) .tgx-footer__link { word-break: auto-phrase; }   /* "ディストリビューター / 向け", not mid-word */
/* Disclosures open with their height where interpolate-size exists, at once elsewhere */
@media (max-width: 39.99rem) and (prefers-reduced-motion: no-preference) {
  @supports (interpolate-size: allow-keywords) {
    .tgx-footer__col { interpolate-size: allow-keywords; }
    .tgx-footer__col::details-content {
      block-size: 0;
      overflow: visible clip;                /* only the height: focus rings keep their sides */
      transition: block-size var(--tg-dur-base) var(--tg-ease-out-quint),
                  content-visibility var(--tg-dur-base) allow-discrete;
    }
    .tgx-footer__col[open]::details-content { block-size: auto; }
  }
}

/* Legal row: policies and Cookie settings, socials, then the copyright line */
.tgx-footer__legal {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "social" "policies" "copy";
  gap: var(--tg-space-4);
  margin-top: var(--tg-space-12);
  padding-top: var(--tg-space-6);
  border-top: 1px solid var(--tg-line);
}
@media (min-width: 40rem) { .tgx-footer__legal { margin-top: var(--tg-space-16); } }
@media (min-width: 48rem) {
  .tgx-footer__legal {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "policies social" "copy social";
    gap: var(--tg-space-2) var(--tg-space-8);
    align-items: center;
  }
}
.tgx-footer__policies { grid-area: policies; display: flex; flex-wrap: wrap; gap: var(--tg-space-2) var(--tg-space-6); }
@media (max-width: 39.99rem) {
  .tgx-footer__policies { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--tg-space-4); }
}
.tgx-footer__small {
  -webkit-appearance: none;
  appearance: none;
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--tg-radius-xs);
  background-color: transparent;
  color: var(--tg-ink-3);                    /* 5.80:1 on #000 */
  font: inherit;
  box-sizing: border-box;
  min-height: 1.5rem;                        /* a 24px target on fine pointers; 44 on coarse (below) */
  font-size: var(--tg-fs-caption);
  line-height: var(--tg-lh-caption);
  text-align: start;
  text-decoration: none;
  cursor: pointer;
  transition: color var(--tg-dur-fast) var(--tg-ease-standard);
}
.tgx-footer__small[aria-current] { color: var(--tg-ink-2); }
.tgx-footer__social { grid-area: social; display: flex; margin-inline: calc(-1 * var(--tg-space-3)) 0; }
@media (min-width: 48rem) { .tgx-footer__social { margin-inline: 0 calc(-1 * var(--tg-space-3)); } }
.tgx-footer__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--tg-hit-min);
  height: var(--tg-hit-min);
  border-radius: var(--tg-radius-pill);
  color: var(--tg-ink-3);
  transition: color var(--tg-dur-fast) var(--tg-ease-standard), background-color var(--tg-dur-fast) var(--tg-ease-standard);
}
html.tgx .tgx-footer__icon svg { display: block; width: var(--tg-icon-s); height: var(--tg-icon-s); }
.tgx-footer__copy { grid-area: copy; color: var(--tg-ink-3); font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); }
@media (hover: hover) and (pointer: fine) {
  .tgx-footer__link:hover, .tgx-footer__small:hover { color: var(--tg-ink); }
  .tgx-footer__head:hover::after { color: var(--tg-ink); }
  .tgx-footer__icon:hover { color: var(--tg-ink); background-color: var(--tg-surface-hover); }
}
/* Touch: every footer target is at least 44px tall, and a column link at least 44px wide */
@media (pointer: coarse) {
  .tgx-sheet__cta > .tgx-btn { min-height: var(--tg-hit-min); }   /* FND-8: the pinned pill of the phone menu is a 44px target */
  .tgx-footer__list { gap: 0; }
  .tgx-footer__link, .tgx-footer__small { min-height: var(--tg-hit-min); }
  .tgx-footer__link { min-width: var(--tg-hit-min); }
  .tgx-footer__fine .tgx-link::after { inset-block: min(0px, calc((100% - var(--tg-hit-min)) / 2)); }
  .tgx-footer__policies { row-gap: 0; }
  /* QA T14: the logo keeps its 28px look inside a 44px hit area, and the
     newsletter field fills the 48px pill (the pill's own padding was dead space) */
  .tgx-footer__logo { position: relative; }
  .tgx-footer__logo::after { content: ""; position: absolute; inset-block: min(0px, calc((100% - var(--tg-hit-min)) / 2)); inset-inline: 0; }
  .tgx-news__group { padding-block: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .tgx-news[data-tgx-busy] .tgx-news__btn::before { animation: none; border-color: rgba(255, 255, 255, 0.6); }
}


/* 8. Consent banner and plan modal ------------------------------------------
   Markup, classes and data attributes are unchanged (footer.php and
   includes/plan-modal.php); only the skin moved here from sleek.css 13. */
/* 8.1 Consent: dark card, bottom left */
html.tgx .tg-consent {
  position: fixed; left: 1rem; right: 1rem; bottom: 1rem;
  z-index: var(--tg-z-consent);
  display: flex; justify-content: flex-start;
  pointer-events: none;
}
@media (min-width: 40rem) { html.tgx .tg-consent { left: 1.5rem; right: auto; bottom: 1.5rem; } }
html.tgx .tg-consent-card {
  position: relative;                       /* above the scrim (a positioned ::before) */
  pointer-events: auto;
  box-sizing: border-box;
  width: 100%; max-width: min(26rem, calc(100vw - 2rem));   /* inside the screen at any text size (QA T09) */
  max-height: calc(100vh - 3rem); max-height: calc(100dvh - 3rem);   /* very large text: the card scrolls inside itself */
  overflow-y: auto; overscroll-behavior: contain;
  padding: 1.25rem;
  border-radius: var(--tg-radius-xl);
  background-color: var(--tg-surface);
  color: var(--tg-ink);
  box-shadow: var(--tg-shadow-pop);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--tg-dur-base) var(--tg-ease-standard), transform var(--tg-dur-slow) var(--tg-ease-out-quint);
}
html.tgx .tg-consent.is-open .tg-consent-card { opacity: 1; transform: none; }
/* While the first-visit banner shows, a control that takes focus is scrolled
   above the band the card covers (WCAG 2.4.11, QA T05): footer.php sets
   --tgx-consent-h to the card's height plus its bottom offset and 16 px. On a
   page that already scrolls it sets --tgx-consent-pad too: the same space below
   the footer (black, the html ground), so the last links can scroll above the
   card as well. */
html.tgx:has(#tg-consent.is-open:not([data-tgx-modal])) {
  scroll-padding-bottom: var(--tgx-consent-h, 15rem);
  padding-bottom: var(--tgx-consent-pad, 0px);
}
/* The card (z 70) also sits above the phone menu sheet (z 60): the sheet
   keeps the same band free, so its pinned View Pricing and its last rows stay
   in view above the card */
html.tgx:has(#tg-consent.is-open:not([data-tgx-modal])) .tgx-sheet { padding-bottom: var(--tgx-consent-h, 15rem); }
/* Settings view (Manage, or Cookie settings in the footer): a modal dialog
   over the same flat scrim as the plan modal; the first-visit banner has
   none. A click on the scrim works as Close (footer.php). */
html.tgx .tg-consent::before {
  content: ""; position: fixed; inset: 0;
  background-color: rgba(11, 11, 13, 0.6);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity var(--tg-dur-base) var(--tg-ease-standard), visibility 0s linear var(--tg-dur-base);
}
html.tgx .tg-consent.is-open[data-tgx-modal]::before { opacity: 1; visibility: visible; pointer-events: auto; transition-delay: 0s; }
html.tgx .tg-consent-title:focus { outline: none; }   /* takes focus when the settings view opens; it is not a control */
html.tgx .tg-consent-panel { margin-top: 0.75rem; }
html.tgx .tg-consent-title { margin: 0 0 0.375rem; color: var(--tg-ink); font-size: var(--tg-fs-title-s); line-height: calc(var(--tg-lh-title) + var(--tg-lh-bump)); -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill; }
html.tgx .tg-consent-text { margin: 0; color: var(--tg-ink-2); font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); }
html.tgx .tg-consent-text a { position: relative; color: var(--tg-link); text-decoration: underline; text-underline-offset: 0.2em; white-space: nowrap; }
/* The Cookie policy link in the text: one line, and a 24px target (44 on
   coarse pointers, below) from a centred ::after; the line box stays (F-17) */
html.tgx .tg-consent-text a::after { content: ""; position: absolute; inset-inline: 0; inset-block: min(0px, calc((100% - 1.5rem) / 2)); }
html.tgx .tg-consent-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-top: 1rem; }
html.tgx .tg-consent-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: var(--tg-btn-h-s); padding: 0 var(--tg-btn-px-s);
  border: 0; border-radius: var(--tg-radius-pill);
  background-color: var(--tgx-btn2-bg); box-shadow: var(--tgx-btn2-ring);
  color: var(--tg-ink); font-size: var(--tg-fs-button-s); line-height: var(--tg-lh-ui);
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill;
  cursor: pointer;
  transition-property: background-color, scale; transition-duration: var(--tg-dur-fast); transition-timing-function: var(--tg-ease-standard);
}
@media (hover: hover) and (pointer: fine) { html.tgx .tg-consent-btn:hover { background-color: var(--tgx-btn2-bg-h); } }
html.tgx .tg-consent-btn:active { scale: var(--tg-press-scale); }
html.tgx .tg-consent-btn--primary { background-color: var(--tg-action); color: var(--tg-action-ink); box-shadow: none; }
@media (hover: hover) and (pointer: fine) { html.tgx .tg-consent-btn--primary:hover { background-color: var(--tg-action-hover); } }
html.tgx .tg-consent-link {
  margin-left: auto; min-height: var(--tg-btn-h-s); padding: 0 0.25rem;
  border: 0; background: none; cursor: pointer;
  color: var(--tg-ink-2); font-size: var(--tg-fs-button-s); line-height: var(--tg-lh-ui);
  text-decoration: underline; text-underline-offset: 0.25em;
}
@media (hover: hover) and (pointer: fine) { html.tgx .tg-consent-link:hover { color: var(--tg-ink); } }
/* Touch: every consent button and link is at least 44px tall */
@media (pointer: coarse) {
  html.tgx :is(.tg-consent-btn, .tg-consent-link) { min-height: var(--tg-hit-min); }
  html.tgx .tg-consent-link { min-width: var(--tg-hit-min); }   /* a two-letter label (ja 管理) is 38px wide */
  html.tgx .tg-consent-text a::after { inset-block: min(0px, calc((100% - var(--tg-hit-min)) / 2)); }
}
/* 8.1b First visit below 640: a bar 16 px from the screen edges, the text clamped to two lines
   (one below 360), one row of buttons. The title stays for assistive tech. Manage opens the
   settings view, which shows the whole text (FND-3). */
html.tgx .tg-consent[data-tgx-modal] .tg-consent-main > .tg-consent-actions { display: none; }
@media (max-width: 39.99rem) {
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-card { max-width: none; padding: 0.75rem 1rem; border-radius: var(--tg-radius-lg); }
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-title {
    position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
    clip-path: inset(50%); white-space: nowrap; border: 0;
  }
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-text {
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden;
  }
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-actions { margin-top: 0.5rem; flex-wrap: wrap; gap: 0.25rem; }
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-btn { padding-inline: 0.625rem; }
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-link { padding-inline: 0.25rem; }
}
@media (max-width: 22.49rem) {
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-card { padding: 0.625rem 0.75rem; }
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-text { -webkit-line-clamp: 1; line-clamp: 1; }
  html.tgx .tg-consent:not([data-tgx-modal]) .tg-consent-actions { margin-top: 0.375rem; }
}
html.tgx .tg-consent-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 0.75rem 0; border-top: 1px solid var(--tg-line); }
html.tgx .tg-consent-row:first-child { border-top: 0; padding-top: 0; }
html.tgx .tg-consent-row-title { display: flex; align-items: center; gap: 0.5rem; margin: 0; color: var(--tg-ink); font-size: var(--tg-fs-body-s); line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump)); -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill; }
html.tgx .tg-consent-row-text { margin: 0.125rem 0 0; color: var(--tg-ink-2); font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); }
html.tgx .tg-consent-tag {
  display: inline-flex; align-items: center; min-height: var(--tg-badge-h); padding: 0 var(--tg-badge-px);
  border-radius: var(--tg-radius-xs); background-color: var(--tgx-badge-bg); color: var(--tg-ink-2);
  font-family: var(--tg-font-mono); font-size: var(--tg-fs-label-s); letter-spacing: var(--tg-ls-label); text-transform: uppercase;
  -webkit-text-stroke: 0; line-height: var(--tg-lh-ui);
}
/* Switch: the button itself is the 44px target; the 40x24 track (::before)
   and the knob sit where they always did (negative margins keep the row). */
html.tgx .tg-switch {
  position: relative; flex: none;
  width: 2.75rem; height: 2.75rem; margin: -0.5rem -0.125rem -0.625rem; padding: 0;
  border: 0; border-radius: var(--tg-radius-pill);
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
html.tgx .tg-switch::before {
  content: ""; position: absolute; top: 0.625rem; left: 0.125rem;
  width: 2.5rem; height: 1.5rem; border-radius: var(--tg-radius-pill);
  background-color: rgba(255, 255, 255, 0.16);
  transition: background-color var(--tg-dur-base) var(--tg-ease-standard);
}
html.tgx .tg-switch:focus-visible { outline: none; }
html.tgx .tg-switch:focus-visible::before { outline: var(--tg-focus-width) solid var(--tg-focus); outline-offset: var(--tg-focus-offset); }
html.tgx .tg-switch i { position: absolute; top: calc(0.625rem + 2px); left: calc(0.125rem + 2px); width: 1.25rem; height: 1.25rem; border-radius: 50%; background-color: #FFFFFF; transition: transform var(--tg-dur-base) var(--tg-ease-out-quint); }
html.tgx .tg-switch[aria-checked="true"]::before, html.tgx .tg-switch.is-locked::before { background-color: var(--tg-action); }
html.tgx .tg-switch[aria-checked="true"] i, html.tgx .tg-switch.is-locked i { transform: translateX(1rem); }
html.tgx .tg-switch.is-locked { opacity: 0.6; cursor: not-allowed; }

/* 8.2 Plan modal: white card on a flat scrim */
html.tg-modal-open, html.tg-modal-open body { overflow: hidden; }
html.tgx .tg-modal { position: fixed; inset: 0; z-index: var(--tg-z-modal); display: flex; align-items: flex-end; justify-content: center; padding: 0; }
@media (min-width: 40rem) { html.tgx .tg-modal { align-items: center; padding: 1.5rem; } }
html.tgx .tg-modal-backdrop { position: absolute; inset: 0; background-color: rgba(11, 11, 13, 0.6); opacity: 0; transition: opacity var(--tg-dur-base) var(--tg-ease-standard); }
html.tgx .tg-modal-card {
  position: relative; box-sizing: border-box;
  width: 100%; max-width: 40rem; max-height: 92vh; max-height: 92dvh; overflow: auto;
  border-radius: var(--tg-radius-xl) var(--tg-radius-xl) 0 0;
  background-color: var(--tg-surface); color: var(--tg-ink);
  box-shadow: var(--tg-shadow-pop);
  opacity: 0; transform: translateY(16px) scale(0.98);
  transition: opacity var(--tg-dur-base) var(--tg-ease-out-quint), transform var(--tg-dur-slow) var(--tg-ease-out-quint);
}
@media (min-width: 40rem) { html.tgx .tg-modal-card { border-radius: var(--tg-radius-xl); } }
html.tgx .tg-modal.is-open .tg-modal-backdrop { opacity: 1; }
html.tgx .tg-modal.is-open .tg-modal-card { opacity: 1; transform: none; }
html.tgx .tg-modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.5rem 1.5rem 0.875rem; }
html.tgx .tg-modal-kicker { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.375rem; color: var(--tg-brand-ink); font-family: var(--tg-font-mono); font-size: var(--tg-fs-label); line-height: var(--tg-lh-label); letter-spacing: var(--tg-ls-label); text-transform: uppercase; }
html.tgx .tg-modal-dot { width: 3px; height: 3px; border-radius: 50%; background-color: var(--tg-ink-3); }
html.tgx .tg-modal-title { margin: 0; color: var(--tg-ink); font-size: var(--tg-fs-title-l); font-weight: var(--tg-fw-regular); line-height: calc(var(--tg-lh-title) + var(--tg-lh-bump)); letter-spacing: var(--tg-ls-title); }
html.tgx .tg-modal-x { flex: none; display: inline-flex; width: 2.25rem; height: 2.25rem; align-items: center; justify-content: center; border: 0; border-radius: var(--tg-radius-pill); background-color: var(--tg-surface-sunken); color: var(--tg-ink-2); cursor: pointer; transition: background-color var(--tg-dur-fast) var(--tg-ease-standard), color var(--tg-dur-fast) var(--tg-ease-standard); }
@media (hover: hover) and (pointer: fine) { html.tgx .tg-modal-x:hover { background-color: var(--tg-gray-100); color: var(--tg-ink); } }
html.tgx .tg-modal-progress { height: 2px; margin: 0 1.5rem; border-radius: 2px; background-color: var(--tg-line); overflow: hidden; }
html.tgx .tg-modal-progress span { display: block; height: 100%; background-color: var(--tg-brand-strong); transition: width var(--tg-dur-slow) var(--tg-ease-out-quint); }
html.tgx .tg-pm-step { padding: 1.25rem 1.5rem 0.5rem; }
html.tgx .tg-pm-grid { display: grid; grid-template-columns: 1fr; gap: 0.875rem; }
@media (min-width: 40rem) { html.tgx .tg-pm-grid { grid-template-columns: 1fr 1fr; } html.tgx .tg-pm-span { grid-column: 1 / -1; } }
html.tgx .tg-pm-field { display: block; }
html.tgx .tg-pm-field > span { display: block; margin-bottom: 0.375rem; color: var(--tg-ink); font-size: var(--tg-fs-body-s); line-height: calc(var(--tg-lh-body-s) + var(--tg-lh-bump)); -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill; }
html.tgx .tg-pm-field :is(input:not([type="radio"]):not([type="checkbox"]), select, textarea) {
  box-sizing: border-box; width: 100%; min-height: var(--tg-hit-min); padding: 0.625rem 0.875rem;
  border: 1px solid var(--tg-line-field); border-radius: var(--tg-radius-md);
  background-color: var(--tg-surface); color: var(--tg-ink);
  font: inherit; font-size: var(--tg-fs-body-s); line-height: var(--tg-lh-body-s); outline: none;
  transition: border-color var(--tg-dur-fast) var(--tg-ease-standard), box-shadow var(--tg-dur-fast) var(--tg-ease-standard);
}
html.tgx .tg-pm-field select {
  appearance: none; -webkit-appearance: none; padding-right: 2.25rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23424245' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 0.875rem center; background-size: 12px 8px;
}
html.tgx .tg-pm-field :is(input, select, textarea):focus { border-color: var(--tg-focus); box-shadow: 0 0 0 3px var(--tg-focus-halo); }
html.tgx .tg-pm-field.is-bad :is(input, select), html.tgx .tg-pm-field.is-bad .tg-pm-choices { border-color: var(--tg-rejected-ink); box-shadow: 0 0 0 3px var(--tg-rejected-bg); }
html.tgx .tg-pm-field ::placeholder { color: var(--tg-ink-3); opacity: 1; }
html.tgx .tg-pm-choices { display: flex; flex-wrap: wrap; gap: 0.5rem; border: 1px solid transparent; border-radius: var(--tg-radius-md); }
html.tgx .tg-pm-choices label { position: relative; cursor: pointer; }
html.tgx .tg-pm-choices input { position: absolute; opacity: 0; pointer-events: none; }
html.tgx .tg-pm-choices span {
  display: inline-flex; align-items: center; min-height: var(--tg-btn-h-s); padding: 0 0.875rem;
  border-radius: var(--tg-radius-pill); background-color: var(--tgx-chip-bg); color: var(--tgx-chip-ink);
  font-size: var(--tg-fs-button-s); line-height: var(--tg-lh-ui); -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill;
  transition: background-color var(--tg-dur-fast) var(--tg-ease-standard), color var(--tg-dur-fast) var(--tg-ease-standard), box-shadow var(--tg-dur-fast) var(--tg-ease-standard);
}
@media (hover: hover) and (pointer: fine) { html.tgx .tg-pm-choices label:hover span { background-color: var(--tgx-chip-bg-h); color: var(--tg-ink); } }
html.tgx .tg-pm-choices input:checked + span { background-color: var(--tg-brand-soft); color: var(--tg-brand-soft-ink); box-shadow: inset 0 0 0 1px var(--tg-brand-strong); }
html.tgx .tg-pm-choices input:focus-visible + span { outline: var(--tg-focus-width) solid var(--tg-focus); outline-offset: var(--tg-focus-offset); }
html.tgx .tg-pm-check { display: flex; align-items: flex-start; gap: 0.625rem; color: var(--tg-ink-2); font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); cursor: pointer; }
html.tgx .tg-pm-check input { margin-top: 0.2rem; accent-color: var(--tg-action); }
html.tgx .tg-pm-fine { color: var(--tg-ink-3); font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); }
html.tgx .tg-pm-fine a { color: var(--tg-link); text-decoration: underline; text-underline-offset: 0.2em; }
html.tgx .tg-modal-foot { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 0.75rem; padding: 1rem 1.5rem 1.5rem; border-top: 1px solid var(--tg-line); }
html.tgx .tg-pm-foot-right { display: flex; align-items: center; gap: 0.875rem; margin-left: auto; }
html.tgx .tg-pm-err { color: var(--tg-rejected-ink); font-size: var(--tg-fs-caption); line-height: var(--tg-lh-caption); }
html.tgx .tg-pm-back { display: inline-flex; align-items: center; gap: 0.25rem; min-height: 2.5rem; padding: 0 0.625rem; border: 0; border-radius: var(--tg-radius-pill); background: none; color: var(--tg-ink-2); font-size: var(--tg-fs-button-s); line-height: var(--tg-lh-ui); cursor: pointer; }
@media (hover: hover) and (pointer: fine) { html.tgx .tg-pm-back:hover { background-color: var(--tg-surface-hover); color: var(--tg-ink); } }
html.tgx :is(.tg-pm-back, .tg-pm-next) .material-symbols-outlined { font-size: var(--tg-icon-s); }
html.tgx .tg-pm-next {
  display: inline-flex; align-items: center; gap: 0.375rem; min-height: var(--tg-btn-h-m); padding: 0 var(--tg-btn-px-m);
  border: 0; border-radius: var(--tg-radius-pill); background-color: var(--tg-action); color: var(--tg-action-ink);
  font-size: var(--tg-fs-button-m); line-height: var(--tg-lh-ui); -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill; cursor: pointer;
  transition-property: background-color, scale; transition-duration: var(--tg-dur-fast); transition-timing-function: var(--tg-ease-standard);
}
@media (hover: hover) and (pointer: fine) { html.tgx .tg-pm-next:hover { background-color: var(--tg-action-hover); } }
html.tgx .tg-pm-next:active { scale: var(--tg-press-scale); }
html.tgx .tg-pm-next:disabled { opacity: 0.7; scale: 1; }
/* Touch: the plan form's choices and step buttons are 44 px tall, and the
   36 px close button gets a 44 px hit area */
@media (pointer: coarse) {
  html.tgx :is(.tg-pm-choices span, .tg-pm-next, .tg-pm-back) { min-height: var(--tg-hit-min); }
  html.tgx .tg-modal-x { position: relative; }
  html.tgx .tg-modal-x::after { content: ""; position: absolute; inset: min(0px, calc((100% - var(--tg-hit-min)) / 2)); }
}


/* 9. Long-tail compatibility -------------------------------------------------
   Every legacy page (Tailwind M3 markup, a main element with the pt-20
   utility) inherits the new theme with zero page edits. Rebuilt pages mark
   main with tgx-main and opt out of the main-scoped rules. Selectors start
   with html.tgx so they out-rank one Tailwind utility (0,1,0) by specificity.
   Every rule that reaches into <main> is scoped main:not(.tgx-main), so a
   rebuilt page never inherits them: its type roles, code cards and
   paragraphs keep their own. */

/* 9.0 The header is sticky and in flow now: the offset that cleared the old
   fixed bar goes. Anchors keep their distance through scroll-padding-top. */
html.tgx main.pt-20:not(.tgx-main) { padding-top: 0; }

/* 9.1 Gradient helpers that head.php no longer defines: flat replacements */
html.tgx .kinetic-text {
  background: none;
  -webkit-background-clip: border-box;
  background-clip: border-box;
  -webkit-text-fill-color: currentColor;
  color: var(--tg-brand-ink);
}
html.tgx :is(a, button).kinetic-gradient {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--tg-btn-gap);
  box-sizing: border-box; min-height: var(--tg-btn-h-l); padding: 0 var(--tg-btn-px-l);
  border: 0; border-radius: var(--tg-radius-pill);
  background: var(--tg-action); color: var(--tg-action-ink);
  font-family: var(--tg-font-sans); font-size: var(--tg-fs-button-l); font-weight: 400; line-height: 1;
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor; paint-order: stroke fill;
  white-space: nowrap; text-decoration: none; box-shadow: none;
  transition-property: background-color, scale; transition-duration: var(--tg-dur-fast); transition-timing-function: var(--tg-ease-standard);
}
html.tgx :is(a, button).kinetic-gradient:hover { background-color: var(--tg-action-hover); }
html.tgx :is(a, button).kinetic-gradient:active { background-color: var(--tg-action-active); scale: var(--tg-press-scale); transform: none; }
html.tgx :is(a, button).kinetic-gradient .material-symbols-outlined { font-size: var(--tg-icon-s); }
@media (pointer: coarse) {
  html.tgx :is(a, button).kinetic-gradient { min-height: var(--tg-hit-min); }
}
html.tgx span.kinetic-gradient,
html.tgx div.kinetic-gradient:not(.text-center) { background: var(--tg-action); color: #FFFFFF; box-shadow: none; }
/* Legacy CTA panels become black rounded panels (dark islands) */
html.tgx div.kinetic-gradient.text-center {
  background: var(--tg-black);
  color: var(--tg-ink);
  border-radius: var(--tg-radius-xl);
  box-shadow: none;
}
/* Decorative glow blobs go */
html.tgx .kinetic-gradient:is(.blur-3xl, .blur-2xl, .blur-xl, [class*="blur-["]),
html.tgx main:not(.tgx-main) :is(.blur-3xl, .blur-2xl, .blur-\[100px\], .blur-\[120px\], .blur-\[140px\]).absolute { display: none; }
html.tgx .card-shine { background-image: none; }
html.tgx [class*="bg-gradient-to-"] { background-image: none; }
html.tgx .stat-glow { box-shadow: none; }
html.tgx .glass-panel {
  background-color: var(--tg-surface);
  box-shadow: var(--tg-shadow-card);
  -webkit-backdrop-filter: none; backdrop-filter: none;
  -webkit-user-select: none; user-select: none;
}
html.tgx .t-tilt-glare { display: none; background-image: none; }   /* motion.css draws a radial glare */

/* 9.2 Dark islands: code blocks and the legacy API console keep a black
   ground, so their syntax colors and white-alpha text stay legible. */
html.tgx main:not(.tgx-main) pre { background-color: var(--tg-black); color: var(--tg-ink); }
html.tgx #api-console { background-color: var(--tg-gray-900); color: var(--tg-ink); }

/* 9.3 Legacy accent hues. Purple is the only accent: decorative green, amber,
   orange, cyan and blue text becomes brand ink (success and selection read
   purple); red stays the error hue. Tints become the brand-soft wash. Code
   inside <pre> keeps its own syntax colors on the dark island. */
html.tgx :is([class*="text-green-"], [class*="text-emerald-"], [class*="text-amber-"], [class*="text-yellow-"],
             [class*="text-orange-"], [class*="text-cyan-"], [class*="text-sky-"], [class*="text-blue-"],
             [class*="text-teal-"], [class*="text-purple-"], [class*="text-violet-"], [class*="text-indigo-"],
             [class*="text-fuchsia-"], [class*="text-pink-"]):not(pre *):not(#api-console *) { color: var(--tg-brand-ink); }
html.tgx :is([class*="text-red-"], [class*="text-rose-"]):not(pre *):not(#api-console *) { color: var(--tg-rejected-ink); }
html.tgx :is([class*="bg-green-"], [class*="bg-emerald-"], [class*="bg-amber-"], [class*="bg-yellow-"], [class*="bg-orange-"],
             [class*="bg-cyan-"], [class*="bg-sky-"], [class*="bg-blue-"], [class*="bg-teal-"], [class*="bg-purple-"],
             [class*="bg-violet-"], [class*="bg-indigo-"], [class*="bg-fuchsia-"], [class*="bg-pink-"]):is([class*="/"]):not(#api-console *) { background-color: var(--tg-brand-soft); }
html.tgx :is([class*="bg-red-"], [class*="bg-rose-"]):is([class*="/"]):not(#api-console *) { background-color: var(--tg-rejected-bg); }
html.tgx :is([class*="bg-green-"], [class*="bg-emerald-"], [class*="bg-amber-"], [class*="bg-yellow-"], [class*="bg-orange-"],
             [class*="bg-cyan-"], [class*="bg-blue-"], [class*="bg-purple-"], [class*="bg-violet-"]):not([class*="/"]):not(#api-console *) { background-color: var(--tg-brand-strong); }
html.tgx :is([class*="border-green-"], [class*="border-amber-"], [class*="border-orange-"], [class*="border-cyan-"], [class*="border-purple-"],
             [class*="border-indigo-"], [class*="border-red-"]):not(#api-console *) { border-color: var(--tg-line-strong); }
/* Faded primary text (/50 to /80) was a soft violet on black; on white it
   fails AA (3.66:1 at 70%), so it takes the full brand ink. */
html.tgx :is([class~="text-primary/50"], [class~="text-primary/60"], [class~="text-primary/70"], [class~="text-primary/80"]) { color: var(--tg-brand-ink); }
html.tgx [class*="shadow-primary"] { --tw-shadow-color: rgba(11, 11, 13, 0.12); --tw-shadow: var(--tw-shadow-colored); }

/* Muted legacy text (white-alpha on the old black page) becomes the meta ink:
   5.07:1 on white, 5.43:1 on the black bands (the variant ink at 70% was
   4.24:1 on white, so 65 to 75 are in too). Exact tokens only (~=), so
   hover variants and decorative 5-10% watermarks are left alone. */
html.tgx :is(
  [class~="text-on-surface-variant/20"], [class~="text-on-surface-variant/25"], [class~="text-on-surface-variant/30"], [class~="text-on-surface-variant/35"], [class~="text-on-surface-variant/40"], [class~="text-on-surface-variant/45"], [class~="text-on-surface-variant/50"], [class~="text-on-surface-variant/55"], [class~="text-on-surface-variant/60"], [class~="text-on-surface-variant/65"], [class~="text-on-surface-variant/70"], [class~="text-on-surface-variant/75"],
  [class~="text-on-surface/20"], [class~="text-on-surface/25"], [class~="text-on-surface/30"], [class~="text-on-surface/35"], [class~="text-on-surface/40"], [class~="text-on-surface/45"], [class~="text-on-surface/50"], [class~="text-on-surface/55"], [class~="text-on-surface/60"],
  [class~="text-on-background/20"], [class~="text-on-background/25"], [class~="text-on-background/30"], [class~="text-on-background/35"], [class~="text-on-background/40"], [class~="text-on-background/45"], [class~="text-on-background/50"], [class~="text-on-background/55"], [class~="text-on-background/60"],
  [class~="text-white/20"], [class~="text-white/25"], [class~="text-white/30"], [class~="text-white/35"], [class~="text-white/40"], [class~="text-white/45"], [class~="text-white/50"], [class~="text-white/55"], [class~="text-white/60"]
) { color: var(--tg-ink-3); }
/* Legacy white pills (bg-white + text-primary/background/black) are the
   brand's inverse button in both contexts. */
html.tgx .bg-white:is(.text-primary, .text-background, .text-black) { background-color: var(--tgx-btn3-bg); color: var(--tgx-btn3-ink); }
html.tgx .bg-white:is(.text-primary, .text-background, .text-black):hover { background-color: var(--tgx-btn3-bg-h); }

/* 9.4 Purple fills: the action violet, white labels (5.70:1) */
html.tgx .bg-primary { background-color: var(--tg-action); }
html.tgx .text-on-primary { color: #FFFFFF; }

/* 9.5 Weights: Aeonik ships 300/400/700. Display headings go Light like
   Hume; sub-heads and UI weights use the synthetic medium; nothing renders
   at a faked 500/600/800. */
html.tgx main:not(.tgx-main) :is(h1, h2) {
  font-weight: var(--tg-fw-light);
  letter-spacing: var(--tg-ls-display-l);
  text-wrap: balance;
  -webkit-text-stroke: 0;
}
html.tgx main:not(.tgx-main) :is(h1, h2):is(.text-xs, .text-sm, .text-base, .text-lg, .text-xl, .text-2xl) {
  font-weight: var(--tg-fw-regular);
  letter-spacing: var(--tg-ls-title);
}
@media (min-width: 40rem) {
  html.tgx main:not(.tgx-main) :is(h1, h2):is([class~="sm:text-3xl"], [class~="sm:text-4xl"], [class~="sm:text-5xl"], [class~="sm:text-6xl"]) { font-weight: var(--tg-fw-light); letter-spacing: var(--tg-ls-display-l); }
}
@media (min-width: 48rem) {
  html.tgx main:not(.tgx-main) :is(h1, h2):is([class~="md:text-3xl"], [class~="md:text-4xl"], [class~="md:text-5xl"], [class~="md:text-6xl"]) { font-weight: var(--tg-fw-light); letter-spacing: var(--tg-ls-display-l); }
}
@media (min-width: 64rem) {
  html.tgx main:not(.tgx-main) :is(h1, h2):is([class~="lg:text-3xl"], [class~="lg:text-4xl"], [class~="lg:text-5xl"], [class~="lg:text-6xl"]) { font-weight: var(--tg-fw-light); letter-spacing: var(--tg-ls-display-l); }
}
html.tgx main:not(.tgx-main) :is(h3, h4, h5, h6) {
  font-weight: var(--tg-fw-regular);
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
  letter-spacing: var(--tg-ls-title);
  text-wrap: balance;
}
html.tgx :is(.font-medium, .font-semibold) {
  font-weight: 400;
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
}
html.tgx main:not(.tgx-main) :is(h1, h2):is(.font-medium, .font-semibold) { -webkit-text-stroke: 0; }
html.tgx :is(.font-extrabold, .font-black) { font-weight: 700; }
html.tgx main:not(.tgx-main) p { text-wrap: pretty; }
html.tgx .font-mono { font-family: var(--tg-font-mono); font-variant-ligatures: none; }

/* 9.6 Cards: white cards on white get Hume's hairline card shadow */
html.tgx :is(.rounded-xl, .rounded-2xl, .rounded-3xl, [class*="rounded-["]).bg-surface-container { box-shadow: var(--tg-shadow-card); }

/* 9.7 Small screens and helpers ported from sleek.css (sections 11 and 14) */
html.tgx .grid > * { min-width: 0; }
@media (max-width: 639px) {
  html.tgx main:not(.tgx-main) h1.text-5xl { font-size: min(var(--tg-fs-display-xl), 10vw); }
  html.tgx main:not(.tgx-main) h2.text-4xl { font-size: min(var(--tg-fs-display-m), 9vw); }
  html.tgx .tg-hero-catwrap {
    position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
  }
}
html.tgx .text-\[9px\], html.tgx .text-\[10px\] { font-size: var(--tg-fs-label-s); }
html.tgx .text-\[11px\] { font-size: var(--tg-fs-label-s); }
html.tgx .tg-mock { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
html.tgx .tg-mock img { -webkit-user-drag: none; pointer-events: none; }
html.tgx .tg-mock ::selection { background: transparent; }


/* 9.8 Automatic bands. RULINGS: long-tail pages get a black first section;
   teardown 14: hume.ai opens every page black under the header, or light for
   a text-led page. The first <section> of a legacy <main> is its hero: it is
   a black band when more sections follow. A page that is one text section
   (the policies, 404) gets a black head instead (9.8b, F-15). The context
   tokens flip with the same selector in 2.2, so every legacy color inside
   the band follows it. */
html.tgx main:not(.tgx-main) > section:first-of-type:not(:only-of-type) {
  background-color: var(--tg-black);
  color: var(--tg-ink);
}
/* A hero that flowed into the next section on the old all-black page (pb-2
   to pb-12) ends at a hard edge now: the band keeps at least 48px under its
   last line, 64px from 40rem, like hume.ai's bands. */
html.tgx main:not(.tgx-main) > section:first-of-type:not(:only-of-type):is([class~="pb-0"], [class~="pb-2"], [class~="pb-4"], [class~="pb-6"], [class~="pb-8"], [class~="pb-10"]) { padding-bottom: var(--tg-space-12); }
@media (min-width: 40rem) {
  html.tgx main:not(.tgx-main) > section:first-of-type:not(:only-of-type):is([class~="pb-0"], [class~="pb-2"], [class~="pb-4"], [class~="pb-6"], [class~="pb-8"], [class~="pb-10"], [class~="pb-12"]) { padding-bottom: var(--tg-space-16); }
}

/* 9.8b Black head on one-section pages (F-15, D1: every long-tail page
   opens black). A page that is one text section keeps its white text, and
   its title area turns black edge to edge (hume.ai's legal head):
   - The policy layout (privacy, terms, ai-music, anti-fraud, content-policy,
     dmca: a contents column beside the text, the title block first in the
     text column). The text column becomes display: contents, so the title
     block spans the grid above both columns (first on phones, before the
     contents list); the section's top padding moves into the block, so the
     black starts flush under the header; box-shadow + clip-path carry it to
     the viewport edges without widening the page. From 1024 the rest of the
     text column keeps columns 2 to 4 beside the contents column.
   - Message pages (404, a closed role, the newsletter confirmation, a missing
     post): the message is the title area, so the whole block is black.
   The dark tokens follow through the selector list in 2.2. Needs :has()
   (every current browser); without it the page opens light, as before. */
@supports selector(:has(*)) {
  html.tgx main:not(.tgx-main) > section:only-of-type:has(> div > .grid > div > .mb-12:first-child > h1) { padding-top: 0; }
  html.tgx main:not(.tgx-main) > section:only-of-type > div > .grid > div:has(> .mb-12:first-child > h1) { display: contents; }
  html.tgx main:not(.tgx-main) > section:only-of-type > div > .grid > div > .mb-12:first-child:has(> h1) {
    grid-column: 1 / -1;
    order: -1;
    margin-bottom: 0;
    padding: var(--tg-space-12) 0 var(--tg-space-16);
    background-color: var(--tg-black);
    color: var(--tg-ink);
    box-shadow: 0 0 0 100vmax var(--tg-black);
    clip-path: inset(0 -100vmax);
  }
  @media (min-width: 40rem) {
    html.tgx main:not(.tgx-main) > section:only-of-type > div > .grid > div > .mb-12:first-child:has(> h1) { padding-top: var(--tg-space-24); }
  }
  @media (min-width: 64rem) {
    html.tgx main:not(.tgx-main) > section:only-of-type > div > .grid > div:has(> .mb-12:first-child > h1) > :not(.mb-12:first-child) { grid-column: 2 / -1; }
  }
  html.tgx main:not(.tgx-main).flex.items-center.justify-center,
  html.tgx main:not(.tgx-main) > section:only-of-type:has(> h1:first-child),
  html.tgx main:not(.tgx-main):not(:has(> section)):has(> h1:first-child) {
    background-color: var(--tg-black);
    color: var(--tg-ink);
  }
}

/* 9.9 Arbitrary hex colors left in page markup (dmca, ndmr): the dark-page
   gray becomes the meta ink, the gold and orange accents become the brand
   ink (purple is the only accent), their tints the brand wash. */
html.tgx main:not(.tgx-main) .text-\[\#adaaaa\] { color: var(--tg-ink-3); }
html.tgx main:not(.tgx-main) :is(.text-\[\#C9A84C\], .text-\[\#E8460A\]) { color: var(--tg-brand-ink); }
html.tgx main:not(.tgx-main) :is(.bg-\[\#C9A84C\]\/10, .bg-\[\#E8460A\]\/8) { background-color: var(--tg-brand-soft); }
html.tgx main:not(.tgx-main) :is(.border-\[\#C9A84C\]\/15, .border-\[\#E8460A\]\/12) { border-color: var(--tg-line-strong); }
/* Arbitrary gradient utilities (decorative glows) lose their image */
html.tgx :is([class*="bg-[radial-gradient"], [class*="bg-[linear-gradient"], [class*="bg-[conic-gradient"]) { background-image: none; }
/* Faint separators and counts (a breadcrumb "/", a "·" between links, a
   "(n)") were 30 to 60% opacity: they take the meta ink at full opacity. */
html.tgx main:not(.tgx-main) :is(span.opacity-30, span.opacity-40, span.opacity-50, span.opacity-60):not(:has(*)) { opacity: 1; color: var(--tg-ink-3); }
/* Watermark numerals (3% white, drawn for black) cannot show on the white
   body: off there, so they also leave the accessibility tree. They stay
   faint on a black band. */
html.tgx main:not(.tgx-main) [class*="text-white/[0.0"]:not(:is(.tgx-dark, main > section:first-of-type, [class*="bg-[#0"]) *) { display: none; }
/* /pricing billing switch: its inline <style> paints the active pill
   violet-500 (white label 4.23:1) and turns hover text white on the light
   track. */
html.tgx .billing-toggle.active { background-color: var(--tg-action); color: var(--tg-action-ink); }
html.tgx .billing-toggle:not(.active):hover { color: var(--tg-ink); }
/* Plan cards: features a plan leaves out read in the meta ink with their
   close icon, instead of the whole row at 40% opacity (2.09:1) */
html.tgx main:not(.tgx-main) .flex.items-start.opacity-40 { opacity: 1; }
html.tgx main:not(.tgx-main) .flex.items-start.opacity-40 > * { color: var(--tg-ink-3); }

/* 9.10 The NDMR report's own components (the inline <style> in ndmr.php was
   written for the old black page) become hume.ai's light surfaces: white
   cards with the hairline card shadow, sunken table heads, ink text. */
html.tgx .ndmr-table-wrap { background-color: var(--tg-surface); border-color: var(--tg-line); box-shadow: var(--tg-shadow-card); }
html.tgx .ndmr-table thead th { background-color: var(--tg-surface-sunken); color: var(--tg-ink-2); border-bottom-color: var(--tg-line); }
html.tgx .ndmr-table tbody td { color: var(--tg-ink-2); border-bottom-color: var(--tg-line); }
html.tgx .ndmr-table tbody tr:hover td { background-color: var(--tg-surface-hover); }
html.tgx .ndmr-table tbody tr.highlight td { background-color: var(--tg-brand-soft); color: var(--tg-ink); }
html.tgx .ndmr-table .cell-label { color: var(--tg-brand-ink); }
html.tgx .chapter-card { background-color: var(--tg-surface); border-color: var(--tg-line); box-shadow: var(--tg-shadow-card); }
html.tgx .chapter-card:hover { border-color: var(--tg-line-strong); }
html.tgx .viz-tag { background-color: var(--tg-brand-soft); color: var(--tg-brand-soft-ink); border-color: transparent; }
html.tgx .timeline-dot { background-color: var(--tg-brand-soft); border-color: var(--tg-brand-strong); }
html.tgx .timeline-step::before { background-color: var(--tg-line-strong); }
html.tgx .swatch { border-color: var(--tg-line-strong); }
@media (max-width: 639px) {
  html.tgx .ndmr-table-wrap { background-color: transparent; box-shadow: none; }
  html.tgx .ndmr-table tbody tr { background-color: var(--tg-surface); border-color: var(--tg-line); box-shadow: var(--tg-shadow-card); }
}

/* 9.11 Blog posts (includes/blog-post-layout.php keeps an inline <style>
   written for the old black page). A post is text-led: the hero is the black
   band and the article reads ink on white, like a hume.ai post. Each visual
   embedded in a post body (unclassed, inline-styled blocks drawn for black)
   sits in a black figure panel, the same dark island as a code block; its
   inline tint is replaced by the black it was drawn for. */
html.tgx #read-progress { background: var(--tg-brand-strong); }
/* The post grid's article column may shrink below its content (a wide
   table scrolls inside its wrapper instead of pushing the contents column
   off the page: live scrolls sideways by 153px at 1440 on one post). */
@media (min-width: 64rem) {
  html.tgx main:not(.tgx-main) .lg\:grid-cols-\[1fr_300px\] { grid-template-columns: minmax(0, 1fr) 300px; }
}
html.tgx .prose-content :is(h2, h3) { color: var(--tg-ink); }
html.tgx .prose-content :is(p, ul li, ol li) { color: var(--tg-ink-2); }
html.tgx .prose-content p strong { color: var(--tg-ink); }
html.tgx .prose-content ul li::before { background-color: var(--tg-brand-strong); }
html.tgx .prose-content a { color: var(--tg-link); text-decoration-color: currentColor; }
html.tgx .prose-content a:hover { color: var(--tg-link-hover); }
html.tgx .pull-quote { background-color: var(--tg-brand-soft); border-color: var(--tg-brand-strong); }
html.tgx .pull-quote p { color: var(--tg-ink) !important; }          /* the layout marks its own rule !important */
html.tgx :is(.callout-info, .callout-tip, .callout-warn) { background-color: var(--tg-surface-sunken); border-color: var(--tg-line); }
html.tgx :is(.callout-info, .callout-tip, .callout-warn) .callout-label { color: var(--tg-brand-ink); }
html.tgx :is(.callout-info, .callout-tip, .callout-warn) p { color: var(--tg-ink-2); }
html.tgx .stat-block { background-color: var(--tg-brand-soft); border-color: transparent; }
html.tgx .stat-block .stat-num { color: var(--tg-brand-ink); }
html.tgx .stat-block .stat-desc { color: var(--tg-ink-3); }
html.tgx .prose-content .table-responsive { background-color: var(--tg-surface); border-color: transparent; box-shadow: var(--tg-shadow-card); }
html.tgx .prose-content .table-responsive::after { display: none; }   /* a gradient fade */
html.tgx :is(.prose-content table thead th, .compare-table th) { background-color: var(--tg-surface-sunken); color: var(--tg-ink-2); border-color: var(--tg-line); }
html.tgx :is(.prose-content table tbody td, .compare-table td) { color: var(--tg-ink-2); border-color: var(--tg-line); }
html.tgx .prose-content table tbody td:first-child { background-color: var(--tg-surface); color: var(--tg-ink); }
html.tgx .prose-content table thead th:first-child { background-color: var(--tg-surface-sunken); }
html.tgx .prose-content table tbody tr:nth-child(even) td,
html.tgx .prose-content table tbody tr:nth-child(even) td:first-child { background-color: var(--tg-canvas-alt); }
html.tgx .prose-content table tbody tr:hover td,
html.tgx .prose-content table tbody tr:hover td:first-child { background-color: var(--tg-surface-selected); }
html.tgx :is(.prose-content table tr.highlight td, .compare-table tr.highlight td) { background-color: var(--tg-brand-soft); color: var(--tg-ink); }
html.tgx .checklist li { color: var(--tg-ink-2) !important; border-bottom-color: var(--tg-line); }   /* the layout marks its own rule !important */
html.tgx .toc-link { color: var(--tg-ink-3); }
html.tgx .toc-link:is(:hover, .active) { color: var(--tg-brand-ink); border-left-color: var(--tg-brand-strong); background-color: var(--tg-brand-soft); }
html.tgx .section-divider { border-top-color: var(--tg-line); }
html.tgx .prose-content > div[style]:not([class]) {
  padding: var(--tg-space-6);
  border-radius: var(--tg-radius-xl);
  background-color: var(--tg-black) !important;                     /* beats the inline tint, drawn for black */
  color: var(--tg-ink);
}
/* What the visuals were drawn with, mapped to the brand (stored post HTML,
   so only the important flag reaches inline values; the values are the ones the
   posts use, from a survey of all 118 posts). Purple is the only accent:
   hue text takes the brand ink, faint hue washes the neutral card tint,
   stronger hue chips the violet tint, hue dots the brand violet and hue
   hairlines the neutral line. White text under 45% (3.2:1 at 35%) takes the
   meta ink. Bar fills (90deg gradients) are flat brand violet; any other
   gradient wash is the flat violet tint. */
html.tgx .prose-content :is(
  [style*="color:#f9a8d4"], [style*="color:#34d399"], [style*="color:#fbbf24"], [style*="color:#fca5a5"],
  [style*="color:#93c5fd"], [style*="color:#fdba74"], [style*="color:#6ee7b7"], [style*="color:#fcd34d"],
  [style*="color:#4ade80"], [style*="color:#5eead4"], [style*="color:#f472b6"], [style*="color:#60a5fa"],
  [style*="color:rgba(255,103,173"], [style*="color:rgba(52,211,153"], [style*="color:rgba(239,68,68"],
  [style*="color:rgba(245,158,11"], [style*="color:rgba(249,115,22"], [style*="color:rgba(16,185,129"],
  [style*="color:rgba(20,184,166"], [style*="color:rgba(30,215,96"], [style*="color:rgba(59,130,246"],
  [style*="color:rgba(236,72,153"], [style*="color:rgba(96,165,250"], [style*="color:rgba(244,114,182"],
  [style*="color:rgba(249,168,212"]
) { color: var(--tg-brand-ink) !important; }
html.tgx .prose-content :is(
  [style*="color:rgba(255,255,255,.2"], [style*="color:rgba(255,255,255,.3"],
  [style*="color:rgba(255,255,255,.4"]
) { color: var(--tg-ink-3) !important; }
html.tgx .prose-content :is(
  [style*="background:rgba(255,103,173"], [style*="background:rgba(52,211,153"],
  [style*="background:rgba(239,68,68"], [style*="background:rgba(245,158,11"],
  [style*="background:rgba(249,115,22"], [style*="background:rgba(16,185,129"],
  [style*="background:rgba(20,184,166"], [style*="background:rgba(30,215,96"],
  [style*="background:rgba(59,130,246"], [style*="background:rgba(236,72,153"],
  [style*="background:rgba(96,165,250"], [style*="background:rgba(244,114,182"],
  [style*="background:rgba(249,168,212"]
) { background-color: rgba(255, 255, 255, 0.04) !important; }
html.tgx .prose-content :is(
  [style*="background:rgba(249,115,22,.15"], [style*="background:rgba(52,211,153,.2"],
  [style*="background:rgba(239,68,68,.15"], [style*="background:rgba(16,185,129,.15"],
  [style*="background:rgba(255,103,173,.15"], [style*="background:rgba(52,211,153,.12"],
  [style*="background:rgba(96,165,250,.12"], [style*="background:rgba(245,158,11,.12"]
) { background-color: rgba(139, 92, 246, 0.2) !important; }
html.tgx .prose-content :is(
  [style*="background:#f9a8d4"], [style*="background:#34d399"]
) { background-color: var(--tg-brand-strong) !important; }
html.tgx .prose-content [style*="box-shadow:0 0 0 3px rgba("] { box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.25) !important; }
html.tgx .prose-content :is(
  [style*="solid rgba(255,103,173"], [style*="solid rgba(52,211,153"], [style*="solid rgba(239,68,68"],
  [style*="solid rgba(245,158,11"], [style*="solid rgba(249,115,22"], [style*="solid rgba(16,185,129"],
  [style*="solid rgba(20,184,166"], [style*="solid rgba(30,215,96"], [style*="solid rgba(59,130,246"],
  [style*="solid rgba(236,72,153"], [style*="solid rgba(96,165,250"], [style*="solid rgba(244,114,182"],
  [style*="solid rgba(249,168,212"]
) { border-color: rgba(255, 255, 255, 0.08) !important; }
/* Phones: the visuals' inline grids (two to four fixed columns) pushed the
   page sideways by up to 118px; they reflow into as many columns of at
   least 8.5rem as fit, and the figure panel's padding drops to 16px. */
@media (max-width: 39.99rem) {
  html.tgx .prose-content [style*="grid-template-columns"] { grid-template-columns: repeat(auto-fit, minmax(min(100%, 8.5rem), 1fr)) !important; }
  html.tgx .prose-content > div[style]:not([class]) { padding: var(--tg-space-4); }
}
html.tgx .prose-content [style*="gradient"] { background: rgba(139, 92, 246, 0.08) !important; }
html.tgx .prose-content [style*="gradient"][style*="90deg,#"] { background: var(--tg-brand-strong) !important; }
/* Stored SVG figures paint with gradient paint servers (url(#...)), which
   the color rules above cannot reach: every such fill or stroke is the flat
   brand violet, and a halo or glow layer is not drawn at all. */
html.tgx .prose-content svg :is([fill^="url(#"], [fill^="url('#"], [fill^='url("#']) { fill: var(--tg-brand-strong); }
html.tgx .prose-content svg :is([stroke^="url(#"], [stroke^="url('#"], [stroke^='url("#']) { stroke: var(--tg-brand-strong); }
html.tgx .prose-content svg :is([fill*="halo" i], [fill*="glow" i], [stroke*="halo" i], [stroke*="glow" i]) { display: none; }
html.tgx .prose-content svg :is(linearGradient, radialGradient) stop { stop-color: var(--tg-brand-strong); stop-opacity: 1; }   /* anything still pointing at one paints flat */
/* Weights in stored post HTML and in the layout's own <style>. Aeonik ships
   300/400/700: 500 and 600 read as the synthetic medium, 800 and 900 as
   bold, and strong stops at bold (the browser's "bolder" over a 600 cell is
   900). Inline values need the important flag (matched as "weight:N" so the build
   guard against declaring 500/600 stays strict); SVG text takes its weight
   from an attribute, which any rule beats. */
html.tgx .prose-content :is([style*="weight:500"], [style*="weight: 500"], [style*="weight:600"], [style*="weight: 600"]) {
  font-weight: 400 !important;
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
}
html.tgx .prose-content :is([style*="weight:800"], [style*="weight: 800"], [style*="weight:900"], [style*="weight: 900"]) { font-weight: 700 !important; }
html.tgx .prose-content :is(strong, b) { font-weight: 700; }
html.tgx .prose-content table tbody td:first-child,
html.tgx .pull-quote p {
  font-weight: 400;
  -webkit-text-stroke: var(--tg-medium-stroke) currentColor;
  paint-order: stroke fill;
}
html.tgx :is(.callout-label, .stat-block .stat-num) { font-weight: 700; }
html.tgx .prose-content svg :is([font-weight="500"], [font-weight="600"]) { font-weight: 400; }
html.tgx .prose-content svg :is([font-weight="800"], [font-weight="900"]) { font-weight: 700; }


/* 10. Reveal, reduced motion, print ---------------------------------------
   tgx.js arms only elements that start BELOW the fold and are at most 1.5
   screens tall (data-tgx-rv="wait"), so nothing on the first screen ever
   blinks; a block is shown as soon as any part of it crosses 94% of the
   screen. The stagger index of blocks that arrive together is an attribute
   (data-tgx-i, 1 to 6), never an inline style: writing to the style
   attribute would re-serialize it and the stored-post rules in 9.11 match
   its compact form. A page's own inline --tgx-i still wins. With JS off or
   failing, nothing is ever hidden. */
html.js [data-tgx-rv="wait"] { opacity: 0; transform: translate3d(0, 16px, 0); }
html.js [data-tgx-i="1"] { --tgx-i: 1; }
html.js [data-tgx-i="2"] { --tgx-i: 2; }
html.js [data-tgx-i="3"] { --tgx-i: 3; }
html.js [data-tgx-i="4"] { --tgx-i: 4; }
html.js [data-tgx-i="5"] { --tgx-i: 5; }
html.js [data-tgx-i="6"] { --tgx-i: 6; }
html.js [data-tgx-rv="in"] {
  opacity: 1; transform: none;
  transition: opacity 600ms var(--tg-ease-out-quint), transform 800ms var(--tg-ease-out-quint);
  transition-delay: calc(var(--tgx-i, 0) * 70ms);
}
@media (prefers-reduced-motion: reduce) {
  html.tgx *, html.tgx *::before, html.tgx *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  html.js [data-tgx-rv] { opacity: 1 !important; transform: none !important; }
}
@media print {
  html.js [data-tgx-rv] { opacity: 1 !important; transform: none !important; }
  .tg-consent, .tgx-skip, .tgx-announce, .tgx-fly, .tgx-scrim, .tgx-lang, .tgx-burger, .tgx-sheet, .tgx-header__cta, .tgx-header__menu { display: none !important; }
  .tgx-header { position: static; }
}
