/* ============================================================
   Claude theme · navigation chrome for the css II motion files
   css II animates #th (top rail pill), #ind (left rail bar) and
   .sgw (header stretch). Those files own the transitions; this
   file only supplies the surrounding DOM contract: the track,
   the label z-order and the resting state.
   ============================================================ */

/* ---------- top rail ---------- */
.nav-rail {
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 23px;
  background: var(--neu-bg);
  box-shadow:
    inset 3px 3px 7px var(--neu-shadow-dark),
    inset -3px -3px 7px var(--neu-shadow-light);
}

.nav-rail .rail-item {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 38px;
  padding: 0 15px;
  border: 0;
  border-radius: 19px;
  background: transparent;
  color: var(--c-ink-3);
  font-family: var(--c-font-label);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0;
  text-decoration: none;
  cursor: pointer;
  transition: color 0.28s var(--ou);
}

.nav-rail .rail-item:hover {
  color: var(--c-ink);
}

.nav-rail .rail-item.on {
  color: var(--c-ink);
}

.nav-rail .rail-item[data-accent] {
  color: var(--c-clay);
}

/* ---------- left rail ---------- */
.rail-list {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 4px;
  border-radius: 20px;
  background: var(--neu-bg);
  box-shadow:
    inset 4px 4px 9px var(--neu-shadow-dark),
    inset -4px -4px 9px var(--neu-shadow-light);
}

.rail-list > * {
  position: relative;
  z-index: 1;
}

.rail-link {
  display: block;
  width: 100%;
  padding: 9px 14px;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: var(--c-ink-3);
  font-family: inherit;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: color 0.26s var(--ou);
}

.rail-link:hover {
  color: var(--c-ink);
}

.rail-link.active {
  color: var(--c-ink);
  font-weight: 600;
}

/* ---------- header stretch (.sgw) ---------- */
.hd {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.sgw > * {
  min-width: 0;
  overflow: hidden;
}

/* The collapsing slot keeps its baseline look while expanded. */
.sgw .doc-title {
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

/* ---------- neumorphic surfaces used by the refactored chrome ---------- */
.neu-raised,
.neu-raised-sm {
  background: var(--neu-bg);
  color: var(--neu-text);
}

.neu-pressed,
.neu-pressed-sm {
  background: var(--neu-bg);
  color: var(--neu-text);
}

/* css II keeps the pill fill neutral; the active page gets a clay edge */
#th[data-current] {
  box-shadow:
    inset 0 1px 0 var(--hl),
    0 4px 14px -6px var(--sh),
    inset 0 0 0 1px var(--c-clay-lt);
}

@media (prefers-reduced-motion: reduce) {
  #ind,
  #th,
  .sgw {
    transition: none !important;
  }

  #th.sq {
    scale: 1;
  }
}

@media (max-width: 640px) {
  .nav-rail {
    gap: 2px;
    padding: 3px;
  }

  .nav-rail .rail-item {
    height: 34px;
    padding: 0 11px;
    font-size: 12px;
  }
}
