/* Inbound webhook help page. Plain CSS shipped with the package so the page
   looks right without the host app compiling the package views into its
   Tailwind theme. Dark mode follows Filament's `.dark` class. */
.ffb-help { display: flex; flex-direction: column; gap: 1.5rem; }
.ffb-help-text { font-size: .875rem; line-height: 1.5rem; color: rgb(55 65 81); margin: 0; }
.ffb-help-h3 { font-size: 1rem; font-weight: 600; color: rgb(3 7 18); margin: 0 0 .5rem; }
.ffb-help-h4 { font-size: .875rem; font-weight: 500; color: rgb(3 7 18); margin: 1rem 0 .5rem; }
.ffb-help-steps { display: flex; flex-direction: column; gap: 2rem; }
.ffb-help-figure { margin: .75rem 0 0; }
.ffb-help-figure img { display: block; width: 100%; max-width: 48rem; height: auto; border-radius: .5rem; border: 1px solid rgb(229 231 235); box-shadow: 0 1px 2px rgb(0 0 0 / .05); }
.ffb-help-figure figcaption { margin-top: .5rem; font-size: .75rem; color: rgb(107 114 128); }
.ffb-help-code { margin: 0; overflow: auto; border-radius: .5rem; background: rgb(17 24 39); color: rgb(243 244 246); padding: 1rem; font-size: .75rem; line-height: 1.25rem; }
.ffb-help-flow { display: flex; flex-direction: column; align-items: stretch; gap: .5rem; margin-top: 1rem; }
.ffb-help-flow-step { flex: 1; border: 1px solid rgb(229 231 235); border-radius: .5rem; background: #fff; padding: .75rem 1rem; text-align: center; }
.ffb-help-flow-step-final { border-color: var(--primary-500, rgb(99 102 241)); }
.ffb-help-flow-title { font-size: .875rem; font-weight: 600; color: rgb(3 7 18); }
.ffb-help-flow-sub { font-size: .75rem; color: rgb(107 114 128); }
.ffb-help-flow-arrow { width: 1.25rem; height: 1.25rem; flex-shrink: 0; align-self: center; color: rgb(156 163 175); transform: rotate(90deg); }
@media (min-width: 768px) {
    .ffb-help-flow { flex-direction: row; align-items: center; }
    .ffb-help-flow-arrow { transform: none; }
}
.ffb-help-table-wrap { margin-top: .5rem; overflow: hidden; border: 1px solid rgb(229 231 235); border-radius: .5rem; }
.ffb-help-table { width: 100%; border-collapse: collapse; text-align: left; font-size: .875rem; }
.ffb-help-table th { background: rgb(249 250 251); padding: .5rem .75rem; font-weight: 500; }
.ffb-help-table td { padding: .5rem .75rem; border-top: 1px solid rgb(229 231 235); color: rgb(55 65 81); vertical-align: top; }
.ffb-help-table td:first-child { font-family: ui-monospace, monospace; white-space: nowrap; }
.ffb-help-tools { display: grid; gap: 1rem; }
@media (min-width: 768px) { .ffb-help-tools { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ffb-help-tool { border: 1px solid rgb(229 231 235); border-radius: .5rem; padding: 1rem; }
.ffb-help-tool-head { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; }
.ffb-help-list { margin: .5rem 0 0; padding-left: 1.25rem; display: flex; flex-direction: column; gap: .25rem; font-size: .875rem; line-height: 1.5rem; color: rgb(55 65 81); }
ol.ffb-help-list { list-style: decimal; }
ul.ffb-help-list { list-style: disc; }

.dark .ffb-help-text, .dark .ffb-help-list, .dark .ffb-help-table td { color: rgb(209 213 219); }
.dark .ffb-help-h3, .dark .ffb-help-h4, .dark .ffb-help-flow-title { color: #fff; }
.dark .ffb-help-flow-sub, .dark .ffb-help-figure figcaption { color: rgb(156 163 175); }
.dark .ffb-help-flow-step { background: rgb(255 255 255 / .05); border-color: rgb(255 255 255 / .1); }
.dark .ffb-help-flow-step-final { border-color: var(--primary-400, rgb(129 140 248)); }
.dark .ffb-help-figure img, .dark .ffb-help-table-wrap, .dark .ffb-help-tool { border-color: rgb(255 255 255 / .1); }
.dark .ffb-help-table th { background: rgb(255 255 255 / .05); }
.dark .ffb-help-table td { border-top-color: rgb(255 255 255 / .1); }
.ffb-help-links { display: flex; flex-wrap: wrap; gap: .5rem; margin: .75rem 0; }

/* Form results page */
.ffb-results { display: flex; flex-direction: column; gap: 1.5rem; }
.ffb-results-toolbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; }
.ffb-results-presets { display: flex; flex-wrap: wrap; gap: .5rem; }
.ffb-results-dates { display: flex; flex-wrap: wrap; gap: .75rem; }
.ffb-results-filter { display: flex; flex-direction: column; gap: .25rem; font-size: .8125rem; color: rgb(107 114 128); }
.ffb-results-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: 1rem; }
.ffb-kpi { display: flex; flex-direction: column; gap: .25rem; padding: 1.25rem 1.5rem; border-radius: .75rem; background: #fff; box-shadow: 0 1px 2px rgb(0 0 0 / .05); outline: 1px solid rgb(3 7 18 / .05); }
.ffb-kpi-label { font-size: .8125rem; font-weight: 500; color: rgb(107 114 128); }
.ffb-kpi-value { font-size: 1.875rem; line-height: 2.25rem; font-weight: 700; color: rgb(17 24 39); font-variant-numeric: tabular-nums; }
.ffb-kpi-hint { font-size: .75rem; color: rgb(156 163 175); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ffb-kpi-good { color: #16a34a; } .ffb-kpi-mid { color: #d97706; } .ffb-kpi-bad { color: #dc2626; }
.ffb-results-grid { display: grid; grid-template-columns: 1fr; gap: 1.5rem; }
@media (min-width: 1024px) { .ffb-results-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ffb-results-card--wide { grid-column: 1 / -1; } }
.ffb-results-card .fi-wi-chart, .ffb-results-card .fi-section .fi-section { box-shadow: none; outline: none; }
.ffb-results-numbers { display: flex; flex-wrap: wrap; gap: 1.5rem; margin: 0 0 1rem; }
.ffb-results-numbers dt { font-size: .75rem; color: rgb(107 114 128); }
.ffb-results-numbers dd { margin: 0; font-size: 1.125rem; font-weight: 600; color: rgb(17 24 39); }
.ffb-results-nps-layout { display: grid; grid-template-columns: 1fr; gap: 1rem; align-items: center; }
@media (min-width: 768px) { .ffb-results-nps-layout { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); } }
.ffb-results-nps-gauge { position: relative; }
.ffb-results-nps-center { position: absolute; inset: 0 0 2.5rem 0; display: flex; flex-direction: column; align-items: center; justify-content: center; pointer-events: none; }
.ffb-results-nps-label { font-size: .75rem; font-weight: 600; letter-spacing: .05em; color: rgb(107 114 128); }
.ffb-results-nps-value { font-size: 2rem; font-weight: 800; color: rgb(17 24 39); }
.ffb-results-text-note { margin: 0; font-size: .875rem; color: rgb(107 114 128); }
.ffb-results-empty-state { display: flex; flex-direction: column; align-items: center; gap: .75rem; padding: 2rem 0; }
.ffb-results-empty-icon { width: 2.5rem; height: 2.5rem; color: rgb(156 163 175); }
.ffb-results-empty { margin: 0; font-size: .875rem; color: rgb(107 114 128); }
.dark .ffb-kpi { background: rgb(17 24 39); outline-color: rgb(255 255 255 / .1); }
.dark .ffb-kpi-value, .dark .ffb-results-numbers dd, .dark .ffb-results-nps-value { color: rgb(243 244 246); }
.dark .ffb-kpi-good { color: #4ade80; } .dark .ffb-kpi-mid { color: #fbbf24; } .dark .ffb-kpi-bad { color: #f87171; }
.ffb-results-text-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.ffb-results-text-list li { display: flex; justify-content: space-between; gap: 1rem; padding: .625rem 0; border-top: 1px solid rgb(3 7 18 / .06); font-size: .875rem; }
.ffb-results-text-list li:first-child { border-top: 0; }
.ffb-results-text-label { color: rgb(17 24 39); font-weight: 500; }
.ffb-results-text-count { color: rgb(107 114 128); white-space: nowrap; }
.dark .ffb-results-text-list li { border-top-color: rgb(255 255 255 / .08); }
.dark .ffb-results-text-label { color: rgb(243 244 246); }
.ffb-submission-message { padding: 1rem 1.25rem; border-radius: .75rem; background: rgb(249 250 251); border-left: 3px solid var(--primary-500, #6366f1); line-height: 1.6; }
.dark .ffb-submission-message { background: rgb(255 255 255 / .04); }
