.plant-alerts { margin-top:20px; }
.plant-alert-heading { display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap; }
.plant-alert-heading h2 { margin:0; }
.plant-alerts button { min-height:44px; }
.plant-alert-table { table-layout:fixed; font-size:.95rem; }
.plant-alert-table th:first-child { width:21%; }
.plant-alert-table th:last-child { width:22%; }
.plant-alert-table td { vertical-align:top; }
.plant-alert-date time, .plant-alert-state time { display:block; color:var(--muted); font-size:.85rem; line-height:1.5; }
.plant-alert-state time { margin-top:6px; }
.plant-alert-table .tag { white-space:normal; line-height:1.4; }
.plant-alert-event>p { white-space:pre-wrap; overflow-wrap:anywhere; line-height:1.6; }
.plant-alert-deliveries summary { cursor:pointer; min-height:44px; padding:12px 0; font-size:.85rem; }
.plant-alert-footer { display:flex; justify-content:space-between; align-items:center; gap:16px; margin-top:20px; flex-wrap:wrap; }
.plant-alert-footer>div { display:flex; gap:8px; flex-wrap:wrap; }
.plant-alerts [hidden] { display:none; }
.plant-alert-empty { color:var(--muted); padding:16px 0; }
@media(max-width:600px) {
  .plant-alert-heading { align-items:flex-start; }
  .plant-alert-table thead { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
  .plant-alert-table, .plant-alert-table tbody { display:block; }
  .plant-alert-table tr { display:block; padding:18px 0; border-top:1px solid var(--border); }
  .plant-alert-table td { display:block; width:100%; max-width:none; padding:0; border:0; }
  .plant-alert-table .plant-alert-event { padding-top:12px; }
  .plant-alert-table .plant-alert-state { display:flex; align-items:center; gap:10px; flex-wrap:wrap; margin-top:12px; }
  .plant-alert-state time { margin:0; }
  .plant-alert-footer>div { width:100%; }
  .plant-alert-footer button { flex:1; }
}
.delivery-history-note { font-size:.9rem; color:var(--muted); line-height:1.55; }
.delivery-history-item { border-top:1px solid var(--border); padding:20px 0; }
.delivery-history-item:first-child { margin-top:20px; }
.delivery-history-item h3 { font-size:1.1rem; margin:10px 0 8px; }
.delivery-history-event { display:flex; justify-content:space-between; align-items:center; gap:8px 20px; flex-wrap:wrap; font-size:.85rem; }
.delivery-history-event time { color:var(--muted); }
.delivery-history-kind { font-weight:700; }
.delivery-history-message { margin:8px 0 14px; line-height:1.5; white-space:pre-wrap; overflow-wrap:anywhere; }
.delivery-history-channels { list-style:none; padding:0; margin:12px 0 0; }
.delivery-history-channel { display:flex; justify-content:space-between; align-items:center; gap:8px 20px; padding:10px 0; border-bottom:1px solid var(--border); }
.delivery-history-channel:last-child { border-bottom:0; }
.delivery-history-channel small { display:block; color:var(--muted); margin-top:4px; overflow-wrap:anywhere; }
.delivery-history-status { padding:6px 10px; border-radius:10px; font-size:.85rem; line-height:1.4; text-align:right; max-width:58%; }
.delivery-sent { background:#eaf3eb; color:#1f543d; }
.delivery-issue { background:#fff0e9; color:#913d24; }
.delivery-pending { background:#fff6dc; color:#765817; }
.delivery-quiet { background:#f0f2ed; color:#5d6a60; }
.delivery-history-no-send { padding:12px; border-radius:10px; background:#f0f2ed; color:#4e6155; }
.delivery-history-inactive, .delivery-history-reference { margin-top:10px; }
.delivery-history summary { cursor:pointer; padding:10px 0; min-height:44px; font-size:.9rem; }
.delivery-history-reference p { white-space:pre-wrap; overflow-wrap:anywhere; }
.delivery-history-pagination { display:flex; justify-content:space-between; align-items:center; gap:16px; flex-wrap:wrap; }
.delivery-history-pagination[hidden] { display:none; }
.delivery-history-pagination>div { display:flex; gap:8px; flex-wrap:wrap; }
.delivery-history button { min-height:44px; }
@media(max-width:600px) {
  .delivery-history-channel { align-items:flex-start; }
  .delivery-history-status { max-width:60%; text-align:left; }
  .delivery-history-heading { align-items:flex-start; }
  .delivery-history-pagination>div { width:100%; }
  .delivery-history-pagination button { flex:1; }
}
