@font-face {
  font-family: "Kardust TS Condensed";
  src: url("/assets/fonts/Kardust%20TS%20Condensed%20Bold%20Italic.ttf") format("truetype");
  font-style: italic;
  font-weight: 700;
  font-display: swap;
}
.site-layout .theme-toggle { display: none; }
.site-layout {
  --rail: 188px;
  --home-bg: var(--bg);
  --home-rail: var(--surface);
  --home-card: var(--surface-2);
  --home-line: var(--line);
  --home-text: var(--text);
  --home-soft: var(--soft);
  --home-muted: var(--muted);
  --home-accent: var(--purple-soft);
  --home-link: var(--yellow);
  background: var(--home-bg);
  color: var(--home-text);
}
html[data-theme="light"] .site-layout { --home-link: #976700; }
.site-layout .home-shell { position: relative; }
.site-layout .home-sidebar { top: 0; bottom: 0; display: flex; flex-direction: column; width: var(--rail); overflow-y: auto; border-color: var(--home-line); background: var(--home-rail); }
.home-brand { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 0 0 166px; padding: 16px 10px; border-bottom: 1px solid var(--home-line); text-align: center; text-decoration: none; }
.home-brand-monogram { display: grid; place-items: center; width: 66px; height: 66px; margin-bottom: 9px; border: 2px solid var(--purple); border-radius: 50%; background: color-mix(in srgb, var(--purple) 18%, var(--home-card)); color: var(--home-accent); font-size: 1.45rem; font-weight: 850; letter-spacing: -.08em; box-shadow: 0 0 0 5px color-mix(in srgb, var(--purple) 12%, transparent); }
.home-brand-monogram img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.home-brand strong { color: var(--home-text); font-size: .88rem; line-height: 1.25; }
.home-brand small { margin-top: 4px; color: var(--home-muted); font-size: .64rem; line-height: 1.35; }
.site-layout .home-sidebar nav { display: grid; gap: 3px; padding: 14px 8px; }
.site-layout .home-sidebar nav a { min-height: 42px; gap: 11px; padding: 0 12px; border-left-width: 2px; border-radius: 4px; color: var(--home-muted); font-size: .77rem; font-weight: 600; }
.site-layout .home-sidebar nav a .icon { width: 18px; height: 18px; padding: 0; border-radius: 0; background: none; color: inherit; }
.site-layout .home-sidebar nav a:hover, .site-layout .home-sidebar nav a[aria-current="page"] { border-left-color: var(--home-link); background: color-mix(in srgb, var(--home-link) 10%, var(--home-card)); color: var(--home-link); }
.site-layout .home-sidebar nav a:hover .icon, .site-layout .home-sidebar nav a[aria-current="page"] .icon { background: none; color: inherit; }
.home-sidebar-bottom { display: grid; gap: 7px; margin-top: auto; padding: 17px 16px 15px; border-top: 1px solid var(--home-line); }
.home-sidebar-bottom p { margin: 0 0 3px; color: var(--home-muted); font-size: .58rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.home-sidebar-bottom a { display: flex; justify-content: space-between; color: var(--home-soft); font-size: .7rem; text-decoration: none; }
.home-sidebar-bottom a:hover, .home-sidebar-bottom a span { color: var(--home-accent); }
.home-sidebar-bottom small { margin-top: 9px; color: var(--home-muted); font-size: .6rem; }
.home-mobilebar { position: absolute; top: 29px; right: 44px; z-index: 5; }
.home-mobile-brand, .site-layout .home-mobilebar .menu-toggle { display: none; }
.home-mobilebar .theme-toggle { border: 1px solid rgba(204,205,224,.25); background: rgba(10,14,23,.72); color: #fff; }

/* Inner pages use a compact theme bar above their content. */
.site-layout:not(.home-page) .home-mobilebar { position: relative; top: auto; right: auto; display: flex; justify-content: flex-end; margin-left: var(--rail); padding: 12px clamp(24px, 3.2vw, 54px) 0; }
.site-layout:not(.home-page) .home-mobilebar .theme-toggle { border-color: var(--home-line); background: var(--home-card); color: var(--home-text); }
@media (max-width: 1050px) {
  .site-layout { --rail: 0px; }
  .home-mobilebar { position: sticky; top: 0; right: auto; z-index: 70; display: flex; align-items: center; gap: 10px; height: 66px; padding: 0 16px; border-bottom: 1px solid var(--home-line); background: var(--home-rail); }
  .home-mobile-brand { display: flex; align-items: center; text-decoration: none; }
  .home-mobile-brand strong { color: #fff; font-family: "Kardust TS Condensed", sans-serif; font-size: clamp(20px, 4.2vw, 25px); font-style: italic; font-weight: 700; letter-spacing: -.02em; line-height: 1; white-space: nowrap; }
  .site-layout .home-mobilebar .menu-toggle { display: block; margin-left: auto; }
  .home-mobilebar .theme-toggle { border-color: var(--home-line); background: var(--home-card); color: var(--home-text); }
  .site-layout .home-sidebar { position: static; display: block; width: 0; height: 0; overflow: visible; border: 0; background: none; }
  .site-layout .home-brand, .site-layout .home-sidebar-bottom { display: none; }
  .site-layout .home-sidebar nav { position: fixed; top: 72px; right: 12px; left: 12px; z-index: 65; display: none; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; width: auto; max-height: calc(100dvh - 84px); overflow: auto; padding: 12px; border: 1px solid var(--home-line); border-radius: 8px; background: var(--home-rail); box-shadow: 0 20px 50px rgba(2,6,14,.55); }
  .site-layout .home-sidebar nav.is-open { display: grid; }
  .site-layout:not(.home-page) .home-mobilebar { position: sticky; top: 0; justify-content: flex-start; margin-left: 0; padding: 0 16px; }
}
@media (max-width: 680px) {
  .home-mobilebar .theme-sun { display: none; }
}
