.channel-editor-overlay { position: fixed; top: var(--editor-top, 0px); left: 0; right: 0; height: var(--editor-height, 100dvh); z-index: 90; display: grid; background: var(--scrim); } .channel-editor { width: min(100%, 640px); height: 100%; min-height: 0; margin-inline: auto; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; overflow: hidden; color: var(--text-primary); background: var(--background); } .channel-editor__header { min-height: calc(56px + env(safe-area-inset-top)); padding: env(safe-area-inset-top) 14px 0 6px; display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 6px; align-items: center; border-bottom: 1px solid var(--border-subtle); background: var(--surface); } .channel-editor__header h2 { font-size: 16px; line-height: 24px; font-weight: 600; text-align: left; } .channel-editor__close { width: 44px; height: 44px; padding: 0; font-size: 28px; color: var(--text-primary); } .channel-editor__body { min-height: 0; padding: 16px; display: flex; flex-direction: column; gap: 12px; overflow-y: auto; } .channel-editor__context { padding-left: 12px; border-left: 2px solid var(--accent); color: var(--text-secondary); } .channel-editor__context strong { display: block; margin-bottom: 4px; color: var(--text-primary); font-size: 13px; } .channel-editor__context p { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; font-size: 13px; line-height: 18px; overflow-wrap: anywhere; } .channel-editor__context.is-expanded p { display: block; } .channel-editor__context-toggle, .channel-editor__clear { min-height: 44px; padding: 6px 0; color: var(--accent); font-size: 13px; } .channel-editor__input { flex: 1 0 auto; overflow-y: hidden; width: 100%; min-height: 160px; padding: 12px 14px; resize: none; border: 1px solid var(--border-subtle); border-radius: 14px; outline: 0; color: var(--text-primary); background: var(--surface); transition: border-color 160ms ease; font: inherit; font-size: 16px; line-height: 24px; caret-color: var(--accent); } .channel-editor__input::placeholder { color: color-mix(in srgb, var(--text-secondary) 62%, var(--background)); opacity: 1; } .channel-editor__type { display: grid; gap: 6px; color: var(--text-secondary); font-size: 13px; } .channel-editor__input:focus-visible { outline: 0; border-color: var(--accent); } .channel-editor__attachments { display: grid; gap: 8px; } .channel-editor__author { display: flex; align-items: center; gap: 12px; font-size: .875rem; } .channel-editor__author .avatar { width: 40px; height: 40px; min-width: 40px; min-height: 40px; } .channel-editor__context-toggle[hidden] { display: none; } .channel-editor__chain { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; } .channel-editor__chain-item { position: relative; display: grid; grid-template-columns: 40px minmax(0, 1fr); column-gap: 12px; padding-bottom: 16px; } /* Линия от аватара вниз – к следующему звену и к автору ответа. */ .channel-editor__chain-item::after { content: ''; position: absolute; top: 44px; bottom: -2px; left: 19px; border-left: 2px solid var(--border-control); } .channel-editor__chain-item .avatar.channel-editor__chain-avatar { width: 40px; height: 40px; min-width: 40px; min-height: 40px; } .channel-editor__chain-main { min-width: 0; } .channel-editor__chain-head { display: flex; align-items: baseline; gap: 6px; min-height: 22px; } .channel-editor__chain-head strong { font-size: .9375rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .channel-editor__chain-head span { flex-shrink: 0; color: var(--text-secondary); font-size: .875rem; } .channel-editor__chain-main p { margin: 2px 0 0; color: var(--text-primary); font-size: .9375rem; line-height: 1.4375rem; white-space: pre-wrap; overflow-wrap: anywhere; } .channel-editor__author.is-chained { margin-top: -4px; } .channel-editor__attach[hidden], .channel-editor__clear[hidden] { display: none; } .channel-editor__attachment { min-height: 44px; padding: 6px 8px 6px 12px; display: grid; grid-template-columns: minmax(0, 1fr) 44px; align-items: center; gap: 8px; border: 1px solid var(--border-subtle); border-radius: 12px; background: var(--surface); font-size: 13px; } .channel-editor__attachment span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .channel-editor__attachment button { min-width: 44px; min-height: 44px; color: var(--text-secondary); } .channel-editor__error { min-height: 18px; color: var(--danger); font-size: 13px; line-height: 18px; } .channel-editor__footer { min-height: calc(68px + env(safe-area-inset-bottom)); padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; border-top: 1px solid var(--border-subtle); background: var(--background); } .channel-editor__submit { min-height: 44px; padding: 0 18px; border-radius: 22px; } .channel-editor__submit { color: var(--on-accent); background: var(--accent); } .channel-editor__submit:disabled { opacity: 1; color: var(--text-secondary); background: var(--surface-selected); } .channel-editor__footer.has-extra { grid-template-columns: auto minmax(0, 1fr) auto; } .channel-editor__type { display: block; min-width: 0; } .channel-editor__type-select { min-height: 44px; width: auto; max-width: 9.5rem; padding-left: 12px; border-radius: 12px; font-size: .875rem; } .channel-editor__counter { min-width: 0; color: var(--text-secondary); font-size: 12px; text-align: right; } .channel-editor__counter.is-near-limit { color: var(--warning); } @media (min-width: 680px) { .channel-editor-overlay { place-items: center; padding: 24px; } .channel-editor { height: min(760px, 100%); border: 1px solid var(--border-subtle); border-radius: 20px; box-shadow: var(--shadow); } } @media (max-width: 400px) { .channel-editor__footer.has-extra .channel-editor__counter { display: none; } } @media (prefers-reduced-motion: reduce) { .channel-editor-overlay, .channel-editor { animation: none; transition: none; } } .channel-editor__author-text { display: grid; gap: 1px; min-width: 0; } .channel-editor__author-text small { color: var(--text-secondary); font-size: .75rem; } .channel-editor__draft { justify-self: end; color: var(--text-secondary); font-size: .75rem; } .channel-editor__close svg { width: 24px; height: 24px; } /* Поле ввода как в Threads: без рамки, под именем автора, с отступом под аватар; вложения и «прикрепить» – ниже текста. */ .channel-editor__compose { display: grid; gap: 8px; margin: -8px 0 0 52px; } .channel-editor__compose .channel-editor__input { min-height: 48px; padding: 0; border: 0; border-radius: 0; background: transparent; } .channel-editor__compose .channel-editor__input:focus-visible { border: 0; } .channel-editor__tools { display: flex; align-items: center; gap: 4px; margin-left: -10px; } .channel-editor__tools .channel-editor__attach { width: 44px; height: 44px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 50%; background: transparent; color: var(--text-secondary); } .channel-editor__tools .channel-editor__attach:hover { color: var(--text-primary); } .channel-editor__tools .channel-editor__clear { margin-left: auto; } .channel-editor__tools .channel-editor__attach svg { width: 22px; height: 22px; }