/*
 * FediMast Five — visual layer for FediPress.
 * Based on the October 2026 Mastodon 5.0 web redesign.
 * The posting, following and federating behavior comes from FediPress,
 * not from this stylesheet. All core FediPress blocks are left intact.
 */
html:root {
 --wp--preset--color--base:#faf8ff;
 --wp--preset--color--surface:#f1edfa;
 --wp--preset--color--line:#e3dfeb;
 --wp--preset--color--ink:#231c35;
 --wp--preset--color--muted:#776f84;
 --wp--preset--color--iris:#5638d6;
 --wp--preset--color--reply:#5638d6;
 --wp--preset--color--repost:#269565;
 --wp--preset--color--like:#d83c75;
 --afv-c-base:#faf8ff;
 --afv-c-surface:#f1edfa;
 --afv-c-line:#e3dfeb;
 --afv-c-ink:#231c35;
 --afv-c-muted:#776f84;
 --afv-c-iris:#5638d6;
 --afv-c-reply:#5638d6;
 --afv-c-repost:#269565;
 --afv-c-like:#d83c75;
 --m5-bg:#f1eef9;
 --m5-feed:#faf8ff;
 --m5-text:#251e36;
 --m5-muted:#786f87;
 --m5-line:#e3ddea;
 --m5-hover:#e9e3f5;
 --m5-active:#e2daf4;
 --m5-purple:#5638d6;
 --m5-purple-dark:#4828bf;
 --m5-admin:0px;
 --m5-shell:1204px;
 color-scheme:light;
}
body.admin-bar { --m5-admin:32px; }
body, html { margin:0; min-height:100%; }
body {
 background:var(--m5-bg);
 color:var(--m5-text);
 font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;
 font-size:14px;
 line-height:1.52;
 overflow-wrap:break-word;
}
.wp-site-blocks { min-height:100vh; }
a { color:var(--m5-purple); text-underline-offset:3px; }
:where(button,textarea,input,select,a,summary):focus-visible {outline:2px solid var(--m5-purple)!important;outline-offset:3px;}
button, input, textarea, select { font-family:inherit; }
button, .m5-link, .m5-shortcut { -webkit-tap-highlight-color:transparent; }
.m5-optional-header, .fplus-header-wrap { display:none!important; }

/* 5.0 layout: single side navigation, one feed, largely open right canvas. */
.afv-shell {
 box-sizing:border-box;
 display:grid;
 grid-template-columns:minmax(230px,288px) minmax(0,560px) minmax(218px,288px);
 width:min(100%,var(--m5-shell));
 max-width:var(--m5-shell);
 min-height:100vh;
 margin:0 auto!important;
 gap:0;
 align-items:start;
 justify-content:center;
}
.afv-shell > * {margin:0!important;min-width:0;}
.afv-main {
 min-width:0;
 min-height:100vh;
 box-sizing:border-box;
 background:var(--m5-feed);
 border-left:1px solid var(--m5-line);
 border-right:1px solid var(--m5-line);
 border-radius:0;
 box-shadow:none;
 padding:0;
}
.afv-main > * {margin-block:0!important;}
.afv-main--paper {background:var(--m5-feed);padding:0;}
.afv-main:has(.afv-timeline) { padding-bottom:48px; }

/* Left column / identity. */
.afv-rail {
 position:sticky!important;
 top:var(--m5-admin)!important;
 height:calc(100vh - var(--m5-admin))!important;
 max-height:calc(100vh - var(--m5-admin));
 overflow-y:auto;
 scrollbar-width:none;
 -ms-overflow-style:none;
 overscroll-behavior-y:contain;
}
.afv-rail::-webkit-scrollbar,.afv-side::-webkit-scrollbar {display:none;width:0;height:0;}
.afv-rail__inner.m5-rail-inner {
 box-sizing:border-box;
 height:100%;
 min-height:650px;
 width:100%;
 padding:24px 12px 14px 16px;
 display:flex;
 flex-direction:column;
 align-items:stretch;
 gap:0;
}
.afv-rail__inner > * {margin:0!important;}
.m5-identity {
 display:flex;align-items:center;gap:10px;
 min-width:0;
 min-height:52px;
 padding:2px 8px 15px;
 color:var(--m5-text);
 text-decoration:none!important;
}
.m5-identity img {width:34px;height:34px;flex:none;border-radius:10px;object-fit:cover;}
.m5-identity__text {display:flex;flex-direction:column;gap:1px;min-width:0;line-height:1.2;}
.m5-identity strong {font-size:15px;font-weight:750;letter-spacing:-.2px;overflow-wrap:anywhere;}
.m5-identity small {font-size:11px;color:var(--m5-muted);font-weight:450;}
.m5-primary,.m5-nav-group nav {display:flex;flex-direction:column;gap:3px;}
.m5-primary {margin-top:2px;}
.m5-link {
 position:relative;
 display:flex;align-items:center;
 gap:14px;
 width:100%;
 box-sizing:border-box;
 padding:10px 13px;
 min-height:42px;
 border-radius:11px;
 background:transparent;
 color:var(--m5-text);
 font-size:14px;
 font-weight:540;
 line-height:1.25;
 text-decoration:none!important;
 transition:background .13s,color .13s;
}
.m5-link::before, .m5-shortcut::before {
 content:"";
 width:18px;height:18px;
 flex:0 0 18px;
 background-color:currentColor;
 -webkit-mask:var(--afv-icon) center/contain no-repeat;
 mask:var(--afv-icon) center/contain no-repeat;
}
.m5-link:hover, .m5-link[aria-current="page"] {background:var(--m5-active);color:var(--m5-text);}
.m5-link[aria-current="page"] {font-weight:750;}
.m5-nav-group {margin-top:19px;}
.m5-nav-group > summary {
 display:flex;align-items:center;justify-content:space-between;
 min-height:31px;padding:0 13px;
 list-style:none;
 font-size:12px;
 line-height:1.4;
 color:#544b63;
 font-weight:650;
 cursor:pointer;
}
.m5-nav-group summary::-webkit-details-marker {display:none;}
.m5-nav-group summary::after {
 content:"";width:7px;height:7px;
 border-right:1.7px solid currentColor;border-bottom:1.7px solid currentColor;
 transform:rotate(45deg);transition:transform .13s;
 margin-right:4px;
}
.m5-nav-group[open] > summary::after {transform:rotate(225deg) translate(-2px,-2px);}
.m5-nav-group nav {padding-top:4px;}
.m5-nav-group .m5-link {font-size:13px;min-height:37px;padding-block:7px;}
.m5-rail-spacer {flex:1;min-height:24px;}
.m5-rail-compose {padding:10px 13px 20px;}
.m5-new-post {
 border:0;box-sizing:border-box;
 display:inline-flex;align-items:center;justify-content:center;gap:10px;
 border-radius:999px;
 padding:10px 20px;
 min-height:42px;
 background:var(--m5-purple);
 color:#fff!important;
 font-size:13px;
 font-weight:720;
 cursor:pointer;
 box-shadow:0 2px 4px rgba(64,38,151,.11);
 text-decoration:none!important;
}
.m5-new-post:hover {background:var(--m5-purple-dark);}
.m5-pencil {font-size:20px;font-weight:350;line-height:1;transform:rotate(-17deg);}
.m5-rail-shortcuts {
 display:grid;
 grid-template-columns:repeat(3, minmax(0,1fr));
 align-items:start;
 margin:3px 0 15px!important;
 gap:2px;
}
.m5-shortcut {
 display:flex;align-items:center;justify-content:flex-start;
 flex-direction:column;
 gap:8px;
 min-width:0;
 border-radius:11px;
 padding:8px 2px;
 color:var(--m5-text);
 font-size:10px;
 line-height:1.2;
 font-weight:500;
 text-decoration:none!important;
 text-align:center;
}
.m5-shortcut::before {width:20px;height:20px;flex-basis:20px;}
.m5-shortcut:hover,.m5-shortcut[aria-current="page"] {background:var(--m5-active);}
.m5-account {
 width:100%;box-sizing:border-box;
 display:flex;align-items:center;gap:9px;
 padding:7px 8px;
 border:1px solid #ded6ed;
 border-radius:12px;
 min-height:52px;
 color:var(--m5-text)!important;
 text-decoration:none!important;
}
.m5-account:hover {background:var(--m5-active);}
.m5-account img {border-radius:50%;width:35px;height:35px;flex:none;object-fit:cover;}
.m5-account__text {display:flex;flex:1;min-width:0;flex-direction:column;line-height:1.4;}
.m5-account__text strong {font-size:12px;font-weight:750;overflow-wrap:anywhere;}
.m5-account__text small {color:var(--m5-muted);font-size:11px;overflow-wrap:anywhere;}
.m5-account__more {font-weight:800;letter-spacing:1px;margin-inline:5px;}
.afv-rail .afv-account-menu {margin-top:6px;padding:0 2px;border:0;}
.afv-rail .afv-account-menu summary {border-radius:12px;font-size:12px;padding:7px 11px;background:transparent;}
.afv-rail .afv-account-menu summary:hover {background:var(--m5-active);}

/* Page heading always centered, with a subtle divider. */
.afv-topbar {
 top:0!important;
 position:sticky;
 z-index:9;
 display:flex;
 justify-content:center;
 align-items:center;
 min-height:56px;
 padding:8px 18px;
 box-sizing:border-box;
 border-bottom:1px solid var(--m5-line);
 background:rgba(250,248,255,.94);
 -webkit-backdrop-filter:blur(14px);
 backdrop-filter:blur(14px);
}
.admin-bar .afv-topbar {top:var(--m5-admin)!important;}
.afv-topbar__title {font-size:16px;letter-spacing:-.25px;line-height:1.3;font-weight:720;color:var(--m5-text);text-align:center;}
.m5-topbar-settings {
 display:grid;place-items:center;
 position:absolute;right:14px;top:50%;transform:translateY(-50%);
 border-radius:9px;width:32px;height:32px;
 color:var(--m5-muted);
}
.m5-topbar-settings:hover {background:var(--m5-hover);color:var(--m5-purple);}
.afv-back {position:absolute;left:14px;top:50%;transform:translateY(-50%);color:var(--m5-text);}

/* Feed and tabs: separating lines, no cards or masonry shadows. */
.afv-main > .afv-tabs,.afv-main > .afv-home-tabs,.afv-main > .afv-feed-status { margin:0!important; }
.afv-tabs,.afv-home-tabs {
 display:flex;
 padding:0 12px;
 border-bottom:1px solid var(--m5-line);
 background:transparent;
 border-radius:0;
 box-shadow:none;
}
.afv-tabs a,.afv-home-tabs a { color:var(--m5-muted);border-radius:0;font-weight:650;padding:12px 15px; }
.afv-tabs a:hover,.afv-home-tabs a:hover {background:var(--m5-hover);color:var(--m5-text);}
.afv-tabs a[aria-current],.afv-tabs a[aria-current="page"] {color:var(--m5-purple);border-bottom-color:var(--m5-purple);box-shadow:inset 0 -2px 0 var(--m5-purple);}
.afv-feed-status, .afv-new-posts {padding:8px 15px;border-bottom:1px solid var(--m5-line);}
.afv-timeline {margin:0!important;}
.afv-timeline .wp-block-post-template {list-style:none;padding:0;margin:0;display:block;gap:0;}
.afv-timeline .wp-block-post-template > li {list-style:none;margin:0!important;padding:0!important;}
.afv-timeline .wp-block-post-template > li > * {margin:0!important;}
.afv-post--list {
 box-sizing:border-box;
 display:grid;
 grid-template-columns:40px minmax(0,1fr);
 gap:11px;
 padding:14px 16px 11px!important;
 border:0;
 border-bottom:1px solid var(--m5-line);
 border-radius:0;
 background:transparent;
 box-shadow:none;
 transition:background .12s ease;
 cursor:pointer;
}
.afv-post--list:hover {background:#f4f1fb;box-shadow:none;}
.afv-post--list .wp-block-avatar {margin:0!important;}
.afv-post--list > .wp-block-avatar img {display:block;width:40px;height:40px;border-radius:50%;object-fit:cover;}
.afv-post__body {min-width:0;}
.afv-post__body > * {margin-block:0;}
.afv-post__body > * + * {margin-block-start:7px;}
.afv-post__meta {display:flex;flex-wrap:wrap;align-items:baseline;gap:2px 5px;line-height:1.35;font-size:12px;}
.afv-post__meta .wp-block-post-author-name a,
.afv-post__meta .wp-block-post-author-name {font-size:13px;color:var(--m5-text);font-weight:760;}
.afv-post__meta .afv-handle,.afv-post__meta .wp-block-post-date,.afv-post__meta .wp-block-post-date a {font-size:11px;color:var(--m5-muted);}
.afv-post__title {font-size:16px;font-weight:725;letter-spacing:-.15px;line-height:1.4;}
.afv-post__title a {color:var(--m5-text);}
.afv-post__content,.afv-post__excerpt {font-size:13px;line-height:1.56;color:var(--m5-text);}
.afv-post__content > :first-child {margin-top:0;}
.afv-post__content > :last-child {margin-bottom:0;}
.afv-post__content a {color:var(--m5-purple);}
.afv-post__content img,.afv-post__image img,.afv-post__body video,.afv-media img {max-width:100%;height:auto;border-radius:12px;}
.afv-post__image img {display:block;width:100%;}
.afv-post--list .afv-actions {max-width:none;justify-content:flex-start;gap:clamp(10px,5%,32px);margin:9px 0 0!important;padding:0;border:0;flex-wrap:wrap;}
.afv-actions .afv-action {display:inline-flex;gap:5px;align-items:center;min-width:26px;min-height:26px;padding:2px 5px;border-radius:999px;font-size:11px;color:#776f88;}
.afv-actions .afv-action svg {width:17px;height:17px;}
.afv-actions .afv-action--like svg {display:block;}
.afv-actions .afv-action--like::before {display:none;content:none;}
.afv-actions .afv-action--reply:hover {color:var(--m5-purple);background:var(--m5-hover);}
.afv-actions .afv-action--like:hover {color:var(--m5-purple);background:var(--m5-hover);}
.afv-post--single {padding:18px;border:0;border-bottom:1px solid var(--m5-line);border-radius:0;background:transparent;box-shadow:none;}
.afv-thread {margin:0!important;border:0;border-radius:0;box-shadow:none;}
.afv-reply {border-bottom:1px solid var(--m5-line);padding:14px 18px;}
.afv-reply-form {padding:18px;border-bottom:1px solid var(--m5-line);background:transparent;border-radius:0;box-shadow:none;}
.afv-pagination,.afv-empty {border:0;border-bottom:1px solid var(--m5-line);background:transparent;box-shadow:none;border-radius:0;padding:15px;}

/* User profiles: same feed canvas with softened banner and borderless content. */
.afv-main > .afv-profile,.afv-main > .afv-remote-profile,.afv-main .afv-profile {
 margin:0!important;border:0;border-bottom:1px solid var(--m5-line);
 border-radius:0;background:transparent;box-shadow:none;overflow:hidden;
}
.afv-profile__cover {aspect-ratio:3.8/1;background:linear-gradient(115deg,#b9a5ef,#ded2ff 48%,#d0e4db);}
.afv-profile__head {padding:14px 18px 7px;}
.afv-profile__avatar {border:4px solid var(--m5-feed);box-shadow:none;border-radius:50%;}
.afv-profile__text {padding:6px 18px 16px;}
.afv-profile__name {font-size:21px;font-weight:760;white-space:normal;overflow:visible;text-overflow:clip;overflow-wrap:anywhere;}
.afv-profile__counts {padding-bottom:14px;}
.afv-profile__buttons .wp-element-button {border-radius:999px;}

/* Right column. Minimal space, search and server footer. */
.afv-side {
 position:sticky!important;
 top:var(--m5-admin)!important;
 height:calc(100vh - var(--m5-admin))!important;
 max-height:calc(100vh - var(--m5-admin));
 overflow-y:auto;
 scrollbar-width:none;
 -ms-overflow-style:none;
 overscroll-behavior-y:contain;
}
.afv-side__inner.m5-side-inner {
 box-sizing:border-box;
 display:flex;flex-direction:column;
 gap:0;
 min-height:100%;
 width:100%;
 padding:29px 12px 15px 12px;
}
.m5-search {width:100%;max-width:100%;margin:0!important;}
.m5-search .wp-block-search__inside-wrapper {
 display:flex;align-items:center;min-height:38px;
 border:1px solid #d6cdeb;
 border-radius:999px;
 padding:0 9px 0 13px;
 background:transparent;
}
.m5-search .wp-block-search__inside-wrapper:focus-within {border-color:var(--m5-purple);box-shadow:0 0 0 2px rgba(86,56,214,.11);}
.m5-search .wp-block-search__input {min-width:0;flex:1;border:0;background:transparent;color:var(--m5-text);padding:8px 5px;font-size:12px;box-shadow:none;outline:none;}
.m5-search .wp-block-search__button {display:grid;place-items:center;order:-1;background:transparent;color:var(--m5-muted);border:0;padding:5px;margin:0;min-width:28px;}
.m5-search .wp-block-search__button svg {width:17px;height:17px;fill:currentColor;}
.m5-side-footer {margin-top:auto!important;padding:22px 8px 5px;font-size:11px;line-height:1.7;color:var(--m5-muted);}
.m5-side-footer strong {font-weight:550;font-size:11px;display:block;color:var(--m5-muted);}
.m5-side-footer a {color:var(--m5-muted);}
.m5-side-footer small {display:block;font-size:10px;}

/* Plugin subpages: no white rectangular 'paper' on a lavender feed. */
.afv-main.afv-main--paper {min-height:100vh;padding:0;background:var(--m5-feed);border-radius:0;box-shadow:none;}
.afv-main--paper > .afv-topbar {padding:8px 18px;}
.afv-main--paper > .afv-page {padding:18px;}
.afv-main > :is(.afv-about,.afv-discover,.afv-directory,.afv-trends,.afv-suggest,.afv-list-index,
 .afv-prefpage,.afv-prefs,.afv-signup,.afv-login,.afv-filter-list,.afv-people,
 .afv-full-list,.afv-notify-settings,.afv-dm-list,.afv-dm-chat,.afv-photos,
 .afv-collections,.afv-article-reader,.afv-professional-hub,.afv-messages) {
 box-sizing:border-box;margin:0!important;padding:18px;
 border:0;border-radius:0;background:transparent;box-shadow:none;
}
.afv-main :is(.afv-card,.afv-news-card,.afv-photo,.afv-remote-result,.afv-quote,.afv-panel,.afv-welcome) {border-radius:12px;}
.afv-main :is(input,textarea,select):not([type=checkbox]):not([type=radio]) {accent-color:var(--m5-purple);}
.afv-main :is(button.wp-element-button,.wp-block-button__link) {border-radius:999px;background:var(--m5-purple);color:#fff;}
.afv-main :is(button.wp-element-button,.wp-block-button__link):hover {background:var(--m5-purple-dark);}

/* Mastodon 5-like bottom-center native composer popout. Dialog remains plugin-owned. */
.afv-main > .afv-composer-wrap,.afv-main > .afv-composer {display:none;}
dialog.afv-dialog--compose {
 position:fixed;
 z-index:999999;
 inset:auto auto 0 50%;
 top:auto!important;
 left:50%;right:auto;bottom:0;
 margin:0;
 transform:translateX(-50%);
 width:min(560px,calc(100vw - 28px));
 max-width:calc(100vw - 28px);
 max-height:min(79vh,700px);
 box-sizing:border-box;
 overflow:auto;
 padding:17px 17px 14px;
 border:1px solid #d8cfed;
 border-bottom:0;
 border-radius:16px 16px 0 0;
 background:var(--m5-feed);
 color:var(--m5-text);
 box-shadow:0 -8px 40px rgba(43,28,80,.16),0 2px 12px rgba(43,28,80,.07);
}
dialog.afv-dialog--compose::backdrop {background:rgba(35,28,53,.11);}
.afv-dialog--compose h2 {font-size:16px;font-weight:760;margin:0 28px 14px 0;color:var(--m5-text);}
.afv-dialog--compose .afv-dialog__close {top:10px;right:12px;}
.afv-dialog--compose .afv-dialog__close button {border-radius:50%;width:29px;height:29px;background:transparent;color:var(--m5-muted);font-size:23px;}
.afv-dialog--compose .afv-dialog__close button:hover {background:var(--m5-hover);}
.afv-dialog--compose .afv-composer {background:transparent;padding:0;border:0;box-shadow:none;grid-template-columns:36px minmax(0,1fr);gap:10px;}
.afv-dialog--compose .afv-composer__avatar img {width:36px;height:36px;}
.afv-dialog--compose .afv-composer textarea {
 min-height:116px;width:100%;padding:12px;
 border:1.5px solid var(--m5-purple);
 border-radius:10px;
 background:transparent;
 box-sizing:border-box;
 color:var(--m5-text);
 font:inherit;font-size:14px;
}
.afv-dialog--compose .afv-composer textarea:focus {outline:0;box-shadow:0 0 0 1px rgba(86,56,214,.18);}
.afv-dialog--compose .afv-composer__bar {display:flex;align-items:center;gap:5px;flex-wrap:wrap;margin-top:12px;}
.afv-dialog--compose .afv-tool {border-radius:9px;padding:7px;color:var(--m5-muted);}
.afv-dialog--compose .afv-tool:hover {background:var(--m5-hover);color:var(--m5-purple);}
.afv-dialog--compose .afv-composer__visibility,.afv-dialog--compose .afv-composer__language {border-color:var(--m5-line);border-radius:999px;background:transparent;color:var(--m5-text);}
.afv-dialog--compose .afv-composer__submit {border-radius:999px!important;background:var(--m5-purple)!important;color:#fff!important;font-weight:720;font-size:12px;padding:8px 18px;}
.afv-dialog--compose .afv-composer__submit:hover {background:var(--m5-purple-dark)!important;}
/* Native FediPress floating write button is reserved for compact/mobile screens. */
.afv-fab {display:none!important;background:var(--m5-purple);border-radius:50%;color:#fff;}
.afv-fab:hover {background:var(--m5-purple-dark);}

/* Neutralize the original theme's old 'card' styling on all post actions. */
.wp-element-button,.wp-block-button__link {background:var(--m5-purple);color:#fff;border-radius:999px;}
.wp-element-button:hover,.wp-block-button__link:hover {background:var(--m5-purple-dark);}

@media (max-width:1120px) {
 .afv-shell {grid-template-columns:minmax(210px,260px) minmax(0,560px) minmax(190px,260px);}
 .afv-rail__inner.m5-rail-inner {padding-left:10px;padding-right:8px;}
}
@media (max-width:940px) {
 .afv-shell {grid-template-columns:255px minmax(0,600px);max-width:855px;}
 .afv-side {display:none!important;}
}
@media (max-width:720px) and (min-width:601px) {
 .afv-shell {grid-template-columns:76px minmax(0,1fr);max-width:720px;}
 .afv-rail__inner.m5-rail-inner {padding:12px 6px;align-items:center;}
 .m5-identity {padding:4px 0 20px;}
 .m5-identity__text,.m5-link span,.m5-shortcut span,.m5-account__text,.m5-account__more,.m5-nav-group summary,.m5-new-post {display:none;}
 .m5-primary,.m5-nav-group,.m5-nav-group nav {width:100%;}
 .m5-nav-group {margin:9px 0 0;}
 .m5-nav-group:not([open]) {display:none;}
 .m5-link {justify-content:center;padding:11px 0;min-height:44px;}
 .m5-link::before {width:21px;height:21px;flex-basis:21px;}
 .m5-rail-compose {padding:0;}
 .m5-rail-shortcuts {grid-template-columns:1fr;gap:6px;}
 .m5-shortcut {padding:8px;}
 .m5-account {padding:6px;justify-content:center;}
 .afv-rail .afv-account-menu {display:none;}
 .afv-fab {display:grid!important;bottom:22px;right:20px;}
}
@media (max-width:600px) {
 .afv-shell {display:block;width:100%;max-width:600px;margin:0 auto!important;padding-bottom:calc(68px + env(safe-area-inset-bottom,0px));}
 .afv-main {width:100%;min-height:calc(100vh - 65px);border-left:0;border-right:0;}
 .afv-topbar {min-height:52px;padding:8px 14px;}
 .afv-topbar__title {font-size:16px;}
 .afv-rail {
  position:fixed!important;inset:auto 0 0 0!important;
  width:100%!important;height:calc(61px + env(safe-area-inset-bottom,0px))!important;
  max-height:none!important;z-index:100;
  overflow:hidden;
  background:var(--m5-feed);
  border-top:1px solid var(--m5-line);
  box-shadow:0 -6px 20px rgba(30,20,64,.045);
 }
 .afv-rail__inner.m5-rail-inner {
  height:100%;min-height:0;display:grid;
  grid-template-columns:3fr 3fr 1fr;
  grid-template-areas:"main shortcuts profile";
  padding:0 8px env(safe-area-inset-bottom,0px);
  align-items:center;
 }
 .m5-identity,.m5-nav-group,.m5-rail-spacer,.m5-rail-compose,.afv-rail .afv-account-menu {display:none!important;}
 .m5-primary {grid-area:main;display:flex;flex-direction:row;justify-content:space-around;gap:0;min-width:0;}
 .m5-primary .m5-link {flex:1;min-width:0;min-height:52px;border-radius:9px;flex-direction:column;justify-content:center;gap:3px;padding:5px 2px;font-size:10px;text-align:center;}
 .m5-primary .m5-link::before {width:19px;height:19px;flex-basis:19px;}
 .m5-primary .m5-link span {display:block;}
 .m5-rail-shortcuts {grid-area:shortcuts;margin:0!important;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0;}
 .m5-shortcut {min-width:0;min-height:52px;padding:5px 2px;gap:4px;border-radius:9px;justify-content:center;font-size:10px;}
 .m5-shortcut::before {width:19px;height:19px;flex-basis:19px;}
 .m5-account {grid-area:profile;justify-self:center;display:flex;flex-direction:column;justify-content:center;min-height:52px;width:auto;border:0;border-radius:9px;padding:6px 9px;}
 .m5-account img {width:25px;height:25px;}
 .m5-account__text {display:none;}
 .m5-account__more {display:none;}
 .afv-fab {display:grid!important;position:fixed;right:17px;bottom:calc(78px + env(safe-area-inset-bottom,0px));width:54px;height:54px;z-index:90;}
 .afv-post--list {grid-template-columns:38px minmax(0,1fr);gap:10px;padding:12px 12px 9px!important;}
 .afv-post--list > .wp-block-avatar img {height:38px;width:38px;}
 .afv-post__content,.afv-post__excerpt {font-size:13px;}
 .afv-post--list .afv-actions {gap:clamp(4px,4%,25px);}
 .afv-side {display:none!important;}
 dialog.afv-dialog--compose {width:100vw;max-width:100vw;max-height:calc(95svh - env(safe-area-inset-bottom,0px));border-radius:18px 18px 0 0;padding-bottom:calc(14px + env(safe-area-inset-bottom,0px));}
}
@media (max-width:370px) {
 .m5-primary .m5-link,.m5-shortcut {font-size:9px;}
 .m5-rail-shortcuts {gap:0;}
 .m5-primary .m5-link {padding-inline:0;}
 .m5-account {padding-inline:4px;}
}
@media (max-width:782px) {
 body.admin-bar {--m5-admin:46px;}
}
@media (prefers-reduced-motion:reduce) {
 *, *::before, *::after {scroll-behavior:auto!important;transition:none!important;}
}
/* Extra navigation icons absent from the original block theme icon collection. */
/* Grupper is the dedicated FediPress groups directory, distinct from Fællesskaber. */
.afv-i-groups {--afv-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8.5 11a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7zM3 19v-1.2C3 14.6 5.4 13 8.5 13S14 14.6 14 17.8V19H3zM17 10.5a3 3 0 1 0 0-6 3 3 0 0 0 0 6zm-1.6 3c.5-.3 1.1-.5 1.8-.5 2.6 0 4.8 1.5 4.8 4.5V19h-6v-1.2c0-1.7-.2-3.1-.6-4.3z'/%3E%3C/svg%3E");}

.afv-i-trends {--afv-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2 14 9l7 3-7 2-2 8-3-8-7-2 7-3zm7 0 1 2 2 1-2 1-1 2-1-2-2-1 2-1z'/%3E%3C/svg%3E");}
.afv-i-drafts {--afv-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 3h10l4 4v14H5zM7 5v14h10V8h-3V5zm2 7h6v2H9zm0 4h5v2H9z'/%3E%3C/svg%3E");}
.afv-i-photos {--afv-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 4h18v16H3zm2 2v12h14V6zm3 1a2 2 0 1 1 0 4 2 2 0 0 1 0-4m-3 9 4-4 3 3 3-5 4 6z'/%3E%3C/svg%3E");}
/* FediPress's own account switcher is the actual interactive desktop account card.
   The parallel simple profile link is retained for the mobile bottom navigation. */
@media (min-width:721px) {
 .afv-rail .m5-account {display:none!important;}
 .afv-rail .afv-account-menu {position:relative;margin-top:2px;padding:0;border:0;}
 .afv-rail .afv-account-menu > summary {
  box-sizing:border-box;display:flex;align-items:center;gap:9px;
  border:1px solid #ded6ed;border-radius:12px;
  min-height:52px;padding:7px 10px;
 }
 .afv-rail .afv-account-menu > summary:hover {background:var(--m5-active);}
 .afv-rail .afv-account-menu .afv-switch__who strong {font-size:12px;font-weight:750;white-space:normal;overflow:visible;text-overflow:clip;overflow-wrap:anywhere;}
 .afv-rail .afv-account-menu .afv-switch__who span {font-size:11px;}
 .afv-rail .afv-account-menu__panel {
  position:absolute;bottom:calc(100% + 7px);left:0;right:0;
  margin:0;padding:10px;
  border-radius:13px;background:var(--m5-feed);
  box-shadow:0 8px 35px rgba(37,27,65,.15);z-index:15;
 }
}
@media (min-width:601px) and (max-width:720px) {
 .afv-rail .m5-account {display:flex!important;}
 .afv-rail .afv-account-menu {display:none!important;}
}


/* Version 1.0.2 — group navigation, group toolbar, genuine follow suggestions. */
/* Keep the duplicate mobile-only Groups shortcut in the bottom navigation;
   on larger screens Groups appears only under Dine feeds. */
.m5-primary .m5-mobile-groups {display:none!important;}
@media (max-width:600px) {
 .m5-primary .m5-mobile-groups {display:flex!important;}
}

/* Groups header: refresh next to Create group, while keeping title readable. */
.afv-main .afv-g-top.m5-groups-header {
 justify-content:space-between;
 flex-wrap:wrap;
 gap:9px;
 padding:10px 14px;
}
.afv-main .m5-groups-header .afv-topbar__title {
 margin:0 auto 0 0;
 text-align:left;
 white-space:normal;
 text-overflow:clip;
 overflow:visible;
}
/* Equal-sized actions: same grid track, same min-height and typography for both
   the plugin's existing link and its existing refresh button. */
.m5-groups-header-actions {
 display:grid;
 grid-template-columns:repeat(2,minmax(0,1fr));
 align-items:stretch;
 gap:8px;
 width:min(100%,388px);
 min-width:0;
 margin:0;
}
.afv-main .m5-groups-header-actions .wp-element-button {
 box-sizing:border-box;
 display:inline-flex;
 align-items:center;
 justify-content:center;
 align-self:stretch;
 width:100%;
 min-width:0;
 min-height:42px;
 padding:9px 10px;
 margin:0;
 border:1px solid transparent;
 border-radius:999px;
 line-height:1.35;
 font-size:12px;
 font-weight:650;
 white-space:normal;
 text-align:center;
 text-decoration:none;
}
.afv-main .m5-groups-header-actions [data-afv-g-call="groups/feed/refresh"] {
 background:transparent;
 color:var(--m5-purple);
 border-color:#cfc4e6;
}
.afv-main .m5-groups-header-actions [data-afv-g-call="groups/feed/refresh"]:hover {
 background:var(--m5-hover);
}
@media (max-width:720px) {
 .afv-main .m5-groups-header .afv-topbar__title {flex-basis:100%;}
 .m5-groups-header-actions {width:100%;max-width:100%;}
}

/* Familiar sidebar recommendation card, using native plugin recommendations. */
.m5-follow-suggestions {margin:20px 0 0;min-width:0;}
.m5-follow-suggestions .afv-suggest {
 box-sizing:border-box;
 margin:0;
 padding:15px 13px 13px;
 border:1px solid var(--m5-line);
 background:rgba(250,248,255,.7);
 border-radius:15px;
 box-shadow:none;
}
.m5-follow-suggestions .afv-panel__title {
 margin:0 0 10px;
 font-size:14px;
 font-family:inherit;
 line-height:1.3;
 font-weight:760;
 letter-spacing:-.1px;
 color:var(--m5-text);
}
.m5-follow-suggestions .afv-suggest ul {padding:0;margin:0;list-style:none;}
.m5-follow-suggestions .afv-suggest li {
 min-width:0;
 padding:11px 0;
 border-top:1px solid var(--m5-line);
}
.m5-follow-suggestions .afv-follow__who {
 display:flex;
 gap:9px;
 align-items:flex-start;
 min-width:0;
 text-decoration:none;
}
.m5-follow-suggestions .afv-follow__who img {
 width:36px;height:36px;flex:none;
 object-fit:cover;border-radius:50%;
}
.m5-follow-suggestions .afv-follow__text {display:block;flex:1;min-width:0;}
.m5-follow-suggestions .afv-follow__text strong {
 display:block;
 color:var(--m5-text);
 font-size:12px;
 font-weight:730;
 line-height:1.4;
 overflow-wrap:anywhere;
}
.m5-follow-suggestions .afv-follow__text > span {
 display:block;
 color:var(--m5-muted);
 font-size:11px;
 line-height:1.35;
 white-space:normal;
 overflow-wrap:anywhere;
}
.m5-follow-suggestions .afv-suggest__why {margin-top:3px;white-space:normal;}
.m5-follow-suggestions .afv-suggest__buttons {margin:7px 0 0 45px;gap:7px;}
.m5-follow-suggestions .afv-suggest__buttons .wp-element-button {
 padding:5px 10px;
 border-radius:999px;
 font-size:11px;
 min-height:28px;
}
.m5-follow-suggestions .afv-suggest .afv-mod {
 padding:5px 4px;
 border:0;
 background:transparent;
 color:var(--m5-muted);
 font-size:11px;
}
.m5-follow-suggestions .afv-panel__more {
 display:block;
 margin:6px 0 0;
 padding-top:10px;
 border-top:1px solid var(--m5-line);
 font-size:11px;
 font-weight:650;
}
.m5-follow-suggestions .afv-panel__more a {text-decoration:none;}

/* Version 1.0.4 — Nyheder joins the main navigation after Udforsk.
   Four main links share the mobile bottom rail without crowding shortcuts. */
@media (max-width:600px) {
 .afv-rail__inner.m5-rail-inner {grid-template-columns:4fr 3fr 1fr;}
}


/* 1.0.5 — Consistent country flags in FediPress language selectors.
   FediPress already outputs 🇩🇰 and 🇬🇧, but some browsers display the
   Unicode regional letters DK/GB instead. Use bundled SVG assets rather than
   depending on color emoji fonts. The plugin continues to handle filtering. */
:is(
 .afv-home-langs__flag[data-afv-home-lang="da"],
 .afv-home-langs__flag[data-afv-home-lang="en"],
 .afv-home-langs__flag[href*="sprog=da"],
 .afv-home-langs__flag[href*="sprog=en"],
 .afv-advanced-search__flag:has(input[value="da"]),
 .afv-advanced-search__flag:has(input[value="en"])
) > span[aria-hidden="true"] {
 font-size:0!important;
 line-height:0;
 display:inline-flex;
 align-items:center;
 justify-content:center;
 vertical-align:middle;
}
:is(
 .afv-home-langs__flag[data-afv-home-lang="da"],
 .afv-home-langs__flag[href*="sprog=da"],
 .afv-advanced-search__flag:has(input[value="da"])
) > span[aria-hidden="true"]::before,
:is(
 .afv-home-langs__flag[data-afv-home-lang="en"],
 .afv-home-langs__flag[href*="sprog=en"],
 .afv-advanced-search__flag:has(input[value="en"])
) > span[aria-hidden="true"]::before {
 content:"";
 display:block;
 width:25px;
 height:17px;
 flex:none;
 border-radius:2px;
 box-shadow:0 0 0 1px rgba(26,24,45,.18);
 background-position:center;
 background-size:cover;
 background-repeat:no-repeat;
}
:is(
 .afv-home-langs__flag[data-afv-home-lang="da"],
 .afv-home-langs__flag[href*="sprog=da"],
 .afv-advanced-search__flag:has(input[value="da"])
) > span[aria-hidden="true"]::before {background-image:url("../flags/dk.svg");}
:is(
 .afv-home-langs__flag[data-afv-home-lang="en"],
 .afv-home-langs__flag[href*="sprog=en"],
 .afv-advanced-search__flag:has(input[value="en"])
) > span[aria-hidden="true"]::before {background-image:url("../flags/gb.svg");}


/* 1.0.6 — Native live unread badges on notifications and messages.
   FediPress front.js already owns the counts, updates and removal. The shortcut
   containers match the selectors it expects; theme CSS supplies red badges.
   Because the number is injected only for unread notifications, zero stays
   invisible. Works in desktop, compact rail and mobile bottom navigation. */
.m5-rail-shortcuts .m5-shortcut-slot {
 min-width:0;
 width:100%;
}
.m5-rail-shortcuts .m5-shortcut-slot > .m5-shortcut {
 position:relative;
 width:100%;
 box-sizing:border-box;
}
.m5-rail-shortcuts .m5-shortcut-slot .m5-shortcut .afv-badge {
 position:absolute;
 z-index:1;
 inset-block-start:0;
 inset-inline-start:calc(50% + 5px);
 display:inline-grid!important;
 place-items:center;
 min-width:20px;
 height:20px;
 padding:0 4px;
 box-sizing:border-box;
 border-radius:999px;
 border:2px solid var(--m5-bg);
 background:#d62839;
 color:#fff;
 font-family:inherit;
 font-size:10px;
 line-height:1;
 font-weight:750;
 white-space:nowrap;
 pointer-events:none;
 box-shadow:0 1px 3px rgba(100,25,40,.15);
}
@media (max-width:600px) {
 .m5-rail-shortcuts .m5-shortcut-slot .m5-shortcut .afv-badge {
  inset-block-start:1px;
  inset-inline-start:calc(50% + 4px);
  min-width:19px;
  height:19px;
  border-color:var(--m5-feed);
 }
}

/* 1.1.0 — Personalisering, komponering, profiler, anbefalinger og notifikationer. */
html:root {
 --m5-card:#faf8ff;
 --m5-field:#fff;
 --m5-panel-border:#ded7eb;
 --m5-dim:rgba(33,24,59,.38);
 --m5-note-unread:#f3eefc;
 --m5-note-follow:#378d74;
 --m5-note-reply:#5d45d5;
 --m5-note-like:#d63d73;
 --m5-note-quote:#a26a27;
}
/* FediPress 0.0.3+ owns light/dark/auto through data-afv-theme on <html>.
 * Never infer dark mode independently from OS when the server forced light. */
html:root[data-afv-theme="dark"] {
 --m5-bg:#12101b;--m5-feed:#201c2c;--m5-card:#282333;--m5-field:#1b1826;
 --m5-text:#f1edf9;--m5-muted:#b4aabf;--m5-line:#393247;--m5-hover:#302a3e;
 --m5-active:#3a3058;--m5-panel-border:#494055;--m5-dim:rgba(5,3,11,.64);
 --m5-note-unread:#352d47;--m5-purple:#a58cff;--m5-purple-dark:#8e70f5;
 color-scheme:dark;
 }
@media (prefers-color-scheme:dark) {
 html:root[data-afv-theme="auto"] {
 --m5-bg:#12101b;--m5-feed:#201c2c;--m5-card:#282333;--m5-field:#1b1826;
 --m5-text:#f1edf9;--m5-muted:#b4aabf;--m5-line:#393247;--m5-hover:#302a3e;
 --m5-active:#3a3058;--m5-panel-border:#494055;--m5-dim:rgba(5,3,11,.64);
 --m5-note-unread:#352d47;--m5-purple:#a58cff;--m5-purple-dark:#8e70f5;
 color-scheme:dark;
 }
}
/* Accent is independent of the light/dark preference, and remains browser-local. */
html:root[data-m5-accent="blue"] {--m5-purple:#2563c8;--m5-purple-dark:#174caa;--afv-c-iris:#2563c8;--afv-c-reply:#2563c8;--wp--preset--color--iris:#2563c8;--m5-active:#dbe8fa;--m5-hover:#e9f0fc;}
html:root[data-m5-accent="green"] {--m5-purple:#087d62;--m5-purple-dark:#06634e;--afv-c-iris:#087d62;--afv-c-reply:#087d62;--wp--preset--color--iris:#087d62;--m5-active:#d9f1e9;--m5-hover:#e8f6f1;}
html:root[data-afv-theme="dark"][data-m5-accent="blue"] {--m5-purple:#7db8ff;--m5-purple-dark:#5b9ef7;--afv-c-iris:#7db8ff;--wp--preset--color--iris:#7db8ff;--m5-active:#233b57;--m5-hover:#293a50;}
html:root[data-afv-theme="dark"][data-m5-accent="green"] {--m5-purple:#67d5b0;--m5-purple-dark:#47bc96;--afv-c-iris:#67d5b0;--wp--preset--color--iris:#67d5b0;--m5-active:#1a4239;--m5-hover:#24483e;}
@media (prefers-color-scheme:dark) {
 html:root[data-afv-theme="auto"][data-m5-accent="blue"] {--m5-purple:#7db8ff;--m5-purple-dark:#5b9ef7;--afv-c-iris:#7db8ff;--wp--preset--color--iris:#7db8ff;--m5-active:#233b57;--m5-hover:#293a50;}
 html:root[data-afv-theme="auto"][data-m5-accent="green"] {--m5-purple:#67d5b0;--m5-purple-dark:#47bc96;--afv-c-iris:#67d5b0;--wp--preset--color--iris:#67d5b0;--m5-active:#1a4239;--m5-hover:#24483e;}
}
.afv-main,.afv-side,.afv-rail,.m5-appearance-dialog {color:var(--m5-text);}
.afv-topbar {background:var(--m5-feed);background:color-mix(in srgb,var(--m5-feed) 94%,transparent);}
.afv-post--list:hover {background:var(--m5-hover);}
.m5-nav-group > summary {color:var(--m5-muted);}
.m5-follow-suggestions .afv-suggest,.m5-context-panels .afv-panel {background:var(--m5-card);}
.afv-rail .afv-account-menu > summary,.m5-search .wp-block-search__inside-wrapper {border-color:var(--m5-panel-border);}
.afv-rail .afv-account-menu__panel {background:var(--m5-card);}
.afv-main :is(input,textarea,select):not([type="checkbox"]):not([type="radio"]),
.afv-dialog--compose :is(input,textarea,select):not([type="checkbox"]):not([type="radio"]) {background:var(--m5-field);color:var(--m5-text);border-color:var(--m5-panel-border);}
.afv-dialog--compose .afv-composer textarea {background:var(--m5-field);border-color:var(--m5-purple);}
.afv-main :is(.afv-card,.afv-news-card,.afv-remote-result,.afv-quote,.afv-panel,.afv-welcome,.afv-g-card) {background-color:var(--m5-card);color:var(--m5-text);border-color:var(--m5-line);}
.afv-main :is(.afv-composer__count,.afv-profile__facts,.afv-profile__counts,.afv-post__meta) {color:var(--m5-muted);}
.afv-main :is(.afv-post__meta a,.afv-profile__counts strong,.afv-profile__name) {color:var(--m5-text);}
.afv-main :is(.afv-note,.afv-notify-filters,.afv-notes,.afv-profile,.afv-tabs) {border-color:var(--m5-line);}
.afv-main :is(.afv-toolbar,.afv-notify-toolbar,.afv-page,.afv-dm-chat,.afv-prefpage,.afv-form,.afv-groups) {color:var(--m5-text);}
.afv-main .afv-dialog,.afv-dialog {color:var(--m5-text);}
/* Primary controls remain legible with the brighter dark accent.
 * Match the effective plugin preference, not an obsolete local setting. */
html[data-afv-theme="dark"] :is(.m5-new-post,.afv-composer__submit,.wp-block-button__link,.afv-main button.wp-element-button) {color:#181121!important;}
@media (prefers-color-scheme:dark) {html[data-afv-theme="auto"] :is(.m5-new-post,.afv-composer__submit,.wp-block-button__link,.afv-main button.wp-element-button) {color:#181121!important;}}
html[data-afv-theme="dark"] .afv-dialog--compose,html[data-afv-theme="dark"] .afv-dialog:not(.m5-appearance-dialog) {background:var(--m5-feed);border-color:var(--m5-panel-border);}
@media (prefers-color-scheme:dark) {html[data-afv-theme="auto"] .afv-dialog--compose,html[data-afv-theme="auto"] .afv-dialog:not(.m5-appearance-dialog) {background:var(--m5-feed);border-color:var(--m5-panel-border);}}
/* Appearance button; native modal stays outside the fixed navigation. */
.m5-appearance-open {border:0;cursor:pointer;text-align:left;font:inherit;}
.afv-i-palette {--afv-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 0 0 0 20h2a3 3 0 0 0 3-3c0-1.2-.8-2-.8-3 0-.7.6-1 1.5-1H19a3 3 0 0 0 3-3A10 10 0 0 0 12 2ZM7 12a1.7 1.7 0 1 1 0-3.4A1.7 1.7 0 0 1 7 12Zm3-4a1.7 1.7 0 1 1 0-3.4A1.7 1.7 0 0 1 10 8Zm6 0a1.7 1.7 0 1 1 0-3.4A1.7 1.7 0 0 1 16 8Zm2.5 4a1.7 1.7 0 1 1 0-3.4 1.7 1.7 0 0 1 0 3.4Z'/%3E%3C/svg%3E");}
.m5-appearance-dialog {position:fixed;inset:0;margin:auto;border:1px solid var(--m5-line);border-radius:19px;width:min(410px,calc(100vw - 28px));max-height:calc(100svh - 30px);overflow:auto;box-sizing:border-box;padding:21px;background:var(--m5-card);box-shadow:0 24px 70px var(--m5-dim);z-index:1000020;}
.m5-appearance-dialog::backdrop {background:var(--m5-dim);}
.m5-appearance-heading {display:flex;justify-content:space-between;align-items:center;gap:12px;}
.m5-appearance-heading h2 {margin:0;font-size:19px;line-height:1.3;color:var(--m5-text);}
.m5-appearance-close {font-size:26px;line-height:1;background:transparent;border:0;border-radius:50%;color:var(--m5-muted);cursor:pointer;width:35px;height:35px;}
.m5-appearance-close:hover {background:var(--m5-hover);}
.m5-appearance-description {font-size:12px;color:var(--m5-muted);margin:4px 0 17px;}
.m5-choice-group {border:0;padding:0;margin:12px 0 20px;min-width:0;}
.m5-choice-group legend {font-size:12px;font-weight:750;color:var(--m5-text);padding:0 0 9px;}
.m5-choice-row {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;}
.m5-choice-row button {display:flex;align-items:center;justify-content:center;gap:7px;min-height:42px;padding:8px 4px;font:inherit;font-size:12px;border:1px solid var(--m5-line);border-radius:10px;background:var(--m5-feed);color:var(--m5-text);cursor:pointer;}
.m5-choice-row button[aria-pressed="true"] {border:2px solid var(--m5-purple);background:var(--m5-hover);font-weight:740;}
.m5-color-dot {width:13px;height:13px;border-radius:50%;display:block;flex:none;}
.m5-color-purple {background:#5638d6;}.m5-color-blue {background:#2563c8;}.m5-color-green {background:#087d62;}
.m5-mobile-appearance {display:none;position:absolute;right:12px;top:50%;transform:translateY(-50%);border:0;background:transparent;border-radius:9px;width:36px;height:36px;color:var(--m5-text);cursor:pointer;}
.m5-mobile-appearance:hover {background:var(--m5-hover);}

/* Composer: native publish/draft logic, new visible visibility + save + minimize controls. */
dialog.afv-dialog--compose {border-color:var(--m5-panel-border);background:var(--m5-feed);}
.afv-dialog--compose h2 {margin-right:0;padding-right:0;}
.m5-composer-head {display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:0 34px 9px 0;border-bottom:1px solid var(--m5-line);margin-bottom:13px;}
.m5-composer-head h2 {flex:1;min-width:110px;margin:0!important;}
.m5-composer-head .m5-composer-save,.m5-composer-minimize,.m5-composer-head .m5-drafts-link {padding:7px 9px;border:1px solid var(--m5-line);border-radius:999px;background:var(--m5-card);color:var(--m5-text);font-size:11px;font-weight:650;text-decoration:none;cursor:pointer;white-space:nowrap;}
.m5-composer-head .m5-composer-save:hover,.m5-composer-minimize:hover {background:var(--m5-hover);}
.m5-composer-vis {display:inline-flex;gap:6px;align-items:center;padding:7px 0 3px;margin:0 0 5px;font-size:12px;font-weight:650;color:var(--m5-muted);}
.m5-composer-vis .afv-composer__visibility {max-width:195px;padding:6px 12px;border:1px solid var(--m5-line);border-radius:999px;background:var(--m5-field);color:var(--m5-text);font-size:12px;}
.m5-resume-composer {position:fixed;bottom:17px;left:50%;transform:translateX(-50%);border:1px solid var(--m5-panel-border);border-radius:999px;padding:11px 19px;background:var(--m5-card);color:var(--m5-text);box-shadow:0 5px 28px var(--m5-dim);z-index:98;font-size:13px;font-weight:700;cursor:pointer;}
.m5-resume-composer[hidden] {display:none!important;}

/* Profiles: full size real cover art, large avatar, verified fields and native tabs. */
.afv-profile__cover {aspect-ratio:3.05/1;min-height:125px;background:linear-gradient(125deg,var(--m5-purple),var(--m5-active) 85%);}
.afv-profile__cover img {width:100%;height:100%;object-fit:cover;}
.afv-profile__head {padding:0 20px 8px!important;display:flex;align-items:flex-end;min-height:52px;}
.afv-profile__head .afv-profile__avatar {width:110px;height:110px;object-fit:cover;border:5px solid var(--m5-feed);border-radius:50%;margin-top:-56px;position:relative;z-index:1;box-sizing:border-box;}
.afv-profile__buttons {margin-left:auto;gap:8px;flex-wrap:wrap;justify-content:flex-end;}
.afv-profile__buttons :is(button,a).wp-element-button {padding:8px 16px;font-size:12px;font-weight:720;min-height:35px;}
.afv-profile__text {padding:0 20px 18px!important;}
.afv-profile__id {display:flex;flex-direction:column;gap:1px;}
.afv-profile__name {font-size:23px;line-height:1.18;letter-spacing:-.4px;overflow-wrap:anywhere;}
.afv-profile__handle {font-size:12px;color:var(--m5-muted);}
.afv-profile__bio {font-size:13px;line-height:1.65;overflow-wrap:anywhere;}
.afv-profile__counts {gap:11px 18px;padding:6px 0 4px!important;font-size:12px;}
.afv-profile__counts strong {font-size:14px;color:var(--m5-text);}
.afv-profile__fields {border:1px solid var(--m5-line);border-radius:12px;padding:10px;}
.afv-profile__social {margin-top:10px;}
.afv-main:has(.afv-profile) .afv-tabs {position:sticky;top:56px;z-index:8;background:var(--m5-feed);}
.afv-main:has(.afv-profile) .afv-tabs a {font-size:12px;padding:13px 9px;white-space:nowrap;}

/* Dynamic right rail: independent real datasets, no invented recommendations. */
.m5-context-panels {display:grid;gap:15px;margin:15px 0 0;}
.m5-aside-panel {border:1px solid var(--m5-line);border-radius:15px;background:var(--m5-card);padding:14px 13px;min-width:0;}
.m5-aside-panel > h2,.m5-aside-panel .afv-panel__title {margin:0 0 10px;font-size:14px;font-weight:760;color:var(--m5-text);letter-spacing:-.1px;}
.m5-aside-panel ul {list-style:none;margin:0;padding:0;}
.m5-aside-panel li {padding:10px 0;border-top:1px solid var(--m5-line);}
.m5-aside-panel li:first-child {border-top:0;}
.m5-aside-panel li a {display:flex;align-items:center;gap:9px;color:var(--m5-text);text-decoration:none;min-width:0;}
.m5-aside-panel li a:hover strong {color:var(--m5-purple);}
.m5-aside-panel li a > span:last-child {min-width:0;}
.m5-aside-panel li strong {display:block;font-size:12px;font-weight:680;line-height:1.35;overflow-wrap:anywhere;}
.m5-aside-panel li small,.m5-aside-panel li a span > span {display:block;margin-top:3px;font-size:11px;color:var(--m5-muted);line-height:1.4;}
.m5-aside-panel .afv-panel {padding:0;border:0;box-shadow:none;background:transparent;}
.m5-aside-panel .afv-trends li a {display:flex;flex-direction:column;align-items:flex-start;gap:1px;}
.m5-aside-more,.m5-aside-panel .afv-panel__more {display:block;padding-top:10px;margin:5px 0 0;border-top:1px solid var(--m5-line);color:var(--m5-purple);font-weight:700;font-size:11px;text-decoration:none;}
.m5-group-icon {width:32px;height:32px;border-radius:10px;display:grid!important;place-items:center;background:var(--m5-hover);color:var(--m5-purple);font-size:17px;font-weight:760;flex:none;margin-top:0!important;}
.m5-aside-news li a {display:block;}
.m5-aside-news li small {margin-top:4px;}
.m5-side-footer {margin-top:15px!important;}

/* Notifications: clear category tabs, unread state and semantic icons. */
.afv-notify-filters {display:flex;align-items:center;gap:0!important;overflow-x:auto;scrollbar-width:none;white-space:nowrap;margin:0!important;padding:0 8px!important;border-bottom:1px solid var(--m5-line);border-radius:0!important;background:var(--m5-feed)!important;}
.afv-notify-filters::-webkit-scrollbar {display:none;}
.afv-notify-filters a {flex:none;display:inline-flex;align-items:center;justify-content:center;padding:13px 12px!important;min-height:44px;color:var(--m5-muted)!important;border:0;border-bottom:3px solid transparent!important;border-radius:0!important;background:transparent!important;font-size:12px!important;font-weight:650;text-decoration:none;}
.afv-notify-filters a[aria-current="page"] {color:var(--m5-purple)!important;border-bottom-color:var(--m5-purple)!important;}
.afv-notify-filters a:hover {color:var(--m5-text)!important;background:var(--m5-hover)!important;}
.afv-notes {list-style:none;padding:0!important;margin:0!important;}
.afv-note {position:relative;padding:13px 16px!important;border-bottom:1px solid var(--m5-line);border-radius:0!important;background:transparent;}
.afv-note:hover {background:var(--m5-hover);}
.afv-note.is-unread {background:var(--m5-note-unread);box-shadow:inset 3px 0 var(--m5-purple);}
.afv-note__avatar img {border-radius:50%;}
.afv-note__text {font-size:13px;line-height:1.5;}
.afv-note__excerpt {font-size:12px;line-height:1.5;color:var(--m5-muted);}
.afv-note__text time {font-size:11px;color:var(--m5-muted);}
.afv-note__icon {color:var(--m5-note-reply)!important;}
.afv-note--follow .afv-note__icon,.afv-note--follow_request .afv-note__icon,.afv-note--follow_accepted .afv-note__icon,.afv-note--atproto_follow .afv-note__icon {color:var(--m5-note-follow)!important;}
.afv-note--like .afv-note__icon,.afv-note--atproto_like .afv-note__icon,.afv-note--community_up .afv-note__icon {color:var(--m5-note-like)!important;}
.afv-note--repost .afv-note__icon,.afv-note--quote .afv-note__icon,.afv-note--atproto_repost .afv-note__icon,.afv-note--atproto_quote .afv-note__icon {color:var(--m5-note-quote)!important;}
@media (max-width:600px) {
 .m5-mobile-appearance {display:grid;place-items:center;}
 .m5-resume-composer {bottom:calc(80px + env(safe-area-inset-bottom,0px));width:max-content;max-width:calc(100vw - 24px);}
 .m5-composer-head {gap:5px;padding-right:29px;}
 .m5-composer-head h2 {flex-basis:100%;font-size:15px;}
 .m5-composer-head .m5-composer-save,.m5-composer-minimize,.m5-composer-head .m5-drafts-link {font-size:11px;padding:6px 9px;}
 .afv-profile__cover {aspect-ratio:2.35/1;}
 .afv-profile__head {padding:0 12px 6px!important;}
 .afv-profile__head .afv-profile__avatar {height:85px;width:85px;margin-top:-43px;border-width:4px;}
 .afv-profile__text {padding:0 14px 14px!important;}
 .afv-profile__name {font-size:20px;}
 .afv-main:has(.afv-profile) .afv-tabs {top:51px;overflow:auto;}
 .afv-note {padding:12px 11px!important;}
 .afv-notify-filters a {padding:12px 10px!important;font-size:11px!important;}
}
/* Keep legacy combined filter available to old themes, but remove its duplicate
   tab from FediMast when the new distinct filters are installed. */
.afv-notify-filters:has(a[href*="filter=mentions"]) a[href*="filter=replies"] {display:none!important;}
@media (max-width:600px) {
 /* 4 main tabs, 2 status tabs and 1 avatar; the profile status shortcut would
    otherwise duplicate the avatar and squeeze all seven labels together. */
 .afv-rail__inner.m5-rail-inner {grid-template-columns:minmax(0,4fr) minmax(0,2fr) minmax(0,1fr);}
 .m5-rail-shortcuts {grid-template-columns:repeat(2,minmax(0,1fr));}
 .m5-rail-shortcuts > a.m5-shortcut.afv-i-profile {display:none!important;}
 .m5-primary .m5-link,.m5-shortcut {font-size:9px;min-width:0;overflow:hidden;}
 .m5-primary .m5-link span,.m5-shortcut span {max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
}

/* 1.1.1 — Dark-mode finishing touches for FediPress 0.0.3.0. */
html[data-afv-theme="dark"] .afv-post--list:hover {background:var(--m5-hover);}
html[data-afv-theme="dark"] :is(.afv-actions .afv-action,.afv-post__meta,.m5-colophon) {color:var(--m5-muted);}
html[data-afv-theme="dark"] :is(.m5-search input,.m5-search .wp-block-search__inside-wrapper,.afv-profile__head,.m5-context-panels .afv-panel) {border-color:var(--m5-line);}
@media (prefers-color-scheme:dark) {
 html[data-afv-theme="auto"] .afv-post--list:hover {background:var(--m5-hover);}
 html[data-afv-theme="auto"] :is(.afv-actions .afv-action,.afv-post__meta,.m5-colophon) {color:var(--m5-muted);}
 html[data-afv-theme="auto"] :is(.m5-search input,.m5-search .wp-block-search__inside-wrapper,.afv-profile__head,.m5-context-panels .afv-panel) {border-color:var(--m5-line);}
}
/* Point colour-mode choices at the source of truth in FediPress preferences. */
.m5-native-theme-settings {margin:12px 0 18px;padding:13px 14px;border:1px solid var(--m5-line);border-radius:12px;background:var(--m5-feed);color:var(--m5-text);}
.m5-native-theme-settings strong {display:block;font-size:13px;}
.m5-native-theme-settings p {margin:7px 0 12px;color:var(--m5-muted);font-size:12px;line-height:1.5;}
.m5-native-theme-link {display:inline-flex;align-items:center;min-height:35px;padding:5px 13px;box-sizing:border-box;border:1px solid var(--m5-purple);border-radius:999px;color:var(--m5-purple);font-size:12px;font-weight:700;text-decoration:none;}
.m5-native-theme-link:hover,.m5-native-theme-link:focus-visible {background:var(--m5-hover);text-decoration:none;}
/* FediPress display.css is intentionally loaded by the plugin after themes.
 * Give the theme canvas precedence without changing FediPress's shared tokens. */
html:root[data-afv-theme="dark"] body {background:var(--m5-bg);color:var(--m5-text);}
@media (prefers-color-scheme:dark) {
 html:root[data-afv-theme="auto"] body {background:var(--m5-bg);color:var(--m5-text);}
}


/* 1.1.2 — Profile actions: consistent, accessible Edit profile / More controls.
   Keep FediPress's native links/details menus and follow/message actions intact.
   The old overflow:hidden on .afv-profile clipped the opened three-dot menu. */
.afv-main .afv-profile {
 overflow:visible;
 position:relative;
}
.afv-main .afv-profile:has(.afv-profile__buttons .afv-menu[open]) {
 z-index:15;
}
.afv-main .afv-profile__cover {
 overflow:hidden;
}
.afv-main .afv-profile__head {
 position:relative;
 z-index:2;
 min-width:0;
}
.afv-main .afv-profile__buttons {
 display:flex;
 flex:0 1 auto;
 align-items:center;
 justify-content:flex-end;
 align-self:flex-end;
 flex-wrap:wrap;
 gap:8px;
 min-width:0;
 margin-inline-start:auto;
 margin-block:0;
 padding:0 0 4px;
}
.afv-main .afv-profile__buttons > :is(a.wp-element-button,button.wp-element-button) {
 display:inline-flex;
 align-items:center;
 justify-content:center;
 flex:0 0 auto;
 box-sizing:border-box;
 min-height:40px;
 width:auto;
 max-width:100%;
 padding:8px 15px;
 margin:0;
 border-radius:999px;
 font-size:13px;
 font-weight:700;
 line-height:1.25;
 white-space:normal;
 text-align:center;
 text-decoration:none;
}
/* Outline the owner's edit link rather than applying the global purple fill. */
.afv-main .afv-profile__buttons > .afv-button-quiet.wp-element-button {
 background:var(--m5-feed) !important;
 color:var(--m5-text) !important;
 border:1px solid var(--m5-line) !important;
 box-shadow:none !important;
}
.afv-main .afv-profile__buttons > .afv-button-quiet.wp-element-button:hover {
 background:var(--m5-hover) !important;
 border-color:var(--m5-purple) !important;
}
.afv-main .afv-profile__buttons > .afv-menu {
 position:relative;
 display:inline-block;
 flex:0 0 40px;
 width:40px;
 height:40px;
 margin:0;
 padding:0;
}
.afv-main .afv-profile__buttons .afv-menu__toggle {
 display:flex !important;
 align-items:center;
 justify-content:center;
 box-sizing:border-box;
 flex:none;
 width:40px;
 min-width:40px;
 height:40px;
 min-height:40px;
 margin:0;
 padding:0;
 border:1px solid var(--m5-line);
 border-radius:50%;
 background:var(--m5-feed);
 color:var(--m5-text);
 cursor:pointer;
 list-style:none;
 line-height:1;
 -webkit-appearance:none;
 appearance:none;
}
.afv-main .afv-profile__buttons .afv-menu__toggle::-webkit-details-marker {display:none;}
.afv-main .afv-profile__buttons .afv-menu__toggle::marker {content:'';}
.afv-main .afv-profile__buttons .afv-menu__toggle svg {
 display:block;
 flex:none;
 width:19px;
 height:19px;
 fill:currentColor;
}
.afv-main .afv-profile__buttons .afv-menu__toggle:hover,
.afv-main .afv-profile__buttons .afv-menu[open] > .afv-menu__toggle {
 background:var(--m5-hover);
 border-color:var(--m5-purple);
 color:var(--m5-text);
}
.afv-main .afv-profile__buttons .afv-menu__panel {
 z-index:40;
 inset-inline-end:0;
 top:calc(100% + 8px);
 min-width:min(250px,calc(100vw - 32px));
 max-width:calc(100vw - 32px);
 background:var(--m5-feed);
 color:var(--m5-text);
 border:1px solid var(--m5-line);
 border-radius:12px;
 box-shadow:0 14px 38px rgb(25 14 52 / .20);
}
.afv-main .afv-profile__buttons .afv-menu__panel :is(.afv-menu__item,.afv-mod) {
 color:var(--m5-text);
}
.afv-main .afv-profile__buttons .afv-menu__panel :is(.afv-menu__item,.afv-mod):hover {
 background:var(--m5-hover);
}
@media (max-width:600px) {
 .afv-main .afv-profile__buttons {gap:6px;padding-block-end:2px;}
 .afv-main .afv-profile__buttons > :is(a.wp-element-button,button.wp-element-button) {
  min-height:38px;padding:7px 11px;font-size:12px;
 }
 .afv-main .afv-profile__buttons > .afv-menu {flex-basis:38px;width:38px;height:38px;}
 .afv-main .afv-profile__buttons .afv-menu__toggle {width:38px;min-width:38px;height:38px;min-height:38px;}
}


/* 1.1.3 — Full mobile/PWA menu, without replacing the bottom shortcuts. */
.m5-mobile-menu, .m5-mobile-menu-toggle {display:none;}
@media (max-width:720px) {
 .m5-mobile-menu-toggle {
  display:grid;place-items:center;
  position:fixed;top:calc(var(--m5-admin) + env(safe-area-inset-top,0px) + 8px);left:10px;
  box-sizing:border-box;width:38px;height:38px;border:0;border-radius:10px;
  background:transparent;color:var(--m5-text);font-size:23px;line-height:1;
  z-index:105;cursor:pointer;
 }
 .afv-topbar > .m5-mobile-menu-toggle {
  position:absolute;top:50%;left:10px;transform:translateY(-50%);
 }
 .m5-mobile-menu-toggle:hover {background:var(--m5-hover);}
 .m5-mobile-menu-toggle:focus-visible,.m5-mobile-menu__close:focus-visible {outline:2px solid var(--m5-purple);outline-offset:2px;}
 .afv-topbar:has(> .m5-mobile-menu-toggle) {padding-inline:51px!important;}
 .m5-mobile-menu[open] {
  display:block!important;position:fixed;inset:0 auto 0 0;
  box-sizing:border-box;width:min(355px,calc(100vw - 44px));max-width:none;
  height:100dvh;max-height:none;margin:0;padding:0;
  border:0;border-radius:0 16px 16px 0;
  background:var(--m5-feed);color:var(--m5-text);
  box-shadow:12px 0 45px rgba(27,21,48,.25);
  overflow:hidden;z-index:1000100;
 }
 .m5-mobile-menu::backdrop {background:rgba(19,14,31,.58);}
 .m5-mobile-menu__content {
  box-sizing:border-box;display:flex;flex-direction:column;height:100%;max-height:100%;
  padding-top:env(safe-area-inset-top,0px);
 }
 .m5-mobile-menu__header {
  box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;
  gap:12px;min-height:72px;padding:13px 17px;
  border-bottom:1px solid var(--m5-line);
 }
 .m5-mobile-menu__branding {display:flex;align-items:center;min-width:0;gap:10px;}
 .m5-mobile-menu__branding img {width:36px;height:36px;flex:none;border-radius:9px;object-fit:cover;}
 .m5-mobile-menu__branding > div {display:flex;flex-direction:column;min-width:0;gap:1px;}
 .m5-mobile-menu__branding strong {font-size:16px;line-height:1.2;}
 .m5-mobile-menu__branding small {font-size:11px;color:var(--m5-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
 .m5-mobile-menu__close {
  box-sizing:border-box;flex:0 0 38px;width:38px;height:38px;
  border:0;border-radius:10px;background:transparent;color:var(--m5-text);
  font-size:26px;line-height:1;cursor:pointer;
 }
 .m5-mobile-menu__close:hover {background:var(--m5-hover);}
 .m5-mobile-menu__nav {overflow-y:auto;overscroll-behavior:contain;min-height:0;flex:1;padding:6px 12px calc(28px + env(safe-area-inset-bottom,0px));scrollbar-width:thin;}
 .m5-mobile-menu__section {padding:10px 0 12px;border-bottom:1px solid var(--m5-line);}
 .m5-mobile-menu__section:last-child {border-bottom:0;}
 .m5-mobile-menu__section h2 {font-size:12px;color:var(--m5-muted);font-weight:750;margin:0 0 8px;padding:3px 12px;line-height:1.5;}
 .m5-mobile-menu .m5-link {
  display:flex!important;box-sizing:border-box;gap:14px;align-items:center;
  min-height:44px;width:100%;padding:10px 12px;margin:0;
  border:0;border-radius:10px;background:transparent;color:var(--m5-text);
  text-align:left;font-size:14px;line-height:1.25;font-weight:550;cursor:pointer;
 }
 .m5-mobile-menu .m5-link span {display:inline!important;visibility:visible!important;max-width:none;overflow:visible;white-space:normal;}
 .m5-mobile-menu .m5-link::before {width:20px;height:20px;flex:0 0 20px;}
 .m5-mobile-menu .m5-link:hover,.m5-mobile-menu .m5-link[aria-current="page"] {background:var(--m5-active);}
 .m5-mobile-menu .m5-link[aria-current="page"] {font-weight:750;}
}
@media (prefers-reduced-motion:reduce) {
 .m5-mobile-menu,.m5-mobile-menu-toggle {scroll-behavior:auto;}
}
