/* Ravalak Pest Control Interface Pro – inbox, chat, safety forms, follow-ups, newsletters. */

/* Top of every screen: Report an incident (red), daily FLHA (green), inbox bell. */
.rvb-incident-btn, .rvb-flha-btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 8px; font-weight: 700; font-size: 14px; line-height: 1.2; text-decoration: none !important; white-space: nowrap; }
.rvb-incident-btn { background: #dc2626; color: #fff !important; box-shadow: 0 1px 0 rgba(0,0,0,.12); }
.rvb-incident-btn:hover, .rvb-incident-btn:focus { background: #b91c1c; color: #fff !important; }
.rvb-flha-btn { background: #16a34a; color: #fff !important; }
.rvb-flha-btn:hover, .rvb-flha-btn:focus { background: #15803d; }
.rvb-bell { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 50%; background: #eef1f5; color: #1d2330 !important; text-decoration: none !important; }
.rvb-bell .dashicons { font-size: 20px; width: 20px; height: 20px; }
.rvb-bell.has-new { background: #fee2e2; color: #b91c1c !important; }
.rvb-bell-n { position: absolute; top: -4px; right: -4px; background: #dc2626; color: #fff; border-radius: 999px; font-size: 11px; font-weight: 700; min-width: 18px; height: 18px; line-height: 18px; text-align: center; padding: 0 5px; box-sizing: border-box; }
.rvb-team-bar { display: flex; justify-content: flex-end; align-items: center; gap: 8px; padding: 10px 20px 0 0; }
html.rvb-embed .rvb-team-bar { display: none; }
.rvb-app-top-actions .rvb-incident-btn { padding: 7px 12px; }
@media (max-width: 600px) {
  .rvb-app-top-actions .rvb-incident-btn, .rvb-app-top-actions .rvb-flha-btn { font-size: 0; gap: 0; padding: 8px 10px; }
  .rvb-app-top-actions .rvb-incident-btn span, .rvb-app-top-actions .rvb-flha-btn span { font-size: 16px; }
  .rvb-portal-head .rvb-actions { flex-wrap: wrap; }
}
.rvb-start-shift { border: 2px solid #16a34a; background: #f0fdf4; }
.rvb-btn-lg { font-size: 17px; padding: 14px 26px; }

/* Inbox. */
.rvb-inbox-filter { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 16px; }
.rvb-inbox-filter a { padding: 5px 12px; border: 1px solid #c3c4c7; border-radius: 999px; text-decoration: none; color: #1d2327; background: #fff; }
.rvb-inbox-filter a.is-on { background: #1d2330; border-color: #1d2330; color: #fff; }
.rvb-inbox { display: flex; flex-direction: column; gap: 10px; max-width: 900px; }
.rvb-inbox-item { background: #fff; border: 1px solid #e3e7ee; border-left: 4px solid #cbd5e1; border-radius: 10px; padding: 12px 14px; }
.rvb-inbox-item.is-new { border-left-color: #dc2626; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.rvb-inbox-item.is-done { opacity: .7; }
.rvb-inbox-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 12px; margin-bottom: 4px; }
.rvb-inbox-kind { background: #eef1f5; border-radius: 999px; padding: 2px 9px; font-weight: 700; }
.rvb-ik-followup { background: #dbeafe; color: #1e40af; } .rvb-ik-safety { background: #fee2e2; color: #991b1b; } .rvb-ik-leave { background: #dcfce7; color: #166534; } .rvb-ik-timesheet { background: #fef3c7; color: #92400e; }
.rvb-inbox-new { background: #dc2626; color: #fff; border-radius: 999px; padding: 2px 8px; font-weight: 700; }
.rvb-inbox-state { color: #166534; font-weight: 600; } .rvb-inbox-state.is-todo { color: #b45309; }
.rvb-inbox-when { margin-left: auto; color: #6b7280; }
.rvb-inbox-title { display: block; font-size: 15px; }
.rvb-inbox-body { margin-top: 4px; color: #374151; font-size: 14px; }
.rvb-inbox-acts { margin-top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.rvb-fu-review { margin-top: 10px; background: #f8fafc; border: 1px solid #e3e7ee; border-radius: 8px; padding: 8px 12px; }
.rvb-fu-review summary { cursor: pointer; font-weight: 700; }
.rvb-fu-rates td, .rvb-fu-rates th { vertical-align: middle; }

/* Chat. */
.rvb-chat-notice { background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412; border-radius: 8px; padding: 8px 12px; font-size: 13.5px; display: flex; gap: 8px; align-items: flex-start; }
.rvb-chat-wrap { display: grid; grid-template-columns: 260px minmax(0, 1fr); height: min(70vh, 640px); background: #fff; border: 1px solid #e3e7ee; border-radius: 12px; overflow: hidden; }
.rvb-chat-rooms { border-right: 1px solid #e3e7ee; overflow-y: auto; padding: 6px; background: #f8fafc; }
.rvb-chat-group { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: #6b7280; margin: 10px 8px 4px; }
.rvb-chat-room { display: grid; grid-template-columns: 1fr auto; width: 100%; text-align: left; border: 0; background: none; padding: 8px 10px; border-radius: 8px; cursor: pointer; font: inherit; color: #1d2330; }
.rvb-chat-room:hover { background: #eef1f5; } .rvb-chat-room.is-on { background: #1d2330; color: #fff; }
.rvb-chat-rname { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rvb-chat-rsub { grid-column: 1; font-size: 11.5px; opacity: .7; }
.rvb-chat-unread { grid-row: 1 / span 2; grid-column: 2; align-self: center; background: #dc2626; color: #fff; border-radius: 999px; font-size: 11px; font-weight: 700; min-width: 18px; height: 18px; line-height: 18px; text-align: center; padding: 0 5px; }
.rvb-chat-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.rvb-chat-head { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid #e3e7ee; }
.rvb-chat-back { display: none; border: 0; background: #eef1f5; border-radius: 8px; font-size: 20px; width: 34px; height: 34px; cursor: pointer; }
.rvb-chat-log { flex: 1; overflow-y: auto; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; background: #fbfcfd; }
.rvb-chat-day { align-self: center; font-size: 11.5px; color: #6b7280; background: #eef1f5; border-radius: 999px; padding: 2px 10px; margin: 6px 0; }
.rvb-chat-msg { max-width: 78%; align-self: flex-start; }
.rvb-chat-msg.is-mine { align-self: flex-end; text-align: right; }
.rvb-chat-meta { font-size: 11.5px; color: #6b7280; margin: 0 4px 2px; }
.rvb-chat-body { display: inline-block; text-align: left; background: #fff; border: 1px solid #e3e7ee; border-radius: 12px; padding: 8px 12px; white-space: pre-wrap; overflow-wrap: anywhere; }
.rvb-chat-msg.is-mine .rvb-chat-body { background: #1d2330; color: #fff; border-color: #1d2330; }
.rvb-chat-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid #e3e7ee; background: #fff; }
.rvb-chat-form textarea { flex: 1; min-width: 0; resize: vertical; border: 1px solid #cbd5e1; border-radius: 8px; padding: 8px; font: inherit; }
@media (max-width: 700px) {
  .rvb-chat-wrap { grid-template-columns: 1fr; height: 72vh; }
  .rvb-chat-main { display: none; } .rvb-chat.is-open .rvb-chat-main { display: flex; } .rvb-chat.is-open .rvb-chat-rooms { display: none; }
  .rvb-chat-back { display: inline-block; } .rvb-chat-rooms { border-right: 0; }
}

/* Safety forms. */
.rvb-sf-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px 16px; }
.rvb-sf-wide { grid-column: 1 / -1; }
.rvb-sf-checks { border: 1px solid #e3e7ee; border-radius: 8px; padding: 8px 12px; margin: 0; }
.rvb-sf-checks legend { font-weight: 700; padding: 0 4px; }
.rvb-sf-checks .rvb-check { display: block; margin: 4px 0; }
.rvb-sf-group { font-weight: 700; margin: 8px 0 2px; font-size: 13px; color: #374151; }
.rvb-sf-yesno .rvb-check { display: inline-flex; margin-right: 12px; }
.rvb-sf-tbl input, .rvb-sf-tbl select { width: 100%; min-width: 90px; box-sizing: border-box; }
.rvb-sf-lines .rvb-table-wrap { margin: 4px 0; }
.rvb-sigpad { position: relative; border: 1px dashed #94a3b8; border-radius: 8px; background: #fff; max-width: 520px; touch-action: none; }
.rvb-sigpad canvas { display: block; touch-action: none; cursor: crosshair; }
.rvb-sigpad [data-rvb-sig-clear] { position: absolute; right: 8px; top: 6px; }
.rvb-sig-prev, .rvb-sig-img { display: block; max-width: 260px; max-height: 110px; background: #fff; border: 1px solid #e3e7ee; border-radius: 6px; }
.rvb-sf-row { min-width: 0; }
.rvb-sf-l { display: block; font-size: 12.5px; font-weight: 700; color: #4b5563; }
.rvb-sf-v { margin-top: 2px; overflow-wrap: anywhere; }
.rvb-sf-done { list-style: none; margin: 0; padding: 0; columns: 2 260px; }
.rvb-sf-done li.is-off { color: #9ca3af; }
.rvb-sf-bad { background: #fee2e2 !important; color: #991b1b; font-weight: 700; }
.rvb-sf-pics { display: flex; flex-wrap: wrap; gap: 8px; } .rvb-sf-pics img { width: 120px; height: 90px; object-fit: cover; border-radius: 6px; }
.rvb-sf-new { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 14px; }
.rvb-sf-new .rvb-sf-new-incident { border-color: #dc2626 !important; color: #b91c1c !important; }
.rvb-sf-filter { margin: 12px 0; }
.rvb-sf-head { grid-column: 1 / -1; margin: 10px 0 0; border-bottom: 1px solid #e3e7ee; padding-bottom: 4px; }
.rvb-sf-admin .rvb-card { background: #fff; border: 1px solid #dcdcde; border-radius: 8px; padding: 14px 18px; margin: 0 0 16px; max-width: 980px; }
.rvb-jha-card { border-left: 4px solid #f59e0b; }
.rvb-fb { display: flex; flex-direction: column; gap: 8px; max-width: 980px; }
.rvb-fb-row { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: flex-end; background: #fff; border: 1px solid #dcdcde; border-radius: 8px; padding: 10px 12px; }
.rvb-fb-row label { display: flex; flex-direction: column; gap: 3px; font-weight: 600; font-size: 13px; }
.rvb-fb-row .rvb-fb-req { flex-direction: row; align-items: center; gap: 6px; font-weight: 400; }
.rvb-fb-move { display: flex; flex-direction: column; }
.rvb-fb-opts textarea { min-width: 220px; }
@media print {
  .rvb-team-bar, .rvb-app-side, .rvb-app-top, .rvb-tabs, .rvb-menu-btn, #adminmenumain, #wpadminbar, .nav-tab-wrapper, .rvb-sf-new, form.rvb-form { display: none !important; }
}

/* Newsletters. */
.rvb-nl-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; margin: 12px 0; }
.rvb-nl-box { background: #fff; border: 1px solid #dcdcde; border-radius: 8px; padding: 12px 18px; margin: 0 0 16px; }
.rvb-nl-box summary { cursor: pointer; }
.rvb-nl-bar { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; margin: 12px 0; }
.rvb-nl-bar form { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.rvb-nl-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.rvb-nl-form strong { width: 100%; }
.rvb-nl-form input[type=email] { flex: 1 1 200px; padding: 9px; }

/* Follow-ups on the job screen. */
.rvb-fu-form { border: 2px solid #2563eb; }
.rvb-fu-free { background: #f8fafc; border-radius: 8px; padding: 8px 12px; margin: 6px 0 10px; }
.rvb-fu-free .rvb-check { display: block; margin: 4px 0; }
.rvb-waiting-notice a { font-weight: 700; }
