/* Responsive refinements shared by the existing page and row layouts. */
#projects{scroll-margin-top:24px}
#projects:focus{outline:none}
.learn-page{padding-top:40px}
.learn-page .learn-intro{padding:0 0 28px}
.learn-page .learn-intro h1{font-size:clamp(2.25rem,4vw,3.25rem);max-width:24ch;line-height:1.1}
.learn-page .learn-intro>p{font-size:1.0625rem;max-width:64ch;margin-top:16px}
.learn-page .plugin-callout{margin:0 0 28px;padding:20px 24px}
.learn-page .resource-section{padding:24px 0;border-top:1px solid var(--line)}
.learn-page .resource-section h2{margin:0 0 18px;font-size:1.375rem}
.learn-page .resource-start{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}
.learn-page .resource-card{display:flex;align-items:flex-start;gap:16px;min-width:0;min-height:0;padding:24px;border:1px solid var(--line);border-radius:16px;background:var(--soft);overflow:visible}
.learn-page .resource-card+.resource-card{border-top:1px solid var(--line)}
.learn-page .resource-card>.oai-icon{flex:none;margin-top:3px}
.learn-page .resource-copy{display:flex;flex-direction:column;min-width:0;width:100%;height:100%}
.learn-page .resource-copy h3{font-size:1.375rem;line-height:1.25;margin:0}
.learn-page .resource-copy p{max-width:none;margin:12px 0 16px;font-size:1rem;line-height:1.5;color:var(--muted)}
.learn-page .resource-links{margin-top:auto;gap:0 16px;align-items:flex-start}
.learn-page .resource-card a,.learn-page .resource-api-grid a,.learn-page .starter-links a{display:inline-flex;align-items:center;min-height:44px;padding:8px 0;border:0;border-radius:0;background:transparent;font-size:.9375rem;line-height:1.4;text-decoration:underline;text-underline-offset:4px;overflow-wrap:anywhere}
.learn-page .resource-card a:hover,.learn-page .resource-api-grid a:hover,.learn-page .starter-links a:hover{color:var(--accent);background:transparent}
.learn-page .learn-prompt{margin:0 0 12px;border:0}
.learn-page summary{cursor:pointer;min-height:44px;padding:10px 0;font-weight:500;line-height:1.5}
.learn-page summary:focus-visible{outline:3px solid var(--focus);outline-offset:4px;border-radius:4px}
.learn-page .learn-prompt[open] summary{margin-bottom:8px}
.learn-page .starter-prompt{max-width:80ch;margin:8px 0 20px;padding-left:16px;color:var(--ink);font-size:1rem;line-height:1.6}
.learn-page .setup-strip{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:16px 32px;align-items:start}
.learn-page .setup-strip details{margin:0}
.learn-page .setup-strip details>p:not(.starter-prompt){color:var(--muted);max-width:72ch;margin:8px 0 16px}
.learn-page .starter-links{margin:0;gap:0 20px;align-items:start}
.learn-page .resource-camera .resource-photo{display:none}
.learn-page .resource-api-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}
.learn-page .resource-api-grid>article{display:flex;align-items:flex-start;gap:14px;min-width:0;padding:20px;border:1px solid var(--line);border-radius:16px}
.learn-page .resource-api-grid h3{font-size:1.25rem;flex-wrap:wrap;line-height:1.25}
.learn-page .resource-api-grid h3 small{font-size:.75rem}
.learn-page .resource-api-grid p{margin:10px 0 8px;font-size:1rem}
.learn-page .resource-api-grid a{margin:0}
.learn-page .learn-footnote{margin-top:16px;font-size:.875rem}
.learn-page .example-links{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}
.learn-page .example-links>a{display:flex;align-items:center;justify-content:flex-start;gap:14px;padding:16px 0;border:0;min-height:72px;font-size:1rem}
.learn-page .example-links>a:hover{color:var(--accent)}
.learn-page .example-links small{margin-top:4px;font-size:.875rem}
@media(max-width:900px){.learn-page .setup-strip{grid-template-columns:1fr;gap:8px}.learn-page .resource-api-grid{gap:12px}.learn-page .resource-api-grid>article{padding:16px;gap:10px}}
@media(max-width:720px){
 .learn-page{padding-top:28px}
 .learn-page .learn-intro{padding-bottom:24px}
 .learn-page .learn-intro>p{font-size:1rem}
 .learn-page .resource-start,.learn-page .resource-api-grid{grid-template-columns:1fr;gap:14px}
 .learn-page .resource-card,.learn-page .resource-api-grid>article{padding:20px;gap:14px}
 .learn-page .plugin-callout{padding:20px;margin-bottom:24px}
 .learn-page .example-links{grid-template-columns:1fr;gap:0}
 .learn-page .example-links>a+a{border-top:1px solid var(--line)}
}
body{padding-left:env(safe-area-inset-left);padding-right:env(safe-area-inset-right)}
/* Four steps from a project choice to a working hardware build. */
.learn-steps{list-style:none;margin:0;padding:0}
.learn-page .learn-steps .resource-section{padding:32px 0 36px}
.learn-step-heading{display:flex;align-items:flex-start;gap:18px;margin-bottom:24px}
.learn-step-number{display:flex;align-items:center;justify-content:center;flex:none;width:44px;height:44px;border:1px solid var(--accent);border-radius:50%;color:var(--accent);font-size:1.25rem;font-weight:500;line-height:1}
.learn-page .learn-step-heading h2{font-size:1.625rem;line-height:1.25;margin:5px 0 10px}
.learn-page .learn-step-heading p a{text-decoration:underline;text-underline-offset:4px}
.learn-step-heading p{max-width:78ch;color:var(--muted);font-size:1rem;line-height:1.6}
.learn-page .resource-links{display:flex;flex-wrap:wrap}
.learn-prompt-panel{position:relative;border:1px solid var(--line);border-radius:16px;background:var(--soft);min-width:0;overflow:hidden}
.learn-page .learn-prompt-details>summary{min-height:76px;padding:24px 116px 24px 20px;font-size:1.0625rem;font-weight:500;line-height:1.5}
.learn-page .learn-prompt-details>summary:focus-visible{outline-offset:-4px}
.learn-prompt-copy{position:absolute;top:16px;right:16px;min-width:76px;min-height:44px;padding:10px 14px;font-size:.9375rem}
.learn-hardware-prompt{border-top:1px solid var(--line);margin:0;padding:20px 24px;max-height:400px;overflow:auto;white-space:pre-wrap;overflow-wrap:anywhere;font:inherit;font-size:1rem;line-height:1.65;scrollbar-gutter:stable}
.learn-hardware-prompt:focus-visible{outline:2px solid var(--focus);outline-offset:-4px}
.learn-page .resource-api-grid .resource-copy h3{font-size:1.25rem}
.learn-page .resource-api-grid .resource-copy h3 small{font-size:.875rem;line-height:1.3}
.learn-page .resource-api-grid .resource-links{margin-top:auto;padding-top:8px}
@media(min-width:721px) and (max-width:1000px){.learn-page .resource-api-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){
 .learn-page .learn-steps .resource-section{padding:28px 0}
 .learn-step-heading{gap:12px;margin-bottom:20px}
 .learn-step-number{width:36px;height:36px;font-size:1.125rem}
 .learn-page .learn-step-heading h2{font-size:1.375rem;margin-top:3px}
 .learn-hardware-prompt{padding:18px;max-height:360px}
}
.header-navigation{display:contents}
.menu-toggle,.filters-toggle,.search-submit>.oai-icon{display:none}
.browse-tools{display:grid;grid-template-columns:minmax(0,1fr) 220px auto;gap:16px 20px;margin:8px 0 24px}
.browse-tools .toolbar,.browse-tools .searchbar,.browse-tools .project-filters{display:contents}
.browse-tools .tabs{grid-column:1;grid-row:1;justify-self:start}
.browse-tools .filters{grid-column:1/-1;grid-row:1;justify-self:end;width:auto}
.browse-tools .query-field{grid-column:1;grid-row:2}
.browse-tools .field.compact{grid-column:2;grid-row:2}
.browse-tools .field{min-width:0;margin:0}
.browse-tools .search-submit{grid-column:3;grid-row:2;align-self:end;min-height:50px}
.header-brand{min-height:44px}
.project-info,.detail-title>div,.detail-grid>div{min-width:0}
.project-info h3,.detail-title h1,.device-content h3{overflow-wrap:anywhere}
.detail-title>.vote{flex-shrink:0}
.hardware-copy p{text-wrap:balance}
.device-guide,.plugin-devices-link{display:inline-flex;align-items:center;min-height:44px}
.footer{padding-bottom:max(28px,env(safe-area-inset-bottom))}
.footer>div a{display:inline-flex;align-items:center;min-height:44px}
.section-head>div{min-width:0}
.section-head p{color:var(--muted);font-size:1.0625rem;line-height:1.6;margin-top:16px;max-width:64ch}
.resource-copy h4{font-weight:500;margin-top:28px}
.starter-prompt,.resource-card .starter-prompt{max-width:72ch;border-left:2px solid var(--accent);padding:4px 0 4px 20px;margin:20px 0 24px;color:var(--ink);line-height:1.65}
.resource-links{display:flex;flex-wrap:wrap;gap:12px}
.starter-links{margin-top:24px}
.starter-links a{display:inline-flex;align-items:center;min-height:44px;text-decoration:underline;text-underline-offset:4px}

@media(min-width:1001px){
 .hardware-hero{height:clamp(540px,calc(100svh - 88px),840px);min-height:540px}
}
@media(min-width:1001px) and (max-width:1200px){
 .hardware-hero{height:clamp(540px,calc(100svh - 146px),840px)}
}
@media(max-width:1000px){
 .hardware-hero{padding-top:28px;gap:20px;margin-bottom:24px}
 .hardware-copy{max-width:580px}
 .hardware-copy h1{font-size:clamp(2.75rem,8vw,4.3rem)}
 .hardware-copy p{margin-top:20px;max-width:32ch;font-size:1rem}
 .hardware-copy .hero-actions{margin-top:24px}
 .hardware-scene{height:280px;aspect-ratio:auto}
 .hardware-scene canvas{display:none!important}
 .hardware-core{--x:.5;--y:.52;--w:.38;--h:.84}
 .cad-static-node{width:calc(var(--w)*100%);height:calc(var(--h)*100%)}
 .hardware-fallback figure{width:calc(var(--w)*90%);height:calc(var(--h)*90%)}
}
@media(max-width:720px){
 .header{gap:12px;padding-block:12px}
 .header>.header-brand{font-size:clamp(.9375rem,4.3vw,1.125rem);gap:8px}
 .header .account a{min-height:44px}
 .openai-logo{width:28px;height:28px}
 .hardware-copy h1{font-size:clamp(2.75rem,11.2vw,4.2rem)}
 .hardware-scene{height:clamp(210px,61vw,280px)}
 .hardware-core{--w:.56;--h:.80}
 .searchbar{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:end}
 .searchbar .field{min-width:0;margin:0}
 .searchbar .field:first-child{grid-column:1/-1}
 .searchbar input,.searchbar select{font-size:16px}
 .searchbar>button{min-height:50px;margin:0}
 .detail-title{flex-direction:column;gap:18px}
 .detail-title h1{font-size:clamp(2rem,8.5vw,3rem)}
 .detail-title p{font-size:1rem}
 .detail-title>.vote{width:64px;height:54px;flex-direction:row}
 .detail .back{display:inline-flex;align-items:center;min-height:44px}
 .dialog-close{width:44px;height:44px}
 .footer>div{column-gap:20px;row-gap:4px}
}
@media(max-width:600px){
 .project-row,.project-list.no-rank .project-row{grid-template-columns:clamp(76px,22vw,108px) minmax(0,1fr);column-gap:16px;row-gap:8px;align-items:start;padding-block:24px}
 .project-row .rank{grid-column:1;grid-row:1;font-size:1.5rem;line-height:1;margin:0}
 .project-row .media-link{grid-column:1;grid-row:2;width:100%;height:auto;aspect-ratio:1}
 .project-list.no-rank .media-link{grid-row:1/3}
 .project-row .project-info{grid-column:2;grid-row:1/4}
 .project-row .project-info h3{font-size:clamp(1.125rem,4.8vw,1.375rem);line-height:1.2}
 .project-row .project-info p{display:-webkit-box;-webkit-line-clamp:3;font-size:.875rem;line-height:1.5}
 .project-row .tag{font-size:.75rem;padding:3px 6px}
 .project-row .byline{font-size:.75rem;line-height:1.45;flex-wrap:wrap;gap:4px}
 .project-row .vote{grid-column:1;grid-row:3;justify-self:start;width:100%;height:44px;flex-direction:row;gap:8px}
 .resource-camera{padding-right:0;min-height:0}
 .resource-camera .resource-photo{position:static;width:140px;max-width:100%;margin-top:16px;grid-column:2;transform:none}
 .plugin-actions{width:100%;gap:12px;align-items:flex-start}
 .plugin-download-group{min-width:0}
 .device-row,.more-devices .device-row{grid-template-columns:88px minmax(0,1fr);gap:12px 16px;align-items:start}
 .device-content{display:contents}
 .device-image{grid-column:1;grid-row:1/3;padding:8px}
 .device-image img,.more-devices .device-image img{height:96px}
 .device-content h3,.device-use,.device-support{grid-column:2;margin:0}
 .device-description,.device-features,.device-note,.device-model{grid-column:1/-1;margin:0}
 .device-actions{grid-column:1/-1;flex-wrap:wrap;padding-left:0;gap:12px 20px;margin-top:4px}
 .device-features{gap:8px 16px}
}
@media(max-width:380px){
 .hardware-copy .hero-actions{flex-direction:column;align-items:stretch;gap:10px;max-width:320px;margin-inline:auto}
 .hardware-copy .button{width:100%}
 .header nav a{font-size:.8125rem}
 .plugin-callout{padding:20px}
}

/* Native select arrows keep a consistent inset at every breakpoint and focus state. */
select,.field select,.searchbar .field select,.searchbar .field select:focus-visible{
 appearance:none;-webkit-appearance:none;
 padding-inline-end:52px;
 background-image:url("/brand/icons/chevron-down.svg");
 background-position:right 18px center;background-size:16px 16px;background-repeat:no-repeat
}
/* Mobile has one navigation row and reveals secondary controls on demand. */
@media(max-width:720px){
 .header{position:relative;z-index:20;display:flex;flex-wrap:nowrap;justify-content:space-between;align-items:center;height:64px;min-height:64px;padding:10px 0;gap:16px}
 .header>.header-brand{flex:0 0 44px;justify-content:flex-start;width:44px;min-height:44px}
 .menu-toggle{display:inline-flex;align-items:center;justify-content:flex-end;gap:10px;min-width:80px;min-height:44px;padding:8px 0 8px 12px;border:0;border-radius:0;background:transparent;color:var(--ink);font-size:1rem}
 .menu-toggle>.oai-icon{width:22px;height:22px}
 .menu-toggle .menu-close-icon,.menu-open .menu-open-icon{display:none}
 .menu-open .menu-close-icon{display:block}
 .header-navigation{display:none;position:absolute;top:100%;left:-16px;right:-16px;background:#000;padding:8px 24px 20px;border-bottom:1px solid var(--line)}
 .menu-open .header-navigation{display:block}
 .header .header-navigation nav{display:flex;flex-direction:column;align-items:stretch;gap:0;width:100%;margin:0;padding:0;min-height:0}
 .header .header-navigation nav a,.header .header-navigation nav a:visited{justify-content:flex-start;min-height:52px;padding:12px 0;font-size:1.125rem;border:0;border-radius:0;background:transparent;color:var(--ink);white-space:normal}
 .header .header-navigation nav a.active,.header .header-navigation nav a.active:visited{background:transparent;color:var(--accent)}
 .header-navigation .selection-pill{display:none}
 .header .header-navigation .account{display:flex;flex-direction:column;align-items:stretch;gap:0;margin:12px 0 0;padding-top:12px;border-top:1px solid var(--line)}
 .header .header-navigation .account a{justify-content:flex-start;min-height:48px;padding:12px 0;border:0;border-radius:0;font-size:1rem;background:transparent}
 .hardware-hero{padding-top:32px;gap:10px;margin-bottom:8px}
 .hardware-copy h1{font-size:clamp(2.75rem,13vw,3.5rem)}
 .hardware-copy p{max-width:36ch;margin-top:18px;font-size:1rem;line-height:1.5}
 .hardware-copy .hero-actions{flex-direction:column;align-items:center;gap:4px;margin:22px auto 0;max-width:320px;width:100%}
 .hardware-copy .button.black{width:100%;max-width:320px;min-height:48px;font-size:.9375rem;padding:12px 16px}
 .hardware-copy .button:not(.black){width:auto;background:transparent;border:0;border-radius:0;padding:10px 8px;min-height:44px;font-size:.9375rem;text-decoration:underline;text-underline-offset:4px}
 .hardware-scene{height:160px}
 .hardware-core{--w:.40;--h:.86}
 .cad-static-node span{display:none}
 .section-head{padding:24px 0 12px}
 .section-head h2{font-size:1.625rem;line-height:1.2}
 .section-head p{font-size:1rem;margin-top:12px;line-height:1.5}
 .browse-tools{grid-template-columns:minmax(0,1fr) 44px;gap:12px 10px;margin:0 0 22px}
 .browse-tools .tabs{grid-column:1;grid-row:1;gap:20px;min-width:0}
 .browse-tools .tabs a{padding:11px 0;min-height:44px;border-radius:0;border-bottom:2px solid transparent;background:transparent;color:var(--muted);font-size:.9375rem}
 .browse-tools .tabs a[aria-current="page"]{color:var(--ink);border-bottom-color:var(--accent);background:transparent}
 .browse-tools .tabs>.selection-pill{display:none}
 .filters-toggle{display:inline-flex;align-items:center;justify-content:flex-end;gap:6px;grid-column:2;grid-row:1;justify-self:end;min-height:44px;min-width:44px;width:max-content;padding:8px 0 8px 8px;color:var(--ink);background:transparent;border:0;border-radius:0;font-size:.875rem}
 .filters-toggle>.oai-icon{width:18px;height:18px}
 .browse-tools .searchbar .query-field:first-child{grid-column:1;grid-row:2}
 .browse-tools #query{min-height:46px;padding:10px 16px;border-radius:8px;font-size:16px}
 .browse-tools .search-submit{grid-column:2;grid-row:2;padding:10px;min-width:44px;min-height:46px;border-radius:8px;margin:0}
 .search-submit>span{display:none}
 .search-submit>.oai-icon{display:block;width:20px;height:20px}
 .browse-tools .project-filters{display:none;grid-column:1/-1;grid-row:3;gap:12px;padding:12px 0 4px}
 .filters-open .browse-tools .project-filters{display:grid}
 .browse-tools .filters{grid-column:1;grid-row:1;justify-self:stretch;flex-wrap:wrap;width:100%;gap:8px;padding:0}
 .browse-tools .field.compact{grid-column:1;grid-row:2}
 .browse-tools .field.compact select{min-height:46px;border-radius:8px;font-size:16px}
}

/* Section destinations clear the header and remain easy to share on touch. */
.learn-page .resource-section{scroll-margin-top:112px}
.learn-step-copy{min-width:0;flex:1}
.learn-step-title{display:flex;align-items:flex-start;gap:8px}
.learn-step-title h2{flex:0 1 auto;min-width:0}
.learn-step-title h2 a:hover{text-decoration:underline;text-underline-offset:5px}
.learn-section-copy{flex:0 0 36px;display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;min-width:36px;padding:0;margin-top:0;border:0;border-radius:4px;background:transparent;color:var(--muted)}
.learn-section-copy:hover,.learn-section-copy:focus-visible{color:var(--ink);background:var(--soft)}
.learn-section-copy svg{display:block}
@media(max-width:720px){.learn-page .resource-section{scroll-margin-top:88px}.learn-section-copy{flex-basis:44px;width:44px;height:44px;min-width:44px;margin-top:-4px}}

/* One first-party demo image and a normal external link on every viewport. */
.detail .build-demo{margin:0 0 32px;min-width:0}.project-short-description{color:var(--muted);font-size:1.125rem;line-height:1.6;margin:0 0 20px;white-space:pre-line}.build-demo-credit{font-size:.8125rem;color:var(--muted);margin-top:12px}.build-demo-photo{display:block}.build-demo .detail-media{display:block;width:100%;height:auto;max-height:560px;object-fit:contain}.build-demo-cta{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;min-height:52px;max-width:100%;margin-top:12px;white-space:normal;text-align:center}.build-demo-cta .social-platform-icon{width:20px;height:20px;flex:0 0 20px}.build-demo+ .project-description{margin-bottom:32px}.build-demo figure{margin-bottom:0}
@media(max-width:620px){.build-demo .detail-media{max-height:420px}.build-demo-cta{font-size:.9375rem}}
