/* App-specific styling only. Colours, spacing and controls come from /kit/kit.css -- change the theme colour here, never the kit. */
:root { --accent: #1f8a9e; }

/* one screen, no navigation rail or tab bar */
.app { grid-template-columns: 1fr; grid-template-rows: auto 1fr; grid-template-areas: "bar" "main"; }
.app-nav { display: none; }
.app-bar .who { margin-left: auto; }
.app-bar .chip.me { background: rgba(255,255,255,.16); border-color: transparent; color: inherit; max-width: 40vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.board { max-width: 680px; margin: 0 auto; display: flex; flex-direction: column; gap: var(--gap); }
.signin { display: flex; }
.composer { display: flex; flex-direction: column; gap: var(--gap); transition: outline-color .1s; }
.composer.drop { outline: 2px dashed var(--accent); outline-offset: 2px; }
.composer textarea { width: 100%; resize: vertical; min-height: 4.2em; max-height: 40vh; }
.composer .bar { min-height: var(--ctl-h); }
.count { font-size: .82em; white-space: nowrap; }

.thumbs { display: flex; flex-wrap: wrap; gap: var(--gap); }
.thumbs:empty { display: none; }
.thumb { position: relative; width: 84px; height: 84px; border-radius: 6px; overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb.uploading img { opacity: .45; }
.thumb.error { border-color: var(--danger); }
.thumb .rm { position: absolute; top: 2px; right: 2px; width: 24px; min-width: 24px; height: 24px; padding: 0; background: rgba(0,0,0,.6); color: #fff; border: 0; border-radius: 50%; }
.thumb .rm svg { width: 14px; height: 14px; }
@media (pointer: coarse) { .thumb .rm { width: 32px; height: 32px; } }
.thumb .err { position: absolute; left: 4px; bottom: 4px; background: var(--danger); color: #fff; border-radius: 50%; width: 20px; height: 20px; display: grid; place-items: center; font-weight: 700; }
.thumb .spin { position: absolute; left: calc(50% - 10px); top: calc(50% - 10px); width: 20px; height: 20px; border: 3px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: nbspin .8s linear infinite; }
@keyframes nbspin { to { transform: rotate(360deg); } }

.newpill { position: sticky; top: 0; z-index: 5; display: none; justify-content: center; }
.newpill.on { display: flex; }
.feed { display: flex; flex-direction: column; gap: var(--gap); }
.post > header { margin-bottom: 4px; }
.post time { font-size: .82em; white-space: nowrap; }
.post .btn.danger { min-height: 24px; height: 24px; padding: 0 8px; font-size: .85em; }
.post .text { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.4; }
.imgs { display: grid; gap: 4px; margin-top: 6px; grid-template-columns: 1fr 1fr; }
.imgs.n1 { grid-template-columns: 1fr; }
.imgs a { display: block; overflow: hidden; border-radius: 6px; background: var(--surface-2); }
.imgs img { display: block; width: 100%; height: auto; max-height: 420px; object-fit: contain; }
.imgs:not(.n1) img { aspect-ratio: 1 / 1; object-fit: cover; max-height: none; }
.more { display: flex; justify-content: center; padding: 4px 0 12px; }
