﻿* {
    margin: 0;
    padding: 0;
}

a[name] {
    scroll-margin-top: 150px;
}

.auto-style9 {
    margin-left: 20px;
    margin-right: 20px;
}

.auto-style14 {
    font-size: x-large;
}

.auto-style15 {
    text-decoration: underline;
    font-weight: bold;
}

.auto-style10,
.auto-style11 {
    line-height: normal;
    font-style: normal;
    font-variant: normal;
}

.auto-style8 {
    color: #080028;
    font-weight: bold;
    line-height: normal;
    font-style: normal;
    font-variant: normal;
    font-size: 16px;
    font-family: "Trebuchet MS", arial, sans-serif;
    text-decoration: underline;
}

.auto-style12 {
    color: #080028;
    font-weight: bold;
    line-height: normal;
    font-style: normal;
    font-variant: normal;
    font-size: 18px;
    font-family: "Trebuchet MS", arial, sans-serif;
}

.faustina-page .auto-style2 {
    margin-left: 20px;
    margin-right: 20px;
}

.faustina-page a[name] {
    padding-top: 150px;
}

.quotes-print-wrap {
    position: relative;
    z-index: 100;
    cursor: pointer;
    margin-bottom: 10px;
}

.pope-page-search-wrap {
    margin: 0 0 8px;
    padding: 8px 9px 9px;
    border: 1px solid #2b6dcc;
    border-radius: 6px;
    background: linear-gradient(180deg, #f8fbff 0%, #eef4ff 100%);
    box-sizing: border-box;
}

.pre-leo-page .ctrl-actions-box .pope-page-search-wrap {
    margin-top: 12px;
}

.pope-page-search-label {
    display: block;
    margin-bottom: 4px;
    color: #16396f;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
}

.pope-page-search-row {
    display: block;
}

.pope-page-search-input {
    display: block;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    border: 1px solid #2b6dcc;
    border-radius: 4px;
    padding: 6px 8px;
    font-size: 15px;
    line-height: 1.2;
    font-family: "Trebuchet MS", Arial, sans-serif;
    color: #10233f;
    background: #ffffff;
}

.pope-page-search-clear {
    display: none;
}

.pope-page-search-go {
    display: none;
}

.pope-page-search-status {
    display: block;
    height: 1.25em;
    min-height: 1.25em;
    margin-top: 3px;
    color: #355b89;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 11px;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pope-page-search-status:empty {
    visibility: hidden;
}

.pope-page-search-help {
    margin-top: 2px;
    color: #516d92;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 10px;
    line-height: 1.25;
}

mark.pope-search-hit {
    padding: 0 2px;
    border-radius: 2px;
    background: #ffe58a;
    color: inherit;
    box-shadow: inset 0 -1px 0 rgba(43, 109, 204, 0.28);
}

.pope-search-sub-hidden {
    display: none;
}

.ctrl-actions-box.pope-filters-inline {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    column-gap: 6px;
    row-gap: 6px;
    align-items: start;
    min-height: 0 !important;
    padding-bottom: 6px;
}

.ctrl-actions-box.pope-filters-inline .alpha-filter-wrap .alpha-filter-label {
    display: block;
    margin: 0 0 2px;
    font-size: 13px;
    white-space: nowrap;
}

.ctrl-actions-box.pope-filters-inline .alpha-filter-wrap .pope-filter-dropdown-wrap {
    display: block;
    margin: 0 auto;
}

.ctrl-actions-box.pope-filters-inline .alpha-filter-wrap .pope-filter-toggle {
    min-width: 0;
    width: 100%;
    max-width: 140px;
    padding: 4px 8px;
    font-size: 12px;
}

.ctrl-actions-box.pope-filters-inline .alpha-filter-wrap.pope-year-filter-wrap {
    grid-column: 1;
    margin: 0;
}

.ctrl-actions-box.pope-filters-inline .alpha-filter-wrap.pope-source-filter-wrap {
    grid-column: 3;
    margin: 0;
}

.ctrl-actions-box.pope-filters-inline .pope-filter-and-or {
    grid-column: 1 / -1;
    align-self: center;
    justify-self: center;
    margin-top: 2px;
    margin-bottom: 0;
    color: #2c4f80;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

.ctrl-actions-box.pope-filters-inline .alpha-filter-actions-wrap.pope-shared-filter-actions {
    grid-column: 1 / -1;
    margin: 0;
    text-align: center;
}

.ctrl-actions-box.pope-filters-inline .pope-page-search-wrap,
.ctrl-actions-box.pope-filters-inline .ctrl-actions-divider,
.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom {
    grid-column: 1 / -1;
}

.ctrl-actions-box.pope-filters-inline .pope-page-search-wrap {
    margin: 0 0 5px;
    padding: 6px 8px 7px;
}

.ctrl-actions-box.pope-filters-inline .pope-page-search-help {
    display: none;
}

.ctrl-actions-box.pope-filters-inline .ctrl-actions-divider {
    margin: 1px auto 0;
}

.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom {
    margin-top: 2px;
}

.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .ea-all-btn-wrap,
.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-wrap {
    margin: 1px 0 0;
}

.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-wrap {
    margin-top: 3px;
    margin-bottom: 2px;
}

#left-content .ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .ea-all-btn-wrap,
#left-content .ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-wrap {
    margin: 1px 0 0;
}

#left-content .ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-wrap {
    margin-top: 3px;
    margin-bottom: 2px;
}

.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .ea-all-toggle,
.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-btn,
#left-content .ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .ea-all-toggle,
#left-content .ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-btn {
    margin: 0;
}

.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-btn {
    margin-top: 6px;
}

#left-content .ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .quotes-print-btn {
    margin-top: 6px;
}

.ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom .view-status {
    margin-top: 2px;
}

#print-quotes-only {
    cursor: pointer;
    position: relative;
    z-index: 100;
}

#left-content #print-quotes-only.quotes-print-btn:focus-visible {
    outline: 2px solid #5d7fb4;
    outline-offset: 2px;
    box-shadow: 0 0 0 4px rgba(93, 127, 180, 0.18);
}

#left-content #print-quotes-only.quotes-print-btn:focus:not(:focus-visible) {
    outline: none;
    box-shadow: none;
}

.pre-leo-page #year-filter-toggle:focus-visible,
.pre-leo-page #year-filter-accept:focus-visible,
.pre-leo-page #year-filter-reset:focus-visible,
.pre-leo-page #expand-all-years:focus-visible,
.pre-leo-page #print-quotes-only:focus-visible,
.pre-leo-page .summary-nav-btn:focus-visible,
.pre-leo-page .summary-nav-mode-option input[type="radio"]:focus-visible,
.pre-leo-page .pre-leo-quick-help-link:focus-visible {
    outline: 2px solid #f3a300;
    outline-offset: 2px;
    box-shadow: 0 0 0 3px rgba(243, 163, 0, 0.24);
}

#left-content .content-pad .td-center {
    margin: 6px 0;
}

#left-content .content-pad .year-row {
    margin: 10px 0 8px;
}

#left-content .content-pad .td-center .auto-style14 {
    display: inline-block;
    margin: 2px 0;
    line-height: 1.1;
}

#left-content .content-pad .td-center .ea-toggle {
    margin-left: 10px;
    margin-top: 0;
    vertical-align: baseline;
}

#left-content .content-pad .year-row .ea-toggle {
    margin-left: 12px;
}

.pre-leo-page #left-content .content-pad .year-row .auto-style14 {
    font-size: 21px;
}

.page-custom-sidebar #left-content .content-pad ul {
    margin: 0 0 0 16px;
    padding-left: 12px;
}

.page-custom-sidebar #left-content .content-pad ul li {
    margin: 0;
}

.pope-jp2-page #left-content .content-pad,
.pope-benedict-page #left-content .content-pad,
.pope-francis-page #left-content .content-pad,
.pope-leo-page #left-content .content-pad {
    --jp2-sidebar-width: 300px;
    --jp2-center-offset: calc(var(--jp2-sidebar-width) / 2);
}

.pre-leo-page .pre-leo-quick-help {
    margin: 8px 0 10px;
    padding: 0;
    border: none;
    background: transparent;
    display: inline-block;
    color: #16396f;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.35;
}

.pre-leo-page .pre-leo-quick-help-link {
    font-weight: 700;
    text-decoration: underline;
    color: #16499e;
}

.ctrl-panel-row.pope-controls-single .ctrl-actions-panel {
    width: 320px;
}

.pope-jp2-page .jp2-top-row .ctrl-panel-row,
.pope-benedict-page .jp2-top-row .ctrl-panel-row,
.pope-francis-page .jp2-top-row .ctrl-panel-row,
.pope-leo-page .jp2-top-row .ctrl-panel-row {
    width: 320px;
    margin: 0 auto;
    transform: translateX(var(--jp2-center-offset));
}

.pope-jp2-page .jp2-top-row,
.pope-benedict-page .jp2-top-row,
.pope-francis-page .jp2-top-row,
.pope-leo-page .jp2-top-row {
    position: relative;
    min-height: 0;
    margin: 8px 0 26px;
}

.pope-jp2-page .ctrl-back-row,
.pope-benedict-page .ctrl-back-row,
.pope-francis-page .ctrl-back-row,
.pope-leo-page .ctrl-back-row {
    width: 320px;
    margin: 8px auto 8px;
    transform: translateX(var(--jp2-center-offset));
    text-align: center;
    display: flex;
    justify-content: center;
}

.pope-jp2-page .jp2-photo-shell,
.pope-benedict-page .jp2-photo-shell,
.pope-francis-page .jp2-photo-shell,
.pope-leo-page .jp2-photo-shell {
    position: absolute;
    left: 0;
    top: 5px;
    bottom: 0;
    width: auto;
    height: auto;
    min-width: 250px;
    aspect-ratio: 1 / 1;
    border: 1px solid #2b6dcc;
    border-radius: 6px;
    background: #f0f4ff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.10);
    padding: 8px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pope-jp2-page .jp2-photo,
.pope-benedict-page .jp2-photo,
.pope-francis-page .jp2-photo,
.pope-leo-page .jp2-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 1px solid #1a1a1a;
    box-sizing: border-box;
}

.pope-jp2-page .ctrl-back-row .back-nav-btn,
.pope-benedict-page .ctrl-back-row .back-nav-btn,
.pope-francis-page .ctrl-back-row .back-nav-btn,
.pope-leo-page .ctrl-back-row .back-nav-btn {
    margin-left: auto;
    margin-right: auto;
}

.ctrl-panel-row.pope-controls-plain {
    display: flex;
    align-items: center;
    justify-content: center;
}

.pope-controls-stack {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
}

.pope-controls-stack .back-nav-btn {
    display: inline-flex;
    width: auto !important;
    max-width: 280px;
    min-width: 0;
}

.jp2-top-row.pope-top-row-fixed-photo {
    min-height: 250px;
}

.jp2-photo-shell.pope-photo-fixed-square {
    bottom: auto;
    width: 250px;
    height: 250px;
    min-width: 250px;
    aspect-ratio: 1 / 1;
    overflow: hidden;
}

.jp2-photo-shell.pope-photo-frame .pope-photo-placeholder {
    width: 100%;
    height: 100%;
    border: 1px dashed #5d7fb4;
    background: linear-gradient(135deg, #f6f9ff 0%, #eaf1ff 100%);
    color: #25406b;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.35;
    text-align: center;
    padding: 14px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
}

.jp2-photo-shell.pope-photo-frame .pope-photo-display[hidden],
.jp2-photo-shell.pope-photo-frame .pope-photo-placeholder[hidden] {
    display: none !important;
}

.jp2-photo-shell.pope-photo-frame .pope-photo-name-strip {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 8px;
    background: rgba(255, 255, 255, 0.95);
    color: #111;
    border: 1px solid #111;
    border-radius: 4px;
    padding: 5px 10px;
    box-sizing: border-box;
    text-align: center;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    width: auto;
    max-width: calc(100% - 16px);
    white-space: nowrap;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
    z-index: 3;
}

.jp2-photo-shell.pope-photo-frame .pope-photo-name-strip[hidden] {
    display: none !important;
}

.jp2-photo-shell.pope-photo-frame .pope-photo-fallback-note {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 34px;
    background: rgba(22, 57, 111, 0.92);
    color: #fff;
    border-radius: 999px;
    padding: 3px 8px;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.01em;
    z-index: 4;
}

.jp2-photo-shell.pope-photo-frame .pope-photo-fallback-note[hidden] {
    display: none !important;
}

.pre-leo-page .pre-leo-century-marker {
    text-align: center;
    margin: 16px 0 6px;
}

.pre-leo-page .pre-leo-century-marker::before {
    content: "";
    display: block;
    height: 2.2em;
}

.pre-leo-page .pre-leo-century-title {
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.15;
    color: #143d77;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.pre-leo-page .pre-leo-century-back {
    display: inline-block;
    margin-top: 5px;
    color: #1f4fb6;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 13px;
    font-weight: 700;
    text-decoration: underline;
}

.pre-leo-page .pre-leo-century-back:hover {
    color: #0d387f;
}

@media (min-width: 981px) {
    .pre-leo-page #year-filter-menu {
        column-count: 4;
        column-gap: 16px;
        max-width: 520px;
    }
}

.pre-leo-page .pre-leo-summary-nav {
    display: flex;
    align-items: stretch;
    justify-content: center;
    gap: 14px;
    margin: 10px 0 8px;
    position: relative;
    z-index: 10;
}

.pre-leo-page .jp2-top-row.pope-top-row-fixed-photo {
    position: relative;
    z-index: 40;
}

.pre-leo-page #year-filter-dropdown {
    position: relative;
    z-index: 3000;
}

.pre-leo-page #year-filter-menu {
    position: absolute;
    top: calc(100% + 8px);
    bottom: auto;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3200;
}

.pre-leo-page #year-filter-dropdown.pope-filter-menu-open #year-filter-menu {
    position: absolute;
    z-index: 3200;
    margin-top: 0;
}

.pre-leo-page.pre-leo-filter-open .ctrl-actions-box {
    box-shadow: 0 0 0 2px rgba(43, 109, 204, 0.22);
    border-radius: 8px;
}

.pre-leo-page.pre-leo-filter-open #year-filter-toggle {
    background: #eef5ff;
    border-color: #2b6dcc;
}

.pre-leo-page .summary-nav-main {
    display: grid;
    grid-template-columns: 240px 240px;
    grid-auto-rows: minmax(44px, auto);
    gap: 10px 12px;
    align-items: stretch;
}

.pre-leo-page .summary-nav-prev {
    grid-column: 1;
    grid-row: 1;
}

.pre-leo-page .summary-nav-next {
    grid-column: 2;
    grid-row: 1;
}

.pre-leo-page .summary-nav-current {
    grid-column: 1;
    grid-row: 2;
}

.pre-leo-page .summary-nav-mode-box {
    grid-column: 2;
    grid-row: 2;
}

.pre-leo-page .summary-nav-side-actions {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    width: 240px;
    padding-left: 14px;
    border-left: 2px solid #c1d1ea;
}

.pre-leo-page .summary-nav-btn {
    min-width: 0;
    width: 100%;
    min-height: 44px;
    padding: 8px 11px;
    border: 1px solid #1e4f96;
    border-radius: 6px;
    background: linear-gradient(180deg, #f7fbff 0%, #e8f1ff 100%);
    color: #114080;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.pre-leo-page .summary-nav-btn:hover {
    background: linear-gradient(180deg, #ffffff 0%, #e4efff 100%);
}

.pre-leo-page .summary-nav-btn:disabled {
    opacity: 0.75;
    color: #5e7090;
    border-color: #9fb2d3;
    background: linear-gradient(180deg, #f2f6fc 0%, #e8eef8 100%);
    cursor: not-allowed;
}

.pre-leo-page .summary-nav-print {
    min-width: 172px;
}

.pre-leo-page .summary-nav-current {
    width: 240px;
    min-width: 240px;
    max-width: 240px;
    padding: 7px 10px;
    border: 1px solid #9eb5d8;
    border-radius: 6px;
    background: #fff;
    color: #173d74;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    line-height: 1.25;
    white-space: pre-line;
    overflow: visible;
}

.pre-leo-page .summary-nav-current.is-feedback {
    background: #edf5ff;
    border-color: #5a84c3;
    color: #0f3c79;
}

.pre-leo-page .summary-nav-mode-box {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 175px;
    padding: 6px 8px;
    border: 1px solid #9eb5d8;
    border-radius: 6px;
    background: #fff;
}

.pre-leo-page .summary-nav-mode-option {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #173d74;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
}

.pre-leo-page .summary-nav-mode-option input[type="radio"] {
    margin: 0;
}

.pre-leo-page .pope-live-preview {
    width: 100%;
    min-height: 260px;
    margin: 10px 0 18px;
    padding: 14px 16px;
    box-sizing: border-box;
    border: 1px solid #5d7fb4;
    border-radius: 8px;
    background: linear-gradient(180deg, #f9fbff 0%, #f2f6ff 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.pre-leo-page .pope-live-preview-empty {
    font-family: "Trebuchet MS", Arial, sans-serif;
    color: #22406a;
    font-size: 18px;
    line-height: 1.45;
    text-align: center;
    padding: 26px 12px;
}

.pre-leo-page .pope-live-preview .pope-live-preview-title {
    margin: 0 0 10px;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 25px;
    line-height: 1.2;
    text-align: center;
    color: #0f2e5a;
}

.pre-leo-page .pope-live-preview .pope-live-preview-content {
    color: #000;
}

.pre-leo-page .pope-live-preview.is-updating {
    animation: pre-leo-preview-fade-in 0.16s ease-out;
}

@keyframes pre-leo-preview-fade-in {
    from {
        opacity: 0.72;
    }
    to {
        opacity: 1;
    }
}

.pre-leo-page .pope-live-preview .pope-live-preview-content .page-splits,
.pre-leo-page .pope-live-preview .pope-live-preview-content .ea-toggle {
    display: none !important;
}
    .source-type-legend {
        margin: 2px 0 0;
        text-align: left;
        font-size: 16px;
        line-height: 1.45;
        color: #111;
    }

    .source-type-legend-label {
        font-weight: 400;
        color: inherit;
    }

    .source-type-chip,
    .source-type-reset-inline {
        display: inline;
        margin: 0;
        padding: 0;
        border: none;
        background: transparent;
        color: #2a37ff;
        font: inherit;
        line-height: inherit;
        text-decoration: none;
        white-space: nowrap;
        cursor: pointer;
    }

    .source-type-chip:hover,
    .source-type-reset-inline:hover {
        text-decoration: underline;
    }

    .source-type-chip:focus-visible,
    .source-type-reset-inline:focus-visible {
        outline: 2px solid #f3a300;
        outline-offset: 2px;
    }

    .source-type-summary {
        margin-top: 12px;
    }

    .pope-floating-reset {
        position: fixed;
        left: 12px;
        top: 50%;
        transform: translateY(-50%);
        z-index: 1200;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 8px 12px;
        border: 1px solid #b68318;
        border-radius: 999px;
        background: rgba(255, 241, 184, 0.97);
        color: #5c3d00;
        font-family: "Trebuchet MS", Arial, sans-serif;
        font-size: 13px;
        font-weight: 700;
        line-height: 1.2;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
        cursor: pointer;
    }

    .pope-floating-reset[hidden] {
        display: none !important;
    }

    .pope-floating-reset:hover {
        background: #fff3bd;
    }

    .pope-floating-reset:focus-visible {
        outline: 2px solid #f3a300;
        outline-offset: 2px;
    }

    .selection-scroll-cue {
        display: inline-block;
        margin: 0 10px 0 0;
        padding: 3px 9px;
        border: 1px solid rgba(191, 146, 55, 0.65);
        border-radius: 7px;
        background: rgba(255, 243, 205, 0.85);
        color: #7a4f00;
        font-family: "Trebuchet MS", Arial, sans-serif;
        font-size: 12px;
        line-height: 1.3;
        vertical-align: middle;
    }

    .current-filter-state {
        margin: 8px 0 12px;
        padding: 4px 10px;
        display: inline-block;
        border: 1px solid rgba(180, 130, 26, 0.45);
        border-radius: 6px;
        background: rgba(255, 241, 184, 0.92);
        color: #5c3d00;
        font-family: "Trebuchet MS", Arial, sans-serif;
        font-size: 12px;
        line-height: 1.35;
    }

@media (max-width: 980px) {
    .pre-leo-page .pre-leo-summary-nav {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .pre-leo-page .summary-nav-main {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .pre-leo-page .summary-nav-prev,
    .pre-leo-page .summary-nav-next,
    .pre-leo-page .summary-nav-current,
    .pre-leo-page .summary-nav-mode-box {
        grid-column: 1;
        grid-row: auto;
    }

    .pre-leo-page .summary-nav-side-actions {
        width: 100%;
        border-left: none;
        border-top: 2px solid #c1d1ea;
        padding-left: 0;
        padding-top: 8px;
    }

    .pre-leo-page .summary-nav-btn {
        min-width: 0;
        width: 100%;
        font-size: 16px;
    }

    .pre-leo-page .summary-nav-current {
        min-width: 0;
        width: 100%;
        max-width: none;
        font-size: 15px;
    }

    .pre-leo-page .summary-nav-mode-box {
        min-width: 0;
        width: 100%;
        box-sizing: border-box;
    }

    .pre-leo-page .summary-nav-mode-option {
        font-size: 13px;
    }

    .jp2-photo-shell.pope-photo-frame .pope-photo-name-strip {
        font-size: 13px;
        font-weight: 700;
        padding: 4px 9px;
        max-width: calc(100% - 12px);
    }

    .pre-leo-page .pope-live-preview {
        min-height: 210px;
        padding: 12px;
    }

    .pre-leo-page .pope-live-preview .pope-live-preview-title {
        font-size: 22px;
    }

    .pre-leo-page .pope-live-preview-empty {
        font-size: 17px;
        padding: 18px 8px;
    }
}

@media (max-width: 980px) {
    .source-type-legend {
        font-size: 15px;
    }

    .pope-floating-reset {
        left: auto;
        right: 12px;
        top: auto;
        bottom: 14px;
        transform: none;
    }

    .pope-jp2-page .jp2-top-row,
    .pope-benedict-page .jp2-top-row,
    .pope-francis-page .jp2-top-row,
    .pope-leo-page .jp2-top-row {
        position: static;
        min-height: 0;
        display: block;
    }

    .pope-jp2-page .ctrl-back-row,
    .pope-benedict-page .ctrl-back-row,
    .pope-francis-page .ctrl-back-row,
    .pope-leo-page .ctrl-back-row {
        width: auto;
        transform: none;
    }

    .pope-jp2-page .jp2-top-row .ctrl-panel-row,
    .pope-benedict-page .jp2-top-row .ctrl-panel-row,
    .pope-francis-page .jp2-top-row .ctrl-panel-row,
    .pope-leo-page .jp2-top-row .ctrl-panel-row {
        transform: none;
    }

    .pope-jp2-page .jp2-photo-shell,
    .pope-benedict-page .jp2-photo-shell,
    .pope-francis-page .jp2-photo-shell,
    .pope-leo-page .jp2-photo-shell,
    .jp2-photo-shell.pope-photo-fixed-square {
        position: static;
        width: 220px;
        height: 220px;
        min-width: 220px;
        max-height: none;
        margin: 0 auto 12px;
    }

    .pope-jp2-page .jp2-photo,
    .pope-benedict-page .jp2-photo,
    .pope-francis-page .jp2-photo,
    .pope-leo-page .jp2-photo,
    .jp2-photo-shell.pope-photo-fixed-square .jp2-photo {
        height: auto;
        aspect-ratio: 1 / 1;
    }
}

.pope-francis-page .jp2-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 1px solid #1a1a1a;
    box-sizing: border-box;
}

.pope-francis-page .ctrl-back-row .back-nav-btn {
    margin-left: auto;
    margin-right: auto;
}

.pope-leo-page .jp2-top-row {
    position: relative;
    min-height: 0;
    margin: 8px 0 26px;
}

.pope-leo-page .ctrl-back-row {
    width: 320px;
    margin: 8px auto 8px;
    transform: translateX(var(--jp2-center-offset));
    text-align: center;
    display: flex;
    justify-content: center;
}

.pope-leo-page .jp2-top-row .ctrl-panel-row {
    width: 320px;
    margin: 0 auto;
    transform: translateX(var(--jp2-center-offset));
}

.pope-leo-page .jp2-photo-shell {
    position: absolute;
    left: 0;
    top: 5px;
    bottom: 0;
    width: auto;
    height: auto;
    min-width: 250px;
    aspect-ratio: 1 / 1;
    border: 1px solid #2b6dcc;
    border-radius: 6px;
    background: #f0f4ff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.10);
    padding: 8px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pope-leo-page .jp2-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 1px solid #1a1a1a;
    box-sizing: border-box;
}

.pope-leo-page .ctrl-back-row .back-nav-btn {
    margin-left: auto;
    margin-right: auto;
}

.pope-leo-page .ctrl-actions-box .ea-toggle {
    margin-left: 12px;
    margin-top: 0;
    vertical-align: baseline;
}

.pope-leo-page .ctrl-actions-box {
    min-height: 0 !important;
    height: auto !important;
}

.pope-leo-page .jp2-top-row.printhide {
    display: grid;
    width: 100%;
    grid-template-columns: minmax(0, 1fr) 320px;
    grid-template-areas: "left controls";
    column-gap: 20px;
    row-gap: 8px;
    align-items: start;
    justify-content: stretch;
}

.pope-leo-page .pope-leo-left-col {
    grid-area: left;
    margin-top: 34px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pope-jp2-page #current-filter-state,
.pope-benedict-page #current-filter-state,
.pope-leo-page #current-filter-state {
    display: table;
    margin: 8px auto 12px;
    text-align: center;
}

.pope-jp2-page .source-type-legend,
.pope-benedict-page .source-type-legend,
.pope-leo-page .source-type-legend {
    font-size: 13px;
    line-height: 24px;
}

.pope-francis-page #current-filter-state {
    display: table;
    margin: 8px auto 12px;
    text-align: center;
}

.pope-francis-page .source-type-legend {
    font-size: 13px;
    line-height: 24px;
}

.pope-jp2-page .pope-jp2-title-row {
    position: relative;
    min-height: 44px;
    margin-bottom: 2px;
}

.pope-benedict-page .pope-benedict-title-row {
    position: relative;
    min-height: 44px;
    margin-bottom: 2px;
}

.pope-leo-page .pope-leo-title-row {
    position: relative;
    min-height: 44px;
    margin-bottom: 2px;
}

.pope-francis-page .pope-francis-title-row {
    position: relative;
    min-height: 44px;
    margin-bottom: 2px;
}

.pope-jp2-page .pope-jp2-title-row .title.td-left {
    margin-right: 340px;
}

.pope-benedict-page .pope-benedict-title-row .title.td-left {
    margin-right: 340px;
}

.pope-leo-page .pope-leo-title-row .title.td-left {
    margin-right: 340px;
}

.pope-francis-page .pope-francis-title-row .title.td-left {
    margin-right: 340px;
}

.pope-jp2-page .ctrl-back-row.jp2-title-back-row {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    margin: 0 auto;
}

.pope-benedict-page .ctrl-back-row.benedict-title-back-row {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    margin: 0 auto;
}

.pope-leo-page .ctrl-back-row.leo-title-back-row {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    margin: 0 auto;
}

.pope-francis-page .ctrl-back-row.francis-title-back-row {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    margin: 0 auto;
}

.pope-leo-page .jp2-top-row.printhide .jp2-photo-shell {
    position: relative;
    left: auto;
    top: auto;
    bottom: auto;
    width: clamp(180px, 22vw, 240px);
    height: clamp(180px, 22vw, 240px);
    min-width: 180px;
    margin: 0 auto;
    padding: 5px;
}

.pope-leo-page .jp2-top-row.printhide .ctrl-panel-row {
    grid-area: controls;
    margin: 0;
    transform: none;
}

.pope-leo-page .pope-leo-intro {
    width: 100%;
    margin: 12px 0 0;
    position: static;
    padding-right: 8px;
    color: #111;
    font-family: "Trebuchet MS", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.35;
    text-align: left;
}

.ctrl-panel-row.pope-controls-plain {
    display: flex;
    align-items: center;
    justify-content: center;
}

.pope-controls-stack {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
}

.pope-controls-stack .back-nav-btn {
    display: inline-flex;
    width: auto !important;
    max-width: 280px;
    min-width: 0;
}

.jp2-top-row.pope-top-row-fixed-photo {
    min-height: 250px;
}

.jp2-photo-shell.pope-photo-fixed-square {
    bottom: auto;
    width: 250px;
    height: 250px;
    min-width: 250px;
    aspect-ratio: 1 / 1;
    overflow: hidden;
}

@media (max-width: 980px) {
    .pope-benedict-page .jp2-top-row {
        position: static;
        min-height: 0;
        display: block;
    }

    .pope-benedict-page .ctrl-back-row {
        width: auto;
        transform: none;
    }

    .pope-benedict-page .jp2-top-row .ctrl-panel-row {
        transform: none;
    }

    .pope-benedict-page .jp2-photo-shell {
        position: static;
        width: 220px;
        height: 220px;
        min-width: 220px;
        max-height: none;
        margin: 0 auto 12px;
    }

    .pope-benedict-page .jp2-photo {
        height: auto;
        aspect-ratio: 1 / 1;
    }

    .pope-francis-page .jp2-top-row {
        position: static;
        min-height: 0;
        display: block;
    }

    .pope-francis-page .ctrl-back-row {
        width: auto;
        transform: none;
    }

    .pope-francis-page .jp2-top-row .ctrl-panel-row {
        transform: none;
    }

    .pope-francis-page .jp2-photo-shell {
        position: static;
        width: 220px;
        height: 220px;
        max-height: none;
        margin: 0 auto 12px;
    }

    .pope-francis-page .jp2-photo {
        height: auto;
        aspect-ratio: 1 / 1;
    }

    .pope-leo-page .jp2-top-row {
        position: static;
        min-height: 0;
        display: block;
    }

    .pope-leo-page .ctrl-back-row {
        width: auto;
        transform: none;
    }

    .pope-leo-page .jp2-top-row .ctrl-panel-row {
        transform: none;
    }

    .pope-leo-page .jp2-photo-shell {
        position: static;
        width: 220px;
        height: 220px;
        max-height: none;
        margin: 0 auto 12px;
    }

    .pope-leo-page .jp2-photo {
        height: auto;
        aspect-ratio: 1 / 1;
    }

    .jp2-top-row.pope-top-row-fixed-photo {
        position: static;
        min-height: 0;
        display: block;
    }

    .jp2-photo-shell.pope-photo-fixed-square {
        position: static;
        width: 220px;
        height: 220px;
        min-width: 220px;
        max-height: none;
        margin: 0 auto 12px;
    }

    .jp2-photo-shell.pope-photo-fixed-square .jp2-photo {
        height: auto;
        aspect-ratio: 1 / 1;
    }

}

@media (max-width: 640px) {
    .pope-jp2-page .ctrl-panel-row.pope-controls-single,
    .pope-benedict-page .ctrl-panel-row.pope-controls-single,
    .pope-francis-page .ctrl-panel-row.pope-controls-single,
    .pope-leo-page .ctrl-panel-row.pope-controls-single,
    .pope-jp2-page .jp2-top-row .ctrl-panel-row,
    .pope-benedict-page .jp2-top-row .ctrl-panel-row,
    .pope-francis-page .jp2-top-row .ctrl-panel-row,
    .pope-leo-page .jp2-top-row .ctrl-panel-row {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: auto;
        margin-right: auto;
        box-sizing: border-box;
        min-width: 0;
    }

    .pope-jp2-page .ctrl-panel-row.pope-controls-single .ctrl-actions-panel,
    .pope-benedict-page .ctrl-panel-row.pope-controls-single .ctrl-actions-panel,
    .pope-francis-page .ctrl-panel-row.pope-controls-single .ctrl-actions-panel,
    .pope-leo-page .ctrl-panel-row.pope-controls-single .ctrl-actions-panel {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box;
        min-width: 0;
    }

    .pope-jp2-page .ctrl-actions-panel .ctrl-actions-shell,
    .pope-benedict-page .ctrl-actions-panel .ctrl-actions-shell,
    .pope-francis-page .ctrl-actions-panel .ctrl-actions-shell,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-shell,
    .pope-jp2-page .ctrl-actions-panel .ctrl-actions-box,
    .pope-benedict-page .ctrl-actions-panel .ctrl-actions-box,
    .pope-francis-page .ctrl-actions-panel .ctrl-actions-box,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-box {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .pope-francis-page .ctrl-actions-box,
    .pope-leo-page .ctrl-actions-box {
        min-height: 0;
        height: auto;
    }

    .pope-francis-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom {
        margin-top: 2px;
        width: 100%;
    }

    .pope-francis-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .ea-all-btn-wrap,
    .pope-francis-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-wrap,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .ea-all-btn-wrap,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-wrap {
        margin: 1px 0 0;
    }

    .pope-francis-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-wrap,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-wrap {
        margin-top: 3px;
        margin-bottom: 2px;
    }

    .pope-francis-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-btn,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-btn {
        margin-top: 6px;
    }

    .pope-francis-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-wrap,
    .pope-leo-page .ctrl-actions-panel .ctrl-actions-box .ctrl-actions-bottom .quotes-print-wrap {
        margin-bottom: 0;
    }

    .pope-page-search-row {
        display: block;
    }

    .pope-page-search-input {
        width: 100%;
        padding: 6px 8px;
        font-size: 12px;
    }

    .pope-page-search-go,
    .pope-page-search-clear {
        display: none;
    }

    .ctrl-actions-box.pope-filters-inline {
        grid-template-columns: 1fr;
        row-gap: 8px;
    }

    .ctrl-actions-box.pope-filters-inline .alpha-filter-wrap.pope-year-filter-wrap,
    .ctrl-actions-box.pope-filters-inline .alpha-filter-wrap.pope-source-filter-wrap,
    .ctrl-actions-box.pope-filters-inline .alpha-filter-actions-wrap.pope-shared-filter-actions,
    .ctrl-actions-box.pope-filters-inline .pope-page-search-wrap,
    .ctrl-actions-box.pope-filters-inline .ctrl-actions-divider,
    .ctrl-actions-box.pope-filters-inline .ctrl-actions-bottom,
    .ctrl-actions-box.pope-filters-inline .pope-filter-and-or {
        grid-column: 1;
    }

    .ctrl-actions-box.pope-filters-inline .pope-filter-and-or {
        margin-top: 0;
    }
}

@media (max-width: 980px) {
    .pope-leo-page .jp2-top-row.printhide {
        display: block;
        margin: 8px auto 20px;
    }

    .pope-leo-page .pope-leo-left-col {
        margin-top: 0;
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell {
        width: 220px;
        height: 220px;
        min-width: 220px;
        margin: 0 auto 10px;
    }

    .pope-leo-page .pope-leo-intro {
        width: auto;
        max-width: 320px;
        left: 0;
        margin: 0 auto 12px;
        padding: 0 4px;
        font-size: 16px;
    }

    /* Keep top back button readable and non-overlapping on small screens */
    .pope-francis-page .ctrl-back-row,
    .pope-leo-page .ctrl-back-row,
    .pope-jp2-page .ctrl-back-row,
    .pope-benedict-page .ctrl-back-row {
        position: static;
        width: auto;
        max-width: 100%;
        transform: none;
        margin: 8px auto 10px;
        padding: 0 6px;
        box-sizing: border-box;
    }

    .pope-francis-page .ctrl-back-row .back-nav-btn,
    .pope-leo-page .ctrl-back-row .back-nav-btn,
    .pope-jp2-page .ctrl-back-row .back-nav-btn,
    .pope-benedict-page .ctrl-back-row .back-nav-btn {
        display: inline-flex;
        width: auto;
        max-width: 100%;
        min-width: 0;
        white-space: normal;
        text-align: center;
        line-height: 1.2;
    }

    .pope-jp2-page .pope-jp2-title-row,
    .pope-benedict-page .pope-benedict-title-row,
    .pope-francis-page .pope-francis-title-row,
    .pope-leo-page .pope-leo-title-row {
        min-height: 0;
    }

    .pope-jp2-page .pope-jp2-title-row .title.td-left,
    .pope-benedict-page .pope-benedict-title-row .title.td-left,
    .pope-francis-page .pope-francis-title-row .title.td-left,
    .pope-leo-page .pope-leo-title-row .title.td-left {
        margin-right: 0;
    }

    .pope-jp2-page .ctrl-back-row.jp2-title-back-row,
    .pope-benedict-page .ctrl-back-row.benedict-title-back-row,
    .pope-francis-page .ctrl-back-row.francis-title-back-row,
    .pope-leo-page .ctrl-back-row.leo-title-back-row {
        position: static;
    }
}

@media (min-width: 981px) {
    .pope-jp2-page .jp2-top-row.printhide .jp2-photo-shell {
        position: absolute;
        left: 0;
        top: 30px;
        bottom: auto;
        width: 250px;
        height: 250px;
        min-width: 250px;
        max-width: none;
        margin: 0;
        padding: 8px;
    }

    .pope-benedict-page .jp2-top-row.printhide .jp2-photo-shell {
        position: absolute;
        left: 0;
        top: 30px;
        bottom: auto;
        width: 250px;
        height: 250px;
        min-width: 250px;
        max-width: none;
        margin: 0;
        padding: 8px;
    }

    .pope-leo-page .jp2-top-row.printhide {
        position: relative;
        display: block;
        min-height: 0;
        margin: 8px 0 26px;
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell {
        position: absolute;
        left: 0;
        top: 30px;
        bottom: auto;
        width: 250px;
        height: 250px;
        min-width: 250px;
        max-width: none;
        margin: 0;
        padding: 8px;
        overflow: visible;
        --pope-nameplate-height: 40px;
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell::after {
        content: var(--pope-photo-name, 'Pope Leo XIV');
        position: absolute;
        left: -1px;
        right: -1px;
        top: 100%;
        margin-top: -1px;
        height: var(--pope-nameplate-height);
        border: 1px solid #2b6dcc;
        border-radius: 0 0 6px 6px;
        background: linear-gradient(180deg, #f7fbff 0%, #e6f0ff 100%);
        color: #183f78;
        display: flex;
        align-items: center;
        justify-content: center;
        font-family: 'Trebuchet MS', Arial, sans-serif;
        font-size: 14px;
        font-weight: 700;
        letter-spacing: 0.2px;
        text-shadow: 0 1px 0 rgba(255, 255, 255, 0.85);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
        box-sizing: border-box;
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.mother-teresa-photo-shell {
        --pope-photo-name: 'St. Teresa of Calcutta';
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.fulton-sheen-photo-shell {
        --pope-photo-name: 'Ven. Archbishop Fulton Sheen';
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.padre-pio-photo-shell {
        --pope-photo-name: 'St. Padre Pio';
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.faustina-photo-shell {
        --pope-photo-name: 'St. Faustina Kowalska';
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.dina-belanger-photo-shell {
        --pope-photo-name: 'Bl. Dina Belanger';
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.john-bosco-photo-shell {
        --pope-photo-name: 'St. John Bosco';
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.peter-eymard-photo-shell {
        --pope-photo-name: 'St. Peter Julian Eymard';
    }

    .pope-leo-page .jp2-top-row.printhide .jp2-photo-shell.john-vianney-photo-shell {
        --pope-photo-name: 'St. John Vianney';
    }

    .pope-francis-page .jp2-top-row.printhide .jp2-photo-shell {
        bottom: auto;
        width: 250px;
        height: 250px;
        min-width: 250px;
        overflow: visible;
        --pope-nameplate-height: 40px;
    }

    .pope-benedict-page .jp2-top-row.printhide .jp2-photo-shell {
        bottom: auto;
        width: 250px;
        height: 250px;
        min-width: 250px;
        overflow: visible;
        --pope-nameplate-height: 40px;
    }

    .pope-jp2-page .jp2-top-row.printhide .jp2-photo-shell {
        bottom: auto;
        width: 250px;
        height: 250px;
        min-width: 250px;
        overflow: visible;
        --pope-nameplate-height: 40px;
    }

    .pope-francis-page .jp2-top-row.printhide .jp2-photo-shell::after {
        content: 'Pope Francis';
        position: absolute;
        left: -1px;
        right: -1px;
        top: 100%;
        margin-top: -1px;
        height: var(--pope-nameplate-height);
        border: 1px solid #2b6dcc;
        border-radius: 0 0 6px 6px;
        background: linear-gradient(180deg, #f7fbff 0%, #e6f0ff 100%);
        color: #183f78;
        display: flex;
        align-items: center;
        justify-content: center;
        font-family: 'Trebuchet MS', Arial, sans-serif;
        font-size: 14px;
        font-weight: 700;
        letter-spacing: 0.2px;
        text-shadow: 0 1px 0 rgba(255, 255, 255, 0.85);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
        box-sizing: border-box;
    }

    .pope-benedict-page .jp2-top-row.printhide .jp2-photo-shell::after {
        content: 'Pope Benedict XVI';
        position: absolute;
        left: -1px;
        right: -1px;
        top: 100%;
        margin-top: -1px;
        height: var(--pope-nameplate-height);
        border: 1px solid #2b6dcc;
        border-radius: 0 0 6px 6px;
        background: linear-gradient(180deg, #f7fbff 0%, #e6f0ff 100%);
        color: #183f78;
        display: flex;
        align-items: center;
        justify-content: center;
        font-family: 'Trebuchet MS', Arial, sans-serif;
        font-size: 14px;
        font-weight: 700;
        letter-spacing: 0.2px;
        text-shadow: 0 1px 0 rgba(255, 255, 255, 0.85);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
        box-sizing: border-box;
    }

    .pope-jp2-page .jp2-top-row.printhide .jp2-photo-shell::after {
        content: var(--pope-photo-name, 'St. Pope John Paul II');
        position: absolute;
        left: -1px;
        right: -1px;
        top: 100%;
        margin-top: -1px;
        height: var(--pope-nameplate-height);
        border: 1px solid #2b6dcc;
        border-radius: 0 0 6px 6px;
        background: linear-gradient(180deg, #f7fbff 0%, #e6f0ff 100%);
        color: #183f78;
        display: flex;
        align-items: center;
        justify-content: center;
        font-family: 'Trebuchet MS', Arial, sans-serif;
        font-size: 14px;
        font-weight: 700;
        letter-spacing: 0.2px;
        text-shadow: 0 1px 0 rgba(255, 255, 255, 0.85);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
        box-sizing: border-box;
    }

    .pope-jp2-page .jp2-top-row.printhide .jp2-photo-shell.hardon-photo-shell {
        --pope-photo-name: 'S.D. Fr. John Hardon';
    }

    .pope-jp2-page .jp2-top-row.printhide .jp2-photo-shell[data-pope-nameplate]::after {
        content: attr(data-pope-nameplate);
    }

    .pre-leo-page .jp2-top-row.printhide .jp2-photo-shell::after {
        content: none;
        display: none;
    }

    .pope-francis-page .jp2-top-row.printhide .jp2-photo-shell {
        top: 30px;
    }

    .pope-leo-page .jp2-top-row.printhide .ctrl-panel-row {
        width: 320px;
        margin: 0 auto;
        transform: translateX(var(--jp2-center-offset));
    }
}

/* Fallback toast for pages without summary-nav panel */
.pope-ctrl-toast {
    position: relative;
    margin-top: 6px;
    padding: 5px 10px;
    background: #eaf3fb;
    border: 1px solid #a8c8e8;
    border-radius: 4px;
    font-size: 0.82em;
    color: #1a3a55;
    text-align: center;
    transition: opacity 0.4s ease;
    opacity: 1;
}
.pope-ctrl-toast.pope-ctrl-toast-fade {
    opacity: 0;
}

