/**
 * Sokar destination (locations taxonomy) archive.
 * Loaded only on `is_tax('locations')` — see triply-child/functions.php.
 *
 * Goal: 4-up compact tour cards (was 1-per-row blog articles) on a clean
 * Sokar surface, reusing the BABE `.babe_items` / `.column-item` card markup.
 */

/* ---- Page surface + header ------------------------------------------- */
body:is(.tax-locations, .tax-types) .site-content > .col-full {
    width: 100%;
    max-width: 1540px;
    padding-right: clamp(18px, 3vw, 36px);
    padding-left: clamp(18px, 3vw, 36px);
}

body:is(.tax-locations, .tax-types) #primary.content-area {
    float: none;
    width: 100%;
    margin-right: 0;
    margin-left: 0;
}

body:is(.tax-locations, .tax-types) .sokar-destination-archive {
    width: min(1480px, 100%);
    margin: 0 auto;
    padding: clamp(28px, 4vw, 56px) 0 clamp(48px, 6vw, 84px);
}

body:is(.tax-locations, .tax-types) .sokar-destination-header {
    margin-bottom: clamp(24px, 3vw, 40px);
    text-align: center;
}

body:is(.tax-locations, .tax-types) .sokar-destination-eyebrow {
    display: inline-block;
    margin-bottom: 8px;
    color: #d99a2b;
    font-family: "Montserrat", Arial, sans-serif;
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .14em;
    text-transform: uppercase;
}

body:is(.tax-locations, .tax-types) .sokar-destination-title {
    margin: 0;
    color: #100d0a;
    font-family: "Playfair Display", Georgia, serif;
    font-size: clamp(2.2rem, 4.4vw, 3.8rem);
    font-weight: 900;
    line-height: .98;
    text-transform: uppercase;
}

body:is(.tax-locations, .tax-types) .taxonomy-description {
    max-width: 720px;
    margin: 14px auto 0;
    color: rgba(16, 13, 10, .66);
    font-weight: 600;
    line-height: 1.5;
}

/* ---- The 4-up grid ---------------------------------------------------- */
/* These cards carry `.column-item` (not `.babe_all_items_item`), which has no
   width rule on a non-Elementor page, so we set the column widths here. */
body:is(.tax-locations, .tax-types) .sc_all_items .babe_shortcode_block_bg_inner {
    padding: 0;
}

body:is(.tax-locations, .tax-types) .sc_all_items .babe_shortcode_block_title {
    display: none; /* empty title from the shortcode */
}

body:is(.tax-locations, .tax-types) .sc_all_items .babe_shortcode_block_inner {
    display: flex;
    flex-wrap: wrap;
    align-content: flex-start;
    justify-content: flex-start;
    gap: 26px 24px;
    padding: 0;
}

body:is(.tax-locations, .tax-types) .sc_all_items .column-item {
    flex: 0 0 calc((100% - 72px) / 4);
    max-width: calc((100% - 72px) / 4);
    margin: 0;
    padding: 0;
}

@media (max-width: 1199px) {
    body:is(.tax-locations, .tax-types) .sc_all_items .column-item {
        flex-basis: calc((100% - 48px) / 3);
        max-width: calc((100% - 48px) / 3);
    }
}

@media (max-width: 899px) {
    body:is(.tax-locations, .tax-types) .sc_all_items .column-item {
        flex-basis: calc((100% - 24px) / 2);
        max-width: calc((100% - 24px) / 2);
    }
}

@media (max-width: 599px) {
    body:is(.tax-locations, .tax-types) .sc_all_items .column-item {
        flex-basis: 100%;
        max-width: 100%;
    }
}

/* ---- Card polish (compact, Sokar identity) --------------------------- */
body:is(.tax-locations, .tax-types) .sc_all_items .babe_all_items_item_inner {
    height: 100%;
    overflow: hidden;
    background: rgba(255, 253, 247, .96);
    border: 1px solid rgba(33, 24, 17, .11);
    border-radius: 10px;
    box-shadow: 0 18px 42px rgba(99, 58, 8, .10);
    transition: transform .24s ease, box-shadow .24s ease, border-color .24s ease;
}

body:is(.tax-locations, .tax-types) .sc_all_items .babe_all_items_item_inner:hover {
    transform: translateY(-4px);
    border-color: rgba(243, 183, 67, .42);
    box-shadow: 0 26px 56px rgba(99, 58, 8, .16);
}

body:is(.tax-locations, .tax-types) .sc_all_items .item_img img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
}

body:is(.tax-locations, .tax-types) .sc_all_items .item_title a {
    color: #100d0a;
    font-family: "Montserrat", Arial, sans-serif;
    font-weight: 900;
    letter-spacing: 0;
    line-height: 1.18;
    text-transform: none;
}

body:is(.tax-locations, .tax-types) .sc_all_items .item_info_price_new,
body:is(.tax-locations, .tax-types) .sc_all_items .currency_amount {
    color: #b84825;
    font-weight: 900;
}

/* ---- Pagination + empty state ---------------------------------------- */
body:is(.tax-locations, .tax-types) .sc_all_items .babe_pager {
    margin-top: 14px;
    text-align: center;
}

body:is(.tax-locations, .tax-types) .sokar-destination-empty {
    margin: 30px auto 0;
    max-width: 560px;
    padding: 40px 26px;
    text-align: center;
    background: rgba(255, 253, 247, .96);
    border: 1px solid rgba(33, 24, 17, .11);
    border-radius: 10px;
}

body:is(.tax-locations, .tax-types) .sokar-destination-empty p {
    margin: 0 0 18px;
    color: rgba(16, 13, 10, .7);
    font-weight: 700;
}

body:is(.tax-locations, .tax-types) .sokar-destination-empty-cta {
    display: inline-flex;
    align-items: center;
    min-height: 46px;
    padding: 0 22px;
    color: #071827;
    font-weight: 900;
    background: #f3b743;
    border-radius: 8px;
    text-decoration: none;
}

body:is(.tax-locations, .tax-types) .sokar-destination-empty-cta:hover {
    background: #d99a2b;
}
