/* Suggestions (October 23, Elvis's design): the header's control, highlights in the text, cards in
   a margin beside the text from 900px wide and in a sheet along the bottom below that, and the
   review page's shared pieces. */
:root { --sg-w: clamp(280px, 26vw, 344px); --sg-sheet: min(55vh, 560px); --sg-hl: #FDF0C4; --sg-hl-on: #F8D96B; --sg-del: #B3261E; --sg-ins: #146C43; }

/* The control (October 26): one button naming the mode, as in Docs, each mode its own color: Reading
   plain, Commenting dark, Suggesting green (the color of suggested text); the count of open
   suggestions in a pill; the arrow says it opens a menu. */
.sg-controls { display: inline-flex; align-items: center; gap: 8px; }
.site-head .btn.suggest.sg-modes, .site-head.compact .btn.suggest.sg-modes { display: inline-flex; align-items: center; gap: 7px; padding: 0 11px 0 14px; font-size: 14px; cursor: pointer; }
.sg-modes .sg-modeicon { display: inline-flex; }
.sg-modes .sg-label { display: inline-grid; }
.sg-modes .sg-label > span { grid-area: 1 / 1; visibility: hidden; text-align: left; }
.sg-modes[data-mode="read"] [data-m="read"], .sg-modes[data-mode="comment"] [data-m="comment"], .sg-modes[data-mode="suggest"] [data-m="suggest"] { visibility: visible; }
.sg-modes svg { width: 15px; height: 15px; flex: none; }
.sg-modes > svg { width: 13px; height: 13px; opacity: .65; }
.sg-modes .sg-count { padding: 1px 7px; border-radius: 999px; background: rgba(14, 17, 22, .08); font-size: 12.5px; font-variant-numeric: tabular-nums; line-height: 18px; }
.sg-modes .sg-count[hidden] { display: none; }
.site-head .btn.suggest.sg-modes[data-mode="comment"], .site-head .btn.suggest.sg-modes[data-mode="comment"]:hover { background: var(--ink); color: #FFFFFF; }
.site-head .btn.suggest.sg-modes[data-mode="suggest"], .site-head .btn.suggest.sg-modes[data-mode="suggest"]:hover { background: var(--sg-ins); color: #FFFFFF; }
.sg-modes:is([data-mode="comment"], [data-mode="suggest"]) .sg-count { background: rgba(255, 255, 255, .18); }
.sg-modes:focus-visible { outline: 2px solid var(--escape); outline-offset: 2px; }
/* Below 900px: the icon, the count and the arrow; the mode's name stays in the button's label for
   screen readers, and in the menu. */
@media (max-width: 899px) {
  .sg-modes .sg-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .site-head .btn.suggest.sg-modes { gap: 6px; padding: 0 9px 0 12px; }
  .sg-controls { gap: 6px; }
}
@media (max-width: 480px) {
  .site-head .btn.suggest.sg-modes { gap: 5px; padding: 0 8px 0 10px; }
  .sg-controls { gap: 5px; }
}

/* Its options. */
.sg-menu { position: fixed; z-index: 60; width: 310px; padding: 6px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 18px 40px -18px rgba(14, 17, 22, .45); font-size: 14px; }
.sg-menu[hidden] { display: none; }
.sg-menu label, .sg-menu button, .sg-menu a { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 40px; padding: 8px 10px; border: 0; border-radius: 9px; background: none; color: var(--ink); font: inherit; text-align: left; text-decoration: none; cursor: pointer; }
.sg-menu label:hover, .sg-menu button:hover, .sg-menu a:hover { background: var(--hover); }
.sg-menu input { width: 16px; height: 16px; margin: 0; accent-color: var(--ink); }
.sg-menu hr { margin: 6px 4px; border: 0; border-top: 1px solid var(--line); }
.sg-menu .sg-who { display: flex; align-items: center; gap: 10px; padding: 8px 10px; color: var(--ink-2); font-size: 13px; line-height: 1.35; }

/* The modes in the menu: icon, name and a line on what it does; the current one ticked. */
.sg-menu .sg-mode-item { align-items: flex-start; }
.sg-menu .sg-mode-item > svg { width: 16px; height: 16px; margin-top: 2px; flex: none; }
.sg-menu .sg-mode-item span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.sg-menu .sg-mode-item small { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.sg-menu .sg-mode-item[aria-checked="true"] { background: var(--hover); }
.sg-menu .sg-mode-item[data-mode="suggest"] > svg:first-child { color: var(--sg-ins); }

/* A first-time tip under the header. */
.sg-tip { position: fixed; z-index: 55; left: 50%; transform: translateX(-50%); top: calc(var(--head-h, 64px) + 12px); display: flex; align-items: center; gap: 12px; max-width: calc(100vw - 32px); padding: 10px 10px 10px 16px; border-radius: 999px; background: var(--ink); color: #FFFFFF; font-size: 14px; box-shadow: 0 12px 30px -14px rgba(14, 17, 22, .6); }
.sg-tip button { border: 0; border-radius: 999px; padding: 6px 12px; background: rgba(255, 255, 255, .14); color: inherit; font: inherit; font-weight: 600; cursor: pointer; }

/* In the text. While suggesting, links don't open (as in Docs), so their text can be selected. */
html.sg-on main a { cursor: text; -webkit-user-drag: none; }
html.sg-on .card .go::after { pointer-events: none; }
html.sg-on main ::selection { background: #B9D3FB; }
/* Suggested text may be one long run (a pasted link, or several suggestions in one place): it breaks
   anywhere rather than widening the page, which on a phone zoomed the whole page out. */
mark.sg-hl, mark.sg-pend, mark.sg-draft, ins.sg-ins, .sg-card { overflow-wrap: anywhere; }
mark.sg-hl { background: var(--sg-hl); color: inherit; border-bottom: 2px solid #E8C04A; border-radius: 2px; cursor: pointer; }
mark.sg-hl.on { background: var(--sg-hl-on); }
mark.sg-hl.sg-del { background: none; border: 0; color: var(--sg-del); text-decoration: line-through; text-decoration-thickness: 1.5px; }
mark.sg-hl.sg-del.on { background: #FBE3E1; }
mark.sg-hl.sg-gone { background: none; border-bottom: 2px dashed var(--sg-del); }
ins.sg-ins { color: var(--sg-ins); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 2px; background: #E4F4EA; border-radius: 2px; cursor: pointer; }
mark.sg-draft { background: #DCE8FD; color: inherit; border-bottom: 2px solid #4C82E8; }

/* Beside a selection: comment and suggest edit, as round buttons in the margin (Docs' place for
   them), or in a row under the selection when there is no margin. */
.sg-add { position: absolute; z-index: 58; display: flex; flex-direction: column; gap: 6px; }
.sg-add.row { flex-direction: row; padding: 4px; border-radius: 999px; background: var(--surface); box-shadow: 0 8px 24px -10px rgba(14, 17, 22, .45); border: 1px solid var(--line); }
.sg-add[hidden] { display: none; }
.sg-add button { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--ink); box-shadow: 0 4px 14px -8px rgba(14, 17, 22, .45); cursor: pointer; }
.sg-add.row button { border: 0; box-shadow: none; width: 40px; height: 40px; }
.sg-add button:hover, .sg-add button:focus-visible { background: var(--hover); outline: none; }
.sg-add svg { width: 17px; height: 17px; }

/* Suggesting: the page is editable, as a document in Docs' suggesting mode. */
html.sg-on main[contenteditable] { outline: none; caret-color: #1A6B3C; }
mark.sg-pend { background: none; color: var(--sg-del); text-decoration: line-through; text-decoration-thickness: 1.5px; }
ins.sg-typing { min-width: 2px; outline: none; padding: 0 2px; border-radius: 3px; background: #E4F4EA; box-shadow: inset 0 0 0 1px #9BD3B0; }
/* Empty, the box says what goes in it (after the caret, which sits at its start). */
ins.sg-typing[data-empty]::after { content: "new text"; color: #5E9A78; font-style: italic; pointer-events: none; }
.sg-turnstile { position: fixed; z-index: 70; left: 16px; bottom: 16px; }
.sg-turnstile:empty { display: none; }

/* The margin (from 900px, and on short landscape screens; suggest.js decides): the page narrows to make room, so nothing is covered, and the cards
   sit level with their text under a header of their own. */
html.sg-wide body { padding-right: var(--sg-w); }
.sg-margin { position: absolute; top: 0; right: 0; width: var(--sg-w); pointer-events: none; border-left: 1px solid var(--line); }
.sg-margin .sg-card { position: absolute; left: 14px; right: 18px; pointer-events: auto; transition: top .18s ease, transform .18s ease; }
.sg-margin .sg-card.on { transform: translateX(-8px); }
/* Nothing yet (October 26, Elvis: as a white box it looked like a text field): plain text in the margin, as in the sheet. */
.sg-margin .sg-empty-card { top: calc(var(--head-h, 64px) + 64px); padding: 0 4px; background: none; border: 0; box-shadow: none; }
@media (prefers-reduced-motion: reduce) { .sg-margin .sg-card { transition: none; } }
.sg-phead { display: flex; align-items: center; gap: 4px; padding: 10px 8px 10px 16px; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); pointer-events: auto; }
.sg-phead h2 { flex: 1; font-size: 15px; font-weight: 650; letter-spacing: -0.02em; }
/* Level with the site's header, as one bar across the top (October 26, Elvis: under the header it left a
   gap that cards scrolled through), and solid, so cards scrolling under it don't show through. */
.sg-margin > .sg-phead { position: sticky; top: 0; z-index: 3; box-sizing: border-box; min-height: var(--head-h, 64px); padding-block: 0; background: var(--paper); border-bottom: 1px solid var(--line); }
/* Room before the footer for the cards below the end of the text (suggest.js sets --sg-room), so the
   footer comes after the last card rather than among them (October 26). */
html.sg-wide .site-foot { margin-top: calc(88px + var(--sg-room, 0px)); }
/* Under a header of two rows (a phone on its side, a narrow window), the title sits level with the
   top row, the wordmark's, rather than between the two. */
html:has(.site-head.two-row) .sg-margin > .sg-phead { padding-bottom: calc(var(--head-h, 64px) - 56px); }
.sg-x { display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 999px; background: none; color: var(--ink-2); cursor: pointer; flex: none; }
.sg-x svg { width: 17px; height: 17px; }
.sg-x:hover { background: var(--hover); color: var(--ink); }

/* The sheet (otherwise): along the bottom, about half the screen, no backdrop; the page above
   stays usable and gains room at its end so nothing stays hidden behind the sheet. */
html.sg-sheet body { padding-bottom: var(--sg-sheet); }
.sg-drawer { position: fixed; z-index: 57; left: 0; right: 0; bottom: 0; height: var(--sg-sheet); display: flex; flex-direction: column; background: var(--paper); border-top: 1px solid var(--line); border-radius: 18px 18px 0 0; box-shadow: 0 -18px 40px -26px rgba(14, 17, 22, .5); }
.sg-drawer[hidden] { display: none; }
.sg-drawer > .sg-phead { border-bottom: 1px solid var(--line); border-radius: 18px 18px 0 0; padding-left: 18px; }
.sg-drawer .sg-list { flex: 1; overflow-y: auto; padding: 12px 14px calc(14px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 10px; overscroll-behavior: contain; }
.sg-empty { margin: 4px 2px; color: var(--ink-2); font-size: 14px; line-height: 1.55; }

/* A card: one suggestion and its thread. */
.sg-card { padding: 12px 14px 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 1px 2px rgba(14, 17, 22, .05); font-size: 13.5px; line-height: 1.45; color: var(--ink); cursor: default; }
.sg-card.on { border-color: var(--line-2); box-shadow: 0 14px 34px -18px rgba(14, 17, 22, .5); z-index: 2; }
.sg-card.sg-done { opacity: .78; }
.sg-card.sg-done.on { opacity: 1; }
.sg-by { display: flex; align-items: center; gap: 9px; }
.sg-by .sg-name { font-weight: 600; font-size: 13.5px; }
.sg-by .sg-when { display: block; color: var(--muted); font-size: 12px; }
.sg-av { flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; font-size: 12.5px; font-weight: 700; }
.sg-av.ed { background: var(--ink); color: #FFFFFF; }
/* A role (October 25): a small pill beside the name, drawn from the database's role, never from the
   name itself, so a display name like "Elvis · editor" reads as the plain text it is. */
.sg-role { display: inline-flex; align-items: center; gap: 3px; height: 18px; margin-left: 6px; padding: 0 7px 0 5px; border-radius: 999px; background: #E3EBFD; border: 1px solid #BCCDF5; color: #1E3A8A; font: 700 11px/1 var(--sans); letter-spacing: .01em; vertical-align: 1px; white-space: nowrap; }
.sg-role svg { width: 11px; height: 11px; flex: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .sg-role { background: #1A2744; border-color: #2D4374; color: #BFD2FF; } }
:root[data-theme="dark"] .sg-role { background: #1A2744; border-color: #2D4374; color: #BFD2FF; }
.sg-badges { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.sg-badge { display: inline-block; padding: 2px 8px; border-radius: 999px; background: var(--hover); border: 1px solid var(--line); color: var(--ink-2); font-size: 11.5px; font-weight: 600; }
.sg-badge.held { background: #FFF6DB; border-color: #F1DC9A; color: #7A5A00; }
.sg-badge.accepted, .sg-badge.modified { background: #E4F4EA; border-color: #BFE3CC; color: #146C43; }
.sg-badge.rejected { background: #FBE9E7; border-color: #F3C9C4; color: #9D2A20; }
.sg-what { margin-top: 8px; color: var(--ink-2); }
.sg-what del { color: var(--sg-del); text-decoration-thickness: 1.5px; }
.sg-what ins { color: var(--sg-ins); text-decoration: none; background: #E4F4EA; border-radius: 2px; padding: 0 2px; }
.sg-what b { color: var(--ink); font-weight: 600; }
.sg-body { margin-top: 6px; white-space: pre-wrap; overflow-wrap: anywhere; }
.sg-quote { margin-top: 8px; padding-left: 9px; border-left: 2px solid var(--line-2); color: var(--muted); font-size: 12.5px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.sg-decision { margin-top: 8px; padding: 8px 10px; border-radius: 9px; background: var(--hover); font-size: 13px; }
.sg-decision b { font-weight: 600; }
.sg-replies { margin-top: 10px; display: flex; flex-direction: column; gap: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.sg-replies .sg-av { width: 24px; height: 24px; font-size: 11px; }
.sg-replies .sg-body { margin-left: 33px; margin-top: 2px; }
.sg-row { display: flex; align-items: center; gap: 6px; margin-top: 10px; }
.sg-grow { flex: 1; }
.sg-who { flex: 1; min-width: 0; }
.sg-av.anon { background: var(--hover); color: var(--muted); border: 1px dashed var(--line-2); }
.sg-icon { display: grid; place-items: center; width: 28px; height: 28px; margin: -4px -6px 0 0; border: 0; border-radius: 50%; background: none; color: var(--muted); cursor: pointer; flex: none; }
.sg-icon:hover { background: var(--hover); color: var(--ink); }
.sg-icon svg { width: 15px; height: 15px; }
.sg-btn { display: inline-flex; align-items: center; justify-content: center; height: 32px; padding: 0 14px; border: 0; border-radius: 999px; background: none; color: var(--ink); font: 600 13px/1 var(--sans); cursor: pointer; text-decoration: none; }
.sg-btn.ink { background: var(--ink); color: #FFFFFF; }
.sg-btn.ink:hover { opacity: .88; }
.sg-btn:disabled { opacity: .35; cursor: default; }
.sg-btn.quiet { color: var(--ink-2); padding: 0 10px; }
.sg-btn.quiet:hover { color: var(--ink); background: var(--hover); }
.sg-link { color: var(--ink-2); font-size: 12.5px; }
.sg-inline { color: inherit; text-decoration: underline; }
/* The text box: borderless until you are in it, growing with what you type. */
.sg-input { display: block; width: 100%; margin-top: 10px; padding: 8px 11px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--ink); font: 14px/1.45 var(--sans); resize: none; overflow: hidden; min-height: 38px; }
.sg-input:focus { outline: none; border-color: #4C82E8; background: var(--surface); box-shadow: 0 0 0 1px #4C82E8; }
.sg-input::placeholder { color: var(--muted); }
.sg-reply:not(.open) .sg-row { display: none; }
/* Reply and Review show on the picked card only (October 26: a box on every card made a crowded page
   several times longer), as in Docs. They stay in the tab order, out of sight, and show when tabbed to. */
.sg-card:not(.on):not(:focus-within) :is(.sg-reply:not(.open), .sg-review) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
/* Public or private: a small toggle in the card. */
.sg-chip { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 9px 0 7px; border: 0; border-radius: 999px; background: var(--hover); color: var(--ink-2); font: 600 12px/1 var(--sans); cursor: pointer; }
.sg-chip:hover { color: var(--ink); background: var(--line); }
.sg-chip[aria-pressed="true"] { background: #FFF6DB; color: #7A5A00; }
.sg-chip svg { width: 13px; height: 13px; }
.sg-what.muted { color: var(--muted); }
.sg-what b { font-weight: 600; color: var(--ink); }
.sg-badge svg { width: 11px; height: 11px; margin: 0 3px -1px 0; }
.sg-note { margin-top: 8px; color: var(--muted); font-size: 12.5px; line-height: 1.45; }
.sg-error { margin-top: 6px; color: #9D2A20; font-size: 13px; }
.sg-error:empty { display: none; }
.sg-toast { position: fixed; z-index: 70; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translateX(-50%); max-width: calc(100vw - 32px); padding: 12px 18px; border-radius: 12px; background: var(--ink); color: #FFFFFF; font-size: 14px; box-shadow: 0 12px 30px -12px rgba(14, 17, 22, .6); }
.sg-toast a { color: inherit; }

/* First-time public posters (October 24): their post waits for the editor, and the card says so
   until dismissed. The first time, the note slides in and glows twice so it is noticed. */
.sg-held-note { display: flex; align-items: flex-start; gap: 7px; margin: 10px 0 0; padding: 7px 4px 7px 9px; border-radius: 10px; background: #FFF6DB; border: 1px solid #F1DC9A; color: #7A5A00; font-size: 12.5px; line-height: 1.4; }
.sg-held-note[hidden] { display: none; }
.sg-held-note > svg { flex: none; width: 14px; height: 14px; margin-top: 1px; }
.sg-held-note > span { flex: 1; }
.sg-held-note .sg-icon { width: 22px; height: 22px; margin: -3px 0 -3px 0; color: inherit; }
.sg-held-note .sg-icon svg { width: 12px; height: 12px; }
.sg-held-note.fresh { animation: sg-held-in .45s ease-out, sg-held-glow 1.2s ease-in-out .45s 2; }
@keyframes sg-held-in { from { opacity: 0; transform: translateY(-6px); } }
@keyframes sg-held-glow { 50% { box-shadow: 0 0 0 4px rgba(232, 192, 74, .45); } }
@media (prefers-reduced-motion: reduce) { .sg-held-note.fresh { animation: none; } }

/* A link clicked while suggesting (October 24): where it goes, and a button to open it. */
.sg-linktip { position: absolute; z-index: 58; display: flex; align-items: center; gap: 10px; max-width: min(440px, calc(100vw - 16px)); padding: 5px 5px 5px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 8px 24px -10px rgba(14, 17, 22, .45); }
.sg-linktip[hidden] { display: none; }
.sg-linktip-url { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); font: 12.5px var(--mono); }
.sg-linktip .sg-btn { flex: none; text-decoration: none; border: 1px solid var(--line-2); }

/* The review page's Preview (October 24): the edit as it would read on the page. */
ins.sg-preview { background: #E4F4EA; color: inherit; text-decoration: none; border-bottom: 2px solid var(--sg-ins); border-radius: 2px; }
del.sg-preview { color: var(--sg-del); text-decoration-thickness: 1px; }
.sg-preview-bar { top: calc(var(--head-h, 64px) + 12px); }

/* Accounts (October 24): the header's Sign in button (your avatar once signed in), the sign-in box
   and the account page. */
.site-head .btn.suggest.sg-account, .site-head.compact .btn.suggest.sg-account { display: inline-flex; align-items: center; gap: 6px; padding: 0 15px 0 13px; border: 0; font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.sg-account svg { width: 15px; height: 15px; flex: none; }
.site-head .btn.suggest.sg-account.in { padding: 0 6px; }
.sg-account.in .sg-av { width: 28px; height: 28px; }
.sg-account:focus-visible { outline: 2px solid var(--escape); outline-offset: -3px; border-radius: 999px; }
.sg-account[hidden] { display: none; }
@media (max-width: 899px) {
  .sg-account .sg-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .site-head .btn.suggest.sg-account { padding: 0 10px; }
  .site-head .btn.suggest.sg-account.in { padding: 0 3px; }
}
@media (max-width: 480px) { .site-head .btn.suggest.sg-account { padding: 0 9px; } }
button.sg-inline { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }

.sg-signin { width: min(400px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; border: 1px solid var(--line); border-radius: 18px; background: var(--paper); color: var(--ink); box-shadow: 0 30px 70px -30px rgba(14, 17, 22, .55); }
.sg-signin::backdrop { background: rgba(14, 17, 22, .32); }
.sg-signin-box { padding: 20px 22px 18px; }
.sg-signin-head { display: flex; align-items: center; justify-content: space-between; margin: -4px -8px 0 0; }
.sg-signin-head h2 { font-size: 20px; letter-spacing: -0.025em; }
.sg-signin-lede { margin: 6px 0 16px; color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.sg-signin-list { display: flex; flex-direction: column; gap: 8px; }
.sg-signin-btn { display: flex; align-items: center; justify-content: center; gap: 10px; height: 44px; padding: 0 16px; border: 1px solid var(--line-2); border-radius: 999px; background: var(--surface); color: var(--ink); font: 600 14.5px/1 var(--sans); text-decoration: none; cursor: pointer; }
.sg-signin-btn:hover { background: var(--hover); }
.sg-signin-btn:disabled { opacity: .5; cursor: default; }
.sg-signin-btn svg { width: 18px; height: 18px; flex: none; }
.sg-signin-new-line { margin: 14px 0 0; color: var(--ink-2); font-size: 14px; text-align: center; }
.sg-signin-new { margin-top: 12px; }
.sg-signin-new[hidden], .sg-signin-new-line[hidden] { display: none; }
.sg-signin-new label { display: block; margin-bottom: 6px; color: var(--ink-2); font-size: 13px; }
.sg-signin-row { display: flex; gap: 8px; }
.sg-signin-row input { flex: 1; min-width: 0; height: 40px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--surface); color: var(--ink); font: 15px var(--sans); }
.sg-signin-row .sg-btn { height: 40px; }
.sg-signin-status { min-height: 0; margin: 10px 0 0; color: var(--sg-del); font-size: 13.5px; line-height: 1.45; }
.sg-signin-status:empty { display: none; }
.sg-signin-fine { margin: 16px 0 0; padding-top: 12px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12.5px; line-height: 1.5; }
/* Links inside the line about you are words in the sentence, not menu rows. */
.sg-menu .sg-who .sg-inline { display: inline; width: auto; min-height: 0; padding: 0; border-radius: 0; color: var(--ink); text-decoration: underline; }
.sg-menu .sg-who .sg-inline:hover { background: none; }

/* Second round (October 24): email first, the avatar's menu. */
.sg-account-menu { width: 260px; }
.sg-account-menu .sg-who b { color: var(--ink); font-weight: 650; }
.sg-signin-back { display: inline-block; margin: 2px 0 10px; color: var(--ink-2); font-size: 13.5px; }
.sg-signin-back[hidden] { display: none; }
.sg-signin-or { display: flex; align-items: center; gap: 12px; margin: 16px 0 6px; color: var(--muted); font-size: 13px; }
.sg-signin-or::before, .sg-signin-or::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
.sg-signin-form { display: flex; flex-direction: column; gap: 6px; }
.sg-signin-label { margin-top: 8px; color: var(--ink-2); font-size: 13px; font-weight: 600; }
.sg-signin-form input { height: 44px; padding: 0 14px; border: 1px solid var(--line-2); border-radius: 12px; background: var(--surface); color: var(--ink); font: 15.5px var(--sans); }
.sg-signin-form input:focus { outline: 2px solid var(--ink); outline-offset: 0; border-color: transparent; }
.sg-signin-form small { color: var(--muted); font-size: 12.5px; }
.sg-signin-go { height: 44px; margin-top: 12px; font-size: 14.5px; }
.sg-signin-who { margin: 0; padding: 10px 14px; border-radius: 12px; background: var(--hover); color: var(--ink); font-size: 14.5px; overflow-wrap: anywhere; }
.sg-signin-form .sg-signin-lede { margin: 0 0 4px; }
.sg-signin-test { margin: 0; padding: 8px 12px; border-radius: 10px; background: #FFF6DB; border: 1px solid #F1DC9A; color: #7A5A00; font-size: 13px; }
.sg-signin-alt { margin: 12px 0 0; color: var(--ink-2); font-size: 13.5px; text-align: center; }
.sg-signin-alt:empty, .sg-signin-alt:has(> [hidden]:only-child) { display: none; }
.sg-signin-box > .sg-signin-head { margin-bottom: 16px; }
/* Third round (October 25): Sign in and Create account as two tabs. */
.sg-signin-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin: 0 0 16px; padding: 4px; border-radius: 12px; background: var(--hover); }
.sg-signin-tabs[hidden] { display: none; }
.sg-signin-tab { height: 34px; border: 0; border-radius: 9px; background: none; color: var(--ink-2); font: 600 14px/1 var(--sans); cursor: pointer; }
.sg-signin-tab[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(14, 17, 22, .12); }
.sg-signin-tab:focus-visible { outline: 2px solid var(--ink); outline-offset: 1px; }
.sg-signin-alt + .sg-signin-alt { margin-top: 6px; }
/* A new entry (October 25): the form reuses the sign-in box; its section picker and text box match
   its inputs. Already listed is a note, not an error. */
.sg-entry { width: min(460px, calc(100vw - 32px)); }
.sg-entry-form select, .sg-entry-form textarea { width: 100%; border: 1px solid var(--line-2); border-radius: 12px; background: var(--surface); color: var(--ink); font: 15.5px var(--sans); }
.sg-entry-form select { height: 44px; padding: 0 10px; }
.sg-entry-form textarea { min-height: 68px; padding: 10px 14px; line-height: 1.45; resize: vertical; }
.sg-entry-form select:focus, .sg-entry-form textarea:focus { outline: 2px solid var(--ink); outline-offset: 0; border-color: transparent; }
.sg-entry-form [aria-invalid="true"] { border-color: var(--sg-del); }
.sg-entry-form [hidden] { display: none; }
.sg-entry-form .sg-row { margin-top: 14px; }
.sg-entry-form .sg-btn { height: 38px; }
.sg-entry-opt { color: var(--muted); font-weight: 500; }
.sg-entry-dup { margin: 2px 0 0; padding: 8px 12px; border-radius: 10px; background: var(--hover); border: 1px solid var(--line); color: var(--ink-2); font-size: 13.5px; line-height: 1.45; }
.sg-entry-dup:empty { display: none; }
.sg-entry-dup a { color: var(--ink); }
.sg-entry .sg-signin-lede { margin-top: 0; }
/* On cards: one line per field. */
.sg-entry-what > div { margin-top: 3px; overflow-wrap: anywhere; }
.sg-entry-what a { color: var(--ink); }
.sg-entry-k { color: var(--muted); }
/* Suggested entries at the end of their section on the resources page, set apart by a dashed tile. */
.sg-pending-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 40px; }
.sg-pending { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 2px 14px; align-items: start; width: 100%; padding: 14px 0; border: 0; border-bottom: 1px dashed var(--line-2); background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.sg-pending b { font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.sg-pending small { font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.sg-pending:hover b { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.sg-pending:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; border-radius: 8px; }
.sg-pending-tile { grid-row: span 2; display: grid; place-items: center; width: 36px; height: 36px; border: 1px dashed var(--line-2); border-radius: 28%; color: var(--muted); font-size: 18px; line-height: 1; }
@media (max-width: 760px) { .sg-pending-list { grid-template-columns: 1fr; } }
