/* Shared by the feed and the single-post page: action pills + toast */
/* X-style action row: bare icons with counts, no background. Hover/active only changes color. */
.pills { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 0 -10px; }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border: 0; border-radius: 980px; background: none; color: #8a8a90; font: 500 14px var(--font); letter-spacing: -.01em; font-variant-numeric: tabular-nums; cursor: pointer; transition: color .15s, transform .1s; }
.pill:hover { color: var(--text); }
.pill:active { transform: scale(.94); }
.pill:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.pill svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.pill.on, .pill.on:hover { color: var(--link); }
.pill.on svg { fill: currentColor; }
.pill .n:empty { display: none; }
/* upvote / score / downvote: one group, like Reddit. Up uses the accent, down a soft coral. */
.vote { --down: #e0907f; display: inline-flex; align-items: center; margin-right: 2px; }
.vote .pill { padding: 0 7px; }
.vote .pill:first-child { padding-left: 10px; }
.vote .pill:last-child { padding-right: 10px; }
.vote.sm .pill { padding: 0 5px; }
.vote.sm .pill:first-child { padding-left: 10px; }
.vote .vn { min-width: 1.5ch; text-align: center; color: #8a8a90; font: 600 14px var(--font); letter-spacing: -.01em; font-variant-numeric: tabular-nums; transition: color .15s; }
.vote.sm .vn { font-size: 13px; }
.vote.up .vn { color: var(--link); }
.vote.dn .vn { color: var(--down); }
.vote .pill:last-child.on, .vote .pill:last-child.on:hover { color: var(--down); }
/* views: a quiet counter, not a button */
.stat { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; color: #8a8a90; font: 500 14px var(--font); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.stat svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.stat .n:empty { display: none; }
/* icon-only in the main row (labels stay on the quieter reply pills) */
.pills .pill > span:not(.n) { display: none; }
/* quieter version used on replies */
.pill.sm { height: 30px; padding: 0 10px; gap: 6px; background: none; color: #8a8a90; font-weight: 500; font-size: 13px; }
.pill.sm:hover { color: var(--text); }
.pill.sm.on { color: var(--link); }
.pill.sm svg { width: 16px; height: 16px; }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 12px); background: #2c2c2e; color: var(--text); font: 500 14px var(--font); padding: 10px 18px; border-radius: 980px; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; z-index: 50; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Post cards, used by the feed and by profile pages */
.plist { list-style: none; margin: 0; padding: 0; }
.fpost { display: grid; grid-template-columns: 40px 1fr; gap: 14px; padding: 18px 0; border-top: 1px solid var(--hair); cursor: pointer; }
.fpost > a > img, .fpost > img { width: 40px; height: 40px; border-radius: 50%; display: block; }
.who { display: flex; gap: 8px; align-items: baseline; font-size: 14px; color: var(--muted); }
.who b, .who a { color: var(--text); font-weight: 600; text-decoration: none; }
.who a:hover { text-decoration: underline; }
.fpost p { margin: 4px 0 0; font-size: 19px; line-height: 1.42; white-space: pre-wrap; overflow-wrap: anywhere; }
.fpost.enter { animation: enter .5s cubic-bezier(.25,.1,.25,1); }
@keyframes enter { from { opacity: 0; transform: translateY(-6px); } }
.pimg { display: block; max-width: 100%; max-height: 520px; width: auto; height: auto; margin: 10px 0 0; border-radius: 16px; background: #161617; object-fit: contain; }
.fpost .pimg { max-height: 320px; background: none; }
.pill.del:hover { color: #ff453a; }
.empty { color: var(--muted); padding: 40px 0; text-align: center; border-top: 1px solid var(--hair); }

/* the first post sits right under the composer, no divider above it */
.plist > .fpost:first-child { border-top: 0; }
.empty { border-top: 0; }

/* Log-in pop-up: the /signup card as a dialog. Centered on desktop, near full width on phones. */
.ldlg { width: calc(100% - 32px); max-width: 440px; max-height: calc(100dvh - 32px); overflow-y: auto; margin: auto; padding: 40px 36px 30px; background: #161617; color: var(--text); border: 1px solid #2e2e30; border-radius: 28px; box-shadow: 0 24px 80px rgba(0,0,0,.6); animation: ldlg-in .22s cubic-bezier(.25,.1,.25,1); }
.ldlg::backdrop { background: rgba(0,0,0,.6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.ldlg h2 { margin: 0 0 12px; font: 700 clamp(34px, 9vw, 46px)/1.03 var(--font); letter-spacing: -.03em; }
.ldlg h2 span { color: var(--accent); }
.ldlg-lede { margin: 0 0 26px; color: var(--muted); font-size: 18px; line-height: 1.35; }
.ldlg-sso { display: grid; gap: 12px; }
.ldlg-sso button { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; height: 52px; border: 0; border-radius: 980px; background: #fff; color: #0f1419; font: 600 17px var(--font); letter-spacing: -.02em; cursor: pointer; transition: background-color .15s, transform .1s; }
.ldlg-sso button:hover:not(:disabled) { background: #e8e8ed; }
.ldlg-sso button:active { transform: scale(.985); }
.ldlg-sso button:disabled { opacity: .6; cursor: default; }
.ldlg-sso button:focus-visible { outline: 2px solid var(--link); outline-offset: 3px; }
.ldlg-sso svg { width: 20px; height: 20px; flex: none; }
.ldlg-fine { margin: 16px 0 0; color: #6e6e73; font-size: 13px; line-height: 1.45; }
.ldlg-fine a { color: var(--text); font-weight: 600; text-decoration: none; }
.ldlg-fine a:hover { text-decoration: underline; color: var(--link); }
.ldlg-note { margin: 10px 0 0; color: var(--accent); font-size: 14px; text-align: center; }
.ldlg-note:empty { display: none; }
.ldlg-x { position: absolute; top: 14px; right: 14px; display: grid; place-items: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%; background: #2c2c2e; color: var(--text); cursor: pointer; }
.ldlg-x svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.ldlg-x:hover { background: #3a3a3c; }
.ldlg-x:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
@keyframes ldlg-in { from { opacity: 0; transform: translateY(10px) scale(.98); } }
@media (max-width: 560px) { .ldlg { padding: 36px 24px 26px; } }
@media (prefers-reduced-motion: reduce) { .ldlg { animation: none; } }

/* Feed dividers: "N new since you were here" on top of what's new, "Earlier" below it. */
.feedsep { list-style: none; font-size: 13px; color: var(--muted); padding: 10px 0 8px; border-top: 1px solid var(--hair); }
.feedsep.new { color: var(--accent); font-weight: 600; border-top: 0; padding-top: 2px; }
.plist > .feedsep + .fpost { border-top: 0; }
