/* ========================================================================
   Find & Bind · index.css
   - Home-page search enhancements
   - Notification menu counter
   - Latest request/listing presentation
   - Featured categories
   - Home-page overflow correction
   ======================================================================== */

/*
	The decorative blurred hero circles intentionally extend beyond the hero.
	Clip them at the hero boundary so they cannot create horizontal scrolling.
*/
.hero-v2{
    overflow:hidden;
}

/*
	Use a slightly more compact homepage hero.

	The hero remains spacious, but more of the search experience becomes
	visible above the fold on common laptop and desktop screens.
*/
.hero-v2 .hero-inner{
    padding:68px 16px 80px;
}

@media (min-width:1024px){
    .hero-v2 .hero-inner{
        padding:88px 16px 100px;
    }
}

/* Home search country selector. */
.hs-form select{
    appearance:none;
    -webkit-appearance:none;
    height:var(--field-h);
    padding:0 36px 0 14px;
    border:1px solid var(--line);
    border-radius:12px;
    background:
            linear-gradient(45deg, transparent 50%, #6b7280 50%)
            calc(100% - 17px) calc(50% - 2px) / 5px 5px no-repeat,
            linear-gradient(135deg, #6b7280 50%, transparent 50%)
            calc(100% - 12px) calc(50% - 2px) / 5px 5px no-repeat,
            #fff;
    color:#111827;
    font:inherit;
    font-size:15px;
    cursor:pointer;
}

.hs-country{
    flex:0 1 190px;
    min-width:150px;
}

.hs-city{
    flex:1 1 190px;
    min-width:150px;
}

.hs-form input:focus,
.hs-form select:focus{
    outline:3px solid rgba(17,24,39,.16);
    outline-offset:2px;
    border-color:#94a3b8;
}

/* ========================================================================
   Home marketplace statistics
   ======================================================================== */

.home-stats{
    position:relative;
    padding:42px 0 46px;
    background:
            radial-gradient(
                    70% 100% at 0 0,
                    rgba(225,6,0,.035),
                    transparent 55%
            ),
            radial-gradient(
                    70% 100% at 100% 100%,
                    rgba(0,161,20,.045),
                    transparent 55%
            ),
            #fff;
    border-bottom:1px solid var(--line);
}

.home-stats__intro{
    max-width:720px;
    margin:0 auto 24px;
    text-align:center;
}

.home-stats__eyebrow{
    margin:0 0 5px;
    color:var(--red-special);
    font-size:12px;
    font-weight:800;
    letter-spacing:.08em;
    text-transform:uppercase;
}

.home-stats__intro h2{
    margin:0;
    color:var(--navy);
    font-size:clamp(22px, 3vw, 30px);
    line-height:1.2;
}

.home-stats__intro > p:last-child{
    margin:8px auto 0;
    color:var(--muted);
    font-size:15px;
}

.home-stats__grid{
    display:grid;
    grid-template-columns:repeat(2, minmax(0, 1fr));
    gap:18px;
    max-width:820px;
    margin:0 auto;
}

.home-stat-card{
    position:relative;
    display:flex;
    align-items:center;
    gap:18px;
    min-width:0;
    padding:22px;
    overflow:hidden;
    background:#fff;
    border:1px solid var(--line);
    border-radius:18px;
    box-shadow:0 8px 24px rgba(17,24,39,.07);
    transition:
            transform .18s ease,
            box-shadow .2s ease,
            border-color .2s ease;
}

.home-stat-card:hover{
    transform:translateY(-2px);
    box-shadow:0 13px 30px rgba(17,24,39,.11);
}

.home-stat-card::after{
    content:"";
    position:absolute;
    right:-35px;
    bottom:-48px;
    width:125px;
    height:125px;
    border-radius:999px;
    opacity:.08;
    pointer-events:none;
}

.home-stat-card--members::after{
    background:var(--red);
}

.home-stat-card--owners::after{
    background:var(--green);
}

.home-stat-card--members:hover{
    border-color:#fecaca;
}

.home-stat-card--owners:hover{
    border-color:#a7f3d0;
}

.home-stat-card__icon{
    display:grid;
    place-items:center;
    width:62px;
    height:62px;
    border-radius:17px;
    font-size:24px;
    flex:0 0 62px;
}

.home-stat-card--members .home-stat-card__icon{
    background:#fef2f2;
    color:var(--red-dark);
}

.home-stat-card--owners .home-stat-card__icon{
    background:#ecfdf5;
    color:var(--green-dark);
}

.home-stat-card__content{
    position:relative;
    z-index:1;
    min-width:0;
}

.home-stat-card__number{
    display:block;
    color:var(--navy);
    font-size:32px;
    font-weight:800;
    line-height:1;
    font-variant-numeric:tabular-nums;
}

.home-stat-card__label{
    display:block;
    margin-top:6px;
    color:var(--ink);
    font-size:15px;
    font-weight:800;
}

.home-stat-card__content p{
    margin:5px 0 0;
    color:var(--muted);
    font-size:13px;
    line-height:1.45;
}

/* Mobile statistics layout */
@media (max-width:720px){
    .home-stats{
        padding:32px 0 36px;
    }

    .home-stats__grid{
        grid-template-columns:1fr;
        max-width:520px;
    }
}

@media (max-width:420px){
    .home-stat-card{
        align-items:flex-start;
        padding:18px;
    }

    .home-stat-card__icon{
        width:52px;
        height:52px;
        border-radius:14px;
        font-size:20px;
        flex-basis:52px;
    }

    .home-stat-card__number{
        font-size:27px;
    }
}

/* Dark theme */
[data-theme="dark"] .home-stats{
    background:
            radial-gradient(
                    70% 100% at 0 0,
                    rgba(225,6,0,.04),
                    transparent 55%
            ),
            radial-gradient(
                    70% 100% at 100% 100%,
                    rgba(0,161,20,.05),
                    transparent 55%
            ),
            #0c111b;
    border-bottom-color:var(--line);
}

[data-theme="dark"] .home-stat-card{
    background:#0e1420;
    border-color:var(--line);
    box-shadow:0 10px 28px rgba(0,0,0,.28);
}

[data-theme="dark"] .home-stat-card:hover{
    box-shadow:0 15px 34px rgba(0,0,0,.4);
}

[data-theme="dark"] .home-stat-card--members .home-stat-card__icon{
    background:#2a0b0b;
    color:#fca5a5;
}

[data-theme="dark"] .home-stat-card--owners .home-stat-card__icon{
    background:#06281d;
    color:#6ee7b7;
}

[data-theme="dark"] .home-stat-card__number,
[data-theme="dark"] .home-stats__intro h2{
    color:#e5e7eb;
}

[data-theme="dark"] .home-stat-card__label{
    color:#d1d5db;
}

/* ========================================================================
   Global community map
   ======================================================================== */

.home-map-section{
    padding:0 0 48px;
    background:#fff;
    border-bottom:1px solid var(--line);
}

.home-map-card{
    overflow:hidden;
    background:#fff;
    border:1px solid var(--line);
    border-radius:20px;
    box-shadow:0 10px 30px rgba(17,24,39,.08);
}

.home-map-card__header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:28px;
    padding:23px 26px;
    border-bottom:1px solid var(--line);
    background:
            linear-gradient(
                    135deg,
                    rgba(0,161,20,.055),
                    rgba(255,255,255,0) 42%
            ),
            #fff;
}

.home-map-card__intro{
    min-width:0;
    max-width:680px;
}

.home-map-card__eyebrow{
    margin:0 0 5px;
    color:var(--green-dark);
    font-size:13px;
    font-weight:700;
    letter-spacing:.08em;
    text-transform:uppercase;
}

.home-map-card__intro h2{
    margin:0;
    color:var(--navy);
    font-size:clamp(22px, 3vw, 30px);
    line-height:1.2;
}

.home-map-card__intro > p:last-child{
    margin:7px 0 0;
    color:var(--muted);
    font-size:14px;
}

.home-map-summary{
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:10px;
    flex-wrap:wrap;
}

.home-map-summary__item{
    display:flex;
    align-items:center;
    gap:10px;
    min-width:132px;
    padding:10px 12px;
    border:1px solid #d1fae5;
    border-radius:13px;
    background:#f0fdf4;
}

.home-map-summary__icon{
    display:grid;
    place-items:center;
    width:36px;
    height:36px;
    border-radius:10px;
    background:#fff;
    color:var(--green-dark);
    font-size:15px;
    box-shadow:0 4px 10px rgba(0,161,20,.08);
    flex:0 0 36px;
}

.home-map-summary__item strong{
    display:block;
    color:#065f46;
    font-size:18px;
    line-height:1;
    font-variant-numeric:tabular-nums;
}

.home-map-summary__item span:last-child{
    display:block;
    margin-top:4px;
    color:#047857;
    font-size:11px;
    font-weight:700;
    white-space:nowrap;
}

.home-map-card__body{
    position:relative;
    padding:20px 22px 17px;
    background:#f8fafc;
}

.home-world-map{
    width:100%;
    height:450px;
    overflow:hidden;
    border-radius:15px;
    /*
		Create a simplified Earth atmosphere/ocean effect:
		- Pale/white areas at the top and bottom suggest polar regions.
		- Blue through the center represents seas and oceans.
	*/
    background:
            linear-gradient(
                    180deg,
                    #f8fbff 0%,
                    #eef8ff 7%,
                    #b9e3f8 14%,
                    #7dc9ee 24%,
                    #57b5e6 50%,
                    #7dc9ee 76%,
                    #b9e3f8 86%,
                    #eef8ff 93%,
                    #f8fbff 100%
            );
}

/*
	JQVMap creates an SVG inside this container.
	Keep the SVG responsive inside the card.
*/
.home-world-map svg{
    display:block;
    width:100%;
    height:100%;
}

/* JQVMap hover tooltip. */
.jqvmap-label{
    z-index:1000;
    display:none;
    position:absolute;
    max-width:220px;
    padding:9px 11px;
    border:1px solid rgba(255,255,255,.14);
    border-radius:9px;
    background:rgba(15,23,42,.96);
    color:#fff;
    box-shadow:0 8px 22px rgba(15,23,42,.24);
    font-size:12px;
    line-height:1.35;
    pointer-events:none;
}

.jqvmap-label strong{
    display:block;
    margin-bottom:2px;
    font-size:13px;
}

.jqvmap-label span{
    display:block;
    color:#cbd5e1;
    font-size:11px;
}

/* Zoom controls are disabled, but keep them hidden defensively. */
.home-world-map .jqvmap-zoomin,
.home-world-map .jqvmap-zoomout{
    display:none;
}

.home-map-legend{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:9px;
    margin-top:13px;
}

.home-map-legend__label{
    color:var(--muted);
    font-size:11px;
    font-weight:700;
    white-space:nowrap;
}

.home-map-legend__gradient{
    display:block;
    width:150px;
    height:8px;
    border-radius:999px;
    background:linear-gradient(
            90deg,
            #dcfce7,
            #86efac,
            #22c55e,
            #047857
    );
    box-shadow:inset 0 0 0 1px rgba(15,23,42,.08);
}

/* Tablet */
@media (max-width:800px){
    .home-map-card__header{
        align-items:flex-start;
        flex-direction:column;
        padding:20px;
    }

    .home-map-summary{
        justify-content:flex-start;
        width:100%;
    }

    .home-map-card__body{
        padding:16px;
    }

    .home-world-map{
        height:360px;
    }
}

/* Mobile */
@media (max-width:520px){
    .home-map-section{
        padding-bottom:36px;
    }

    .home-map-summary{
        display:grid;
        grid-template-columns:repeat(2, minmax(0, 1fr));
    }

    .home-map-summary__item{
        min-width:0;
    }

    .home-world-map{
        height:285px;
    }

    .home-map-legend__gradient{
        width:95px;
    }
}

/* Dark theme */
[data-theme="dark"] .home-map-section{
    background:#0c111b;
    border-bottom-color:var(--line);
}

[data-theme="dark"] .home-map-card{
    background:#0e1420;
    border-color:var(--line);
    box-shadow:0 12px 32px rgba(0,0,0,.34);
}

[data-theme="dark"] .home-map-card__header{
    background:
            linear-gradient(
                    135deg,
                    rgba(0,161,20,.07),
                    rgba(14,20,32,0) 42%
            ),
            #0e1420;
    border-bottom-color:var(--line);
}

[data-theme="dark"] .home-map-card__intro h2{
    color:#e5e7eb;
}

[data-theme="dark"] .home-map-summary__item{
    background:#06281d;
    border-color:#14532d;
}

[data-theme="dark"] .home-map-summary__icon{
    background:#0b1220;
    color:#6ee7b7;
}

[data-theme="dark"] .home-map-summary__item strong{
    color:#a7f3d0;
}

[data-theme="dark"] .home-map-summary__item span:last-child{
    color:#6ee7b7;
}

[data-theme="dark"] .home-map-card__body{
    background:#0b1220;
}

[data-theme="dark"] .home-world-map{
    /*
		Night-ocean appearance.

		The center remains deep navy while the top and bottom retain
		a faint icy/polar highlight.
	*/
    background:
            linear-gradient(
                    180deg,
                    #dce8f4 0%,
                    #7893ac 5%,
                    #183750 13%,
                    #0d2942 24%,
                    #081a2e 50%,
                    #0d2942 76%,
                    #183750 87%,
                    #7893ac 95%,
                    #dce8f4 100%
            );
}

[data-theme="dark"] .home-map-legend__gradient{
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.08);
}

/* Section heading Font Awesome icons. */
.latest-seekers .section-head h2,
.latest-owners .section-head h2,
.categories .section-head h2{
    display:flex;
    align-items:center;
    gap:9px;
}

.latest-seekers .section-head h2 i{
    color:var(--red-special);
}

.latest-owners .section-head h2 i{
    color:var(--green);
}

.categories .section-head h2 i{
    color:var(--navy);
}

.link-more{
    display:inline-flex;
    align-items:center;
    gap:6px;
}

/* Latest request/listing category badges are now links. */
.home-category-link{
    display:inline-flex;
    align-items:center;
    text-decoration:none;
    font-weight:700;
}

.home-category-link:hover{
    filter:brightness(.92);
}

/* Make the card title itself clickable without changing the visual style. */
.seeker-title a,
.owner-title a{
    color:inherit;
    text-decoration:none;
}

.seeker-title a:hover,
.owner-title a:hover{
    text-decoration:underline;
    text-decoration-thickness:1px;
    text-underline-offset:3px;
}

/* Keep metadata icons aligned consistently. */
.seeker-meta > span,
.owner-meta > span{
    display:inline-flex;
    align-items:flex-start;
    gap:6px;
}

.seeker-meta i,
.owner-meta i{
    width:14px;
    margin-top:4px;
    color:var(--muted);
    text-align:center;
    flex:0 0 14px;
}

.seeker-meta .fa-wallet{
    color:var(--red);
}

.owner-meta .fa-tag{
    color:var(--green-grass);
}

.home-owner-name{
    display:flex;
    align-items:center;
    gap:7px;
    margin:0 0 8px;
    color:var(--green-grass);
    font-size:13px;
    font-weight:700;
}

.home-owner-name i{
    width:15px;
    text-align:center;
}

/* Make the latest card buttons slightly more descriptive. */
.seeker-card .seeker-btn,
.owner-card .owner-btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:7px;
}

/* Empty states span the complete responsive grid. */
.home-empty{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:10px;
    grid-column:1 / -1;
    min-height:110px;
    padding:24px;
    border:1px dashed #cbd5e1;
    border-radius:14px;
    background:#f8fafc;
    color:var(--muted);
    font-weight:700;
    text-align:center;
}

.home-empty i{
    color:var(--navy);
    font-size:20px;
}

/*
	Replace emoji bullets with controlled Font Awesome icons.
*/
.aud-list{
    list-style:none;
    padding-left:0;
}

.aud-list li{
    display:flex;
    align-items:flex-start;
    gap:9px;
}

.aud-list li i{
    width:18px;
    margin-top:4px;
    text-align:center;
    flex:0 0 18px;
}

.aud-card.seeker .aud-list i{
    color:var(--red-special2);
}

.aud-card.owner .aud-list i{
    color:var(--green-dark);
}

/* Featured category heading is clickable. */
.cat-col h3 a{
    color:inherit;
    text-decoration:none;
}

.cat-col h3 a:hover{
    color:var(--red);
}

/* Font Awesome arrow inside the category CTA. */
.cat-more{
    display:inline-flex;
    align-items:center;
    gap:6px;
}

/* Responsive home search/header refinements. */
@media (max-width:720px){
    /*
        When the search form becomes vertical, remove the desktop
        520px flex-basis from the main search input.
    */
    .hs-form > input[type="search"]{
        width:100%;
        min-width:0;
        height:var(--field-h);
        flex:0 0 var(--field-h);
    }

    .hs-country,
    .hs-city{
        width:100%;
        min-width:0;
        flex:1 1 auto;
    }

    .hs-form select{
        width:100%;
    }
}

/* Dark-theme home controls. */
[data-theme="dark"] .hs-form select{
    background:
            linear-gradient(45deg, transparent 50%, #94a3b8 50%)
            calc(100% - 17px) calc(50% - 2px) / 5px 5px no-repeat,
            linear-gradient(135deg, #94a3b8 50%, transparent 50%)
            calc(100% - 12px) calc(50% - 2px) / 5px 5px no-repeat,
            #0b1220;
    color:var(--black);
    border-color:var(--line);
}

[data-theme="dark"] .hs-form select option{
    background:#0b1220;
    color:#e5e7eb;
}

[data-theme="dark"] .home-owner-name{
    color:#6ee7b7;
}

[data-theme="dark"] .home-empty{
    background:#0e1420;
    border-color:#334155;
    color:#94a3b8;
}

[data-theme="dark"] .home-empty i{
    color:#c7d2fe;
}
