:root{color-scheme:light dark;--header-height:78px;--color-page:#f5f3ed;--color-text:#242721;--color-text-muted:#565b50;--color-text-accent:#a32834;--color-surface-interactive:#eee;--color-surface-interactive-hover:#e5e5e5;--color-surface-raised:#f8f8f8;--color-surface-notch:#262626;--color-text-on-notch:#f8f8f8;--color-divider:#d5d7cb;--color-divider-demo:#c8c8c8;--color-control-edge:#757575;--color-focus:#262626;--mono:ui-monospace,"SFMono-Regular",Consolas,monospace;--sans:"Avenir Next",Avenir,"Segoe UI",system-ui,sans-serif}html{scroll-padding-top:var(--header-height)}*,:after,:before{box-sizing:border-box}body{margin:0;background:var(--color-page);color:var(--color-text);font:16px/1.55 var(--sans)}[hidden]{display:none!important}html[lang=en] [data-copy=pt],html[lang=pt-BR] [data-copy=en]{display:none}a{color:inherit;text-decoration:none}button{font:inherit;cursor:pointer}:focus-visible{outline:2px solid var(--color-focus);outline-offset:4px}summary{cursor:pointer;list-style:none}summary::-webkit-details-marker{display:none}figure,h1,h2,h3,h4,p{margin:0}::selection{background:var(--color-surface-interactive);color:var(--color-text)}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.page-width{max-width:1120px;padding-inline:clamp(20px,5vw,72px);margin-inline:auto}.topbar{position:sticky;top:0;z-index:10;border-bottom:1px solid var(--color-divider);background:var(--color-page)}.topbar-content{min-height:calc(var(--header-height) - 1px);display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:24px}.wordmark{justify-self:start;margin-inline-start:-4px;padding:4px;font-size:22px;font-weight:750;line-height:1.35;letter-spacing:-.03em;white-space:nowrap}@property --title-fill{syntax:"<number>";inherits:false;initial-value:0}@supports (background-clip:text){@media (forced-colors:none){[data-title-fill]{--title-fill:0;color:transparent;background-image:radial-gradient(circle farthest-corner at var(--title-fill-origin,left center),var(--color-text-accent) calc(var(--title-fill) * 1%),var(--color-text) calc(var(--title-fill) * 1%));background-clip:text;transition:--title-fill .74s ease-out}[data-title-fill]:is([data-fill-active],:focus-visible),a:focus-visible [data-title-fill]{--title-fill:100}}}.topbar nav{display:flex;align-items:center;gap:clamp(14px,4vw,32px);font-size:13px;font-weight:600}.inline-link,.topbar nav a{min-height:24px;display:inline-flex;align-items:center}.inline-link:is(:hover,:focus-visible),.topbar nav a:is(:hover,:focus-visible){text-decoration:underline;text-underline-offset:4px}.language{justify-self:end;display:flex;gap:2px;border:1px solid var(--color-control-edge);border-radius:7px;padding:3px}.language button{min-width:24px;min-height:24px;border:0;border-radius:4px;background:transparent;color:var(--color-text-muted);font:11px var(--mono);padding:6px 8px}.language button[aria-pressed=true]{background:var(--color-surface-interactive);color:var(--color-text-accent);font-weight:700;text-decoration:underline;text-underline-offset:3px}.language button:hover{background:var(--color-surface-interactive-hover)}.language button:focus-visible{outline-offset:0}.frames{display:grid;align-items:start}.frame{min-width:0}.app-version,.caption,figure figcaption{font: 12px/1.45 var(--mono)}.role{margin-top:16px;color:var(--color-text-accent);font-size:14px;font-weight:650}h1{font-size:clamp(40px, 7.1vw, 92px);line-height:.97;letter-spacing: -.053em;font-weight:670}.about{margin-top:12px}.about summary,.inline-link{min-height:24px;display:inline-flex;align-items:center;gap:6px;color:var(--color-text-accent);font-size:13px;font-weight:700}
.work-perspectives { min-width: 0; max-width: 46ch; margin: 6px 0 0; padding: 0; border: 0; font-size: 13px; }
.work-options { display: flex; flex-wrap: wrap; gap: 0 16px; }
.work-options label { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; cursor: pointer; }
.work-options input { margin: 0; accent-color: var(--color-text-accent); }
.work-options label:has(input:checked) { font-weight: 700; }
.work-panels { display: grid; margin-top: 5px; color: var(--color-text-muted); }
.work-panels p { grid-area: 1 / 1; line-height: 1.5; }
.work-engineering, .work-perspectives:has(.work-engineering-option:checked) .work-product { visibility: hidden; }
.work-perspectives:has(.work-engineering-option:checked) .work-engineering { visibility: visible; }
/* Keep the alternate perspective in flow so switching views preserves the panel height. */
.about[open] summary svg,.case-notes[open] summary svg{transform:rotate(45deg)}.link-row{display:flex;align-items:center;gap:8px 16px;flex-wrap:wrap;margin-top:12px}.section-heading{border-bottom:1px solid var(--color-divider);padding-bottom:12px;font:700 18px/1.35 var(--sans)}.case,.cases,.other{scroll-margin-top:18px}.case{border-bottom:1px solid var(--color-divider);padding-top:24px}.case-grid{display:grid;grid-template-columns:.84fr 1.16fr;gap:clamp(16px,4vw,48px);align-items:start}.app-version,.caption,figure figcaption{color:var(--color-text-muted)}.case-title{display:flex;align-items:center;gap:12px;font-size:clamp(42px,6vw,73px);line-height:1.04;letter-spacing: -.052em;font-weight:690}.case-title img{flex:none;width:clamp(40px,5vw,52px);height:auto;aspect-ratio:1;border-radius:11px;object-fit:contain}.case{padding-bottom:24px}.case-page{padding-top:24px}.case-page .case{border-bottom:0}.case-lead{max-width:43ch;margin-top:16px;font-size:clamp(17px,2vw,21px);line-height:1.45}.case-page .frila-art{display:grid;justify-items:center;gap:8px;min-height:0}.frila-art img{display:block;width:min(100%,380px);height:auto}.case-page .frila-art figcaption{position:static;font-size:13px}.dotch-demo {
  min-height: 0;
  overflow: visible;
  border-radius: 0;
}
.dotch-demo figcaption {
  position: static;
  margin-top: 8px;
  font: 13px/1.5 var(--sans);
}.case-sections{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:32px clamp(16px,4vw,48px);margin-top:40px}.case-section{border-top:1px solid var(--color-divider);padding-top:16px}.case-section h2{font-size:18px;line-height:1.3;margin-bottom:8px}.case-section p,.case-section ul{max-width:54ch;color:var(--color-text-muted)}.case-section ul{margin:8px 0 0;padding-inline-start:20px}.case-section ul li+li{margin-top:6px}.case-flow{display:grid;gap:4px;font-size:14px}.case-flow{margin:0 0 8px;padding-inline-start:20px}.case-title a{padding-inline:.08em;margin-inline:-.08em}.case-title a:is(:hover,:focus-visible){text-decoration:underline;text-decoration-color:var(--color-text);text-decoration-thickness:2px;text-underline-offset:6px}.case .caption{margin-top:8px}.pitch{font-size:clamp(17px,2vw,22px);font-weight:650;letter-spacing:-.03em;margin-top:9px;line-height:1.25}.description{max-width:43ch;margin-top:12px;color:var(--color-text-muted);font-size:15px;line-height:1.55}.case-result{margin-top:16px;font-size:14px;font-weight:700}.store-links{margin-top:4px}figure{position:relative;isolation:isolate;overflow:hidden;min-height:257px;border-radius:11px}figure figcaption{position:absolute;z-index:1;bottom:13px;left:15px}#frila{--frila-orange:#eb5d39;--frila-bone:#fbf6ec;--frila-ink:#351b14;--frila-accent-text:#a63821;--frila-divider:#e7d8ca}#frila .case-notes summary{color:var(--frila-accent-text)}.frila-visual{background:var(--frila-orange);display:grid;place-items:center;padding:30px 18px 44px}.frila-visual figcaption,.shift-card{color:var(--frila-ink)}.shift-card{background:var(--frila-bone);width:min(342px,100%);border:1px solid var(--frila-divider);border-radius:10px;padding:14px 19px 16px}.shift-data,.shift-top{display:flex;align-items:center;justify-content:space-between;gap:7px 12px;flex-wrap:wrap}.shift-brand{color:var(--frila-accent-text);font-size:23px;font-weight:800;letter-spacing:-.06em}.shift-kind{color:var(--color-text-muted);font-size:12px}.shift-title{font-weight:750;font-size:clamp(17px,2.2vw,25px);line-height:1.18;margin-top:9px;letter-spacing:-.04em}.shift-data>span,.shift-location{display:flex;align-items:center;gap:5px;font-size:12px}.shift-location{margin-top:7px}.shift-data{border-top:1px solid var(--frila-divider);padding-top:9px;margin-top:12px;justify-content:flex-start;gap:8px 17px}.dotch-visual {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  place-items: start center;
  min-height: 257px;
  border-radius: 11px;
  background:radial-gradient(ellipse at 88% 104%,#080e35 3%,transparent 62%),linear-gradient(147deg,transparent 31%,#62cbd25e 32%,#427eda7d 51%,transparent 52%),linear-gradient(27deg,#15185a 4%,#4139a4 38%,#226cc8 67%,#5489d7 82%,#3a2883);
}.dotch-visual--with-menu{--dotch-menu-height:28px;--dotch-trigger-width:56px;--dotch-menu-surface:#101014;grid-template-columns:minmax(0,1fr);align-content:start;padding-inline:0}.dotch-visual--with-menu>*{grid-area:1/1}.dotch-visual--with-menu .notch{max-width:calc(100% - 24px);background:var(--dotch-menu-surface);border-radius:0 0 20px 20px}.dotch-visual--with-menu .notch summary{position:relative;z-index:2;width:var(--dotch-trigger-width);min-height:var(--dotch-menu-height);margin-inline:auto;border-radius:4px}.dotch-menu-bar{z-index:1;display:grid;grid-template-columns:minmax(0,1fr) var(--dotch-trigger-width) minmax(0,1fr);align-items:center;gap:6px;width:100%;height:var(--dotch-menu-height);padding-inline:12px;background:var(--dotch-menu-surface);color:#f4f4f6;font-size:11px;white-space:nowrap;font-variant-numeric:tabular-nums;container-type:inline-size}.dotch-menu-app,.dotch-menu-status{display:flex;align-items:center;gap:10px}.dotch-menu-status{grid-column:3;justify-self:end}@container (width < 430px){.dotch-menu-view{display:none}}@container (width < 315px){.dotch-menu-edit{display:none}}:is(.about,.case-notes,.notch){--disclosure-duration:200ms;--disclosure-easing:cubic-bezier(.22,1,.36,1)}.notch{--hover-delay:1s;--disclosure-duration:260ms;width:min(148px,100%);background:#101014;color:var(--color-text-on-notch);border-radius:0 0 18px 18px;transition:width var(--disclosure-duration) var(--disclosure-easing)}.notch[open]{width:min(344px,100%)}@supports (interpolate-size:allow-keywords) and selector(::details-content){:is(.about,.case-notes,.notch){interpolate-size:allow-keywords}:is(.about,.case-notes,.notch)::details-content{height:0;opacity:0;overflow:clip;transition:height var(--disclosure-duration) var(--disclosure-easing),opacity .16s ease,content-visibility var(--disclosure-duration) allow-discrete}:is(.about,.case-notes,.notch)[open]::details-content{height:auto;opacity:1}}.about[open]>p,.case-notes[open]>.notes-grid{animation:disclosure-slide-in var(--disclosure-duration) var(--disclosure-easing)}@keyframes disclosure-slide-in{0%{transform:translateY(-5px)}}.notch summary{display:grid;place-items:center;min-height:40px;border-radius:inherit}.notch-handle{position:relative;width:35px;height:3px;border-radius:3px;background:#777780}.notch-handle:after{content:"";position:absolute;inset:0;transform:scaleX(0);transform-origin:left;border-radius:inherit;background:var(--color-text-on-notch)}.notch[data-hovering] .notch-handle:after{transform:scaleX(1);transition:transform var(--hover-delay) linear}.notch :focus-visible{outline-color:var(--color-text-on-notch)}.notch summary:focus-visible{outline-offset:-4px}.notch-body{padding:0 12px 14px;font-size:13px}.notch-heading{display:flex;align-items:baseline;gap:12px;padding:0 8px 8px;border-bottom:1px solid #414148}.notch-heading span{color:#babac3;font-size:11px}.notch-files{margin:4px 0 0;padding:0;list-style:none}.notch-files li{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:6px}.notch-files li+li{border-top:1px solid #414148}.notch-files a{display:grid;align-items:center;padding:7px 8px;border-radius:6px}.notch-file{grid-template-columns:auto minmax(0,1fr);gap:8px;min-height:39px}.notch-download{width:36px;height:34px;justify-items:center;border:1px solid #666670}.notch-files a:is(:hover,:focus-visible){background:#2c2c37;text-decoration:underline;text-underline-offset:3px}.notch-files a:focus-visible{outline-offset:-2px}.case-notes summary{padding:12px 0;display:flex;width:fit-content;align-items:center;gap:8px;font-size:13px;font-weight:730;color:var(--color-text-accent)}.about summary:is(:hover,:focus-visible),.case-notes summary:is(:hover,:focus-visible){text-decoration:underline;text-underline-offset:4px}.notes-grid{border-top:1px solid var(--color-divider);display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px 24px;padding:16px 0 24px}.notes-grid h4{font-size:13px;margin-bottom:5px}.notes-grid p{font-size:13px;color:var(--color-text-muted);line-height:1.45}.other{padding-top:clamp(42px,7vw,75px)}
.more-projects { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(24px, 5vw, 56px); }
.more-project { padding-block: 18px; border-bottom: 1px solid var(--color-divider); }
.more-project .case-title { gap: 9px; font-size: clamp(22px, 3vw, 30px); letter-spacing: -.045em; }
.more-project .case-title img { width: 32px; border-radius: 8px; }
.more-project .description { margin-top: 8px; }
.more-project .link-row { margin-top: 6px; }
.footer{font-size:13px;color:var(--color-text-muted);padding-block:24px 32px}@media (max-width:660px){:root{--header-height:62px}.topbar-content{gap:9px}.topbar nav{font-size:12px}.case-grid,.case-sections,.intro,.notes-grid,.more-projects{grid-template-columns:1fr}.case{padding-top:14px}:is(.frila-visual, .dotch-visual) { min-height: 215px; }}@media (max-width:430px){:root{--header-height:88px}.topbar-content{grid-template-columns:1fr auto;gap:0 16px;padding-block:8px}.wordmark{grid-column:1/-1;font-size:20px}.topbar nav{gap:16px}}@media (prefers-reduced-motion:reduce){*,:after,:before{transition:none!important}:is(.about,.case-notes,.notch)::details-content{transition:none!important}.about[open]>p,.case-notes[open]>.notes-grid{animation:none}}


@media (pointer: coarse) {
  .topbar nav a, .language button,
  .inline-link, .about summary, .work-options label { min-height: 36px; }
}

.case-walkthrough { container-type: inline-size; }
.case-sections > .case-walkthrough { grid-column: 1 / -1; width: min(100%, 620px); }
.case-walkthrough .walkthrough-intro { font-size: 14px; }
.walkthrough-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  min-inline-size: 0;
  margin: 14px 0 0;
  padding: 0;
  border: 0;
}
.walkthrough-steps--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.walkthrough-steps label {
  display: grid;
  place-items: center;
  min-height: 44px;
  padding: 6px 4px;
  border: 1px solid var(--color-control-edge);
  border-radius: 6px;
  text-align: center;
  overflow-wrap: anywhere;
  font-size: clamp(13px, 3.3cqi, 14px);
  line-height: 1.25;
  font-weight: 650;
  cursor: pointer;
}
.walkthrough-steps input:checked + label {
  color: var(--color-text-accent);
  background: var(--color-surface-interactive);
  border-color: currentColor;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.walkthrough-steps input:focus-visible + label { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.walkthrough-panels {
  grid-column: 1 / -1;
  display: grid;
  border: 1px solid var(--color-divider);
  border-radius: 8px;
  background: var(--color-surface-raised);
}
.walkthrough-panel {
  grid-area: 1 / 1;
  visibility: hidden;
  min-width: 0;
  padding: clamp(14px, 4%, 22px);
}
.walkthrough-steps input:nth-of-type(1):checked ~ .walkthrough-panels .walkthrough-panel:nth-child(1),
.walkthrough-steps input:nth-of-type(2):checked ~ .walkthrough-panels .walkthrough-panel:nth-child(2),
.walkthrough-steps input:nth-of-type(3):checked ~ .walkthrough-panels .walkthrough-panel:nth-child(3),
.walkthrough-steps input:nth-of-type(4):checked ~ .walkthrough-panels .walkthrough-panel:nth-child(4) { visibility: visible; }
.walkthrough-panel h3 { font-size: 17px; line-height: 1.3; }
.walkthrough-panel p, .walkthrough-panel blockquote { margin: 10px 0 0; font-size: 14px; }
.walkthrough-panel dl {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  font-size: 14px;
}
.walkthrough-panel dt { font-weight: 700; }
.walkthrough-panel dd { margin: 0; color: var(--color-text-muted); }
.walkthrough-panel blockquote { border-inline-start: 2px solid var(--color-divider); padding-inline-start: 10px; }
@container (width >= 410px) {
  .walkthrough-steps--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.intro { padding-block: clamp(52px, 8vw, 115px) clamp(54px, 8vw, 104px); }
.hero-letter { position: relative; display: inline-block; }
.hero-ball {
  position: absolute;
  top: 50%;
  left: 54%;
  display: none;
  width: .5em;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 28%, #f3ac6b 0%, #d5793c 37%, #ad5023 74%, #803b1f 100%);
  box-shadow: inset 0 0 0 1px #7e391e;
  transform: translate(-50%, -36%);
}
.hero-ball svg { display: block; width: 100%; height: 100%; fill: none; stroke: #713619; stroke-width: .075; stroke-linecap: round; stroke-linejoin: round; }
[data-hero-ball-ready] .hero-ball { display: block; }
[data-hero-ball-ready] .hero-letter-text { color: transparent; }

.personal-story { margin-block-end: clamp(46px, 8vw, 95px); }
.personal-section {
  display: grid;
  grid-template-columns: minmax(135px, .48fr) minmax(0, 1fr);
  gap: clamp(16px, 4vw, 44px);
  align-items: start;
  border-top: 1px solid var(--color-divider);
  padding-block: clamp(22px, 4.5vw, 48px);
  scroll-margin-top: 12px;
}
.personal-section > h2 { border: 0; padding: 0; }
.personal-bio { max-width: 61ch; }
.personal-bio .role { margin-top: 0; margin-bottom: 9px; }
.personal-bio .personal-lead {
  max-width: 40ch;
  font-size: clamp(20px, 2.4vw, 28px);
  line-height: 1.34;
  letter-spacing: -.019em;
}
.personal-lead + p { margin-top: 12px; color: var(--color-text-muted); }
.personal-links { margin-top: 16px; }
.personal-links > a { color: var(--color-text-muted); }
/* In the dark theme the contact links sit close to white. */
:root[data-theme=dark] .personal-links > a { color: #e4e3dc; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) .personal-links > a { color: #e4e3dc; } }
.journey-list { margin: 0; padding: 0; list-style: none; }
.journey-list li {
  display: grid;
  grid-template-columns: 4ch minmax(0, 1fr);
  gap: clamp(12px, 3vw, 30px);
  padding-block: 16px;
  border-bottom: 1px solid var(--color-divider);
}
.journey-list li:first-child { padding-top: 0; }
.journey-list li:last-child { padding-bottom: 0; border-bottom: 0; }
.journey-list time { padding-top: 4px; font: 13px/1.35 var(--mono); color: var(--color-text-muted); }
.journey-list h3 { font-size: 16px; line-height: 1.4; }
.journey-list p { max-width: 53ch; margin-top: 4px; color: var(--color-text-muted); font-size: 15px; }
.personal-bio .personal-lead { font: inherit; letter-spacing: inherit; max-width: inherit; }
.work-method { margin-top: 18px; }
.work-method h3 { font: 650 16px/1.5 var(--sans); }
.work-method label { position: relative; min-height: 44px; color: var(--color-text); }
.work-method input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.work-method label span { transition: color 180ms ease, transform 180ms ease; }
.work-method label:has(input:checked) span { color: var(--color-text-accent); transform: scale(1.05); text-decoration: underline; text-underline-offset: .36em; }
.work-method label:has(input:focus-visible) { outline: 2px solid var(--color-focus); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .work-method label span { transition: none; } }

@media (max-width: 660px) {
  .intro { padding-block: 42px 34px; }
  .personal-section { grid-template-columns: 1fr; }
}
@media (max-width: 430px) {
  .topbar nav { gap: clamp(8px, 3vw, 16px); }
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme=light]) {
    color-scheme: dark;
    --color-page: #141513;
    --color-text: #ecebe4;
    --color-text-muted: #a9aba0;
    --color-text-accent: #f0717a;
    --color-surface-interactive: #262823;
    --color-surface-interactive-hover: #30322c;
    --color-surface-raised: #1b1c19;
    --color-divider: #34362f;
    --color-divider-demo: #3c3d39;
    --color-control-edge: #8b8d84;
    --color-focus: #ecebe4;
  }
  :root:not([data-theme=light]) #frila { --frila-accent-text: #f58d6e; }
  :root:not([data-theme=light]) .shift-card { --color-text-muted: #6d5d53; --frila-accent-text: #a63821; }
  :root:not([data-theme=light]) .frila-art img { padding: 12px; border-radius: 11px; background: #f5f3ed; }
}
:root[data-theme=dark] {
  color-scheme: dark;
  --color-page: #141513;
  --color-text: #ecebe4;
  --color-text-muted: #a9aba0;
  --color-text-accent: #f0717a;
  --color-surface-interactive: #262823;
  --color-surface-interactive-hover: #30322c;
  --color-surface-raised: #1b1c19;
  --color-divider: #34362f;
  --color-divider-demo: #3c3d39;
  --color-control-edge: #8b8d84;
  --color-focus: #ecebe4;
}
:root[data-theme=dark] #frila { --frila-accent-text: #f58d6e; }
:root[data-theme=dark] .shift-card { --color-text-muted: #6d5d53; --frila-accent-text: #a63821; }
:root[data-theme=dark] .frila-art img { padding: 12px; border-radius: 11px; background: #f5f3ed; }
:root[data-theme=light] { color-scheme: light; }


[tabindex="-1"]:focus { outline: none; }

.topbar { transition: background-color .2s ease; }
@supports (backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px)) {
  .topbar[data-scrolled] {
    background-color: color-mix(in srgb, var(--color-page) 82%, transparent);
    -webkit-backdrop-filter: blur(8px) saturate(130%);
    backdrop-filter: blur(8px) saturate(130%);
  }
}
@media (prefers-reduced-transparency: reduce) {
  .topbar[data-scrolled] { background-color: var(--color-page); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
.header-controls { justify-self: end; display: flex; align-items: center; gap: 8px; }
.theme-toggle {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--color-control-edge);
  border-radius: 7px;
  background: transparent;
  color: var(--color-text);
}
.theme-toggle:hover { background: var(--color-surface-interactive-hover); }
.theme-toggle .icon-sun, :root[data-theme=dark] .theme-toggle .icon-moon { display: none; }
:root[data-theme=dark] .theme-toggle .icon-sun { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme=light]) .theme-toggle .icon-moon { display: none; }
  :root:not([data-theme=light]) .theme-toggle .icon-sun { display: block; }
}
@media (pointer: coarse) { .theme-toggle { width: 44px; height: 44px; } }
:is(.topbar nav a, .inline-link, .case-title a, .about summary, .case-notes summary):is(:hover, :focus-visible) { text-decoration-color: var(--color-text-accent); }

/* Language switch: a highlight slides to the chosen language. */
.language { position: relative; isolation: isolate; }
.language::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 3px;
  bottom: 3px;
  left: 3px;
  width: 34px;
  border-radius: 4px;
  background: var(--color-surface-interactive);
  transition: transform .32s cubic-bezier(.22, 1, .36, 1);
}
.language:has([data-lang=en][aria-pressed=true])::before { transform: translateX(36px); }
.language button { width: 34px; padding-inline: 0; transition: color .24s ease, background-color .2s ease; }
.language button[aria-pressed=true] { background: transparent; }
.language button[aria-pressed=false]:hover { background: var(--color-surface-interactive-hover); }
.language button[aria-pressed=true]:hover { background: transparent; }

/* Expo mode (expo.js, docs/modo-expo.md). */
:root { --expo-backdrop: #d8d5cb; }
:root[data-theme=dark] { --expo-backdrop: #0a0b09; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) { --expo-backdrop: #0a0b09; } }
.expo-toggle {
  position: fixed;
  left: 20px;
  bottom: 20px;
  z-index: 30;
  display: none;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid var(--color-control-edge);
  border-radius: 999px;
  background: color-mix(in srgb, var(--color-page) 86%, transparent);
  color: var(--color-text);
  font: 650 13px/1 var(--sans);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: background-color .2s ease, color .2s ease;
}
.expo-toggle:hover { color: var(--color-text-accent); }
.expo-toggle-on, [data-expo] .expo-toggle-off { display: none; }
[data-expo] .expo-toggle-on { display: inline; }
@media (min-width: 60rem) and (hover: hover) and (pointer: fine) { .expo-toggle { display: inline-flex; } }
.expo-sheet { display: none; }
[data-expo] body { background: var(--expo-backdrop); }
[data-expo] .expo-sheet { position: fixed; inset: 0; z-index: 0; display: block; pointer-events: none; }
.expo-sheet span {
  position: absolute;
  top: 0;
  background: color-mix(in srgb, var(--color-page), #000 calc(var(--expo-shade, 0) * 100%));
}
[data-expo] #inicio { position: fixed; top: 0; right: 0; left: 0; z-index: 1; }
[data-expo] .topbar { visibility: hidden; }
[data-expo] [data-expo-container] { border-color: transparent; background: none; box-shadow: none; }
.expo-nav { display: none; }
[data-expo] .expo-nav {
  position: fixed;
  top: 50%;
  left: 20px;
  z-index: 30;
  display: block;
  max-width: 200px;
  padding: 10px 12px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--expo-backdrop) 80%, transparent);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transform: translateY(-50%);
  animation: expo-nav-in .5s .3s both;
}
.expo-nav ol { margin: 0; padding: 0; list-style: none; }
.expo-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 24px;
  color: var(--color-text);
  font: 12px/16px var(--mono);
}
.expo-nav-label { flex: 1; min-width: 0; opacity: .7; transition: opacity .15s ease; }
.expo-nav-dot {
  flex: none;
  width: 5px;
  height: 5px;
  border: 1px solid currentColor;
  border-radius: 50%;
  opacity: .7;
  transition: background-color .3s ease, opacity .3s ease;
}
.expo-nav a:is(:hover, :focus-visible) .expo-nav-label { opacity: 1; text-decoration: underline; text-decoration-color: var(--color-text-accent); text-underline-offset: 3px; }
.expo-nav a:is(:hover, :focus-visible) .expo-nav-dot { background: currentColor; opacity: 1; }
.expo-nav a[aria-current] { color: var(--color-text-accent); }
.expo-nav a[aria-current] .expo-nav-label, .expo-nav a[aria-current] .expo-nav-dot { opacity: 1; }
.expo-nav a[aria-current] .expo-nav-dot { background: currentColor; }
@keyframes expo-nav-in { from { opacity: 0; transform: translate(-8px, -50%); } }
.expo-models { display: none; }
[data-expo] .expo-models { position: fixed; inset: 0; z-index: 0; display: block; width: 100%; height: 100%; pointer-events: none; }

/* Expo mode keeps the name, theme and language controls; the section links give way to the summary. */
[data-expo] .topbar { visibility: visible; border-color: transparent; background: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; }
[data-expo] .topbar nav { visibility: hidden; }
/* Opening a page already in Expo mode: hide the flat page until expo.js has curled it. */
[data-expo-boot] body { background: var(--expo-backdrop); }
[data-expo-boot] #inicio { visibility: hidden; }

/* Short cross-fade between pages; the header stays in place. */
@view-transition { navigation: auto; }
.topbar { view-transition-name: topbar; }
::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation-duration: 240ms; }
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
}
