/* DaCucina — global WhatsApp agent notifications (2026-09-28). Lives on <body>, outside the workspace-tab containers.
   Same visual system as the sidebar / inbox theme (cream, charcoal, bronze). */
#dcn-root { position: fixed; left: 84px; bottom: 16px; z-index: 2600; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; direction: rtl; pointer-events: none; font-family: inherit; }
#dcn-root * { box-sizing: border-box; }
.dcn-pop { pointer-events: auto; width: min(360px, calc(100vw - 32px)); background: #FFFEFC; color: #292621; border: 1px solid #E5DDD2; border-radius: 14px; box-shadow: 0 12px 34px rgba(41, 38, 33, .18); padding: 10px 12px 10px; font-size: 12.5px; animation: dcn-in 180ms cubic-bezier(.4, 0, .2, 1); border-inline-start: 4px solid #A78053; }
.dcn-pop.leaving { animation: dcn-out 140ms ease-in forwards; }
@keyframes dcn-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes dcn-out { to { opacity: 0; transform: translateY(6px); } }
.dcn-head { display: flex; align-items: center; gap: 8px; }
.dcn-avatar { width: 34px; height: 34px; border-radius: 50%; background: rgba(167, 128, 83, .14); border: 1px solid #A78053; color: #6b5230; display: flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0; font-size: 13px; }
.dcn-who { flex: 1; min-width: 0; }
.dcn-name { font-weight: 700; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dcn-meta { font-size: 11px; color: #756D63; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dcn-count { background: #2B2724; color: #F7F3EC; border-radius: 999px; min-width: 20px; height: 20px; padding: 0 6px; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; }
.dcn-x { border: none; background: transparent; color: #756D63; cursor: pointer; font-size: 16px; line-height: 1; padding: 2px 4px; border-radius: 6px; }
.dcn-x:hover, .dcn-x:focus-visible { background: rgba(167, 128, 83, .14); outline: none; }
.dcn-preview { margin-top: 6px; background: #F7F5F0; border: 1px solid #E5DDD2; border-radius: 10px; padding: 6px 9px; font-size: 12.5px; line-height: 1.45; max-height: 64px; overflow: hidden; white-space: pre-wrap; word-break: break-word; }
.dcn-preview .m { color: #756D63; font-style: italic; }
.dcn-actions { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.dcn-btn { border: 1px solid #E5DDD2; background: transparent; color: #292621; border-radius: 9px; padding: 6px 10px; font-size: 12px; font-weight: 600; cursor: pointer; font-family: inherit; transition: background 150ms, border-color 150ms, transform 150ms; display: inline-flex; align-items: center; gap: 5px; }
.dcn-btn:hover { background: rgba(167, 128, 83, .14); border-color: #A78053; }
.dcn-btn:active { transform: translateY(1px); }
.dcn-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(167, 128, 83, .35); }
.dcn-btn.primary { background: #A78053; border-color: #A78053; color: #fff; }
.dcn-btn.primary:hover { background: #8a6636; }
.dcn-btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.dcn-reply { margin-top: 8px; display: none; }
.dcn-reply.on { display: block; }
.dcn-reply textarea { width: 100%; min-height: 58px; max-height: 140px; resize: vertical; border: 1px solid #E5DDD2; border-radius: 10px; padding: 7px 9px; font: inherit; font-size: 12.5px; background: #fff; color: #292621; }
.dcn-reply textarea:focus { outline: none; border-color: #A78053; box-shadow: 0 0 0 3px rgba(167, 128, 83, .35); }
.dcn-reply .row { display: flex; gap: 6px; align-items: center; margin-top: 6px; flex-wrap: wrap; }
.dcn-status { font-size: 11px; color: #756D63; flex: 1; min-width: 0; }
.dcn-status.ok { color: #3d6b3a; } .dcn-status.err { color: #9b2c2c; } .dcn-status.warn { color: #b7791f; }
.dcn-tabs { margin-top: 6px; background: #F7F5F0; border: 1px solid #E5DDD2; border-radius: 10px; padding: 6px 8px; font-size: 11.5px; }
.dcn-tabs button { display: block; width: 100%; text-align: right; border: none; background: transparent; padding: 4px 6px; border-radius: 6px; cursor: pointer; font: inherit; font-size: 12px; }
.dcn-tabs button:hover { background: rgba(167, 128, 83, .14); }
/* bell (notification centre entry) */
.dcn-bell { pointer-events: auto; position: relative; width: 42px; height: 42px; border-radius: 50%; border: 1px solid #E5DDD2; background: #FFFEFC; color: #292621; box-shadow: 0 6px 18px rgba(41, 38, 33, .12); cursor: pointer; display: none; align-items: center; justify-content: center; font-size: 18px; transition: transform 150ms; }
.dcn-bell.on { display: inline-flex; }
.dcn-bell, .dcn-center-head { touch-action: none; }
.dcn-center-head { cursor: grab; }
#dcn-root.dragging { transition: none; } #dcn-root.dragging .dcn-bell, #dcn-root.dragging .dcn-center-head { cursor: grabbing; }
.dcn-bell::after { content: ''; }
.dcn-bell:hover { transform: translateY(-1px); }
.dcn-bell:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(167, 128, 83, .35); }
.dcn-bell .n { position: absolute; top: -4px; inset-inline-end: -4px; background: #9b2c2c; color: #fff; border-radius: 999px; min-width: 18px; height: 18px; font-size: 10.5px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; }
.dcn-center { pointer-events: auto; width: min(400px, calc(100vw - 32px)); max-height: 60vh; display: none; flex-direction: column; background: #FFFEFC; color: #292621; border: 1px solid #E5DDD2; border-radius: 14px; box-shadow: 0 12px 34px rgba(41, 38, 33, .18); overflow: hidden; }
.dcn-center.on { display: flex; }
.dcn-center-head { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-bottom: 1px solid #E5DDD2; font-weight: 700; font-size: 13px; }
.dcn-center-body { overflow: auto; padding: 6px; }
.dcn-item { display: flex; gap: 8px; align-items: flex-start; padding: 8px; border-radius: 10px; border: 1px solid transparent; }
.dcn-item:hover { background: #F7F5F0; border-color: #E5DDD2; }
.dcn-item .b { flex: 1; min-width: 0; }
.dcn-item .p { color: #756D63; font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dcn-item .later { font-size: 10.5px; color: #b7791f; }
.dcn-empty { color: #756D63; padding: 18px; text-align: center; font-size: 12.5px; }
.dcn-prefs { display: flex; gap: 8px; flex-wrap: wrap; padding: 8px 12px; border-top: 1px solid #E5DDD2; font-size: 11.5px; color: #756D63; align-items: center; }
.dcn-prefs label { display: inline-flex; align-items: center; gap: 4px; cursor: pointer; }
body.dark .dcn-pop, body.dark .dcn-center, body.dark .dcn-bell { background: #1c2030; color: #f5f1ea; border-color: rgba(245, 241, 234, .10); }
body.dark .dcn-preview, body.dark .dcn-tabs, body.dark .dcn-item:hover { background: #161922; border-color: rgba(245, 241, 234, .10); }
body.dark .dcn-reply textarea { background: #161922; color: #f5f1ea; border-color: rgba(245, 241, 234, .14); }
body.dark .dcn-btn { color: #f5f1ea; border-color: rgba(245, 241, 234, .14); }
body.dark .dcn-meta, body.dark .dcn-status, body.dark .dcn-item .p, body.dark .dcn-empty, body.dark .dcn-prefs { color: #b3ada1; }
@media (max-width: 760px) { #dcn-root { left: 68px; bottom: 8px; } .dcn-pop { width: calc(100vw - 16px); } }
@media (prefers-reduced-motion: reduce) { .dcn-pop, .dcn-pop.leaving { animation: none; } .dcn-btn, .dcn-bell { transition: none; } }
