html, body { max-width: 100%; overflow-x: hidden; }
.search { display: grid; grid-template-columns: 1fr auto; gap: 0; margin-bottom: 14px; }
.search input { min-width: 0; border-right: 0; }
.search button { padding-inline: 14px; }
.topic-actions { display: flex; align-items: center; gap: 28px; margin-top: 13px; color: var(--muted); font-size: 13px; }
.topic-actions a:hover { color: var(--blue); }
.topic-card { grid-template-columns: 48px minmax(0, 1fr); }
.topic-card h2, .topic-card p { overflow-wrap: anywhere; }
.section-title { display: flex; align-items: center; justify-content: space-between; height: auto; min-height: 58px; }
.feed-search { display: none; grid-template-columns: minmax(0, 1fr) auto; gap: 0; width: 210px; }
.feed-search input, .feed-search button { padding: 8px 10px; }

@media (min-width: 761px) and (max-width: 1100px) {
  main { width: calc(100vw - 88px); }
  .home-grid { grid-template-columns: minmax(0, 600px) minmax(280px, 390px); }
}

@media (max-width: 760px) {
  header { top: 0; bottom: auto; height: 56px; }
  .header-inner { height: 56px; display: flex; flex-direction: row; align-items: center; gap: 8px; }
  .header-inner::before { display: grid; width: 42px; height: 42px; margin: 0; font-size: 25px; }
  .header-inner nav { display: none; }
  .account-wrap, .auth-links { display: flex; margin: 0 0 0 auto; }
  .account-button { width: 46px; height: 46px; padding: 2px; }
  .account-button .avatar { width: 40px; height: 40px; }
  .account-button .account-name, .account-button .inbox, .account-button > .icon { display: none; }
  .account-menu { display: none; position: fixed; left: auto; right: 8px; top: 52px; bottom: auto; width: min(260px, calc(100vw - 16px)); }
  .account-menu.open { display: grid; }
  .auth-links a { display: block; width: auto; font-size: 13px; padding: 8px 12px; }
  .auth-links .tonal::after { content: none; }
  .create-button { right: 16px; bottom: 18px; width: 54px; height: 54px; }
  main { padding-top: 56px; }
  .welcome { padding-top: 64px; }
  .welcome::before { position: absolute; }
  .welcome { display: block !important; min-height: 205px; padding: 78px 16px 18px !important; color: #e7e9ea !important; }
  .welcome::before { z-index: 0; }
  .welcome > div, .welcome h1, .welcome p, .welcome > a { visibility: visible !important; opacity: 1 !important; }
  .welcome > div, .welcome > a { position: relative; z-index: 1; }
  .welcome h1 { font-size: 20px; line-height: 1.35; margin: 0 0 5px; }
  .welcome p { margin: 0 0 13px; }
  .feed-search { display: grid; width: 150px; }
  .section-title h2 { font-size: 18px; }
  .topic-card { padding: 12px; gap: 10px; }
  .topic-card .avatar { width: 40px; height: 40px; }
  .topic-actions { gap: 22px; }
}

