/* Shared website toolbar. Routes and active states come from partials/header.html. */
body.is-menu-open { overflow: hidden; }
.site-header, .site-header.is-scrolled {
  position: fixed; inset: 0 0 auto; z-index: 100; height: var(--header-height);
  overflow: visible; background: transparent; border: 0; box-shadow: none;
  backdrop-filter: none; -webkit-backdrop-filter: none; pointer-events: none;
}
.site-header::before { content: none; }
.site-header .site-header-inner {
  position: relative; z-index: 1; display: flex; align-items: center; justify-content: center;
  width: max-content; max-width: calc(100% - (var(--page-gutter) * 2)); height: var(--nav-bar-height);
  gap: 0; margin: var(--nav-top) auto 0; padding: 5px; box-sizing: border-box;
  border: 1px solid var(--card-border); border-radius: var(--radius-pill);
  background: color-mix(in srgb, var(--card) 88%, transparent);
  box-shadow: var(--floating-shadow); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  pointer-events: auto; transition: background var(--ui-duration) ease;
}
.site-header.is-scrolled .site-header-inner { background: color-mix(in srgb, var(--card) 94%, transparent); }
.site-header .site-logo {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  /* A persistent brand circle gives the mark its own visual boundary. */
  width: var(--nav-control-height); height: var(--nav-control-height); padding: 0; margin-right: 4px;
  box-sizing: border-box; border: 0; border-radius: var(--radius-round);
  background: var(--brand-blue); color: #fff; text-decoration: none;
  transition: background var(--ui-duration) ease;
}
.site-header .site-logo:hover { background: var(--brand-blue-hover); }
.site-header .site-logo:active { background: #89a6c4; }
.site-header .site-logo-mark {
  display: block; flex: none; width: 20px; height: 20px; background: currentColor; transform: none;
  -webkit-mask: url('../assets/shared/brand/jimin-mark.png') center / contain no-repeat;
  mask: url('../assets/shared/brand/jimin-mark.png') center / contain no-repeat;
}
.site-header .site-nav {
  position: static; display: flex; align-items: center; gap: 2px; height: auto; padding: 0;
  background: transparent; border: 0; box-shadow: none; transform: none; backdrop-filter: none;
}
.site-header .site-nav a, .site-header .site-nav-start, .site-mobile-nav > a {
  display: inline-flex; align-items: center; justify-content: center; min-height: var(--nav-control-height);
  padding: 0 12px; border: 0; border-radius: var(--radius-pill); background: transparent;
  color: var(--ink-soft); font: 700 14px/20px var(--font-ui); letter-spacing: 0;
  text-decoration: none; white-space: nowrap; transform: none; box-shadow: none;
  transition: color var(--ui-duration) ease, background var(--ui-duration) ease;
}
.site-header .site-nav a::after { content: none; }
.site-header .site-nav a:hover, .site-mobile-nav > a:hover {
  color: var(--ink); background: color-mix(in srgb, var(--brand-blue) 12%, transparent); transform: none; box-shadow: none;
}
.site-header a[aria-current="page"] { color: var(--ink); background: color-mix(in srgb, var(--brand-blue) 20%, var(--card)); }
.site-header .site-header-actions { position: static; display: flex; align-items: center; gap: 4px; padding: 0; margin: 0 0 0 4px; border: 0; background: none; box-shadow: none; }
.site-header .site-nav-start { background: var(--brand-blue); color: #fff; padding-inline: 16px; font-size: 16px; }
.site-header .site-nav-start:hover { background: #a5bcd3; color: #fff; box-shadow: none; transform: none; }
.site-header .site-nav-start:active { background: #89a6c4; }
.site-header .theme-toggle, .site-header .site-menu-btn {
  display: inline-flex; align-items: center; justify-content: center; position: relative;
  width: 44px; min-width: 44px; height: var(--nav-control-height); min-height: var(--nav-control-height);
  padding: 0; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--ink);
  box-shadow: none; cursor: pointer; transform: none;
}
.site-header .theme-toggle {
  width: var(--nav-control-height); min-width: var(--nav-control-height);
  flex: none; border-radius: var(--radius-round);
  transition: background var(--ui-duration) ease, color var(--ui-duration) ease;
}
.site-header .site-menu-btn:hover { background: color-mix(in srgb, var(--ink) 5%, transparent); }
@media (hover: hover) {
  .site-header .theme-toggle:hover { background: color-mix(in srgb, var(--brand-blue) 12%, transparent); }
}
.site-header .theme-toggle:active { background: color-mix(in srgb, var(--brand-blue) 22%, transparent); }
.site-header .theme-toggle::before, .site-header .theme-toggle::after { content: none; }
/* Show the next available theme; the accessible label names the same action. */
.site-header .theme-icon {
  display: block; flex: none; width: 20px; height: 20px; background: currentColor;
  -webkit-mask: url('../assets/shared/icons/theme/moon.svg') center / contain no-repeat;
  mask: url('../assets/shared/icons/theme/moon.svg') center / contain no-repeat;
}
[data-theme="dark"] .site-header .theme-icon {
  -webkit-mask-image: url('../assets/shared/icons/theme/sun.svg');
  mask-image: url('../assets/shared/icons/theme/sun.svg');
}
.site-header .site-menu-btn { display: none; }
.site-header .menu-icon { position: static; transform: none; }
.site-header .menu-icon--close { display: none; }
.site-header .site-menu-btn[aria-expanded="true"] .menu-icon--menu { display: none; }
.site-header .site-menu-btn[aria-expanded="true"] .menu-icon--close { display: block; }
.site-header .site-mobile-nav { display: none; }
.site-header :is(a, button):focus-visible { outline: 2px solid #448ac7; outline-offset: 2px; }
@media (max-width: 767px) {
  .site-header .site-header-inner { width: calc(100% - (var(--page-gutter) * 2)); max-width: 520px; justify-content: space-between; }
  .site-header .site-nav { display: none; }
  .site-header .site-header-actions > .site-nav-start { display: none; }
  .site-header .site-menu-btn { display: inline-flex; }
  .site-header .site-mobile-nav:not([hidden]) {
    display: flex; flex-direction: column; gap: 4px; pointer-events: auto;
    width: calc(100% - (var(--page-gutter) * 2)); max-width: 520px; margin: 8px auto 0; padding: 8px;
    max-height: calc(100dvh - var(--header-height) - 16px); overflow-y: auto;
    border: 1px solid var(--card-border); border-radius: var(--radius-panel);
    background: color-mix(in srgb, var(--card) 96%, transparent); box-shadow: var(--floating-shadow);
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  }
  .site-mobile-nav > a { min-height: 44px; justify-content: flex-start; padding-inline: 16px; }
}
@media (prefers-reduced-motion: reduce) { .site-header *, .site-header *::before { transition: none; } }
