/* =========================================================
   HAAMines — Consolidated custom.css
========================================================= */

/* =========================================================
   1. ROOT VARIABLES
========================================================= */

:root {
    --space-xs: 0.25rem;
    --space-s: 0.5rem;
    --space-m: 1rem;
    --space-l: 1.5rem;
    --space-xl: 2rem;

    --text-main: #444;
    --text-muted: #666;
    --rule-light: rgba(0, 0, 0, 0.12);

    --page-max-width: 1200px;
    --page-side-padding: 28px;
}

html {
    scrollbar-gutter: stable;
}

html,
body {
    height: 100%;
}

/* =========================================================
   2. GLOBAL TYPOGRAPHY
========================================================= */

body {
    font-family: Arial, sans-serif;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-main);
    margin: 0;
    padding: 0;
}

.prose,
.site-section p,
.site-history,
.site-overview,
.site-sources {
    max-width: none;
    line-height: 1.6;
}

/* =========================================================
   3. LAYOUT PRIMITIVES
========================================================= */

.content-wrapper,
.page-shell {
    max-width: var(--page-max-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--page-side-padding);
    padding-right: var(--page-side-padding);
    width: 100%;
    box-sizing: border-box;
}

/* =========================================================
   4. BOOTSTRAP CONTAINER ALIGNMENT
========================================================= */

.page-index .container,
.page-index .container-sm,
.page-index .container-md,
.page-index .container-lg,
.page-index .container-xl,
.page-index .container-xxl {
    max-width: var(--page-max-width);
    padding-left: var(--page-side-padding);
    padding-right: var(--page-side-padding);
}

.page-shell .container,
.page-shell .container-sm,
.page-shell .container-md,
.page-shell .container-lg,
.page-shell .container-xl,
.page-shell .container-xxl {
    padding-left: 0;
    padding-right: 0;
}

/* =========================================================
   5. GLOBAL HEADER BASE
========================================================= */

.site-header {
    position: relative;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    color: #fff;
    margin-bottom: 0;
}

/* =========================================================
   6. MEDIA / PHOTO DATE
========================================================= */

.media-photo-box {
    position: relative;
}

.media-photo-date {
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 2;
    padding: 0.3rem 0.55rem;
    font-size: 0.78rem;
    line-height: 1.2;
    color: rgba(255, 255, 255, 0.96);
    background: rgba(0, 0, 0, 0.5);
    border-radius: 0.35rem;
    text-shadow: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* =========================================================
   7. PAGE TOOLBAR + IN-PAGE SECTION NAV
========================================================= */

/* Base toolbar */
.page-toolbar {
    position: static;
    background: transparent;
}

/* Sticky toolbar on desktop only */
@media (min-width: 992px) {
    .page-toolbar {
        position: sticky;
        top: 0;
        z-index: 1020;
        background: #fff;
        padding-top: 0.2rem;
        padding-bottom: 0.45rem;
        margin-bottom: 0.6rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.08);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    }
}

/* Shared toolbar button sizing */
.page-toolbar .toolbar-btn,
.page-toolbar .toolbar-select,
.page-toolbar .toolbar-sort-label,
.page-toolbar .btn-primary {
    min-height: 2.1rem;
    height: 2.1rem;
    box-sizing: border-box;
    font-size: 0.88rem;
    line-height: 1.2;
}

/* Secondary toolbar button */
.page-toolbar .toolbar-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.72rem;
    background: #dfe4e8;
    border: 1px solid #b5bcc3;
    color: #2f3438;
}

.page-toolbar .toolbar-btn:hover,
.page-toolbar .toolbar-btn:focus {
    background: #d2d9de;
    border-color: #a7afb7;
    color: #1f2326;
}

.page-toolbar .toolbar-btn i {
    vertical-align: -0.08em;
}

/* Sort label */
.page-toolbar .toolbar-sort-label {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.72rem;
    background: #dfe4e8;
    border: 1px solid #b5bcc3;
    color: #2f3438;
    border-radius: 0.25rem;
    white-space: nowrap;
}

/* Selects */
.page-toolbar .toolbar-select {
    background-color: #dfe4e8;
    border: 1px solid #b5bcc3;
    color: #2f3438;
    min-width: 190px;
    padding: 0.35rem 2rem 0.35rem 0.72rem;
}

.page-toolbar .toolbar-select:focus {
    border-color: #a7afb7;
    box-shadow: none;
}

/* Primary buttons inside toolbar */
.page-toolbar .btn-primary {
    padding: 0.35rem 0.72rem;
    display: inline-flex;
    align-items: center;
}

/* Results page spacing tweak */
.page-results-list .page-toolbar,
.page-results-map .page-toolbar {
    margin-top: 0.35rem;
    margin-bottom: 0.7rem;
}

/* Toolbar split layout */
.page-toolbar-inner {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem 1.25rem;
    flex-wrap: wrap;
}

/* Left-side in-page section nav */
.page-sections-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem 0.6rem;
    min-width: 0;
}

.page-sections-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #6c757d;
    margin-right: 0.15rem;
}

.page-sections-link {
    display: inline-block;
    padding: 0.3rem 0.65rem;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 999px;
    background: #f8f9fa;
    color: #495057;
    text-decoration: none;
    font-size: 0.9rem;
    line-height: 1.2;
}

.page-sections-link:hover,
.page-sections-link:focus {
    background: #e9ecef;
    border-color: rgba(0, 0, 0, 0.14);
    color: #212529;
    text-decoration: none;
}

/* Right-side action buttons */
.page-toolbar-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-left: auto;
}

/* Anchor offset for section jumps */
.site-section {
    scroll-margin-top: 7rem;
}

#site-top {
    scroll-margin-top: 0;
}

/* =========================================================
   8. STANDARD HEADER (SEARCH / LIST / MAP PAGES)
========================================================= */

.page-index .site-header {
    background-image: url("/assets/header-mine.png");
    background-repeat: no-repeat;
    background-size: cover;
    background-position: 55% 68%;
    padding-top: 1.1rem;
    padding-bottom: 1rem;
}

.page-index .site-header::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.55),
        rgba(0, 0, 0, 0.30)
    );
    z-index: 0;
}

.page-index .site-header > * {
    position: relative;
    z-index: 1;
}

.page-index .site-header .header-inner {
    max-width: var(--page-max-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--page-side-padding);
    padding-right: var(--page-side-padding);
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 1rem;
    box-sizing: border-box;
}

.page-index .site-header .header-left {
    transform: none !important;
    flex: 0 0 auto;
}

.page-index .site-header .header-right {
    flex: 1 1 auto;
    display: flex;
    justify-content: flex-end;
}

.page-index .site-header,
.page-index .site-header * {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
}

.page-index .site-header .site-title {
    font-size: 1.55rem;
    font-weight: 600;
    line-height: 1.25;
    margin-bottom: var(--space-xs);
}

.page-index .site-header .site-location-text {
    font-size: 0.9rem;
    line-height: 1.35;
    opacity: 0.9;
    margin: 0;
}

.page-index .site-header .site-header-summary,
.page-index .site-header .haa-context {
    font-size: 0.9rem;
    line-height: 1.4;
    opacity: 0.92;
}

.page-index .project-summary-title-link {
    display: inline-flex;
    align-items: center;
    margin-left: 0.35rem;
    color: inherit;
    text-decoration: none;
    opacity: 0.75;
    vertical-align: middle;
}

.page-index .project-summary-title-link:hover,
.page-index .project-summary-title-link:focus {
    opacity: 1;
    color: inherit;
}

.page-index .project-summary-title-link i {
    font-size: 0.9em;
    line-height: 1;
}

/* =========================================================
   9. INDEX HEADER WORDMARK
========================================================= */

.page-index .site-header .haa-wordmark {
    display: inline-flex;
    align-items: flex-start;
    line-height: 1.15;
}

.page-index .site-header .haa-core {
    font-size: 2.15rem;
    font-weight: 500;
    line-height: 1;
    letter-spacing: 0.02em;
    color: #fff;
    white-space: nowrap;
}

.page-index .site-header .haa-sup {
    color: #66bb6a;
}

.page-index .site-header .haa-brand-text {
    text-align: right;
    line-height: 1.15;
}

.page-index .site-header .page-title {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
    line-height: 1.1;
}

.page-index .site-header .haa-strapline {
    margin-top: 0.2rem;
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    opacity: 0.88;
    text-transform: lowercase;
    line-height: 1.15;
}

/* =========================================================
   10. SITE HERO HEADER
========================================================= */

.page-site .site-header {
    overflow: hidden;
    background-position: center 65%;
    background-size: cover;
    padding-top: 1rem;
    padding-bottom: 0.9rem;
    padding-left: 0;
    padding-right: 0;
    margin-bottom: 1rem;
}

.page-site .site-header::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 0;
    pointer-events: none;
}

.page-site .site-header.no-hero-photo::before {
    background: rgba(0, 0, 0, 0.52);
}

.page-site .site-header > * {
    position: relative;
    z-index: 1;
}

.page-site .site-header,
.page-site .site-header * {
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
}

.page-site .site-header .header-inner {
    max-width: var(--page-max-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--page-side-padding);
    padding-right: var(--page-side-padding);
    width: 100%;
    box-sizing: border-box;
}

.page-site .site-header .header-left {
    display: block;
    width: 100%;
    min-width: 0;
}

.page-site .site-header .site-title {
    display: block;
    width: 100%;
    margin: 0 0 0.1rem 0;
    font-size: 1.65rem;
    font-weight: 600;
    line-height: 1.2;
}

.page-site .site-header .site-title-main {
    display: inline;
}

.page-site .site-header .site-location-inline {
    font-size: 0.62em;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.3;
}

.page-site .site-header .site-id {
    font-size: 0.85em;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
}

.page-site .site-header .site-location-text {
    display: block;
    width: 100%;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.35;
    opacity: 0.9;
}

.page-site .site-header .site-mining-region-text {
    display: block;
    width: 100%;
    margin: var(--space-xs) 0 0 0;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    opacity: 0.95;
}

.page-site .site-header-summary {
    display: block;
    width: 100%;
    max-width: none;
    margin-top: 0.1rem;
    font-size: 0.85rem;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.88);
}

.page-site .site-character-header {
    display: block;
    width: 100%;
    margin-top: 0.15rem;
    text-align: right;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.85);
}

.page-site .site-character-header .site-character-value {
    font-style: italic;
}

.page-site .site-header + .content-wrapper {
    margin-top: var(--space-m);
}

.page-site .site-header .site-wordmark {
    display: inline-flex;
    align-items: flex-start;
    margin: 0 0 0.45rem 0;
    line-height: 1;
}

.page-site .site-header .haa-core {
    font-size: 1.5rem;
    font-weight: 500;
    line-height: 1;
    letter-spacing: 0.02em;
    color: #fff;
    white-space: nowrap;
}

.page-site .site-header .haa-sup {
    color: #66bb6a;
}

/* =========================================================
   11. FILTER SUMMARY / META
========================================================= */

.filter-info {
    margin-top: 0;
    margin-bottom: 0.5rem;
    padding: 0.4rem 0.6rem;
    font-size: 0.9rem;
}

.alert.filter-info {
    margin-bottom: 0.5rem;
}

.results-summary {
    font-size: 0.8rem;
    color: #777;
    margin-bottom: var(--space-xs);
}

/* =========================================================
   12. RESULTS LIST
========================================================= */

.result-list {
    font-size: 0.95rem;
}

.result-item {
    padding: 0.7rem 0;
    border-bottom: 1px solid #ddd;
}

.result-item:first-child {
    border-top: 1px solid #ddd;
}

.result-title-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
}

.result-title-link {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    color: #0d6efd;
    text-decoration: none;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.result-title-link:hover {
    text-decoration: underline;
}

.result-title-side {
    display: inline-flex;
    align-items: baseline;
    gap: 0.5rem;
    flex: 0 1 auto;
    min-width: 0;
    text-align: right;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.result-char {
    line-height: 1.3;
}

.result-camera {
    flex: 0 0 auto;
}

.result-desc {
    margin-top: 0.15rem;
}

.result-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    margin-top: 0.15rem;
    font-size: 0.875rem;
    color: #6c757d;
}

.result-meta-left {
    min-width: 0;
    flex: 1 1 auto;
    overflow-wrap: anywhere;
}

.result-output {
    flex: 0 0 auto;
    text-align: right;
}

.output-tag {
    display: inline-block;
    padding: 1px 7px;
    font-size: 0.8rem;
    line-height: 1.3;
    border: 1px solid #c9ced3;
    background: #eef1f3;
    color: #495057;
    border-radius: 2px;
}

/* =========================================================
   13. SITE SECTIONS
========================================================= */

.site-section {
    margin: var(--space-l) 0;
}

.site-section h2 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: var(--space-s);
    padding-bottom: var(--space-xs);
    border-bottom: 1px solid var(--rule-light);
}

.page-site .content-wrapper > .site-section:first-of-type {
    margin-top: var(--space-s);
}

/* =========================================================
   14. MAP + IMAGE SPLIT
========================================================= */

.site-map-image {
    margin: var(--space-xl) 0;
}

.media-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-m);
    align-items: stretch;
}

.media-box {
    position: relative;
    height: 360px;
    background: #eee;
    border-radius: 6px;
    overflow: hidden;
}

.media-box-wide {
    width: 100%;
}

.media-box #map,
.media-box .leaflet-container {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.media-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.media-box .muted {
    padding: var(--space-m);
    font-size: 0.85rem;
    color: #666;
}

/* =========================================================
   15. OVERVIEW + CONTEXT MAP
========================================================= */

.overview-split {
    display: grid;
    grid-template-columns: 3fr 1.4fr;
    gap: var(--space-m);
    align-items: start;
}

.overview-map {
    position: relative;
}



#overview-map {
    position: relative !important;
    inset: auto !important;
    width: 100% !important;
    height: 100% !important;
    display: block !important;
}

.overview-map-caption {
    display: block;
    position: relative !important;
    z-index: 5 !important;
}

/* =========================================================
   16. SETTING & SURROUNDINGS
========================================================= */

.site-setting {
    margin-top: var(--space-m);
    padding-top: var(--space-s);
    border-top: 1px solid var(--rule-light);
}

.site-setting-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0 0 var(--space-xs) 0;
    color: #222;
}

.site-setting-text {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-main);
    max-width: none;
}

/* =========================================================
   17. GALLERY
========================================================= */

.site-gallery {
    margin: var(--space-xl) 0;
}

.site-gallery .gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: var(--space-s);
}

.site-gallery .gallery a {
    display: block;
}

.site-gallery .gallery img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    background: #eee;
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-radius: 4px;
    display: block;
}

.site-gallery h2::after {
    content: " (click to enlarge)";
    font-weight: normal;
    font-size: 0.85em;
    color: #777;
}


.site-header-bottom-row {
    margin-top: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.site-header-bottom-left {
    min-width: 0;
}

.site-header-bottom-right {
    margin-left: auto;
}

.site-header-links {
    font-size: 0.75rem;
    line-height: 1.4;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.55rem;
    align-items: center;
}

.site-header-link,
.site-header-link:visited {
    color: #fff;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.14em;
    font-weight: 500;
}

.site-header-link:hover,
.site-header-link:focus {
    color: #fff;
    text-decoration: underline;
    text-decoration-thickness: 2px;
}

.site-header-link i {
    opacity: 0.95;
}

.site-header-link-sep {
    color: rgba(255,255,255,0.8);
}


.overview-map-canvas {
    position: relative;
    width: 100%;
    height: 220px;
    margin: 0;
    padding: 0;
    background: #fff;
    border: 1px solid #d7d7d7;
    border-radius: 0.35rem;
    overflow: hidden;
    line-height: 0;
}

#overview-country-map {
    width: 100%;
    height: 100%;
    display: block;
    margin: 0;
    padding: 0;
}

@media (max-width: 991.98px) {
    .overview-split {
        display: flex;
        flex-direction: column;
    }

    .overview-map {
        order: -1;
        width: 100%;
        margin-bottom: 1rem;
    }

    .overview-map-canvas {
        height: 180px;
    }
}


/* =========================================================
   18. SOURCES / SUPPORTING SECTION
========================================================= */

.site-sources-muted {
    margin-top: 2.5rem;
    padding: 1.25rem 1.5rem;
    background: #f8f9fa;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 0.5rem;
}

.site-sources-muted h2 {
    font-size: 1.05rem;
    margin-bottom: 0.85rem;
    color: #495057;
}

.site-sources-muted .prose {
    font-size: 0.95rem;
    line-height: 1.65;
    color: #5c6770;
}

.site-sources-muted .prose p:last-child,
.site-sources-muted .prose br:last-child {
    margin-bottom: 0;
}

/* =========================================================
   19. FOOTER
========================================================= */

.site-footer {
    border-top: 1px solid #cfd5db;
    margin-top: 1.5rem;
    padding: 0.2rem 0 1.1rem;
    font-size: 0.84rem;
    color: #555;
    background: #fff;
}

.site-footer .footer-text p {
    margin: 0 0 0.45rem 0;
    line-height: 1.5;
}

.site-footer .footer-text p:last-child {
    margin-bottom: 0;
}

.site-footer .haa-sup {
    font-size: 0.58em;
    vertical-align: super;
    position: relative;
    top: -0.08em;
    color: #66bb6a;
    letter-spacing: 0.01em;
}

.site-footer a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.site-footer a:hover {
    text-decoration-thickness: 2px;
}

/* =========================================================
   20. SIMPLE TIMELINE
========================================================= */

.site-timeline-block {
    margin: var(--space-xl) 0;
}

.site-timeline-block h2 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: var(--space-s);
    padding-bottom: var(--space-xs);
    border-bottom: 1px solid var(--rule-light);
}

.timeline-register {
    position: relative;
    display: grid;
    grid-template-columns: 7rem 1fr;
    column-gap: var(--space-m);
    row-gap: var(--space-s);
    max-width: 900px;
    padding-left: 1.5rem;
    font-size: 0.9rem;
    line-height: 1.5;
}

.timeline-register::before {
    content: "";
    position: absolute;
    left: 0.6rem;
    top: 0;
    bottom: 0;
    width: 1px;
    background: rgba(0, 0, 0, 0.15);
}

.timeline-register dt {
    position: relative;
    font-weight: 500;
    color: #333;
    white-space: nowrap;
}

.timeline-register dt::before {
    content: "";
    position: absolute;
    left: -1rem;
    top: 0.45em;
    width: 6px;
    height: 6px;
    background: #444;
    border-radius: 50%;
}

.timeline-register dd {
    margin: 0;
    color: var(--text-main);
}

.timeline-register dd strong {
    display: block;
    font-weight: 600;
    margin-bottom: 0.15rem;
    color: #222;
}

/* =========================================================
   21. HERITAGE TIMELINE
========================================================= */








.heritage-timeline-block {
    margin-top: 2.5rem;
}

.heritage-timeline {
    position: relative;
    margin-top: 1.25rem;
    padding-left: 0;
}

.heritage-timeline::before {
    content: "";
    position: absolute;
    left: 125px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, #8f887c 0%, #b9b2a5 45%, #d7d1c7 100%);
    opacity: 0.95;
}

.heritage-timeline-item {
    display: grid;
    grid-template-columns: 94px 34px minmax(0, 1fr);
    gap: 0 0.9rem;
    position: relative;
    margin-bottom: 1.5rem;
    align-items: start;
}

.heritage-timeline-date-col {
    padding-top: 0.2rem;
    text-align: right;
}

.heritage-year-plaque {
    display: inline-block;
    min-width: 0;
    padding: 0.34rem 0.6rem;
    border: 1px solid #b7ac99;
    border-radius: 4px;
    background: linear-gradient(to bottom, #f3eee4 0%, #e5dccd 100%);
    color: #3f372d;
    font-size: 0.84rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.65),
        0 2px 6px rgba(0, 0, 0, 0.05);
}

.heritage-timeline-spine-col {
    position: relative;
    min-height: 100%;
}

.heritage-timeline-dot {
    position: absolute;
    top: 0.9rem;
    left: 50%;
    width: 14px;
    height: 14px;
    transform: translateX(-50%);
    border-radius: 50%;
    background: #6f3f2a;
    border: 2px solid #f6f2ea;
    box-shadow: 0 0 0 3px rgba(111, 63, 42, 0.16);
    z-index: 2;
}

.heritage-timeline-content-col {
    min-width: 0;
}

.heritage-event-card {
    position: relative;
    background: linear-gradient(to bottom, #f9f6f0 0%, #f2ece2 100%);
    border: 1px solid #d6cdbf;
    border-left: 5px solid #8a5a3b;
    border-radius: 8px;
    padding: 1rem 1.1rem 0.95rem;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.7) inset,
        0 6px 16px rgba(0, 0, 0, 0.05);
}

.heritage-event-title {
    margin: 0 0 0.45rem;
    color: #2a241d;
    font-size: 1rem;
    line-height: 1.35;
    font-weight: 700;
}

.heritage-event-text {
    color: #4b443b;
    font-size: 0.92rem;
    line-height: 1.58;
}

.heritage-event-text p:last-child,
.heritage-event-text > *:last-child {
    margin-bottom: 0;
}

.heritage-event-meta {
    margin-bottom: 0.45rem;
}

.heritage-category-tab {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.72rem;
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border: 1px solid transparent;
}

.heritage-category-tab.cat-legislation {
    background: #e7e3ee;
    color: #5b516d;
    border-color: #d4cede;
}

.heritage-category-tab.cat-exploration {
    background: #e5ece7;
    color: #4d6354;
    border-color: #d1dbd4;
}

.heritage-category-tab.cat-planning {
    background: #ece7df;
    color: #6b5c49;
    border-color: #ddd3c7;
}

.heritage-category-tab.cat-construction {
    background: #efe4dc;
    color: #755641;
    border-color: #dfcfc3;
}

.heritage-category-tab.cat-operation {
    background: #e4eaed;
    color: #4e6169;
    border-color: #d0dadd;
}

.heritage-category-tab.cat-closure {
    background: #ece4e4;
    color: #6b5151;
    border-color: #ddd0d0;
}

.heritage-category-tab.cat-redevelopment {
    background: #e6ede6;
    color: #546854;
    border-color: #d3ddd3;
}

.heritage-category-tab.cat-heritage {
    background: #efe9dd;
    color: #6d5b3f;
    border-color: #dfd4c1;
}

.heritage-event-card.cat-legislation { border-left-color: #7a6a96; }
.heritage-event-card.cat-exploration { border-left-color: #6d8a72; }
.heritage-event-card.cat-planning { border-left-color: #8a7459; }
.heritage-event-card.cat-construction { border-left-color: #9a6d4d; }
.heritage-event-card.cat-operation { border-left-color: #65808b; }
.heritage-event-card.cat-closure { border-left-color: #8b6767; }
.heritage-event-card.cat-redevelopment { border-left-color: #6f866f; }
.heritage-event-card.cat-heritage { border-left-color: #9a8359; }

@media (hover: hover) {
    .heritage-event-card {
        transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    }

    .heritage-event-card:hover {
        transform: translateY(-1px);
        box-shadow:
            0 1px 0 rgba(255, 255, 255, 0.7) inset,
            0 10px 22px rgba(0, 0, 0, 0.08);
        border-color: #c8bda9;
    }
}

/* =========================================================
   22. CUSTOM MAP PINS / BADGES
========================================================= */

.custom-pin {
    position: relative;
    width: 28px;
    height: 40px;
}

.custom-pin svg {
    width: 100%;
    height: 100%;
    display: block;
}

.custom-pin .camera-badge {
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 11px;
    color: #ffffff;
    pointer-events: none;
}

.leaflet-tooltip.camera-badge {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin: 0;
    color: #111;
    font-size: 14px;
    line-height: 1;
}

.leaflet-tooltip.camera-badge:before {
    display: none;
}

/* =========================================================
   23. MAP COMPARE CONTROL
========================================================= */

.leaflet-control.aerial-compare {
    background: rgba(255, 255, 255, .9);
    padding: 6px 8px;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .18);
    font-size: 11px;
    line-height: 1.1;
    min-width: 150px;
    max-width: 170px;
}

.leaflet-control.aerial-compare .row1 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin-bottom: 0;
}

.leaflet-control.aerial-compare .toggle-btn {
    padding: 2px 7px;
    border: 1px solid rgba(0, 0, 0, .18);
    background: #fff;
    border-radius: 5px;
    cursor: pointer;
    font-size: 11px;
    line-height: 1.1;
}

.leaflet-control.aerial-compare .toggle-btn[aria-pressed="true"] {
    background: #e9f2ff;
    border-color: rgba(13, 110, 253, .45);
}

.leaflet-control.aerial-compare .compare-panel {
    margin-top: 5px;
}

.leaflet-control.aerial-compare input[type="range"] {
    width: 100%;
    margin: 0;
}

.leaflet-control.aerial-compare .labels {
    display: flex;
    justify-content: space-between;
    color: #666;
    margin-top: 2px;
    font-size: 10px;
}

/* =========================================================
   24. STANDARD RESPONSIVE HEADER TWEAKS
========================================================= */

.site-header-standard .header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.25rem;
}

.site-header-standard .header-left {
    flex: 0 0 auto;
}

.site-header-standard .header-right {
    flex: 1 1 auto;
    display: flex;
    justify-content: flex-end;
}

.site-header-standard .page-title {
    margin: 0;
    line-height: 1.2;
}

.site-header-standard .haa-wordmark,
.site-header-standard .haa-strapline,
.site-header-standard .haa-brand-text {
    line-height: 1.15;
}

/* =========================================================
   25. SEARCH PAGE (page-index)
========================================================= */

.page-index {
    line-height: 1.55;
}

.page-index .content-wrapper {
    padding-top: 1rem;
    padding-bottom: 0.2rem;
}

.page-index .form-control,
.page-index .form-select,
.page-index .form-label {
    font-size: 0.95rem;
}

.page-index .form-control,
.page-index .form-select {
    padding: 0.45rem 0.75rem;
    line-height: 1.35;
}

.page-index .form-control::placeholder {
    font-size: 0.95rem;
    opacity: 0.75;
}

.page-index .btn,
.page-results-list .btn,
.page-results-map .btn {
    font-size: 0.9rem;
    padding: 0.38rem 0.72rem;
    line-height: 1.2;
}

.page-index .form-select,
.page-results-list .form-select,
.page-results-map .form-select {
    font-size: 0.9rem;
    line-height: 1.2;
}

.page-index .context-card,
.page-index .search-hero {
    border: 1px solid rgba(0, 0, 0, 0.18);
    border-radius: 1rem;
    background: var(--bs-body-bg);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.10);
}

.page-index .context-card::before,
.page-index .search-hero::before {
    content: none !important;
}

.page-index .search-hero {
    padding: 0.85rem;
    margin-top: 0.85rem;
    margin-bottom: 0.85rem;
}

.page-index .hero-title {
    font-size: 1.1rem;
    margin: 0;
}

.page-index .hero-sub {
    max-width: none;
}

.page-index .search-mode {
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 0.85rem;
    padding: 0.8rem;
    background: rgba(0, 0, 0, 0.015);
}

.page-index .search-mode + .search-mode {
    margin-top: 0.7rem;
}

.page-index .search-mode-title {
    font-size: 0.98rem;
    margin: 0 0 0.2rem 0;
}

.page-index .search-mode-help {
    font-size: 0.9rem;
    color: var(--bs-secondary-color);
    margin-bottom: 0.55rem;
    line-height: 1.45;
}

.page-index .search-subtitle {
    font-size: 0.92rem;
    margin-bottom: 0.35rem;
    font-weight: 600;
}

.page-index .search-divider {
    border-top: 1px solid rgba(0, 0, 0, 0.12);
    margin: 0.65rem 0;
}

.page-index .search-hero .mb-3 {
    margin-bottom: 0.65rem !important;
}

.page-index .search-hero .form-control,
.page-index .search-hero .form-select {
    padding: 0.4rem 0.72rem;
}

.page-index .filter-toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.2rem;
}

.page-index .filter-toggle-row .search-subtitle,
.page-index .filter-toggle-row .search-mode-help {
    margin-bottom: 0;
}

.page-index .search-actions-primary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 0.7rem;
    padding-top: 0.7rem;
    border-top: 1px solid rgba(0, 0, 0, 0.12);
}

.page-index .search-actions-primary-left,
.page-index .search-actions-primary-right {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}

.page-index .search-actions-primary-right .btn {
    min-width: 8.5rem;
}

.page-index .search-actions-primary .btn,
.page-index .near-me-controls .btn {
    padding: 0.42rem 0.8rem;
}

.page-index .search-filters-collapse {
    margin-top: 0.35rem;
}

.page-index .near-me-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.page-index .near-me-radius {
    width: auto;
    min-width: 8.5rem;
}

.page-index .near-me-note {
    color: var(--bs-secondary-color);
    font-size: 0.88rem;
    margin-top: 0.2rem;
}

.page-index .btn-search-secondary {
    background-color: #dfe3e8;
    border: 1px solid #aeb6bf;
    color: #1f2328;
}

.btn-filter-toggle {
  background: #dbeafe;
  border: 1px solid #93c5fd;
  color: #1e3a8a;
}

.btn-filter-toggle:hover,
.btn-filter-toggle:focus {
  background: #bfdbfe;
  border-color: #60a5fa;
  color: #172554;
}

.btn-clear-search {
  background: #f8f9fa;
  border: 1px solid #d0d5dd;
  color: #495057;
}

.btn-clear-search:hover,
.btn-clear-search:focus {
  background: #eef1f4;
  border-color: #c4c9cf;
  color: #343a40;
}

.page-index .btn-search-secondary:hover,
.page-index .btn-search-secondary:focus {
    background-color: #cfd6dd;
    border-color: #98a2ad;
    color: #1f2328;
}

.page-index .btn-search-secondary:active {
    background-color: #c2c9d1;
    border-color: #8c97a3;
    color: #1f2328;
}

.page-index .btn-search-secondary:disabled {
    background-color: #e9ecef;
    border-color: #c7cdd4;
    color: #6c757d;
    opacity: 1;
}

.page-index .top-card {
    margin-top: 0;
    padding: 0.9rem 1rem;
}

.page-index .top-card p {
    max-width: none;
}

.page-index .project-summary-title {
    margin: 0 0 0.3rem 0;
    font-size: 0.98rem;
    font-weight: 600;
    line-height: 1.2;
}

.page-index .project-summary-lead {
    margin: 0 0 0.35rem 0;
    font-size: 0.91rem;
    line-height: 1.5;
}

.page-index .project-summary-text {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.5;
    color: var(--text-main);
}

.page-index .project-summary-title .haa-sup,
.page-index .project-summary-lead .haa-sup,
.page-index .project-summary-text .haa-sup {
    font-size: 0.58em;
    vertical-align: super;
    position: relative;
    top: -0.08em;
    color: #66bb6a;
    letter-spacing: 0.01em;
}

.page-index .coverage-map-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.3rem;
    font-size: 0.9rem;
}

.page-index .coverage-map {
    height: 200px;
    width: 100%;
    border-radius: 0.75rem;
    border: 1px solid rgba(0, 0, 0, 0.12);
    overflow: hidden;
}

.page-index .coverage-map-legend {
    font-size: 0.78rem;
    color: var(--bs-secondary-color);
    margin-top: 0.2rem;
}

.page-index .coverage-figures {
    margin-top: 0.75rem;
    font-size: 0.92rem;
    line-height: 1.5;
    color: var(--text-main);
}

.page-index .coverage-figures strong {
    font-size: 1.08rem;
    font-weight: 700;
    color: #222;
}

.page-index .coverage-sep {
    color: var(--bs-secondary-color);
    margin: 0 0.35rem;
}

/* =========================================================
   26. RESULTS PAGES LAYOUT
========================================================= */

.page-results-list,
.page-results-map {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.page-results-list main.content-wrapper,
.page-results-map main.content-wrapper {
    flex: 1 0 auto;
    width: 100%;
    box-sizing: border-box;
}

.page-results-map main.content-wrapper {
    display: flex;
    flex-direction: column;
}

/* =========================================================
   27. RESULTS MAP PAGE
========================================================= */

.page-results-map #map {
    flex: 1 1 auto;
    min-height: 450px;
    margin-bottom: 1.5rem;
}

.page-results-map .leaflet-popup-content .bi-camera-fill {
    vertical-align: -0.08em;
}

.page-results-map .map-popup-title {
    margin-bottom: 0.15rem;
    font-weight: 600;
}

.page-results-map .map-popup-title a {
    text-decoration: none;
}

.page-results-map .map-popup-title a:hover {
    text-decoration: underline;
}

.page-results-map .map-popup-sitechar,
.page-results-map .map-popup-location,
.page-results-map .map-popup-mining {
    margin-top: 0.15rem;
    color: #6c757d;
    font-size: 0.875rem;
}

.page-results-map .map-popup-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.35rem;
}

.page-results-map .map-popup-camera {
    color: #6c757d;
    font-size: 0.9rem;
    line-height: 1;
}

.page-results-map .output-tag {
    display: inline-block;
    padding: 0 4px;
    font-size: 0.74rem;
    line-height: 1.25;
    border: 1px solid #d7dadd;
    background: #fafafa;
    color: #666;
    border-radius: 0;
}

.page-results-map .site-header .header-inner,
.page-results-map main.content-wrapper {
    max-width: var(--page-max-width);
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--page-side-padding);
    padding-right: var(--page-side-padding);
    box-sizing: border-box;
}

.page-results-map .page-toolbar,
.page-results-map .filter-info,
.page-results-map #map {
    width: 100%;
    box-sizing: border-box;
}

/* =========================================================
   28. STATIC CONTENT PAGES (ABOUT / PRIVACY)
========================================================= */

.page-about .content-wrapper {
    padding-top: 1rem;
    padding-bottom: 0.2rem;
}

.page-about .about-shell {
    max-width: 1200px;
    margin: 0 0 1.25rem;
}

.page-about .about-card {
    border: 1px solid rgba(0, 0, 0, 0.14);
    border-radius: 1rem;
    background: #fff;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.06);
    padding: 1.1rem 1.15rem;
}

.page-about .about-intro {
    margin-bottom: 1rem;
}

.page-about .about-title {
    margin: 0 0 0.4rem 0;
    font-size: 1.2rem;
    line-height: 1.2;
    font-weight: 600;
}

.page-about .about-lead {
    margin: 0;
    font-size: 0.98rem;
    line-height: 1.6;
}

.page-about .about-section {
    margin-top: 1.35rem;
}

.page-about .about-section:first-of-type {
    margin-top: 1rem;
}

.page-about .about-section h2 {
    margin: 0 0 0.55rem 0;
    padding-bottom: 0.25rem;
    font-size: 1.02rem;
    line-height: 1.25;
    font-weight: 600;
    border-bottom: 1px solid rgba(0, 0, 0, 0.10);
}

.page-about .about-section p {
    margin: 0 0 0.75rem 0;
    line-height: 1.65;
    max-width: none;
}

.page-about .about-section p:last-child {
    margin-bottom: 0;
}

.page-about .about-section ul {
    margin: 0.2rem 0 0.85rem 1.15rem;
    padding: 0;
    line-height: 1.65;
}

.page-about .about-section li {
    margin: 0 0 0.35rem 0;
}

.page-about .about-section a {
    word-break: break-word;
}

.page-about .about-note {
    margin-top: 1.25rem;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(0, 0, 0, 0.10);
    font-size: 0.95rem;
    color: var(--text-muted);
}

.page-about .haa-sup {
    font-size: 0.58em;
    vertical-align: super;
    position: relative;
    top: -0.08em;
    color: #66bb6a;
    letter-spacing: 0.01em;
}

/* =========================================================
   29. RESPONSIVE
========================================================= */

@media (max-width: 991.98px) {
    .overview-split {
        display: flex;
        flex-direction: column;
    }

    .overview-map {
        order: -1;
        margin-bottom: 1rem;
    }
}




@media (max-width: 991.98px) {
    .page-toolbar-inner {
        flex-direction: column;
        align-items: stretch;
    }

    .page-sections-nav {
        order: 2;
    }

    .page-toolbar-actions {
        order: 1;
        margin-left: 0;
        justify-content: flex-start;
    }

    .site-section {
        scroll-margin-top: 1rem;
    }
}

@media (max-width: 900px) {
    .media-split {
        grid-template-columns: 1fr;
    }

    .media-box {
        height: 300px;
    }

    .overview-split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    :root {
        --page-side-padding: 16px;
    }

    .media-photo-date {
        right: 8px;
        bottom: 8px;
        font-size: 0.72rem;
    }

    .result-title-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.2rem;
    }

    .result-title-side {
        display: flex;
        flex-wrap: wrap;
        gap: 0.35rem 0.5rem;
        text-align: left;
        justify-content: flex-start;
    }

    .result-meta-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.15rem;
    }

    .result-output {
        text-align: left;
    }

    .page-index .site-header {
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
        min-height: auto;
    }

    .page-index .site-header .header-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.35rem;
    }

    .page-index .site-header .header-left {
        order: 1;
    }

    .page-index .site-header .header-right {
        order: 2;
        width: 100%;
        justify-content: flex-start;
    }

    .page-index .site-header .haa-brand-text {
        text-align: left;
    }

    .page-index .site-header .page-title {
        font-size: 1.1rem;
        line-height: 1.15;
        margin: 0;
    }

    .page-index .site-header .haa-core {
        font-size: 1.8rem;
        line-height: 1;
    }

    .page-index .site-header .haa-context {
        font-size: 0.85rem;
    }

    .page-index .site-header .haa-strapline {
        font-size: 0.78rem;
    }

    .page-index .content-wrapper {
        padding-top: 0.75rem;
    }

    .page-index .search-hero {
        padding: 0.9rem;
        margin-top: 0.75rem;
        margin-bottom: 0.75rem;
    }

    .page-index .hero-sub {
        font-size: 0.92rem;
    }

    .page-index .search-mode {
        padding: 0.8rem;
    }

    .page-index .search-actions-primary {
        flex-direction: column;
        align-items: stretch;
    }

    .page-index .search-actions-primary-left,
    .page-index .search-actions-primary-right {
        width: 100%;
    }

    .page-index .search-actions-primary-right .btn,
    .page-index .search-actions-primary-left .btn {
        width: 100%;
    }

    .page-index .search-actions-primary-right {
        flex-direction: column;
    }

    .page-index .near-me-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .page-index .near-me-controls .btn,
    .page-index .near-me-controls .near-me-radius {
        width: 100%;
    }

    .page-index .top-card {
        padding: 0.85rem;
    }

    .page-index .top-card p {
        font-size: 0.92rem;
    }

    .page-index .project-summary-title {
        font-size: 0.95rem;
    }

    .page-index .project-summary-lead,
    .page-index .project-summary-text {
        font-size: 0.86rem;
    }

    .page-index .coverage-figures {
        font-size: 0.88rem;
        line-height: 1.45;
        margin-top: 0.65rem;
    }

    .page-index .coverage-figures strong {
        font-size: 1rem;
    }

    .page-index .coverage-sep {
        margin: 0 0.25rem;
    }

    .page-index .coverage-map,
    .page-index .coverage-map-legend {
        display: none;
    }

    .page-site .site-header .site-title {
        display: block;
    }

    .page-site .site-header .site-location-inline {
        display: block;
        margin-top: 0.2rem;
        font-size: 0.72em;
    }

    .page-site .site-header .site-meta-line {
        display: block;
        width: 100%;
        margin: 0.2rem 0 0 0;
        font-size: 0.82rem;
        font-style: italic;
        font-weight: 400;
        line-height: 1.35;
        color: rgba(255, 255, 255, 0.84);
    }

    .page-site .site-header .haa-core {
        font-size: 1.5rem;
    }

    .heritage-timeline::before {
        left: 20px;
    }

    .heritage-timeline-item {
        grid-template-columns: 40px minmax(0, 1fr);
        gap: 0.45rem 0.9rem;
        margin-bottom: 1.2rem;
    }

    .heritage-timeline-date-col {
        grid-column: 2;
        text-align: left;
        padding-top: 0;
        margin-bottom: 0.45rem;
    }

    .heritage-timeline-spine-col {
        grid-column: 1;
        grid-row: 1 / span 2;
    }

    .heritage-timeline-content-col {
        grid-column: 2;
    }

    .heritage-timeline-dot {
        left: 20px;
        top: 0.7rem;
        transform: translateX(-50%);
    }

    .heritage-year-plaque {
        min-width: 0;
        font-size: 0.82rem;
        padding: 0.3rem 0.62rem;
    }
}

@media (max-width: 640px) {
    .timeline-register {
        grid-template-columns: 1fr;
        padding-left: 1.25rem;
    }

    .timeline-register::before {
        left: 0.4rem;
    }

    .timeline-register dt {
        margin-top: var(--space-s);
        font-size: 0.85rem;
    }

    .timeline-register dt::before {
        left: -0.75rem;
    }
}

@media (max-width: 480px) {
    .page-index .site-header .page-title {
        font-size: 1.15rem;
    }

    .page-index .site-header .haa-core {
        font-size: 1.35rem;
    }

    .page-index .site-header .haa-strapline {
        display: none;
    }

    .page-site .site-header .haa-core {
        font-size: 1.35rem;
    }
}

/* ============================================================
   HAABase Windmills — country / region browse page
   Used by regions.php
   ============================================================ */

.countries-page {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

/* Toolbar */

.countries-toolbar {
  margin-bottom: 0.25rem;
}

.page-toolbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.page-toolbar-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Intro */

.countries-intro-card,
.countries-list-card {
  padding: 1.25rem;
}

.countries-intro-card .project-summary-title,
.countries-list-card .project-summary-title {
  margin-bottom: 0.5rem;
}

/* Coverage/map row */

.countries-overview-row {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(280px, 1.1fr);
  gap: 1.25rem;
  align-items: stretch;
  margin-top: 1.25rem;
  margin-bottom: 1.5rem;
}

.countries-overview-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.countries-overview-text h3 {
  margin: 0 0 0.5rem;
  font-size: 1.15rem;
  font-weight: 700;
}

.countries-overview-text p {
  margin-bottom: 0.65rem;
}

.countries-overview-note {
  color: var(--bs-secondary-color, #6c757d);
  font-size: 0.95rem;
}

.countries-map-panel {
  min-height: 260px;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.08);
  background: #f8f9fa;
}

.countries-map-panel .coverage-map,
#regionsCoverageMap,
#countriesCoverageMap {
  width: 100%;
  height: 300px;
  min-height: 260px;
}

/* Country sections */

.country-region-section {
  margin-top: 1.5rem;
}

.country-region-section + .country-region-section {
  border-top: 1px solid rgba(0,0,0,.08);
  padding-top: 1.5rem;
}

.country-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.85rem;
  flex-wrap: wrap;
}

.country-section-heading h3 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 750;
  letter-spacing: -0.01em;
}

.country-card-count {
  color: var(--bs-secondary-color, #6c757d);
  font-weight: 600;
  margin-left: 0.25rem;
}

/* Region card grid */

.country-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 0.85rem;
}

.country-card {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 1rem;
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 1rem;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}

.country-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.country-card-name {
  font-weight: 700;
  line-height: 1.25;
}

/* Card actions */

.country-card-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.country-card-action {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.3rem 0.5rem;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,.12);
  background: #f8f9fa;
  color: inherit;
  text-decoration: none;
  font-size: 0.85rem;
  line-height: 1.1;
  white-space: nowrap;
}

.country-card-action:hover,
.country-card-action:focus {
  background: #eef3f8;
  border-color: rgba(0,0,0,.18);
  color: inherit;
  text-decoration: none;
}

.country-card-action i {
  font-size: 0.95rem;
}

/* Use summary */

.country-card-outputs {
  display: block;
  color: var(--bs-secondary-color, #6c757d);
  font-size: 0.9rem;
  line-height: 1.35;
}

/* Mobile */

@media (max-width: 768px) {
  .countries-intro-card,
  .countries-list-card {
    padding: 1rem;
  }

  .countries-overview-row {
    display: block;
  }

  .countries-map-panel {
    display: none;
  }

  .country-section-heading {
    align-items: flex-start;
  }

  .country-section-heading .country-card-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .country-grid {
    grid-template-columns: 1fr;
  }

  .country-card-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .country-card-actions {
    justify-content: flex-start;
  }
}


/* =========================================================
   28. FOOTER — current compact grey panel version
========================================================= */

.site-footer {
    margin-top: 2rem;
    padding: 1rem 0;
    background: #e7e4de;
    color: #3a3a34;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.site-footer .content-wrapper {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 1rem;
}

.footer-panel {
    width: 100%;
    padding: 0.8rem 1rem;
    border-radius: 0.75rem;
    background: #f5f3ef;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 0.25rem 0.8rem rgba(0, 0, 0, 0.035);
}

.footer-panel p {
    margin: 0;
    line-height: 1.35;
}

.footer-panel p + p {
    margin-top: 0.35rem;
}

.footer-brand {
    color: #20201c;
    font-size: 0.95rem;
}

.footer-brand strong {
    font-weight: 700;
}

.footer-brand span {
    margin-left: 0.45rem;
    color: #6f6b63;
    font-size: 0.9rem;
}

.haa-sup {
    font-size: 0.55em;
    vertical-align: super;
    letter-spacing: 0.02em;
}

.footer-description {
    color: #444039;
    font-size: 0.9rem;
}

.footer-meta {
    color: #5d584f;
    font-size: 0.88rem;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.15rem 0.4rem;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    font-size: 0.86rem;
    line-height: 1.35;
}

.site-footer a {
    color: #8a4f1f;
    text-decoration: none;
    font-weight: 600;
}

.site-footer a:hover,
.site-footer a:focus {
    color: #4f2b0f;
    text-decoration: underline;
}

.footer-links span {
    color: #9a948a;
}

.footer-small {
    margin-top: 0.45rem !important;
    font-size: 0.8rem;
    color: #756f66;
}

.footer-thp-logo {
    display: inline-block;
    margin-right: 0.1rem;
    color: #1f5c4c;
    font-size: 1.35em;
    font-weight: 600;
    letter-spacing: -0.05em;
    line-height: 0.85;
    text-transform: lowercase;
    transform: translateY(0.07em);
}
