.composer { position: relative; align-items: center; }
.composer-icon { width: 44px; height: 44px; flex: 0 0 44px; padding: 0; border: 0; border-radius: 10px; background: #0f2a44; color: #fff; font-size: 21px; cursor: pointer; box-shadow: inset 0 -2px 0 #0002; }
.composer-icon:hover { background: #123b5d; }
.composer-icon.attach { display: grid; place-items: center; font-size: 24px; line-height: 1; }
.composer-icon.camera { display: grid; place-items: center; font-size: 23px; line-height: 1; background: #c8a24a; color: #07111d; }
.composer-icon.camera:hover { background: #d8b65d; }
.emoji-picker { position: absolute; z-index: 5; left: 15px; bottom: calc(100% + 8px); display: grid; grid-template-columns: repeat(8, 36px); gap: 6px; width: max-content; max-width: calc(100vw - 40px); max-height: min(330px, calc(100dvh - 190px)); overflow-y: auto; overscroll-behavior: contain; padding: 10px; border: 1px solid #e5e7e9; border-radius: 16px; background: #fff; box-shadow: 0 8px 25px #0003; }
.emoji-picker[hidden] { display: none !important; }
.emoji-picker button { display: grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 9px; background: #f0f2f5; font-family: "Apple Color Emoji", "Segoe UI Emoji", sans-serif; font-size: 21px; cursor: pointer; }
.emoji-picker button:hover { background: #dff4ee; }
.attachment-card { display: flex; align-items: center; gap: 9px; margin-top: 7px; padding: 8px; border-radius: 7px; background: #0000000d; font-size: 12px; }
.attachment-card .attachment-icon { display: grid; width: 30px; height: 30px; place-items: center; border-radius: 6px; background: #fff; color: #008069; font-weight: bold; }
.attachment-card span { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attachment-card a { color: #008069; font-weight: bold; text-decoration: none; }
.message a { color: #007d68; text-decoration: underline; }
.message-status { display: block; margin-top: 2px; text-align: right; color: #667781; font-size: 10px; }
.message-status.read { color: #0b79d0; }
.security-code { display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; padding: 3px 7px; border-radius: 999px; background: #0f2a4414; color: #0f2a44; font: 700 10px/1.2 ui-monospace, SFMono-Regular, Consolas, monospace; letter-spacing: .2px; }
.file-selected { max-width: 170px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #008069; font-size: 10px; }
body.dark .emoji-picker { background: #202c33; }
body.dark .attachment-card { background: #ffffff14; }
body.dark .attachment-card .attachment-icon { background: #111b21; }
body.dark .security-code { background: #ffffff14; color: #d8b65d; }
.composer { flex-wrap: wrap; }
.reply-preview { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 10px; border-left: 3px solid #00a884; border-radius: 8px; background: #ffffff; color: #54656f; font-size: 12px; }
.reply-preview[hidden] { display: none; }
.reply-preview button { padding: 0 6px; background: transparent; color: #54656f; font-weight: bold; }
.message { position: relative; }
.message-actions { position: absolute; top: 3px; right: 4px; display: none; width: 24px; height: 24px; padding: 0; border-radius: 50%; background: #00000012; color: #54656f; font-weight: bold; }
.message:hover .message-actions { display: grid; place-items: center; }
.message.selected { outline: 2px solid #00a884; outline-offset: 2px; }
.message-flag { margin-left: 4px; color: #d99b00; }
.message-menu,
.chat-menu { position: fixed; z-index: 30; width: min(270px, calc(100vw - 24px)); padding: 8px; border-radius: 16px; background: #121820; box-shadow: 0 12px 35px #0008; color: #fff; }
.message-menu[hidden],
.chat-menu[hidden] { display: none !important; }
.message-menu button,
.chat-menu button { display: flex; width: 100%; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 10px; background: transparent; color: #fff; text-align: left; font-weight: bold; }
.message-menu button:hover,
.chat-menu button:hover { background: #ffffff18; }
.message-menu button + button,
.chat-menu button + button { border-top: 1px solid #ffffff10; }
.chat-menu button.danger { color: #ffb4ab; }
body.dark .reply-preview { background: #202c33; color: #e9edef; }
.message-info-dialog { width: min(420px, calc(100vw - 28px)); padding: 26px; border: 0; border-radius: 20px; background: #fff; color: #111b21; box-shadow: 0 18px 55px #0005; }
.message-info-dialog::backdrop { background: #0b141acc; }
.message-info-dialog .privacy-badge { display: grid; width: 48px; height: 48px; margin-bottom: 12px; place-items: center; border-radius: 16px; background: #e9f7f3; color: #008069; font-size: 24px; }
.message-info-dialog h2 { margin: 0 0 6px; }
.message-info-dialog .privacy-copy { margin: 0 0 18px; color: #667781; font-size: 13px; }
.message-info-dialog dl { display: grid; gap: 10px; margin: 0 0 18px; }
.message-info-dialog dl div { padding: 10px 12px; border-radius: 12px; background: #f0f2f5; }
.message-info-dialog dt { margin-bottom: 4px; color: #667781; font-size: 11px; font-weight: bold; text-transform: uppercase; }
.message-info-dialog dd { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.action-dialog .dialog-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }
.action-dialog .ghost { padding: 11px 18px; border-radius: 999px; background: #eef2f7; color: #0f2a44; font-weight: 800; }
.action-dialog .primary { width: auto; padding: 11px 20px; border-radius: 999px; }
.choice-list { display: grid; gap: 8px; max-height: min(360px, 55dvh); overflow-y: auto; }
.choice-list button { display: grid; gap: 2px; width: 100%; padding: 12px 14px; border: 1px solid #d7dee8; border-radius: 13px; background: #f8fafc; color: #101820; text-align: left; cursor: pointer; }
.choice-list button:hover { border-color: #c8a24a; background: #fff8e7; }
.choice-list small { color: #64748b; }
body.dark .message-info-dialog { background: #202c33; color: #e9edef; }
body.dark .message-info-dialog dl div { background: #111b21; }
body.dark .action-dialog .ghost,
body.dark .choice-list button { background: #111b21; color: #e9edef; border-color: #33434d; }
body.dark .emoji-picker button { background: #111b21; color: #e9edef; }
@media (max-width: 700px) { .emoji-picker { left: 10px; grid-template-columns: repeat(5, 36px); max-height: min(300px, calc(100dvh - 175px)); } .message-actions { display: grid; place-items: center; } .message-menu, .chat-menu { bottom: 74px; left: 12px !important; top: auto !important; } .security-code { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } }
