/* Profile hierarchy: identity, full-width mobile bio, activity, local follow. */
main.profile-page{max-width:var(--ys-header-width,1180px);margin:0 auto;padding:0 var(--ys-header-gutter,24px)}
.profile-page>.back-link{display:inline-flex;align-items:center;min-height:44px;margin:20px 0 16px;font-size:14px;line-height:1.5}
.profile-page .profile-layout{display:block;padding-bottom:64px}
.profile-page .profile-card{
 display:grid;grid-template-columns:112px minmax(0,1fr) 220px;
 grid-template-areas:"portrait identity action" "portrait bio action" "portrait stats action" "note note note";
 gap:12px 24px;align-items:start;text-align:left;border:0;border-radius:0;
 padding:8px 0 28px;border-bottom:1px solid #dce6e8;
}
.profile-page .profile-card>*{min-width:0}
.profile-page .profile-portrait{grid-area:portrait;width:112px;height:112px;object-fit:cover;border-radius:50%;margin:0}
.profile-identity{grid-area:identity;align-self:center}
.profile-page .profile-card h1{font-size:32px;line-height:1.3;margin:4px 0 8px;word-break:keep-all;overflow-wrap:anywhere}
.profile-page .profile-card p{font-size:15px;line-height:1.75;margin:0;color:#5c7074;word-break:keep-all;overflow-wrap:anywhere}
.profile-page .profile-card .profile-eyebrow{font-size:13px;line-height:1.5;color:#008f83}
.profile-page .profile-card .profile-location{font-size:14px;line-height:1.5}
.profile-page .profile-card .profile-bio{grid-area:bio;max-width:65ch;text-align:left}
.profile-page .profile-card .profile-stats{grid-area:stats;display:flex;flex-wrap:wrap;justify-content:flex-start;gap:12px 24px;margin:4px 0 0;font-size:14px;line-height:1.5;color:#5c7074}
.profile-page .profile-stats>span{display:inline-flex;align-items:baseline;gap:6px;white-space:nowrap}
.profile-page .profile-stats strong{display:inline;font-size:20px;margin:0;color:#203b37}
.profile-follow-area{grid-area:action;display:flex;flex-direction:column;align-items:stretch;gap:8px;min-width:0}
.profile-follow-area small{font-size:13px;color:#61767b;max-width:none;line-height:1.6;word-break:keep-all;overflow-wrap:anywhere}
.profile-follow-button{display:flex;align-items:center;justify-content:center;gap:9px;border:1px solid #008f83;border-radius:10px;background:#fff;color:#007c74;padding:11px 18px;min-height:48px;font:inherit;font-size:15px;font-weight:650;cursor:pointer}
.profile-follow-button[aria-pressed=true]{background:#008f83;color:#fff}
.profile-page .profile-card .profile-editorial-note{grid-area:note;padding-top:16px;border-top:1px solid #edf1f2;margin:8px 0 0;font-size:13px;line-height:1.7;color:#667b80}
.profile-page .profile-card .profile-feedback{font-size:14px;line-height:1.65;color:#53696e}
.profile-feedback:empty{display:none}
.profile-main{min-width:0}
.profile-page .profile-tabs{display:flex;flex-wrap:wrap;overflow:visible;margin-top:24px;gap:8px 28px}
.profile-page .profile-tabs button{font-size:15px;min-height:44px;padding:12px 0}
.profile-tags{margin:28px 0}
.profile-tags h2{font-size:17px;line-height:1.5;margin:0 0 12px}
.profile-page .profile-tags .ys-content-tags{margin:0;gap:8px;justify-content:flex-start}
.profile-page .profile-tags .ys-content-tags a{font-size:14px;min-height:40px;max-width:100%;padding:8px 12px;line-height:1.5;word-break:keep-all;overflow-wrap:anywhere}
.profile-filter{display:flex;flex-wrap:wrap;gap:8px;margin:24px 0}
.profile-filter button{border:1px solid #dce6e8;border-radius:20px;padding:8px 14px;font:inherit;font-size:14px;min-height:44px;background:white;max-width:100%;word-break:keep-all;overflow-wrap:anywhere}
.profile-filter button[aria-pressed=true]{border-color:#008f83;color:#007c74;background:#f2faf9}
.profile-filter button span{margin-left:5px;color:#677f83;font-size:14px}
.profile-post-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:32px 24px}
.profile-post-card{min-width:0}
.profile-post-card>a{display:block}
.profile-post-card img{display:block;width:100%;aspect-ratio:3/2;object-fit:contain;border-radius:9px}
.profile-post-card small{display:block;font-size:13px;color:#677b80;margin:12px 0 6px}
.profile-post-card h3{word-break:keep-all;overflow-wrap:anywhere;text-wrap:balance;margin:0 0 10px}
.profile-post-card .ys-content-tags{margin:0;gap:5px}
.profile-post-card .ys-content-tags a{font-size:13px;min-height:30px;padding:4px 9px}
.profile-page .profile-empty{background:#f5f8f9;color:#53696e;line-height:1.8}
.profile-page .profile-empty a{color:#008f83;text-decoration:underline;text-underline-offset:4px}
.author-open,.space-author{text-decoration:none}
.author-open:focus-visible,.space-author:focus-visible,.profile-page button:focus-visible,.profile-page a:focus-visible{outline:2px solid #008f83;outline-offset:4px;border-radius:6px}
/* Keep authored posts and saved stories photo-first, without changing gallery tiles. */
.profile-page .profile-post-grid{align-items:start}
.profile-page .profile-post-card img{width:100%;height:auto;aspect-ratio:3/2;object-fit:contain;object-position:center;background:#f6f9fa}
.profile-page .profile-post-card h3{font-size:21px;line-height:1.5}
.profile-page .profile-post-card .ys-content-tags{max-width:100%;flex-wrap:wrap}
@media(max-width:1000px){.profile-page .profile-post-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){
 main.profile-page{padding:0 var(--ys-header-gutter,18px)}
 .profile-page>.back-link{margin:12px 0}
 .profile-page .profile-card{grid-template-columns:80px minmax(0,1fr);grid-template-areas:"portrait identity" "bio bio" "stats stats" "action action" "note note";gap:20px 16px;padding:8px 0 24px;align-items:start}
 .profile-page .profile-portrait{width:80px;height:80px}
 .profile-page .profile-card h1{font-size:26px;line-height:1.3;margin:3px 0 6px}
 .profile-page .profile-card .profile-bio{font-size:16px;line-height:1.75;max-width:none}
 .profile-page .profile-card .profile-stats{margin:0;gap:12px 24px}
 .profile-follow-area{width:100%;gap:8px}
 .profile-follow-area small{text-align:left;max-width:none;font-size:13px}
 .profile-page .profile-card .profile-editorial-note{margin:0;padding-top:16px}
 .profile-page .profile-tabs{gap:8px 24px}
 .profile-page .profile-post-grid{grid-template-columns:minmax(0,1fr);gap:30px}
 .profile-page .profile-post-card{padding-bottom:22px;border-bottom:1px solid #e3ecee}
 .profile-page .profile-post-card small{font-size:14px;margin:14px 0 7px}
 .profile-page .profile-post-card h3{margin-bottom:12px}
 .profile-page .profile-post-card .ys-content-tags a{min-height:36px;padding:6px 11px}
}
