/* Forms — WhatsApp Flows (Bulk Sender → Forms). Shared pieces: whatsapp-tools.css. */

/* The list */
.wfo-table td{vertical-align:middle}
.wfo-table td small{max-width:360px}
.wfo-warn{display:inline-flex;align-items:center;gap:4px;color:#b54708}
.wfo-muted{color:#98a2b3}
.wfo-cats{display:flex;flex-wrap:wrap;gap:4px;max-width:260px}
.wfo-cat{display:inline-block;background:#f2f4f7;color:#344054;border-radius:999px;padding:2px 9px;font-size:11.5px;font-weight:500;white-space:nowrap}
.wfo-num{white-space:nowrap;font-variant-numeric:tabular-nums}
.wfo-nowrap{white-space:nowrap}
.wfo-table .we-link{font-size:13px;padding:2px 4px}
.wfo-empty{padding:48px 20px;margin:0}
.wfo-dep{margin:0}
.wfo-pages{display:flex;align-items:center;gap:6px;white-space:nowrap}
.wfo-pages b{color:var(--we-ink)}
.we-page .wfo-per{margin-left:8px}

/* The builder */
.wfo-main{min-width:0}
.wfo-cats-pick{display:flex;flex-wrap:wrap;gap:8px}
.wfo-chip{display:inline-flex;align-items:center;gap:5px;border:1px solid #d0d5dd;background:#fff;color:#344054;border-radius:999px;padding:6px 12px;font-size:12.5px;font-weight:500;transition:background .15s,border-color .15s}
.wfo-chip svg{display:none}
.wfo-chip:hover{border-color:#9db4f2;color:#1d4ed8}
.wfo-chip.on{background:#eef4ff;border-color:#2563eb;color:#1d4ed8}
.wfo-chip.on svg{display:inline}
.wfo-chip:focus-visible{outline:2px solid #2563eb;outline-offset:2px}
.wfo-tabs-row{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin:0 0 16px}
.wfo-tabs{flex-wrap:wrap;max-width:100%}
.wfo-screen-head{display:flex;align-items:flex-end;gap:12px}
.wfo-screen-head .wt-field{flex:1;min-width:0}
.wfo-screen-head .btn{margin-bottom:14px;flex-shrink:0}
.wfo-fields{margin:4px 0 12px}
.wfo-none{display:flex;align-items:center;gap:6px;color:var(--we-muted);font-size:12.5px;border:1px dashed #d0d5dd;border-radius:10px;padding:14px;margin:0 0 12px}
.wfo-field .wt-field:last-child{margin-bottom:6px}
.wfo-field .wt-block-head span{display:inline-flex;align-items:center;gap:6px}
.wfo-field .wt-block-tools .we-icon-btn.small{width:28px;height:28px}
.wfo-options{display:grid;gap:6px;margin:0 0 8px}
.wfo-option{display:grid;grid-template-columns:18px minmax(0,1fr) auto;gap:8px;align-items:center}
.we-page .wfo-option .input{margin-top:0}
.wfo-mark{width:14px;height:14px;border:2px solid #98a2b3;border-radius:50%}
.wfo-mark.checkbox{border-radius:4px}
.wfo-mark.dropdown{border:0;width:6px;height:6px;border-radius:50%;background:#98a2b3;margin-left:4px}
.wfo-opt-add{margin:0 0 12px}
.wfo-field-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;border-top:1px solid #f2f4f7;padding-top:10px;margin-top:4px}
.wfo-save{display:flex;align-items:center;gap:8px;font-size:12.5px;font-weight:600;color:#24385d}
.we-page .wfo-save .input{width:auto;min-width:150px;max-width:220px;margin:0;min-height:34px;height:34px;padding:0 8px;font-size:12.5px}
.wfo-types{margin:10px 0 4px}
.wfo-types .wt-tile{width:92px}
.wfo-button-text{margin:16px 0 0}
.wfo-continue{display:flex;align-items:center;gap:6px;margin:14px 0 0}
.wfo-errors strong{display:flex;align-items:center;gap:6px}
.wfo-errors ul{margin:6px 0 0;padding-left:20px}
.wfo-errors li{margin:3px 0}
.wfo-bar{display:flex;justify-content:flex-end;gap:10px;margin-top:16px}
.wfo-bar .btn{min-width:120px;justify-content:center}

/* The phone preview: a WhatsApp Flow screen sliding up over the chat */
.wfo-phone{border-radius:24px;overflow:hidden;border:8px solid #10213f;background:#10213f;box-shadow:0 18px 40px rgba(9,29,66,.18);max-width:300px;margin:0 auto}
.wfo-phone-chat{background:#efe7dd;background-image:radial-gradient(rgba(0,0,0,.035) 1px,transparent 1px);background-size:12px 12px;padding-top:34px}
.wfo-sheet{background:#fff;border-radius:16px 16px 0 0;min-height:430px;display:flex;flex-direction:column;box-shadow:0 -2px 10px rgba(0,0,0,.08)}
.wfo-sheet-top{display:grid;grid-template-columns:24px minmax(0,1fr) 24px;align-items:center;gap:6px;padding:12px 12px 10px;border-bottom:1px solid #eef0f2;color:#54656f}
.wfo-sheet-top strong{font-size:14px;color:#111b21;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.wfo-sheet-more{font-size:18px;line-height:1;text-align:right}
.wfo-sheet-body{flex:1;padding:14px 16px;display:grid;gap:13px;align-content:start}
.wfo-p-h{margin:0;font-size:17px;font-weight:700;color:#111b21;line-height:1.3;overflow-wrap:anywhere}
.wfo-p-b{margin:0;font-size:13px;color:#3b4a54;line-height:1.5;white-space:pre-wrap;overflow-wrap:anywhere}
.wfo-p-in{display:flex;align-items:center;justify-content:space-between;gap:8px;border:1px solid #c6cfd4;border-radius:8px;padding:11px 12px;font-size:13px;color:#667781}
.wfo-p-in.area{min-height:62px;align-items:flex-start}
.wfo-p-in span,.wfo-p-group strong span,.wfo-p-optin span{overflow-wrap:anywhere}
.wfo-p-in svg{flex-shrink:0;color:#54656f}
.wfo-p-in em,.wfo-p-group em,.wfo-p-optin em{font-style:normal;color:#8696a0;font-size:11.5px}
.wfo-p-help{display:block;font-size:11px;color:#667781;margin:4px 2px 0}
.wfo-p-group strong{display:block;font-size:13px;color:#111b21;margin:0 0 4px}
.wfo-p-group .wfo-p-help{margin:0 0 4px}
.wfo-p-opt{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:9px 2px;border-bottom:1px solid #f0f2f5;font-size:13px;color:#111b21}
.wfo-p-opt span{overflow-wrap:anywhere}
.wfo-p-opt i,.wfo-p-optin i{width:16px;height:16px;border:2px solid #8696a0;border-radius:50%;flex-shrink:0}
.wfo-p-opt i.checkbox,.wfo-p-optin i{border-radius:4px}
.wfo-p-optin{display:flex;align-items:flex-start;gap:10px;font-size:13px;color:#111b21;line-height:1.45}
.wfo-p-ph{color:#98a2b3;font-style:italic}
.wfo-p-empty{margin:60px 0;text-align:center;color:#8696a0;font-size:12px}
.wfo-sheet-foot{padding:10px 16px 14px;border-top:1px solid #eef0f2;text-align:center}
.wfo-p-btn{display:block;background:#1daa61;color:#fff;border-radius:22px;padding:10px;font-weight:600;font-size:13.5px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.wfo-sheet-foot small{display:block;margin-top:8px;font-size:10.5px;color:#8696a0}
.wfo-pager{display:flex;justify-content:center;gap:6px;margin:12px 0 0}
.wfo-pager button{width:30px;height:30px;border-radius:50%;border:1px solid #d0d5dd;background:#fff;color:#475467;font-size:12px;font-weight:600}
.wfo-pager button.on{background:#2563eb;border-color:#2563eb;color:#fff}

/* Responses */
.wfo-resp-back{flex-wrap:wrap}
.wfo-resp-back>div{min-width:0;flex:1 1 220px}
.wfo-resp-back p{overflow-wrap:anywhere}
.wfo-resp-table td{max-width:280px;overflow-wrap:anywhere}
.wfo-contact strong{display:block;white-space:nowrap}
.wfo-contact .we-link{padding:2px 0 0;font-size:12px}

/* Dialogs: a form's own preview, the template that opens a form, and sending one from the inbox */
.wfo-view .wfo-phone{margin-bottom:4px}
.wfo-tpl-grid{display:grid;grid-template-columns:minmax(0,1fr) 280px;gap:20px;align-items:start}
.wfo-tpl-side .we-phone{max-width:100%}
.wfo-tpl .wt-field .input,.wfo-tpl .wt-field .textarea,.wfo-send .wt-field .input,.wfo-send .wt-field .textarea{margin-top:0}

@media(max-width:900px){.wfo-tpl-grid{grid-template-columns:minmax(0,1fr)}.wfo-tpl-side{max-width:320px}}
@media(max-width:640px){
  .wfo-screen-head{flex-direction:column;align-items:stretch;gap:0}
  .wfo-screen-head .btn{align-self:flex-start}
  .wfo-field-foot{align-items:stretch;flex-direction:column}
  .wfo-save{flex-direction:column;align-items:stretch;gap:4px}
  .we-page .wfo-save .input{max-width:none;width:100%}
  .wfo-types .wt-tile{width:calc(33.33% - 6px)}
  .wfo-bar .btn{flex:1;min-width:0}
  .wfo-cats{max-width:none}
}
@media(prefers-reduced-motion:reduce){.wfo-chip{transition:none}}
