.achievement-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,240px),1fr)); gap:20px; }
.profile-more { position:absolute; top:16px; right:16px; z-index:5; }
.profile-more summary { display:grid; place-items:center; list-style:none; width:44px; height:44px; border-radius:50%; background:#fff; color:#a72560; cursor:pointer; box-shadow:0 3px 12px #39203c18; }
.profile-more summary::-webkit-details-marker { display:none; }
.profile-more > div { position:absolute; right:0; display:grid; gap:12px; width:220px; max-width:calc(100vw - 48px); padding:18px; margin-top:8px; border:1px solid #eedce7; border-radius:16px; background:#fff; box-shadow:0 8px 24px #39203c18; }
.profile-more a { font-size:14px; color:#79445f; }
.achievement-card { padding:24px; border:1px solid #e7e2e7; border-radius:20px; color:#77717b; background:#faf9fa; }
.achievement-card.earned { background:linear-gradient(130deg,#fff3f8,#e9f8f7); color:#333344; border-color:#edc8dc; }
.achievement-card--collection { padding:28px; }
.achievement-members { list-style:none; padding:0; display:grid; gap:12px; }
.achievement-members li { display:flex; align-items:center; gap:12px; font-size:14px; }
.achievement-members img { width:40px; height:40px; object-fit:contain; }
.achievement-members li:not(.earned) img { filter:grayscale(1); opacity:.5; }
.achievement-rewards { margin-top:16px; padding-top:14px; border-top:1px solid #eadfe8; font-size:14px; }
.achievement-rewards summary { cursor:pointer; color:#a72560; }
.achievement-rewards ul { padding-left:20px; line-height:1.8; }
.cosmetic-form > [hidden] { display:none!important; }
.achievement-card h2 { font-size:20px; margin-block:16px; }
.achievement-medal { display:grid; place-items:center; width:64px; height:64px; border-radius:50%; border:3px double #d3b6c7; background:#fff; font-size:34px; color:#e52a7a; }
:is(.achievement-card,.achievement-progress) progress { width:100%; height:20px; accent-color:#ec287b; margin-top:20px; }
.profile-decoration { display:flex; align-items:center; gap:12px; flex-wrap:wrap; padding:20px; border-radius:20px; background:#fff5fa; }
.profile-decoration__badge { color:#af2258; background:#fff; padding:10px 16px; border:1px solid #ebcbdd; border-radius:24px; }
.profile-decoration img { width:64px; height:64px; object-fit:cover; border-radius:50%; }
.frame-starter { outline:4px double #eaa5ca; outline-offset:4px; }
.frame-author { outline:4px double #20aaa9; outline-offset:4px; }
.frame-home,.frame-star,.frame-gold { outline:5px double #c79b46; outline-offset:4px; box-shadow:0 0 14px #d9b67377; }
.achievement-progress { display:flex; align-items:center; flex-wrap:wrap; gap:24px; }
.achievement-level { font-size:56px; font-weight:700; color:#dd2878; }
.achievement-progress__bar { flex:1 1 360px; }
.achievement-tabs { display:flex; gap:12px; flex-wrap:wrap; margin:28px 0; }
.achievement-tabs a { padding:12px 20px; border-radius:24px; border:1px solid #eacddd; color:#66394c; }
.achievement-tabs a[aria-current] { background:#e72b7c; color:white; }
.achievement-filter { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin-bottom:28px; }
.achievement-filter select { padding:12px; border:1px solid #ddcbd4; border-radius:10px; background:white; }
.achievement-branch { margin-block:36px; }
.achievement-branch > h2 { margin-bottom:20px; }
.achievement-card h3 { font-size:20px; margin-block:18px 12px; }
.achievement-card p { margin-block:12px; line-height:1.5; }
.achievement-card:not(.earned) .achievement-medal { filter:grayscale(1); opacity:.65; }
.achievement-card ul { padding-left:0; list-style:none; line-height:1.8; }
/* Original achievement artwork supplied with the visual specification. */
.achievement-art { display:block; width:144px; height:144px; max-width:100%; object-fit:contain; margin:0 auto 20px; }
.achievement-card { position:relative; background:#fff; box-shadow:0 6px 24px #38213208; }
.achievement-card.earned { border-color:#eeb4cb; background:linear-gradient(145deg,#fff,#fff4f8 70%,#edfaf8); }
.achievement-card:not(.earned) .achievement-art { filter:grayscale(.85); opacity:.6; }
.achievement-branch .achievement-grid { grid-template-columns:repeat(auto-fill,minmax(min(100%,190px),1fr)); gap:16px; align-items:start; }
.achievement-branch .achievement-card { padding:18px 14px; text-align:center; }
.achievement-branch .achievement-art { width:110px; height:110px; margin-bottom:12px; }
.achievement-branch .achievement-card h3 { font-size:16px; line-height:1.4; margin:8px 0; overflow-wrap:anywhere; }
.achievement-card .achievement-card__condition { font-size:13px; line-height:1.5; }
.achievement-card .achievement-card__xp { color:#ec247b; font-size:14px; margin:8px 0; }
.achievement-card .achievement-card__date,.achievement-card .achievement-card__count { font-size:12px; color:#756881; margin:8px 0; }
.achievement-card progress { height:7px; margin-top:8px; }
.achievement-collections { align-items:start; }
.achievement-card--collection { text-align:center; }
.achievement-card--collection .achievement-rewards { text-align:left; }
.achievement-card--collection .achievement-members { grid-template-columns:repeat(2,minmax(0,1fr)); margin-top:18px; padding-top:16px; border-top:1px solid #eadfe8; }
.achievement-card--collection .achievement-members li { flex-direction:column; gap:6px; font-size:12px; line-height:1.5; }
.achievement-card--collection .achievement-members span { font-size:inherit; }
.collection-open { width:100%; margin-top:16px; padding:10px; border:1px solid #e7d8e5; border-radius:10px; background:white; color:#806284; cursor:pointer; font:inherit; font-size:13px; }
.collection-open[hidden] { display:none; }
.achievement-collection-layout--enhanced > .achievement-collections .achievement-card__condition,
.achievement-collection-layout--enhanced > .achievement-collections .achievement-rewards,
.achievement-collection-layout--enhanced > .achievement-collections .achievement-members { display:none; }
.achievement-collection-layout--enhanced > .achievement-collections .is-selected { border-color:#f05296; box-shadow:0 0 0 1px #f0529640; }
.collection-detail[hidden] { display:none; }
.collection-dialog { box-sizing:border-box; max-width:none; width:min(520px,calc(100% - 24px)); max-height:calc(100dvh - 24px); padding:46px 14px 14px; border:1px solid #ebdce7; border-radius:22px; background:white; color:#302b40; }
.collection-dialog::backdrop { background:#251d3066; }
html.collection-dialog-open { overflow:hidden; }
.collection-dialog__close { position:absolute; right:12px; top:8px; width:36px; height:36px; border:0; background:white; color:#886c90; font-size:28px; cursor:pointer; }
@media(min-width:1001px) {
 .achievement-collection-layout--enhanced { display:grid; grid-template-columns:minmax(0,1fr) 300px; gap:24px; align-items:start; }
 .collection-detail { position:sticky; top:150px; }
 .collection-detail .achievement-card { padding:20px; }
}
@media(max-width:1000px) { .collection-detail { display:none; } }
.achievement-branch .achievement-rewards { font-size:12px; margin-top:12px; padding-top:10px; text-align:left; }
@media(max-width:600px) {
 .achievement-branch .achievement-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
 .achievement-branch .achievement-card { padding:14px 10px; border-radius:16px; }
 .achievement-branch .achievement-art { width:80px; height:80px; }
 .achievement-branch .achievement-card h3 { font-size:14px; }
}
.profile-decoration__badge { display:inline-flex; align-items:center; gap:10px; }
.profile-decoration .profile-decoration__badge img { width:48px; height:48px; object-fit:contain; border-radius:0; }
@media(max-width:600px) { .achievement-art { width:120px; height:120px; } }
.cosmetic-preview { display:flex; align-items:center; gap:28px; padding:28px; border:1px solid #ecd9e4; border-radius:22px; background:linear-gradient(120deg,#fff2f8,#eef9f8); }
.cosmetic-preview__avatar { width:96px; height:96px; flex-shrink:0; border-radius:50%; object-fit:cover; }
.cosmetic-preview h3 { font-size:24px; overflow-wrap:anywhere; }
.cosmetic-preview__badge { display:inline-flex; align-items:center; gap:10px; margin-top:12px; }
.cosmetic-preview__badge[hidden] { display:none; }
.cosmetic-preview__badge img { width:48px; height:48px; object-fit:contain; }
.cosmetic-preview__status { font-size:14px; color:#796875; }
.cosmetic-form__actions { display:flex; gap:16px; flex-wrap:wrap; align-items:center; }
.cosmetic-form__reset { min-height:44px; background:#fff; padding:10px 20px; border:1px solid #ddc9d4; border-radius:12px; color:#834562; cursor:pointer; }
@media(max-width:500px) { .cosmetic-preview { padding:20px; gap:20px; flex-wrap:wrap; } }
.cosmetic-preview { background-size:cover; background-position:center; }
.cosmetic-preview > div { border-radius:12px; background:#ffffffde; padding:12px; }
.cosmetic-preview__sticker,.profile-decoration .profile-decoration__sticker { width:90px; height:90px; object-fit:contain; border-radius:12px; }
.cosmetic-preview__sticker[hidden] { display:none; }
.cosmetic-name_style-visit_collection { color:#956423!important; text-shadow:0 1px 0 #fff2c8; font-weight:600!important; }
.cosmetic-name_style-involved { color:#ab2e6d!important; font-weight:600!important; }
.cosmetic-name_style-story_best_month { color:#91600b!important; text-shadow:0 1px 0 #ffefad; font-weight:700!important; }
.cosmetic-name_style-moment_likes_thirty { color:#197b87!important; font-weight:600!important; }
.cosmetic-frame-involved { outline:4px double #ce68a2; outline-offset:4px; }
.cosmetic-frame-moment_likes_thirty { outline:4px double #30a4a8; outline-offset:4px; }
.cosmetic-frame-story_photos { outline:4px double #b7974f; outline-offset:4px; }
.cosmetic-preview__portrait { position:relative; display:inline-flex; flex-shrink:0; margin:24px; }

:is(.frame-author,.cosmetic-preview__portrait:has(.frame-author)) { --avatar-frame:url('../img/achievements/story_five-frame.webp'); }
:is(.frame-home,.cosmetic-preview__portrait:has(.frame-home)) { --avatar-frame:url('../img/achievements/visit_collection-frame.webp'); }
:is(.frame-star,.cosmetic-preview__portrait:has(.frame-star)) { --avatar-frame:url('../img/achievements/story_best_week-frame.webp'); }
:is(.frame-gold,.cosmetic-preview__portrait:has(.frame-gold)) { --avatar-frame:url('../img/achievements/story_best_month-frame.webp'); }
:is(.cosmetic-frame-story_photos,.cosmetic-preview__portrait:has(.cosmetic-frame-story_photos)) { --avatar-frame:url('../img/achievements/story_photos-frame.webp'); }
:is(.cosmetic-frame-involved,.cosmetic-preview__portrait:has(.cosmetic-frame-involved)) { --avatar-frame:url('../img/achievements/involved-frame.webp'); }
:is(.cosmetic-frame-moment_likes_thirty,.cosmetic-preview__portrait:has(.cosmetic-frame-moment_likes_thirty)) { --avatar-frame:url('../img/achievements/moment_likes_thirty-frame.webp'); }
.cosmetic-preview__portrait:has(:is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen))::after,
:is(.wrap_img_avatar,.profile-framed-avatar):is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen)::after { content:''; position:absolute; inset:-30%; background:var(--avatar-frame) center/contain no-repeat; pointer-events:none; z-index:2; }
.cosmetic-preview__portrait :is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen),:is(.wrap_img_avatar,.profile-framed-avatar):is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen) { outline:none; box-shadow:none; }
:is(.wrap_img_avatar,.profile-framed-avatar):is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen) { position:relative; overflow:visible; }
.avatar .content:has(:is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen)) { margin-bottom:40px; }
.avatar .content :is(.wrap_img_avatar,.profile-framed-avatar):is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen) { margin-inline:30px; }
.cosmetic-name_style-level_five { color:#b92f84!important; font-weight:600!important; }
.cosmetic-name_style-level_ten { color:#208d92!important; font-weight:600!important; }
.cosmetic-name_style-level_fifteen { color:#9c7215!important; font-weight:700!important; text-shadow:0 1px 0 #fff0c1; }

:is(.frame-level-five,.cosmetic-preview__portrait:has(.frame-level-five)) { --avatar-frame:url('../img/achievements/level_five-frame.webp'); }
:is(.frame-level-ten,.cosmetic-preview__portrait:has(.frame-level-ten)) { --avatar-frame:url('../img/achievements/level_ten-frame.webp'); }
:is(.frame-level-fifteen,.cosmetic-preview__portrait:has(.frame-level-fifteen)) { --avatar-frame:url('../img/achievements/level_fifteen-frame.webp'); }
.avatar .shift:has(.content :is(.frame-starter,.frame-author,.frame-home,.frame-star,.frame-gold,.cosmetic-frame-story_photos,.cosmetic-frame-involved,.cosmetic-frame-moment_likes_thirty,.frame-level-five,.frame-level-ten,.frame-level-fifteen)) { height:auto; min-height:196px; }
#profile-header { scroll-margin-top:120px; }
@media (max-width:600px) {
  .avatar .content:has([class*="frame-"]) { margin-bottom:-30px; row-gap:36px; }
  .avatar .socials:not(:has(a)) { display:none; }
  .avatar .bottom { padding-bottom:16px; }
}

.comment-decoration { display:inline-flex; vertical-align:middle; }
.comment-decoration img,.comments .comment-decoration img { width:40px; height:40px; object-fit:contain; border-radius:0; }
.cosmetic-comment-preview { padding:20px; border:1px solid #eddde5; border-radius:14px; background:#fff; }
.cosmetic-comment-preview > span { display:inline-flex; vertical-align:middle; margin-left:12px; }
.cosmetic-comment-preview img { width:40px; height:40px; object-fit:contain; }

.cosmetic-wardrobe { margin-block:28px; }
.cosmetic-wardrobe [hidden] { display:none!important; }
.cosmetic-wardrobe .achievement-tabs button { border:1px solid #eacddd; border-radius:24px; padding:12px 20px; background:#fff; color:#66394c; cursor:pointer; }
.cosmetic-wardrobe .achievement-tabs button[aria-pressed="true"] { background:#e72b7c; color:white; }
.wardrobe-frame { display:flex; justify-content:center; align-items:center; min-height:190px; }
.wardrobe-name { display:grid; place-items:center; min-height:190px; font-size:26px; overflow-wrap:anywhere; }
.wardrobe-cover { width:100%; height:190px; object-fit:cover; border-radius:12px; }
.cosmetic-wardrobe [data-wardrobe-state] { display:block; font-size:13px; margin-top:10px; color:#675363; }
.cosmetic-wardrobe .achievement-card:not(.earned) .wardrobe-frame,.cosmetic-wardrobe .achievement-card:not(.earned) .wardrobe-name { filter:grayscale(.85); opacity:.6; }

.profile-status { max-width:400px; overflow-wrap:anywhere; white-space:pre-wrap; line-height:1.5; margin-top:8px; font-size:14px; }
.badge-order { display:flex; flex-wrap:wrap; gap:12px; }
.badge-order > div { display:flex; align-items:center; gap:8px; padding:12px; border:1px solid #eacddd; border-radius:12px; background:#fff9fc; flex:1 1 240px; }
.badge-order span { flex:1; }
.badge-order button { min-width:36px; min-height:36px; border:1px solid #decad4; border-radius:8px; background:white; cursor:pointer; }
.badge-order button:disabled { opacity:.35; cursor:default; }

.avatar .names { min-width:0; }
.avatar .profile-status { color:white; width:100%; }
@media (max-width:600px) {
  .avatar .names:has(.profile-status) { flex-basis:100%; text-align:left; align-items:flex-start; top:0; }
  .avatar .names .profile-status { margin-block:4px 12px; }
}
.avatar .content .profile-framed-avatar { overflow:visible; }
.avatar .content .profile-framed-avatar > img { width:100%; height:100%; object-fit:cover; }

.profile-decoration-edit { background:#ffffffee; color:#a92965; border:1px solid #efd3e0; padding:8px 14px; border-radius:10px; cursor:pointer; margin-bottom:12px; }
.profile-decoration-dialog { width:min(1000px,calc(100% - 24px)); max-height:90dvh; box-sizing:border-box; border:1px solid #eed6e1; border-radius:22px; padding:24px; }
.profile-decoration-dialog::backdrop { background:#26182899; }
.profile-decoration-dialog .cosmetic-form { margin:0; border:0; box-shadow:none; padding:0; }
.profile-decoration-close { display:block; margin-left:auto; min-width:44px; min-height:44px; border:0; border-radius:50%; font-size:28px; background:#fff0f6; cursor:pointer; }
@media(max-width:600px) { .profile-decoration-dialog { padding:16px; } }

.profile-header-awards { display:flex; align-items:center; gap:24px; padding:0 24px 24px; color:#fff; }
.profile-header-awards__main { flex:1; min-width:0; }
.profile-header-awards__badges { display:flex; gap:12px; flex-wrap:wrap; margin-bottom:18px; }
.profile-header-awards__badges a { display:flex; gap:10px; align-items:center; border:1px solid #ffffff70; border-radius:32px; padding:8px 14px; background:#ffffff18; color:inherit; }
.profile-header-awards__badges img { width:48px; height:48px; object-fit:contain; }
.profile-header-progress { display:flex; gap:14px; align-items:center; flex-wrap:wrap; color:inherit; }
.profile-header-progress progress { flex:1 1 160px; max-width:500px; height:12px; accent-color:#ff82b6; }
.profile-header-sticker { display:flex; flex-direction:column; align-items:center; gap:8px; max-width:140px; text-align:center; color:inherit; }
.profile-header-sticker img { width:100px; height:100px; object-fit:contain; }
.avatar .shift:has(.profile-header-awards) { height:auto; padding-bottom:20px; }
.avatar .shift .content { margin-bottom:-20px; }
.avatar .shift:has(.profile-header-awards) .bottom { top:0; }
@media(max-width:600px) {
 .profile-header-awards { padding-inline:18px; gap:16px; flex-wrap:wrap; }
 .profile-header-awards__badges a { font-size:13px; padding:6px 10px; }
 .profile-header-awards__badges img { width:36px; height:36px; }
 .profile-header-progress { font-size:14px; }
 .profile-header-sticker { flex-direction:row; max-width:100%; font-size:13px; }
 .profile-header-sticker img { width:64px; height:64px; }
}

:is(.frame-starter,.cosmetic-preview__portrait:has(.frame-starter)) { --avatar-frame:url('../img/achievements/profile_complete-frame.svg'); }
.cosmetic-name_style-visit_collection { background:linear-gradient(180deg,#fff5dc 5%,#f4b8cf 48%,#82cecc 100%); color:#916222!important; -webkit-text-stroke:.25px #94662d; text-shadow:0 1px 1px #78522930; }
@supports (background-clip:text) {
 .cosmetic-name_style-visit_collection { background-clip:text; color:transparent!important; }
}
.cosmetic-name_style-involved { color:#bd347c!important; text-shadow:0 1px 0 #ffe5ef,0 0 6px #2bb5bb25; }
.cosmetic-name_style-level_five { color:#ad407f!important; text-shadow:0 1px 0 #ffe1ee; }
.cosmetic-name_style-level_ten { color:#167d7b!important; text-shadow:0 1px 0 #deffe9,0 0 5px #e8b17145; }
.cosmetic-name_style-level_fifteen,.cosmetic-name_style-story_best_month { color:#926412!important; text-shadow:0 1px 0 #fff2be,0 0 6px #e8c15755; }
@media (forced-colors:active) { [class*="cosmetic-name_style-"] { color:CanvasText!important; background:none; -webkit-text-stroke:0; text-shadow:none; } }

.comment-author { display:flex; align-items:center; gap:22px; padding:8px 0; min-width:0; }
.comment-author__portrait { position:relative; display:block; flex:0 0 52px; width:52px; height:52px; margin:6px; border-radius:50%; }
.comment-author__portrait > img { display:block; width:100%; height:100%; aspect-ratio:1; object-fit:cover; border-radius:50%; }
.comment-author__online { position:absolute; bottom:0; right:0; width:12px; height:12px; border:2px solid white; border-radius:50%; background:#29b875; z-index:3; }
.comment-author__identity { flex:1; min-width:0; }
.comment-author__name { display:flex; flex-wrap:wrap; align-items:center; gap:7px; font-weight:600; overflow-wrap:anywhere; }
.comment-author__name > a { animation:none; text-shadow:none; }
.comment-author__vip { padding:3px 6px; border-radius:8px; background:#fff0c8; color:#765217; font-size:10px; line-height:1.4; }
.comment-author__award { display:inline-flex; flex:none; width:30px; height:30px; }
.comment-author__award img { width:100%; height:100%; object-fit:contain; border-radius:0; }
.comment-author__meta { display:flex; align-items:center; flex-wrap:wrap; gap:5px 10px; margin-top:5px; color:#82727d; font-size:12px; }
.comment-author__meta > span { color:inherit; font-size:inherit; }
.comment-author__level { position:relative; margin:0; }
.comment-author__level summary { cursor:pointer; border-radius:8px; background:#eaf7f3; color:#477266; padding:3px 7px; list-style:none; }
.comment-author__meta .comment-author__level summary { font-size:12px; }
.comment-author__level summary::-webkit-details-marker { display:none; }
.comment-author__level > div { padding:12px; margin-top:8px; border:1px solid #e5dbe1; border-radius:12px; background:white; color:#4d4149; font-size:13px; }
.comment-author__level p { margin:8px 0; }
.comment-author__date { display:block; color:#82727d; font-size:12px; margin:8px 0; }
.comment-author a:focus-visible,.comment-author summary:focus-visible { outline:2px solid #a72560; outline-offset:3px; }
@media(max-width:480px) { .comment-author { gap:16px; } .comment-author__portrait { flex-basis:44px; width:44px; height:44px; } }

/* Keep header controls below the cover; only the portrait overlaps it. */
#profile-header .shift { top:0; height:auto; padding:0 0 20px; }
#profile-header .shift .content { top:0; margin:0; padding:24px; align-items:center; flex-wrap:wrap; gap:24px; }
#profile-header .content > :is(.img_avatar,.wrap_img_avatar) { margin:-55px 20px 0; position:relative; z-index:3; }
#profile-header .names { flex:1 1 240px; width:auto; }
#profile-header .names .name { line-height:1.3; overflow-wrap:anywhere; }
#profile-header .bottom { top:0; padding-inline:24px; flex-wrap:wrap; gap:16px; }
#profile-header .profile-header-awards__badges a { color:white; }
@media(max-width:600px) {
 #profile-header .shift .content { padding:20px; gap:20px; }
 #profile-header .content > :is(.img_avatar,.wrap_img_avatar) { margin:-30px auto 0; }
 #profile-header .names { flex-basis:100%; }
}

/* Profile editor follows the reference's side panel and compact header preview. */
.profile-decoration-dialog { width:min(620px,calc(100% - 32px)); max-width:none; max-height:calc(100dvh - 32px); margin:16px 16px 16px auto; overflow:auto; }
.profile-decoration-close { position:absolute; top:12px; right:12px; background:transparent; }
.profile-decoration-dialog .cosmetic-form > h2 { padding-right:42px; margin-top:0; }
.cosmetic-form :is(input,textarea,select) { box-sizing:border-box; min-width:0; max-width:100%; }
.cosmetic-form textarea[name=status_text] { resize:vertical; }
.cosmetic-form [data-status-length] { font:inherit; color:inherit; }
.profile-decoration-dialog .cosmetic-preview { flex-wrap:nowrap; gap:16px; padding:20px 12px; }
.profile-decoration-dialog .cosmetic-preview__portrait { margin:12px; }
.profile-decoration-dialog .cosmetic-preview > div { min-width:0; flex:1; }
.profile-decoration-dialog .cosmetic-preview h3 { font-size:20px; }
.profile-decoration-dialog [data-preview-status-text] { overflow-wrap:anywhere; white-space:pre-line; font-size:13px; }
.profile-decoration-dialog .cosmetic-form__actions { position:sticky; bottom:-24px; padding:14px 0; background:white; border-top:1px solid #eee5ed; }
.profile-decoration-dialog .cosmetic-form__actions > * { flex:1; width:0; min-width:0; text-align:center; }
@media(max-width:600px) {
 .profile-decoration-dialog { width:100%; margin:auto 0 0; max-height:calc(100dvh - 16px); border-radius:24px 24px 0 0; }
 .profile-decoration-dialog .cosmetic-preview { gap:8px; padding:16px 8px; }
 .profile-decoration-dialog .cosmetic-preview__avatar { width:64px; height:64px; }
 .profile-decoration-dialog .cosmetic-preview__portrait { margin:8px; }
 .profile-decoration-dialog .cosmetic-preview > div { padding:8px; }
 .profile-decoration-dialog .cosmetic-form__actions { bottom:-16px; gap:10px; }
}
.profile-decoration-close { z-index:1; color:#625875; }
.profile-decoration-dialog .cosmetic-form__actions > * { min-height:48px; height:auto; padding:10px; font-size:14px; }

.achievement-tabs { gap:8px; border-bottom:1px solid #eee7ee; }
.achievement-tabs a { border:0; border-bottom:2px solid transparent; border-radius:0; padding:12px 16px; }
.achievement-tabs a[aria-current] { color:#f2277a; background:transparent; border-bottom-color:#f2277a; }
.achievement-status-filters { display:flex; gap:12px; flex-wrap:wrap; margin:24px 0; }
.achievement-status-filters a { display:flex; align-items:center; gap:14px; border:1px solid #e8e2ec; border-radius:24px; padding:10px 16px; font-size:13px; color:#625274; }
.achievement-status-filters a[aria-current] { background:#f5267c; border-color:#f5267c; color:white; }
.achievement-status-filters span { font:inherit; color:inherit; }
.achievement-filter { padding:16px; border:1px solid #efe7ef; border-radius:16px; background:white; }
.achievement-filter label { color:#7c6c85; font-size:13px; }
.achievement-filter select { min-width:0; max-width:100%; box-sizing:border-box; font:inherit; font-size:14px; }
.achievement-filter .btn { width:auto; padding:12px 18px; min-height:44px; }
.achievement-empty { padding:24px; border:1px dashed #e3d5e1; border-radius:18px; color:#786880; }
@media(max-width:600px) {
 .achievement-tabs { flex-wrap:nowrap; overflow-x:auto; }
 .achievement-tabs a { white-space:nowrap; padding:12px 10px; font-size:13px; }
 .achievement-status-filters { gap:8px; }
 .achievement-status-filters a { padding:9px 12px; gap:8px; font-size:12px; }
 .achievement-filter { display:grid; grid-template-columns:minmax(0,1fr); gap:8px; }
 .achievement-filter select { width:100%; }
 .achievement-filter .btn { margin-top:8px; }
}
.cosmetic-preview [data-preview-badges] { display:flex; flex-wrap:wrap; align-items:center; gap:6px; }
.cosmetic-preview__badge { margin-top:6px; }
.cosmetic-preview > div { min-width:0; }
@media(max-width:600px) {
 .cosmetic-preview { flex-wrap:nowrap; padding:16px 8px; gap:8px; }
 .cosmetic-preview__portrait { margin:12px; }
 .cosmetic-preview__avatar { width:64px; height:64px; }
 .cosmetic-preview > div { flex:1; padding:8px; }
 .cosmetic-preview h3 { font-size:20px; }
 .cosmetic-preview__badge img { width:32px; height:32px; }
 .cosmetic-preview .cosmetic-preview__sticker { width:60px; height:60px; margin-top:8px; }
}
