/* ── Country Travelers Page ── */

.country-travelers {
    --country-travelers-content-margin-top: -240px;
    --country-travelers-content-overlap-offset: 0px;
    background: #052330;
    color: #fff;
    min-height: 100vh;
    padding-bottom: 120px;
}

/* ── Hero ── */

.country-travelers__hero {
    position: relative;
    box-sizing: border-box;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.country-travelers__hero-bg {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.country-travelers__hero-bg::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(4, 23, 35, 0.18) 0%, rgba(4, 23, 35, 0.48) 100%);
}

.country-travelers__hero-shape {
    order: 2;
    position: relative;
    width: calc(100% - 40px);
    margin-top: 55px;
    margin-bottom: -78px;
    min-height: 291px;
    border-radius: 10px;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
    background: var(--Dark, #052330);
    max-width: 1920px;
    flex: none;
}

.country-travelers__hero-shape::after {
    content: "";
    position: absolute;
    top: 69%;
    left: 0;
    width: 100%;
    height: 90px;
    box-shadow: inset 0 -200px 300px -180px rgba(5, 35, 48, 0.45);
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.country-travelers__title-wrap {
    order: 1;
    position: relative;
    margin: 0 auto;
    width: min(894px, calc(100% - 80px));
    text-align: center;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 22px;
}

.country-travelers__title-country {
    display: block;
    margin: 0;
    text-align: center;
    font-family: Barlow, sans-serif;
    font-size: 110px;
    font-weight: 900;
    line-height: 1;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    white-space: normal;
}

.country-travelers__title-country-name {
    display: inline;
    white-space: normal;
    overflow-wrap: anywhere;
    text-wrap: balance;
}

.country-travelers__title-flag {
    display: inline-block;
    width: 40px;
    height: 30px
    border-radius: 2px;
    object-fit: cover;
    margin-top: 0;
    vertical-align: super;
}

/* ── Content area ── */

.country-travelers__content {
    position: relative;
    z-index: 3;
    max-width: 1920px;
    margin: calc(var(--country-travelers-content-margin-top) + var(--country-travelers-content-overlap-offset)) auto 0;
    padding: 0 60px;
}

.ai-prompt {
    display: flex;
    padding: 20px 32px;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    border-radius: 12px;
    background: rgba(5, 35, 48, 0.40);
    width: fit-content;
    margin: -111px auto 37px auto;
    position: relative;
    z-index: 3;
    backdrop-filter: blur(30px) saturate(1.2);
    width: min(100%, 760px);
    display: block;
    width: 500px;
    padding: 0;
    border: 0;
    background: transparent;
    backdrop-filter: none;
}

.ai-prompt .ask-jizo-search-bar {
    min-height: 56px;
}

.ai-prompt-link {
    display: flex;
    align-items: center;
    gap: 20px;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    text-align: center;
    cursor: pointer;
}

.ai-prompt-icon {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    align-self: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.ai-prompt-text-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    flex: 1 1 auto;
    text-align: center;
}

.ai-prompt-text {
    display: block;
    color: var(--White, #FFF);
    font-family: Inter;
    font-size: 14px;
    font-style: normal;
    font-weight: 700;
    line-height: 1.4;
    transition: opacity 0.3s ease, transform 0.3s ease;
    opacity: 0;
    transform: translateY(6px);
    will-change: opacity, transform;
}

.ai-prompt-text.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.ai-prompt-link:hover .ai-prompt-text,
.ai-prompt-link:focus-visible .ai-prompt-text {
    color: #FF6E42;
}

.ai-prompt-link:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 4px;
    border-radius: 8px;
}

.ai-prompt-link:active .ai-prompt-text {
    transform: translateY(1px);
}

/* ── Section header ── */

.country-travelers__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 62px;
}

.country-travelers__header-title {
    display: flex;
    align-items: center;
    gap: 20px;
    font-family: Inter, sans-serif;
    font-size: 40px;
    font-weight: 400;
    line-height: 1;
    text-transform: uppercase;
    /* white-space: nowrap; */
}

.country-travelers__header-label {
    color: #fff;
}

.country-travelers__header-count {
    color: #fc6433;
}

.country-travelers__header-total {
    color: rgba(255, 255, 255, 0.2);
}

.country-travelers__filter-btn {
    box-sizing: border-box;
    flex: 0 0 auto;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.09) 0%, rgba(255, 255, 255, 0.03) 100%);
    color: #fff;
    cursor: pointer;
    appearance: none;
    transition: border-color 0.2s ease, background 0.2s ease;
    position: relative;
}

.country-travelers__filter-btn:hover {
    border-color: rgba(109, 212, 255, 0.55);
    background: linear-gradient(180deg, rgba(111, 187, 223, 0.18) 0%, rgba(54, 122, 154, 0.14) 100%);
}

.country-travelers__filter-btn svg {
    width: 24px;
    height: 24px;
    display: block;
}

.country-travelers__filter-btn.is-active::after {
    content: "";
    position: absolute;
    top: -2px;
    right: -2px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fc6433;
    border: 2px solid #052330;
}

/* ── Filters bar ── */

.country-travelers__filters {
    display: none;
    margin-bottom: 20px;
    padding: 8px 20px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.country-travelers__filters.is-open {
    display: block;
}

.country-travelers__filters-row {
    display: flex;
    align-items: flex-start;
    gap: 28px;
}

.country-travelers__filter-group {
    flex: 1 1 0;
    min-width: 0;
}

.country-travelers__filter-label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 0;
    font-family: Inter, sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 24px;
    text-transform: uppercase;
    letter-spacing: 0.01em;
    color: #fff;
    cursor: pointer;
    background: none;
    border: none;
    appearance: none;
    white-space: nowrap;
}

.country-travelers__filter-label svg {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    opacity: 0.6;
}

.country-travelers__filter-label-arrow {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    opacity: 0.4;
    transition: transform 0.2s ease;
}

.country-travelers__filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 4px 0 8px;
}

.country-travelers__filter-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 36px;
    padding: 0 12px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.08);
    font-family: Inter, sans-serif;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    color: #fff;
    text-transform: uppercase;
    white-space: nowrap;
}

.country-travelers__filter-tag-flag {
    width: 20px;
    height: 14px;
    border-radius: 2px;
    object-fit: cover;
}

.country-travelers__filter-tag-icon {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    opacity: 0.6;
}

.country-travelers__filter-tag-remove {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.2s ease;
    background: none;
    border: none;
    padding: 0;
    color: #fff;
    appearance: none;
}

.country-travelers__filter-tag-remove:hover {
    opacity: 1;
}

.country-travelers__filter-tag-remove svg {
    width: 100%;
    height: 100%;
    display: block;
}

.country-travelers__filters-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 0 0 auto;
    padding-top: 40px;
}

.country-travelers__filters-clear {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.09) 0%, rgba(255, 255, 255, 0.03) 100%);
    color: #fff;
    cursor: pointer;
    appearance: none;
    transition: border-color 0.2s ease;
}

.country-travelers__filters-clear:hover {
    border-color: rgba(109, 212, 255, 0.55);
}

.country-travelers__filters-clear svg {
    width: 24px;
    height: 24px;
}

.country-travelers__filters-apply {
    height: 48px;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: none;
    background: #fc6433;
    color: #fff;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 400;
    text-transform: uppercase;
    cursor: pointer;
    appearance: none;
    transition: filter 0.2s ease;
}

.country-travelers__filters-apply:hover {
    filter: brightness(1.1);
}

/* ── Travelers grid ── */

.country-travelers__grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 4px;
}

/* ── Empty card placeholder ── */

.country-travelers__empty-card {
    position: relative;
    height: 220px;
    border-radius: 8px;
    background: linear-gradient(0deg, #052330 0%, #12313E 100%);
    box-shadow: 0 3px 4px 0 rgba(255, 255, 255, 0.15) inset, 0 4px 24px 0 rgba(0, 17, 25, 0.70);
}

/* ── Empty state ── */

.country-travelers__empty-state {
    padding: 0px 16px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

.country-travelers__empty-pin {
    width: 96px;
    height: 140px;
    position: relative;
    margin-bottom: 38px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.country-travelers__empty-pin-shape {
    width: 96px;
    height: 135px;
    display: block;
    filter: drop-shadow(0 10px 24px rgba(0, 17, 25, 0.4));
}

.country-travelers__empty-pin-avatar {
    position: absolute;
    z-index: 2;
    width: 84px;
    height: 84px;
    border-radius: 50%;
    overflow: hidden;
    border: 5px solid #fc6433;
    top: 5px;
    left: 6px;
}

.country-travelers__empty-pin-avatar img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.country-travelers__empty-title {
    margin: 0;
    text-align: center;
    text-transform: uppercase;
    color: #fff;
    font-family: Inter, sans-serif;
    font-size: 40px;
    font-weight: 700;
    line-height: 1.05;
}

.country-travelers__empty-title span {
    color: #fc6433;
}

.country-travelers__empty-actions {
    margin-top: 42px;
    display: flex;
    gap: 28px;
}

.country-travelers__empty-link {
    height: 48px;
    min-width: 182px;
    padding: 8px 32px 8px 24px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.09) 0%, rgba(255, 255, 255, 0.03) 100%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: #fff;
    font-family: Inter, sans-serif;
    font-size: 12px;
    font-weight: 700;
    line-height: 24px;
    letter-spacing: 0.01em;
    text-transform: uppercase;
    text-decoration: none;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.country-travelers__empty-link:hover {
    border-color: rgba(109, 212, 255, 0.55);
    background: linear-gradient(180deg, rgba(111, 187, 223, 0.18) 0%, rgba(54, 122, 154, 0.14) 100%);
    color: #fff;
    text-decoration: none;
}

.country-travelers__empty-link-icon {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.country-travelers__empty-link-icon svg {
    width: 24px;
    height: 24px;
    display: block;
}

/* ── Load more button ── */

.country-travelers__load-more {
    width: 100%;
    height: 68px;
    margin-top: 20px;
    padding: 16px 32px 16px 24px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.09) 0%, rgba(255, 255, 255, 0.03) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    color: #fff;
    appearance: none;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.country-travelers__load-more:hover {
    border-color: rgba(109, 212, 255, 0.55);
    background: linear-gradient(180deg, rgba(111, 187, 223, 0.18) 0%, rgba(54, 122, 154, 0.14) 100%);
}

.country-travelers__load-more.is-hidden {
    display: none;
}

.country-travelers__load-more-label {
    font-family: Inter, sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
}

.country-travelers__load-more-icon {
    width: 36px;
    height: 36px;
    color: #fff;
    transition: transform 0.2s ease;
}

@media (min-width: 1200px) {
    .country-travelers__title-flag {
        margin-bottom: 10px;
    }
}


/* ── Responsive: 1280px ── */

@media (max-width: 1400px) {
    .country-travelers__grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }

    .country-travelers__grid .country-user-card,
    .country-travelers__empty-card {
        height: 180px;
    }
}

@media (max-width: 1280px) {
    .country-travelers {
        --country-travelers-content-margin-top: -265px;
    }

    .country-travelers__title-country {
        font-size: 90px;
    }

    .country-travelers__empty-title {
        font-size: 34px;
    }
}

@media (max-width: 1100px) {
    .country-travelers {
        --country-travelers-content-margin-top: -275px;
    }
}

/* ── Responsive: 992px ── */

@media (max-width: 992px) {
    .country-travelers__hero {
        min-height: 268px;
    }

    .country-travelers__hero-shape {
        margin-top: 48px;
        min-height: 268px;
    }
    .ai-prompt {
        margin: -111px auto 25px auto;
    }
    .country-travelers__title-wrap {
        width: calc(100% - 30px);
    }

    .country-travelers__title-country {
        font-size: 62px;
    }

    .country-travelers__title-flag {
        width: 40px;
        height: 30px
        margin-top: 0;
    }

    .country-travelers__content {
        margin-top: -220px;
    }

    .country-travelers__empty-title {
        font-size: 28px;
    }

    .country-travelers__empty-actions {
        gap: 12px;
    }

    .country-travelers__empty-link {
        min-width: 170px;
        padding-right: 22px;
    }

    .country-travelers__header-title {
        font-size: 28px;
        gap: 12px;
    }

    .country-travelers__title-wrap {
        margin-top: 18px;
    }
}

/* ── Responsive: tablet (481–1200) ── */

@media (min-width: 481px) and (max-width: 1200px) {
    .country-travelers__header {
        margin-bottom: 40px;
    }
    .country-travelers__title-wrap {
        width: calc(100% - clamp(190px, calc(190px - (100vw - 768px) * 0.25463), 80px));
        gap: 10px;
    }

    .country-travelers__title-country {
        font-size: clamp(60px, calc(60px + (100vw - 768px) * 0.069444), 90px);
    }

    .country-travelers__title-flag {
        width: 40px;
        height: 30px
    }

    .country-travelers__grid {
        gap: 4px;
    }
}

@media (max-width: 920px) {
    .country-travelers__grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .country-travelers__grid .country-user-card,
    .country-travelers__empty-card {
        height: 160px;
    }
}

/* ── Responsive: mobile (≤640px) ── */

@media (max-width: 640px) {
    .ai-prompt {
        width: calc(100% - 5px);
        margin-top: 0;
        margin-bottom: 24px;
        min-height: unset;
    }
    .ai-prompt .ask-jizo-search-bar {
        min-height: unset;
    }


    .country-travelers {
        padding-bottom: 60px;
    }

    .country-travelers__hero {
        min-height: 200px;
    }

    .country-travelers__hero-shape {
        margin-top: 40px;
        width: 100%;
        min-height: 199px;
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-top-left-radius: 12px;
        border-top-right-radius: 12px;
    }
    .ask-jizo-search-bar { 
        padding: 6px !important;
    }

    .country-travelers__title-wrap {
        width: calc(100% - 20px);
    }

    .country-travelers__title-country {
        font-size: 40px;
    }

    .country-travelers__title-flag {
        width: 20px;
        height: 12.692px;
    }

    .country-travelers__content {
        margin-top: -140px;
        padding: 0 10px;
    }

    .country-travelers__header {
        margin-bottom: 14px;
    }

    .country-travelers__header-title {
        font-size: 20px;
        gap: 8px;
    }

    .country-travelers__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 4px;
    }

    .country-travelers__grid .country-user-card,
    .country-travelers__empty-card {
        height: 120px;
    }

    .country-travelers__empty-card {
        display: none;
    }

    .country-travelers__empty-state {
        min-height: 380px;
        padding: 34px 16px 20px;
    }

    .country-travelers__empty-pin {
        width: 78px;
        height: 114px;
        margin-bottom: 22px;
    }

    .country-travelers__empty-pin-shape {
        width: 78px;
        height: 110px;
    }

    .country-travelers__empty-pin-avatar {
        width: 62px;
        height: 62px;
        border-width: 4px;
        top: 5px;
        left: 8px;
    }

    .country-travelers__empty-title {
        font-size: 24px;
        line-height: 1.15;
        max-width: 350px;
    }

    .country-travelers__empty-actions {
        margin-top: 26px;
        width: 100%;
        flex-direction: column;
        gap: 10px;
    }

    .country-travelers__empty-link {
        width: 100%;
        min-width: 0;
        padding-left: 18px;
        padding-right: 18px;
    }

    .country-travelers__load-more {
        height: 54px;
        padding: 12px 20px;
        gap: 8px;
    }

    .country-travelers__load-more-label {
        font-size: 14px;
    }

    .country-travelers__load-more-icon {
        width: 24px;
        height: 24px;
    }

    .country-travelers__filters-row {
        flex-direction: column;
        gap: 8px;
    }

    .country-travelers__filters-actions {
        padding-top: 12px;
        justify-content: flex-end;
        width: 100%;
    }

    .country-travelers__filter-btn {
        width: 40px;
        height: 40px;
        padding: 8px;
    }
}


.country-travelers__empty-card {
    display: none !important;
}
