/* Celestia Glow family: pastel atmosphere, rounded type, frosted surfaces.
   Shared shell styling only. Experiment CSS belongs with its own module. */
@font-face { font-family: Quicksand; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/quicksand-400.woff') format('woff'); }
@font-face { font-family: Quicksand; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/quicksand-600.woff') format('woff'); }
@font-face { font-family: 'Baloo 2'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/baloo-2-700.woff') format('woff'); }
:root {
  color-scheme: light;
  --bg-1: #f9eee8;
  --bg-2: #f3eff7;
  --bg-3: #e9eef8;
  --paper: var(--bg-2);
  --surface: rgba(255,253,255,.7);
  --ink: #3d354d;
  --muted: #685e74;
  --line: rgba(93,72,120,.16);
  --accent: #75608a;
  --wash: #e6dded;
  --note: rgba(241,228,242,.78);
  --note-ink: #665074;
  --rim: rgba(255,255,255,.94);
  --orb-pink: #e9bccd;
  --orb-lav: #c0b2e4;
  --shadow: 0 18px 55px rgba(75,52,108,.065);
  font-family: Quicksand, ui-rounded, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg-1: #252132; --bg-2: #211e30; --bg-3: #20273a;
    --surface: rgba(46,40,63,.83); --ink: #eee8f5; --muted: #bcb2c9;
    --line: rgba(215,197,239,.16); --accent: #c8b3e4; --wash: #3a304c;
    --note: rgba(66,48,76,.8); --note-ink: #d6c5e7;
    --rim: rgba(237,222,255,.18); --orb-pink: #6a435e; --orb-lav: #534374;
    --shadow: 0 18px 55px rgba(8,4,20,.16);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg-1: #252132; --bg-2: #211e30; --bg-3: #20273a;
  --surface: rgba(46,40,63,.83); --ink: #eee8f5; --muted: #bcb2c9;
  --line: rgba(215,197,239,.16); --accent: #c8b3e4; --wash: #3a304c;
  --note: rgba(66,48,76,.8); --note-ink: #d6c5e7;
  --rim: rgba(237,222,255,.18); --orb-pink: #6a435e; --orb-lav: #534374;
  --shadow: 0 18px 55px rgba(8,4,20,.16);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 2rem; }
body { margin: 0; background: var(--paper); color: var(--ink); font-size: 15px; line-height: 1.6; isolation: isolate; min-height: 100svh; }
body::before { content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none; background: radial-gradient(ellipse at 12% 15%, color-mix(in srgb, var(--orb-pink) 32%, transparent), transparent 45%), radial-gradient(ellipse at 90% 20%, color-mix(in srgb, var(--orb-lav) 28%, transparent), transparent 45%), linear-gradient(120deg, var(--bg-1), var(--bg-2) 50%, var(--bg-3)); }
button, input { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button { color: inherit; cursor: pointer; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 4px; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }
::selection { background: var(--wash); color: var(--ink); }
[hidden] { display: none !important; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.site-wrap { max-width: 1232px; margin: auto; padding: 0 56px; }
.site-header { min-height: 76px; display: flex; align-items: center; gap: 25px; padding: 0 25px; margin-top: 24px; background: var(--surface); border: 1px solid var(--rim); border-radius: 26px; box-shadow: var(--shadow), inset 0 1px 0 var(--rim); backdrop-filter: blur(24px) saturate(125%); -webkit-backdrop-filter: blur(24px) saturate(125%); }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 21px; font-weight: 600; letter-spacing: -.7px; text-decoration: none; white-space: nowrap; min-height: 44px; }
.brand strong { font-weight: 550; }
.brand-mark { width: 34px; height: 34px; color: var(--accent); }
.brand-mark path { stroke: currentColor; stroke-width: 1.2; }
.brand-mark circle { fill: currentColor; }
.brand-dot { color: var(--accent); }
.site-header nav { display: flex; align-items: center; gap: 28px; margin-left: auto; font-size: 13px; }
.site-header nav a { color: var(--muted); text-decoration: none; padding: 10px 12px; border-radius: 20px; min-height: 44px; font-weight: 600; }
.site-header nav a:hover, .site-header nav a[aria-current] { color: var(--ink); }
.site-header nav a[aria-current] { background: var(--wash); color: var(--accent); }
.theme-toggle { padding: 7px 12px; border: 1px solid var(--line); background: transparent; border-radius: 20px; min-width: 92px; min-height: 44px; font-size: 12px; }
.theme-toggle:hover { background: var(--wash); }
.skip-link { position: fixed; top: 10px; left: 10px; transform: translateY(-200%); z-index: 10; background: var(--ink); color: var(--paper); padding: 10px 18px; }
.skip-link:focus { transform: none; }
.hero { display: grid; grid-template-columns: 1.6fr 1fr; gap: 70px; align-items: center; padding: 76px 0 80px; }
.eyebrow { font-family: "SFMono-Regular", Consolas, monospace; font-size: 10px; letter-spacing: 1.4px; font-weight: 500; line-height: 1.8; color: var(--muted); margin: 0 0 23px; }
.tiny-star { font-size: 14px; margin-right: 8px; color: var(--accent); vertical-align: -1px; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-family: 'Baloo 2', ui-rounded, sans-serif; font-size: clamp(44px, 5.3vw, 66px); font-weight: 700; line-height: 1.09; letter-spacing: -1.8px; margin-bottom: 25px; text-wrap: balance; }
h1 em { color: var(--accent); font-weight: inherit; font-style: normal; letter-spacing: inherit; }
.hero-description { color: var(--muted); font-size: 15px; line-height: 1.8; margin-bottom: 25px; }
.text-link { display: inline-flex; align-items: center; gap: 22px; font-size: 12px; font-weight: 550; text-decoration: none; padding: 5px 0; border-bottom: 1px solid var(--line); }
.text-link:hover { border-bottom-color: var(--accent); }
.text-link span { font-size: 16px; }
.lab-note { position: relative; background: var(--note); padding: 26px 28px 22px; color: var(--note-ink); border: 1px solid var(--rim); border-radius: 30px; transform: rotate(2deg); box-shadow: var(--shadow), inset 0 1px 0 var(--rim); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.note-top { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid color-mix(in srgb, var(--note-ink) 18%, transparent); padding-bottom: 15px; margin-bottom: 24px; }
.note-top .eyebrow { margin: 0; color: inherit; font-size: 9px; }
.note-top > span:last-child { font-size: 24px; line-height: 1; }
.lab-note > p { font-family: 'Baloo 2', ui-rounded, sans-serif; font-size: 30px; font-weight: 700; line-height: 1.2; letter-spacing: -.8px; margin-bottom: 27px; }
.collection-stats { display: flex; gap: 32px; margin: 0 0 23px; }
.collection-stats div { display: flex; flex-direction: column; gap: 0; }
.collection-stats dd { order: 0; margin: 0; font-size: 27px; letter-spacing: -1px; line-height: 1.2; }
.collection-stats dt { order: 1; font-size: 10px; margin-top: 6px; }
.note-caption { display: block; font-size: 10px; border-top: 1px solid color-mix(in srgb, var(--note-ink) 18%, transparent); padding-top: 13px; }
.catalogue { border-top: 1px solid var(--line); padding-top: 33px; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.section-heading .eyebrow { margin-bottom: 6px; font-size: 9px; }
h2 { font-family: 'Baloo 2', ui-rounded, sans-serif; font-size: 31px; line-height: 1.3; letter-spacing: -.7px; font-weight: 700; margin-bottom: 0; }
.accent-dot { color: var(--accent); }
.section-heading > p { font-size: 12px; color: var(--muted); margin: 0 0 4px; }
.catalogue-controls { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin: 0 0 30px; }
.category-filters { display: flex; flex-wrap: wrap; gap: 5px; }
.category-filters button { background: transparent; border: 1px solid transparent; border-radius: 20px; padding: 8px 13px; min-height: 44px; font-size: 12px; font-weight: 600; color: var(--muted); }
.category-filters button[aria-pressed="true"] { background: var(--wash); color: var(--accent); border-color: var(--line); }
.category-filters button:hover { color: var(--ink); }
.search-field { display: flex; gap: 8px; align-items: center; border-bottom: 1px solid var(--line); min-width: 180px; }
.search-field > span { font-size: 24px; color: var(--muted); }
.search-field input { width: 185px; min-width: 0; padding: 8px 0; background: transparent; border: 0; color: var(--ink); font-size: 12px; border-radius: 0; }
.search-field input::placeholder { color: var(--muted); opacity: 1; }
.catalogue-meta { display: flex; justify-content: space-between; color: var(--muted); font-family: "SFMono-Regular", Consolas, monospace; font-size: 9px; letter-spacing: .8px; margin-bottom: 12px; }
.experiment-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.experiment-card { --category-accent: var(--accent); position: relative; min-height: 252px; padding: 25px 27px 19px; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--rim); border-radius: 28px; box-shadow: var(--shadow), inset 0 1px 0 var(--rim); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); transition: border-color .2s, box-shadow .2s; }
.experiment-card:hover, .experiment-card:focus-within { border-color: var(--accent); box-shadow: var(--shadow); }
.category-simulation { --category-accent: #8a6d47; }
.category-systems { --category-accent: #817296; }
.category-tools { --category-accent: #4d7d86; }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.category-label { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; }
.category-dot { display: inline-block; background: var(--category-accent); width: 6px; height: 6px; border-radius: 2px; }
.status-badge { font-family: "SFMono-Regular", Consolas, monospace; font-size: 9px; border: 1px solid var(--line); padding: 2px 7px; border-radius: 4px; color: var(--muted); }
.card-body { flex: 1; padding: 25px 53px 19px 0; }
.card-number { position: absolute; top: 78px; right: 27px; font: 700 43px/1 'Baloo 2', ui-rounded, sans-serif; letter-spacing: -2px; color: var(--line); }
.card-body h3 { font-family: 'Baloo 2', ui-rounded, sans-serif; font-size: 27px; line-height: 1.25; font-weight: 700; letter-spacing: -.5px; margin-bottom: 9px; }
.card-body h3 a { text-decoration: none; }
.card-body h3 a::after { position: absolute; inset: 0; content: ""; z-index: 1; }
.card-body p { font-size: 12px; color: var(--muted); line-height: 1.7; margin: 0; max-width: 310px; }
.card-bottom { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 10px; color: var(--muted); font-size: 10px; }
.card-arrow { font-size: 18px; color: var(--accent); }
.empty-results { padding: 50px 20px; text-align: center; background: var(--surface); border: 1px dashed var(--line); border-radius: 10px; }
.empty-results h3 { font-weight: 500; margin-bottom: 5px; }
.empty-results p { color: var(--muted); font-size: 13px; }
.text-button { background: transparent; border: 0; border-bottom: 1px solid var(--line); padding: 8px; font-size: 13px; }
.collection-footnote { display: flex; align-items: center; gap: 16px; padding: 28px 0 45px; }
.collection-footnote > span { font-family: Georgia, serif; font-size: 30px; color: var(--accent); align-self: flex-start; }
.collection-footnote p { margin: 0; font-size: 12px; }
.collection-footnote p span { color: var(--muted); font-size: 11px; }
.collection-footnote > a { margin-left: auto; white-space: nowrap; }
.site-footer { display: flex; justify-content: space-between; align-items: center; gap: 24px; border-top: 1px solid var(--line); padding: 25px 0 31px; font-size: 10px; color: var(--muted); }
.site-footer a { text-decoration: none; }
.footer-brand { font-size: 12px; color: var(--ink); }
.footer-brand span { margin-left: 8px; color: var(--accent); }
.page-intro { max-width: 780px; padding: 65px 0 45px; }
.page-intro .eyebrow { margin-bottom: 20px; }
.page-intro h1 { margin-bottom: 25px; }
.page-lead { max-width: 660px; color: var(--muted); font-size: 18px; line-height: 1.8; }
.back-link { display: inline-block; color: var(--muted); font-size: 12px; text-decoration: none; margin-bottom: 45px; }
.concept-layout { display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; padding: 0 0 80px; }
.concept-note { padding: 28px; background: var(--note); color: var(--note-ink); border-radius: 28px; border: 1px solid var(--rim); box-shadow: var(--shadow); align-self: start; }
.concept-note .eyebrow { color: inherit; }
.concept-note h2 { font-size: 26px; margin: 0 0 15px; }
.concept-note p { font-size: 13px; }
.concept-note p:last-child { margin-bottom: 0; }
.scope-notes h2 { font-size: 21px; letter-spacing: -.5px; }
.scope-notes ol { padding-left: 22px; color: var(--muted); margin: 22px 0; }
.scope-notes li { padding-left: 8px; margin-bottom: 18px; font-size: 14px; }
.about-sections { max-width: 800px; margin-bottom: 80px; }
.about-sections section { display: grid; grid-template-columns: 45px 1fr; gap: 22px; padding: 30px 0; border-top: 1px solid var(--line); }
.section-index { font-family: "SFMono-Regular", Consolas, monospace; font-size: 12px; color: var(--muted); padding-top: 5px; }
.about-sections h2 { font-size: 24px; letter-spacing: -.6px; margin-bottom: 14px; }
.about-sections p { font-size: 15px; color: var(--muted); max-width: 630px; }
.not-found { min-height: 65vh; }
.experiment-workspace { border: 1px solid var(--rim); border-radius: 28px; background: var(--surface); overflow: hidden; }
.experiment-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; padding: 15px 20px; border-bottom: 1px solid var(--line); }
.experiment-toolbar button { border: 1px solid var(--line); background: var(--wash); border-radius: 6px; min-height: 44px; padding: 8px 16px; }
.experiment-toolbar p { font-size: 12px; color: var(--muted); margin: 0; }
#experiment-stage { position: relative; min-height: 360px; isolation: isolate; }
.experiment-notes { padding: 30px 0 60px; }
.experiment-notes h2 { font-size: 24px; }
.experiment-notes li { color: var(--muted); font-size: 14px; margin-bottom: 12px; }
@media (max-width: 1000px) {
  .site-wrap { padding: 0 32px; }
  .hero { gap: 35px; grid-template-columns: 1.4fr 1fr; }
  h1 { font-size: 53px; }
  .lab-note { padding: 22px; }
  .collection-stats { gap: 24px; }
  .site-header { gap: 20px; }
  .site-header nav { gap: 6px; }
  .category-filters button { padding: 8px 9px; }
}
@media (max-width: 720px) {
  .site-wrap { padding: 0 22px; }
  .site-header { min-height: 88px; gap: 10px; flex-wrap: wrap; padding: 15px 18px 10px; margin-top: 16px; border-radius: 26px; }
  .brand { font-size: 20px; }
  .brand-mark { width: 28px; height: 28px; }
  .site-header nav { order: 3; width: 100%; justify-content: space-between; margin: 2px 0 0; gap: 3px; font-size: 12px; }
  .site-header nav a { padding: 10px 9px; }
  .theme-toggle { margin-left: auto; }
  .hero { grid-template-columns: 1fr; gap: 34px; padding: 46px 0 45px; }
  h1 { font-size: clamp(39px, 8.6vw, 58px); letter-spacing: -2px; }
  h1 em { letter-spacing: -1.8px; }
  .hero-copy .eyebrow { font-size: 9px; margin-bottom: 21px; }
  .hero-description { font-size: 14px; }
  .lab-note { transform: none; max-width: none; padding: 20px 23px; }
  .note-top { padding-bottom: 10px; margin-bottom: 15px; }
  .lab-note > p { font-size: 26px; margin-bottom: 20px; }
  .collection-stats { gap: 40px; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 10px; margin-bottom: 20px; }
  .section-heading h2 { font-size: 30px; }
  .catalogue-controls { align-items: stretch; flex-direction: column; gap: 15px; margin-bottom: 23px; }
  .category-filters { gap: 3px; }
  .category-filters button { padding: 7px 10px; min-height: 44px; }
  .search-field input { width: 100%; min-height: 44px; font-size: 16px; }
  .experiment-grid { grid-template-columns: 1fr; gap: 14px; }
  .experiment-card { min-height: 234px; padding: 20px 22px 14px; }
  .card-body { padding-top: 23px; }
  .card-body h3 { font-size: 25px; }
  .collection-footnote { flex-wrap: wrap; gap: 12px; padding-bottom: 30px; }
  .collection-footnote > a { margin-left: 29px; }
  .collection-footnote p { flex: 1; }
  .site-footer { flex-wrap: wrap; gap: 12px; }
  .site-footer > span { order: 3; width: 100%; }
  .page-intro { padding: 45px 0 30px; }
  .page-lead { font-size: 16px; }
  .concept-layout { grid-template-columns: 1fr; gap: 32px; padding-bottom: 50px; }
  .about-sections { margin-bottom: 40px; }
  .about-sections section { grid-template-columns: 25px 1fr; gap: 13px; }
  .about-sections h2 { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
@media (forced-colors: active) {
  .category-filters button[aria-pressed="true"] { outline: 2px solid Highlight; }
  .category-dot { border: 2px solid CanvasText; }
}
