﻿    /* Hide phone-home on tablet and desktop — only mobile (≤767px) shows it */
    @media (min-width: 768px)

{
    .phone-home

{
    display: none !important;
}

}


.world-map-wrapper {
    background: #fff;
    border-radius: 14px;
    padding: 15px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

#desktopMap,
#mobileMap {
    width: 100%;
    border-radius: 10px;
}

#desktopMap {
    height: 650px;
}

.leaflet-popup-content img {
    border-radius: 6px;
}



@media (max-width:767px) {

    .dh-main-footer {
        display: none;
    }

    hero-beetle {
        display: none;
    }

    .website-view {
        display: none;
    }

    #mobileMap {
        height: 250px;
    }

    .phone-home {
        background: #f7f4ef;
    }

    .hero-section-tablet {
        display: none;
    }

    .hero-section {
        padding: 24px;
        background: linear-gradient( 135deg, #0f3d1e, #204f21, #0f3d1e );
        color: white;
    }

        .hero-section h1 {
            font-family: Georgia, 'Times New Roman', serif;
            color: white;
            font-size: 37px;
            font-weight: 500;
            line-height: 1.08;
            margin: 0 0 20px;
        }

    .hero-search input {
        width: 100%;
        border: none;
        border-radius: 16px;
        padding: 16px;
        font-size: 1rem;
    }

    .hero-actions {
        display: flex;
        gap: 12px;
        margin-top: 20px;
    }

    .hero-badge {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        background: rgba(201,168,76,0.16);
        border: 1px solid rgba(201,168,76,0.35);
        color: #C9A84C;
        font-size: 12px;
        font-weight: 600;
        padding: 6px 14px;
        border-radius: 9999px;
        margin-bottom: 24px;
    }

    .btn-family,
    .btn-map {
        flex: 1;
        text-align: center;
        padding: 14px;
        border-radius: 14px;
        text-decoration: none;
    }

    .btn-family {
        background: #c8a63c;
        color: #143d1f;
        font-weight: 700;
    }

    .btn-map {
        border: 1px solid rgba(255,255,255,.4);
        color: white;
    }

    .quick-nav {
        display: grid;
        grid-template-columns: repeat(4,1fr);
        gap: 12px;
        padding: 16px;
    }

    .quick-card {
        background: white;
        border-radius: 14px;
        padding: 18px 10px;
        text-align: center;
        text-decoration: none;
        color: #222;
        box-shadow: 0 2px 8px rgba(0,0,0,.08);
    }

        .quick-card i {
            display: block;
            font-size: 22px;
            margin-bottom: 6px;
            color: #1f3d1f;
        }

    .family-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .family-card {
        background: white;
        border-radius: 18px;
        overflow: hidden;
        box-shadow: 0 2px 8px rgba(0,0,0,.08);
    }

        .family-card img {
            width: 100%;
            height: 120px;
            object-fit: contain;
            margin-top: 10px;
        }

    .family-content {
        padding: 12px;
    }

        .family-content h4 {
            line-height: 1.3;
            /* Limit to 2 lines */
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
            min-height: 2em;
            font-family: Georgia, 'Times New Roman', serif;
            font-size: 13px;
            font-weight: 700;
            color: #1A1A1A;
            margin: 0 0 2px;
        }


        .family-content span {
            font-size: 12px;
            color: #7A7268;
            margin: 0;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            max-width: 220px;
        }


    .recent-date {
        font-size: 10px;
        color: #AAA49D;
        margin: 0;
    }

    .families-section,
    .recent-section,
    .map-section,
    .about-section {
        padding: 16px;
    }

    .section-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 16px;
    }

        .section-header h2 {
            font-family: Georgia, 'Times New Roman', serif;
            font-size: 22px;
            font-weight: 600;
            color: #1A1A1A;
            margin: 0;
        }

    #map {
        height: 250px;
    }

    .recent-slider {
        display: flex;
        gap: 14px;
        overflow-x: auto;
        padding-bottom: 8px;
    }

    .recent-card {
        min-width: 140px;
        background: #fff;
        border-radius: 16px;
        overflow: hidden;
        box-shadow: 0 2px 8px rgba(0,0,0,.08);
    }

    .recent-image img {
        width: 100%;
        height: 90px;
        object-fit: contain;
        margin-top: 10px;
    }

    .recent-content {
        padding: 10px;
    }

        .recent-content h5 {
            font-weight: 600;
            /* Limit to 2 lines */
            display: -webkit-box;
            min-height: 2em;
            font-family: Georgia, 'Times New Roman', serif;
            font-size: 13px;
            font-weight: 700;
            color: #1A1A1A;
            margin: 0 0 4px;
            line-height: 1.3;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .recent-content small {
            font-size: 11px;
            color: #7A7268;
            margin: 0 0 4px;
        }

    .new-badge {
        background: #caa93e;
        color: #143d1f;
        font-size: .7rem;
        padding: 3px 8px;
        border-radius: 999px;
    }

    .mini-map {
        background: white;
        border-radius: 18px;
        overflow: hidden;
        box-shadow: 0 2px 8px rgba(0,0,0,.08);
    }

    .about-card {
        background: white;
        padding: 20px;
        border-radius: 18px;
        box-shadow: 0 2px 8px rgba(0,0,0,.08);
    }

    .about-header {
        display: flex;
        gap: 15px;
        margin-bottom: 16px;
    }

    .about-icon {
        width: 56px;
        height: 56px;
        border-radius: 50%;
        background: #2f6d2f;
        color: white;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .collection-stats {
        display: flex;
        justify-content: space-between;
        margin-top: 20px;
        padding-top: 20px;
        border-top: 1px solid #eee;
    }

        .collection-stats div {
            text-align: center;
        }

        .collection-stats strong {
            display: block;
            font-size: 1.6rem;
        }

        .collection-stats span {
            font-size: .85rem;
            color: #666;
        }

    .contribute-card {
        background: linear-gradient( 135deg, #143d1f, #204f21 );
        color: white;
        border-radius: 18px;
        padding: 10px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .contribute-left {
        display: flex;
        gap: 14px;
        align-items: center;
        padding-top: 1rem;
        padding-bottom: 1rem;
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .contribute-icon {
        width: 7rem;
        height: 4rem;
        border-radius: 9999px;
        background: rgba(255,255,255,.1);
        display: flex;
        align-items: center;
        justify-content: center;
        background-color: rgba(201, 168, 76, 0.2);
    }

    .contibute-title {
        color: rgb(255 255 255 / var(--tw-text-opacity, 1));
        font-weight: 700;
        font-size: 14px;
    }

    .contibute-text {
        color: rgb(157 184 154 / var(--tw-text-opacity, 1));
        font-size: 11px;
        margin-top: 0.125rem;
    }

    .btn-contribute {
        background: #caa93e;
        color: #143d1f;
        text-decoration: none;
        padding: 10px;
        border-radius: 12px;
        font-weight: 700;
    }
}


/* ==========================================
   TABLET VIEW (768px - 1024px)
========================================== */

@media (min-width:768px) and (max-width:1399px) {

    .website-view {
        display: none !important;
    }

    .phone-home {
        display: none !important;
    }

    .tablet-home {
        display: block !important;
    }

    .hero-section {
        display: none;
    }
    /* =====================
       HERO
    ====================== */

    .hero-section-tablet {
        padding: 0;
    }

    .hero-content {
        display: grid;
        grid-template-columns: 58% 42%;
        min-height: 620px;
        overflow: hidden;
        border-radius: 0 0 20px 20px;
        background: linear-gradient( 90deg, #123c1d 0%, #184523 40%, #284f2c 65%, #4f6843 100% );
    }
    /* LEFT SIDE */

    .hero-left {
        padding: 70px 50px;
        color: white;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .hero-badge {
        display: inline-flex;
        align-self: flex-start;
        padding: 10px 18px;
        background: rgba(201,167,64,.15);
        border: 1px solid rgba(201,167,64,.35);
        color: #d4b44a;
        border-radius: 999px;
        font-weight: 600;
        font-size: .9rem;
    }

    .hero-left h1 {
        font-size: 4rem;
        line-height: 1.05;
        margin: 25px 0;
        font-family: Georgia, serif;
    }

    .hero-left p {
        max-width: 540px;
        font-size: 1.15rem;
        line-height: 1.8;
        color: rgba(255,255,255,.82);
    }
    /* SEARCH */

    .hero-search {
        margin-top: 35px;
        display: flex;
        max-width: 520px;
        background: white;
        border-radius: 18px;
        padding: 10px;
    }

        .hero-search input {
            flex: 1;
            border: none;
            outline: none;
            padding: 0 15px;
            font-size: 1rem;
        }

        .hero-search button {
            border: none;
            background: #143d1f;
            color: white;
            padding: 0 28px;
            border-radius: 12px;
            font-weight: 600;
            cursor: pointer;
        }
    /* BUTTONS */

    .hero-actions {
        display: flex;
        gap: 18px;
        margin-top: 30px;
    }

    .btn-family {
        background: #c9a740;
        color: #143d1f;
        padding: 16px 28px;
        border-radius: 14px;
        text-decoration: none;
        font-weight: 700;
    }

    .btn-map {
        border: 1px solid rgba(255,255,255,.35);
        color: white;
        padding: 16px 28px;
        border-radius: 14px;
        text-decoration: none;
    }
    /* RIGHT SIDE */

    .hero-right {
        position: relative;
        display: flex;
        justify-content: center;
        align-items: center;
        background: linear-gradient( to right, rgba(255,255,255,.03), rgba(255,255,255,.15) );
    }

        .hero-right::before {
            content: "";
            position: absolute;
            inset: 0;
            background: radial-gradient( circle at center, rgba(255,255,255,.25), transparent 70% );
            pointer-events: none;
        }

        .hero-right img {
            width: 80%;
            max-width: 420px;
            object-fit: contain;
            filter: drop-shadow(0 20px 30px rgba(0,0,0,.35));
        }
    /* =====================
       QUICK NAV
    ====================== */

    .quick-nav {
        display: grid;
        grid-template-columns: repeat(4,1fr);
        gap: 20px;
        padding: 25px;
    }

    .quick-card {
        background: white;
        border-radius: 18px;
        padding: 24px;
        text-align: center;
        box-shadow: 0 3px 15px rgba(0,0,0,.08);
    }

        .quick-card i {
            font-size: 32px;
            margin-bottom: 12px;
            display: block;
            color: #143d1f;
        }

        .quick-card span {
            display: block;
            font-size: 1rem;
            font-weight: 600;
        }
    /* =====================
       SECTIONS
    ====================== */

    .families-section,
    .recent-section,
    .map-section,
    .about-section {
        padding: 25px;
    }

    .section-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 20px;
    }

        .section-header h2 {
            font-size: 2rem;
            color: #143d1f;
        }
    /* =====================
       FAMILY GRID
    ====================== */

    .family-grid {
        display: grid;
        grid-template-columns: repeat(3,1fr);
        gap: 20px;
    }

    .family-card {
        background: white;
        border-radius: 18px;
        overflow: hidden;
        box-shadow: 0 3px 12px rgba(0,0,0,.08);
    }

        .family-card img {
            width: 100%;
            height: 220px;
            object-fit: contain;
        }

    .family-content {
        padding: 18px;
    }

        .family-content h4 {
            font-size: 1.4rem;
            margin-bottom: 8px;
        }
    /* =====================
       MAP + ABOUT
    ====================== */

    .tablet-layout {
        display: grid;
        grid-template-columns: 2fr 1fr;
        gap: 25px;
        padding: 25px;
    }

    .mini-map {
        background: white;
        border-radius: 20px;
        overflow: hidden;
        box-shadow: 0 3px 15px rgba(0,0,0,.08);
    }

    #mobileMap {
        height: 500px;
    }

    .about-card {
        background: white;
        border-radius: 20px;
        padding: 25px;
        box-shadow: 0 3px 15px rgba(0,0,0,.08);
    }

        .about-card h3 {
            font-size: 2rem;
            margin-bottom: 15px;
        }

    .collection-stats {
        margin-top: 25px;
        display: flex;
        justify-content: space-between;
    }

        .collection-stats strong {
            display: block;
            font-size: 2rem;
        }
    /* =====================
       RECENTLY ADDED
    ====================== */

    .recent-slider {
        display: grid;
        grid-template-columns: repeat(4,1fr);
        gap: 20px;
        overflow: visible;
    }

    .recent-card {
        min-width: auto;
        background: white;
        border-radius: 18px;
        overflow: hidden;
        box-shadow: 0 3px 12px rgba(0,0,0,.08);
    }

    .recent-image img {
        width: 100%;
        height: 180px;
        object-fit: contain;
    }

    .recent-content {
        padding: 15px;
    }

        .recent-content h5 {
            font-size: 1.1rem;
            line-height: 1.4;
        }
    /* =====================
       CONTRIBUTE
    ====================== */

    .contribute-card {
        background: linear-gradient( 135deg, #143d1f, #1d4a21 );
        border-radius: 20px;
        padding: 30px;
        color: white;
        text-align: center;
        padding: 25px 20px;
    }

    .contribute-left {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .contribute-icon {
        /* width: 60px;
            height: 60px; */
        display: none;
    }

    .btn-contribute {
        display: inline-block;
        background: #c9a740;
        color: #143d1f;
        font-weight: 700;
        border-radius: 12px;
        padding: 12px 24px;
        text-decoration: none;
        margin-top: 20px;
    }
    /* =====================
       FOOTER
    ====================== */

    footer {
        background: #111;
        color: white;
        padding: 50px 30px;
    }

        footer .container {
            display: grid;
            grid-template-columns: 1.5fr 1fr 1fr 1fr;
            gap: 30px;
        }
}

/* ============================================================
   TABLET HOME  —  visible only at 768–1399 px
   All classes prefixed with .th- to avoid conflicts
============================================================ */
.tablet-home {
    display: none;
    font-family: 'Inter', system-ui, sans-serif;
}

/* Map height */
#tabletHomeMap {
    height: 260px !important;
    width: 100% !important;
}

/* ---- Hero ---- */
.th-hero {
    background: #1E3A1E;
    position: relative;
    overflow: hidden;
}

    .th-hero::before {
        content: '';
        position: absolute;
        inset: 0;
        pointer-events: none;
        background: radial-gradient(ellipse at 88% 12%, rgba(201,168,76,.14) 0%, transparent 55%), radial-gradient(ellipse at 6% 88%, rgba(45,90,39,.5) 0%, transparent 46%);
    }

.th-hero-inner {
    display: flex;
    min-height: 320px;
}

.th-hero-left {
    flex: 1;
    padding: 36px 28px 32px;
    position: relative;
    z-index: 1;
}

.th-hero-right {
    width: 260px;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}

    .th-hero-right img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center;
        display: block;
    }

.th-hero-right-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, #1E3A1E 0%, transparent 35%);
}

.th-hero-right-label {
    position: absolute;
    bottom: 18px;
    left: 18px;
    right: 12px;
}

.th-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(201,168,76,.18);
    border: 1px solid rgba(201,168,76,.35);
    color: #C9A84C;
    font-size: 11px;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 9999px;
    margin-bottom: 16px;
}

.th-hero-title {
    font-family: Georgia,'Times New Roman',serif;
    color: white;
    font-size: 30px;
    font-weight: 700;
    line-height: 1.15;
    margin: 0 0 10px;
}

.th-hero-subtitle {
    color: #9DB89A;
    font-size: 13px;
    line-height: 1.7;
    margin: 0 0 18px;
    max-width: 380px;
}

.th-search-form {
    display: flex;
    align-items: center;
    background: white;
    border-radius: 14px;
    padding: 5px 5px 5px 14px;
    max-width: 420px;
    margin-bottom: 18px;
    box-shadow: 0 4px 16px rgba(0,0,0,.2);
    border: 2px solid transparent;
}

    .th-search-form:focus-within {
        border-color: #C9A84C;
    }

    .th-search-form i {
        color: #7A7268;
        font-size: 13px;
        margin-right: 8px;
        flex-shrink: 0;
    }

    .th-search-form input {
        flex: 1;
        border: none;
        outline: none;
        font-size: 13px;
        color: #1A1A1A;
        background: transparent;
    }

        .th-search-form input::placeholder {
            color: #AAA49D;
        }

.th-search-btn {
    background: #1E3A1E;
    color: white;
    font-size: 12px;
    font-weight: 600;
    padding: 8px 16px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    white-space: nowrap;
}

.th-hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.th-btn-primary {
    background: #C9A84C;
    color: #1E3A1E;
    font-size: 13px;
    font-weight: 700;
    padding: 10px 20px;
    border-radius: 12px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.th-btn-secondary {
    border: 2px solid rgba(255,255,255,.3);
    color: white;
    font-size: 13px;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 12px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.th-featured-family-label {
    background: rgba(201,168,76,.9);
    color: #1E3A1E;
    font-size: 9px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 9999px;
    display: inline-block;
    margin-bottom: 6px;
    text-transform: uppercase;
}

.th-featured-family-name {
    font-family: Georgia,serif;
    color: white;
    font-size: 14px;
    font-weight: 700;
    margin: 0;
}

.th-featured-family-sub {
    color: #B8D4B6;
    font-size: 11px;
    margin: 2px 0 0;
}

/* ---- Shared section wrapper ---- */
.th-section {
    padding: 18px 20px;
    background: #F4F1EC;
}

/* ---- Section header ---- */
.th-section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 14px;
}

.th-section-title {
    font-family: Georgia,'Times New Roman',serif;
    font-size: 20px;
    font-weight: 700;
    color: #1A1A1A;
    margin: 0;
}

.th-section-subtitle {
    font-size: 12px;
    color: #7A7268;
    margin: 4px 0 0;
}

.th-view-all {
    color: #2D5A27;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
    padding-bottom: 4px;
}

    .th-view-all:hover {
        color: #1E3A1E;
        text-decoration: none;
    }

/* ---- Quick nav ---- */
.th-quick-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 12px;
}

.th-qnav-card {
    background: white;
    border-radius: 16px;
    border: 1px solid #E2DDD6;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    transition: transform .15s, box-shadow .15s;
}

    .th-qnav-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 8px 20px rgba(30,58,30,.12);
        text-decoration: none;
        color: inherit;
    }

.th-qnav-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: #F0EDE6;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1E3A1E;
    font-size: 18px;
    flex-shrink: 0;
}

.th-qnav-icon-gold {
    background: rgba(201,168,76,.15);
    color: #C9A84C;
}

.th-qnav-card h3 {
    font-size: 13px;
    font-weight: 700;
    color: #1A1A1A;
    margin: 0 0 2px;
}

.th-qnav-card p {
    font-size: 11px;
    color: #7A7268;
    margin: 0;
}

/* ---- Family grid ---- */
.th-family-grid {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 14px;
}

.th-family-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #E2DDD6;
    box-shadow: 0 2px 6px rgba(0,0,0,.05);
    text-decoration: none;
    display: block;
    color: inherit;
    transition: transform .15s, box-shadow .15s;
}

    .th-family-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 8px 20px rgba(30,58,30,.12);
        text-decoration: none;
        color: inherit;
    }

.th-family-img-wrap {
    position: relative;
    height: 130px;
    overflow: hidden;
}

.th-family-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: block;
}

.th-family-img-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(30,58,30,.7) 0%, transparent 55%);
}

.th-family-count {
    position: absolute;
    bottom: 8px;
    left: 12px;
    color: white;
    font-size: 11px;
    font-weight: 600;
}

.th-family-body {
    padding: 10px 12px;
}

.th-family-name {
    font-family: Georgia,serif;
    font-size: 14px;
    font-weight: 700;
    color: #1A1A1A;
    margin: 0 0 2px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.th-family-desc {
    font-size: 11px;
    color: #7A7268;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.th-browse-all-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px;
    margin-top: 14px;
    border: 1.5px solid #2D5A27;
    border-radius: 12px;
    color: #2D5A27;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    background: transparent;
    cursor: pointer;
}

    .th-browse-all-btn:hover {
        background: #F0EDE6;
        text-decoration: none;
        color: #1E3A1E;
    }

/* ---- Map + About ---- */
.th-map-about-grid {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 16px;
}

.th-map-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.th-map-title {
    font-family: Georgia,serif;
    font-size: 18px;
    font-weight: 700;
    color: #1A1A1A;
    margin: 0;
}

.th-map-subtitle {
    font-size: 11px;
    color: #7A7268;
    margin: 2px 0 0;
}

.th-fullscreen-btn {
    background: #C9A84C;
    color: #1E3A1E;
    font-size: 11px;
    font-weight: 700;
    padding: 7px 14px;
    border-radius: 10px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    white-space: nowrap;
}

    .th-fullscreen-btn:hover {
        background: #d9b962;
        color: #1E3A1E;
        text-decoration: none;
    }

.th-map-box {
    background: white;
    border-radius: 16px;
    border: 1px solid #E2DDD6;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
}

.th-map-legend {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 14px;
    border-top: 1px solid #E2DDD6;
    font-size: 11px;
    color: #5A5651;
    flex-wrap: wrap;
}

.th-legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 4px;
}

/* ---- Sidebar cards ---- */
.th-sidebar {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.th-card {
    background: white;
    border-radius: 16px;
    border: 1px solid #E2DDD6;
    padding: 16px;
    box-shadow: 0 2px 6px rgba(0,0,0,.05);
}

.th-about-title {
    font-family: Georgia,serif;
    font-size: 16px;
    font-weight: 700;
    color: #1A1A1A;
    margin: 0 0 2px;
}

.th-about-sub {
    font-size: 11px;
    color: #7A7268;
    margin: 0 0 10px;
}

.th-about-text {
    font-size: 12px;
    color: #5A5651;
    line-height: 1.65;
    margin-bottom: 12px;
}

.th-stats-row {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 8px;
    margin-bottom: 12px;
}

.th-stat-box {
    background: #F4F1EC;
    border-radius: 12px;
    padding: 10px;
    text-align: center;
}

.th-stat-num {
    font-family: Georgia,serif;
    font-size: 18px;
    font-weight: 700;
    color: #1E3A1E;
    display: block;
}

.th-stat-label {
    font-size: 9px;
    color: #7A7268;
    font-weight: 500;
    display: block;
    margin-top: 2px;
}

.th-read-more {
    color: #2D5A27;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.th-new-badge {
    background: #C9A84C;
    color: #1E3A1E;
    font-size: 9px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 9999px;
}

.th-news-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding-bottom: 12px;
    margin-bottom: 12px;
    border-bottom: 1px solid #E2DDD6;
}

    .th-news-item:last-child {
        border-bottom: none;
        padding-bottom: 0;
        margin-bottom: 0;
    }

.th-news-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #2D5A27;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #C9A84C;
    font-size: 13px;
    flex-shrink: 0;
}

.th-news-title {
    font-size: 12px;
    font-weight: 600;
    color: #1A1A1A;
    margin: 0 0 2px;
}

.th-news-body {
    font-size: 11px;
    color: #7A7268;
    margin: 0 0 2px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.th-news-date {
    font-size: 10px;
    color: #AAA49D;
    margin: 0;
}

.th-contribute-card {
    background: #1E3A1E;
    border-radius: 16px;
    padding: 16px;
}

    .th-contribute-card h3 {
        font-family: Georgia,serif;
        font-size: 14px;
        font-weight: 700;
        color: white;
        margin: 0 0 4px;
    }

    .th-contribute-card p {
        font-size: 11px;
        color: #9DB89A;
        line-height: 1.65;
        margin-bottom: 12px;
    }

.th-contribute-btn {
    display: block;
    width: 100%;
    background: #C9A84C;
    color: #1E3A1E;
    font-size: 12px;
    font-weight: 700;
    padding: 10px;
    border-radius: 10px;
    text-align: center;
    text-decoration: none;
}

    .th-contribute-btn:hover {
        background: #d9b962;
        text-decoration: none;
        color: #1E3A1E;
    }

/* ---- Recently added ---- */
.th-recent-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 12px;
}

.th-recent-card {
    background: white;
    border-radius: 14px;
    border: 1px solid #E2DDD6;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,.05);
    text-decoration: none;
    display: block;
    color: inherit;
    transition: transform .15s;
}

    .th-recent-card:hover {
        transform: translateY(-2px);
        text-decoration: none;
        color: inherit;
    }

.th-recent-img-wrap {
    height: 100px;
    overflow: hidden;
    background: #ffffff;
}

.th-recent-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.th-recent-body {
    padding: 10px 12px;
}

.th-recent-name {
    font-family: Georgia,serif;
    font-size: 12px;
    font-weight: 700;
    color: #1A1A1A;
    margin: 0 0 2px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
}

.th-recent-family {
    font-size: 10px;
    color: #7A7268;
    margin: 0 0 5px;
}

.th-recent-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.th-recent-location {
    font-size: 9px;
    color: #7A7268;
}

.th-recent-date {
    font-size: 9px;
    color: #AAA49D;
}

/* ---- Small tablet (768–1023px) overrides ---- */
@media (min-width:768px) and (max-width:1023px) {
    .th-quick-grid {
        grid-template-columns: repeat(2,1fr);
    }

    .th-family-grid {
        grid-template-columns: repeat(2,1fr);
    }

    .th-recent-grid {
        grid-template-columns: repeat(2,1fr);
    }

    .th-map-about-grid {
        grid-template-columns: 1fr;
    }

    .th-hero-right {
        display: none;
    }

    .th-hero-title {
        font-size: 26px;
    }

    .th-search-form {
        max-width: 100%;
    }
}





