/* v0.4.18: scoped Copy controls for code and non-code examples; lesson-only. */
body.ngit-app #ngit-article{min-width:0}
body.ngit-app #ngit-article pre.ngit-copy-source{min-width:0;max-width:100%;overflow-x:auto;white-space:pre;overscroll-behavior-x:contain}
body.ngit-app #ngit-article pre>code{font:inherit;white-space:inherit;tab-size:inherit}
body.ngit-app #ngit-article .ngit-code-toolbar{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;min-width:0;max-width:100%;padding:8px 12px;margin:20px 0 0;background:#edf4f5;color:#163447;border:1px solid #d6e3e6;border-bottom:0;border-radius:8px 8px 0 0}
body.ngit-app #ngit-article .ngit-code-toolbar-label{font-size:13px;font-weight:750;line-height:1.35;color:#203c4c}
body.ngit-app #ngit-article .ngit-copy-controls{display:flex;align-items:center;gap:5px;min-width:0;margin-left:auto}
body.ngit-app #ngit-article .ngit-copy-code{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:38px;padding:7px 12px;background:#fff;color:#075a52;border:1px solid #86b6b4;border-radius:6px;font:700 13px/1.25 system-ui,-apple-system,'Segoe UI',sans-serif;white-space:nowrap;cursor:pointer}
body.ngit-app #ngit-article .ngit-copy-code:hover{background:#e3f4f1;border-color:#07866c}
body.ngit-app #ngit-article .ngit-copy-code.is-copied{background:#e0f5eb;color:#075b43;border-color:#1f936f}
body.ngit-app #ngit-article .ngit-copy-code:focus-visible{outline:3px solid #005fc7;outline-offset:3px}
body.ngit-app #ngit-article .ngit-copy-icon{display:inline-flex;align-items:center;flex-shrink:0}
body.ngit-app #ngit-article .ngit-copy-feedback{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
body.ngit-app #ngit-article .ngit-copy-manual{flex-basis:100%;grid-column:1/-1;min-width:0;max-width:100%;width:100%;resize:vertical;max-height:220px;padding:9px 10px;border:1px solid #a6beca;border-radius:6px;background:#fff;color:#183747;font:12px/1.6 ui-monospace,Consolas,monospace;white-space:pre;overflow:auto}
body.ngit-app #ngit-article .ngit-copy-manual:focus-visible{outline:3px solid #005fc7;outline-offset:2px}
body.ngit-app #ngit-article .ngit-copy-feedback.is-error{position:static;width:100%;height:auto;margin:0;clip-path:none;white-space:normal;overflow:visible;font-size:12px;font-weight:600;line-height:1.5;color:#8b2c20}
body.ngit-app #ngit-article .ngit-code-toolbar+pre{margin-top:0;border-radius:0 0 8px 8px}
/* The existing Try it Yourself button keeps its own action and styling. */
body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:8px;min-width:0;max-width:100%}
body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy>strong{grid-column:1;min-width:0}
body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy>button{grid-column:2;white-space:nowrap}
body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy>.ngit-copy-controls{grid-column:3;margin-left:0}
body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy>.ngit-copy-feedback.is-error{grid-column:1/-1}
@media(max-width:520px){
 body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy{grid-template-columns:minmax(0,1fr) auto;gap:8px;padding:10px}
 body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy>strong{grid-column:1/-1;font-size:12px}
 body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy>button{grid-column:1;justify-self:start;min-height:38px;padding:8px 9px;font-size:12px}
 body.ngit-app #ngit-article .ngit-example-toolbar.ngit-has-copy>.ngit-copy-controls{grid-column:2;justify-self:end}
 body.ngit-app #ngit-article .ngit-copy-code{font-size:12px;min-height:38px;padding:7px 9px}
}
@media(prefers-color-scheme:dark){
 body.ngit-app.ngit-dark #ngit-article .ngit-code-toolbar{background:#182d39;color:#f0f6fa;border-color:#526876}
 body.ngit-app.ngit-dark #ngit-article .ngit-code-toolbar-label{color:#f0f6fa}
 body.ngit-app.ngit-dark #ngit-article .ngit-copy-code{background:#233a43;color:#e1faf4;border-color:#86b6b4}
 body.ngit-app.ngit-dark #ngit-article .ngit-copy-feedback.is-error{color:#ffc3b8}
}
@media print{body.ngit-app #ngit-article .ngit-code-toolbar,body.ngit-app #ngit-article .ngit-copy-controls,body.ngit-app #ngit-article .ngit-copy-manual{display:none!important}body.ngit-app #ngit-article pre{border-radius:4px!important}}
