@font-face {
  font-family: "Library Cormorant";
  src: url("./cormorant-garamond-latin-normal.woff2") format("woff2");
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: "Library Cormorant";
  src: url("./cormorant-garamond-latin-italic.woff2") format("woff2");
  font-style: italic;
  font-weight: 300 700;
  font-display: swap;
}

/* One session palette drives the interface, authored typography, and shader inputs. */
:root {
  --chameleon-ink:#f4e8d3; --chameleon-muted:#b5a997; --chameleon-accent:#d4b486;
  --chameleon-surface:#151b20; --chameleon-light:#f8f0dd;
  --chameleon-display:"Library Cormorant",Georgia,serif;
  --chameleon-body:DM,Arial,sans-serif; --chameleon-machine:Mono,monospace;
}
html[data-archetype="disruptor"] {
  --chameleon-ink:#f8ffe6; --chameleon-muted:#c3d3b6; --chameleon-accent:#c9ff49;
  --chameleon-surface:#111715; --chameleon-light:#f1ffe0; --chameleon-display:Display,Impact,sans-serif;
}
html[data-archetype="editorial"] {
  --chameleon-ink:#25221f; --chameleon-muted:#665f56; --chameleon-accent:#9b4131;
  --chameleon-surface:#f2ece0; --chameleon-light:#fff;
}
html[data-archetype="industrial"] {
  --chameleon-ink:#e0e8e8; --chameleon-muted:#a6b4b7; --chameleon-accent:#64d6e1;
  --chameleon-surface:#131c21; --chameleon-light:#f5fbfc; --chameleon-display:Mono,monospace;
}
html[data-archetype] {
  --cream: var(--chameleon-ink);
  --ink: var(--chameleon-surface);
  --muted: var(--chameleon-muted);
  --orange: var(--chameleon-accent);
  --line: color-mix(in srgb, var(--chameleon-muted) 35%, transparent);
  --fresco-vellum: var(--chameleon-surface);
  --fresco-chalk: var(--chameleon-ink);
  --fresco-parchment: color-mix(in srgb, var(--chameleon-surface) 85%, var(--chameleon-accent));
  --fresco-sand: var(--chameleon-accent);
  --fresco-ink: var(--chameleon-ink);
  --fresco-copy: var(--chameleon-muted);
  --fresco-line: var(--line);
  --fresco-clay: var(--chameleon-accent);
  --fresco-gold: var(--chameleon-accent);
  --fresco-olive: var(--chameleon-surface);
  --paper-white: var(--chameleon-surface);
  --paper-soft: var(--fresco-parchment);
  --paper-ink: var(--chameleon-ink);
  --paper-copy: var(--chameleon-muted);
  --paper-line: var(--line);
  --paper-signal: var(--chameleon-accent);
  --core-fx-accent: var(--chameleon-accent);
  color-scheme: dark;
}
html[data-archetype="editorial"] { color-scheme: light; }
html[data-archetype] body {
  color: var(--chameleon-ink);
  background: var(--chameleon-surface);
  font-family: var(--chameleon-body);
}
html[data-archetype] body :is(h1, h2, h3, h4, .statement, .footer-wordmark) {
  font-family: var(--chameleon-display) !important;
}
html[data-archetype="luxury"] body :is(h1, h2, h3, h4, .statement) {
  font-weight: 400;
  letter-spacing: -.025em;
  text-transform: none;
}
html[data-archetype="disruptor"] body :is(h1, h2, h3, h4, .statement) {
  font-weight: 700;
  letter-spacing: -.025em;
  text-transform: uppercase;
}
html[data-archetype="editorial"] body :is(h1, h2, h3, h4, .statement) {
  font-weight: 400;
  letter-spacing: -.035em;
  text-transform: none;
}
html[data-archetype="industrial"] body :is(h1, h2, h3, h4, .statement) {
  font-weight: 400;
  letter-spacing: -.065em;
  text-transform: uppercase;
}
html:is([data-archetype="industrial"],[data-archetype="disruptor"]) body :is(h1,h2,h3,h4,.statement) em { font-family:inherit !important; font-style:normal; }
html[data-archetype="editorial"] body .hero h1 { font-size: clamp(64px, 7.5vw, 134px); }
html[data-archetype="industrial"] body .hero h1 { font-size: clamp(48px, 6.2vw, 110px); }
html[data-archetype] body :is(p, li, dd, input, select, textarea) {
  font-family: var(--chameleon-body) !important;
}
html[data-archetype] body :is(.eyebrow, .hero-note, .hero-folio, .world-top, .world-controls, .footer-bottom) {
  font-family: var(--chameleon-machine) !important;
}
html[data-archetype] body :is(.header, .mobile-menu, dialog, .clarity-section, .page-hero, .page-content, .privacy-copy) {
  background-color: var(--chameleon-surface);
  color: var(--chameleon-ink);
}
html[data-archetype] body :is(.hero-description, .intro-description, .section-heading p, .service-row p, .footer-top p) {
  color: var(--chameleon-muted);
}
html[data-archetype] body :is(.hero-top, .hero-note, .dust-caption, .hero-coordinate) {
  color: var(--chameleon-ink);
}
html[data-archetype] body :is(.hero-copy, .hero-journey-copy) { color: var(--chameleon-ink); }
html[data-archetype] body .hero-fresco-portal::before {
  background: linear-gradient(90deg, color-mix(in srgb, var(--chameleon-surface) 95%, transparent), color-mix(in srgb, var(--chameleon-surface) 60%, transparent) 35%, transparent 78%);
}
html[data-archetype] body .reading-progress { background: var(--chameleon-accent); }
html[data-archetype] body :is(.website-library-thanks, #site-footer) {
  color: var(--chameleon-ink);
  background-color: var(--chameleon-surface);
}
html[data-archetype] body .website-library-thanks :is(.thanks-note, .footer-wordmark, .footer-top p, .footer-bottom a, .footer-service-areas) {
  color: var(--chameleon-ink);
}
html[data-archetype] body :is(.button, .nav-cta, .hero-direct, .text-link, .glass-button, .motion-toggle, .menu-toggle) {
  border-color: color-mix(in srgb, var(--chameleon-accent) 45%, transparent) !important;
  color: var(--chameleon-ink) !important;
  background-color: color-mix(in srgb, var(--chameleon-surface) 86%, transparent) !important;
}
html[data-archetype] body :is(.button, .nav-cta, .hero-direct, .glass-button) {
  background-image: linear-gradient(145deg, color-mix(in srgb, var(--chameleon-light) 18%, transparent), transparent 64%) !important;
}
html[data-archetype] body :is(a, button, summary, input, textarea, select):focus-visible {
  outline-color: var(--chameleon-accent) !important;
}
/* The existing Effects control stays below the compact archetype control. */
[data-chameleon] {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(74px, calc(env(safe-area-inset-bottom) + 62px));
  z-index: 2147483002;
  max-width: calc(100vw - 24px);
  font: 400 12px/1.4 Mono, monospace;
  letter-spacing: .015em;
}
[data-chameleon] [hidden] { display: none !important; }
html[data-archetype] body [data-chameleon] button {
  min-height: 44px;
  padding: 10px 13px;
  border: 1px solid color-mix(in srgb, var(--chameleon-muted) 65%, transparent) !important;
  border-radius: 8px !important;
  background: color-mix(in srgb, var(--chameleon-surface) 94%, transparent) !important;
  color: var(--chameleon-ink) !important;
  font: 400 12px/1.4 Mono, monospace !important;
  letter-spacing: .015em;
  box-shadow: none !important;
  backdrop-filter: blur(18px) !important;
  cursor: pointer;
}
html[data-archetype] body [data-chameleon] [data-chameleon-trigger] {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 110px;
  box-shadow: 0 6px 22px #0002 !important;
}
[data-chameleon-trigger]::before {
  content: '';
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--chameleon-accent);
  box-shadow: 0 0 12px color-mix(in srgb, var(--chameleon-accent) 45%, transparent);
}
#chameleon-panel {
  position: absolute;
  right: 0;
  bottom: calc(100% + 10px);
  width: min(340px, calc(100vw - 24px));
  max-height: calc(100dvh - 150px);
  overflow-y: auto;
  padding: 20px;
  border: 1px solid color-mix(in srgb, var(--chameleon-muted) 45%, transparent);
  border-radius: 12px;
  background: var(--chameleon-surface);
  color: var(--chameleon-ink);
  box-shadow: 0 16px 60px #0004;
}
#chameleon-panel :is(h2, h3, legend) {
  color: var(--chameleon-ink);
  font: 400 23px/1.1 var(--chameleon-display) !important;
  letter-spacing: -.02em;
  text-transform: none;
}
#chameleon-panel p { font: 400 12px/1.6 DM, sans-serif; color: var(--chameleon-muted); margin: 8px 0 16px; }
#chameleon-panel fieldset { padding: 0; margin: 0; border: 0; }
#chameleon-panel .archetype-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 16px 0;
}
html[data-archetype] body #chameleon-panel button[data-archetype][aria-pressed="true"] {
  border-color: var(--chameleon-accent) !important;
  color: var(--chameleon-accent) !important;
  background: color-mix(in srgb, var(--chameleon-accent) 9%, var(--chameleon-surface)) !important;
}
#chameleon-panel .chameleon-panel-tools { display: flex; justify-content: space-between; gap: 8px; }
#chameleon-panel [data-chameleon-status] { min-height: 1.4em; margin-bottom: 0; }

@media (max-width: 800px) {
  html[data-archetype] body .hero h1 { font-size: clamp(56px, 12.8vw, 105px); }
  html[data-archetype="industrial"] body .hero h1 { font-size: clamp(38px, 9.7vw, 78px); }
  html[data-archetype] body .hero h1 span { white-space: normal; }
  html[data-archetype] body .hero-fresco-portal::before {
    background: linear-gradient(180deg, color-mix(in srgb, var(--chameleon-surface) 95%, transparent), color-mix(in srgb, var(--chameleon-surface) 58%, transparent) 47%, transparent 82%);
  }
  [data-chameleon] { right: max(12px, env(safe-area-inset-right)); }
}
@media (max-width: 359px) {
  html[data-archetype] body [data-chameleon] [data-chameleon-trigger] { min-width: 100px; gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  [data-chameleon] *, [data-chameleon] *::before { transition: none !important; }
}
@media (forced-colors: active) {
  [data-chameleon] { forced-color-adjust: auto; }
  html[data-archetype] body [data-chameleon] button, #chameleon-panel {
    color: ButtonText !important;
    background: Canvas !important;
    border-color: ButtonText !important;
  }
}

/* Keep high-contrast glass controls in every palette, including the shared layer. */
html[data-archetype] body :is(.motion-toggle,.menu-toggle,.cinematic-chapters button,.core-fx-header-sound,.core-fx-disclosure,.core-fx-panel button) {
 background-color:var(--chameleon-surface) !important;
 background-image:linear-gradient(145deg,color-mix(in srgb,var(--chameleon-light) 18%,transparent),transparent 70%) !important;
 color:var(--chameleon-ink) !important;
 border-color:color-mix(in srgb,var(--chameleon-accent) 50%,transparent) !important;
}
html[data-archetype] body .motion-toggle span { color:var(--chameleon-ink) !important; }
html[data-archetype] body .cinematic-chapters button[aria-pressed="true"] { border-color:var(--chameleon-accent) !important; }

html[data-archetype] body :is(button,.button,.nav-cta,.estimate-inquire,.preview-expand,.hero-direct,.world-stages>a,.world-controls>a,.world-skip,.finale-skip) {
 background:linear-gradient(145deg,color-mix(in srgb,var(--chameleon-light) 18%,var(--chameleon-surface)),var(--chameleon-surface)) !important;
 color:var(--chameleon-ink) !important;
 border-color:color-mix(in srgb,var(--chameleon-accent) 50%,transparent) !important;
}
html[data-archetype] body #strategy-atlas [data-strategy-focus][aria-pressed="true"] { background:var(--chameleon-accent) !important; color:var(--chameleon-surface) !important; }

/* The fresco stays visible; its protective overlays follow the active palette. */
html[data-archetype] body.home :is(.intro, .work-showcase, .investment-tease),
html[data-archetype] body.home #capabilities.cap-network {
  background: linear-gradient(90deg,
    color-mix(in srgb, var(--chameleon-surface) 97%, transparent),
    color-mix(in srgb, var(--chameleon-surface) 94%, transparent) 46%,
    color-mix(in srgb, var(--chameleon-surface) 89%, transparent));
}
html[data-archetype] body.home .build-world .world-backdrop,
html[data-archetype] body.home .connected-world .connected-render-layer,
html[data-archetype] body.home .connected-world[data-connected-art="dust"] .connected-render-layer,
html[data-archetype] body.home .finale[data-finale-mode="motion"] .finale-stage {
  background: linear-gradient(90deg,
    color-mix(in srgb, var(--chameleon-surface) 97%, transparent),
    color-mix(in srgb, var(--chameleon-surface) 93%, transparent) 39%,
    color-mix(in srgb, var(--chameleon-surface) 77%, transparent) 70%,
    color-mix(in srgb, var(--chameleon-surface) 63%, transparent));
}
html[data-archetype] body.home .world-backdrop::before {
  background: linear-gradient(90deg, color-mix(in srgb, var(--chameleon-surface) 65%, transparent), transparent 66%);
}
html[data-archetype] body.home .proportion-section {
  background: linear-gradient(105deg,
    color-mix(in srgb, var(--chameleon-surface) 97%, transparent),
    color-mix(in srgb, var(--chameleon-surface) 92%, transparent) 47%,
    color-mix(in srgb, var(--chameleon-surface) 86%, transparent));
}
html[data-archetype] body.home .connected-vignette {
  background: linear-gradient(180deg,
    color-mix(in srgb, var(--chameleon-surface) 73%, transparent), transparent 24% 76%,
    color-mix(in srgb, var(--chameleon-surface) 67%, transparent));
}
html[data-archetype] body.home .connected-world[data-connected-mode="motion"] .venture-pin::before {
  background: linear-gradient(90deg,
    color-mix(in srgb, var(--chameleon-surface) 94%, transparent),
    color-mix(in srgb, var(--chameleon-surface) 76%, transparent) 37%, transparent 65%);
}
html[data-archetype] body.home .finale[data-finale-mode="motion"] .finale-shade {
  background: linear-gradient(90deg,
    color-mix(in srgb, var(--chameleon-surface) 94%, transparent),
    color-mix(in srgb, var(--chameleon-surface) 73%, transparent) 38%, transparent 70%),
    linear-gradient(0deg, color-mix(in srgb, var(--chameleon-surface) 75%, transparent), transparent 22%),
    linear-gradient(180deg, color-mix(in srgb, var(--chameleon-surface) 67%, transparent), transparent 24%);
}
html[data-archetype] body :is(.world-inspector, .venture-navigation, .clarity-list, .connected-caption, .estimate-summary, .estimate-mobile-bar),
html[data-archetype] body .work-showcase .work-browser,
html[data-archetype] body #capabilities.cap-network .cap-card,
html[data-archetype] body.services-page #deliverables .dn-detail,
html[data-archetype] body :is(dialog, dialog.living-dialog) {
  background: color-mix(in srgb, var(--chameleon-surface) 96%, var(--chameleon-accent));
  color: var(--chameleon-ink);
  border-color: var(--line);
}
html[data-archetype] body .world-inspector :is(h3, p, .eyebrow),
html[data-archetype] body #world-discoveries {
  color: var(--chameleon-muted);
}
html[data-archetype] body .world-inspector h3 { color: var(--chameleon-ink); }
html[data-archetype] body :is(.section, .page-hero) :is(h1, h2, h3) em {
  color: var(--chameleon-accent);
}
html[data-archetype] body :is(.proportion-copy > p, .proportion-measure span, .proportion-measure small, .proportion-figure figcaption, .email),
html[data-archetype] body.services-page #service-details :is(.eyebrow, .section-heading p, .service-row p, .service-deliverables, .service-number),
html[data-archetype] body.services-page .text-section p {
  color: var(--chameleon-muted);
}

/* Native controls need the same foreground/surface pairing as glass buttons. */
html[data-archetype] body :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea, option),
html[data-archetype] body .estimate-field :is(select, input:not([type="checkbox"]):not([type="radio"])) {
  color: var(--chameleon-ink);
  background: color-mix(in srgb, var(--chameleon-surface) 96%, var(--chameleon-light));
  border-color: color-mix(in srgb, var(--chameleon-muted) 65%, transparent);
}
html[data-archetype] body ::placeholder { color: var(--chameleon-muted); opacity: 1; }
html[data-archetype] body input:-webkit-autofill,
html[data-archetype] body textarea:-webkit-autofill,
html[data-archetype] body select:-webkit-autofill {
  -webkit-text-fill-color: var(--chameleon-ink);
  box-shadow: 0 0 0 100px var(--chameleon-surface) inset;
}
html[data-archetype] body.home #site-footer {
  background: linear-gradient(90deg,
    color-mix(in srgb, var(--chameleon-surface) 96%, transparent),
    color-mix(in srgb, var(--chameleon-surface) 87%, transparent));
}
html[data-archetype] body .website-library-thanks {
  background: radial-gradient(ellipse at 50% 67%, color-mix(in srgb, var(--chameleon-accent) 10%, transparent), transparent 64%), var(--chameleon-surface);
}
html[data-archetype] body :is(.footer-top p, .footer-top p a, .footer-bottom, .footer-bottom a, .footer-service-areas) {
  color: var(--chameleon-muted);
  border-color: var(--line);
}
html[data-archetype] body .footer-bottom a:hover,
html[data-archetype] body .website-library-thanks .thanks-directory a:hover { color: var(--chameleon-accent); }

@media (max-width: 800px) {
  html[data-archetype] body.home :is(.intro, .work-showcase, .investment-tease),
  html[data-archetype] body.home #capabilities.cap-network,
  html[data-archetype] body.home .proportion-section {
    background: linear-gradient(180deg,
      color-mix(in srgb, var(--chameleon-surface) 97%, transparent),
      color-mix(in srgb, var(--chameleon-surface) 94%, transparent) 46%,
      color-mix(in srgb, var(--chameleon-surface) 90%, transparent));
  }
  html[data-archetype] body.home .build-world .world-backdrop,
  html[data-archetype] body.home .connected-world .connected-render-layer,
  html[data-archetype] body.home .connected-world[data-connected-art="dust"] .connected-render-layer,
  html[data-archetype] body.home .finale[data-finale-mode="motion"] .finale-stage {
    background: linear-gradient(180deg,
      color-mix(in srgb, var(--chameleon-surface) 97%, transparent),
      color-mix(in srgb, var(--chameleon-surface) 94%, transparent) 29%,
      color-mix(in srgb, var(--chameleon-surface) 78%, transparent) 51%,
      color-mix(in srgb, var(--chameleon-surface) 87%, transparent) 73%,
      color-mix(in srgb, var(--chameleon-surface) 97%, transparent));
  }
  html[data-archetype] body.home .connected-world[data-connected-mode="motion"] .venture-pin::before {
    background: linear-gradient(180deg,
      color-mix(in srgb, var(--chameleon-surface) 95%, transparent),
      color-mix(in srgb, var(--chameleon-surface) 79%, transparent) 33%, transparent 56%);
  }
  html[data-archetype] body.home .connected-world[data-connected-mode="motion"] .venture-detail {
    background: linear-gradient(180deg, transparent,
      color-mix(in srgb, var(--chameleon-surface) 92%, transparent) 31%,
      color-mix(in srgb, var(--chameleon-surface) 98%, transparent));
  }
  html[data-archetype] body.home .finale[data-finale-mode="motion"] .finale-shade {
    background: linear-gradient(180deg,
      color-mix(in srgb, var(--chameleon-surface) 96%, transparent),
      color-mix(in srgb, var(--chameleon-surface) 83%, transparent) 32%, transparent 49% 63%,
      color-mix(in srgb, var(--chameleon-surface) 91%, transparent) 84%);
  }
  html[data-archetype] body.home #site-footer {
    background: linear-gradient(180deg,
      color-mix(in srgb, var(--chameleon-surface) 96%, transparent),
      color-mix(in srgb, var(--chameleon-surface) 88%, transparent));
  }
}
@media (prefers-reduced-transparency: reduce) {
  html[data-archetype] body.home :is(.intro, .work-showcase, #capabilities.cap-network, .investment-tease, .proportion-section, .world-backdrop, .connected-render-layer),
  html[data-archetype] body.home .connected-world[data-connected-art="dust"] .connected-render-layer,
  html[data-archetype] body.home .finale[data-finale-mode="motion"] .finale-stage {
    background: var(--chameleon-surface);
  }
}
@media (max-width: 480px) {
  html body .header .core-fx-header-sound { display: none !important; }
}
@media (forced-colors: active) {
  html[data-archetype] body.home :is(.build-world, .world-sticky, .world-backdrop, .intro, .proportion-section, .work-showcase, #capabilities.cap-network, .investment-tease, .connected-world, .connected-render-layer, .contact-section.finale, #site-footer),
  html[data-archetype] body.home .connected-world[data-connected-art="dust"] .connected-render-layer,
  html[data-archetype] body.home .finale[data-finale-mode="motion"] .finale-stage,
  html[data-archetype] body :is(input, select, textarea, option, .website-library-thanks) {
    background: Canvas;
    color: CanvasText;
  }
}

@media(max-width:800px) {
 .hero-copy > .hero-fresco-credit {
   position:static; display:block; margin-top:12px; max-width:38ch; padding:0;
   border:0; background:none; backdrop-filter:none; color:var(--chameleon-muted, #dfd2bd);
   font:8px/1.5 Mono,monospace; opacity:1; transform:none; visibility:visible;
 }
 .hero-copy > .hero-fresco-credit :is(strong,small) {
   display:block; margin:0; color:inherit; font:inherit; letter-spacing:normal; text-transform:none;
 }
 .hero-copy > .hero-fresco-credit a { text-underline-offset:2px; }
 html[data-archetype="editorial"] body .hero h1 { font-size:clamp(38px,11vw,70px); }
 html[data-archetype] body [data-chameleon] [data-chameleon-trigger] { min-width:0; width:100px; font-size:0 !important; gap:9px; justify-content:center; padding-inline:10px; }
 [data-chameleon-trigger] [data-chameleon-label] { display:none; }
 [data-chameleon-trigger]::after { content:"Identity"; font:10px/1.4 Mono,monospace; }
}
