/* Warm neutral palette for the public site. Media keeps its original colors. */
html.cgd-light:not([data-education-theme=dark]){
 color-scheme:light;--canvas:#d7d5d0;--cream:#eeede9;--sheet:#faf9f7;--white:#fff;--graph:#222220;--quiet:#575651;--edge:#d5d2cb;
 --relay-bg:var(--cream);--relay-surface:var(--sheet);--relay-text:var(--graph);--relay-muted:var(--quiet);--relay-accent:var(--graph);--relay-line:var(--edge);
 --paper:var(--cream);--ink:var(--graph);--muted:var(--quiet);--accent:var(--graph);--acid:var(--graph);--black:var(--graph);--line:var(--edge)
}
.cgd-light:not([data-education-theme=dark]) body{background:var(--cream)!important;color:var(--graph);font-family:Manrope,Arial,sans-serif}
.cgd-light:not([data-education-theme=dark]) body :is(h1,h2,h3,h4,button,input,select,textarea){font-family:Manrope,Arial,sans-serif}
.cgd-light:not([data-education-theme=dark]) ::selection{background:#d6d2c9;color:#222220}
.cgd-light:not([data-education-theme=dark]) :focus-visible{outline:2px solid #58554d;outline-offset:4px}
.cgd-light .site-relay-home{--home-edge:clamp(8px,3vw,56px);--home-width: min(1920px,calc(100% - 2 * var(--home-edge)));background:var(--canvas)!important}
.cgd-light .site-relay-home>.wrap{width:var(--home-width);margin-inline:auto;padding-inline:clamp(16px,3.5vw,60px)}
.cgd-light .site-relay-home .stage.reference-stage{width:var(--home-width);min-height:clamp(570px,78svh,850px);margin:clamp(10px,2.5vw,44px) auto 0;background:var(--cream);border-color:#fff;border-radius:clamp(24px,4vw,64px);overflow:hidden}
.cgd-light .site-relay-home .stage.reference-stage::after{background:radial-gradient(ellipse at center,#eeede9be 12%,#eeede967 76%),linear-gradient(0deg,#eeede9ad,transparent 30%);pointer-events:none}
.cgd-light .site-relay-home .stage.reference-stage .hero-video{opacity:.7;filter:grayscale(1)}
.cgd-light .site-relay-home .stage.reference-stage .reference-copy h1.hero-intro{color:var(--graph);font-weight:600;max-width:min(100%,1050px);font-size:clamp(35px,5.2vw,84px);line-height:1.06;letter-spacing:-.065em;text-wrap:balance}
.cgd-light .site-relay-home .stage.reference-stage .reference-copy .hero-support{color:var(--quiet);max-width:52ch;font-size:clamp(14px,1.35vw,20px);line-height:1.6}
.cgd-light .site-relay-home .reference-clients{width:min(1180px,100%);padding:0;background:transparent}
.cgd-light .site-relay-home .reference-clients img{filter:grayscale(1) brightness(0);opacity:.8}
.cgd-light .site-relay-home .reference-nav .site-brand{filter:brightness(0)}
.cgd-light .site-relay-home .reference-nav::before{display:none}
.cgd-light .site-relay-home .reference-nav :is(.reference-menu,.reference-actions){color:var(--graph)}
.cgd-light .site-relay-home .reference-nav .reference-menu{background:#fff!important;border-color:#d5d2cb!important;box-shadow:0 4px 18px #2222200d}
.cgd-light .site-relay-home .reference-nav .reference-menu a,.cgd-light .site-relay-home .reference-nav .lang-switch{color:var(--graph)!important}
.cgd-light .site-relay-home .reference-nav .reference-menu a[aria-current]{background:transparent!important;color:#fff!important}
.cgd-light .site-relay-home .reference-nav .nav-glider{background:var(--graph);border:0;box-shadow:none}
.cgd-light .site-relay-home .reference-nav .reference-actions :is(.cg-social,.lang-switch){background:#fff;color:var(--graph)!important;border-color:var(--edge)}
.cgd-light .site-relay-home :is(.portfolio,.blog,.skills,#about){background:var(--cream);border-radius:clamp(22px,4vw,56px);margin-block-start:clamp(12px,2vw,28px)}
.cgd-light .site-relay-home :is(.portfolio,.blog,.skills){padding-block:clamp(24px,4vw,58px)}
.cgd-light .site-relay-home .section-label h2{color:var(--graph);font-weight:600}
.cgd-light .site-relay-home :is(.section-label p,.blog-kicker,.blog-feature p,.skill p,.education-topic-links){color:var(--quiet)}
.cgd-light .site-relay-home :is(.blog-feature,.skill,.quote){color:var(--graph);background:var(--sheet);border-color:var(--edge);box-shadow:none}
.cgd-light .site-relay-home :is(.blog-feature h3,.blog-feature .lime,.quote h2,.skill h3){color:var(--graph)}
.cgd-light .site-relay-home .skill:is(:hover,.is-active){background:#e1ded7;border-color:#c0bcb2;color:var(--graph)}
.cgd-light .site-relay-home .skill:is(:hover,.is-active) p{color:var(--quiet)}
.cgd-light .site-relay-home .project{background:#222220;color:#fff;border-color:#fff}
.cgd-light .site-relay-home .project .role{background:#faf9f7;color:#222220}
.cgd-light .site-relay-home .project span:not(.role){color:#fff}
.cgd-light .site-relay-home .blog-feature .museum-cover{color:#fff}
.cgd-light .site-relay-home .home-about-editorial{background:var(--cream);color:var(--graph);border-radius:inherit}
.cgd-light .site-relay-home .contact{background:var(--sheet);color:var(--graph);border-color:var(--edge);text-align:center;border-radius:clamp(20px,3vw,42px)}
.cgd-light .site-relay-home .contact h2{color:var(--graph);max-width:24ch;margin-inline:auto;font-weight:600}
.cgd-light .site-relay-home .footer{background:var(--cream);color:var(--quiet);border-color:var(--edge);font-family:Manrope,Arial,sans-serif}
.cgd-light .site-relay-home :is(.blog-link,.contact>a,.hero-portfolio,.reference-nav .telegram){background:var(--graph);color:#fff;border-color:var(--graph);box-shadow:none}
.cgd-light .site-relay-home .hero-portfolio::before,.cgd-light .site-relay-home .hero-portfolio::after{display:none}
.cgd-light .site-relay-home .ue{width:var(--home-width);margin-inline:auto;border-radius:clamp(20px,4vw,56px);overflow:hidden}
@media(min-width:1600px){.cgd-light .site-relay-home .portfolio-grid{grid-auto-rows:clamp(140px,8vw,185px)}}

/* Guides, article directory, cases, and legal pages. */
.cgd-light body.reading-dark{--reading-bg:#eeede9;--reading-text:#222220;--reading-muted:#575651;--reading-surface:#faf9f7;--reading-line:#d5d2cb;color:var(--graph)}
.cgd-light .reading-dark :is(.reading-header,.reading-menu a,.reading-language,.reading-menu a:hover,.reading-menu a[aria-current],.reading-language:hover){color:var(--graph)}
.cgd-light .reading-dark .reading-brand img{filter:brightness(0)}
.cgd-light .reading-dark :is(.article-directory-card,.article-directory-categories a,.seo-aside){background:var(--sheet);border-color:var(--edge);color:var(--graph)}
.cgd-light .reading-dark .article-directory-card:hover,.cgd-light .reading-dark .article-directory-categories a:hover{background:#fff;border-color:#a7a298;color:var(--graph)}
.cgd-light .reading-dark :is(.article-directory-time,.seo-aside nav p,.seo-aside nav a,.reading-details a,.reading-bio,.utility-footer,.facts,.eyebrow,.hero .lead,.seo-lead){color:var(--quiet)!important}
.cgd-light .reading-dark :is(.editorial-hero,.editorial-inline) figcaption,.cgd-light .site-relay-article :is(figcaption,.media-note){color:var(--quiet)!important}
.cgd-light .reading-dark :is(.editorial-hero,.editorial-inline)>img,.cgd-light .reading-dark .article-directory-card>img{background:var(--sheet);border-color:var(--edge)}
.cgd-light .reading-dark :is(.reading-next>a,.seo-copy a,.seo-copy strong,.article strong,.metrics b,.ai-allocation-legend h4,.ai-allocation-copy h3,.ai-article-toc summary,.article-language,.lime,.end a){color:var(--graph)!important}
.cgd-light .reading-dark :is(.seo-copy a,.reading-next>a){text-decoration-color:#888479}
.cgd-light .reading-dark :is(.pull,.dialogue,.metrics>div,.article-gallery figure,.story-media figure,.film){color:var(--graph);background:var(--sheet);border-color:var(--edge);box-shadow:none}
.cgd-light .reading-dark :is(.metrics span,.ai-allocation figcaption,.ai-article-toc,.ai-allocation-legend p,.media-note){color:var(--quiet)!important}
.cgd-light .reading-dark :is(.reading-next,.end,.facts,.reading-mobile-toc,.ai-allocation-legend li,.ai-article-toc details){border-color:var(--edge)}
.cgd-light .reading-dark :is(.hero-media,.article-visual,.ai-case-visual){border-color:var(--edge);box-shadow:none}
.cgd-light .reading-dark :is(.skip-link,.ai-skip-link){color:white;background:var(--graph)}
.cgd-light .site-relay-utility :is(.utility-main p,.utility-main li,.utility-footer,.utility-kicker){color:var(--quiet)}
.cgd-light .site-relay-utility :is(.utility-main h1,.utility-main h2,.utility-main a:not(.utility-cta),.utility-brand){color:var(--graph)}
.cgd-light .site-relay-utility .utility-cta{background:var(--graph);color:white;border-color:var(--graph)}

/* Shared dialogs, consent, comments and contact chat. */
.cgd-light:not([data-education-theme=dark]) body :is(.privacy-dialog,.cgd-consent,.cg-chat-panel,.cgd-comments textarea,.cgd-comment){background:var(--sheet)!important;color:var(--graph)!important;border-color:var(--edge)!important}
.cgd-light:not([data-education-theme=dark]) body :is(.privacy-copy h2,.cgd-consent h2,.cgd-consent p,.cgd-consent-settings,.cg-chat-heading,.cg-chat-row,.cgd-comments,.cgd-comment-label,.cgd-comment-status,.cgd-comment-author,.cgd-comments a,.cgd-comment p,.cgd-comment-time,.cgd-comment-empty){color:var(--graph)!important}
.cgd-light:not([data-education-theme=dark]) body :is(.privacy-copy p,.privacy-copy li,.cg-chat-intro,.cg-chat-heading span,.cg-chat-contact span,.cg-chat-consent,.cg-chat-activity,.cg-chat-unavailable,.cgd-comments p,.cgd-comments time){color:var(--quiet)!important}
.cgd-light:not([data-education-theme=dark]) body .cg-chat{--cg-bg:#faf9f7;--cg-text:#222220;--cg-line:#d5d2cb}
.cgd-light:not([data-education-theme=dark]) body :is(.cg-chat-heading,.cg-chat-row,.cg-chat input:not([type=checkbox]),.cg-chat textarea){background:var(--cream)!important;color:var(--graph)!important;border-color:var(--edge)!important}
.cgd-light:not([data-education-theme=dark]) body :is(.cgd-consent-actions button,.cg-chat-toggle,.cg-chat-send-row button,.cg-chat-badge,.cgd-comments button[type=submit]){background:var(--graph)!important;color:#fff!important;border-color:var(--graph)!important;box-shadow:none}
.cgd-light:not([data-education-theme=dark]) body .cgd-consent-actions button[data-consent=reject]{background:#fff!important;color:var(--graph)!important;border-color:var(--edge)!important}

/* Learning retains its existing optional dark mode and editable accent. */
html.cgd-light[data-education-theme=light]:has(.learning-builder){--learn-bg:#eeede9;--learn-ink:#222220;--learn-muted:#575651;--learn-purple:#4d4a43;--learn-line:#d5d2cb;--learn-glass:#fffaf3cc;--text:#222220;--muted:#575651;--line:#d5d2cb;--surface:#faf9f7;--graphite:#faf9f7;--mint:#4d4a43;--ink:#222220;--accent-text:#4d4a43}
.cgd-light[data-education-theme=light] .learning-builder .learn-atmosphere{background:var(--cream)}
.cgd-light[data-education-theme=light] .learning-builder[data-learning-scene=home] .learn-atmosphere{background:linear-gradient(120deg,rgb(var(--learn-glow-rgb)) 0%,rgb(var(--learn-glow-soft-rgb)) 100%)}
.cgd-light[data-education-theme=light] .learning-builder :is(.learn-button-dark,.learn-confirm,.learn-button[type=submit]){background:var(--graph);border-color:var(--graph);color:white}
.cgd-light[data-education-theme=light] .learning-builder :is(.learn-option[aria-pressed=true],.learn-homework-option:has(:checked)){background:#e1ded7!important;border-color:#8b857a}
.cgd-light[data-education-theme=light] .learning-builder .learn-calendar-full .learn-calendar-cell:disabled{background:#dedbd4;color:#575651;border-color:#c6c1b7}
.cgd-light[data-education-theme=light] .learning-builder .learn-header .reference-menu{background:#fff;border-color:var(--edge)}
.cgd-light[data-education-theme=light] .learning-builder .learn-header .reference-menu a{color:var(--graph)}
.cgd-light[data-education-theme=light] .learning-builder .learn-header .reference-menu a[aria-current]{color:#fff}
.cgd-light[data-education-theme=light] .learning-builder .learn-header .nav-glider{background:var(--graph);border-color:var(--graph)}
@media(max-width:600px){.cgd-light .site-relay-home .stage.reference-stage{min-height:max(540px,80svh)}.cgd-light .site-relay-home .stage.reference-stage .reference-copy h1.hero-intro{font-size:clamp(33px,8.3vw,48px)}}
html.cgd-light:not([data-education-theme=dark]) body.site-relay-home{background:var(--canvas)!important}
.cgd-light .site-relay-home .stage.reference-stage .hero-portfolio:is(:hover,:focus-visible){box-shadow:none;background:#393833;color:white}
.cgd-light .site-relay-home .education-topic-links a:hover{color:var(--graph);text-decoration:underline}
.cgd-light .reading-dark .end a{background:var(--sheet);border-color:var(--edge)}
.cgd-light .reading-dark .hero-media :is(.label,.foot){color:#fff}
.cgd-light:not([data-education-theme=dark]) body .cgd-article-return a{background:var(--sheet);color:var(--graph);border-color:var(--edge)}
.cgd-light:not([data-education-theme=dark]) body .privacy-dialog .dialog-close{background:var(--graph);color:#fff;border-color:var(--graph)}
.cgd-light[data-education-theme=light] .learning-builder .learn-header .reference-menu a[aria-current]{background:var(--graph);color:#fff}
.cgd-light[data-education-theme=light] .learning-builder :is(.learn-orb,.learn-orb-glow){filter:grayscale(1)}
.cgd-light[data-education-theme=light] .learning-builder .learn-header .telegram{background:var(--graph);color:#fff;border-color:var(--graph)}
.cgd-light[data-education-theme=light] .learning-builder .learn-theme-toggle{background:var(--sheet);color:var(--graph);border-color:var(--edge)}

@media(min-width:700px){.cgd-light .site-relay-home .stage.reference-stage .reference-hero{padding-bottom:max(20px,env(safe-area-inset-bottom))}}

/* Keep editorial headings and navigation readable on the light canvas. */
.cgd-light body.reading-dark :is(h1,h2,h3,h4){color:var(--graph)}
.cgd-light body.reading-dark :is(.seo-breadcrumbs a,.reading-details summary){color:var(--quiet)!important}
.cgd-light body[data-no-analytics-ui] .cgd-article-return{display:flex;justify-content:center;margin:clamp(28px,5vw,56px) auto 0;padding-inline:16px}
.cgd-light body[data-no-analytics-ui] .cgd-article-return a{display:inline-flex;justify-content:center;align-items:center;min-width:104px;min-height:44px;padding:10px 20px;border:1px solid var(--edge);border-radius:999px;background:var(--sheet);color:var(--graph);text-align:center;text-decoration:none;line-height:1.2;font-size:14px}
.cgd-light body[data-no-analytics-ui] .cgd-article-return a:hover{background:#fff;border-color:#8b857a;text-decoration:none}
