/* ============ FlipStack FAQ (dark) ============ */
/* Uses tokens from /apps/flipstack/flipstack.css */

:root { --faq-maxw: 860px; }
html { scroll-behavior: smooth; }


/* Base */
body.flipstack-faq {
  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(52,152,219,.25), transparent),
    linear-gradient(180deg, #0f1222 0%, #0b0e1a 100%);
  line-height: 1.6;
  margin: 0;
}

/* Constrain page like the site’s .container but keep the FAQ’s centered doc look */
.faq-wrap {
  max-width: var(--faq-maxw);
  margin: 40px auto;
  padding: 0 20px 60px;
}

/* Top nav */
.faq-wrap nav {
  margin-bottom: 16px;
  font-size: .95rem;
}
.faq-wrap nav a {
  color: var(--flip-accent);
  text-decoration: none;
}
.faq-wrap nav a:hover { text-decoration: underline; }

/* Headings */
.faq-wrap h1 {
  margin: 8px 0 20px;
  color: var(--flip-white);
}
.faq-wrap h2 { opacity: .98; letter-spacing: .1px; }
.faq-wrap .updated {
  color: var(--text-dim);
  font-size: .9rem; margin-top: -6px;
}

/* TOC panel (dark glass) */
.toc {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  padding: 16px;
  margin: 12px 0 24px;
}
.toc a { text-decoration: none; color: var(--flip-accent); }
.toc a:hover { text-decoration: underline; }

/* Section spacing */
.faq-section { margin: 18px 0 28px; }

/* Reveal items (details/summary) */
details {
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 12px;
  padding: 12px 14px;
  background: rgba(255,255,255,0.04);
  margin: 10px 0;
}
details[open] { background: rgba(255,255,255,0.06); }

summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  outline: none;
  color: var(--flip-white);
}
summary::-webkit-details-marker { display: none; }

/* Answers */
.answer {
  margin-top: 10px;
  color: var(--text-dim);
  line-height: 1.5;
}

/* Inline code/kbd on dark */
code, kbd {
  background: rgba(255,255,255,0.10);
  color: var(--flip-white);
  padding: 2px 6px;
  border-radius: 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .95em;
}

/* Footnote/footer area inside the doc */
.foot {
  border-top: 1px solid rgba(255,255,255,0.12);
  margin-top: 40px; padding-top: 18px;
  font-size: .95rem;
  color: var(--text-dim);
}

/* Links in body */
.faq-wrap a { color: var(--flip-accent); }
.faq-wrap a:hover { text-decoration: underline; }

/* Style kbd tags inside FAQ answers */
.answer kbd {
  background: rgba(255,255,255,0.12); /* subtle glassy panel */
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  padding: 2px 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.85em;
  font-weight: 500;
  color: var(--flip-white);
  box-shadow: inset 0 -1px 0 rgba(0,0,0,0.25);
}

/* On hover/focus, brighten a little */
.answer kbd:hover {
  background: rgba(255,255,255,0.18);
}


/* Back to top */
#backToTop {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: var(--flip-accent);
  color: #000;
  padding: .6rem .9rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 500;
  text-decoration: none;
  box-shadow: 0 6px 16px rgba(0,0,0,.25);
  display: none; /* hidden by default */
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  transform: translateY(20px);
}
#backToTop:hover { background: var(--flip-secondary); }

body.scrolled #backToTop { display: inline-block;opacity: 1;transform: translateY(0); }



/* Optional: reuse the landing footer at the bottom of the page */
.site-footer {
  margin-top: 3rem;
  padding: 2.5rem 1.5rem;
  background: rgba(255,255,255,0.05);
  border-top: 1px solid rgba(255,255,255,0.12);
  border-radius: 16px 16px 0 0;
  color: var(--text-dim);
}
.footer-inner {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 2rem;
  max-width: 1100px; margin: 0 auto;
}
.footer-brand h3 { margin: 0 0 .25rem; font-size: 1.25rem; color: var(--flip-white); }
.footer-brand .tagline { margin: 0 0 .75rem; font-size: 0.9rem; color: var(--text-dim); }
.footer-brand .byline { font-size: 0.85rem; color: var(--text-dim); }
.footer-brand .byline a { color: var(--flip-accent); text-decoration: none; font-weight: 500; }
.footer-brand .byline a:hover { text-decoration: underline; }
.footer-nav ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .4rem; }
.footer-nav a { color: var(--text); text-decoration: none; font-size: .9rem; }
.footer-nav a:hover { color: var(--flip-accent); }

@media (max-width: 720px) {
  .footer-inner { flex-direction: column; text-align: center; align-items: center; }
  .footer-nav ul { grid-template-columns: repeat(2, auto); gap: .6rem 1.2rem; }
}
