.ebr-modern {
    --ebr-rose: #a92d56;
    --ebr-ink: #35242e;
    --ebr-muted: #695963;
    --ebr-line: #e9dfe4;
    --ebr-paper: #faf7f6;
    color: var(--ebr-ink);
    background: var(--ebr-paper);
    font: 15px/1.55 system-ui, sans-serif;
}
.ebr-modern #wrap { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.ebr-modern #header[hidden] { display: none !important; }
.ebr-modern #page {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 280px);
    gap: 24px;
    align-items: start;
    margin-top: 24px;
}
.ebr-modern #page > :is(#content1, #content2, #rsidebar) {
    float: none;
    width: 100%;
    min-width: 0;
    max-width: none;
    margin: 0;
    box-sizing: border-box;
}
.ebr-modern #content2 > .post { width: auto; min-width: 0; }
.ebr-modern :is(#content2, #rsidebar, #content1ST) :is(.DesignBox, .DesignBoxBorder, .cwtbl, .ControlPanelTable) {
    max-width: 100%;
    color: var(--ebr-ink);
    background: #fff;
    border: 1px solid var(--ebr-line);
    border-radius: 14px;
}
.ebr-modern :is(.DesignBoxTitle, .erb-catalog-title, .ebr-site-info h2) {
    color: var(--ebr-ink);
    font-family: Georgia, serif;
    letter-spacing: -.02em;
}
.ebr-modern :is(#content2, #content1ST) > :is(.DataDiv, .post) { overflow-x: auto; }
.ebr-modern :is(.cc-nav, .profile_details, .erb-profile-card, #rsidebar .widget) { border-radius: 14px; }
.ebr-modern :is(.cc-nav a, .erb-catalog-quick-links a) { border-radius: 999px; }
.ebr-site-bar {
    position: relative;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 0;
    min-height: 54px;
    border-bottom: 1px solid var(--ebr-line);
}
.ebr-site-bar a, .ebr-bottom-nav a, .ebr-site-info a { color: var(--ebr-ink); text-decoration: none; }
.ebr-site-bar a:hover, .ebr-bottom-nav a:hover, .ebr-site-info a:hover { color: var(--ebr-rose); }
.ebr-site-brand { margin-right: auto; font: 700 clamp(16px, 2.5vw, 24px)/1.08 Georgia, serif; }
.ebr-site-brand span { color: var(--ebr-rose); }
.ebr-desktop-nav, .ebr-guest-actions { display: flex; align-items: center; gap: 12px; }
.ebr-site-bar .ebr-primary-link {
    padding: 7px 11px;
    color: #fff;
    background: var(--ebr-rose);
    border-radius: 999px;
}
.ebr-guest-actions { font-size: 13px; font-weight: 650; white-space: nowrap; }
.ebr-site-menu summary {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    list-style: none;
    cursor: pointer;
    font-size: 23px;
    border: 1px solid var(--ebr-line);
    border-radius: 12px;
}
.ebr-site-menu summary::-webkit-details-marker { display: none; }
.ebr-menu-links {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    display: grid;
    width: min(280px, 100%);
    padding: 8px;
    box-sizing: border-box;
    background: #fff;
    border: 1px solid var(--ebr-line);
    border-radius: 14px;
    box-shadow: 0 12px 30px #35242e1a;
}
.ebr-site-menu:not([open]) .ebr-menu-links { display: none; }
.ebr-menu-links a { padding: 10px 12px; border-radius: 8px; }
.ebr-menu-links a:hover { background: var(--ebr-paper); }
.ebr-modern :is(.ebr-site-bar, .ebr-bottom-nav) :focus-visible { outline: 2px solid var(--ebr-rose); outline-offset: 2px; }
.ebr-bottom-nav { display: none; }
.ebr-site-info { display: none; }
.ebr-site-info:target { display: block; padding: 18px; background: #fff; border: 1px solid var(--ebr-line); border-radius: 14px; }
.ebr-site-info a { display: inline-block; margin: 8px 14px 0 0; text-decoration: underline; }
.ebr-open-letter > td { padding: 12px; background: #fff5f8; }
.ebr-open-letter table { max-width: 100%; }
.ebr-letter-selected > td { background: #f8e9ef; }
.ebr-modern .erb-profile-card .erb-profile-card-heading,
.ebr-modern .erb-profile-card .erb-profile-card-identity,
.ebr-modern .erb-profile-card .erb-profile-card-identity b {
    background-color: transparent;
}
/* Let the legacy catalog actions wrap within the profile card. */
.erb-profile-card #prof.erb-profile-card-body {
    height: auto;
}

.erb-profile-card #aiim.erb-profile-card-actions {
    width: auto;
    min-width: 0;
    max-width: 100%;
    flex-wrap: wrap;
}

.erb-profile-card #aiim.erb-profile-card-actions form {
    max-width: 100%;
    min-width: 0;
    margin: 0 !important;
    padding: 0 !important;
}

.erb-profile-card #aiim.erb-profile-card-actions :is(img, input[type="image"]) {
    max-width: 100%;
    height: auto;
    margin: 0;
}

@media (max-width: 880px) {
    .ebr-modern { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
    .ebr-modern #page { grid-template-columns: minmax(0, 1fr); }
    .ebr-modern #page > #rsidebar { grid-column: 1; grid-row: auto; }
    .ebr-desktop-nav { display: none; }
    .ebr-site-bar { gap: 8px; }
    .ebr-guest-actions { gap: 7px; }
    .ebr-bottom-nav {
        position: fixed;
        z-index: 30;
        inset: auto 0 0;
        display: grid;
        grid-auto-columns: 1fr;
        grid-auto-flow: column;
        padding: 5px 4px calc(5px + env(safe-area-inset-bottom));
        background: #fff;
        border-top: 1px solid var(--ebr-line);
    }
    .ebr-bottom-nav a { position: relative; display: grid; justify-items: center; align-content: center; min-height: 49px; font: 600 11px/1.2 system-ui, sans-serif; }
    .ebr-bottom-nav a[aria-current] { color: var(--ebr-rose); }
    .ebr-nav-icon { font: 25px/1.1 system-ui, sans-serif; }
    .ebr-nav-badge { position: absolute; top: 1px; left: calc(50% + 7px); padding: 2px 4px; border-radius: 999px; color: #fff; background: var(--ebr-rose); font-size: 10px; }
    .ebr-nav-dot { width: 8px; height: 8px; padding: 0; }
}
@media (max-width: 390px) {
    .ebr-modern #wrap { width: calc(100% - 20px); }
}
