.im-page{max-width:1120px;margin:auto;padding:20px;box-sizing:border-box}.im-page *,.im-dialog *{box-sizing:border-box}.im-top{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.im-top h1{margin:0}.im-top>div{flex:1;min-width:200px}.im-tabs,.im-actions,.im-filters{display:flex;gap:8px;flex-wrap:wrap;margin:16px 0}.im-tabs .on{background:var(--accent,#247655);color:white}.im-filters input[type=search]{min-width:180px;flex:1}.im-filters label{display:flex;align-items:center;gap:6px}.im-list{display:grid;gap:10px}.im-row{display:flex;width:100%;text-align:left;flex-direction:column;gap:6px;padding:14px;white-space:normal;overflow-wrap:anywhere}.im-row>span{font-weight:normal}.im-letter{margin-top:16px;padding:18px;border:1px solid var(--line,#6c7c78);border-radius:12px;overflow-wrap:anywhere}.im-letter h3{margin-top:0;white-space:pre-wrap}.im-text{white-space:pre-wrap;overflow-wrap:anywhere;margin:18px 0;line-height:1.55}.im-recipients{font-size:.9em;margin-top:8px}.im-files,.im-file{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.im-files{flex-direction:column;align-items:stretch}.im-file{padding:10px;border:1px solid var(--line,#6c7c78);border-radius:8px;margin:8px 0;overflow-wrap:anywhere}.im-file button{white-space:normal;overflow-wrap:anywhere;max-width:100%}.im-compose{display:grid;gap:14px;margin-top:20px}.im-compose>label{display:grid;gap:6px}.im-compose>label:first-of-type{display:flex;align-items:center}.im-compose input[type=text],.im-compose input[type=search],.im-compose textarea{width:100%;min-width:0}.im-compose textarea{resize:vertical;line-height:1.5;font:inherit}.im-people{display:flex;flex-wrap:wrap;gap:8px;max-height:220px;overflow:auto;border:1px solid var(--line,#6c7c78);padding:12px}.im-people label{display:flex;align-items:center;gap:7px;padding:6px;overflow-wrap:anywhere;white-space:normal}.im-notice{white-space:pre-wrap;overflow-wrap:anywhere;margin:10px 0}.im-thread{margin:16px 0}.im-thread article{border-top:1px solid var(--line,#6c7c78);padding:12px}.im-overlay{position:fixed;inset:0;z-index:100000;background:#000b;display:flex;justify-content:center;align-items:center;padding:18px}.im-dialog{width:min(850px,100%);max-height:calc(100dvh - 36px);display:flex;flex-direction:column;border-radius:16px;background:var(--panel-solid,#fff);color:var(--text,#1d1d1f);box-shadow:0 16px 70px #0009;border:1px solid #657d6e;overflow:hidden}.im-dialog header{padding:18px 22px 0}.im-dialog header h2{margin:0}.im-dialog-scroll{overflow:auto;overscroll-behavior:contain;padding:0 22px 18px;min-height:0}.im-dialog footer{flex-shrink:0;padding:12px 22px 18px;border-top:1px solid #657d6e;display:flex;gap:12px;flex-wrap:wrap;align-items:center}.im-dialog footer p{width:100%;margin:0;overflow-wrap:anywhere}.im-dialog button{min-height:44px;white-space:normal}.im-dialog .im-letter{padding:12px}.im-dialog-scroll:focus{outline:2px solid #5bbd82}.im-phone-shell{min-height:100dvh}.im-phone-shell>a{display:inline-block;padding:12px}.im-page button,.im-page input{min-height:40px}.im-page input[type=checkbox]{min-height:20px}.im-compose [data-im-progress]{overflow-wrap:anywhere}
@media(max-width:600px){.im-page{padding:12px}.im-top h1{font-size:24px}.im-top>div{width:100%;flex-basis:100%}.im-top button{flex:1}.im-tabs button{flex:1;padding:8px}.im-tabs{gap:5px}.im-filters{align-items:stretch}.im-filters input[type=search]{width:100%;flex-basis:100%}.im-filters label{flex:1}.im-overlay{padding:8px}.im-dialog{max-height:calc(100dvh - 16px);border-radius:12px}.im-dialog header{padding:14px 14px 0}.im-dialog header h2{font-size:23px}.im-dialog-scroll{padding:0 12px 12px}.im-dialog footer{padding:10px 12px}.im-dialog footer button{flex:1}.im-file{align-items:flex-start;flex-direction:column}.im-actions>button{flex:1;min-width:120px}.im-people{max-height:180px}.im-compose .im-actions{position:sticky;bottom:0;background:var(--panel-solid,#fff);padding:10px 0;z-index:2}}

.im-preview-wrap{width:100%;flex-basis:100%;padding:8px;border:1px solid var(--line,#6c7c78);border-radius:8px}.im-preview-frame{display:block;width:100%;height:min(65vh,700px);min-height:320px;border:0;background:#eee}.im-preview-wrap>p{overflow-wrap:anywhere}@media(max-width:600px){.im-preview-frame{height:55dvh;min-height:260px}}

.im-urgent{display:inline-block;background:#9e2020;color:#fff;padding:4px 10px;border-radius:5px;margin-right:8px}.im-deadline{display:inline-block;margin:5px 0;overflow-wrap:anywhere}.im-letter-options,.im-group-add{display:flex;gap:12px;align-items:end;flex-wrap:wrap}.im-letter-options label,.im-group-add label{display:grid;gap:6px}.im-own-task{border:1px solid var(--line,#6c7c78);padding:14px;border-radius:10px;margin:12px 0;overflow-wrap:anywhere}.im-page select,.im-page input[type=datetime-local]{min-height:44px;max-width:100%}.im-page [data-im-signature]{display:block;width:100%;font:inherit;margin:10px 0}.im-page [data-im-group-name]{max-width:100%}@media(max-width:600px){.im-group-add>*{width:100%}.im-letter-options{align-items:stretch}.im-letter-options>*{max-width:100%}}

.im-recalled{display:inline-block;padding:5px 10px;margin:5px 0;border:1px solid var(--line,#6c7c78);border-radius:5px;background:#eadcc2;color:#3b2d17}

.im-recall-confirm{flex-basis:100%;padding:12px;border:1px solid #a77b3b;border-radius:8px;background:#fff5df;color:#332813}.im-recall-confirm[hidden]{display:none}.im-recall-confirm button{margin:4px}.im-recall-confirm p{overflow-wrap:anywhere}
