/* pulsorb.app/messages and /account: what the website needs on top of the Messages screens' own
   stylesheet (src/renderer/social/social.css, which comes later in the cascade, so these rules
   carry body[data-page] to win). A normal page header instead of the app's title bar, and on
   phones one column: the chat list, or the open chat (bridge.js sets data-view). */

body[data-page] { grid-template-rows: 52px minmax(0, 1fr); height: 100dvh; }
body[data-page] .titlebar { height: 52px; padding: 0 16px; gap: 16px; -webkit-app-region: no-drag; border-bottom: 1px solid var(--line, rgba(255, 255, 255, 0.08)); }
body[data-page] .brand { color: inherit; text-decoration: none; font-size: 15px; }
body[data-page] .brand-logo { width: 22px; height: 22px; }
body[data-page] .web-links { display: flex; gap: 4px; margin-left: auto; }
body[data-page] .web-links a { padding: 6px 12px; border-radius: 999px; color: var(--text-muted, #a3abbc); font-size: 13.5px; font-weight: 600; text-decoration: none; }
body[data-page] .web-links a:hover { color: var(--text, #f1f3f8); background: rgba(255, 255, 255, 0.06); }
body[data-page="messages"] .web-links a[href="/messages"],
body[data-page="account"] .web-links a[href="/account"] { color: var(--text, #f1f3f8); background: rgba(255, 255, 255, 0.08); }

@media (max-width: 760px) {
  body[data-page] .titlebar { padding: 0 10px; gap: 8px; }
  body[data-page] .brand-sub, body[data-page] .web-links a[href="/"] { display: none; }
  body[data-page] .web-links a { padding: 6px 10px; }
  body[data-page] .shell { grid-template-columns: minmax(0, 1fr); }
  html:not([data-view="pane"]) body[data-page] .pane-wrap { display: none; }
  html[data-view="pane"] body[data-page] .sidebar { display: none; }
  body[data-page] .phone-back { display: inline-flex; margin-right: 2px; }
  body[data-page] .profile-panel { width: 100%; border-left: 0; }
  /* A Settings row with two buttons puts them under its text, which keeps the row's width. */
  body[data-page] .card-row:has(> .row-buttons) { flex-wrap: wrap; }
  body[data-page] .card-row > .row-buttons { flex-basis: 100%; justify-content: flex-start; padding-left: 44px; }
  /* A sign-in's two days, one under the other (Where you're logged in). */
  body[data-page] .signin-days span { display: block; }
  body[data-page] .signin-days .signin-dot { display: none; }
  body[data-page] .crop-dialog, body[data-page] .crop-dialog.wide { width: calc(100vw - 24px); }
  body[data-page] .crop-dialog.wide .crop-frame, body[data-page] .crop-dialog.wide .crop-canvas { width: calc(100vw - 72px) !important; height: calc((100vw - 72px) / 3) !important; }
}
