.fb-page {
  padding: 0.85rem 0 calc(2rem + var(--safe-bottom, 0px) + var(--app-tab-clearance, 0px) + var(--app-pwa-clearance, 0px));
  max-width: 720px;
}
.fb-page[hidden],
.fb-similar[hidden],
.fb-form-body[hidden],
.fb-error[hidden],
.fb-notice[hidden] {
  display: none !important;
}
.fb-nav {
  display: none;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0 0 1rem;
}
.fb-nav a {
  color: var(--muted, #9aa3b2);
  text-decoration: none;
  font-weight: 650;
  font-size: 0.86rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}
.fb-nav a.is-active,
.fb-nav a:hover {
  color: inherit;
  background: rgba(var(--accent-rgb), 0.16);
}
.fb-hero {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "copy art"
    "cta cta";
  gap: 0.4rem 0.7rem;
  align-items: start;
  margin: 0 0 0.75rem;
}
.fb-hero-copy { grid-area: copy; }
.fb-hero h1 {
  font-size: clamp(1.35rem, 5.4vw, 1.85rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin: 0 0 0.4rem;
}
.fb-hero p {
  color: var(--muted, #9aa3b2);
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.4;
}
.fb-hero-art {
  grid-area: art;
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  padding-top: 0.1rem;
}
.fb-hero-bubble {
  width: 2.15rem;
  height: 2.15rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}
.fb-hero-bubble.is-idea { background: #ff2d83; }
.fb-hero-bubble.is-chat { background: #7c3aed; }
.fb-hero-cta {
  grid-area: cta;
  width: 100%;
  justify-content: center;
  min-height: 2.7rem;
  border-radius: 999px;
}
.fb-hero--compact {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  text-align: start;
}
.fb-hero--compact h1 { margin: 0; font-size: 1.25rem; }
.fb-hero--compact p { width: 100%; }
.fb-type-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
}
.fb-type-card {
  position: relative;
  display: grid;
  grid-template-columns: 1.2rem minmax(0, 1fr) 0.85rem;
  align-items: start;
  gap: 0.25rem 0.35rem;
  padding: 0.58rem 0.55rem 0.58rem 0.6rem;
  min-height: 0;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}
.fb-type-card strong {
  display: block;
  font-size: 0.78rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.fb-type-copy span {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--muted, #9aa3b2);
  font-size: 0.68rem;
  line-height: 1.3;
  margin-top: 0.12rem;
  font-weight: 500;
}
.fb-type-card:hover,
.fb-type-card.is-selected {
  border-color: rgba(var(--accent-rgb), 0.45);
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb), 0.12);
}
.fb-type-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.fb-type-icon {
  font-size: 1rem;
  line-height: 1;
  margin-top: 0.05rem;
}
.fb-type-arrow {
  color: var(--muted, #9aa3b2);
  display: inline-flex;
  margin-top: 0.15rem;
  opacity: 0.7;
}
.fb-form-body,
.fb-card {
  margin-top: 0.9rem;
  padding: 0.85rem 0.85rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}
.fb-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
  font-size: 0.9rem;
}
.fb-field small { font-weight: 500; color: var(--muted, #9aa3b2); }
.fb-field input,
.fb-field textarea,
.fb-field select,
.fb-filters input,
.fb-filters select {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.2);
  color: inherit;
  padding: 0.62rem 0.75rem;
  font: inherit;
}
.fb-field textarea { min-height: 5.5rem; }
.fb-field em,
.fb-error {
  color: #fb7185;
  font-style: normal;
  font-weight: 600;
  font-size: 0.86rem;
}
.fb-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0.7rem; }
.fb-help { color: var(--muted, #9aa3b2); font-size: 0.84rem; margin: 0 0 0.45rem; }
.fb-notice { padding: 0.65rem 0.75rem; border-radius: 12px; margin-bottom: 0.75rem; }
.fb-notice.is-warn { background: rgba(251, 191, 36, 0.12); border: 1px solid rgba(251, 191, 36, 0.28); }
.fb-drop {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 4.25rem;
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 14px;
  cursor: pointer;
}
.fb-drop input { display: none; }
.fb-files { list-style: none; padding: 0; margin: 0.65rem 0 0; display: grid; gap: 0.45rem; }
.fb-files li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.5rem 0.65rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
}
.fb-files progress { width: 7rem; }
.fb-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.85rem; }
.fb-similar { margin: 0.75rem 0; padding: 0.85rem; border-radius: 14px; border: 1px solid rgba(var(--accent-rgb), 0.28); }
.fb-similar ul { list-style: none; padding: 0; margin: 0.65rem 0; display: grid; gap: 0.5rem; }
.fb-similar li { display: flex; flex-wrap: wrap; gap: 0.35rem 0.7rem; align-items: center; }
.fb-similar-actions { display: flex; flex-wrap: wrap; gap: 0.55rem; }
.fb-confirm { text-align: center; padding: 2rem 0.75rem; }
.fb-confirm-number { font-size: 2rem; font-weight: 800; margin: 0.35rem 0 1rem; }
.fb-detail-head { display: flex; flex-wrap: wrap; gap: 0.65rem 0.85rem; align-items: center; margin-bottom: 0.85rem; }
.fb-detail-head h1 { margin: 0; font-size: 1.25rem; flex: 1; }
.fb-meta { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0.7rem; margin: 0 0 0.85rem; }
.fb-meta dt { color: var(--muted, #9aa3b2); font-size: 0.78rem; }
.fb-meta dd { margin: 0.15rem 0 0; font-weight: 600; }
.fb-badge { display: inline-flex; align-items: center; gap: 0.3rem; border-radius: 999px; padding: 0.22rem 0.6rem; font-size: 0.8rem; font-weight: 700; }
.fb-badge.is-new { background: rgba(59, 130, 246, 0.18); }
.fb-badge.is-reviewing { background: rgba(168, 85, 247, 0.18); }
.fb-badge.is-in_progress { background: rgba(249, 115, 22, 0.18); }
.fb-badge.is-testing { background: rgba(234, 179, 8, 0.18); }
.fb-badge.is-done { background: rgba(34, 197, 94, 0.18); }
.fb-badge.is-rejected { background: rgba(239, 68, 68, 0.18); }
.fb-comment { border-top: 1px solid rgba(255, 255, 255, 0.06); padding: 0.75rem 0; }
.fb-comment:first-of-type { border-top: 0; }
.fb-comment.is-internal { background: rgba(251, 191, 36, 0.06); margin: 0 -0.4rem; padding: 0.75rem 0.4rem; border-radius: 10px; }
.fb-comment time,
.fb-pill { color: var(--muted, #9aa3b2); font-size: 0.78rem; margin-inline-start: 0.35rem; }
.fb-activity { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.fb-activity time { display: block; color: var(--muted, #9aa3b2); font-size: 0.78rem; }
.fb-stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 0.6rem; margin-bottom: 1rem; }
.fb-stats article { padding: 0.75rem; border-radius: 14px; border: 1px solid rgba(255, 255, 255, 0.08); background: rgba(255, 255, 255, 0.03); }
.fb-stats span { color: var(--muted, #9aa3b2); font-size: 0.78rem; }
.fb-stats strong { display: block; font-size: 1.3rem; margin-top: 0.15rem; }
.fb-filters { display: grid; grid-template-columns: 1.4fr repeat(4, 0.9fr) 0.8fr 0.8fr auto auto; gap: 0.5rem; align-items: end; margin-bottom: 0.85rem; }
.fb-table-wrap { overflow-x: auto; }
.fb-table { width: 100%; border-collapse: collapse; min-width: 820px; }
.fb-table th,
.fb-table td { text-align: start; padding: 0.65rem 0.5rem; border-bottom: 1px solid rgba(255, 255, 255, 0.06); vertical-align: top; }
.fb-table a { color: inherit; font-weight: 650; }
.fb-mobile-list { display: none; }
.fb-empty { text-align: center; padding: 2rem 0.75rem; }
.fb-flash { padding: 0.65rem 0.85rem; border-radius: 12px; background: rgba(34, 197, 94, 0.14); margin-bottom: 0.85rem; }
.fb-check { display: flex; align-items: center; gap: 0.45rem; margin: 0.4rem 0; }
html[data-theme="light"] .fb-type-card,
html[data-theme="light"] .fb-card,
html[data-theme="light"] .fb-form-body,
html[data-theme="light"] .fb-stats article,
html[data-theme="light"] .fb-nav a {
  background: #fff;
  border-color: rgba(15, 23, 42, 0.08);
}
html[data-theme="light"] .fb-field input,
html[data-theme="light"] .fb-field textarea,
html[data-theme="light"] .fb-field select,
html[data-theme="light"] .fb-filters input,
html[data-theme="light"] .fb-filters select {
  background: #fff;
  border-color: rgba(15, 23, 42, 0.12);
}

@media (max-width: 900px) {
  .fb-page {
    padding-bottom: calc(
      6.25rem + var(--safe-bottom, 0px) + var(--app-tab-clearance, 0px) + var(--app-pwa-clearance, 0px)
    );
  }
  .fb-filters { grid-template-columns: 1fr 1fr; }
  .fb-grid-2 { grid-template-columns: 1fr; }
  .fb-table-wrap { display: none; }
  .fb-mobile-list { display: grid; gap: 0.6rem; }
  .fb-mobile-card {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    padding: 0.8rem;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: inherit;
    text-decoration: none;
  }
  .fb-hero--compact { flex-direction: column; align-items: stretch; }
  .fb-actions .btn,
  .fb-hero--compact .btn { min-height: 2.6rem; }
}

@media (min-width: 901px) {
  .fb-nav { display: flex; }
  .fb-page { max-width: 1080px; }
  .fb-type-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 44rem; }
  .fb-hero { max-width: 44rem; }
  .fb-hero-cta { width: auto; justify-self: start; padding-inline: 1.35rem; }
  .fb-type-card { padding: 0.85rem 0.8rem; }
  .fb-type-card strong { font-size: 0.92rem; }
  .fb-type-copy span { font-size: 0.78rem; }
}

[dir="rtl"] .fb-type-arrow { transform: scaleX(-1); }

.fb-admin-shell.fb-page {
  max-width: none;
  width: 100%;
  padding: 0 0 1.5rem;
}
.fb-admin-shell .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-height: 2.4rem;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.fb-admin-shell .btn-primary { background: #ff2d78; color: #fff; }
.fb-admin-shell .btn-outline { background: transparent; color: inherit; border-color: rgba(255, 255, 255, 0.22); }
.fb-admin-shell .btn-ghost { background: transparent; color: inherit; }
.fb-admin-shell .btn-sm { min-height: 2.15rem; font-size: 0.85rem; }
@media (max-width: 900px) {
  .fb-admin-shell.fb-page { padding-bottom: 5.5rem; }
}
