/* ==========================================================================
   Component · Button
   ========================================================================== */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color var(--duration-fast) var(--ease-gentle),
    transform var(--duration-fast) var(--ease-spring);
}

.button:active {
  transform: scale(0.97);
}

/* White pill on dark — nav CTA */
.button--primary {
  height: 44px;
  padding-inline: 22px;
  background: var(--color-fill-inverse);
  color: var(--color-text-inverse);
}

.button--primary:hover {
  background: var(--color-fill-inverse-hover);
  transform: scale(1.03);
}

/* ---- Theme toggle — circular icon button --------------------------------- */

.theme-toggle {
  width: 44px;
  height: 44px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--color-hairline);
  color: var(--color-text-primary);
  transition:
    background-color var(--duration-fast) var(--ease-gentle),
    border-color var(--duration-fast) var(--ease-gentle),
    color var(--duration-theme) var(--ease-gentle),
    transform var(--duration-fast) var(--ease-spring);
}

.theme-toggle:hover {
  background: var(--color-tile-hover);
  border-color: var(--color-border-strong);
}

.theme-toggle svg {
  width: 18px;
  height: 18px;
}

/* Sun shown in dark mode (tap → light); moon shown in light mode */
.theme-toggle__moon { display: none; }

:root[data-theme="light"] .theme-toggle__sun  { display: none; }
:root[data-theme="light"] .theme-toggle__moon { display: block; }
