/* ---------------------------------------------------------
   High Country History Group
   Journal archive, article pages, and parish map explorer
--------------------------------------------------------- */

/* Style for People Page */
.people-list ul {
    list-style: none;
    padding: 0;
}

.people-list li {
    margin: 10px 0;
}

.people-list a {
    text-decoration: none;
    color: #0073aa;
}

.people-list a:hover {
    color: #005177;
}

/* Style for Person Profile */
.person-profile h1 {
    font-size: 2em;
    margin-bottom: 20px;
}

.person-bio {
    margin-bottom: 20px;
}

.article-date {
    font-size: 0.9em;
    color: #777;
}

/* ---------------------------------------------------------
   Journal archive
--------------------------------------------------------- */
.hchg-article-reader-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex: 1 1 100%;
    width: 100%;
    padding-bottom: 10px;
    margin-bottom: 6px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.hchg-article-reader-nav-count {
    font-size: 0.82rem;
    color: #66726c;
    font-weight: 800;
    white-space: nowrap;
}

.hchg-article-nav-button[disabled] {
    opacity: 0.42;
    cursor: not-allowed;
}

.hchg-article-nav-button[disabled]:hover {
    background: #eef2ee;
}


.hchg-archive-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    font-family: "Times New Roman", Times, serif;
}

.hchg-archive-container .archive-header {
    margin-bottom: 24px;
    border-bottom: 3px double #333;
    padding-bottom: 20px;
}

.hchg-archive-container .archive-header h1 {
    font-size: 3rem;
    margin: 0;
    color: #000;
}

.archive-intro {
    margin-top: 10px;
    color: #555;
    font-size: 1rem;
    line-height: 1.5;
    font-family: Arial, sans-serif;
}

.archive-tools {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 34px;
    padding: 16px;
    background: #f8f8f8;
    border: 1px solid #e6e6e6;
    border-radius: 12px;
    font-family: Arial, sans-serif;
}

.journal-search-label,
.journal-year-label {
    font-weight: 700;
    color: #222;
    font-size: 0.95rem;
}

.journal-search-input {
    width: 100%;
    max-width: 520px;
    padding: 11px 13px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    font-family: Arial, sans-serif;
    box-sizing: border-box;
}

.journal-search-input:focus,
.journal-year-select:focus {
    outline: 2px solid #004b87;
    outline-offset: 2px;
    border-color: #004b87;
}

.journal-jump-tools {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
}

.journal-year-select {
    min-width: 190px;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 8px;
    background: #fff;
    font-size: 0.95rem;
    font-family: Arial, sans-serif;
}

.decade-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.decade-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 11px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #d7d7d7;
    color: #004b87;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 700;
}

.decade-nav a:hover,
.decade-nav a:focus {
    background: #004b87;
    color: #fff;
}

.journal-filter-summary {
    display: none;
    color: #555;
    font-size: 0.92rem;
}

.hchg-archive-container .year-section {
    margin-bottom: 60px;
    scroll-margin-top: 30px;
}

.decade-anchor {
    display: block;
    position: relative;
    top: -30px;
    visibility: hidden;
}

.hchg-archive-container .year-title {
    font-size: 2.5rem;
    color: #004b87;
    margin-bottom: 25px;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
}

.journals-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px 30px;
}

.journal-card-wrapper {
    display: flex;
    flex-direction: column;
}

.journal-card {
    position: relative;
    overflow: hidden;
    background: #fff;
    border: 1px solid #ddd;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    aspect-ratio: 3 / 4;
    margin-bottom: 15px;
}

.journal-card-link {
    display: block;
    position: relative;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.journal-cover {
    width: 100%;
    height: 100%;
    background: #f4f4f4;
}

.journal-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.journal-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f4f4f4, #e7e7e7);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #777;
    font-family: Arial, sans-serif;
    font-size: 0.9rem;
    text-align: center;
    padding: 20px;
    box-sizing: border-box;
}

.journal-meta-under {
    text-align: center;
}

.issue-name {
    font-weight: bold;
    font-size: 1.1rem;
    display: block;
    color: #000;
    text-decoration: none;
    margin-bottom: 2px;
}

.issue-name:hover,
.issue-name:focus {
    text-decoration: underline;
}

.pub-month {
    font-style: italic;
    color: #666;
    font-size: 0.95rem;
    display: block;
    margin-bottom: 8px;
}

.journal-desc-short {
    font-size: 0.85rem;
    color: #444;
    line-height: 1.4;
    font-family: Arial, sans-serif;
}

/* Journal hover overlay */

.journal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 75, 135, 0.96);
    color: #fff;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 18px;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    pointer-events: none;
}

.journal-card:hover .journal-overlay,
.journal-card:focus-within .journal-overlay,
.journal-card.is-open .journal-overlay {
    opacity: 1;
    pointer-events: none;
}

.journal-card:hover .journal-cover img,
.journal-card:focus-within .journal-cover img,
.journal-card.is-open .journal-cover img {
    transform: scale(1.08);
}

.overlay-title {
    flex: 0 0 auto;
    font-weight: bold;
    font-size: 1.1rem;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.3);
    padding-bottom: 6px;
}

/*
   Reliable contents scroll.
   The JavaScript in the archive template calculates:
   --hchg-scroll-distance
   --hchg-scroll-duration
*/

.overlay-scroll-area {
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
    padding-right: 8px;
    position: relative;
}

.overlay-contents {
    font-size: 0.85rem;
    line-height: 1.35;
    list-style: none;
    padding: 0;
    margin: 0;
    font-family: Arial, sans-serif;
    transform: translateY(0);
    will-change: transform;
}

.overlay-contents li {
    margin-bottom: 7px;
    padding-left: 14px;
    position: relative;
}

.overlay-contents li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: #ffd700;
}

.journal-card.has-overflow:hover .overlay-contents,
.journal-card.has-overflow:focus-within .overlay-contents,
.journal-card.has-overflow.is-open .overlay-contents {
    animation-name: hchgContentsScroll;
    animation-duration: var(--hchg-scroll-duration, 16s);
    animation-timing-function: linear;
    animation-fill-mode: forwards;
    animation-delay: 0.8s;
    animation-iteration-count: 1;
}

@keyframes hchgContentsScroll {
    from {
        transform: translateY(0);
    }

    to {
        transform: translateY(calc(-1 * var(--hchg-scroll-distance, 0px)));
    }
}

.overlay-scroll-hint {
    flex: 0 0 auto;
    display: none;
    margin-top: 8px;
    padding-top: 7px;
    border-top: 1px solid rgba(255,255,255,0.2);
    font-size: 0.72rem;
    font-family: Arial, sans-serif;
    color: rgba(255,255,255,0.82);
}

.journal-card.has-overflow .overlay-scroll-hint {
    display: block;
}

.journal-card.has-overflow .overlay-scroll-area::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 26px;
    background: linear-gradient(
        to bottom,
        rgba(0,75,135,0),
        rgba(0,75,135,0.96)
    );
    pointer-events: none;
}

/* Mobile/touch journal contents button */

.journal-mobile-toggle {
    display: none;
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 3;
    border: 0;
    border-radius: 999px;
    background: rgba(0, 75, 135, 0.92);
    color: #fff;
    font-family: Arial, sans-serif;
    font-size: 0.78rem;
    padding: 7px 10px;
    cursor: pointer;
}

.journal-mobile-toggle:focus {
    outline: 2px solid #ffd700;
    outline-offset: 2px;
}

.no-journal-results {
    display: none;
    padding: 24px;
    border: 1px solid #ddd;
    background: #fafafa;
    color: #555;
    font-family: Arial, sans-serif;
    border-radius: 12px;
    margin-top: 20px;
}

@media (hover: none) {
    .journal-mobile-toggle {
        display: inline-flex;
    }

    .journal-card:hover .journal-overlay {
        opacity: 0;
        pointer-events: none;
    }

    .journal-card.is-open .journal-overlay {
        opacity: 1;
        pointer-events: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .journal-cover img,
    .journal-overlay {
        transition: none;
    }

    .journal-card.has-overflow:hover .overlay-contents,
    .journal-card.has-overflow:focus-within .overlay-contents,
    .journal-card.has-overflow.is-open .overlay-contents {
        animation: none;
    }
}

@media (max-width: 1024px) {
    .journals-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .hchg-archive-container {
        padding: 30px 16px;
    }

    .hchg-archive-container .archive-header h1 {
        font-size: 2.4rem;
    }

    .hchg-archive-container .year-title {
        font-size: 2rem;
    }

    .journals-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 32px 20px;
    }

    .archive-tools {
        padding: 14px;
    }

    .journal-jump-tools {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .journals-grid {
        grid-template-columns: 1fr;
    }

    .journal-card {
        max-width: 320px;
        width: 100%;
        margin-left: auto;
        margin-right: auto;
    }
}


/* ---------------------------------------------------------
   Articles archive
--------------------------------------------------------- */

.hchg-articles-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 20px;
    font-family: "Times New Roman", Times, serif;
}

/* Archive Header */

.articles-archive-header {
    margin-bottom: 40px;
    border-bottom: 3px double #333;
    padding-bottom: 20px;
}

.articles-archive-header h1 {
    font-size: 3rem;
    margin: 0;
    color: #000;
}

/* Section Headings */

.archive-section {
    margin-bottom: 60px;
}

.archive-section-title {
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #888;
    font-family: sans-serif;
    margin-bottom: 24px;
    padding-bottom: 6px;
    border-bottom: 2px solid #eee;
}

/* Group Sections */

.group-section {
    margin-bottom: 40px;
}

.group-title {
    font-size: 1.75rem;
    color: #004b87;
    margin-bottom: 14px;
    padding-bottom: 4px;
    border-bottom: 1px solid #ddd;
}

/* Article Row */

.article-row {
    border-bottom: 1px solid #eee;
}

.article-summary {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 12px 0;
    cursor: pointer;
    transition: background 0.15s;
    gap: 12px;
}

.article-summary:hover {
    background: #f9f9f9;
    padding-left: 8px;
    padding-right: 8px;
    margin-left: -8px;
    margin-right: -8px;
}

.article-title-col {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.article-title-text {
    font-size: 1.1rem;
    font-weight: bold;
    color: #000;
    line-height: 1.3;
}

.article-author-text {
    font-size: 0.9rem;
    font-style: italic;
    color: #555;
}

.article-journal-tag {
    font-size: 0.82rem;
    color: #777;
    white-space: nowrap;
    font-family: sans-serif;
}

.expand-indicator {
    font-size: 1.2rem;
    color: #004b87;
    transition: transform 0.25s;
    flex-shrink: 0;
    line-height: 1;
}

.article-row.open .expand-indicator {
    transform: rotate(45deg);
}

/* Inline Expanded Detail */

.article-detail {
    display: none;
    padding: 20px 0 30px 0;
    border-top: 1px dashed #ccc;
    margin-top: 4px;
}

.article-row.open .article-detail {
    display: block;
}

/* Detail layout */

.detail-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
}

@media (max-width: 700px) {
    .detail-grid {
        grid-template-columns: 1fr;
    }
}

.detail-field {
    margin-bottom: 18px;
}

.detail-field-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #888;
    font-family: sans-serif;
    margin-bottom: 4px;
}

.detail-field-value {
    font-size: 1rem;
    color: #222;
    line-height: 1.6;
}

/* Relationship pill links */

.rel-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.rel-pill {
    display: inline-block;
    padding: 4px 12px;
    border: 1px solid #004b87;
    color: #004b87;
    font-size: 0.82rem;
    font-family: sans-serif;
    text-decoration: none;
    border-radius: 2px;
    transition: all 0.2s;
}

.rel-pill:hover {
    background: #004b87;
    color: #fff;
}

.rel-pill.journal-pill {
    background: #004b87;
    color: #fff;
    font-weight: bold;
}

.rel-pill.journal-pill:hover {
    background: #002f57;
}

/* Source notes */

.source-notes-text {
    font-size: 0.88rem;
    color: #555;
    font-family: sans-serif;
    line-height: 1.5;
    font-style: italic;
}

/* Empty state */

.no-articles {
    padding: 40px 0;
    color: #777;
    font-style: italic;
}


/* ---------------------------------------------------------
   Single journal / article display
--------------------------------------------------------- */

.hchg-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    font-family: "Times New Roman", Times, serif;
    line-height: 1.6;
    color: #1a1a1a;
}

.hchg-branding {
    display: flex;
    align-items: center;
    gap: 30px;
    margin-bottom: 40px;
    border-bottom: 3px double #333;
    padding-bottom: 25px;
}

.hchg-logo img {
    max-width: 150px;
    height: auto;
    display: block;
}

.hchg-brand-text h1 {
    margin: 0;
    font-size: 2.8rem;
    line-height: 1;
    color: #000;
    font-weight: bold;
}

.hchg-villages {
    font-size: 1.15rem;
    font-weight: bold;
    margin-top: 8px;
    color: #333;
}

.hchg-est {
    font-style: italic;
    color: #666;
    margin-top: 5px;
    font-size: 1rem;
}

.hchg-cover-wrapper {
    text-align: center;
    margin-bottom: 40px;
}

.hchg-cover-img img {
    max-width: 500px;
    width: 100%;
    height: auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    border: 1px solid #ddd;
    margin: 0 auto;
    display: block;
}

.hchg-caption {
    font-size: 1.1rem;
    font-style: italic;
    color: #444;
    margin: 15px auto 0;
    max-width: 600px;
    line-height: 1.4;
}

.hchg-journal-info {
    text-align: center;
    margin-bottom: 50px;
}

.hchg-journal-info h2 {
    font-size: 2.2rem;
    margin-bottom: 5px;
    color: #004b87;
}

.hchg-pub-date {
    font-weight: bold;
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 20px;
}

.hchg-journal-desc {
    max-width: 800px;
    margin: 0 auto;
    text-align: left;
    font-size: 1.1rem;
}

.hchg-contents {
    background: #f9f9f9;
    padding: 30px;
    margin-bottom: 60px;
    border: 1px solid #eee;
}

.hchg-contents h3 {
    margin-top: 0;
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
    text-transform: uppercase;
}

.hchg-contents ul {
    list-style: none;
    padding-left: 0;
}

.hchg-contents li {
    margin-bottom: 10px;
    font-size: 1.1rem;
    font-weight: bold;
}

.hchg-contents a {
    text-decoration: none;
    color: #004b87;
}

.single-article-block {
    margin-bottom: 120px;
    padding-top: 60px;
    border-top: 1px solid #ddd;
}

.single-article-block h2 {
    font-size: 2.5rem;
    margin-bottom: 5px;
    color: #111;
}

.article-author {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 25px;
    font-style: italic;
}

.article-details {
    background: #fff;
    border-left: 4px solid #004b87;
    padding: 10px 20px;
    margin-bottom: 30px;
    font-size: 1.1rem;
    font-style: italic;
    color: #444;
}

.article-main-content {
    font-size: 1.25rem;
    margin-bottom: 40px;
}

.article-source-notes {
    background: #f4f4f4;
    padding: 20px;
    font-size: 1rem;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
    margin-bottom: 20px;
}

.article-source-notes strong {
    display: block;
    margin-bottom: 5px;
    text-transform: uppercase;
    font-size: 0.85rem;
    color: #777;
}

/* Associated Event Styles */

.associated-event-box {
    background: #eef4f9;
    border: 1px solid #c9d6e0;
    padding: 20px;
    margin-top: 20px;
    border-radius: 4px;
}

.associated-event-box h4 {
    margin-top: 0;
    color: #004b87;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
    margin-bottom: 15px;
    border-bottom: 1px solid #c9d6e0;
    padding-bottom: 5px;
}

.event-item {
    border-bottom: 1px dashed #c9d6e0;
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.event-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 0;
}

.event-meta span {
    display: block;
    margin-bottom: 4px;
    font-size: 1.1rem;
    color: #333;
}

.event-meta strong {
    color: #000;
}

/* Debug Box for Admin */

.hchg-admin-debug {
    background: #fff3f3;
    border: 1px dashed #d9534f;
    padding: 10px;
    margin: 10px 0;
    font-family: monospace;
    font-size: 12px;
}

.back-to-top {
    display: inline-block;
    margin-top: 20px;
    font-size: 0.9rem;
    color: #004b87;
    text-decoration: none;
    font-weight: bold;
}

.hchg-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 60px;
    padding: 30px 0;
    border-top: 2px solid #000;
    font-weight: bold;
}

@media (max-width: 850px) {
    .hchg-branding {
        flex-direction: column;
        text-align: center;
    }

    .hchg-brand-text h1 {
        font-size: 2rem;
    }
}


/* ---------------------------------------------------------
   Parish map pages and Google Maps-style explorer
--------------------------------------------------------- */

.hchg-parish-map-wrap,
.hchg-parish-single-wrap,
.hchg-parish-map-wrap * {
    box-sizing: border-box;
}

.hchg-parish-map-wrap,
.hchg-parish-single-wrap {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
    background: #eef1f0;
    overflow: hidden;
}

.hchg-parish-map-page,
.hchg-parish-single {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 48px 20px 72px;
    color: #222;
    box-sizing: border-box;
    overflow: visible;
}

.hchg-parish-map-header,
.hchg-parish-single-header {
    max-width: 900px;
    margin: 0 auto 36px;
    text-align: center;
    border-bottom: 1px solid #e6e1d8;
    padding-bottom: 32px;
}

.hchg-parish-map-kicker {
    margin: 0 0 12px;
    font-size: 0.9rem;
    color: #6f665c;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
}

.hchg-parish-map-header h1,
.hchg-parish-single-header h1 {
    margin: 0;
    font-size: clamp(2rem, 5vw, 3.4rem);
    line-height: 1.08;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.hchg-parish-map-header p,
.hchg-parish-single-intro {
    max-width: 680px;
    margin: 18px auto 0;
    font-size: 1.08rem;
    line-height: 1.7;
    color: #444;
}

#hchg-map-status {
    margin-top: 0.75rem;
    font-size: 0.88rem;
    color: #666;
}


/* ---------------------------------------------------------
   Shared map shell
--------------------------------------------------------- */

.hchg-map-outer {
    position: relative;
    width: 100%;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
    background: transparent;
    padding: 0;
    border: none;
}

#hchg-parishes-map,
#hchg-single-parish-map,
.hchg-parish-map {
    display: block;
    width: 100%;
    height: 720px;
    min-height: 720px;
    max-width: 100%;
    visibility: visible;
    opacity: 1;
    position: relative;
    z-index: 1;
    border: none;
    border-radius: 18px;
    overflow: hidden;
    background: #e8e4d8 !important;
    box-sizing: border-box;
}

.hchg-parish-map--single {
    max-width: 980px;
    margin: 0 auto;
}

#hchg-parishes-map .leaflet-interactive:focus,
#hchg-parishes-map .leaflet-interactive:focus-visible,
#hchg-single-parish-map .leaflet-interactive:focus,
#hchg-single-parish-map .leaflet-interactive:focus-visible {
    outline: none !important;
}

.leaflet-container {
    font-family: inherit;
}

.leaflet-popup-content-wrapper {
    border-radius: 14px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.18);
}

.leaflet-popup-content {
    margin: 14px 16px;
}

.leaflet-control-zoom a {
    width: 32px !important;
    height: 32px !important;
    line-height: 32px !important;
    font-size: 18px !important;
}

.hchg-reset-control {
    width: auto !important;
    min-width: 34px;
    height: 34px;
    line-height: 32px;
    padding: 0 9px;
    background: #fff;
    border: 2px solid rgba(0, 0, 0, 0.2);
    border-radius: 4px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 700;
    color: #333;
    box-shadow: none;
}

.hchg-reset-control:hover {
    background: #f4f4f4;
}


/* ---------------------------------------------------------
   Loading overlay
--------------------------------------------------------- */

#hchg-map-loading,
.hchg-map-loading,
#hchg-map-loading.hchg-map-loading {
    position: absolute;
    inset: 0;
    z-index: 20;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: rgba(248, 248, 244, 0.92);
    border-radius: 0;
    font-size: 15px;
    font-weight: 600;
    color: #25342f;
    transition: opacity 0.28s ease;
}

#hchg-map-loading.hchg-fade-out,
.hchg-map-loading.hchg-fade-out {
    opacity: 0;
    pointer-events: none;
}

.hchg-spinner,
.hchg-map-loading .hchg-spinner,
.hchg-map-app .hchg-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(0, 0, 0, 0.12);
    border-top-color: #2f4f4f;
    border-radius: 999px;
    animation: hchg-spin 0.8s linear infinite;
}

@keyframes hchg-spin {
    to {
        transform: rotate(360deg);
    }
}

.hchg-loading-label {
    font-size: 0.8rem;
    color: #888;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}


/* ---------------------------------------------------------
   Parish polygons and tooltips
--------------------------------------------------------- */

.hchg-parish-polygon {
    cursor: pointer;
}

.hchg-parish-tooltip,
.leaflet-tooltip.hchg-parish-tooltip,
.hchg-place-marker-tooltip,
.leaflet-tooltip.hchg-place-marker-tooltip {
    background: rgba(30, 39, 35, 0.92);
    border: none !important;
    border-radius: 999px;
    padding: 0.45rem 0.75rem;
    font-size: 0.86rem;
    font-weight: 800;
    color: #fff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    pointer-events: none;
}

.hchg-parish-tooltip::before,
.hchg-place-marker-tooltip::before,
.leaflet-tooltip.hchg-parish-tooltip::before,
.leaflet-tooltip.hchg-place-marker-tooltip::before {
    display: none;
}


/* ---------------------------------------------------------
   Place markers
--------------------------------------------------------- */

.hchg-place-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.hchg-place-marker span {
    display: block;
    width: 18px;
    height: 18px;
    border: 3px solid #fff;
    border-radius: 999px;
    background: #555;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.35);
}

.hchg-place-marker--church span,
.hchg-place-marker--church-chapel span,
.hchg-place-marker--chapel span {
    background: #7a2e2e;
}

.hchg-place-marker--house span,
.hchg-place-marker--building span,
.hchg-place-marker--house-building span,
.hchg-place-marker--hall span,
.hchg-place-marker--manor span {
    background: #5b6f91;
}

.hchg-place-marker--farm span,
.hchg-place-marker--farmhouse span {
    background: #8a5a2b;
}

.hchg-place-marker--school span {
    background: #2f6f7c;
}

.hchg-place-marker--pub span,
.hchg-place-marker--inn span,
.hchg-place-marker--pub-inn span {
    background: #7a4f6d;
}

.hchg-place-marker--monument span,
.hchg-place-marker--memorial span,
.hchg-place-marker--monument-memorial span,
.hchg-place-marker--churchyard span,
.hchg-place-marker--cemetery span,
.hchg-place-marker--burial-ground span {
    background: #4c4c4c;
}

.hchg-place-marker--landscape span,
.hchg-place-marker--wood span,
.hchg-place-marker--woodland span,
.hchg-place-marker--landscape-woodland span {
    background: #4a7c59;
}

.hchg-place-marker--road span,
.hchg-place-marker--bridge span {
    background: #7b6f5b;
}


/* ---------------------------------------------------------
   Place popups
--------------------------------------------------------- */

.hchg-place-popup {
    min-width: 230px;
    max-width: 330px;
}

.hchg-place-popup h3 {
    margin: 0 0 8px;
    font-size: 1.05rem;
    line-height: 1.25;
}

.hchg-place-popup h3 a,
.hchg-place-popup a {
    color: #2f4f4f;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.hchg-place-popup-meta {
    margin: 0 0 10px;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
    color: #777;
}

.hchg-place-popup p {
    margin: 0 0 10px;
    font-size: 0.92rem;
    line-height: 1.45;
    color: #444;
}

.hchg-place-popup strong {
    display: block;
    margin: 12px 0 6px;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6f665c;
}

.hchg-place-popup ul {
    margin: 0;
    padding-left: 18px;
}

.hchg-place-popup li {
    margin-bottom: 6px;
    font-size: 0.92rem;
    line-height: 1.35;
}

.hchg-place-popup-link {
    margin-top: 12px !important;
    padding-top: 10px;
    border-top: 1px solid #e6e1d8;
}


/* ---------------------------------------------------------
   Main full-screen parish explorer
--------------------------------------------------------- */

.hchg-map-app {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 680px;
    overflow: hidden;
    background: #eef1f0;
}

body.admin-bar .hchg-map-app {
    height: calc(100vh - 32px);
}

.hchg-map-app #hchg-parishes-map {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    max-width: none;
    z-index: 1;
    border: 0;
    border-radius: 0;
    overflow: hidden;
    background: #e8ece9 !important;
}

.hchg-map-app .hchg-reset-control {
    width: 42px !important;
    min-width: 42px;
    height: 42px;
    line-height: 42px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: #fff;
    color: #25342f;
    font-size: 22px;
    font-weight: 800;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    cursor: pointer;
}

.hchg-map-app .hchg-reset-control:hover {
    background: #f4f6f4;
}

.hchg-map-app .leaflet-control-zoom a {
    border-radius: 12px !important;
}


/* ---------------------------------------------------------
   Hide removed / decluttered UI
--------------------------------------------------------- */

.hchg-map-legend,
.hchg-marker-legend,
.hchg-map-top-bar,
.hchg-parish-pills,
.hchg-parish-pill,
.hchg-pill-dot {
    display: none !important;
}


/* ---------------------------------------------------------
   Left search and place panel
--------------------------------------------------------- */

.hchg-side-panel {
    position: absolute;
    top: 18px;
    left: 18px;
    bottom: 18px;
    z-index: 50;
    width: 390px;
    max-width: calc(100vw - 36px);
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.97);
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
    overflow: hidden;
    backdrop-filter: blur(14px);
    transition: transform 0.24s ease, opacity 0.24s ease;
}

.hchg-map-app.hchg-panel-collapsed .hchg-side-panel {
    transform: translateX(calc(-100% - 24px));
    opacity: 0;
    pointer-events: none;
}

.hchg-panel-reopen {
    position: absolute;
    top: 18px;
    left: 18px;
    z-index: 55;
    display: none;
    align-items: center;
    gap: 8px;
    height: 46px;
    padding: 0 15px;
    border: 0;
    border-radius: 999px;
    background: #fff;
    color: #25342f;
    font-weight: 800;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
    cursor: pointer;
}

.hchg-map-app.hchg-panel-collapsed .hchg-panel-reopen {
    display: inline-flex;
}

.hchg-panel-top {
    padding: 14px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.hchg-panel-handle {
    display: none;
    width: 44px;
    height: 5px;
    margin: 0 auto 10px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.18);
}

.hchg-search-row {
    display: flex;
    align-items: center;
    gap: 9px;
}

.hchg-place-search-wrap,
.hchg-side-panel .hchg-place-search-wrap {
    position: relative;
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
}

.hchg-side-panel .hchg-place-search-wrap::before {
    content: "⌕";
    position: absolute;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    color: #68736d;
    font-size: 18px;
    line-height: 1;
    pointer-events: none;
}

#hchg-place-search,
.hchg-side-panel #hchg-place-search {
    width: 100%;
    height: 48px;
    padding: 0 14px 0 42px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    background: #f8faf8;
    font-size: 14px;
    color: #17211d;
    outline: none;
    box-sizing: border-box;
}

#hchg-place-search:focus,
.hchg-side-panel #hchg-place-search:focus {
    background: #fff;
    border-color: #2f4f4f;
    box-shadow: 0 0 0 3px rgba(47, 79, 79, 0.13);
    outline: none;
}

.hchg-near-me-button {
    border: 0;
    border-radius: 999px;
    padding: 0 14px;
    min-height: 42px;
    font-weight: 700;
    cursor: pointer;
    background: #25342f;
    color: #fff;
    white-space: nowrap;
}

.hchg-near-me-button:hover,
.hchg-near-me-button:focus {
    background: #111c18;
    outline: none;
}

.hchg-panel-icon-button {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: #f1f3f1;
    color: #25342f;
    font-size: 20px;
    font-weight: 800;
    cursor: pointer;
}

.hchg-panel-icon-button:hover {
    background: #e4e9e5;
}

.hchg-panel-body {
    flex: 1 1 auto;
    overflow: auto;
    padding: 0;
}

.hchg-panel-section {
    padding: 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.hchg-panel-section:last-child {
    border-bottom: 0;
}

.hchg-panel-kicker {
    margin: 0 0 5px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #6d776f;
}

.hchg-panel-title {
    margin: 0;
    font-size: 22px;
    line-height: 1.12;
    color: #18251f;
}

.hchg-panel-copy {
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 1.48;
    color: #52605a;
}


/* ---------------------------------------------------------
   Search results and cards
--------------------------------------------------------- */

.hchg-search-results,
.hchg-side-panel .hchg-search-results {
    display: grid;
    grid-template-columns: 1fr;
    gap: 9px;
}

.hchg-search-empty,
.hchg-side-panel .hchg-search-empty {
    margin: 0;
    padding: 13px 14px;
    border-radius: 16px;
    background: #f5f6f3;
    color: #5d6862;
    font-size: 13px;
    line-height: 1.4;
}

.hchg-search-result-card,
.hchg-side-panel .hchg-search-result-card {
    padding: 12px 13px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-left: 5px solid #2f4f4f;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.07);
    cursor: pointer;
    box-sizing: border-box;
    transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}

.hchg-search-result-card:hover,
.hchg-search-result-card:focus,
.hchg-search-result-card.hchg-search-result-active,
.hchg-side-panel .hchg-search-result-card:hover,
.hchg-side-panel .hchg-search-result-card:focus,
.hchg-side-panel .hchg-search-result-card.hchg-search-result-active {
    transform: translateY(-1px);
    box-shadow: 0 9px 24px rgba(0, 0, 0, 0.12);
    background: #fbfcfb;
    outline: none;
}

.hchg-search-result-card h3,
.hchg-side-panel .hchg-search-result-card h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    font-size: 15px;
    line-height: 1.25;
    color: #16241d;
}

.hchg-search-result-card h3 a,
.hchg-side-panel .hchg-search-result-card h3 a {
    color: inherit;
    text-decoration: none;
}

.hchg-search-result-card h3 a:hover,
.hchg-side-panel .hchg-search-result-card h3 a:hover {
    color: #2f4f4f;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.hchg-search-result-dot,
.hchg-side-panel .hchg-search-result-dot {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    flex: 0 0 auto;
    box-shadow: 0 0 0 2px #fff, 0 1px 4px rgba(0, 0, 0, 0.22);
}

.hchg-search-result-meta,
.hchg-side-panel .hchg-search-result-meta {
    margin-top: 5px;
    font-size: 12px;
    font-weight: 700;
    color: #66726c;
    text-transform: none;
    letter-spacing: 0;
}

.hchg-search-result-card p,
.hchg-side-panel .hchg-search-result-card p {
    margin: 8px 0 0;
    font-size: 13px;
    line-height: 1.42;
    color: #46534d;
}

.hchg-search-result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 10px;
    align-items: center;
}

.hchg-search-result-actions a {
    font-size: 12px;
    font-weight: 800;
    color: #25342f;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.hchg-result-subheading,
.hchg-side-panel .hchg-result-subheading {
    margin: 6px 0 2px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #6d776f;
}

.hchg-article-result-card,
.hchg-person-result-card,
.hchg-nearby-place-card,
.hchg-near-me-place-card {
    cursor: pointer;
}


/* ---------------------------------------------------------
   Selected place / person information panel
--------------------------------------------------------- */

.hchg-place-info-panel,
.hchg-side-panel .hchg-place-info-panel {
    margin: 0;
    padding: 16px;
    border: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    max-height: none;
    overflow: visible;
    scroll-margin-top: 0;
}

.hchg-place-info-panel[hidden] {
    display: none !important;
}

.hchg-place-info-panel:focus,
.hchg-side-panel .hchg-place-info-panel:focus {
    outline: none;
}

.hchg-place-info-card,
.hchg-side-panel .hchg-place-info-card {
    display: block;
    width: 100%;
    padding: 0;
}

.hchg-place-info-card--empty,
.hchg-side-panel .hchg-place-info-card--empty {
    color: #666;
}

.hchg-place-info-header,
.hchg-side-panel .hchg-place-info-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin: 0;
    padding: 0;
    border: 0;
}

.hchg-place-info-kicker {
    margin: 0 0 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.72rem;
    font-weight: 700;
    color: #777;
}

.hchg-place-info-card h2 {
    margin: 0 0 0.6rem;
    font-size: 1.45rem;
    line-height: 1.18;
}

.hchg-place-info-meta,
.hchg-side-panel .hchg-place-info-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 10px;
}

.hchg-place-info-meta span,
.hchg-side-panel .hchg-place-info-meta span,
.hchg-place-parish-pill,
.hchg-side-panel .hchg-place-parish-pill {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 4px 9px;
    border: 0;
    border-radius: 999px;
    background: #eef2ee;
    color: #41504a;
    font-size: 12px;
    font-weight: 800;
    text-transform: none;
    letter-spacing: 0;
    font-family: inherit;
    line-height: 1.2;
}

.hchg-place-parish-pill,
.hchg-side-panel .hchg-place-parish-pill {
    cursor: pointer;
}

.hchg-place-parish-pill:hover,
.hchg-place-parish-pill:focus,
.hchg-side-panel .hchg-place-parish-pill:hover,
.hchg-side-panel .hchg-place-parish-pill:focus {
    background: #e0e7e1;
    outline: none;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.hchg-place-info-main-link,
.hchg-side-panel .hchg-place-info-main-link,
.hchg-navigate-link {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 11px;
    border-radius: 999px;
    background: #25342f;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: none;
}

.hchg-place-info-main-link:hover,
.hchg-place-info-main-link:focus,
.hchg-navigate-link:hover,
.hchg-navigate-link:focus {
    background: #1d2925;
    color: #fff;
    text-decoration: none;
    transform: none;
    box-shadow: none;
    outline: none;
}

.hchg-place-info-notes,
.hchg-side-panel .hchg-place-info-notes {
    margin-top: 14px;
    padding: 13px;
    border: 0;
    border-radius: 16px;
    background: #f5f7f5;
}

.hchg-place-info-notes p,
.hchg-side-panel .hchg-place-info-notes p {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: #34433d;
}

.hchg-place-info-related {
    margin-top: 1.25rem;
}

.hchg-place-info-related h3 {
    margin: 0 0 0.75rem;
    font-size: 1.05rem;
    color: #222;
}

.hchg-place-info-article-grid {
    display: grid;
    gap: 8px;
}

.hchg-place-info-article {
    display: block;
    padding: 0.75rem 0.85rem;
    border-radius: 12px;
    background: #faf8f2;
    border: 1px solid #ece7dc;
    color: #2f4f4f;
    font-weight: 700;
    text-decoration: none;
    line-height: 1.35;
}

.hchg-place-info-article:hover,
.hchg-place-info-article:focus {
    background: #fff;
    text-decoration: underline;
    text-underline-offset: 3px;
    outline: none;
}

.hchg-person-back-pill {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 4px 9px;
    border: 0;
    border-radius: 999px;
    background: #eef2ee;
    color: #41504a;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    font-family: inherit;
    line-height: 1.2;
}

.hchg-person-back-pill:hover,
.hchg-person-back-pill:focus {
    background: #e0e7e1;
    outline: none;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.hchg-person-back-pill--place,
.hchg-person-back-pill--parish {
    background: #eef2ee;
    color: #41504a;
}


/* ---------------------------------------------------------
   Article reader panel
--------------------------------------------------------- */

.hchg-article-panel {
    position: absolute;
    top: 18px;
    right: 18px;
    bottom: 18px;
    z-index: 54;
    width: 480px;
    max-width: calc(100vw - 36px);
    background: rgba(255, 255, 255, 0.98);
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.24);
    overflow: hidden;
    backdrop-filter: blur(14px);
}

.hchg-map-app.hchg-article-expanded .hchg-article-panel {
    width: min(880px, calc(100vw - 96px));
}

.hchg-map-app.hchg-article-expanded.hchg-panel-collapsed .hchg-article-panel {
    right: 24px;
}

.hchg-article-panel[hidden] {
    display: none !important;
}

.hchg-article-panel-inner {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.hchg-article-panel-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.hchg-article-panel-top .hchg-panel-kicker {
    margin: 0;
}

.hchg-article-content {
    flex: 1 1 auto;
    overflow: auto;
    padding: 22px;
}

.hchg-article-content:focus {
    outline: none;
}

.hchg-article-reader-title {
    margin: 0;
    font-size: 30px;
    line-height: 1.12;
    color: #18251f;
}

.hchg-article-reader-header {
    margin-bottom: 18px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.hchg-article-reader-body {
    font-size: 16px;
    line-height: 1.72;
    color: #24342e;
}

.hchg-article-reader-body p {
    margin: 0 0 1em;
}

.hchg-article-reader-body img {
    max-width: 100%;
    height: auto;
    border-radius: 14px;
}

.hchg-article-reader-body figure {
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
}

.hchg-article-reader-source-notes,
.hchg-article-reader-links {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.hchg-article-reader-source-notes h3,
.hchg-article-reader-links h3,
.hchg-article-reader-link-group h4 {
    margin: 0 0 10px;
    color: #18251f;
}

.hchg-article-reader-source-notes h3,
.hchg-article-reader-links h3 {
    font-size: 18px;
}

.hchg-article-reader-link-group {
    margin-top: 14px;
}

.hchg-article-reader-link-group h4 {
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #6d776f;
}

.hchg-linked-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hchg-linked-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 6px 10px;
    border: 0;
    border-radius: 999px;
    background: #eef2ee;
    color: #25342f;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
    font-family: inherit;
}

.hchg-linked-chip:hover,
.hchg-linked-chip:focus {
    background: #e0e7e1;
    outline: none;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.hchg-article-reader-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.hchg-article-reader-close-inline,
.hchg-read-article-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 11px;
    border: 0;
    border-radius: 999px;
    background: #eef2ee;
    color: #25342f;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
    font-family: inherit;
}

.hchg-article-reader-close-inline:hover,
.hchg-read-article-button:hover,
.hchg-article-reader-close-inline:focus,
.hchg-read-article-button:focus {
    background: #e0e7e1;
    outline: none;
}


/* ---------------------------------------------------------
   Accessibility
--------------------------------------------------------- */

.screen-reader-text {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}


/* ---------------------------------------------------------
   Responsive parish map styles
--------------------------------------------------------- */

@media (max-width: 900px) {
    .hchg-map-app {
        height: 100vh;
        min-height: 620px;
    }

    body.admin-bar .hchg-map-app {
        height: calc(100vh - 46px);
    }

    .hchg-side-panel {
        top: auto;
        left: 10px;
        right: 10px;
        bottom: 10px;
        width: auto;
        max-width: none;
        height: 44vh;
        min-height: 235px;
        max-height: 78vh;
        border-radius: 24px;
    }

    .hchg-panel-handle {
        display: block;
    }

    .hchg-map-app.hchg-panel-collapsed .hchg-side-panel {
        transform: translateY(calc(100% + 24px));
    }

    .hchg-panel-reopen {
        top: auto;
        left: 50%;
        bottom: 16px;
        transform: translateX(-50%);
    }

    .hchg-map-app .leaflet-control-container .leaflet-bottom.leaflet-right {
        bottom: 84px;
    }

    .hchg-side-panel .hchg-place-info-header,
    .hchg-place-info-header {
        display: block;
    }

    .hchg-side-panel .hchg-place-info-main-link,
    .hchg-place-info-main-link,
    .hchg-navigate-link {
        margin-top: 12px;
        width: 100%;
        box-sizing: border-box;
    }

    .hchg-article-panel,
    .hchg-map-app.hchg-article-expanded .hchg-article-panel {
        top: auto;
        left: 10px;
        right: 10px;
        bottom: 10px;
        width: auto;
        max-width: none;
        height: 78vh;
        border-radius: 24px;
        z-index: 70;
    }

    .hchg-article-reader-title {
        font-size: 22px;
    }

    .hchg-article-content {
        padding: 18px;
    }
}

@media (max-width: 700px) {
    .hchg-parish-map-header,
    .hchg-parish-single-header {
        text-align: left;
    }

    .hchg-parish-map-header p,
    .hchg-parish-single-intro {
        margin-left: 0;
        margin-right: 0;
    }

    .hchg-search-row {
        align-items: stretch;
        flex-wrap: wrap;
    }

    .hchg-near-me-button {
        width: 100%;
    }
}

@media (max-width: 560px) {
    #hchg-single-parish-map,
    .hchg-parish-map {
        height: 480px;
        min-height: 480px;
        border-radius: 14px;
    }

    .hchg-map-outer {
        border-radius: 14px;
    }

    .hchg-side-panel {
        left: 8px;
        right: 8px;
        bottom: 8px;
    }

    .hchg-panel-section,
    .hchg-place-info-panel,
    .hchg-side-panel .hchg-place-info-panel {
        padding: 14px;
    }
}


/* ---------------------------------------------------------
   Nearby places cards
--------------------------------------------------------- */

.hchg-nearby-place-card:hover,
.hchg-near-me-place-card:hover {
    background: #f6faf7;
}

.hchg-nearby-place-card:focus,
.hchg-near-me-place-card:focus {
    outline: 2px solid rgba(47, 79, 79, 0.2);
    outline-offset: 2px;
}

.hchg-place-parish-pill {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 4px 9px;
    border: 0;
    border-radius: 999px;
    background: #eef2ee;
    color: #41504a;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    font-family: inherit;
    line-height: 1.2;
}

.hchg-place-parish-pill:hover,
.hchg-place-parish-pill:focus {
    background: #e0e7e1;
    outline: none;
    text-decoration: underline;
    text-underline-offset: 3px;
}


/* ---------------------------------------------------------
   Global smooth scrolling
--------------------------------------------------------- */

html {
    scroll-behavior: smooth;
}