/* Flashiibo Pro Gen 3 Documentation Styles (scoped to .fp-doc-page) */

/* Hide default Minima page title when custom hero leads */
.post-header:has(+ .post-content .fp-doc-page),
article.post:has(.fp-doc-page) > .post-header {
  display: none;
}

.fp-doc-page {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: #0f172a;
  line-height: 1.6;
  margin-bottom: 3rem;
}

.fp-doc-page *,
.fp-doc-page *::before,
.fp-doc-page *::after {
  box-sizing: border-box;
}

/* Override custom.css centered table rule inside manual pages */
.fp-doc-page table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
  border: none;
}

.fp-doc-page table th,
.fp-doc-page table td {
  text-align: left !important;
  vertical-align: top;
  padding: 0.72rem 0.9rem;
  border: none;
  border-bottom: 1px solid #e2e8f0;
  font-size: 0.92rem;
}

.fp-doc-page table thead th {
  background: #f8fafc;
  color: #334155;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1.5px solid #cbd5e1;
}

.fp-doc-page table tbody tr:last-child td {
  border-bottom: none;
}

.fp-doc-page table tbody tr:nth-child(even) {
  background: #fafcff;
}

.fp-doc-table-wrap {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow-x: auto;
  background: #ffffff;
  margin: 1rem 0 1.25rem 0;
}

/* Breadcrumb */
.fp-doc-breadcrumb {
  font-size: 0.88rem;
  color: #64748b;
  margin-bottom: 0.9rem;
}

.fp-doc-breadcrumb a {
  color: #2563eb;
  text-decoration: none;
  font-weight: 600;
}

.fp-doc-breadcrumb a:hover {
  text-decoration: underline;
}

/* Hero Banner */
.fp-doc-hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e295b 60%, #172554 100%);
  color: #ffffff;
  border-radius: 20px;
  padding: 2rem 2.2rem;
  margin-bottom: 1.75rem;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
  border: 1px solid rgba(99, 132, 255, 0.24);
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  gap: 2rem;
  align-items: center;
}

.fp-doc-hero--compact {
  grid-template-columns: minmax(0, 1fr);
  padding: 1.65rem 2rem;
  gap: 0.75rem;
}

.fp-doc-hero-copy {
  min-width: 0;
}

.fp-doc-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(56, 189, 248, 0.16);
  border: 1px solid rgba(56, 189, 248, 0.42);
  color: #7dd3fc;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.28rem 0.78rem;
  border-radius: 999px;
  margin-bottom: 0.85rem;
}

.fp-doc-hero h1 {
  font-size: 2.05rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #ffffff;
  margin: 0 0 0.65rem 0;
}

.fp-doc-hero--compact h1 {
  font-size: 1.85rem;
}

.fp-doc-hero p {
  font-size: 1rem;
  line-height: 1.58;
  color: #cbd5e1;
  margin: 0 0 1.15rem 0;
}

.fp-doc-hero--compact p {
  margin-bottom: 0.9rem;
  max-width: 740px;
}

.fp-doc-hero-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1.25rem;
}

.fp-doc-hero-pill {
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #f1f5f9;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.28rem 0.68rem;
  border-radius: 8px;
}

.fp-doc-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  align-items: center;
}

.fp-doc-btn-primary,
.fp-doc-btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  font-size: 0.94rem;
  font-weight: 700;
  padding: 0.72rem 1.25rem;
  border-radius: 11px;
  text-decoration: none !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.fp-doc-btn-primary {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: #ffffff !important;
  border: 1px solid rgba(147, 197, 253, 0.5);
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.35);
}

.fp-doc-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.48);
}

.fp-doc-btn-secondary {
  background: rgba(255, 255, 255, 0.11);
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.26);
}

.fp-doc-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
}

.fp-doc-hero-visual {
  text-align: center;
  min-width: 0;
}

.fp-doc-hero-visual img {
  width: 100%;
  max-width: 280px;
  height: auto;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.42);
}

/* 2-Column Docs Shell */
.fp-doc-layout {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
}

.fp-doc-sidebar {
  position: sticky;
  top: 1.25rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1rem 0.9rem;
}

.fp-doc-sidebar-title {
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #64748b;
  margin: 0 0 0.65rem 0.55rem;
}

.fp-doc-toc {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
}

.fp-doc-toc li {
  margin: 0;
}

.fp-doc-toc a {
  display: block;
  padding: 0.38rem 0.62rem;
  font-size: 0.86rem;
  font-weight: 500;
  color: #475569;
  text-decoration: none;
  border-radius: 8px;
  border-left: 2.5px solid transparent;
  transition: background 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}

.fp-doc-toc a:hover {
  background: #eff6ff;
  color: #1d4ed8;
}

.fp-doc-toc a.is-active {
  background: #eff6ff;
  color: #1d4ed8;
  font-weight: 700;
  border-left-color: #2563eb;
}

.fp-doc-sidebar-cta {
  margin-top: 0.9rem;
  padding-top: 0.85rem;
  border-top: 1px solid #e2e8f0;
}

.fp-doc-sidebar-cta a {
  display: block;
  text-align: center;
  padding: 0.52rem 0.7rem;
  background: #0f172a;
  color: #ffffff !important;
  border-radius: 9px;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none !important;
}

.fp-doc-sidebar-cta a:hover {
  background: #1e293b;
}

/* Mobile Jump Bar */
.fp-doc-mobile-toc {
  display: none;
  flex-wrap: wrap;
  gap: 0.45rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 0.75rem;
  margin-bottom: 1.25rem;
}

.fp-doc-mobile-toc a {
  display: inline-block;
  padding: 0.3rem 0.68rem;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #1e293b;
  text-decoration: none;
}

.fp-doc-mobile-toc a:hover {
  border-color: #3b82f6;
  color: #1d4ed8;
}

/* Main Content Column */
.fp-doc-main {
  min-width: 0;
}

.fp-doc-section {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1.5rem 1.65rem;
  margin-bottom: 1.35rem;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
  scroll-margin-top: 1.25rem;
}

.fp-doc-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid #f1f5f9;
}

.fp-doc-section h2 {
  font-size: 1.38rem;
  font-weight: 800;
  letter-spacing: -0.015em;
  color: #0f172a;
  margin: 0;
  scroll-margin-top: 1.25rem;
}

.fp-doc-section h3 {
  font-size: 1.06rem;
  font-weight: 700;
  color: #0f172a;
  margin: 1.25rem 0 0.5rem 0;
  scroll-margin-top: 1.25rem;
}

.fp-doc-section p {
  margin: 0 0 0.85rem 0;
  color: #334155;
}

.fp-doc-section p:last-child,
.fp-doc-section ul:last-child,
.fp-doc-section ol:last-child {
  margin-bottom: 0;
}

.fp-doc-section ul,
.fp-doc-section ol {
  margin: 0 0 0.95rem 0;
  padding-left: 1.35rem;
  color: #334155;
}

.fp-doc-section li {
  margin-bottom: 0.42rem;
}

.fp-doc-section code {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 5px;
  padding: 0.08rem 0.36rem;
  font-size: 0.86em;
  color: #0f172a;
}

/* Inline "Watch & Try Live" button */
.fp-doc-try-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.9rem 0 0.25rem 0;
}

.fp-doc-try-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8 !important;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 0.34rem 0.78rem;
  border-radius: 999px;
  text-decoration: none !important;
  white-space: nowrap;
  transition: background 0.14s ease, border-color 0.14s ease, transform 0.14s ease;
}

.fp-doc-try-btn:hover {
  background: #dbeafe;
  border-color: #60a5fa;
  transform: translateY(-1px);
}

/* Quick Start 3-Step Strip */
.fp-doc-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.95rem;
  margin-top: 0.75rem;
}

.fp-doc-step-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1rem;
}

.fp-doc-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #2563eb;
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 800;
  margin-bottom: 0.55rem;
}

.fp-doc-step-card h3 {
  font-size: 0.98rem;
  font-weight: 800;
  margin: 0 0 0.3rem 0;
  color: #0f172a;
}

.fp-doc-step-card p {
  font-size: 0.88rem;
  line-height: 1.48;
  color: #475569;
  margin: 0;
}

/* Controls Visual Card + Keycaps */
.fp-doc-controls-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.25fr);
  gap: 1.25rem;
  align-items: start;
  margin: 0.9rem 0 1rem 0;
}

.fp-doc-hw-card {
  background: linear-gradient(160deg, #f8fafc 0%, #eef2f7 100%);
  border: 1px solid #cbd5e1;
  border-radius: 16px;
  padding: 1.15rem;
}

.fp-doc-diamond {
  display: grid;
  grid-template-columns: repeat(3, 62px);
  grid-template-rows: repeat(3, 48px);
  justify-content: center;
  align-items: center;
  gap: 4px 8px;
  margin: 0.4rem auto 0.95rem auto;
}

.fp-doc-keycap {
  width: 62px;
  height: 46px;
  border-radius: 12px;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  box-shadow: 0 3px 0 #cbd5e1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 800;
  color: #1e293b;
  letter-spacing: 0.03em;
}

.fp-doc-keycap span {
  font-size: 0.76rem;
  line-height: 1;
  margin-bottom: 2px;
  color: #2563eb;
}

.fp-doc-keycap--up { grid-column: 2; grid-row: 1; }
.fp-doc-keycap--back { grid-column: 1; grid-row: 2; }
.fp-doc-keycap--ok { grid-column: 3; grid-row: 2; }
.fp-doc-keycap--down { grid-column: 2; grid-row: 3; }

.fp-doc-hw-notes {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
  border-top: 1px solid #dbe3ee;
  padding-top: 0.75rem !important;
  font-size: 0.85rem;
  color: #334155;
}

.fp-doc-hw-notes li {
  margin-bottom: 0.38rem;
}

.fp-kbd {
  display: inline-block;
  padding: 0.08rem 0.42rem;
  font-size: 0.78rem;
  font-family: inherit;
  font-weight: 800;
  color: #0f172a;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  box-shadow: 0 1px 0 #cbd5e1;
  white-space: nowrap;
}

/* Callout Boxes */
.fp-doc-callout {
  border-radius: 12px;
  padding: 0.9rem 1.05rem;
  margin: 1rem 0;
  border: 1px solid #e2e8f0;
  border-left-width: 4px;
  font-size: 0.93rem;
}

.fp-doc-callout-title {
  font-weight: 800;
  font-size: 0.9rem;
  margin: 0 0 0.25rem 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.fp-doc-callout p {
  margin: 0;
  font-size: 0.91rem;
  line-height: 1.52;
}

.fp-doc-callout ul {
  margin: 0.35rem 0 0 0;
  padding-left: 1.2rem;
  font-size: 0.9rem;
}

.fp-doc-callout.is-tip {
  background: #ecfdf5;
  border-color: #a7f3d0;
  border-left-color: #059669;
  color: #064e3b;
}

.fp-doc-callout.is-tip p,
.fp-doc-callout.is-tip li {
  color: #065f46;
}

.fp-doc-callout.is-info {
  background: #eff6ff;
  border-color: #bfdbfe;
  border-left-color: #2563eb;
  color: #1e3a8a;
}

.fp-doc-callout.is-info p,
.fp-doc-callout.is-info li {
  color: #1e40af;
}

.fp-doc-callout.is-warning {
  background: #fffbeb;
  border-color: #fde68a;
  border-left-color: #d97706;
  color: #78350f;
}

.fp-doc-callout.is-warning p,
.fp-doc-callout.is-warning li {
  color: #92400e;
}

.fp-doc-callout.is-caution {
  background: #fef2f2;
  border-color: #fecaca;
  border-left-color: #dc2626;
  color: #7f1d1d;
}

.fp-doc-callout.is-caution p,
.fp-doc-callout.is-caution li {
  color: #991b1b;
}

/* Card Grids (Apps, FCA Downloads, Platforms) */
.fp-doc-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  margin: 0.9rem 0 1.1rem 0;
}

.fp-doc-card-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.fp-doc-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1rem 1.05rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.65rem;
  min-width: 0;
}

.fp-doc-card.is-recommended {
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 70%);
  border-color: #93c5fd;
}

.fp-doc-card-badge {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.69rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.16rem 0.52rem;
  border-radius: 999px;
  background: #e2e8f0;
  color: #334155;
  margin-bottom: 0.35rem;
}

.fp-doc-card-badge.is-blue {
  background: #dbeafe;
  color: #1d4ed8;
}

.fp-doc-card-badge.is-green {
  background: #d1fae5;
  color: #047857;
}

.fp-doc-card-badge.is-amber {
  background: #fef3c7;
  color: #b45309;
}

.fp-doc-card h3 {
  font-size: 1rem;
  font-weight: 800;
  margin: 0 0 0.25rem 0;
  color: #0f172a;
}

.fp-doc-card p {
  font-size: 0.87rem;
  line-height: 1.46;
  color: #475569;
  margin: 0;
}

.fp-doc-card-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.48rem 0.82rem;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 9px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #1d4ed8 !important;
  text-decoration: none !important;
  transition: border-color 0.14s ease, background 0.14s ease;
}

.fp-doc-card-link:hover {
  border-color: #3b82f6;
  background: #eff6ff;
}

.fp-doc-card-link.is-primary {
  background: #2563eb;
  border-color: #2563eb;
  color: #ffffff !important;
}

.fp-doc-card-link.is-primary:hover {
  background: #1d4ed8;
}

/* Badges inside tables */
.fp-doc-badge {
  display: inline-block;
  font-size: 0.74rem;
  font-weight: 800;
  padding: 0.15rem 0.5rem;
  border-radius: 6px;
  white-space: nowrap;
}

.fp-doc-badge.is-default {
  background: #d1fae5;
  color: #065f46;
}

.fp-doc-badge.is-blue {
  background: #dbeafe;
  color: #1e40af;
}

.fp-doc-badge.is-amber {
  background: #fef3c7;
  color: #92400e;
}

.fp-doc-badge.is-gray {
  background: #f1f5f9;
  color: #475569;
}

/* Collapsible Accordions (<details>) */
.fp-doc-details {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
  margin: 0.65rem 0;
  overflow: hidden;
}

.fp-doc-details summary {
  cursor: pointer;
  list-style: none;
  padding: 0.85rem 1.05rem;
  font-weight: 700;
  font-size: 0.95rem;
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  user-select: none;
}

.fp-doc-details summary::-webkit-details-marker {
  display: none;
}

.fp-doc-details summary::after {
  content: "+";
  font-size: 1.15rem;
  font-weight: 700;
  color: #64748b;
  flex-shrink: 0;
}

.fp-doc-details[open] summary::after {
  content: "−";
  color: #2563eb;
}

.fp-doc-details[open] summary {
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
}

.fp-doc-details-body {
  background: #ffffff;
  padding: 0.95rem 1.05rem;
  font-size: 0.92rem;
  color: #334155;
}

.fp-doc-details-body p:last-child,
.fp-doc-details-body ul:last-child,
.fp-doc-details-body ol:last-child {
  margin-bottom: 0;
}

/* Sub-page compact links footer */
.fp-doc-footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.5rem;
}

/* Responsive Breakpoints */
@media screen and (max-width: 900px) {
  .fp-doc-hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.35rem;
    padding: 1.5rem;
  }

  .fp-doc-hero-visual img {
    max-width: 240px;
  }

  .fp-doc-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
  }

  .fp-doc-sidebar {
    display: none;
  }

  .fp-doc-mobile-toc {
    display: flex;
  }

  .fp-doc-controls-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .fp-doc-card-grid--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media screen and (max-width: 600px) {
  .fp-doc-hero {
    padding: 1.3rem 1.1rem;
    border-radius: 16px;
  }

  .fp-doc-hero h1 {
    font-size: 1.58rem;
  }

  .fp-doc-hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .fp-doc-section {
    padding: 1.15rem 1rem;
    border-radius: 14px;
  }

  .fp-doc-steps,
  .fp-doc-card-grid,
  .fp-doc-card-grid--3 {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media print {
  .fp-doc-sidebar,
  .fp-doc-mobile-toc,
  .fp-doc-try-links,
  .fp-doc-hero-actions {
    display: none !important;
  }

  .fp-doc-layout {
    grid-template-columns: 1fr;
  }

  .fp-doc-section {
    box-shadow: none;
    break-inside: avoid;
  }
}
