/* The public header owns the preferences card. Its color roles follow the active site palette. */
.style-studio {
    --studio-ink:var(--color-ink,#17364a); --studio-paper:var(--color-panel,#fbfdff);
    --studio-muted:var(--color-muted,#4c6071); --studio-accent:var(--color-accent,#16578f);
    --studio-line:color-mix(in srgb,var(--studio-ink) 20%,transparent);
    position:relative; display:inline-flex; align-items:center; gap:.4rem; min-width:0;
}
.style-studio [hidden]{display:none!important}
.style-studio summary::-webkit-details-marker{display:none}
.style-studio .visual-preferences>summary {
    list-style:none; display:flex; align-items:center; gap:8px; min-height:36px; padding:5px 13px 5px 7px;
    font:650 .88rem/1.15 var(--font-body,system-ui); color:var(--studio-ink); border-radius:999px;
    border:1px solid var(--studio-line); background:linear-gradient(150deg,color-mix(in srgb,var(--studio-paper) 92%,white),color-mix(in srgb,var(--studio-paper) 78%,var(--studio-accent)));
    box-shadow:inset 0 1px 0 #fff9,0 2px 5px #162d4817;
}
.style-studio summary::after{content:"";width:5px;height:5px;border:solid currentColor;border-width:0 1.6px 1.6px 0;transform:rotate(45deg);margin:-2px 0 0 1px}
.style-studio details[open]>summary::after{transform:rotate(225deg);margin-top:3px}
.style-emblem{position:relative;width:24px;height:24px;display:inline-block;background:#192f48;border-radius:50%;overflow:hidden;flex:none}
.style-emblem i{position:absolute;width:13px;height:13px;border-radius:65% 35% 55% 45%;transform:rotate(25deg);background:linear-gradient(145deg,#fbfffd,#83e5ee 54%,#3c8eb1);left:3px;top:2px;box-shadow:inset 0 1px 1px #fff9}
.style-emblem i:nth-child(2){left:10px;top:7px;background:linear-gradient(145deg,#efe8ff,#ad92fc 65%,#694ab9)}
.style-emblem i:nth-child(3){left:5px;top:13px;width:9px;height:9px;background:linear-gradient(145deg,#fff1d0,#eaa384)}
.header:has(.style-guide:not([hidden])){z-index:2147483001;overflow:visible}
.style-studio .style-pop,html[data-cc-appearance] .style-studio .visual-preferences-panel.style-pop {
    position:absolute;right:auto;bottom:auto;z-index:25;isolation:isolate;box-sizing:border-box;
    width:min(392px,calc(100vw - 16px));max-width:none;overflow:auto;overscroll-behavior:contain;
    border:1px solid var(--studio-line);border-radius:22px;padding:18px;color:var(--studio-ink);
    background:radial-gradient(ellipse at 88% 0%,color-mix(in srgb,#8fadd8 23%,transparent),transparent 55%),var(--studio-paper);
    box-shadow:inset 0 1px 1px #fff9,0 18px 60px #091d372c,0 3px 10px #162f461c;
    text-align:start;white-space:normal;font:400 .9rem/1.4 var(--font-body,system-ui);
    transform-origin:var(--origin-x,80%) -8px;animation:style-unfold .38s cubic-bezier(.18,.84,.24,1) both;
}
.style-studio .style-guide{margin:0;padding:0;width:min(350px,calc(100vw - 16px))}
.style-heading{position:relative;margin:0 0 13px;padding:4px 40px 14px 0;border-bottom:1px solid var(--studio-line)}
.style-studio :is(.style-heading,.style-guide-copy) h2{font:650 1.38rem/1.13 var(--font-display,system-ui);letter-spacing:-.045em;text-transform:none;margin:0;color:var(--studio-ink)}
.style-studio button{cursor:pointer}
.style-studio .style-close{position:absolute;right:0;top:0;width:32px;height:32px;min-width:0;display:grid;place-items:center;border:1px solid var(--studio-line);border-radius:50%;color:var(--studio-ink);background:var(--studio-paper);font:21px/1 system-ui;padding:0;z-index:2}
.style-guide>.style-close{right:10px;top:10px}
.style-choices{position:relative;margin:0;padding:0;border:0;min-width:0}
.style-choices legend,.style-studio .visual-preferences-panel h3,.style-studio .visual-mode-row>span{font:650 .86rem/1.3 var(--font-body,system-ui);color:var(--studio-ink);padding:0;margin:0 0 8px;text-transform:none;letter-spacing:0}
.style-choices>[data-choice]{position:absolute;right:0;top:-1.85em;border:0;background:transparent;color:var(--studio-accent);font:inherit;font-size:.77rem;text-decoration:underline;text-underline-offset:3px}
.style-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px}
.style-studio .style-grid .style-tile {
    display:flex;flex-direction:column;align-items:stretch;gap:5px;justify-content:flex-start;min-width:0;
    border:1px solid var(--studio-line);border-radius:9px;padding:4px 4px 6px;margin:0;
    color:var(--studio-ink);background:var(--studio-paper);font:500 .70rem/1.15 var(--font-body,system-ui);
    overflow-wrap:anywhere;text-align:center;
}
.style-tile[aria-pressed=true]{outline:2px solid var(--studio-accent);outline-offset:-2px}
.style-sample{height:23px;border-radius:5px;position:relative;display:block;overflow:hidden;background:var(--color-paper);border:1px solid var(--color-rule)}
.style-sample::before{content:"";position:absolute;inset:0 0 0 56%;background:var(--color-warm);border-left:1px solid var(--color-rule)}
.style-sample i,.style-sample b{position:absolute;left:9%;top:6px;width:37%;height:3px;background:var(--color-accent)}
.style-sample b{top:12px;width:22%;height:2px;background:var(--color-ink)}
[data-design=blueprint]>.style-sample{background-image:repeating-linear-gradient(90deg,transparent 0 5px,var(--color-rule) 5px 6px)}
[data-design=coral]>.style-sample::before,[data-design=studio]>.style-sample::before{border-radius:70% 0 0 70%}
[data-design=violet]>.style-sample::before{inset:4px 4px 2px 58%;box-shadow:2px 2px var(--color-accent)}
.style-studio .visual-typography,.style-studio .ill-preferences,.style-studio .visual-mode-row{border-top:1px solid var(--studio-line);padding-top:11px;margin-top:12px}
.style-studio .visual-preferences-panel .visual-field,.style-studio .visual-preferences-panel .ill-preferences .visual-field{display:grid;gap:3px;grid-template-columns:minmax(0,1fr);margin:0;font-size:.79rem;color:var(--studio-muted)}
.style-studio .visual-preferences-panel .visual-typography .visual-field{grid-template-columns:1fr minmax(0,60%);align-items:center}
.style-studio .visual-preferences-panel .ill-preferences>div{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
html[data-cc-appearance] .style-studio .visual-preferences-panel.cc-appearance :is(select,.cc-picker-trigger,.cc-picker-trigger[data-cc-picker=text-size]){
    min-height:36px;width:100%;max-width:100%;border:1px solid var(--studio-line);border-radius:9px;
    background:var(--studio-paper);color:var(--studio-ink);padding:5px 8px;box-sizing:border-box;font:inherit;font-size:.83rem;
}
.style-studio .visual-mode-row{display:flex;align-items:center;justify-content:space-between}
.style-studio .visual-mode-row>span{margin:0}
.style-studio .style-help{display:block;border:0;background:transparent;color:var(--studio-accent);font:inherit;font-size:.78rem;padding:6px 0 0;margin-top:6px;text-decoration:underline;text-underline-offset:3px}
.style-studio :is(button,summary,select):focus-visible{outline:3px solid var(--studio-accent);outline-offset:2px}
.style-film{position:relative;height:130px;overflow:hidden;border-radius:21px 21px 0 0;background:radial-gradient(ellipse at 80% 25%,#d7c5fc 0,transparent 49%),linear-gradient(115deg,#9bcddd,#dcf4f0 56%,#a3b5d3)}
.film-window{position:absolute;left:calc(50% - 97px);top:15px;width:150px;height:99px;border:1px solid #ffffffc9;border-radius:10px;background:#f0f8ff;box-shadow:0 10px 22px #1b36642c;transform:rotate(-4deg);animation:film-paper 4.5s ease both}
.film-bar{display:flex;align-items:center;gap:3px;height:15px;border-bottom:1px solid #22385c35;padding:0 7px}
.film-bar i{width:4px;height:4px;border-radius:50%;background:#536d85}
.film-page{position:relative;margin:3px 10px;color:#20577d;animation:film-ink 4.5s ease both}
.film-page strong{display:block;font:700 30px/1.2 Georgia,serif;transform-origin:left center;animation:film-type 4.5s ease both}
.film-page span,.film-page b{display:block;margin:3px 0;width:70%;height:3px;background:currentColor;opacity:.5;border-radius:5px}
.film-page span:nth-child(3){width:45%}.film-page b{width:22%;height:7px;opacity:1;margin-top:7px}
.film-palette{position:absolute;left:calc(50% + 4px);top:70px;display:flex;gap:7px;padding:8px;border-radius:20px;background:#fffe;box-shadow:0 5px 14px #1c365b40;transform:rotate(4deg)}
.film-palette i{width:17px;height:17px;border-radius:50%;background:#22618b}.film-palette i:nth-child(2){background:#ce735c}.film-palette i:nth-child(3){background:#705195}
.film-pointer{position:absolute;top:89px;left:calc(50% + 21px);width:15px;height:19px;background:#162f47;clip-path:polygon(0 0,100% 58%,59% 62%,76% 92%,55% 100%,36% 68%,7% 91%);animation:film-pick 4.5s ease both}
.style-guide-copy{padding:17px 20px 19px}
.style-primary{display:inline-flex;align-items:center;gap:15px;padding:9px 15px;border:0;border-radius:99px;background:var(--studio-accent);color:var(--color-accent-ink,white);font:650 .86rem/1.2 var(--font-body,system-ui)}
@keyframes style-unfold{from{opacity:0;transform:translateY(-7px) scale(.66,.45)}to{opacity:1;transform:none}}
@keyframes film-pick{0%,15%{transform:translate(0,0)}40%,52%{transform:translate(23px,-5px)}75%,100%{transform:translate(47px,0)}}
@keyframes film-paper{0%,35%{background:#f0f8ff}46%,68%{background:#ffeddd}81%,100%{background:#f1e6ff}}
@keyframes film-type{0%,35%{transform:scale(.85)}46%,68%{transform:scale(1)}81%,100%{transform:scale(1.12)}}
@keyframes film-ink{0%,35%{color:#20577d}46%,68%{color:#9c4638}81%,100%{color:#694d84}}
@media(max-width:380px){.style-grid{gap:4px}.style-studio .visual-preferences>summary{gap:4px;padding-right:8px}}
@media(prefers-reduced-motion:reduce){.style-studio *, .style-studio *::before,.style-studio *::after{animation:none!important;transition:none!important}}

.style-step h3{font:650 1.04rem/1.25 var(--font-body,system-ui);color:var(--studio-ink);margin:14px 0 6px}
.style-step h3:focus{outline:none}
.style-step-nav{display:flex;justify-content:space-between;align-items:center;gap:8px;margin:10px 0 15px}
.style-step-nav button{background:var(--studio-paper);color:var(--studio-ink);border:1px solid var(--studio-line);padding:6px 11px;border-radius:12px;font:inherit}
.style-step-nav button:disabled{opacity:.42;cursor:default}
.style-step-nav output{color:var(--studio-muted);font-variant-numeric:tabular-nums}
.guide-art{height:130px;display:flex;align-items:center;justify-content:center;gap:10px;position:relative;overflow:hidden;border-radius:21px 21px 0 0;background:linear-gradient(135deg,#a4d4df,#e6edf5 55%,#c5b6df)}
.guide-gallery img{width:23%;max-width:78px;height:auto;aspect-ratio:1;object-fit:cover;border:3px solid #fff;border-radius:9px;box-shadow:0 6px 16px #2343;animation:guide-reveal .38s backwards}
.guide-gallery img:nth-child(2){animation-delay:.12s}.guide-gallery img:nth-child(3){animation-delay:.24s}
@keyframes guide-reveal{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
.aesthetic-picker{grid-column:1/-1;min-width:0}
.aesthetic-picker>summary{cursor:pointer;list-style:none;display:flex;align-items:center;gap:10px;padding:5px 11px 5px 5px;color:var(--studio-ink);background:var(--studio-paper);border:1px solid var(--studio-line);border-radius:10px}
.aesthetic-caption{flex:1;display:grid;text-align:start}.aesthetic-caption small{color:var(--studio-muted);font-size:.74rem}.aesthetic-caption strong{font-size:.88rem}
.aesthetic-current{width:49px;height:44px;display:block;flex:none;overflow:hidden;border-radius:6px}
.aesthetic-current img,.aesthetic-mix img{width:100%;height:100%;object-fit:cover}
.aesthetic-mix{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));width:100%;height:100%}
.aesthetic-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;margin:8px 0 3px}
.aesthetic-grid button{display:flex;flex-direction:column;gap:4px;align-items:stretch;min-width:0;border:1px solid var(--studio-line);border-radius:8px;background:var(--studio-paper);color:var(--studio-ink);padding:4px;font:500 .74rem/1.2 var(--font-body,system-ui);overflow-wrap:anywhere}
.aesthetic-grid button>img,.aesthetic-grid button>.aesthetic-mix{width:100%;height:auto;aspect-ratio:1.45;object-fit:cover;border-radius:5px;overflow:hidden}
.aesthetic-grid button[aria-pressed=true]{outline:2px solid var(--studio-accent);outline-offset:-2px}
.style-studio .ill-preferences .aesthetic-picker~label:not([hidden]){grid-column:1/-1;grid-template-columns:1fr minmax(0,60%);align-items:center}

/* Public reading sizes, shared by the site and its embedded globe. */
html[data-cc-appearance][data-cc-text-size=small]{--cc-text-scale:.82}
html[data-cc-appearance][data-cc-text-size=large]{--cc-text-scale:1.25}
html[data-cc-appearance][data-cc-text-size=xlarge]{--cc-text-scale:1.55}
html[data-cc-appearance][data-cc-text-size=huge]{--cc-text-scale:1.9}
.cc-picker-option[data-size=small]{font-size:13.12px}
.cc-picker-option[data-size=large]{font-size:20px}
.cc-picker-option[data-size=xlarge]{font-size:24.8px}
.cc-picker-option[data-size=huge]{font-size:30.4px}
.style-step ul{margin:10px 0 0;padding-inline-start:1.2em;list-style:disc}
.style-step li{margin:.4em 0;line-height:1.35}
.style-step li::marker,.style-step li strong{color:color-mix(in srgb,var(--studio-accent) 68%,var(--studio-ink))}
.style-step li strong{font-weight:750}
.style-step-nav{margin:12px 0 0}
.style-step-nav .style-primary{background:var(--studio-accent);color:var(--color-accent-ink,white);gap:6px}
@media(max-width:760px){
    html:has(.style-guide:modal,.style-studio .visual-preferences[open]){overflow:hidden;overscroll-behavior:none}
    .style-studio .style-guide:modal{position:fixed}
    .style-guide::backdrop,body:has(.style-studio .visual-preferences[open])::after{background:rgba(100,112,122,.26)}
    body:has(.style-studio .visual-preferences[open])::after{content:"";position:fixed;inset:0;z-index:1000}
    .header:has(.style-studio .visual-preferences[open]){z-index:1100}
    .style-studio .style-guide{width:min(345px,calc(100vw - 24px));border-radius:15px;scroll-padding:8px}
    .style-guide .style-film,.style-guide .guide-gallery{height:44px;border-radius:14px 14px 0 0;justify-content:flex-start;padding-left:15px}
    .style-guide .film-window{left:16px;top:3px;scale:.55;transform-origin:top left}
    .style-guide .film-palette{left:102px;top:8px;scale:.8;transform-origin:top left}
    .style-guide .film-pointer{left:113px;top:27px;width:10px;height:12px}
    .style-guide .guide-gallery img{width:39px;height:39px;border-width:1px;border-radius:5px}
    .style-guide-copy{padding:10px 14px 12px}
    .style-studio .style-guide-copy h2{font:600 .79rem/1.25 var(--font-body,system-ui);letter-spacing:0;color:var(--studio-muted)}
    .style-step h3{margin:4px 0;font-size:1.12rem}
    .style-step ul{margin-top:6px}
    .style-step-nav{flex-wrap:wrap}
    .style-step-nav button{min-height:36px}
}

.style-heading{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:3px 10px}
.style-heading .style-help{margin:0;padding:4px 2px;min-height:36px;font-size:.88rem;font-weight:650}
.style-more{border:0;border-top:1px solid var(--studio-line);background:var(--studio-paper);color:var(--studio-accent);font:650 .85rem/1.25 var(--font-body,system-ui);padding:7px}
.style-more span{margin-inline-start:.4em}
html[data-cc-globe-modal]{overflow:hidden;overscroll-behavior:none}
@media(max-width:760px){
    html[data-cc-appearance] .style-studio .visual-preferences[open] .visual-preferences-panel.style-pop{
        display:grid;grid-template: auto minmax(0,1fr) auto / minmax(0,1fr);align-items:stretch;align-content:start;overflow:hidden;padding:10px 12px;
    }
    .style-heading{margin-bottom:0;padding-bottom:6px}
    .style-panel-scroll{min-height:0;min-width:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable}
    .style-panel-scroll>div{padding:12px 4px 6px}
}
