/**
 * Fulcrum × Boundless — literary overrides.
 * Boundless skin supplies interaction/a11y patterns; this file keeps
 * the austere black/white book look (no Material loudness).
 */
@import url("../boundless/skin.min.css");
@import url("./tokens-extra.css");

/* Soften Boundless global box-sizing clash — already set in book.css */
.cover-page .b-button,
.intro-page .b-button,
.btn.b-button {
  font-family: var(--font-sans, system-ui, sans-serif);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  border-radius: var(--fulcrum-radius, 2px);
  padding: 0.7rem 1.25rem;
  line-height: 1.2;
  white-space: normal;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease,
    box-shadow 0.15s ease;
}

/* Primary = filled ink (Boundless default is already near-black) */
.b-button,
.btn.b-button.btn-primary,
.b-button.btn-primary {
  background: var(--fulcrum-ink, #1a1a1a);
  border: 1px solid var(--fulcrum-ink, #1a1a1a);
  color: var(--fulcrum-paper, #faf9f6);
}
.b-button:hover,
.b-button:focus,
.btn.b-button.btn-primary:hover,
.btn.b-button.btn-primary:focus {
  background: transparent;
  color: var(--fulcrum-ink, #1a1a1a);
  border-color: var(--fulcrum-ink, #1a1a1a);
  outline: none;
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--fulcrum-focus, #2c5f8a) 35%, transparent);
}

/* Ghost / secondary */
.b-button.b-button-ghost,
.btn.b-button.btn-ghost,
.b-button.btn-ghost {
  background: transparent;
  border: 1px solid var(--fulcrum-ink, #1a1a1a);
  color: var(--fulcrum-ink, #1a1a1a);
}
.b-button.b-button-ghost:hover,
.b-button.b-button-ghost:focus,
.btn.b-button.btn-ghost:hover,
.btn.b-button.btn-ghost:focus {
  background: var(--fulcrum-ink, #1a1a1a);
  color: var(--fulcrum-paper, #faf9f6);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--fulcrum-focus, #2c5f8a) 35%, transparent);
}

/* Strong ghost — Introduction when not primary */
.btn.b-button.btn-strong-ghost {
  background: transparent;
  border: 1.5px solid var(--fulcrum-ink, #1a1a1a);
  color: var(--fulcrum-ink, #1a1a1a);
  font-weight: 600;
}
.btn.b-button.btn-strong-ghost:hover,
.btn.b-button.btn-strong-ghost:focus {
  background: var(--fulcrum-ink, #1a1a1a);
  color: var(--fulcrum-paper, #faf9f6);
}

/* Boundless + spacing: cancel default adjacent margin in flex wraps */
.cover-actions .b-button + .b-button,
.intro-actions .b-button + .b-button {
  margin-left: 0;
}

/* Progressive disclosure — cover secondary links */
.cover-more.b-disclosure,
.cover-more {
  width: 100%;
  max-width: var(--fulcrum-cover-actions-max, 28rem);
  margin: 0.25rem auto 0;
  text-align: center;
}
.cover-more .b-disclosure-toggle {
  color: var(--fulcrum-ink-soft, #4a4a4a);
  font-family: var(--font-sans, system-ui, sans-serif);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding-left: 1.1rem;
  background: none;
  border: none;
  cursor: pointer;
}
.cover-more .b-disclosure-toggle::before {
  border-left-color: var(--fulcrum-ink-soft, #4a4a4a);
}
.cover-more.b-disclosure-expanded .b-disclosure-toggle::before,
.cover-more.is-expanded .b-disclosure-toggle::before {
  border-top-color: var(--fulcrum-ink-soft, #4a4a4a);
  border-left-color: transparent;
}
.cover-more .b-disclosure-content,
.cover-more .cover-more-panel {
  display: none;
  margin-top: 0.85rem;
}
.cover-more.b-disclosure-expanded .b-disclosure-content,
.cover-more.is-expanded .cover-more-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}

/* Cover action rows */
.cover-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  max-width: var(--fulcrum-cover-actions-max, 28rem);
}
.cover-actions-primary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  width: 100%;
}
.cover-actions .b-button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.cover-actions-secondary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  width: 100%;
}

/* Intro chrome: Boundless-like focus on transport */
.intro-chrome button:focus-visible,
.intro-actions .btn:focus-visible {
  outline: 2px solid var(--fulcrum-focus, #2c5f8a);
  outline-offset: 2px;
}

/* Guide download chip on intro end */
.intro-download-note {
  margin-top: 1.25rem;
  font-family: var(--font-sans, system-ui, sans-serif);
  font-size: 0.8rem;
  color: var(--ink-muted, #4a4a4a);
}
.intro-download-note a {
  color: inherit;
  text-underline-offset: 0.15em;
}
