﻿/*
  Azure Parish Webapp theme
  Drop this file in wwwroot/css/site.css.
  It keeps the existing parish-specific classes and adds MVC/Bootstrap-compatible
  fallbacks so the dark gold/orange styling applies across layout, forms,
  tables, staff portal, bookings, articles, alerts, and readings.
*/

@import url('https://fonts.googleapis.com/css2?family=Cardo:wght@400;700&family=Source+Sans+3:wght@400;500;600;700;800;900&display=swap');

:root {
    --bg: #171717;
    --bg-deep: #101010;
    --panel: #1f1f1f;
    --panel-2: #252525;
    --panel-3: #2e2e2e;
    --text: #f6f6f6;
    --muted: #9a9a9a;
    --line: #343434;
    --gold: #d4af37;
    --orange: #f08020;
    --orange-soft: #d48948;
    --green: #2ecc71;
    --red: #d9534f;
    --purple: #9878a0;
    --head: 'Cardo', Georgia, serif;
    --body: 'Source Sans 3', system-ui, sans-serif;
    --serif: 'Cardo', Georgia, serif;
}

* {
    box-sizing: border-box;
}

html {
    background: var(--bg);
    color: var(--text);
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--body);
}

a {
    color: inherit;
}

button, input, select, textarea {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(180deg, #111, rgba(17,17,17,.94));
    border-bottom: 1px solid rgba(255,255,255,.04);
    box-shadow: 0 12px 30px rgba(0,0,0,.35);
}

.nav-shell {
    max-width: 1120px;
    margin: 0 auto;
    height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
}

.brand img {
    height: 54px;
    width: auto;
    display: block;
}

.brand img.brand-logo--light,
.navbar-brand img.brand-logo--light,
.parish-footer__brand img.brand-logo--light {
    display: none !important;
}

.brand img.brand-logo--dark,
.navbar-brand img.brand-logo--dark,
.parish-footer__brand img.brand-logo--dark {
    display: block !important;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 28px;
    font-family: var(--body);
    font-weight: 800;
    font-size: 0.98rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

    .main-nav a, .nav-form button {
        color: #fff1cf;
        text-decoration: none;
        background: transparent;
        border: 0;
        padding: 8px 0;
        cursor: pointer;
        transition: color .2s, border-color .2s;
        border-bottom: 1px solid transparent;
    }

        .main-nav a:hover, .main-nav a.active, .nav-form button:hover {
            color: var(--gold);
            border-bottom-color: var(--gold);
        }

.nav-form {
    margin: 0;
}

.mobile-nav-toggle {
    display: none;
    background: none;
    border: 1px solid var(--line);
    color: #fff;
    border-radius: 4px;
    padding: 8px 10px;
}

.site-main {
    min-height: calc(100vh - 160px);
}

.page-shell {
    max-width: 1120px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

.site-footer {
    color: #666;
    border-top: 1px solid #202020;
    padding: 28px 0;
    margin-top: 60px;
}

.flash {
    max-width: 1060px;
    margin: 16px auto;
    padding: 12px 16px;
    border-radius: 8px;
}

    .flash.local {
        margin: 0 0 18px 0;
    }

.flash-success {
    background: rgba(46,204,113,.13);
    border: 1px solid rgba(46,204,113,.45);
    color: #8ff0b7;
}

.flash-error {
    background: rgba(217,83,79,.13);
    border: 1px solid rgba(217,83,79,.45);
    color: #ffaaa6;
}

.home-hero {
    padding-top: 34px;
}

.timetable-panel {
    background: #181818;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 20px 55px rgba(0,0,0,.28);
}

.timetable-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
}

.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    border-bottom: 1px solid #333;
    margin-bottom: 20px;
}

.tab-button {
    background: none;
    border: 0;
    color: #777;
    font-family: var(--head);
    font-size: 1.35rem;
    text-transform: uppercase;
    font-weight: 700;
    padding: 8px 0 12px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
}

    .tab-button.active, .tab-button:hover {
        color: var(--orange);
        border-bottom-color: var(--orange);
    }

.tab-content {
    display: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

    .tab-content.active {
        display: grid;
    }

.mass-card {
    background: #222;
    border-radius: 6px;
    padding: 16px;
    min-height: 104px;
    display: flex;
    align-items: center;
    transition: background .2s, transform .2s;
    border: 1px solid transparent;
}

    .mass-card:hover {
        background: #2a2a2a;
        transform: translateY(-2px);
        border-color: #303030;
    }

.time-block {
    min-width: 74px;
    text-align: center;
    padding-right: 14px;
    margin-right: 14px;
    border-right: 1px solid #333;
}

.mass-time {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
    color: #fff;
}

.ampm {
    display: block;
    margin-top: 4px;
    color: var(--orange);
    font-weight: 800;
    text-transform: uppercase;
}

.mass-info h3 {
    font-size: 1.05rem;
    line-height: 1.1;
    margin: 4px 0 7px;
    text-transform: uppercase;
    color: #fff;
}

.mass-info p {
    margin: 0;
    color: #8e8e8e;
}

.mass-info small {
    color: var(--orange);
    display: block;
    margin-top: 4px;
}

.day-row {
    min-height: 22px;
}

.day-badge {
    display: inline-block;
    background: #333;
    color: #aaa;
    border-radius: 3px;
    padding: 3px 6px;
    font-size: .72rem;
    text-transform: uppercase;
    margin-right: 4px;
    margin-bottom: 4px;
}

.empty-card {
    background: #222;
    border-radius: 6px;
    padding: 25px;
    color: #999;
    grid-column: 1 / -1;
}

.section-kicker {
    margin: 0 0 16px;
    font-size: 1.35rem;
    text-transform: uppercase;
    font-family: var(--head);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
}

    .section-kicker span {
        width: 3px;
        height: 30px;
        background: var(--orange);
        display: inline-block;
    }

.stream-card {
    margin-bottom: 22px;
}

    .stream-card p {
        color: #d2d2d2;
        margin: 10px 0 0;
    }

.video-shell {
    position: relative;
    background: #000;
    aspect-ratio: 16 / 9;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
}

    .video-shell video {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

.play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    place-items: center;
    background: rgba(0,0,0,.36);
    border: 0;
    color: #fff;
    cursor: pointer;
    text-align: center;
    touch-action: manipulation;
}

    .play-overlay i {
        width: 68px;
        height: 68px;
        border: 2px solid #fff;
        border-radius: 50%;
        display: grid;
        place-items: center;
        padding-left: 4px;
        font-size: 1.45rem;
        background: rgba(0, 0, 0, .34);
    }

    .play-overlay span {
        padding: 0.42rem 0.7rem;
        border-radius: 999px;
        background: rgba(0, 0, 0, .58);
        color: #fff7dc;
        font-size: 0.86rem;
        font-weight: 900;
        letter-spacing: 0.04em;
        text-transform: uppercase;
    }

.video-shell.is-loading .play-overlay span {
    visibility: hidden;
}

.video-shell.is-loading .play-overlay::after {
    content: "Loading stream...";
    padding: 0.42rem 0.7rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, .58);
    color: #fff7dc;
    font-size: 0.86rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.video-shell.needs-tap .play-overlay span {
    visibility: hidden;
}

.video-shell.needs-tap .play-overlay::after {
    content: "Tap again to play";
    padding: 0.42rem 0.7rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, .58);
    color: #fff7dc;
    font-size: 0.86rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.video-shell.playing .play-overlay {
    display: none;
}

.live-controls {
    position: absolute;
    left: 50%;
    right: auto;
    bottom: 10px;
    z-index: 4;
    display: flex;
    align-items: center;
    gap: 9px;
    width: max-content;
    max-width: calc(100% - 20px);
    padding: 8px;
    border: 1px solid rgba(234, 209, 138, 0.24);
    border-radius: 999px;
    background: rgba(5, 4, 3, 0.78);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.34);
    opacity: 0;
    pointer-events: none;
    transform: translateX(-50%);
    transition: opacity 0.18s ease;
}

.video-shell.playing .live-controls,
.live-stream-player-shell.is-playing .live-controls {
    opacity: 1;
    pointer-events: auto;
}

.live-control-btn {
    width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    flex: 0 0 34px;
    border: 1px solid rgba(234, 209, 138, 0.28);
    border-radius: 50%;
    background: rgba(214, 177, 83, 0.12);
    color: #fff7dc;
    cursor: pointer;
}

.live-cast-icon {
    width: 19px;
    height: 19px;
    display: block;
    fill: currentColor;
}

.live-control-btn:hover,
.live-control-btn:focus {
    border-color: rgba(234, 209, 138, 0.72);
    color: var(--gold);
    outline: none;
}

.live-cast-toggle {
    display: none;
}

.cast-available .live-cast-toggle {
    display: inline-grid;
}

.live-volume {
    width: 76px;
    height: 34px;
    max-width: 22vw;
    flex: 0 0 76px;
    margin: 0 2px;
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    cursor: pointer;
}

.live-volume--compact::-webkit-slider-runnable-track {
    height: 4px;
    border-radius: 999px;
    background: rgba(234, 209, 138, 0.35);
}

.live-volume--compact::-webkit-slider-thumb {
    width: 15px;
    height: 15px;
    margin-top: -5.5px;
    border: 2px solid #fff7dc;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
    -webkit-appearance: none;
    appearance: none;
}

.live-volume--compact::-moz-range-track {
    height: 4px;
    border-radius: 999px;
    background: rgba(234, 209, 138, 0.35);
}

.live-volume--compact::-moz-range-thumb {
    width: 15px;
    height: 15px;
    border: 2px solid #fff7dc;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
}

.live-controls--large {
    left: 50%;
    right: auto;
    bottom: 16px;
    max-width: calc(100% - 32px);
}

html[data-theme="light"] .live-controls {
    border-color: rgba(139, 101, 24, 0.24);
    background: rgba(36, 29, 20, 0.84);
}

.video-shell:fullscreen,
.live-stream-player-shell:fullscreen {
    width: 100vw !important;
    height: 100vh !important;
    max-width: none !important;
    max-height: none !important;
    aspect-ratio: auto !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: #000 !important;
}

.video-shell:-webkit-full-screen,
.live-stream-player-shell:-webkit-full-screen {
    width: 100vw !important;
    height: 100vh !important;
    max-width: none !important;
    max-height: none !important;
    aspect-ratio: auto !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: #000 !important;
}

.video-shell:fullscreen video,
.live-stream-player-shell:fullscreen video,
.video-shell:-webkit-full-screen video,
.live-stream-player-shell:-webkit-full-screen video {
    width: 100vw !important;
    height: 100vh !important;
    object-fit: contain !important;
    object-position: center center !important;
    background: #000 !important;
}

.video-shell:fullscreen .live-controls,
.live-stream-player-shell:fullscreen .live-controls,
.video-shell:-webkit-full-screen .live-controls,
.live-stream-player-shell:-webkit-full-screen .live-controls {
    left: 50% !important;
    right: auto !important;
    bottom: max(14px, env(safe-area-inset-bottom)) !important;
    width: max-content !important;
    max-width: calc(100vw - 32px) !important;
    gap: clamp(10px, 2vw, 16px) !important;
    padding: 10px 12px !important;
    transform: translateX(-50%) !important;
}

.video-shell:fullscreen .live-control-btn,
.live-stream-player-shell:fullscreen .live-control-btn,
.video-shell:-webkit-full-screen .live-control-btn,
.live-stream-player-shell:-webkit-full-screen .live-control-btn {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
}

.video-shell:fullscreen .live-volume,
.live-stream-player-shell:fullscreen .live-volume,
.video-shell:-webkit-full-screen .live-volume,
.live-stream-player-shell:-webkit-full-screen .live-volume {
    width: 150px;
    max-width: 28vw;
    flex-basis: 150px;
}

@media (max-width: 480px) {
    .video-shell:fullscreen .live-controls,
    .live-stream-player-shell:fullscreen .live-controls,
    .video-shell:-webkit-full-screen .live-controls,
    .live-stream-player-shell:-webkit-full-screen .live-controls {
        width: max-content !important;
        max-width: calc(100vw - 20px) !important;
        gap: 8px !important;
        padding: 8px 10px !important;
    }

    .video-shell:fullscreen .live-control-btn,
    .live-stream-player-shell:fullscreen .live-control-btn,
    .video-shell:-webkit-full-screen .live-control-btn,
    .live-stream-player-shell:-webkit-full-screen .live-control-btn {
        width: 38px;
        height: 38px;
        flex-basis: 38px;
    }

    .video-shell:fullscreen .live-volume,
    .live-stream-player-shell:fullscreen .live-volume,
    .video-shell:-webkit-full-screen .live-volume,
    .live-stream-player-shell:-webkit-full-screen .live-volume {
        width: 104px;
        max-width: 26vw;
        flex-basis: 104px;
    }
}

.alert-banner {
    background: #222;
    border-left: 5px solid var(--red);
    padding: 16px 20px;
    margin-bottom: 24px;
    border-radius: 0 6px 6px 0;
    box-shadow: 0 6px 18px rgba(0,0,0,.28);
}

.alert-title {
    color: var(--gold);
    font-family: var(--head);
    font-size: 1.25rem;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.alert-body p {
    margin: 0 0 8px;
}

.alert-link {
    color: var(--gold);
    font-weight: 700;
    text-decoration: none;
}

.articles-section {
    padding-top: 70px;
}

    .articles-section.standalone {
        padding-top: 40px;
    }

.section-header {
    border-bottom: 1px solid #333;
    padding-bottom: 16px;
    margin-bottom: 28px;
}

    .section-header h1, .section-header h2 {
        margin: 0;
        font-family: var(--head);
        text-transform: uppercase;
        font-size: 2rem;
        letter-spacing: 1px;
    }

    .section-header p {
        color: #ddd;
        margin: 4px 0 0;
    }

.article-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.article-card {
    position: relative;
    min-height: 370px;
    background-size: cover;
    background-position: center;
    overflow: hidden;
    border-radius: 0;
    background-color: #000;
    transition: transform .3s ease;
}

    .article-card:hover {
        transform: translateY(-5px);
    }

    .article-card::after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(to bottom, rgba(0,0,0,.05), rgba(0,0,0,.15) 40%, rgba(0,0,0,.95));
    }

.article-hit {
    position: absolute;
    inset: 0;
    z-index: 3;
    text-indent: -9999px;
}

.article-content {
    position: absolute;
    z-index: 2;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 24px;
    pointer-events: none;
}

.article-cat {
    color: #ccc;
    font-family: var(--head);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: .78rem;
}

.article-content h3 {
    font-family: var(--head);
    text-transform: none;
    font-size: 2rem;
    line-height: .95;
    margin: 6px 0 12px;
}

    .article-content h3 .first-word {
        color: var(--orange);
        display: block;
    }

    .article-content h3 .rest-words {
        color: #fff;
    }

.article-content p {
    color: #ddd;
    margin: 0;
    font-size: .92rem;
    line-height: 1.45;
}

.content-card, .auth-card, .manager-card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 14px 38px rgba(0,0,0,.25);
}

.content-card {
    padding: 34px;
    margin-top: 40px;
}

    .content-card h1, .content-card h2 {
        font-family: var(--head);
        text-transform: uppercase;
    }

.btn-gold, .btn-outline, .btn-muted, .mini-btn, .portal-logout-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    border-radius: 5px;
    cursor: pointer;
    font-family: var(--head);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .4px;
}

.btn-gold {
    background: var(--gold);
    color: #111;
    border: 1px solid var(--gold);
    padding: 10px 16px;
}

.btn-outline {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
    padding: 9px 15px;
}

.btn-muted {
    background: #333;
    color: #eee;
    border: 1px solid #444;
    padding: 9px 15px;
}

.btn-gold.full {
    width: 100%;
}

.mini-btn {
    background: #333;
    color: #fff;
    border: 1px solid #454545;
    padding: 5px 9px;
    font-size: .8rem;
}

    .mini-btn.danger {
        background: var(--red);
        border-color: var(--red);
    }

.auth-wrap {
    padding-top: 60px;
    display: flex;
    justify-content: center;
}

.auth-card {
    width: min(460px, 100%);
    padding: 30px;
}

    .auth-card h1 {
        font-family: var(--head);
        text-transform: uppercase;
        margin-top: 0;
    }

.validation-summary {
    color: #ffaaa6;
    margin-bottom: 10px;
}

.staff-portal-wrap {
    background: #121212;
    min-height: 82vh;
    padding: 44px 20px;
}

.staff-portal-container {
    max-width: 1120px;
    margin: 0 auto;
}

.portal-header {
    background: var(--panel);
    border: 1px solid var(--line);
    border-left: 5px solid var(--gold);
    border-radius: 8px;
    padding: 25px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,.35);
    margin-bottom: 38px;
}

.portal-welcome h1 {
    font-family: var(--head);
    text-transform: uppercase;
    margin: 0;
    letter-spacing: 1px;
    font-size: 2rem;
}

.portal-welcome p {
    color: #bbb;
    margin: 4px 0 0;
}

.portal-logout-btn {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
    padding: 10px 20px;
}

    .portal-logout-btn:hover {
        background: var(--gold);
        color: #111;
    }

.portal-grid-title {
    font-family: var(--head);
    font-size: 1.55rem;
    color: #fff;
    margin: 38px 0 16px;
    border-bottom: 1px solid var(--line);
    padding-bottom: 8px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 10px;
}

    .portal-grid-title i {
        color: var(--orange-soft);
        font-size: 1.1rem;
    }

.portal-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

.portal-tile {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 30px 20px;
    min-height: 150px;
    text-decoration: none;
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: transform .2s, border-color .2s, background .2s;
}

    .portal-tile:hover {
        transform: translateY(-5px);
        border-color: var(--gold);
        background: #252525;
    }

.portal-icon {
    font-size: 2.35rem;
    color: var(--gold);
    margin-bottom: 16px;
}

    .portal-icon.secondary {
        color: var(--orange-soft);
    }

.portal-label {
    font-family: var(--head);
    text-transform: uppercase;
    font-size: 1.15rem;
    font-weight: 700;
}

.portal-desc {
    color: #aaa;
    font-size: .9rem;
    margin-top: 4px;
}

.portal-footer {
    text-align: center;
    color: #555;
    margin-top: 50px;
    border-top: 1px solid #222;
    padding-top: 18px;
}

.manager-wrap {
    padding-top: 36px;
}

.manager-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
    flex-wrap: wrap;
}

    .manager-header h1 {
        font-family: var(--head);
        text-transform: uppercase;
        margin: 0;
    }

.manager-card {
    padding: 22px;
    margin-bottom: 22px;
}

    .manager-card h2, .manager-card h3 {
        font-family: var(--head);
        text-transform: uppercase;
        margin-top: 0;
    }

.manager-grid {
    display: grid;
    gap: 22px;
}

    .manager-grid.two {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

.stack-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.spaced-top {
    margin-top: 14px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    align-items: end;
}

    .form-row.three {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .form-row.four {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

.form-button {
    display: flex;
    align-items: end;
}

.form-input {
    width: 100%;
    background: #111;
    border: 1px solid #444;
    color: #fff;
    border-radius: 5px;
    padding: 10px;
}

    .form-input.small {
        max-width: 90px;
    }

textarea.form-input {
    resize: vertical;
}

.code-box {
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}

label {
    color: #bbb;
    font-size: .9rem;
    font-weight: 700;
}

.checkbox-row {
    display: flex;
    gap: 8px;
    align-items: center;
    color: #ddd;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    background: #151515;
    border: 1px solid #333;
    padding: 10px;
    border-radius: 5px;
}

    .checkbox-grid label, .tiny-check {
        display: flex;
        gap: 6px;
        align-items: center;
        color: #ddd;
        font-weight: 400;
    }

.list-table {
    display: grid;
    gap: 8px;
    margin-top: 16px;
}

.list-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    background: #171717;
    border: 1px solid #303030;
    border-radius: 5px;
    padding: 10px;
}

.row-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

    .row-actions form {
        margin: 0;
    }

.badge {
    display: inline-block;
    background: #333;
    color: var(--gold);
    border: 1px solid #4a4a4a;
    padding: 2px 7px;
    border-radius: 999px;
    font-size: .75rem;
    text-transform: uppercase;
}

    .badge.danger {
        color: #fff;
        background: var(--red);
        border-color: var(--red);
    }

.muted {
    color: var(--muted);
}

.center {
    text-align: center;
}

.accent {
    color: var(--orange-soft);
}

.table-scroll {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    color: #e8e8e8;
}

    .admin-table th {
        background: #202020;
        color: var(--orange-soft);
        text-transform: uppercase;
        font-size: .78rem;
        text-align: left;
        padding: 10px;
        border-bottom: 1px solid #444;
    }

    .admin-table td {
        border-bottom: 1px solid #333;
        padding: 10px;
        vertical-align: middle;
    }

    .admin-table tr:hover {
        background: #242424;
    }

.inline-form {
    display: flex;
    gap: 6px;
    align-items: center;
}

.inline-stack details {
    min-width: 150px;
}

.status-select {
    border: 0;
    border-radius: 4px;
    padding: 5px 8px;
    font-weight: 700;
    color: #fff;
    background: #555;
}

    .status-select.approved {
        background: #28a745;
    }

    .status-select.pending {
        background: #ffc107;
        color: #111;
    }

    .status-select.declined {
        background: #dc3545;
    }

.status-dot.approved {
    color: #73e39a;
}

.status-dot.muted {
    color: #777;
}

.log-box {
    margin-top: 14px;
    background: #050505;
    color: #70ff70;
    font-family: ui-monospace, Consolas, monospace;
    padding: 14px;
    border-radius: 6px;
    max-height: 520px;
    overflow: auto;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 1px;
    background: #333;
    border: 1px solid #333;
}

.calendar-head {
    background: #202020;
    color: var(--gold);
    font-family: var(--head);
    text-transform: uppercase;
    padding: 10px;
    text-align: center;
}

.calendar-cell {
    min-height: 135px;
    background: #1d1d1d;
    padding: 8px;
}

    .calendar-cell.empty {
        background: #141414;
    }

.calendar-day {
    color: #aaa;
    font-weight: 700;
    margin-bottom: 8px;
}

.calendar-event {
    border-left: 3px solid var(--orange);
    background: #292929;
    padding: 6px;
    margin-bottom: 5px;
    border-radius: 4px;
    font-size: .82rem;
}

    .calendar-event.anniversary {
        border-left-color: var(--gold);
    }

    .calendar-event.baptism {
        border-left-color: #8686ac;
    }

    .calendar-event.wedding {
        border-left-color: #b35959;
    }

    .calendar-event.confession {
        border-left-color: var(--purple);
    }

.article-hero-wrap {
    display: flex;
    justify-content: center;
    padding: 40px 0 20px;
}

.article-hero-card {
    position: relative;
    width: min(94%, 1300px);
    height: clamp(420px, 62vh, 800px);
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 28px 60px rgba(0,0,0,.65);
}

    .article-hero-card::before {
        content: "";
        position: absolute;
        inset: 14px;
        z-index: 2;
        border: 1px solid rgba(255,255,255,.13);
        border-radius: 22px;
        pointer-events: none;
    }

    .article-hero-card img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        filter: contrast(1.08) saturate(1.06);
    }

.article-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 42%, rgba(0,0,0,.82));
}

.article-hero-title {
    position: absolute;
    z-index: 3;
    left: 8%;
    right: 8%;
    bottom: 46px;
    text-align: center;
}

    .article-hero-title h1 {
        font-family: var(--serif);
        font-size: clamp(2rem, 4vw, 3.6rem);
        margin: 0;
        text-shadow: 0 3px 14px rgba(0,0,0,.8);
    }

.article-detail {
    max-width: 840px;
    line-height: 1.8;
}

.bulletin-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.bulletin-card {
    background: #171717;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 20px;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

    .bulletin-card i {
        color: var(--gold);
        font-size: 2rem;
    }

    .bulletin-card span {
        color: var(--muted);
    }

.readings-wrap {
    margin-top: 40px;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 8px;
    padding-top: 30px;
    padding-bottom: 30px;
    max-width: 860px;
}

.fr-meta-header {
    text-align: center;
    background: #222;
    border-bottom: 4px solid var(--gold);
    border-radius: 8px;
    padding: 28px;
    margin-bottom: 40px;
}

.fr-day-title {
    font-family: var(--head);
    font-size: 2rem;
    font-weight: 700;
}

.fr-date-row {
    display: inline-block;
    margin-top: 8px;
    color: #999;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.Universalis_number {
    display: none !important;
}

.fr-section {
    border-bottom: 1px solid #333;
    padding-bottom: 34px;
    margin-bottom: 34px;
    scroll-margin-top: 100px;
}

    .fr-section h2 {
        font-family: var(--head);
        color: var(--gold);
        font-size: 1.8rem;
        text-transform: uppercase;
    }

.fr-conditional-hide {
    display: none;
}

.fr-dynamic-heading {
    color: #fff;
    font-size: 1.15rem;
    margin-bottom: 10px;
}

.fr-source {
    color: #999;
    border-left: 3px solid #00796b;
    padding-left: 10px;
    margin-bottom: 20px;
}

.fr-body {
    color: #e0e0e0;
    font-size: 1.12rem;
    line-height: 1.8;
}

@media (max-width: 960px) {
    .timetable-grid, .manager-grid.two {
        grid-template-columns: 1fr;
    }

    .article-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .portal-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .main-nav {
        display: none;
        position: absolute;
        top: 76px;
        left: 0;
        right: 0;
        background: #151515;
        padding: 20px 24px;
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        border-bottom: 2px solid var(--gold);
    }

        .main-nav.open {
            display: flex;
        }

    .mobile-nav-toggle {
        display: inline-flex;
    }

    .tab-content.active {
        grid-template-columns: 1fr;
    }

    .article-grid, .bulletin-grid, .portal-grid, .form-row, .form-row.three, .form-row.four {
        grid-template-columns: 1fr;
    }

    .timetable-panel {
        padding: 18px;
    }

    .checkbox-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .calendar-grid {
        display: block;
        background: transparent;
        border: 0;
    }

    .calendar-head, .calendar-cell.empty {
        display: none;
    }

    .calendar-cell {
        margin-bottom: 8px;
        border: 1px solid #333;
    }
}

.inline-rule-form {
    display: grid;
    grid-template-columns: repeat(6, minmax(100px, auto)) minmax(220px, 1fr) auto;
    gap: 10px;
    align-items: center;
}

    .inline-rule-form textarea {
        min-width: 220px;
    }

.soft-line {
    border: 0;
    border-top: 1px solid var(--line);
    margin: 18px 0;
}

.schema-row {
    align-items: flex-start;
}

    .schema-row pre {
        margin: 8px 0 0;
        max-width: 720px;
        white-space: pre-wrap;
        color: #aaa;
        background: #101010;
        border: 1px solid #333;
        padding: 8px;
        border-radius: 4px;
    }

@media (max-width: 960px) {
    .inline-rule-form {
        grid-template-columns: 1fr 1fr;
    }
}

/* --------------------------------------------------------------------------
   MVC / Bootstrap compatibility and polish
   -------------------------------------------------------------------------- */

:root {
    --focus: rgba(212, 175, 55, .35);
    --shadow-soft: 0 14px 38px rgba(0, 0, 0, .25);
    --shadow-heavy: 0 28px 60px rgba(0, 0, 0, .55);
    --radius-sm: 5px;
    --radius-md: 8px;
    --radius-lg: 10px;
}

html {
    color-scheme: dark;
    min-height: 100%;
}

body {
    min-height: 100vh;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img,
svg,
video,
canvas {
    max-width: 100%;
}

img {
    height: auto;
}

p {
    margin-top: 0;
}

a {
    text-underline-offset: .18em;
}

    a:hover {
        color: var(--gold);
    }

:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 3px;
}

::selection {
    background: rgba(212, 175, 55, .28);
    color: #fff;
}

/* Layout wrappers used by the default ASP.NET Core MVC template. */
.container,
.container-sm,
.container-md,
.container-lg,
.container-xl,
.container-xxl,
.page-shell {
    width: min(100%, 1120px);
}

.container,
.page-shell {
    margin-left: auto;
    margin-right: auto;
    padding-left: 24px;
    padding-right: 24px;
}

main.container,
main .container,
.site-main > .container,
.site-main > .page-shell {
    padding-top: 28px;
}

/* Bootstrap navbar fallback: keeps the custom .site-header/.main-nav styling
   even when _Layout.cshtml still uses navbar/nav-link/navbar-collapse classes. */
header,
.site-header,
.navbar {
    background: linear-gradient(180deg, #111, rgba(17, 17, 17, .94)) !important;
    color: var(--text);
}

    .navbar,
    .site-header .navbar {
        padding: 0;
        border-bottom: 1px solid rgba(255, 255, 255, .04);
        box-shadow: 0 12px 30px rgba(0, 0, 0, .35);
    }

        .navbar .container,
        .navbar .container-fluid,
        .nav-shell {
            min-height: 76px;
        }

.navbar-brand,
.brand {
    color: #fff1cf !important;
    font-family: var(--serif);
    font-weight: 700;
    text-decoration: none;
}

    .navbar-brand:hover,
    .brand:hover {
        color: var(--gold) !important;
    }

    .navbar-brand img,
    .brand img {
        max-height: 54px;
        width: auto;
    }

.navbar-nav,
.main-nav {
    align-items: center;
}

    .navbar-nav .nav-link,
    .navbar-light .navbar-nav .nav-link,
    .navbar-dark .navbar-nav .nav-link,
    .site-header .nav-link,
    .main-nav a,
    .nav-form button {
        color: #fff1cf !important;
        border-bottom: 1px solid transparent;
        font-family: var(--serif);
        font-weight: 700;
    }

        .navbar-nav .nav-link:hover,
        .navbar-nav .nav-link:focus,
        .navbar-nav .nav-link.active,
        .navbar-nav .show > .nav-link,
        .site-header .nav-link:hover,
        .site-header .nav-link:focus,
        .site-header .nav-link.active,
        .main-nav a:hover,
        .main-nav a:focus,
        .main-nav a.active,
        .nav-form button:hover,
        .nav-form button:focus {
            color: var(--gold) !important;
            border-bottom-color: var(--gold);
        }

.navbar-toggler,
.mobile-nav-toggle {
    border: 1px solid var(--line) !important;
    color: #fff !important;
    background: rgba(255, 255, 255, .03) !important;
    border-radius: var(--radius-sm);
    padding: 8px 10px;
}

    .navbar-toggler:focus,
    .mobile-nav-toggle:focus {
        box-shadow: 0 0 0 .2rem var(--focus);
    }

.navbar-toggler-icon {
    filter: invert(1) sepia(.4) saturate(1.2);
}

.dropdown-menu {
    background: var(--panel);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-soft);
}

.main-nav .nav-dropdown {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.main-nav .nav-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

    .main-nav .nav-dropdown-toggle i {
        font-size: 0.72rem;
        transition: transform 0.2s ease;
    }

.main-nav .nav-dropdown:hover .nav-dropdown-toggle i,
.main-nav .nav-dropdown:focus-within .nav-dropdown-toggle i {
    transform: rotate(180deg);
}

.main-nav .nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    min-width: 230px;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    background: rgba(10, 13, 28, 0.97);
    border: 1px solid rgba(231, 198, 106, 0.28);
    border-radius: 14px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.35);
    transform: translateX(-50%) translateY(10px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 100;
}

.main-nav .nav-dropdown:hover .nav-dropdown-menu,
.main-nav .nav-dropdown:focus-within .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}

.main-nav .nav-dropdown-menu a {
    display: block;
    padding: 0.65rem 0.85rem;
    border-bottom: 0;
    border-radius: 10px;
    white-space: nowrap;
    text-decoration: none;
}

    .main-nav .nav-dropdown-menu a:hover,
    .main-nav .nav-dropdown-menu a.active {
        background: rgba(231, 198, 106, 0.14);
    }

/* Match this breakpoint to your existing mobile nav breakpoint if different */
@media (max-width: 900px) {
    .main-nav .nav-dropdown {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }

    .main-nav .nav-dropdown-toggle {
        width: 100%;
        justify-content: space-between;
    }

    .main-nav .nav-dropdown-menu {
        position: static;
        width: 100%;
        min-width: 0;
        margin-top: 0.35rem;
        padding: 0.35rem 0 0.35rem 1rem;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: none;
        background: transparent;
        border: 0;
        box-shadow: none;
    }

    .main-nav .nav-dropdown:hover .nav-dropdown-menu,
    .main-nav .nav-dropdown:focus-within .nav-dropdown-menu {
        transform: none;
    }

    .main-nav .nav-dropdown-menu a {
        white-space: normal;
    }
}

.dropdown-item {
    color: #fff1cf;
}

    .dropdown-item:hover,
    .dropdown-item:focus {
        background: var(--panel-2);
        color: var(--gold);
    }

/* Cards and content surfaces. */
.card,
.content-card,
.auth-card,
.manager-card,
.timetable-panel,
.readings-wrap {
    background: var(--panel);
    border-color: var(--line);
    color: var(--text);
}

.card {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
}

.card-header,
.card-footer {
    background: var(--panel-2);
    border-color: var(--line);
    color: var(--text);
}

.card-title,
.card h1,
.card h2,
.card h3 {
    font-family: var(--head);
    text-transform: uppercase;
}

/* Buttons: map Bootstrap/default MVC button classes onto the parish palette. */
.btn,
button,
[type='button'],
[type='submit'],
[type='reset'] {
    transition: background .2s ease, border-color .2s ease, color .2s ease, transform .2s ease, box-shadow .2s ease;
}

    .btn:hover,
    .btn-gold:hover,
    .btn-outline:hover,
    .btn-muted:hover,
    .mini-btn:hover {
        transform: translateY(-1px);
    }

.btn-primary,
.btn-success,
.btn-gold {
    background: var(--gold) !important;
    border-color: var(--gold) !important;
    color: #111 !important;
}

    .btn-primary:hover,
    .btn-primary:focus,
    .btn-success:hover,
    .btn-success:focus,
    .btn-gold:hover,
    .btn-gold:focus {
        background: #e2bf49 !important;
        border-color: #e2bf49 !important;
        color: #111 !important;
        box-shadow: 0 0 0 .2rem var(--focus);
    }

.btn-outline-primary,
.btn-outline-warning,
.btn-outline {
    background: transparent !important;
    border-color: var(--gold) !important;
    color: var(--gold) !important;
}

    .btn-outline-primary:hover,
    .btn-outline-primary:focus,
    .btn-outline-warning:hover,
    .btn-outline-warning:focus,
    .btn-outline:hover,
    .btn-outline:focus,
    .portal-logout-btn:hover,
    .portal-logout-btn:focus {
        background: var(--gold) !important;
        border-color: var(--gold) !important;
        color: #111 !important;
        box-shadow: 0 0 0 .2rem var(--focus);
    }

.btn-secondary,
.btn-muted {
    background: #333 !important;
    border-color: #444 !important;
    color: #eee !important;
}

    .btn-secondary:hover,
    .btn-secondary:focus,
    .btn-muted:hover,
    .btn-muted:focus {
        background: #3e3e3e !important;
        border-color: #565656 !important;
        color: #fff !important;
    }

.btn-danger,
.mini-btn.danger {
    background: var(--red) !important;
    border-color: var(--red) !important;
    color: #fff !important;
}

.btn-link {
    color: var(--gold);
    text-decoration-color: rgba(212, 175, 55, .45);
}

    .btn-link:hover,
    .btn-link:focus {
        color: #e2bf49;
    }

.btn-sm,
.mini-btn {
    padding: 5px 9px;
    font-size: .8rem;
}

/* Forms and validation. */
.form-control,
.form-select,
.form-input,
input[type='text'],
input[type='email'],
input[type='password'],
input[type='number'],
input[type='date'],
input[type='time'],
input[type='datetime-local'],
input[type='search'],
input[type='tel'],
input[type='url'],
select,
textarea {
    background-color: #111 !important;
    border: 1px solid #444 !important;
    border-radius: var(--radius-sm);
    color: #fff !important;
    padding: 10px;
}

    .form-control::placeholder,
    .form-input::placeholder,
    textarea::placeholder,
    input::placeholder {
        color: #777;
        opacity: 1;
    }

    .form-control:focus,
    .form-select:focus,
    .form-input:focus,
    input:focus,
    select:focus,
    textarea:focus {
        background-color: #141414 !important;
        border-color: var(--gold) !important;
        color: #fff !important;
        box-shadow: 0 0 0 .2rem var(--focus) !important;
    }

.form-check-input,
input[type='checkbox'],
input[type='radio'] {
    accent-color: var(--gold);
}

.form-text,
.text-muted,
.muted {
    color: var(--muted) !important;
}

.text-danger,
.field-validation-error,
.validation-summary-errors,
.validation-summary,
.input-validation-error + span {
    color: #ffaaa6 !important;
}

.input-validation-error,
.form-control.input-validation-error,
.form-input.input-validation-error {
    border-color: var(--red) !important;
    box-shadow: 0 0 0 .15rem rgba(217, 83, 79, .25) !important;
}

/* Alerts / flash messages. */
.alert,
.flash {
    border-radius: var(--radius-md);
}

.alert-success,
.flash-success {
    background: rgba(46, 204, 113, .13) !important;
    border: 1px solid rgba(46, 204, 113, .45) !important;
    color: #8ff0b7 !important;
}

html[data-theme="light"] .alert-success,
html[data-theme="light"] .flash-success {
    background: #eaf7ec !important;
    border-color: #65b878 !important;
    color: #1f6f37 !important;
}

.alert-danger,
.alert-error,
.flash-error {
    background: rgba(217, 83, 79, .13) !important;
    border: 1px solid rgba(217, 83, 79, .45) !important;
    color: #ffaaa6 !important;
}

.alert-warning {
    background: rgba(240, 128, 32, .14) !important;
    border: 1px solid rgba(240, 128, 32, .42) !important;
    color: #ffd7b1 !important;
}

.alert-info {
    background: rgba(152, 120, 160, .16) !important;
    border: 1px solid rgba(152, 120, 160, .45) !important;
    color: #decbe3 !important;
}

/* Tables: support both .admin-table and Bootstrap .table output. */
.table,
.admin-table {
    --bs-table-bg: transparent;
    --bs-table-color: #e8e8e8;
    --bs-table-border-color: #333;
    color: #e8e8e8 !important;
    border-color: #333 !important;
}

    .table > :not(caption) > * > *,
    .admin-table th,
    .admin-table td {
        background: transparent !important;
        border-bottom-color: #333 !important;
        color: inherit !important;
    }

    .table thead th,
    .admin-table th {
        background: #202020 !important;
        color: var(--orange-soft) !important;
        font-family: var(--head);
        letter-spacing: .04em;
    }

    .table-hover > tbody > tr:hover > *,
    .admin-table tr:hover {
        background: #242424 !important;
        color: #fff !important;
    }

.table-responsive,
.table-scroll {
    border-radius: var(--radius-md);
}

/* Article cards and interactive tiles. */
.article-card,
.portal-tile,
.bulletin-card,
.mass-card {
    will-change: transform;
}

    .article-card:focus-within,
    .portal-tile:focus-visible,
    .bulletin-card:focus-visible,
    .mass-card:focus-within {
        outline: 3px solid var(--focus);
        outline-offset: 3px;
    }

    .article-card:not([style*='background-image']) {
        background-image: linear-gradient(135deg, #111, #292929);
    }

.article-hit:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: -6px;
}

/* Readings/Universalis compatibility. */
.readings-wrap a,
.fr-body a,
.article-detail a {
    color: var(--gold);
    font-weight: 700;
}

    .readings-wrap a:hover,
    .fr-body a:hover,
    .article-detail a:hover {
        color: #e2bf49;
    }

.article-detail img,
.fr-body img {
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
}

/* Booking/calendar guardrails. */
.calendar-cell,
.manager-card,
.content-card,
.auth-card {
    min-width: 0;
}

.inline-form,
.row-actions,
.portal-header,
.manager-header {
    min-width: 0;
}

    .inline-form > *,
    .row-actions > * {
        max-width: 100%;
    }

.status-select {
    min-width: 120px;
}

/* Bootstrap collapse compatibility at the project breakpoint. */
@media (max-width: 720px) {
    .navbar .container,
    .navbar .container-fluid,
    .nav-shell {
        position: relative;
        min-height: 76px;
    }

    .navbar-collapse,
    .main-nav {
        display: none;
        position: absolute;
        top: 76px;
        left: 0;
        right: 0;
        z-index: 60;
        background: #151515;
        padding: 20px 24px;
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        border-bottom: 2px solid var(--gold);
        box-shadow: 0 20px 38px rgba(0, 0, 0, .45);
    }

        .navbar-collapse.show,
        .navbar-collapse.collapsing,
        .main-nav.open,
        .main-nav.show,
        .main-nav.is-open,
        .main-nav[data-open='true'] {
            display: flex !important;
        }

        .navbar-collapse .navbar-nav,
        .main-nav {
            width: 100%;
            align-items: flex-start;
        }

            .navbar-nav .nav-link,
            .main-nav a,
            .nav-form button {
                width: 100%;
            }

    .content-card,
    .auth-card,
    .manager-card {
        padding: 22px;
    }

    .list-row,
    .schema-row,
    .inline-form {
        align-items: flex-start;
        flex-direction: column;
    }

    .inline-rule-form {
        grid-template-columns: 1fr !important;
    }

        .inline-rule-form textarea,
        .schema-row pre {
            min-width: 0;
            width: 100%;
        }
}

@media (max-width: 520px) {
    .container,
    .page-shell,
    .nav-shell {
        padding-left: 16px;
        padding-right: 16px;
    }

    .nav-shell,
    .navbar .container,
    .navbar .container-fluid {
        min-height: 68px;
    }

    .brand img,
    .navbar-brand img {
        max-height: 46px;
    }

    .navbar-collapse,
    .main-nav {
        top: 68px;
    }

    .home-hero,
    .articles-section,
    .articles-section.standalone,
    .manager-wrap,
    .auth-wrap {
        padding-top: 24px;
    }

    .content-card,
    .auth-card,
    .manager-card,
    .timetable-panel,
    .readings-wrap {
        border-radius: var(--radius-md);
        padding: 18px;
    }

    .article-card {
        min-height: 320px;
    }

    .article-content {
        padding: 20px;
    }

        .article-content h3 {
            font-size: 1.65rem;
        }

    .article-hero-card {
        width: 100%;
        height: clamp(320px, 54vh, 560px);
        border-radius: 18px;
    }

        .article-hero-card::before {
            inset: 10px;
            border-radius: 14px;
        }

    .article-hero-title {
        left: 6%;
        right: 6%;
        bottom: 32px;
    }

    .mass-card {
        align-items: flex-start;
    }

    .time-block {
        min-width: 64px;
        padding-right: 10px;
        margin-right: 10px;
    }

    .mass-time {
        font-size: 1.65rem;
    }

    .checkbox-grid {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: .001ms !important;
    }
}

/* ==========================================================================
   PARISH HOMEPAGE — dark triptych theme
   Tuned to the stained-glass triptych artwork: near-black warm ground that
   blends into the artwork's vignette, restrained gold accents so the
   stained glass — and the gold already inside it — stays the focal point.
   Variable names kept (navy-*) for backwards-compat with the rest of the file.
   ========================================================================== */

:root {
    --navy-deep: #07060a; /* near-black, faint warm undertone */
    --navy: #0c0a08;
    --navy-mid: #1a140e;
    --navy-panel: rgba(18, 14, 11, .82); /* warm-dark, slightly translucent */
    --navy-panel-2: rgba(28, 22, 17, .70);
    --navy-line: rgba(212, 175, 55, .14); /* gold trim, much subtler */
    --home-gold: #c9a868; /* slightly desaturated gold */
    --home-gold-bright: #e7c66a; /* reserved for hovers / focal accents */
}

.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

/* --- Page shell on the homepage ---------------------------------------- */
body.home-page {
    background: var(--navy-deep);
}

/* Header floats translucently over the artwork — the rays show through */
.site-header--home {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(8,5,3,.46) 0%, rgba(8,5,3,.14) 55%, transparent 100%);
    border-bottom: 0;
    box-shadow: none;
}

    .site-header--home .main-nav a,
    .site-header--home .nav-form button {
        color: #f3e4bc;
        text-shadow: 0 1px 6px rgba(0,0,0,.55);
    }

        .site-header--home .main-nav a:hover,
        .site-header--home .main-nav a.active,
        .site-header--home .nav-form button:hover {
            color: var(--home-gold);
            border-bottom-color: var(--home-gold);
        }

.site-main--home {
    min-height: auto;
}

.site-footer--home {
    background: var(--navy-deep);
    border-top: 1px solid rgba(212,175,55,.12);
    color: #8a7e6c;
}

/* --- Hero ---------------------------------------------------------------- */
.parish-home {
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg, #14100c 0%, #100c08 34%, #0a0806 64%, var(--navy-deep) 100%);
    padding-bottom: 76px;
}

.parish-home__media {
    position: relative;
    width: 100%;
    line-height: 0;
}

.parish-home__art {
    display: block;
    width: 100%;
    height: 55vh;
    min-height: 360px;
    max-height: 720px;
    object-fit: cover;
    object-position: center 35%;
}

/* Subtle bottom seam — blends the cropped image edge into the dashboard area below */
.parish-home__media::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 8%;
    background: linear-gradient(180deg, rgba(7,6,10,0) 0%, rgba(7,6,10,.4) 55%, #07060a 100%);
    pointer-events: none;
}

/* Gentle edge vignette for depth */
.parish-home__veil {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(120% 70% at 50% 22%, transparent 55%, rgba(2,1,0,.6) 100%);
    z-index: 1;
}

.parish-home__content {
    position: relative;
    z-index: 2;
    /* Dashboard sits cleanly below the artwork so the full triptych is visible */
    margin-top: 0;
}

.home-stage {
    display: flex;
    flex-direction: column;
    gap: 34px;
}

/* --- Alert banner -------------------------------------------------------- */
.home-alert-slot .alert-banner {
    background: rgba(20, 15, 11, .92);
    border: 1px solid var(--navy-line);
    border-left: 5px solid var(--red);
    border-radius: 8px;
    box-shadow: 0 22px 50px rgba(0,0,0,.5);
    backdrop-filter: blur(2px);
}

/* --- Dashboard layout ---------------------------------------------------- */
.home-dashboard {
    display: grid;
    grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr);
    gap: 28px;
    align-items: start;
}

.home-schedule-panel,
.home-stream-panel {
    background: var(--navy-panel);
    border: 1px solid var(--navy-line);
    border-radius: 12px;
    padding: 26px 28px 30px;
    box-shadow: 0 24px 60px rgba(0,0,0,.45);
    backdrop-filter: blur(3px);
}

/* --- Mass-time tabs ------------------------------------------------------ */
.home-tabs {
    border-bottom: 1px solid rgba(212,175,55,.14);
}

    .home-tabs .tab-button {
        color: #a59785;
        font-size: 1.18rem;
        letter-spacing: .04em;
    }

        .home-tabs .tab-button.active,
        .home-tabs .tab-button:hover {
            color: var(--home-gold-bright);
            border-bottom-color: var(--home-gold-bright);
        }

.home-tab-content .mass-card {
    background: var(--navy-panel-2);
    border: 1px solid rgba(212,175,55,.08);
    border-radius: 8px;
    position: relative;
}

    .home-tab-content .mass-card:hover {
        background: rgba(34, 26, 19, .82);
        border-color: rgba(212,175,55,.26);
        transform: translateY(-2px);
    }

.home-tab-content .time-block {
    border-right-color: rgba(212,175,55,.18);
}

.home-tab-content .ampm {
    color: var(--home-gold);
}

.home-tab-content .day-badge {
    background: rgba(212,175,55,.10);
    color: var(--home-gold-bright);
    border: 1px solid rgba(212,175,55,.22);
}

.home-tab-content .mass-info p {
    color: #b6a892;
}

.home-tab-content .mass-info small {
    color: var(--home-gold);
}

.home-tab-content .empty-card {
    background: var(--navy-panel-2);
    border: 1px solid rgba(212,175,55,.08);
    color: #b6a892;
}

/* Small "+" flourishes echoing the artwork — restrained so the artwork's own gold leads */
.home-card-plus,
.home-section-plus {
    color: var(--home-gold);
    font-weight: 400;
    opacity: .55;
}

.home-card-plus {
    position: absolute;
    right: 18px;
    bottom: 14px;
    left: auto;
    transform: none;
    font-size: 1rem;
    line-height: 1;
    opacity: .38;
    pointer-events: none;
}

.home-tab-content .mass-card {
    padding-bottom: 28px;
}

.home-tab-content .mass-info {
    min-width: 0;
    padding-right: 24px;
}

.home-calendar-link {
    display: block;
    text-align: center;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid rgba(212,175,55,.14);
    color: var(--home-gold);
    font-family: var(--head);
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    text-decoration: none;
}

    .home-calendar-link:hover {
        color: #fff;
    }

/* --- Live streams -------------------------------------------------------- */
.home-stream-title {
    margin: 0 0 20px;
    text-align: center;
    font-family: var(--head);
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    font-size: 1.15rem;
    color: var(--home-gold);
}

    .home-stream-title .home-section-plus {
        display: block;
        margin-top: 2px;
        font-size: 1rem;
    }

.home-stream-panel .stream-card p {
    color: #e6dccb;
    font-family: var(--serif);
}

.home-stream-panel .video-shell {
    border: 1px solid rgba(212,175,55,.14);
}

/* --- Scripture quote ----------------------------------------------------- */
.home-quote {
    margin: 6px auto 0;
    max-width: 760px;
    text-align: center;
    color: #e2d6c0;
}

    .home-quote blockquote {
        margin: 0;
        font-family: var(--serif);
        font-style: italic;
        font-size: clamp(1.1rem, 2vw, 1.5rem);
        line-height: 1.5;
        color: #f4ead4;
    }

    .home-quote figcaption {
        margin-top: 10px;
        font-family: var(--head);
        letter-spacing: .12em;
        text-transform: uppercase;
        color: var(--home-gold);
        font-size: .9rem;
    }

        .home-quote figcaption cite {
            font-style: normal;
        }

    .home-quote::after {
        content: "+";
        display: block;
        margin-top: 8px;
        color: var(--home-gold);
        opacity: .45;
    }

/* --- Articles section on the dark ground -------------------------------- */
.home-page .articles-section .section-header {
    border-bottom-color: rgba(212,175,55,.18);
}

    .home-page .articles-section .section-header h1,
    .home-page .articles-section .section-header h2 {
        color: #f3e4bc;
    }

/* --- Responsive ---------------------------------------------------------- */
@media (max-width: 960px) {
    .home-dashboard {
        grid-template-columns: 1fr;
        gap: 22px;
    }

    .parish-home__content {
        margin-top: 0;
    }
}

@media (max-width: 720px) {
    .site-header--home {
        background: linear-gradient(180deg, rgba(8,5,3,.62) 0%, rgba(8,5,3,.24) 60%, transparent 100%);
    }

    .parish-home__art {
        height: auto;
        max-height: 65vh;
        min-height: 0;
        object-fit: contain;
        object-position: center;
    }

    .home-schedule-panel,
    .home-stream-panel {
        padding: 20px 18px 24px;
    }
}

/* ==========================================================================
   HOMEPAGE HERO IMAGE — full width, maximum 40% viewport height
   Uses the wide 2560x576 hero asset so the image scales naturally across the
   whole screen without becoming a giant full-screen hero.
   ========================================================================== */

body.home-page .parish-home {
    overflow: hidden;
    padding-bottom: 76px;
    background: linear-gradient(180deg, #100c08 0%, #080706 44%, var(--navy-deep) 100%);
}

body.home-page .parish-home__media {
    position: relative;
    width: 100%;
    height: min(40svh, calc(100vw * 0.225));
    min-height: 280px;
    max-height: 40svh;
    overflow: hidden;
    line-height: 0;
    background: #07060a;
}

body.home-page .parish-home__art {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    max-height: none;
    object-fit: cover;
    object-position: center center;
}

body.home-page .parish-home__media::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 26%;
    background: linear-gradient(180deg, rgba(7,6,10,0) 0%, rgba(7,6,10,.55) 66%, #07060a 100%);
    pointer-events: none;
}

body.home-page .parish-home__veil {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(85% 72% at 50% 18%, transparent 52%, rgba(2,1,0,.5) 100%), linear-gradient(180deg, rgba(0,0,0,.08) 0%, rgba(0,0,0,0) 38%, rgba(0,0,0,.18) 100%);
    z-index: 1;
}

body.home-page .parish-home__content {
    position: relative;
    z-index: 2;
    margin-top: 0;
    padding-top: clamp(24px, 4vh, 46px);
}

@media (max-width: 720px) {
    body.home-page .parish-home__media {
        height: min(40svh, 46vw);
        min-height: 190px;
    }

    body.home-page .parish-home__art {
        object-fit: cover;
        object-position: center center;
    }
}

.article-body img,
.article-detail img,
.article-card img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.article-featured-image img,
.article-card-image img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
}

.nav-dropdown-button {
    background: none;
    border: 0;
    cursor: pointer;
    font: inherit;
    color: inherit;
}

.main-nav .nav-dropdown-button {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.main-nav .nav-dropdown-button {
    color: #fff1cf !important;
    text-decoration: none;
    background: transparent !important;
    border: 0;
    border-bottom: 1px solid transparent;
    padding: 8px 0;
    cursor: pointer;
    font-family: var(--serif);
    font-weight: 700;
}

    .main-nav .nav-dropdown-button:hover,
    .main-nav .nav-dropdown-button:focus,
    .main-nav .nav-dropdown-button.active,
    .main-nav .nav-dropdown.active > .nav-dropdown-button {
        color: var(--gold) !important;
        border-bottom-color: var(--gold);
    }

body.home-page .main-nav .nav-dropdown-button {
    color: #f3e4bc !important;
    text-shadow: 0 1px 8px rgba(0, 0, 0, .65);
}

    body.home-page .main-nav .nav-dropdown-button:hover,
    body.home-page .main-nav .nav-dropdown-button:focus,
    body.home-page .main-nav .nav-dropdown-button.active,
    body.home-page .main-nav .nav-dropdown.active > .nav-dropdown-button {
        color: #e7c66a !important;
        border-bottom-color: #e7c66a;
    }

.parish-footer {
    margin-top: 0;
    padding: 0;
    background: radial-gradient(circle at center top, rgba(212, 175, 55, 0.08), transparent 42%), linear-gradient(180deg, #171717 0%, #0f0f0f 100%);
    border-top: 1px solid rgba(212, 175, 55, 0.18);
    color: #d8d0bf;
}

.parish-footer__inner {
    max-width: 1120px;
    margin: 0 auto;
    padding: 4.5rem 1.5rem 3.5rem;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1.25fr;
    gap: 4rem;
    align-items: start;
}

.parish-footer__brand img {
    width: 220px;
    max-width: 100%;
    height: auto;
    margin-bottom: 1.5rem;
}

.parish-footer__brand p {
    max-width: 280px;
    color: #aaa08e;
    font-family: var(--serif);
    font-size: 1.1rem;
    line-height: 1.6;
}

.parish-footer h2 {
    margin: 0 0 1.4rem;
    color: #fff1cf;
    font-family: var(--head);
    font-size: 1.55rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.parish-footer__links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

    .parish-footer__links a,
    .parish-footer__contact a {
        color: #d8d0bf;
        text-decoration: none;
        font-family: var(--serif);
        font-size: 1.1rem;
        font-weight: 700;
        line-height: 1.9;
        transition: color 0.2s ease;
    }

        .parish-footer__links a:hover,
        .parish-footer__contact a:hover {
            color: var(--gold);
        }

.parish-footer__contact p {
    margin: 0 0 1.4rem;
    color: #d8d0bf;
    font-family: var(--serif);
    font-size: 1.1rem;
    line-height: 1.8;
}

.parish-footer__contact strong {
    color: #fff1cf;
}

.parish-footer__bottom {
    border-top: 1px solid rgba(212, 175, 55, 0.12);
    padding: 1.2rem 1.5rem;
    text-align: center;
    color: #8f8470;
    font-size: 0.9rem;
}

@media (max-width: 800px) {
    .parish-footer__inner {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }

    .parish-footer__brand p {
        margin-left: auto;
        margin-right: auto;
    }

    .parish-footer__links {
        align-items: center;
    }
}

.home-bulletins {
    padding-top: 70px;
}

.home-bulletin-carousel {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.5rem;
}

.home-bulletin-card {
    min-height: 190px;
    padding: 2rem;
    background: rgba(18, 14, 11, .82);
    border: 1px solid rgba(212, 175, 55, .18);
    border-radius: 14px;
    text-decoration: none;
    color: #f3e4bc;
    box-shadow: 0 18px 45px rgba(0,0,0,.35);
    transition: transform .25s ease, border-color .25s ease, background .25s ease;
}

    .home-bulletin-card:hover {
        transform: translateY(-5px);
        border-color: var(--home-gold-bright);
        background: rgba(28, 22, 17, .9);
    }

.home-bulletin-icon {
    display: block;
    margin-bottom: 1.5rem;
    color: var(--home-gold-bright);
    font-size: 2rem;
}

.home-bulletin-title {
    display: block;
    margin-bottom: .75rem;
    font-family: var(--head);
    font-size: 1.25rem;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.home-bulletin-date {
    color: #b6a892;
    font-family: var(--serif);
    font-size: 1rem;
}

body.home-page .home-bulletins,
body.home-page .articles-section {
    max-width: 1200px;
}

body.home-page .home-bulletins {
    padding-top: clamp(5rem, 8vw, 7rem);
}

body.home-page .articles-section {
    padding-top: clamp(3.5rem, 6vw, 5rem);
}

body.home-page .home-bulletins .section-header,
body.home-page .articles-section .section-header {
    position: relative;
    border-bottom: 0;
    padding-bottom: 2.2rem;
    margin-bottom: 2rem;
}

body.home-page .home-bulletins .section-header::before,
body.home-page .articles-section .section-header::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0.7rem;
    height: 1px;
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.95), rgba(212, 175, 55, 0.55) 44%, transparent 44%, transparent 56%, rgba(212, 175, 55, 0.55) 56%, rgba(212, 175, 55, 0.95));
}

body.home-page .home-bulletins .section-header::after,
body.home-page .articles-section .section-header::after {
    content: "✣";
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    color: var(--gold);
    font-family: var(--serif);
    font-size: 1.35rem;
    line-height: 1;
    text-shadow: 0 0 18px rgba(212, 175, 55, 0.35);
}

body.home-page .home-bulletins .section-header h2,
body.home-page .articles-section .section-header h2 {
    color: #fff7dc;
    font-size: clamp(2.35rem, 5vw, 3.2rem);
    font-weight: 900;
    line-height: 0.95;
    letter-spacing: 0;
}

body.home-page .home-bulletins .section-header p,
body.home-page .articles-section .section-header p {
    margin-top: 0.85rem;
    color: rgba(255, 247, 220, 0.88);
    font-family: var(--serif);
    font-size: clamp(1rem, 1.7vw, 1.25rem);
}

body.home-page .home-empty-bulletins {
    display: flex;
    align-items: center;
    gap: 2rem;
    min-height: 126px;
    padding: 1.55rem 1.85rem;
    border: 1px solid rgba(255, 247, 220, 0.16);
    border-radius: 6px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)), rgba(18, 18, 18, 0.86);
    color: #fff7dc;
    font-family: var(--serif);
    font-size: clamp(1.1rem, 2vw, 1.45rem);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 24px 80px rgba(0, 0, 0, 0.18);
}

body.home-page .home-empty-bulletins__icon {
    width: 82px;
    height: 82px;
    flex: 0 0 auto;
    border: 2px solid var(--gold);
    border-radius: 50%;
    color: var(--gold);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

body.home-page .home-empty-bulletins__icon i {
    display: none;
}

body.home-page .home-empty-bulletins__icon::before {
    content: "✉";
    font-family: var(--body);
    font-size: 2.1rem;
    font-weight: 400;
    line-height: 1;
}

body.home-page .articles-section .article-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.75rem;
}

body.home-page .articles-section .article-card {
    min-height: clamp(360px, 31vw, 430px);
    border: 1px solid rgba(212, 175, 55, 0.64);
    border-radius: 6px;
    background-position: center;
    background-size: cover;
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.34);
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

body.home-page .articles-section .article-card:hover,
body.home-page .articles-section .article-card:focus-within {
    transform: translateY(-4px);
    border-color: rgba(226, 190, 86, 0.95);
    box-shadow: 0 36px 100px rgba(0, 0, 0, 0.42);
}

body.home-page .articles-section .article-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.86), rgba(0, 0, 0, 0.56) 48%, rgba(0, 0, 0, 0.14)), linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.10) 58%);
}

body.home-page .articles-section .article-card::after {
    background: radial-gradient(circle at 80% 18%, rgba(226, 190, 86, 0.22), transparent 34%);
    opacity: 0.55;
    z-index: 1;
}

body.home-page .articles-section .article-content {
    top: 0;
    bottom: 0;
    right: auto;
    width: min(76%, 450px);
    padding: clamp(2rem, 3.5vw, 2.7rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-shadow: 0 3px 20px rgba(0, 0, 0, 0.65);
}

body.home-page .articles-section .article-cat {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    color: #e2be56;
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.12em;
}

body.home-page .articles-section .article-cat::before {
    content: "+";
    width: 2rem;
    height: 2rem;
    border: 1px solid var(--gold);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--gold);
    font-size: 1.15rem;
    line-height: 1;
}

body.home-page .articles-section .article-content h3 {
    margin: 1.25rem 0 1rem;
    color: #fff7dc;
    font-size: clamp(2rem, 3.65vw, 2.9rem);
    font-weight: 900;
    line-height: 0.98;
    letter-spacing: 0;
}

body.home-page .articles-section .article-content h3 .first-word,
body.home-page .articles-section .article-content h3 .rest-words {
    color: inherit;
}

body.home-page .articles-section .article-content h3::after {
    content: "";
    display: block;
    width: 2.4rem;
    height: 3px;
    margin-top: 1rem;
    background: var(--gold);
}

body.home-page .articles-section .article-content p {
    color: rgba(255, 247, 220, 0.88);
    font-family: var(--serif);
    font-size: clamp(1rem, 1.55vw, 1.14rem);
    line-height: 1.38;
    max-width: 23rem;
}

body.home-page .articles-section .article-read-more {
    margin-top: 1.65rem;
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    color: #e2be56;
    font-family: var(--head);
    font-size: 1.05rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

body.home-page .articles-section .article-read-more i {
    font-size: 1.1rem;
}

body.home-page .articles-section .article-card:nth-child(2n) .article-content {
    width: min(68%, 405px);
}

@media (max-width: 960px) {
    .home-bulletin-carousel {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.home-page .articles-section .article-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .home-bulletin-carousel {
        grid-template-columns: 1fr;
    }

    body.home-page .home-empty-bulletins {
        align-items: flex-start;
        gap: 1rem;
        font-size: 1rem;
    }

    body.home-page .home-empty-bulletins__icon {
        width: 58px;
        height: 58px;
        font-size: 1.35rem;
    }

    body.home-page .articles-section .article-content {
        width: 100%;
    }
}

@media (max-width: 1100px) {
    .mobile-nav-toggle {
        display: inline-flex;
    }

    .main-nav {
        display: none;
        position: absolute;
        top: 76px;
        left: 0;
        right: 0;
        z-index: 200;
        background: #151515;
        padding: 20px 24px;
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        border-bottom: 2px solid var(--gold);
        box-shadow: 0 20px 38px rgba(0, 0, 0, .45);
    }

        .main-nav.open {
            display: flex !important;
        }

        .main-nav a,
        .main-nav .nav-dropdown-button,
        .nav-form button {
            width: 100%;
            text-align: left;
        }

        .main-nav .nav-dropdown {
            width: 100%;
            display: flex;
            flex-direction: column;
            align-items: stretch;
        }

        .main-nav .nav-dropdown-toggle {
            width: 100%;
            justify-content: space-between;
        }

        .main-nav .nav-dropdown-menu {
            position: static;
            width: 100%;
            min-width: 0;
            margin-top: .35rem;
            padding: .35rem 0 .35rem 1rem;
            opacity: 1;
            visibility: visible;
            pointer-events: auto;
            transform: none;
            background: transparent;
            border: 0;
            box-shadow: none;
        }
}

/* ==========================================================================
   HOMEPAGE HERO — sacrament-style background image system
   Single image source: wwwroot/img/home-image.webp
   ========================================================================== */

body.home-page {
    background-color: var(--navy-deep);
}

    body.home-page .site-main,
    body.home-page .site-main--home {
        padding: 0;
        background-color: var(--navy-deep);
        min-height: auto;
    }

/* Keep the homepage nav transparent, but make it less heavy over the image */
.site-header--home {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient( 180deg, rgba(8, 5, 3, 0.42) 0%, rgba(8, 5, 3, 0.18) 55%, rgba(8, 5, 3, 0) 100% );
    border-bottom: 0;
    box-shadow: none;
}

    .site-header--home .main-nav a,
    .site-header--home .nav-form button,
    body.home-page .main-nav .nav-dropdown-button {
        color: #f3e4bc !important;
        text-shadow: 0 2px 8px rgba(0, 0, 0, .75);
    }

        .site-header--home .main-nav a:hover,
        .site-header--home .main-nav a.active,
        .site-header--home .nav-form button:hover,
        body.home-page .main-nav .nav-dropdown-button:hover,
        body.home-page .main-nav .nav-dropdown-button:focus,
        body.home-page .main-nav .nav-dropdown-button.active,
        body.home-page .main-nav .nav-dropdown.active > .nav-dropdown-button {
            color: #e7c66a !important;
            border-bottom-color: #e7c66a;
        }

/* Hero image section */
.homepage-hero {
    position: relative;
    width: 100%;
    height: 58vh;
    min-height: 520px;
    max-height: 760px;
    padding-top: 96px;
    background-image: url('/img/home-image.webp');
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    background-color: var(--navy-deep);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.homepage-hero--main {
    background-image: url('/img/home-image.webp');
}

/* Softer overlay so the top of the image is not buried */
.homepage-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient( 100% 78% at 50% 30%, rgba(0, 0, 0, 0) 54%, rgba(0, 0, 0, 0.38) 100% ), linear-gradient( to bottom, rgba(7, 6, 10, 0.02) 0%, rgba(7, 6, 10, 0.04) 48%, var(--navy-deep) 100% );
    pointer-events: none;
}

.homepage-hero__content {
    position: relative;
    z-index: 2;
}

/* Main homepage content beneath the hero */
body.home-page .parish-home {
    position: relative;
    overflow: visible;
    padding: 0 0 76px;
    background: radial-gradient(circle at center top, rgba(212, 175, 55, 0.08), transparent 36%), linear-gradient(180deg, var(--navy-deep) 0%, #080706 55%, var(--navy-deep) 100%);
}

/* The homepage now uses .homepage-hero as the image section. */
body.home-page .parish-home__media,
body.home-page .parish-home__art,
body.home-page .parish-home__veil {
    display: none !important;
}

body.home-page .parish-home__content {
    position: relative;
    z-index: 2;
    margin-top: 0;
    padding-top: clamp(28px, 4vh, 52px);
}

body.home-page .home-stage {
    margin-top: -42px;
}

body.home-page .home-dashboard {
    position: relative;
    z-index: 3;
}

body.home-page .home-schedule-panel,
body.home-page .home-stream-panel {
    background: var(--navy-panel);
    border: 1px solid var(--navy-line);
    border-radius: 12px;
    padding: 26px 28px 30px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .45);
    backdrop-filter: blur(3px);
}

@media (max-width: 1000px) {
    .homepage-hero {
        height: 52vh;
        min-height: 460px;
        max-height: 640px;
        padding-top: 90px;
        background-size: cover;
        background-position: center top;
    }

    body.home-page .home-stage {
        margin-top: -28px;
    }
}

/* Homepage lower-section polish: final overrides for the live site. */
body.home-page .home-bulletins > .empty-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    min-height: 126px;
    padding: 1.55rem 1.85rem;
    border: 1px solid rgba(255, 247, 220, 0.16);
    border-radius: 6px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)), rgba(18, 18, 18, 0.86);
    color: #fff7dc;
    font-family: var(--serif);
    font-size: clamp(1.1rem, 2vw, 1.45rem);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 24px 80px rgba(0, 0, 0, 0.18);
}

body.home-page .home-bulletins > .empty-card:not(.home-empty-bulletins)::before {
    content: "\2709";
    width: 82px;
    height: 82px;
    flex: 0 0 auto;
    border: 2px solid var(--gold);
    border-radius: 50%;
    color: var(--gold);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--body);
    font-size: 2.1rem;
    font-weight: 400;
    line-height: 1;
}

body.home-page .articles-section .article-card {
    isolation: isolate;
}

body.home-page .articles-section .article-content {
    z-index: 2;
}

@media (max-width: 560px) {
    body.home-page .home-bulletins > .empty-card {
        align-items: flex-start;
        gap: 1rem;
        font-size: 1rem;
    }

    body.home-page .home-bulletins > .empty-card::before {
        width: 58px;
        height: 58px;
        font-size: 1.35rem;
    }
}

@media (max-width: 700px) {
    .homepage-hero {
        height: 380px;
        min-height: 380px;
        max-height: none;
        padding-top: 80px;
        background-size: cover;
        background-position: center top;
    }

    body.home-page .parish-home__content {
        padding-top: 28px;
    }

    body.home-page .home-stage {
        margin-top: -20px;
    }

    body.home-page .home-schedule-panel,
    body.home-page .home-stream-panel {
        padding: 20px 18px 24px;
    }
}

/* ==========================================================================
   HOMEPAGE HERO FINAL OVERRIDES
   Added without removing the original parish theme code.
   Purpose:
   - keep the transparent menu-safe dark space at the top
   - show more of the stained-glass triptych before the dashboard begins
   - reduce the bottom fade so the central image remains the focus
   - stop the lower figures being swallowed by the cards
   ========================================================================== */

body.home-page .homepage-hero {
    height: clamp(640px, 76svh, 860px);
    min-height: 640px;
    max-height: 860px;
    padding-top: 96px;
    background-image: url('/img/home-image.webp');
    background-size: cover;
    background-position: center 38%;
    background-repeat: no-repeat;
    background-color: var(--navy-deep);
}

    /* Keep the navbar area readable, but do not darken the stained glass too much. */
    body.home-page .homepage-hero::after {
        content: "";
        position: absolute;
        inset: 0;
        pointer-events: none;
        background: linear-gradient( to bottom, rgba(7, 6, 10, 0.64) 0%, rgba(7, 6, 10, 0.34) 13%, rgba(7, 6, 10, 0.08) 31%, rgba(7, 6, 10, 0.04) 54%, rgba(7, 6, 10, 0.24) 78%, var(--navy-deep) 100% ), radial-gradient( 110% 80% at 50% 42%, rgba(212, 175, 55, 0.10) 0%, rgba(7, 6, 10, 0.00) 45%, rgba(2, 1, 0, 0.50) 100% );
    }

/* Give the artwork breathing room. The dashboard should begin after the
   triptych has had enough vertical space, rather than covering its lower half. */
body.home-page .parish-home__content {
    padding-top: clamp(34px, 5vh, 62px);
}

body.home-page .home-stage {
    margin-top: -30px;
}

/* Slightly darken the dashboard panels themselves instead of relying on a heavy
   image fade. This makes the cards readable while leaving the stained glass clear. */
body.home-page .home-schedule-panel,
body.home-page .home-stream-panel {
    background: rgba(15, 11, 8, 0.90);
    border-color: rgba(212, 175, 55, 0.20);
    box-shadow: 0 24px 65px rgba(0, 0, 0, 0.56);
}

/* Medium desktop and tablets */
@media (max-width: 1200px) {
    body.home-page .homepage-hero {
        height: clamp(590px, 72svh, 780px);
        min-height: 590px;
        background-position: center 39%;
    }

    body.home-page .home-stage {
        margin-top: -24px;
    }
}

@media (max-width: 1000px) {
    body.home-page .homepage-hero {
        height: clamp(540px, 68svh, 700px);
        min-height: 540px;
        max-height: 700px;
        padding-top: 90px;
        background-position: center 40%;
    }

    body.home-page .home-stage {
        margin-top: -18px;
    }
}

/* Mobile: keep the image usable rather than forcing a desktop crop. */
@media (max-width: 700px) {
    body.home-page .homepage-hero {
        height: clamp(390px, 58svh, 560px);
        min-height: 390px;
        max-height: 560px;
        padding-top: 80px;
        background-size: cover;
        background-position: center 39%;
    }

        body.home-page .homepage-hero::after {
            background: linear-gradient( to bottom, rgba(7, 6, 10, 0.58) 0%, rgba(7, 6, 10, 0.24) 22%, rgba(7, 6, 10, 0.08) 50%, rgba(7, 6, 10, 0.70) 100% );
        }

    body.home-page .parish-home__content {
        padding-top: 28px;
    }

    body.home-page .home-stage {
        margin-top: -12px;
    }
}

@media (max-width: 480px) {
    body.home-page .homepage-hero {
        height: clamp(340px, 52svh, 480px);
        min-height: 340px;
        background-position: center 38%;
    }
}
/* ==========================================================================
   HOMEPAGE HERO FULL-BLEED FIX
   Forces the hero image to escape any parent .container / .page-shell width
   and span the full browser width.
   ========================================================================== */

body.home-page .homepage-hero,
body.home-page .homepage-hero--main {
    width: 100vw;
    max-width: none;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
}

/* Keep the image full width and visually close to your current positioning */
@media (min-width: 1001px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(680px, 78svh, 900px);
        min-height: 680px;
        max-height: 900px;
        background-size: cover;
        background-position: center 24%;
    }
}

/* ==========================================================================
   HOMEPAGE HERO DESKTOP CALIBRATION FOR /img/home-image.webp
   Image: 1672 × 941 (aspect ratio 56.28%).
   This final block intentionally overrides earlier homepage-hero experiments.
   ========================================================================== */

body.home-page {
    background: #07060a;
}

    body.home-page .site-main,
    body.home-page .site-main--home {
        padding: 0 !important;
        margin-top: 0 !important;
        background: #07060a;
        min-height: auto;
        overflow-x: clip;
    }

    /* Transparent desktop header over the dark top of the artwork. */
    body.home-page .site-header,
    body.home-page .site-header--home {
        position: absolute !important;
        top: 0;
        left: 0;
        right: 0;
        z-index: 100;
        height: 84px;
        background: linear-gradient( 180deg, rgba(3, 2, 2, 0.78) 0%, rgba(3, 2, 2, 0.48) 48%, rgba(3, 2, 2, 0.00) 100% ) !important;
        border-bottom: 0 !important;
        box-shadow: none !important;
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
    }

    body.home-page .nav-shell {
        width: min(1480px, calc(100vw - 112px));
        max-width: none;
        height: 84px;
        min-height: 84px;
        margin-inline: auto;
        padding: 0;
        background: transparent !important;
    }

    body.home-page .brand img,
    body.home-page .navbar-brand img {
        height: 55px;
        max-height: 55px;
        width: auto;
    }

    body.home-page .main-nav {
        gap: clamp(20px, 1.65vw, 34px);
        font-size: clamp(0.96rem, 0.95vw, 1.08rem);
    }

        body.home-page .main-nav a,
        body.home-page .main-nav .nav-dropdown-button,
        body.home-page .nav-form button {
            color: #f3e4bc !important;
            text-shadow: 0 2px 10px rgba(0, 0, 0, 0.82);
        }

            body.home-page .main-nav a:hover,
            body.home-page .main-nav a:focus,
            body.home-page .main-nav a.active,
            body.home-page .main-nav .nav-dropdown-button:hover,
            body.home-page .main-nav .nav-dropdown-button:focus,
            body.home-page .main-nav .nav-dropdown-button.active,
            body.home-page .main-nav .nav-dropdown.active > .nav-dropdown-button,
            body.home-page .nav-form button:hover,
            body.home-page .nav-form button:focus {
                color: #e7c66a !important;
                border-bottom-color: #e7c66a !important;
            }

    /* Full-bleed hero. The image is 1672 × 941, so 941 / 1672 = 56.28vw.
   This preserves the generated composition instead of zooming into the centre. */
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        position: relative;
        width: 100vw;
        max-width: none;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        height: clamp(760px, 56.28vw, 1060px);
        min-height: 760px;
        max-height: 1060px;
        padding: 0;
        background-image: url('/img/home-image.webp');
        background-size: 100% auto;
        background-position: center top;
        background-repeat: no-repeat;
        background-color: #07060a;
        overflow: hidden;
        display: block;
        text-align: initial;
    }

        /* The overlay only protects the real menu and creates a gentle handoff to the
   panels below. It must not bury the figures in the triptych. */
        body.home-page .homepage-hero::after,
        body.home-page .homepage-hero--main::after {
            content: "";
            position: absolute;
            inset: 0;
            pointer-events: none;
            background: linear-gradient( to bottom, rgba(3, 2, 2, 0.66) 0%, rgba(3, 2, 2, 0.36) 7%, rgba(3, 2, 2, 0.08) 17%, rgba(3, 2, 2, 0.00) 40%, rgba(3, 2, 2, 0.00) 78%, rgba(7, 6, 10, 0.50) 92%, #07060a 100% ), radial-gradient( 120% 88% at 50% 39%, rgba(212, 175, 55, 0.04) 0%, rgba(0, 0, 0, 0.00) 52%, rgba(0, 0, 0, 0.28) 100% );
        }

    body.home-page .homepage-hero__content {
        position: relative;
        z-index: 2;
    }

    /* Keep the dashboard below the artwork. A small upward tuck is enough; a large
   negative margin is what made the image look cropped and swallowed. */
    body.home-page .parish-home {
        position: relative;
        overflow: visible;
        padding: 0 0 76px;
        background: linear-gradient(180deg, #07060a 0%, #080706 55%, #07060a 100%);
    }

    body.home-page .parish-home__media,
    body.home-page .parish-home__art,
    body.home-page .parish-home__veil {
        display: none !important;
    }

    body.home-page .parish-home__content {
        position: relative;
        z-index: 3;
        padding-top: clamp(24px, 3.5vh, 44px);
        margin-top: 0;
    }

    body.home-page .home-stage {
        margin-top: clamp(-54px, -3vw, -28px);
    }

    body.home-page .home-dashboard {
        position: relative;
        z-index: 4;
    }

    body.home-page .home-schedule-panel,
    body.home-page .home-stream-panel {
        background: rgba(15, 11, 8, 0.92);
        border-color: rgba(212, 175, 55, 0.22);
        box-shadow: 0 24px 65px rgba(0, 0, 0, 0.58);
        -webkit-backdrop-filter: blur(3px);
        backdrop-filter: blur(3px);
    }

/* Smaller desktop / laptop: keep the triptych visible and avoid an excessive
   first-screen hero height. */
@media (max-width: 1400px) and (min-width: 1001px) {
    body.home-page .nav-shell {
        width: min(1180px, calc(100vw - 56px));
    }

    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(650px, 56.28vw, 790px);
        min-height: 650px;
        max-height: 790px;
    }

    body.home-page .home-stage {
        margin-top: -30px;
    }
}

/* Tablet and mobile keep the earlier cover-based behaviour because the desktop
   full-ratio treatment would become too tall on narrow screens. */
@media (max-width: 1000px) {
    body.home-page .site-header,
    body.home-page .site-header--home {
        position: sticky !important;
        height: auto;
        background: linear-gradient(180deg, #111, rgba(17, 17, 17, .94)) !important;
        border-bottom: 1px solid rgba(255,255,255,.04) !important;
        box-shadow: 0 12px 30px rgba(0,0,0,.35) !important;
    }

    body.home-page .nav-shell {
        width: min(100%, 1120px);
        height: 76px;
        min-height: 76px;
        padding: 0 24px;
    }

    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
        height: clamp(500px, 64svh, 700px);
        min-height: 500px;
        max-height: 700px;
        background-size: cover;
        background-position: center 37%;
    }

    body.home-page .home-stage {
        margin-top: -18px;
    }
}

@media (max-width: 700px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(360px, 56svh, 540px);
        min-height: 360px;
        max-height: 540px;
        background-position: center 38%;
    }

        body.home-page .homepage-hero::after,
        body.home-page .homepage-hero--main::after {
            background: linear-gradient( to bottom, rgba(7, 6, 10, 0.50) 0%, rgba(7, 6, 10, 0.18) 32%, rgba(7, 6, 10, 0.10) 55%, rgba(7, 6, 10, 0.74) 100% );
        }

    body.home-page .parish-home__content {
        padding-top: 28px;
    }

    body.home-page .home-stage {
        margin-top: -12px;
    }
}
/* ==========================================================================
   HOMEPAGE HERO DESKTOP HEIGHT REFINEMENT
   Uses the full-width image, but treats it as a true hero rather than a
   full-page image showcase.
   ========================================================================== */

@media (min-width: 1001px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        width: 100vw;
        max-width: none;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        /* Reduced from the near-full image ratio */
        height: clamp(560px, 58svh, 680px);
        min-height: 560px;
        max-height: 680px;
        background-image: url('/img/home-image.webp');
        background-size: 100% auto;
        background-position: center top;
        background-repeat: no-repeat;
        background-color: var(--navy-deep);
    }

        body.home-page .homepage-hero::after {
            background: linear-gradient( to bottom, rgba(7, 6, 10, 0.70) 0%, rgba(7, 6, 10, 0.38) 14%, rgba(7, 6, 10, 0.08) 34%, rgba(7, 6, 10, 0.08) 56%, rgba(7, 6, 10, 0.52) 88%, var(--navy-deep) 100% ), radial-gradient( 110% 75% at 50% 38%, rgba(212, 175, 55, 0.08) 0%, rgba(7, 6, 10, 0.00) 48%, rgba(2, 1, 0, 0.48) 100% );
        }

    body.home-page .home-stage {
        margin-top: -72px;
    }
}

/* ============================================================================
   HOMEPAGE HERO AUTHORITATIVE FIX — SUBJECT-SAFE ART DIRECTION
   Image: /img/home-image.webp, generated at 1672 × 941.

   The stained-glass triptych is subject-critical content, not a decorative
   texture. A short desktop hero cannot show the whole 16:9 image at full width
   without cropping. This block uses two layers:
   1. a dark full-bleed cover layer for atmosphere across the whole viewport;
   2. a contained foreground layer so the primary triptych remains visible.
   ============================================================================ */

@media (min-width: 1001px) {
    body.home-page {
        background: #07060a !important;
        overflow-x: clip;
    }

        body.home-page .site-main,
        body.home-page .site-main--home {
            padding: 0 !important;
            margin: 0 !important;
            background: #07060a !important;
            overflow-x: clip;
        }

        body.home-page .site-header,
        body.home-page .site-header--home {
            position: absolute !important;
            top: 0;
            left: 0;
            right: 0;
            z-index: 100;
            height: 84px;
            background: linear-gradient( 180deg, rgba(3, 2, 2, 0.76) 0%, rgba(3, 2, 2, 0.42) 56%, rgba(3, 2, 2, 0.00) 100% ) !important;
            border-bottom: 0 !important;
            box-shadow: none !important;
        }

        body.home-page .nav-shell {
            width: min(1480px, calc(100vw - 112px));
            max-width: none;
            height: 84px;
            min-height: 84px;
            margin-inline: auto;
            padding: 0;
            background: transparent !important;
        }

        body.home-page .brand img,
        body.home-page .navbar-brand img {
            height: 55px;
            max-height: 55px;
            width: auto;
        }

        body.home-page .main-nav {
            gap: clamp(20px, 1.65vw, 34px);
            font-size: clamp(0.96rem, 0.95vw, 1.08rem);
        }

            body.home-page .main-nav a,
            body.home-page .main-nav .nav-dropdown-button,
            body.home-page .nav-form button {
                color: #f3e4bc !important;
                text-shadow: 0 2px 10px rgba(0, 0, 0, 0.86);
            }

                body.home-page .main-nav a:hover,
                body.home-page .main-nav a:focus,
                body.home-page .main-nav a.active,
                body.home-page .main-nav .nav-dropdown-button:hover,
                body.home-page .main-nav .nav-dropdown-button:focus,
                body.home-page .main-nav .nav-dropdown-button.active,
                body.home-page .main-nav .nav-dropdown.active > .nav-dropdown-button,
                body.home-page .nav-form button:hover,
                body.home-page .nav-form button:focus {
                    color: #e7c66a !important;
                    border-bottom-color: #e7c66a !important;
                }

        body.home-page .homepage-hero,
        body.home-page .homepage-hero--main {
            position: relative !important;
            width: 100vw !important;
            max-width: none !important;
            margin-left: calc(50% - 50vw) !important;
            margin-right: calc(50% - 50vw) !important;
            height: clamp(540px, 60svh, 690px) !important;
            min-height: 540px !important;
            max-height: 690px !important;
            padding: 0 !important;
            overflow: hidden !important;
            isolation: isolate;
            display: block !important;
            text-align: initial !important;
            background: linear-gradient(rgba(3, 2, 2, 0.64), rgba(3, 2, 2, 0.66)), url('/img/home-image.webp') center center / cover no-repeat #07060a !important;
        }

            /* Foreground subject layer. This is the important layer: it preserves the
       image's proportions and keeps the primary stained-glass subject visible. */
            body.home-page .homepage-hero::before,
            body.home-page .homepage-hero--main::before {
                content: "";
                position: absolute;
                inset: 0;
                z-index: 0;
                pointer-events: none;
                background-image: url('/img/home-image.webp');
                background-repeat: no-repeat;
                background-position: center top;
                background-size: auto 100%;
                filter: drop-shadow(0 20px 46px rgba(0, 0, 0, 0.45));
            }

            /* Gentle top/bottom control only. This must not be used to hide the image. */
            body.home-page .homepage-hero::after,
            body.home-page .homepage-hero--main::after {
                content: "";
                position: absolute;
                inset: 0;
                z-index: 1;
                pointer-events: none;
                background: linear-gradient( to bottom, rgba(3, 2, 2, 0.48) 0%, rgba(3, 2, 2, 0.18) 14%, rgba(3, 2, 2, 0.00) 34%, rgba(3, 2, 2, 0.00) 72%, rgba(7, 6, 10, 0.38) 92%, #07060a 100% ), radial-gradient( 115% 90% at 50% 42%, rgba(212, 175, 55, 0.04) 0%, rgba(0, 0, 0, 0.00) 50%, rgba(0, 0, 0, 0.25) 100% );
            }

        body.home-page .homepage-hero__content {
            position: relative;
            z-index: 2;
        }

        body.home-page .parish-home {
            position: relative;
            overflow: visible;
            padding: 0 0 76px;
            background: linear-gradient(180deg, #07060a 0%, #080706 55%, #07060a 100%) !important;
        }

        body.home-page .parish-home__media,
        body.home-page .parish-home__art,
        body.home-page .parish-home__veil {
            display: none !important;
        }

        body.home-page .parish-home__content {
            position: relative;
            z-index: 3;
            padding-top: clamp(30px, 4vh, 48px) !important;
            margin-top: 0 !important;
        }

        body.home-page .home-stage {
            margin-top: 0 !important;
        }

        body.home-page .home-dashboard {
            position: relative;
            z-index: 4;
        }

        body.home-page .home-schedule-panel,
        body.home-page .home-stream-panel {
            background: rgba(15, 11, 8, 0.92) !important;
            border-color: rgba(212, 175, 55, 0.22) !important;
            box-shadow: 0 24px 65px rgba(0, 0, 0, 0.58) !important;
            -webkit-backdrop-filter: blur(3px);
            backdrop-filter: blur(3px);
        }
}

@media (max-width: 1400px) and (min-width: 1001px) {
    body.home-page .nav-shell {
        width: min(1180px, calc(100vw - 56px));
    }

    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(500px, 58svh, 620px) !important;
        min-height: 500px !important;
        max-height: 620px !important;
    }
}

@media (max-width: 1000px) {
    body.home-page .site-header,
    body.home-page .site-header--home {
        position: sticky !important;
        height: auto;
        background: linear-gradient(180deg, #111, rgba(17, 17, 17, .94)) !important;
        border-bottom: 1px solid rgba(255,255,255,.04) !important;
        box-shadow: 0 12px 30px rgba(0,0,0,.35) !important;
    }

    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        height: clamp(460px, 62svh, 660px) !important;
        min-height: 460px !important;
        max-height: 660px !important;
        background-size: cover !important;
        background-position: center 37% !important;
    }
}


/* ==========================================================================
   HOMEPAGE ALERTS AND EVENTS SIGNUP
   Sits beneath the Mass Times / Live Streams dashboard.
   ========================================================================== */

.home-alerts-signup {
    margin-top: 0;
}

.home-alerts-signup__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 26px 28px;
    background: rgba(15, 11, 8, 0.92);
    border: 1px solid rgba(212, 175, 55, 0.22);
    border-radius: 12px;
    box-shadow: 0 24px 65px rgba(0, 0, 0, 0.46);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}

.home-alerts-signup__text {
    min-width: 0;
}

.home-alerts-signup__kicker {
    margin: 0 0 0.45rem;
    color: var(--home-gold-bright);
    font-family: var(--head);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.16em;
}

.home-alerts-signup h2 {
    margin: 0 0 0.45rem;
    color: #f3e4bc;
    font-family: var(--head);
    font-size: clamp(1.55rem, 2.4vw, 2.15rem);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.home-alerts-signup p {
    margin: 0;
    color: #b6a892;
    max-width: 680px;
}

.home-alerts-signup__actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

    .home-alerts-signup__actions .btn-gold,
    .home-alerts-signup__actions .btn-outline {
        white-space: nowrap;
    }

@media (max-width: 760px) {
    .home-alerts-signup__inner {
        flex-direction: column;
        align-items: flex-start;
        padding: 22px 20px;
    }

    .home-alerts-signup__actions {
        width: 100%;
        flex-wrap: wrap;
    }

        .home-alerts-signup__actions .btn-gold,
        .home-alerts-signup__actions .btn-outline {
            flex: 1 1 150px;
        }
}

.assignee-capability-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(110px, 1fr));
    gap: 0.4rem 0.75rem;
    min-width: 260px;
}

    .assignee-capability-form .mini-btn {
        grid-column: 1 / -1;
        justify-self: start;
        margin-top: 0.35rem;
    }

@media (max-width: 900px) {
    .assignee-capability-form {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   HOMEPAGE EVENT REGISTRATION LINK
   Keeps bookable events elegant inside the compact homepage event cards.
   ========================================================================== */

.home-tab-content .event-register-action {
    margin-top: 0.65rem;
}

.home-tab-content .event-register-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    max-width: max-content;
    padding: 0.35rem 0.65rem;
    border: 1px solid rgba(226, 190, 86, 0.65);
    border-radius: 999px;
    background: rgba(226, 190, 86, 0.08);
    color: #e2be56;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-decoration: none;
}

    .home-tab-content .event-register-link:hover,
    .home-tab-content .event-register-link:focus {
        background: rgba(226, 190, 86, 0.16);
        color: #f1d879;
        border-color: rgba(241, 216, 121, 0.9);
        text-decoration: none;
    }

/* ==========================================================================
   NAVBAR WRAPPING FIX
   Keeps top-level nav links on one line, including Live Streams and Staff Portal.
   ========================================================================== */

.main-nav > a,
.main-nav .nav-dropdown-toggle,
.main-nav .nav-dropdown-button,
.main-nav .nav-form button {
    white-space: nowrap;
}

.main-nav {
    flex-wrap: nowrap;
}

.nav-shell {
    gap: 1.25rem;
}

@media (min-width: 1001px) {
    .main-nav {
        column-gap: 1rem;
        row-gap: 0;
    }

        .main-nav > a,
        .main-nav .nav-dropdown-toggle,
        .main-nav .nav-dropdown-button,
        .main-nav .nav-form button {
            font-size: clamp(0.88rem, 0.82vw, 1.02rem);
        }
}

/* Logged-in desktop nav has extra links, so give it a little more room. */
@media (min-width: 1001px) {
    .site-header .nav-shell {
        width: min(1480px, calc(100vw - 80px));
        max-width: none;
    }

    body:not(.home-page) .main-nav {
        gap: clamp(14px, 1.2vw, 24px);
    }
}

@media (max-width: 1100px) {
    .main-nav {
        flex-wrap: wrap;
    }

        .main-nav > a,
        .main-nav .nav-dropdown-toggle,
        .main-nav .nav-dropdown-button,
        .main-nav .nav-form button {
            white-space: normal;
        }
}

/* ==========================================================================
   HOMEPAGE STYLE-GUIDE PASS
   Principles applied from GOV.UK, Apple HIG, Material Design, and NN/g:
   readable typography, minimal decoration, predictable spacing, strong
   contrast, restrained colour, clear interactive states, and obvious hierarchy.
   ========================================================================== */

:root {
    --head: 'Cardo', Georgia, serif;
    --body: 'Source Sans 3', system-ui, sans-serif;
    --serif: 'Cardo', Georgia, serif;
    --home-bg: #080808;
    --home-surface: #161616;
    --home-surface-raised: #1d1d1d;
    --home-border: #3a3427;
    --home-text: #f7f2e8;
    --home-text-muted: #c9c0ae;
    --home-accent: #d6b75f;
    --home-accent-strong: #f1d377;
    --home-focus: #ffffff;
}

body {
    font-family: var(--body);
    letter-spacing: 0;
}

h1,
h2,
h3,
.section-header h1,
.section-header h2 {
    font-family: var(--head);
    letter-spacing: 0;
}

body.home-page {
    background: var(--home-bg) !important;
    color: var(--home-text);
}

body.home-page .site-main,
body.home-page .site-main--home {
    background: var(--home-bg) !important;
}

body.home-page .parish-home {
    padding-bottom: clamp(48px, 7vw, 80px);
    background: var(--home-bg) !important;
}

body.home-page .parish-home__content {
    padding-top: clamp(32px, 4vw, 48px) !important;
}

body.home-page .home-stage {
    gap: clamp(24px, 3vw, 36px);
}

@media (min-width: 1001px) {
    body.home-page .site-header,
    body.home-page .site-header--home {
        height: 84px;
        background: linear-gradient(180deg, rgba(0, 0, 0, 0.68), rgba(0, 0, 0, 0.26) 70%, rgba(0, 0, 0, 0)) !important;
    }

    body.home-page .nav-shell {
        height: 84px;
        min-height: 84px;
        width: min(1320px, calc(100vw - 64px));
    }

    body.home-page .brand img,
    body.home-page .navbar-brand img {
        height: 52px;
        max-height: 52px;
        filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.7));
    }

    body.home-page .main-nav {
        gap: clamp(16px, 1.35vw, 26px);
        font-family: var(--body);
        font-size: clamp(0.92rem, 0.82vw, 1rem);
        font-weight: 600;
    }

    body.home-page .main-nav a,
    body.home-page .main-nav .nav-dropdown-button,
    body.home-page .nav-form button {
        min-height: 40px;
        display: inline-flex;
        align-items: center;
        color: rgba(247, 242, 232, 0.92) !important;
        text-shadow: 0 2px 8px rgba(0, 0, 0, 0.85);
        border-bottom: 2px solid transparent !important;
        letter-spacing: 0;
        text-transform: none;
    }

    body.home-page .main-nav a:hover,
    body.home-page .main-nav a:focus,
    body.home-page .main-nav a.active,
    body.home-page .main-nav .nav-dropdown-button:hover,
    body.home-page .main-nav .nav-dropdown-button:focus,
    body.home-page .main-nav .nav-dropdown-button.active,
    body.home-page .main-nav .nav-dropdown.active > .nav-dropdown-button,
    body.home-page .nav-form button:hover,
    body.home-page .nav-form button:focus {
        color: #ffffff !important;
        border-bottom-color: var(--home-accent-strong) !important;
    }

    body.home-page .homepage-hero::after,
    body.home-page .homepage-hero--main::after {
        background: linear-gradient(to bottom, rgba(0, 0, 0, 0.46), rgba(0, 0, 0, 0.05) 34%, rgba(0, 0, 0, 0.06) 68%, var(--home-bg) 100%) !important;
    }
}

body.home-page a:focus-visible,
body.home-page button:focus-visible {
    outline: 3px solid var(--home-focus);
    outline-offset: 3px;
}

body.home-page .home-dashboard {
    gap: clamp(20px, 2.5vw, 32px);
}

body.home-page .home-schedule-panel,
body.home-page .home-stream-panel,
body.home-page .home-alerts-signup__inner {
    background: var(--home-surface) !important;
    border: 1px solid var(--home-border) !important;
    border-radius: 6px;
    box-shadow: 0 16px 42px rgba(0, 0, 0, 0.34) !important;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
}

body.home-page .home-schedule-panel,
body.home-page .home-stream-panel {
    padding: clamp(20px, 2.4vw, 28px);
}

body.home-page .home-tabs {
    gap: 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #3a3a3a;
}

body.home-page .home-tabs .tab-button {
    min-height: 44px;
    margin-right: clamp(16px, 2vw, 28px);
    padding: 0 0 10px;
    color: var(--home-text-muted);
    font-family: var(--body);
    font-size: clamp(1rem, 1.25vw, 1.12rem);
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
    border-bottom: 3px solid transparent;
}

body.home-page .home-tabs .tab-button.active,
body.home-page .home-tabs .tab-button:hover {
    color: var(--home-text);
    border-bottom-color: var(--home-accent);
}

body.home-page .home-tab-content {
    gap: 12px;
}

body.home-page .home-tab-content .mass-card {
    min-height: 108px;
    padding: 16px;
    background: var(--home-surface-raised);
    border: 1px solid #333333;
    border-radius: 6px;
    box-shadow: none;
}

body.home-page .home-tab-content .mass-card:hover {
    background: #232323;
    border-color: #504734;
    transform: none;
}

body.home-page .home-card-plus,
body.home-page .home-section-plus {
    display: none;
}

body.home-page .time-block {
    min-width: 76px;
    border-right-color: #3a3a3a;
}

body.home-page .mass-time {
    color: var(--home-text);
    font-family: var(--body);
    font-size: clamp(1.75rem, 2.4vw, 2.15rem);
    font-weight: 700;
}

body.home-page .home-tab-content .ampm,
body.home-page .home-tab-content .mass-info small,
body.home-page .home-alerts-signup__kicker,
body.home-page .articles-section .article-cat,
body.home-page .articles-section .article-read-more {
    color: var(--home-accent);
}

body.home-page .home-tab-content .day-badge {
    background: #2a2a2a;
    border: 1px solid #454545;
    border-radius: 4px;
    color: var(--home-text-muted);
    font-size: 0.72rem;
    letter-spacing: 0.02em;
}

body.home-page .home-tab-content .mass-info h3 {
    color: var(--home-text);
    font-family: var(--body);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.25;
    text-transform: none;
}

body.home-page .home-tab-content .mass-info p,
body.home-page .home-stream-panel .stream-card p,
body.home-page .home-alerts-signup p,
body.home-page .home-bulletins .section-header p,
body.home-page .articles-section .section-header p {
    color: var(--home-text-muted);
}

body.home-page .home-stream-title,
body.home-page .home-alerts-signup h2,
body.home-page .home-bulletins .section-header h2,
body.home-page .articles-section .section-header h2 {
    color: var(--home-text);
    font-family: var(--body);
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
}

body.home-page .home-stream-title {
    margin: 0 0 16px;
    text-align: left;
    font-size: clamp(1.25rem, 1.7vw, 1.5rem);
}

body.home-page .home-stream-panel .stream-card {
    margin-bottom: 18px;
}

body.home-page .home-stream-panel .stream-card:last-child {
    margin-bottom: 0;
}

body.home-page .home-stream-panel .stream-card p {
    margin-top: 8px;
    font-family: var(--body);
    font-size: 0.95rem;
}

body.home-page .home-stream-panel .video-shell {
    border: 1px solid #333333;
    border-radius: 6px;
}

body.home-page .play-overlay {
    background: rgba(0, 0, 0, 0.30);
}

body.home-page .play-overlay i {
    width: 48px;
    height: 48px;
    border-color: #ffffff;
}

body.home-page .home-alerts-signup__inner {
    padding: clamp(20px, 2.4vw, 28px);
}

body.home-page .home-alerts-signup__kicker {
    margin-bottom: 6px;
    font-family: var(--body);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

body.home-page .home-alerts-signup h2 {
    margin-bottom: 6px;
    font-size: clamp(1.35rem, 2vw, 1.65rem);
}

body.home-page .btn-gold,
body.home-page .btn-outline,
body.home-page .home-tab-content .event-register-link {
    min-height: 44px;
    border-radius: 4px;
    font-family: var(--body);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
}

body.home-page .btn-gold {
    background: var(--home-accent);
    border-color: var(--home-accent);
    color: #141414;
}

body.home-page .btn-outline {
    border-color: var(--home-accent);
    color: var(--home-accent-strong);
}

body.home-page .home-tab-content .event-register-link {
    min-height: 0;
    padding: 6px 10px;
    border-color: var(--home-accent);
    color: var(--home-accent-strong);
}

body.home-page .home-bulletins,
body.home-page .articles-section {
    max-width: 1120px;
}

body.home-page .home-bulletins {
    padding-top: clamp(56px, 7vw, 84px);
}

body.home-page .articles-section {
    padding-top: clamp(48px, 6vw, 72px);
}

body.home-page .home-bulletins .section-header,
body.home-page .articles-section .section-header {
    margin-bottom: 24px;
    padding-bottom: 14px;
    border-bottom: 1px solid #383838;
}

body.home-page .home-bulletins .section-header::before,
body.home-page .articles-section .section-header::before,
body.home-page .home-bulletins .section-header::after,
body.home-page .articles-section .section-header::after {
    content: none;
}

body.home-page .home-bulletins .section-header h2,
body.home-page .articles-section .section-header h2 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    line-height: 1.15;
}

body.home-page .home-bulletins .section-header p,
body.home-page .articles-section .section-header p {
    margin-top: 6px;
    font-family: var(--body);
    font-size: 1rem;
}

body.home-page .home-bulletin-carousel {
    gap: 16px;
}

body.home-page .home-bulletin-card {
    min-height: 150px;
    padding: 20px;
    background: var(--home-surface);
    border: 1px solid #333333;
    border-radius: 6px;
    color: var(--home-text);
    box-shadow: none;
}

body.home-page .home-bulletin-card:hover,
body.home-page .home-bulletin-card:focus {
    background: var(--home-surface-raised);
    border-color: var(--home-border);
    transform: none;
}

body.home-page .home-bulletin-icon {
    margin-bottom: 14px;
    color: var(--home-accent);
    font-size: 1.35rem;
}

body.home-page .home-bulletin-title {
    font-family: var(--body);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0;
    line-height: 1.25;
    text-transform: none;
}

body.home-page .home-bulletin-date {
    color: var(--home-text-muted);
    font-family: var(--body);
    font-size: 0.92rem;
}

body.home-page .articles-section .article-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

body.home-page .articles-section .article-card {
    min-height: 360px;
    border: 1px solid #333333;
    border-radius: 6px;
    box-shadow: none;
}

body.home-page .articles-section .article-card:hover,
body.home-page .articles-section .article-card:focus-within {
    border-color: var(--home-border);
    box-shadow: none;
    transform: none;
}

body.home-page .articles-section .article-card::before {
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.24) 42%, rgba(0, 0, 0, 0.86));
}

body.home-page .articles-section .article-card::after {
    opacity: 0;
}

body.home-page .articles-section .article-content,
body.home-page .articles-section .article-card:nth-child(2n) .article-content {
    top: auto;
    bottom: 0;
    width: 100%;
    padding: 22px;
    justify-content: flex-end;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.82);
}

body.home-page .articles-section .article-cat {
    font-family: var(--body);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

body.home-page .articles-section .article-cat::before {
    display: none;
}

body.home-page .articles-section .article-content h3 {
    margin: 8px 0 10px;
    font-family: var(--body);
    font-size: clamp(1.35rem, 2vw, 1.75rem);
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: 0;
    text-transform: none;
}

body.home-page .articles-section .article-content h3::after {
    content: none;
}

body.home-page .articles-section .article-content h3 .first-word,
body.home-page .articles-section .article-content h3 .rest-words {
    color: var(--home-text);
    display: inline;
}

body.home-page .articles-section .article-content p {
    color: rgba(247, 242, 232, 0.88);
    font-family: var(--body);
    font-size: 0.96rem;
    line-height: 1.45;
    max-width: none;
}

body.home-page .articles-section .article-read-more {
    margin-top: 14px;
    font-family: var(--body);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
}

@media (max-width: 1000px) {
    body.home-page .site-header,
    body.home-page .site-header--home {
        background: #101010 !important;
    }

    body.home-page .main-nav a,
    body.home-page .main-nav .nav-dropdown-button,
    body.home-page .nav-form button {
        font-family: var(--body);
        font-weight: 700;
    }

    body.home-page .parish-home__content {
        padding-top: 28px !important;
    }

    body.home-page .articles-section .article-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    body.home-page .home-dashboard,
    body.home-page .home-tab-content,
    body.home-page .home-bulletin-carousel {
        gap: 12px;
    }

    body.home-page .home-schedule-panel,
    body.home-page .home-stream-panel,
    body.home-page .home-alerts-signup__inner,
    body.home-page .home-bulletin-card,
    body.home-page .articles-section .article-card {
        border-radius: 6px;
    }

    body.home-page .home-bulletin-card {
        min-height: 128px;
    }
}

/* ==========================================================================
   LIVE HOMEPAGE SACRED ELEGANCE
   Applies the approved mockup direction to the real homepage without changing
   its content structure.
   ========================================================================== */

:root {
    --head: 'Cardo', Georgia, serif;
    --body: 'Source Sans 3', system-ui, sans-serif;
    --serif: 'Cardo', Georgia, serif;
    --home-bg: #07060a;
    --home-bg-2: #100d0a;
    --home-panel: rgba(17, 13, 10, 0.92);
    --home-panel-2: rgba(255, 255, 255, 0.035);
    --home-line: rgba(214, 177, 83, 0.20);
    --home-line-strong: rgba(214, 177, 83, 0.42);
    --home-gold: #d6b153;
    --home-gold-soft: #ead18a;
    --home-ivory: #f7eed8;
    --home-muted: #b9aa91;
    --home-muted-deep: #8f806b;
}

body {
    font-family: var(--body);
}

body.home-page {
    background:
        radial-gradient(circle at 50% 0, rgba(214, 177, 83, 0.08), transparent 34%),
        var(--home-bg) !important;
    color: var(--home-ivory);
}

body.home-page .site-main,
body.home-page .site-main--home,
body.home-page .parish-home {
    background: var(--home-bg) !important;
}

@media (min-width: 1001px) {
    body.home-page .site-header,
    body.home-page .site-header--home {
        height: 92px;
        background: linear-gradient(180deg, rgba(2, 2, 2, 0.72), rgba(2, 2, 2, 0.18) 72%, rgba(2, 2, 2, 0)) !important;
    }

    body.home-page .nav-shell {
        width: min(1400px, calc(100vw - 72px));
        height: 92px;
        min-height: 92px;
    }

    body.home-page .brand img,
    body.home-page .navbar-brand img {
        height: 68px;
        max-height: 68px;
        filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.62));
    }

    body.home-page .main-nav {
        gap: clamp(16px, 1.45vw, 28px);
        font-family: var(--body);
        font-size: clamp(0.82rem, 0.74vw, 0.94rem);
        font-weight: 900;
    }

    body.home-page .main-nav a,
    body.home-page .main-nav .nav-dropdown-button,
    body.home-page .nav-form button {
        min-height: 44px;
        color: rgba(247, 238, 216, 0.86) !important;
        font-family: var(--body);
        font-weight: 900;
        letter-spacing: 0.07em;
        text-shadow: 0 2px 12px rgba(0, 0, 0, 0.85);
        text-transform: uppercase;
        border-bottom: 1px solid transparent !important;
    }

    body.home-page .main-nav a:hover,
    body.home-page .main-nav a:focus,
    body.home-page .main-nav a.active,
    body.home-page .main-nav .nav-dropdown-button:hover,
    body.home-page .main-nav .nav-dropdown-button:focus,
    body.home-page .main-nav .nav-dropdown-button.active,
    body.home-page .main-nav .nav-dropdown.active > .nav-dropdown-button,
    body.home-page .nav-form button:hover,
    body.home-page .nav-form button:focus {
        color: var(--home-ivory) !important;
        border-bottom-color: rgba(234, 209, 138, 0.82) !important;
    }

    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(560px, 64svh, 720px) !important;
        min-height: 560px !important;
        max-height: 720px !important;
        background:
            linear-gradient(180deg, rgba(3, 2, 2, 0.58), rgba(3, 2, 2, 0.04) 34%, rgba(3, 2, 2, 0.08) 66%, var(--home-bg) 100%),
            url('/img/home-image.webp') center top / cover no-repeat !important;
    }

    body.home-page .homepage-hero::before {
        background-image: none !important;
    }

    body.home-page .homepage-hero::after,
    body.home-page .homepage-hero--main::after {
        background: linear-gradient(180deg, rgba(7, 6, 10, 0), var(--home-bg)) !important;
        top: auto;
        height: 120px;
    }
}

body.home-page .parish-home {
    padding-bottom: clamp(64px, 8vw, 96px);
}

body.home-page .parish-home__content {
    padding-top: clamp(28px, 4vw, 48px) !important;
}

body.home-page .home-stage {
    gap: 26px;
}

body.home-page .home-dashboard {
    gap: 26px;
    grid-template-columns: minmax(0, 1.82fr) minmax(310px, 0.88fr);
}

body.home-page .home-schedule-panel,
body.home-page .home-stream-panel,
body.home-page .home-alerts-signup__inner,
body.home-page .home-bulletin-card,
body.home-page .articles-section .article-card {
    background: var(--home-panel) !important;
    border: 1px solid var(--home-line) !important;
    border-radius: 8px;
    box-shadow: 0 22px 54px rgba(0, 0, 0, 0.34) !important;
}

body.home-page .home-schedule-panel,
body.home-page .home-stream-panel {
    padding: clamp(22px, 2.4vw, 30px);
}

body.home-page .home-tabs {
    gap: clamp(18px, 2.2vw, 30px);
    margin-bottom: 22px;
    border-bottom: 1px solid var(--home-line);
}

body.home-page .home-tabs .tab-button {
    min-height: 45px;
    padding: 0;
    color: var(--home-muted);
    font-family: var(--head);
    font-size: clamp(1.32rem, 1.9vw, 1.65rem);
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0;
    text-transform: none;
    border-bottom: 2px solid transparent;
}

body.home-page .home-tabs .tab-button.active,
body.home-page .home-tabs .tab-button:hover {
    color: var(--home-ivory);
    border-bottom-color: var(--home-gold);
}

body.home-page .home-tab-content {
    gap: 12px;
}

body.home-page .home-tab-content .mass-card {
    min-height: 116px;
    padding: 17px 18px;
    border: 1px solid rgba(247, 238, 216, 0.07);
    border-radius: 7px;
    background: var(--home-panel-2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025);
}

body.home-page .home-tab-content .mass-card:hover {
    border-color: var(--home-line-strong);
    background: rgba(255, 255, 255, 0.052);
    transform: none;
}

body.home-page .home-card-plus,
body.home-page .home-section-plus {
    display: none;
}

body.home-page .home-tab-content .time-block {
    min-width: 78px;
    padding-right: 15px;
    margin-right: 15px;
    border-right-color: var(--home-line);
}

body.home-page .mass-time {
    color: var(--home-ivory);
    font-family: var(--head);
    font-size: 2.16rem;
    font-weight: 600;
    line-height: 0.9;
}

body.home-page .home-tab-content .ampm,
body.home-page .home-tab-content .mass-info small,
body.home-page .home-alerts-signup__kicker,
body.home-page .articles-section .article-cat,
body.home-page .articles-section .article-read-more {
    color: var(--home-gold);
}

body.home-page .home-tab-content .day-badge {
    padding: 3px 7px;
    border: 1px solid rgba(214, 177, 83, 0.18);
    border-radius: 4px;
    background: rgba(214, 177, 83, 0.08);
    color: var(--home-gold-soft);
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.04em;
}

body.home-page .home-tab-content .mass-info h3 {
    color: var(--home-ivory);
    font-family: var(--body);
    font-size: 1.02rem;
    font-weight: 900;
    line-height: 1.18;
    text-transform: none;
}

body.home-page .home-tab-content .mass-info p,
body.home-page .home-stream-panel .stream-card p,
body.home-page .home-alerts-signup p {
    color: var(--home-muted);
}

body.home-page .home-stream-title,
body.home-page .home-alerts-signup h2,
body.home-page .home-bulletins .section-header h2,
body.home-page .articles-section .section-header h2 {
    color: var(--home-ivory);
    font-family: var(--head);
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
}

body.home-page .home-stream-title {
    margin-bottom: 18px;
    text-align: left;
    font-size: clamp(1.82rem, 2.45vw, 2.3rem);
    line-height: 1;
}

body.home-page .home-stream-panel .stream-card {
    margin-bottom: 18px;
}

body.home-page .home-stream-panel .stream-card:last-child {
    margin-bottom: 0;
}

body.home-page .home-stream-panel .video-shell {
    border: 1px solid rgba(247, 238, 216, 0.10);
    border-radius: 7px;
}

body.home-page .home-stream-panel .stream-card p {
    margin-top: 9px;
    color: var(--home-muted);
    font-family: var(--body);
    font-size: 0.96rem;
    font-weight: 700;
}

body.home-page .play-overlay {
    background: rgba(0, 0, 0, 0.30);
}

body.home-page .play-overlay i {
    width: 48px;
    height: 48px;
    border-color: var(--home-ivory);
}

body.home-page .home-alerts-signup__inner {
    padding: clamp(22px, 2.6vw, 30px);
}

body.home-page .home-alerts-signup__kicker {
    margin-bottom: 6px;
    font-family: var(--body);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.13em;
}

body.home-page .home-alerts-signup h2 {
    margin-bottom: 7px;
    font-size: clamp(1.72rem, 2.5vw, 2.28rem);
    line-height: 1;
}

body.home-page .btn-gold,
body.home-page .btn-outline,
body.home-page .home-tab-content .event-register-link {
    border-radius: 5px;
    font-family: var(--body);
    font-size: 0.94rem;
    font-weight: 900;
    letter-spacing: 0;
    text-transform: none;
}

body.home-page .btn-gold {
    background: var(--home-gold);
    border-color: var(--home-gold);
    color: #14100a;
}

body.home-page .btn-outline {
    border-color: var(--home-gold);
    color: var(--home-gold-soft);
}

body.home-page .home-bulletins,
body.home-page .articles-section {
    max-width: 1180px;
}

body.home-page .home-bulletins {
    padding-top: clamp(66px, 8vw, 96px);
}

body.home-page .articles-section {
    padding-top: clamp(66px, 8vw, 96px);
}

body.home-page .home-bulletins .section-header,
body.home-page .articles-section .section-header {
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--home-line);
}

body.home-page .home-bulletins .section-header::before,
body.home-page .home-bulletins .section-header::after,
body.home-page .articles-section .section-header::before,
body.home-page .articles-section .section-header::after {
    content: none;
}

body.home-page .home-bulletins .section-header h2,
body.home-page .articles-section .section-header h2 {
    font-size: clamp(2.25rem, 4.5vw, 3.9rem);
    line-height: 0.92;
}

body.home-page .home-bulletin-carousel {
    gap: 14px;
}

body.home-page .home-bulletin-card {
    min-height: 158px;
    padding: 22px;
    background: var(--home-panel) !important;
    box-shadow: none !important;
}

body.home-page .home-bulletin-card:hover {
    border-color: var(--home-line-strong) !important;
    background: rgba(17, 13, 10, 0.98) !important;
    transform: none;
}

body.home-page .home-bulletin-icon {
    margin-bottom: 1rem;
    color: var(--home-gold);
    font-size: 1.55rem;
}

body.home-page .home-bulletin-title {
    color: var(--home-ivory);
    font-family: var(--body);
    font-size: 1.02rem;
    font-weight: 900;
    line-height: 1.25;
    letter-spacing: 0;
    text-transform: none;
}

body.home-page .home-bulletin-date {
    color: var(--home-muted-deep);
    font-family: var(--body);
    font-size: 0.92rem;
}

body.home-page .articles-section .article-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

body.home-page .articles-section .article-card {
    min-height: 420px;
    background-position: center;
    background-size: cover;
    box-shadow: none !important;
}

body.home-page .articles-section .article-card:hover,
body.home-page .articles-section .article-card:focus-within {
    border-color: var(--home-line-strong) !important;
    box-shadow: none !important;
    transform: none;
}

body.home-page .articles-section .article-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.26) 42%, rgba(0, 0, 0, 0.88));
}

body.home-page .articles-section .article-card::after {
    opacity: 0;
}

body.home-page .articles-section .article-content,
body.home-page .articles-section .article-card:nth-child(2n) .article-content {
    top: auto;
    bottom: 0;
    width: 100%;
    padding: 26px;
    justify-content: flex-end;
    text-shadow: none;
}

body.home-page .articles-section .article-cat {
    font-family: var(--body);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.10em;
}

body.home-page .articles-section .article-cat::before,
body.home-page .articles-section .article-content h3::after {
    display: none;
}

body.home-page .articles-section .article-content h3 {
    margin: 10px 0;
    color: var(--home-ivory);
    font-family: var(--head);
    font-size: clamp(1.8rem, 2.7vw, 2.45rem);
    font-weight: 600;
    line-height: 0.98;
    letter-spacing: 0;
    text-transform: none;
}

body.home-page .articles-section .article-content h3 .first-word,
body.home-page .articles-section .article-content h3 .rest-words {
    color: inherit;
    display: inline;
}

body.home-page .articles-section .article-content p {
    color: rgba(247, 238, 216, 0.82);
    font-family: var(--body);
    font-size: 1rem;
    line-height: 1.48;
    max-width: none;
}

body.home-page .articles-section .article-read-more {
    margin-top: 14px;
    font-family: var(--body);
    font-size: 0.9rem;
    font-weight: 900;
    letter-spacing: 0;
    text-transform: none;
}

@media (max-width: 1100px) {
    body.home-page .home-dashboard,
    body.home-page .articles-section .article-grid {
        grid-template-columns: 1fr;
    }

    body.home-page .main-nav a,
    body.home-page .main-nav .nav-dropdown-button,
    body.home-page .nav-form button {
        font-family: var(--body);
    }
}

@media (max-width: 760px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: 430px !important;
        min-height: 430px !important;
        background-position: center !important;
    }

    body.home-page .home-tab-content,
    body.home-page .home-bulletin-carousel {
        grid-template-columns: 1fr;
    }

    body.home-page .home-alerts-signup__inner {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* ==========================================================================
   LIVE HOMEPAGE MOCKUP PARITY FIX
   The earlier homepage CSS defines structural rules for cards and articles.
   This final block makes the real MVC markup follow the approved mockup more
   closely, rather than only sharing its colours and fonts.
   ========================================================================== */

body.home-page .page-shell {
    max-width: 1180px;
}

body.home-page .home-stage {
    margin-top: 0 !important;
}

body.home-page .home-dashboard {
    display: grid !important;
    grid-template-columns: minmax(0, 1.82fr) minmax(310px, 0.88fr) !important;
    gap: 26px !important;
    align-items: start !important;
}

body.home-page .home-tab-content.active {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
}

body.home-page .home-tab-content .mass-card {
    display: grid !important;
    grid-template-columns: 78px minmax(0, 1fr) !important;
    gap: 17px !important;
    align-items: center !important;
    min-height: 116px !important;
    padding: 17px 18px !important;
}

body.home-page .home-tab-content .mass-card > .time-block {
    min-width: 0 !important;
    width: 78px !important;
    padding-right: 15px !important;
    margin-right: 0 !important;
    text-align: center !important;
}

body.home-page .home-tab-content .mass-card > .mass-info {
    min-width: 0 !important;
    padding-right: 0 !important;
}

body.home-page .home-tab-content .day-row {
    min-height: 0 !important;
    margin-bottom: 7px !important;
}

body.home-page .home-tab-content .mass-info h3 {
    margin: 0 0 5px !important;
}

body.home-page .home-stream-panel {
    display: block !important;
}

body.home-page .home-stream-panel .stream-card {
    display: grid !important;
    gap: 9px !important;
}

body.home-page .home-stream-panel .stream-card p {
    margin: 0 !important;
}

body.home-page .home-alerts-signup__inner {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 24px !important;
}

body.home-page .home-alerts-signup__actions {
    gap: 10px !important;
}

body.home-page .home-bulletins .section-header,
body.home-page .articles-section .section-header {
    display: flex !important;
    align-items: flex-end !important;
    justify-content: space-between !important;
    gap: 28px !important;
}

body.home-page .home-bulletins .section-header p,
body.home-page .articles-section .section-header p {
    display: none !important;
}

body.home-page .home-bulletin-carousel {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 14px !important;
}

body.home-page .home-bulletin-card {
    display: grid !important;
    align-content: space-between !important;
    min-height: 158px !important;
}

body.home-page .articles-section .article-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 18px !important;
}

body.home-page .articles-section .article-card {
    display: grid !important;
    align-content: end !important;
    min-height: 420px !important;
    overflow: hidden !important;
}

body.home-page .articles-section .article-content {
    position: absolute !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    z-index: 2 !important;
    display: block !important;
    pointer-events: none !important;
}

body.home-page .articles-section .article-hit {
    z-index: 4 !important;
}

body.home-page .articles-section .article-content p {
    display: block !important;
}

body.home-page .articles-section .article-read-more {
    display: inline-flex !important;
}

body.home-page .articles-section {
    margin-bottom: clamp(48px, 6vw, 84px) !important;
    padding-bottom: 0 !important;
}

body.home-page .site-footer,
body.home-page .site-footer--home,
body.home-page .parish-footer {
    clear: both;
    margin-top: 0 !important;
}

body.home-page .articles-section .article-grid {
    gap: 20px !important;
}

body.home-page .articles-section .article-card {
    display: grid !important;
    grid-template-rows: 235px 1fr !important;
    align-content: stretch !important;
    min-height: 0 !important;
    background-color: var(--home-panel) !important;
    background-repeat: no-repeat !important;
    background-size: 0 0 !important;
    box-shadow: 0 18px 46px rgba(0, 0, 0, 0.28) !important;
}

body.home-page .articles-section .article-card::before {
    content: "" !important;
    position: relative !important;
    inset: auto !important;
    z-index: 1 !important;
    display: block !important;
    min-height: 235px !important;
    border-bottom: 1px solid var(--home-line);
    background-image: inherit;
    background-position: center;
    background-size: cover;
}

body.home-page .articles-section .article-card::after {
    content: "" !important;
    position: absolute !important;
    inset: 0 !important;
    z-index: 3 !important;
    opacity: 1 !important;
    border: 1px solid transparent;
    border-radius: inherit;
    background: none !important;
    pointer-events: none;
    transition: border-color 0.2s ease;
}

body.home-page .articles-section .article-card:hover::after,
body.home-page .articles-section .article-card:focus-within::after {
    border-color: var(--home-line-strong);
}

body.home-page .articles-section .article-content,
body.home-page .articles-section .article-card:nth-child(2n) .article-content {
    position: relative !important;
    inset: auto !important;
    z-index: 2 !important;
    width: 100% !important;
    padding: 22px !important;
    display: grid !important;
    align-content: start !important;
    background: transparent !important;
}

body.home-page .articles-section .article-cat {
    color: var(--home-gold-soft) !important;
    font-size: 0.72rem !important;
    letter-spacing: 0.11em !important;
}

body.home-page .articles-section .article-content h3 {
    margin: 9px 0 10px !important;
    font-size: clamp(1.55rem, 2.1vw, 2rem) !important;
    line-height: 1.02 !important;
}

body.home-page .articles-section .article-content p {
    color: var(--home-muted) !important;
    font-size: 0.96rem !important;
    line-height: 1.5 !important;
}

body.home-page .articles-section .article-read-more {
    margin-top: 18px !important;
    gap: 8px !important;
    color: var(--home-gold-soft) !important;
    font-size: 0.86rem !important;
    font-weight: 900 !important;
}

body.home-page .articles-section .article-read-more i {
    font-size: 0.82rem !important;
    transition: transform 0.2s ease;
}

body.home-page .articles-section .article-card:hover .article-read-more i,
body.home-page .articles-section .article-card:focus-within .article-read-more i {
    transform: translateX(3px);
}

@media (max-width: 1100px) {
    body.home-page .home-dashboard,
    body.home-page .articles-section .article-grid {
        grid-template-columns: 1fr !important;
    }

    body.home-page .home-bulletin-carousel {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 760px) {
    body.home-page .home-tab-content.active,
    body.home-page .home-bulletin-carousel {
        grid-template-columns: 1fr !important;
    }

    body.home-page .home-alerts-signup__inner {
        align-items: flex-start !important;
        flex-direction: column !important;
    }
}

/* ==========================================================================
   NAV CONSISTENCY AND SUBJECT-SAFE HERO FIX
   Keeps the sacred-elegance menu across pages and prevents the homepage artwork
   from being cropped by cover sizing.
   ========================================================================== */

.site-header {
    background: linear-gradient(180deg, #111, rgba(17, 17, 17, 0.96)) !important;
}

.main-nav,
.main-nav .nav-dropdown-button,
.nav-form button {
    font-family: var(--body) !important;
}

.main-nav {
    gap: clamp(14px, 1.2vw, 24px) !important;
    font-size: clamp(0.82rem, 0.76vw, 0.96rem) !important;
    font-weight: 900 !important;
}

.main-nav > a,
.main-nav .nav-dropdown-button,
.main-nav .nav-form button,
.nav-form button {
    color: rgba(247, 238, 216, 0.88) !important;
    font-weight: 900 !important;
    letter-spacing: 0.06em !important;
    text-transform: uppercase !important;
    border-bottom: 1px solid transparent !important;
}

.main-nav > a:hover,
.main-nav > a:focus,
.main-nav > a.active,
.main-nav .nav-dropdown-button:hover,
.main-nav .nav-dropdown-button:focus,
.main-nav .nav-dropdown-button.active,
.main-nav .nav-dropdown.active > .nav-dropdown-button,
.nav-form button:hover,
.nav-form button:focus {
    color: var(--home-ivory) !important;
    border-bottom-color: rgba(234, 209, 138, 0.82) !important;
}

.brand img,
.navbar-brand img {
    filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.42));
}

body.home-page .site-header,
body.home-page .site-header--home {
    background: linear-gradient(180deg, rgba(2, 2, 2, 0.72), rgba(2, 2, 2, 0.18) 72%, rgba(2, 2, 2, 0)) !important;
}

@media (min-width: 1001px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        position: relative !important;
        height: clamp(620px, 66svh, 760px) !important;
        min-height: 620px !important;
        max-height: 760px !important;
        isolation: isolate;
        background:
            linear-gradient(rgba(3, 2, 2, 0.62), rgba(3, 2, 2, 0.64)),
            url('/img/home-image.webp') center center / cover no-repeat var(--home-bg) !important;
    }

    body.home-page .homepage-hero::before,
    body.home-page .homepage-hero--main::before {
        content: "" !important;
        position: absolute !important;
        inset: 0 !important;
        z-index: 0 !important;
        pointer-events: none !important;
        background-image: url('/img/home-image.webp') !important;
        background-repeat: no-repeat !important;
        background-position: center top !important;
        background-size: auto 100% !important;
        filter: drop-shadow(0 20px 46px rgba(0, 0, 0, 0.45));
    }

    body.home-page .homepage-hero::after,
    body.home-page .homepage-hero--main::after {
        content: "" !important;
        position: absolute !important;
        left: 0 !important;
        right: 0 !important;
        top: 0 !important;
        bottom: 0 !important;
        z-index: 1 !important;
        height: auto !important;
        pointer-events: none !important;
        background:
            linear-gradient(to bottom, rgba(3, 2, 2, 0.44) 0%, rgba(3, 2, 2, 0.10) 22%, rgba(3, 2, 2, 0.00) 56%, rgba(7, 6, 10, 0.42) 90%, var(--home-bg) 100%),
            radial-gradient(115% 92% at 50% 42%, rgba(214, 177, 83, 0.04), rgba(0, 0, 0, 0.00) 50%, rgba(0, 0, 0, 0.26) 100%) !important;
    }

    body.home-page .homepage-hero__content {
        position: relative;
        z-index: 2;
    }
}

@media (max-width: 1000px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(460px, 62svh, 660px) !important;
        min-height: 460px !important;
        max-height: 660px !important;
        background:
            linear-gradient(to bottom, rgba(3, 2, 2, 0.36), rgba(7, 6, 10, 0.42)),
            url('/img/home-image.webp') center 38% / contain no-repeat var(--home-bg) !important;
    }
}

@media (max-width: 700px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(360px, 54svh, 520px) !important;
        min-height: 360px !important;
        max-height: 520px !important;
        background-size: contain !important;
        background-position: center 42% !important;
    }
}

/* ==========================================================================
   ARTICLES INDEX SACRED ELEGANCE
   ========================================================================== */

.articles-index {
    max-width: 1180px;
    margin-inline: auto;
    padding-top: clamp(48px, 7vw, 88px) !important;
    padding-bottom: clamp(72px, 9vw, 112px) !important;
}

.articles-index__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: clamp(24px, 4vw, 38px);
    padding-bottom: 18px;
    border-bottom: 1px solid var(--home-line);
}

.articles-index__kicker {
    margin: 0 0 8px;
    color: var(--home-gold-soft);
    font-family: var(--body);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.13em;
    line-height: 1.2;
    text-transform: uppercase;
}

.articles-index__header h1 {
    margin: 0;
    color: var(--home-ivory);
    font-family: var(--head);
    font-size: clamp(2.85rem, 6vw, 5rem);
    font-weight: 600;
    letter-spacing: 0;
    line-height: 0.92;
    text-transform: none;
}

.articles-index__count {
    margin: 0 0 8px;
    color: var(--home-muted);
    font-family: var(--body);
    font-size: 0.9rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.articles-index .article-category-filter {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin: -1.1rem 0 2rem;
}

.articles-index .article-category-filter a {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.58rem 0.9rem;
    border: 1px solid rgba(218, 183, 86, 0.24);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.035);
    color: #d9b538;
    font-family: var(--body);
    font-size: 0.8rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    line-height: 1;
    text-decoration: none;
    text-transform: uppercase;
    transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.articles-index .article-category-filter a:hover,
.articles-index .article-category-filter a:focus,
.articles-index .article-category-filter a.active {
    border-color: rgba(218, 183, 86, 0.68);
    background: rgba(218, 183, 86, 0.12);
    color: #fff8e8;
}

.articles-index .article-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.articles-index .article-card {
    position: relative;
    display: grid;
    grid-template-rows: 235px 1fr;
    min-height: 0;
    overflow: hidden;
    border: 1px solid var(--home-line);
    border-radius: 8px;
    background: var(--home-panel);
    box-shadow: 0 18px 46px rgba(0, 0, 0, 0.28);
    transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.articles-index .article-card:hover,
.articles-index .article-card:focus-within {
    transform: translateY(-3px);
    border-color: var(--home-line-strong);
    box-shadow: 0 24px 58px rgba(0, 0, 0, 0.34);
}

.articles-index .article-card::before,
.articles-index .article-card::after {
    content: none !important;
}

.articles-index .article-list-card__media {
    min-height: 235px;
    border-bottom: 1px solid var(--home-line);
    background-color: rgba(255, 255, 255, 0.04);
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    transition: transform 0.28s ease;
}

.articles-index .article-card:hover .article-list-card__media,
.articles-index .article-card:focus-within .article-list-card__media {
    transform: scale(1.025);
}

.articles-index .article-hit {
    position: absolute;
    inset: 0;
    z-index: 5;
    overflow: hidden;
    text-indent: -9999px;
}

.articles-index .article-content {
    position: relative;
    inset: auto;
    z-index: 2;
    display: grid;
    align-content: start;
    width: 100%;
    min-height: 230px;
    padding: 22px;
    background: transparent;
    text-shadow: none;
    pointer-events: none;
}

.articles-index .article-cat {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--home-gold-soft);
    font-family: var(--body);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.11em;
    line-height: 1.2;
    text-transform: uppercase;
}

.articles-index .article-cat::before {
    content: "";
    width: 18px;
    height: 1px;
    background: currentColor;
    opacity: 0.75;
}

.articles-index .article-content h3 {
    margin: 9px 0 10px;
    color: var(--home-ivory);
    font-family: var(--head);
    font-size: clamp(1.55rem, 2.1vw, 2rem);
    font-weight: 600;
    letter-spacing: 0;
    line-height: 1.02;
    text-transform: none;
}

.articles-index .article-content h3 .first-word,
.articles-index .article-content h3 .rest-words {
    display: inline;
    color: inherit;
}

.articles-index .article-content p {
    margin: 0;
    color: var(--home-muted);
    font-family: var(--body);
    font-size: 0.96rem;
    font-weight: 400;
    line-height: 1.5;
}

.articles-index .article-read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 18px;
    color: var(--home-gold-soft);
    font-family: var(--body);
    font-size: 0.86rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.articles-index .article-read-more i {
    font-size: 0.82rem;
    transition: transform 0.2s ease;
}

.articles-index .article-card:hover .article-read-more i,
.articles-index .article-card:focus-within .article-read-more i {
    transform: translateX(3px);
}

.articles-index .articles-result-count {
    margin: 24px 0 0;
    color: var(--home-muted);
    font-family: var(--body);
    font-size: 0.88rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-align: center;
}

.articles-index .articles-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    flex-wrap: wrap;
    margin-top: 26px;
}

.articles-index .articles-pagination a,
.articles-index .articles-pagination span {
    min-width: 42px;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    border: 1px solid var(--home-line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.035);
    color: var(--home-gold-soft);
    font-family: var(--body);
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-decoration: none;
    text-transform: uppercase;
}

.articles-index .articles-pagination a:hover,
.articles-index .articles-pagination a:focus {
    border-color: var(--home-line-strong);
    background: rgba(234, 209, 138, 0.11);
    color: var(--home-ivory);
}

.articles-index .articles-pagination .active {
    border-color: var(--home-gold-soft);
    background: var(--home-gold-soft);
    color: #14100b;
}

.articles-index .articles-pagination .disabled {
    opacity: 0.45;
    pointer-events: none;
}

.articles-index .articles-empty {
    padding: clamp(54px, 8vw, 86px) 18px;
    border: 1px solid var(--home-line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.035);
    color: var(--home-muted);
    text-align: center;
}

.articles-index .articles-empty h2 {
    margin: 0 0 8px;
    color: var(--home-ivory);
    font-family: var(--head);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
    letter-spacing: 0;
}

.articles-index .articles-empty p {
    margin: 0;
}

@media (max-width: 1100px) {
    .articles-index .article-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .articles-index {
        padding-top: 38px !important;
    }

    .articles-index__header {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .articles-index__count {
        margin: 0;
    }

    .articles-index .article-grid {
        grid-template-columns: 1fr;
    }

    .articles-index .article-card {
        grid-template-rows: 220px 1fr;
    }

    .articles-index .article-list-card__media {
        min-height: 220px;
    }
}

/* ==========================================================================
   HOMEPAGE SCHEDULE - SOFT SEGMENTED OPTION
   ========================================================================== */

body.home-page .home-schedule-panel {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)),
        rgba(18, 14, 11, 0.9) !important;
    border-color: var(--home-line) !important;
    box-shadow: 0 22px 54px rgba(0, 0, 0, 0.34) !important;
    backdrop-filter: blur(10px);
    min-height: 0 !important;
    padding: clamp(22px, 2.35vw, 30px) !important;
}

body.home-page .home-stream-panel {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.012)),
        rgba(18, 14, 11, 0.9) !important;
    border-color: var(--home-line) !important;
    box-shadow: 0 22px 54px rgba(0, 0, 0, 0.34) !important;
    min-height: 0 !important;
    padding: clamp(22px, 2.35vw, 30px) !important;
    backdrop-filter: blur(10px);
}

body.home-page .home-panel-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 14px;
    padding: 0;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.home-page .home-panel-head > div,
body.home-page .home-panel-head h2,
body.home-page .home-panel-kicker {
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.home-page .home-panel-kicker {
    margin: 0 0 6px;
    color: var(--home-gold-soft);
    font-family: var(--body);
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.13em;
    line-height: 1.2;
    text-transform: uppercase;
}

body.home-page .home-panel-head h2 {
    margin: 0;
    color: var(--home-ivory);
    font-family: var(--head);
    font-size: clamp(1.82rem, 2.7vw, 2.55rem);
    font-weight: 600;
    letter-spacing: 0;
    line-height: 0.95;
    text-transform: none;
}

body.home-page .home-panel-mark {
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    display: grid;
    place-items: center;
    border: 1px solid var(--home-line);
    border-radius: 999px;
    background: rgba(234, 209, 138, 0.07);
    color: var(--home-gold-soft);
}

body.home-page .home-schedule-panel .tabs.home-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px !important;
    margin: 0 0 14px !important;
    padding: 6px !important;
    border: 1px solid var(--home-line) !important;
    border-radius: 7px;
    border-bottom: 1px solid var(--home-line) !important;
    background: rgba(255, 255, 255, 0.03) !important;
    box-shadow: none !important;
}

body.home-page .home-schedule-panel .tabs.home-tabs::before,
body.home-page .home-schedule-panel .tabs.home-tabs::after {
    content: none !important;
}

body.home-page .home-schedule-panel .home-tabs .tab-button {
    min-height: 38px !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 13px !important;
    border: 1px solid transparent !important;
    border-radius: 5px;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--home-muted);
    font-family: var(--body) !important;
    font-size: 0.78rem !important;
    font-weight: 900 !important;
    letter-spacing: 0.08em !important;
    line-height: 1;
    text-transform: uppercase !important;
}

body.home-page .home-schedule-panel .home-tabs .tab-button.active,
body.home-page .home-schedule-panel .home-tabs .tab-button:hover,
body.home-page .home-schedule-panel .home-tabs .tab-button:focus {
    border-color: rgba(234, 209, 138, 0.52) !important;
    background: rgba(234, 209, 138, 0.12);
    color: var(--home-ivory);
}

body.home-page .home-stream-panel .home-panel-head {
    margin-bottom: 16px;
}

body.home-page .home-stream-panel .stream-card {
    margin-bottom: 14px !important;
}

body.home-page .home-stream-panel .stream-card:last-child {
    margin-bottom: 0 !important;
}

body.home-page .home-schedule-panel .home-tab-content.active {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
}

body.home-page .home-schedule-panel .home-tab-content .mass-card {
    min-height: 104px !important;
    display: grid !important;
    grid-template-columns: 96px minmax(0, 1fr) !important;
    gap: 17px !important;
    align-items: center !important;
    padding: 15px 16px !important;
    border: 1px solid rgba(247, 238, 216, 0.08) !important;
    border-radius: 7px !important;
    background: rgba(255, 255, 255, 0.04) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035) !important;
    transition: border-color 0.2s ease, background 0.2s ease;
}

body.home-page .home-schedule-panel .home-tab-content .mass-card:hover,
body.home-page .home-schedule-panel .home-tab-content .mass-card:focus-within {
    border-color: var(--home-line-strong) !important;
    background: rgba(255, 255, 255, 0.055) !important;
}

body.home-page .home-schedule-panel .home-tab-content .mass-card > .time-block {
    width: auto !important;
    min-width: 96px !important;
    padding-right: 15px !important;
    margin-right: 0 !important;
    border-right: 1px solid var(--home-line) !important;
    text-align: center !important;
}

body.home-page .home-schedule-panel .home-tab-content .mass-card.event-mass-card {
    grid-template-columns: 128px minmax(0, 1fr) !important;
}

body.home-page .home-schedule-panel .home-tab-content .mass-card.event-mass-card > .time-block {
    min-width: 128px !important;
    padding-right: 18px !important;
}

body.home-page .home-schedule-panel .mass-time {
    color: var(--home-ivory);
    font-family: var(--head);
    font-size: 2.16rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    line-height: 0.9;
    white-space: nowrap;
}

body.home-page .home-schedule-panel .home-tab-content .ampm {
    margin-top: 6px;
    color: var(--home-gold);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.08em;
}

body.home-page .home-schedule-panel .home-tab-content .day-row {
    min-height: 0 !important;
    margin-bottom: 7px !important;
}

body.home-page .home-schedule-panel .home-tab-content .day-badge {
    padding: 3px 7px;
    border: 1px solid rgba(214, 177, 83, 0.18);
    border-radius: 4px;
    background: rgba(214, 177, 83, 0.08);
    color: var(--home-gold-soft);
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.04em;
}

body.home-page .home-schedule-panel .home-tab-content .mass-info {
    min-width: 0 !important;
}

body.home-page .home-schedule-panel .home-tab-content .mass-info h3 {
    margin: 0 0 5px !important;
    color: var(--home-ivory);
    font-family: var(--body);
    font-size: 1.02rem;
    font-weight: 900;
    line-height: 1.18;
}

body.home-page .home-schedule-panel .home-tab-content .mass-info p {
    margin: 0;
    color: var(--home-muted);
    font-size: 0.94rem;
    font-weight: 700;
    line-height: 1.4;
}

body.home-page .home-schedule-panel .home-tab-content .mass-info small {
    color: var(--home-gold);
}

@media (max-width: 1100px) {
    body.home-page .home-schedule-panel .home-tab-content.active {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 760px) {
    body.home-page .home-panel-head {
        align-items: flex-start;
    }

    body.home-page .home-schedule-panel .home-tab-content.active {
        grid-template-columns: 1fr !important;
    }

    body.home-page .home-schedule-panel .home-tab-content .mass-card {
        grid-template-columns: 96px minmax(0, 1fr) !important;
    }

    body.home-page .home-schedule-panel .home-tab-content .mass-card.event-mass-card {
        grid-template-columns: 118px minmax(0, 1fr) !important;
    }

    body.home-page .home-schedule-panel .home-tab-content .mass-card.event-mass-card > .time-block {
        min-width: 118px !important;
        padding-right: 16px !important;
    }
}

/* ==========================================================================
   SITE TYPOGRAPHY UNIFICATION
   ========================================================================== */

:root {
    --head: 'Cardo', Georgia, serif;
    --body: 'Source Sans 3', system-ui, sans-serif;
    --serif: 'Cardo', Georgia, serif;
}

body,
button,
input,
select,
textarea {
    font-family: var(--body);
}

h1,
h2,
h3,
.section-header h1,
.section-header h2 {
    font-family: var(--head);
    font-weight: 400;
    letter-spacing: 0.005em;
}

.main-nav,
.main-nav a,
.main-nav .nav-dropdown-button,
.main-nav .nav-dropdown-toggle,
.main-nav .nav-form button,
.site-footer,
.btn,
.btn-gold,
.form-input,
.form-select {
    font-family: var(--body) !important;
}

/* Lower homepage sections should sit below the hero/schedule hierarchy. */
body.home-page .home-bulletins .section-header h2,
body.home-page .articles-section .section-header h2 {
    font-family: var(--head) !important;
    font-size: clamp(1.85rem, 3vw, 2.65rem) !important;
    font-weight: 400 !important;
    line-height: 1.05 !important;
    letter-spacing: 0.005em !important;
    text-transform: none !important;
}

@media (max-width: 700px) {
    body.home-page .home-bulletins .section-header h2,
    body.home-page .articles-section .section-header h2 {
        font-size: clamp(1.65rem, 8vw, 2.2rem) !important;
    }
}

/* ==========================================================================
   LIGHT MODE
   ========================================================================== */

.theme-toggle {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid rgba(212, 175, 55, 0.34);
    border-radius: 999px;
    background: rgba(212, 175, 55, 0.10);
    color: #fff1cf;
    cursor: pointer;
    font-family: var(--body);
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.05em;
    line-height: 1;
    text-transform: uppercase;
}

.theme-toggle:hover,
.theme-toggle:focus {
    border-color: var(--gold);
    color: var(--gold);
}

html[data-theme="light"] {
    --bg: #f5f0e6;
    --bg-deep: #ebe2d2;
    --panel: #fffaf0;
    --panel-2: #f8efdF;
    --panel-3: #eee2cd;
    --text: #1f1b16;
    --muted: #685d4e;
    --line: #d8c8a8;
    --gold: #9f7617;
    --orange: #a55319;
    --orange-soft: #b97844;
    --green: #137a43;
    --red: #a93632;
    --purple: #715378;
    --home-bg: #f5f0e6;
    --home-surface: #fffaf0;
    --home-surface-raised: #ffffff;
    --home-border: #d8c8a8;
    --home-text: #1f1b16;
    --home-text-muted: #685d4e;
    --home-accent: #9f7617;
    --home-accent-strong: #7d5a0e;
    --home-focus: #1f1b16;
    --home-panel: #fffaf0;
    --home-line: rgba(139, 101, 24, 0.28);
    --home-line-strong: rgba(139, 101, 24, 0.48);
    --home-ivory: #221d17;
    --home-muted: #685d4e;
    --home-gold: #9f7617;
    --home-gold-soft: #8a6415;
}

html[data-theme="light"],
html[data-theme="light"] body {
    background: #f5f0e6;
    color: #1f1b16;
}

html[data-theme="light"] .site-header,
html[data-theme="light"] .site-header--home {
    background: linear-gradient(180deg, rgba(255, 250, 240, 0.98), rgba(255, 250, 240, 0.94)) !important;
    border-bottom-color: rgba(139, 101, 24, 0.24) !important;
    box-shadow: 0 12px 30px rgba(66, 45, 14, 0.12) !important;
}

html[data-theme="light"] .main-nav a,
html[data-theme="light"] .main-nav .nav-dropdown-button,
html[data-theme="light"] .nav-form button {
    color: #2a241d !important;
}

html[data-theme="light"] .main-nav a:hover,
html[data-theme="light"] .main-nav a.active,
html[data-theme="light"] .main-nav .nav-dropdown-button:hover,
html[data-theme="light"] .main-nav .nav-dropdown-button.active,
html[data-theme="light"] .nav-form button:hover {
    color: #8a6415 !important;
    border-bottom-color: #8a6415 !important;
}

html[data-theme="light"] .theme-toggle {
    border-color: rgba(139, 101, 24, 0.36);
    background: rgba(139, 101, 24, 0.10);
    color: #2a241d;
}

html[data-theme="light"] .theme-toggle:hover,
html[data-theme="light"] .theme-toggle:focus {
    color: #8a6415;
}

html[data-theme="light"] .mobile-nav-toggle {
    border-color: rgba(139, 101, 24, 0.34) !important;
    background: rgba(255, 250, 240, 0.78) !important;
    color: #8a6415 !important;
}

html[data-theme="light"] .mobile-nav-toggle i {
    color: #8a6415 !important;
}

html[data-theme="light"] .main-nav[data-main-nav].is-open,
html[data-theme="light"] body.mobile-nav-open .main-nav[data-main-nav] {
    background: rgba(255, 250, 240, 0.985) !important;
    border-top-color: rgba(139, 101, 24, 0.24) !important;
    border-bottom-color: rgba(139, 101, 24, 0.52) !important;
    box-shadow: 0 22px 50px rgba(66, 45, 14, 0.18) !important;
}

html[data-theme="light"] .site-main,
html[data-theme="light"] .site-main--home,
html[data-theme="light"] body.home-page,
html[data-theme="light"] body.home-page .site-main,
html[data-theme="light"] body.home-page .site-main--home,
html[data-theme="light"] body.home-page .parish-home,
html[data-theme="light"] .readings-page,
html[data-theme="light"] .readings-sidebar {
    background: #f5f0e6 !important;
    color: #1f1b16 !important;
}

html[data-theme="light"] .content-card,
html[data-theme="light"] .auth-card,
html[data-theme="light"] .manager-card,
html[data-theme="light"] .article-detail-card,
html[data-theme="light"] .bulletin-header,
html[data-theme="light"] .bulletin-card,
html[data-theme="light"] .bulletin-empty,
html[data-theme="light"] .readings-container,
html[data-theme="light"] .readings-sidebar,
html[data-theme="light"] .readings-page-nav,
html[data-theme="light"] body.home-page .home-schedule-panel,
html[data-theme="light"] body.home-page .home-stream-panel,
html[data-theme="light"] body.home-page .articles-section .article-card,
html[data-theme="light"] body.home-page .home-bulletin-card,
html[data-theme="light"] .articles-index .article-card {
    border-color: rgba(139, 101, 24, 0.24) !important;
    background: #fffaf0 !important;
    color: #1f1b16 !important;
    box-shadow: 0 18px 44px rgba(66, 45, 14, 0.12) !important;
}

html[data-theme="light"] body.home-page .articles-section .article-card::before {
    border-bottom-color: rgba(139, 101, 24, 0.24) !important;
}

html[data-theme="light"] body.home-page .articles-section .article-content,
html[data-theme="light"] body.home-page .articles-section .article-card:nth-child(2n) .article-content {
    background: transparent !important;
}

html[data-theme="light"] body.home-page .parish-home__media {
    background: #e8dcc7 !important;
}

html[data-theme="light"] body.home-page .parish-home__media::after {
    background: linear-gradient(180deg, rgba(245, 240, 230, 0) 0%, rgba(245, 240, 230, 0.58) 66%, #f5f0e6 100%) !important;
}

html[data-theme="light"] body.home-page .parish-home__veil {
    background: linear-gradient(180deg, rgba(255, 250, 240, 0.04), rgba(255, 250, 240, 0.14)) !important;
}

html[data-theme="light"] .section-header,
html[data-theme="light"] .articles-index__header {
    border-bottom-color: rgba(139, 101, 24, 0.28) !important;
}

html[data-theme="light"] h1,
html[data-theme="light"] h2,
html[data-theme="light"] h3,
html[data-theme="light"] .section-header h1,
html[data-theme="light"] .section-header h2,
html[data-theme="light"] .articles-index__header h1,
html[data-theme="light"] .bulletin-header h1,
html[data-theme="light"] .article-body h2,
html[data-theme="light"] .article-body h3,
html[data-theme="light"] .article-body h4,
html[data-theme="light"] .readings-day-title,
html[data-theme="light"] .reading-static-title,
html[data-theme="light"] .readings-static-title,
html[data-theme="light"] .bulletin-card strong,
html[data-theme="light"] .article-content h3,
html[data-theme="light"] .articles-index .article-content h3 {
    color: #211b14 !important;
}

html[data-theme="light"] .article-page-kicker,
html[data-theme="light"] .article-detail-meta,
html[data-theme="light"] .article-cat,
html[data-theme="light"] .articles-index .article-cat,
html[data-theme="light"] body.home-page .articles-section .article-cat,
html[data-theme="light"] .readings-context-label,
html[data-theme="light"] .readings-sidebar-title,
html[data-theme="light"] .bulletin-count,
html[data-theme="light"] .bulletin-page-link,
html[data-theme="light"] .bulletin-result-count,
html[data-theme="light"] .articles-index .articles-result-count,
html[data-theme="light"] .article-read-more,
html[data-theme="light"] .articles-index .article-read-more {
    color: #8a6415 !important;
}

html[data-theme="light"] p,
html[data-theme="light"] .muted,
html[data-theme="light"] .newsletter-summary,
html[data-theme="light"] .bulletin-card-copy span,
html[data-theme="light"] .article-content p,
html[data-theme="light"] .article-detail-summary,
html[data-theme="light"] .article-body,
html[data-theme="light"] .readings-body,
html[data-theme="light"] .readings-source,
html[data-theme="light"] .reading-source,
html[data-theme="light"] body.home-page .articles-section .article-content p,
html[data-theme="light"] .articles-index .article-content p {
    color: #5f5548 !important;
}

html[data-theme="light"] .form-input,
html[data-theme="light"] .form-select,
html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] textarea {
    border-color: rgba(139, 101, 24, 0.28) !important;
    background: #fffdf8 !important;
    color: #1f1b16 !important;
}

html[data-theme="light"] .live-volume {
    border: 0 !important;
    background: transparent !important;
    color: inherit !important;
}

html[data-theme="light"] .live-volume--compact::-webkit-slider-runnable-track {
    background: rgba(234, 209, 138, 0.42) !important;
}

html[data-theme="light"] .live-volume--compact::-moz-range-track {
    background: rgba(234, 209, 138, 0.42) !important;
}

html[data-theme="light"] .live-volume--compact::-webkit-slider-thumb {
    border-color: #fff7dc !important;
    background: #b8891f !important;
}

html[data-theme="light"] .live-volume--compact::-moz-range-thumb {
    border-color: #fff7dc !important;
    background: #b8891f !important;
}

html[data-theme="light"] .form-input::placeholder,
html[data-theme="light"] textarea::placeholder,
html[data-theme="light"] input::placeholder {
    color: #8b8173 !important;
}

html[data-theme="light"] .btn-gold,
html[data-theme="light"] .bulletin-page-current,
html[data-theme="light"] .articles-index .articles-pagination .active {
    border-color: #8a6415 !important;
    background: #8a6415 !important;
    color: #fffaf0 !important;
}

html[data-theme="light"] .btn-outline,
html[data-theme="light"] .btn-muted,
html[data-theme="light"] .mini-btn,
html[data-theme="light"] .articles-index .article-category-filter a,
html[data-theme="light"] .articles-index .articles-pagination a,
html[data-theme="light"] .articles-index .articles-pagination span,
html[data-theme="light"] .bulletin-page-link,
html[data-theme="light"] .bulletin-page-disabled {
    border-color: rgba(139, 101, 24, 0.28) !important;
    background: rgba(139, 101, 24, 0.06) !important;
    color: #8a6415 !important;
}

html[data-theme="light"] .articles-index .article-category-filter a:hover,
html[data-theme="light"] .articles-index .article-category-filter a:focus,
html[data-theme="light"] .articles-index .article-category-filter a.active {
    border-color: #8a6415 !important;
    background: #8a6415 !important;
    color: #fffaf0 !important;
}

html[data-theme="light"] .article-page-image,
html[data-theme="light"] .featured-preview img {
    background: #e8dcc7 !important;
}

html[data-theme="light"] .site-footer,
html[data-theme="light"] .site-footer--home,
html[data-theme="light"] .parish-footer {
    border-top-color: rgba(139, 101, 24, 0.24) !important;
    background: #eee5d4 !important;
    color: #5f5548 !important;
}

html[data-theme="light"] .parish-footer a,
html[data-theme="light"] .parish-footer h2,
html[data-theme="light"] .parish-footer strong {
    color: #211b14 !important;
}

/* Homepage article cards use the database FeaturedImagePath as real media. */
body.home-page .articles-section .home-article-card {
    display: grid !important;
    grid-template-rows: 235px 1fr !important;
    min-height: 0 !important;
    overflow: hidden !important;
    background-image: none !important;
    background-color: var(--home-panel) !important;
}

body.home-page .articles-section .home-article-card::before {
    content: none !important;
}

body.home-page .articles-section .home-article-card__media {
    position: relative;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    border-bottom: 1px solid var(--home-line);
    background: #0b0907;
}

body.home-page .articles-section .home-article-card__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

html[data-theme="light"] body.home-page .articles-section .home-article-card__media {
    border-bottom-color: rgba(139, 101, 24, 0.24) !important;
    background: #e8dcc7 !important;
}

.bulletin-page .bulletin-header,
html[data-theme="light"] .bulletin-page .bulletin-header {
    border-top: 0 !important;
    border-right: 0 !important;
    border-left: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

/* Light mode: keep article title hero legible on its dark editorial banner. */
html[data-theme="light"] .article-page-heading {
    max-width: 900px;
    padding: clamp(20px, 3vw, 30px) clamp(20px, 4vw, 44px);
    border: 1px solid rgba(139, 101, 24, 0.22);
    background: linear-gradient(180deg, #151210 0%, #101010 100%) !important;
    box-shadow: 0 18px 42px rgba(66, 45, 14, 0.16);
}

html[data-theme="light"] .article-page-heading h1 {
    color: #fff7df !important;
    text-shadow: 0 2px 14px rgba(0, 0, 0, 0.34);
}

html[data-theme="light"] .article-page-heading .article-page-kicker {
    color: #e4c467 !important;
}

/* Light mode dropdown menus should read as light surfaces, not dark overlays. */
html[data-theme="light"] .main-nav .nav-dropdown-menu {
    border-color: rgba(139, 101, 24, 0.28) !important;
    background: #fffaf0 !important;
    box-shadow: 0 18px 42px rgba(66, 45, 14, 0.18) !important;
}

html[data-theme="light"] .main-nav .nav-dropdown-menu::before {
    border-bottom-color: rgba(139, 101, 24, 0.28) !important;
    border-left-color: rgba(139, 101, 24, 0.28) !important;
    background: #fffaf0 !important;
}

html[data-theme="light"] .main-nav .nav-dropdown-menu a {
    border-bottom-color: rgba(139, 101, 24, 0.14) !important;
    color: #2a241d !important;
}

html[data-theme="light"] .main-nav .nav-dropdown-menu a:hover,
html[data-theme="light"] .main-nav .nav-dropdown-menu a.active {
    background: rgba(139, 101, 24, 0.08) !important;
    color: #8a6415 !important;
}

/* Light mode: image heroes keep a dark overlay, so their text must stay bright. */
html[data-theme="light"] .prayer-hero h1,
html[data-theme="light"] .prayer-hero__eyebrow,
html[data-theme="light"] .prayer-hero p:last-child,
html[data-theme="light"] .livestream-hero__content h1,
html[data-theme="light"] .livestream-hero__content p:not(.section-kicker),
html[data-theme="light"] .sacrament-hero h1 {
    color: #fff7dc !important;
}

html[data-theme="light"] .prayer-hero__eyebrow,
html[data-theme="light"] .section-kicker,
html[data-theme="light"] .sacrament-tag {
    color: #f2d28a !important;
}

/* Light mode refinements for page-specific hero treatments. */
html[data-theme="light"] .article-page-heading {
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

html[data-theme="light"] .article-page-heading h1 {
    color: #241d14 !important;
    text-shadow: none !important;
}

html[data-theme="light"] .article-page-heading .article-page-kicker {
    color: #8a6415 !important;
}

html[data-theme="light"] body.home-page .homepage-hero,
html[data-theme="light"] body.home-page .homepage-hero--main {
    background: url('/img/home-image.webp') center top / cover no-repeat #f5f0e6 !important;
}

html[data-theme="light"] body.home-page .homepage-hero::before,
html[data-theme="light"] body.home-page .homepage-hero--main::before {
    filter: none !important;
    opacity: 1 !important;
}

html[data-theme="light"] body.home-page .homepage-hero::after,
html[data-theme="light"] body.home-page .homepage-hero--main::after,
html[data-theme="light"] body.home-page .parish-home__media::after,
html[data-theme="light"] body.home-page .parish-home__veil {
    content: none !important;
    display: none !important;
    background: none !important;
}

html[data-theme="light"] .readings-container,
html[data-theme="light"] .readings-meta-header {
    background: #fffaf0 !important;
}

html[data-theme="light"] .readings-day-title,
html[data-theme="light"] .readings-day-title *,
html[data-theme="light"] .readings-dynamic-heading {
    color: #241d14 !important;
    text-shadow: none !important;
}

html[data-theme="light"] .readings-context-label,
html[data-theme="light"] .readings-date-row,
html[data-theme="light"] .readings-static-title {
    color: #8a6415 !important;
}

@media (max-width: 700px) {
    html[data-theme="light"] body.home-page .site-header,
    html[data-theme="light"] body.home-page .site-header--home {
        background: rgba(255, 250, 240, 0.98) !important;
    }

    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        height: clamp(250px, 38svh, 340px) !important;
        min-height: 250px !important;
        max-height: 340px !important;
    }

    html[data-theme="light"] body.home-page .homepage-hero,
    html[data-theme="light"] body.home-page .homepage-hero--main {
        background-size: cover !important;
        background-position: center top !important;
    }

    body.home-page .home-stage {
        margin-top: clamp(-22px, -4vw, -10px) !important;
    }
}

/* Homepage light mode uses the same navbar treatment as inner pages. */
html[data-theme="light"] body.home-page .site-header,
html[data-theme="light"] body.home-page .site-header--home {
    background: linear-gradient(180deg, rgba(255, 250, 240, 0.98), rgba(255, 250, 240, 0.94)) !important;
    border-bottom: 1px solid rgba(139, 101, 24, 0.24) !important;
    box-shadow: 0 12px 30px rgba(66, 45, 14, 0.12) !important;
}

html[data-theme="light"] body.home-page .main-nav a,
html[data-theme="light"] body.home-page .main-nav .nav-dropdown-button,
html[data-theme="light"] body.home-page .nav-form button {
    color: #2a241d !important;
    text-shadow: none !important;
}

html[data-theme="light"] body.home-page .main-nav a:hover,
html[data-theme="light"] body.home-page .main-nav a.active,
html[data-theme="light"] body.home-page .main-nav .nav-dropdown-button:hover,
html[data-theme="light"] body.home-page .main-nav .nav-dropdown-button:focus,
html[data-theme="light"] body.home-page .main-nav .nav-dropdown-button.active,
html[data-theme="light"] body.home-page .main-nav .nav-dropdown.active > .nav-dropdown-button,
html[data-theme="light"] body.home-page .nav-form button:hover,
html[data-theme="light"] body.home-page .nav-form button:focus {
    color: #8a6415 !important;
    border-bottom-color: #8a6415 !important;
}

html[data-theme="light"] body.home-page .brand img,
html[data-theme="light"] body.home-page .navbar-brand img {
    filter: none !important;
}

/* Light mode uses the gold logo supplied for pale nav backgrounds. */
html[data-theme="light"] .brand img.brand-logo--dark,
html[data-theme="light"] .navbar-brand img.brand-logo--dark,
html[data-theme="light"] .parish-footer__brand img.brand-logo--dark {
    display: none !important;
}

html[data-theme="light"] .brand img.brand-logo--light,
html[data-theme="light"] .navbar-brand img.brand-logo--light,
html[data-theme="light"] .parish-footer__brand img.brand-logo--light {
    display: block !important;
}

/* Article titles should sit on the page, not inside a visible title block. */
.article-page-heading,
html[data-theme="light"] .article-page-heading {
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

/* Light mode homepage alerts should read as a light warning panel. */
html[data-theme="light"] body.home-page .home-alert-slot .alert-banner {
    border: 1px solid rgba(139, 101, 24, 0.24) !important;
    border-left: 5px solid #b34137 !important;
    background: linear-gradient(180deg, #fffaf0, #f5ead5) !important;
    color: #2a241d !important;
    box-shadow: 0 18px 44px rgba(66, 45, 14, 0.14) !important;
    backdrop-filter: none !important;
}

html[data-theme="light"] body.home-page .home-alert-slot .alert-title {
    color: #8a6415 !important;
}

html[data-theme="light"] body.home-page .home-alert-slot .alert-title i {
    color: #b34137 !important;
}

html[data-theme="light"] body.home-page .home-alert-slot .alert-body p {
    color: #5f5548 !important;
}

html[data-theme="light"] body.home-page .home-alert-slot .alert-link {
    color: #8a6415 !important;
}

html[data-theme="light"] body.home-page .home-alert-slot .alert-link:hover,
html[data-theme="light"] body.home-page .home-alert-slot .alert-link:focus {
    color: #6e4f10 !important;
}

html[data-theme="light"] body.home-page .home-schedule-panel .home-tab-content .empty-card {
    border: 1px solid rgba(139, 101, 24, 0.18) !important;
    background: #fffaf0 !important;
    color: #5f5548 !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72) !important;
}

html[data-theme="light"] .auth-card h1 {
    color: #1f1b16 !important;
}

html[data-theme="light"] .auth-card p,
html[data-theme="light"] .auth-card label,
html[data-theme="light"] .auth-card .checkbox-row {
    color: #4f463a !important;
}

html[data-theme="light"] .auth-card form > label:not(.checkbox-row) {
    color: #5d4b2e !important;
    font-weight: 800 !important;
}

html[data-theme="light"] .auth-card .checkbox-row {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    font-weight: 800 !important;
}

html[data-theme="light"] .auth-card input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    accent-color: #9f7411;
}

html[data-theme="light"] .auth-card .auth-links a {
    color: #6e4f10 !important;
}

html[data-theme="light"] .auth-card .auth-links a:hover,
html[data-theme="light"] .auth-card .auth-links a:focus {
    color: #9f7411 !important;
}

body.home-page .home-bulletin-icon {
    display: inline-grid !important;
    place-items: center !important;
    width: 44px !important;
    height: 44px !important;
    margin-bottom: 1rem !important;
    border: 1px solid var(--home-line) !important;
    border-radius: 50% !important;
    background: rgba(214, 177, 83, 0.1) !important;
    color: var(--home-gold) !important;
    font-size: 0.68rem !important;
    font-weight: 900 !important;
    letter-spacing: 0.08em !important;
    line-height: 1 !important;
    text-transform: uppercase !important;
}

@media (max-width: 520px) {
    body.home-page .home-schedule-panel .tabs.home-tabs {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 8px !important;
        width: 100% !important;
    }

    body.home-page .home-schedule-panel .home-tabs .tab-button {
        width: 100% !important;
        min-width: 0 !important;
        padding: 10px 8px !important;
        text-align: center !important;
        white-space: nowrap !important;
    }
}

@media (max-width: 700px) {
    body.home-page .homepage-hero,
    body.home-page .homepage-hero--main {
        background: url('/img/home-image.webp') center 42% / contain no-repeat var(--home-bg) !important;
    }

    body.home-page .homepage-hero::before,
    body.home-page .homepage-hero--main::before {
        background-image: none !important;
        filter: none !important;
    }

    body.home-page .homepage-hero::after,
    body.home-page .homepage-hero--main::after {
        background: linear-gradient(180deg, rgba(7, 6, 10, 0) 0%, rgba(7, 6, 10, 0.4) 72%, var(--home-bg) 100%) !important;
        height: 92px !important;
        top: auto !important;
    }
}

