/* Home page (includes/home-design.php): what differs from the Location page. The tokens, the search bar, the category
   chips, the cards, the section titles and the pills come from search-design.css and archive-design.css. Scoped to
   body.abv-home. Every section is a group block with the class abv-band; its title row a group with abv-band-head. */

.abv-home {
    --abv-home-gap: 4.5rem;
    --abv-home-title: 1.75rem;
}

/* The page's blocks sit one under the other with their own spaces */
.abv-home .entry-content {
    padding-bottom: 5rem;
}
.abv-home .entry-content > *,
.abv-home .abv-band > *,
.abv-home .abv-home-finder > * {
    margin-block: 0;
}
/* The theme indents paragraphs on phones; here they line up with their headings */
.abv-home :is(.abv-home-hero, .abv-home-finder, .abv-band) p {
    padding-inline: 0;
}
.abv-home .entry-content > .abv-band {
    margin-top: var(--abv-home-gap) !important;
}
.abv-home .abv-band-title {
    font-size: var(--abv-home-title);
    letter-spacing: -.01em;
}
.abv-home:lang(fa) .abv-band-title {
    letter-spacing: 0;
}
.abv-home .abv-band-head + * {
    margin-top: 0;
}
/* A section's "See all" link written in the editor: the Location page's pill */
.abv-home .abv-home-more {
    margin: 0;
}
.abv-home .abv-home-more a {
    display: inline-flex;
    align-items: center;
    height: 2.5rem;
    padding: calc(2 * var(--abv-drop)) var(--abv-s4) 0;
    border: 1px solid var(--abv-edge);
    border-radius: var(--abv-r-full);
    background: var(--abv-surface);
    color: var(--abv-ink) !important;
    font-size: .9375rem;
    font-weight: 600;
    line-height: 1;
    text-decoration: none !important;
    white-space: nowrap;
    transition: background-color var(--abv-fast) var(--abv-ease), border-color var(--abv-fast) var(--abv-ease);
}
.abv-home .abv-home-more a:hover {
    border-color: var(--abv-ink);
    background: #f7f7f8;
}
.abv-home .abv-home-more a:focus-visible {
    outline: var(--abv-focus);
    outline-offset: 3px;
}

/* The site's Additional CSS takes away the space under the fixed site header on this page (.page-id-51 #content, made
   for the old photo header that ran under it): the page starts under the header again, as every other page does */
body.abv-home #content {
    padding-top: 76px !important;
}
/* The theme's content column pads the page on smaller screens (30px above, 10px each side): the home's bands keep
   their own spacing */
body.abv-home #primary.content-area {
    padding: 0 !important;
}
body.abv-home #content {
    padding-inline: 0 !important;
}

/* Header: a warm band across the page, without a photo (owner, 2026-11-18); the heading, the sentence, the search bar
   and the chips in its middle */
.abv-home .abv-home-hero {
    margin: 0 !important;
    padding: 2.5rem 0 5.25rem !important;
    background: #fff4eb;
    text-align: center;
}
.abv-home .abv-home-hero > .wp-block-group__inner-container {
    box-sizing: border-box;
    width: min(100% - 2 * var(--abv-s6), 72rem);
    margin-inline: auto;
}
.abv-home .abv-home-hero h1 {
    max-width: 16em;
    margin: 0 auto var(--abv-s4);
    color: var(--abv-ink);
    font-size: clamp(2.125rem, 1.2rem + 2.7vw, 3.5rem);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -.02em;
    text-wrap: balance;
}
/* The line above the heading and the sentence under it */
.abv-home .abv-home-hero p.abv-home-kicker {
    width: fit-content;
    margin: 0 auto var(--abv-s3);
    /* Red, white and green from where the line starts (owner, 2026-11-18); the thin dark edge keeps the white
       letters readable on the light band */
    background: linear-gradient(to right, #da0000 15%, #fff 50%, #239f40 85%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: clamp(1rem, .9rem + .3vw, 1.125rem);
    font-weight: 800;
    /* light, so the red and green keep their own colour */
    text-shadow: 0 0 1px rgb(0 0 0 / 16%);
}
[dir="rtl"] .abv-home .abv-home-hero p.abv-home-kicker {
    background-image: linear-gradient(to left, #da0000 15%, #fff 50%, #239f40 85%);
}
.abv-home .abv-home-hero p.abv-home-discover {
    margin: 0 auto var(--abv-s2);
    color: var(--abv-ink);
    font-size: clamp(1.125rem, 1rem + .5vw, 1.375rem);
    font-weight: 600;
}
.abv-home:lang(fa) .abv-home-hero h1 {
    line-height: 1.4;
    letter-spacing: 0;
}
.abv-home .abv-home-hero p {
    max-width: 36em;
    margin: 0 auto;
    color: var(--abv-muted);
    font-size: clamp(1.0625rem, .95rem + .4vw, 1.25rem);
    line-height: 1.55;
    text-wrap: pretty;
}

/* Search bar, chips and the line for business owners: the bar on the band's lower edge, all in the middle */
.abv-home .abv-home-finder {
    position: relative;
    z-index: 3;
    box-sizing: border-box;
    width: min(100% - 2 * var(--abv-s6), 72rem);
    margin: -2.25rem auto 0 !important;
}
.abv-home .abv-home-finder {
    text-align: center;
}
.abv-home .abv-home-finder .geodir-search-container {
    max-width: 50rem;
    margin-inline: auto;
    padding: var(--abv-s2);
    text-align: start;
    border-radius: calc(var(--abv-r-container) + var(--abv-s2));
    background: var(--abv-surface);
    box-shadow: var(--abv-shadow-high);
}
/* The theme gives forms a bottom margin on phones, and the bar's grid a gap above the fields: the card's own padding
   is the only space around them */
.abv-home .abv-home-finder .geodir-listing-search {
    margin: 0 !important;
}
.abv-home .abv-home-finder .geodir-search > * {
    margin-top: 0 !important;
}
.abv-home .abv-home-finder .geodir-search::after {
    display: none;
}
.abv-home .abv-home-finder .geodir-search .form-control,
.abv-home .abv-home-finder .geodir-search .geodir_submit_search {
    height: 3.5rem;
}
.abv-home .abv-home-finder .geodir-search .geodir_submit_search {
    width: 4rem !important;
}
.abv-home .abv-home-finder .gd-categories-widget {
    margin: var(--abv-s5) 0 0 !important;
}
.abv-home .abv-home-finder .gd-categories-widget .row {
    justify-content: center;
    gap: var(--abv-s1-5);
}
/* The numbers sentence, right under the search bar */
.abv-home .abv-home-finder p.abv-home-numbers {
    margin: var(--abv-s3) auto 0;
    color: var(--abv-muted);
    font-size: .9375rem;
    line-height: 1.5;
}
.abv-home .abv-home-owner {
    margin-top: var(--abv-s4);
    color: var(--abv-muted);
    font-size: .9375rem;
}
.abv-home .abv-home-owner a,
.abv-home .abv-band p a:not([class]) {
    color: #017f4c;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.abv-home .abv-home-owner a:hover,
.abv-home .abv-band p a:not([class]):hover {
    color: #015c37;
}

/* Recently added: the Location page's two columns of cards */
.abv-home .abv-home-places .geodir-loop-container {
    margin: 0 !important;
}

/* Cities and countries */
.abv-home .abv-home-subtitle {
    margin: var(--abv-s8) 0 var(--abv-s3);
    color: var(--abv-ink);
    font-size: 1.125rem;
    font-weight: 700;
}
.abv-home .abv-home-country-list .abv-pill {
    height: 2.25rem;
    font-size: .875rem;
}

/* Upcoming events: photo with the date on it, name, day and time, place; the whole card opens the event */
.abv-home .abv-event-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(15.5rem, 1fr));
    gap: var(--abv-s8) var(--abv-s6);
    margin: 0;
    padding: 0;
    list-style: none;
}
.abv-home .abv-event {
    position: relative;
    margin: 0;
}
.abv-home .abv-event-photo {
    overflow: hidden;
    aspect-ratio: 3 / 2;
    border-radius: var(--abv-r-container);
    background: #efe9e3;
}
.abv-home .abv-event-photo img,
.abv-home .abv-home-posts .wp-block-post-featured-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--abv-medium) var(--abv-ease);
}
.abv-home .abv-event-nophoto {
    display: grid;
    place-items: center;
    height: 100%;
    color: #c8bdb2;
    font-size: 2rem;
}
.abv-home .abv-event-nophoto::before {
    content: "\f133";
    font: var(--fa-font-regular);
}
.abv-home .abv-event-date {
    position: absolute;
    top: var(--abv-s3);
    inset-inline-start: var(--abv-s3);
    margin: 0;
}
.abv-home .abv-event-date time {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 3.25rem;
    padding: var(--abv-s1-5) var(--abv-s2);
    border-radius: var(--abv-r-element);
    background: var(--abv-surface);
    box-shadow: var(--abv-shadow-low);
    color: var(--abv-ink);
    line-height: 1.15;
    text-align: center;
}
.abv-home .abv-event-day {
    font-size: 1.375rem;
    font-weight: 800;
}
.abv-home .abv-event-month {
    color: #b93b0b;
    font-size: .75rem;
    font-weight: 700;
}
.abv-home .abv-event-title {
    margin: var(--abv-s4) 0 var(--abv-s1);
    font-size: 1.0625rem;
    font-weight: 700;
    line-height: 1.4;
}
.abv-home .abv-event-title a,
.abv-home .abv-home-posts .wp-block-post-title a {
    color: var(--abv-ink) !important;
    text-decoration: none;
}
/* The name's link covers the whole card */
.abv-home .abv-event-title a::after,
.abv-home .abv-home-posts .wp-block-post-title a::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: var(--abv-r-container);
}
.abv-home .abv-event-title a:focus-visible,
.abv-home .abv-home-posts .wp-block-post-title a:focus-visible {
    outline: 0;
}
.abv-home .abv-event-title a:focus-visible::after,
.abv-home .abv-home-posts .wp-block-post-title a:focus-visible::after {
    outline: var(--abv-focus);
    outline-offset: 4px;
}
.abv-home .abv-event-meta {
    display: flex;
    flex-direction: column;
    margin: 0;
    color: var(--abv-muted);
    font-size: .9375rem;
    line-height: 1.5;
}
@media (hover: hover) {
    .abv-home .abv-event:hover .abv-event-photo img,
    .abv-home .abv-home-posts .wp-block-post:hover .wp-block-post-featured-image img {
        transform: scale(1.03);
    }
    .abv-home .abv-event:hover .abv-event-title a,
    .abv-home .abv-home-posts .wp-block-post:hover .wp-block-post-title a {
        text-decoration: underline;
        text-underline-offset: 3px;
    }
}

/* No event coming: an invitation to add one, the text beside its buttons. The theme keeps the group's inner box. */
.abv-home .abv-home-no-events {
    padding: var(--abv-s8);
}
.abv-home :is(.abv-home-no-events, .abv-home-no-events > .wp-block-group__inner-container) {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--abv-s4) var(--abv-s8);
}
.abv-home .abv-home-no-events > .wp-block-group__inner-container {
    flex: 1 1 100%;
}
.abv-home .abv-home-no-events p {
    flex: 1 1 26rem;
    max-width: 40rem;
    margin: 0;
}
.abv-home .abv-home-no-events .wp-block-buttons {
    flex: 0 0 auto;
    margin: 0;
}

/* Magazine: the latest posts as cards, photo on top */
.abv-home .abv-home-posts .wp-block-post-template {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--abv-s8) var(--abv-s6);
    margin: 0;
    padding: 0;
    list-style: none;
}
.abv-home .abv-home-posts .wp-block-post {
    position: relative;
    margin: 0;
}
.abv-home .abv-home-posts .wp-block-post-featured-image {
    overflow: hidden;
    aspect-ratio: 3 / 2;
    margin: 0;
    border-radius: var(--abv-r-container);
    background: #efe9e3;
}
/* Another plugin wraps featured images in a figure of its own */
.abv-home .abv-home-posts .wp-block-post-featured-image > figure {
    height: 100%;
    margin: 0;
}
.abv-home .abv-home-posts .wp-block-post-title {
    margin: var(--abv-s4) 0 var(--abv-s1);
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1.45;
}
.abv-home .abv-home-posts .wp-block-post-date {
    margin: 0;
    color: var(--abv-muted);
    font-size: .875rem;
}

/* Ways to take part: one warm panel, three columns with a line between them */
.abv-home .abv-home-take {
    padding: 2.75rem var(--abv-s8) var(--abv-s8);
    border-radius: var(--abv-r-page);
    background: #fff4eb;
}
.abv-home .abv-home-take .wp-block-columns {
    gap: 0;
    margin: var(--abv-s6) 0 0;
}
.abv-home .abv-home-take .wp-block-column {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: var(--abv-s2) var(--abv-s8);
    border-inline-start: 1px solid rgb(0 0 0 / 9%);
}
.abv-home .abv-home-take .wp-block-column:first-child {
    padding-inline-start: 0;
    border-inline-start: 0;
}
.abv-home .abv-home-take .wp-block-column:last-child {
    padding-inline-end: 0;
}
.abv-home .abv-take::before {
    display: grid;
    place-items: center;
    width: 3rem;
    height: 3rem;
    margin-bottom: var(--abv-s4);
    border-radius: var(--abv-r-full);
    background: var(--abv-surface);
    box-shadow: var(--abv-shadow-low);
    color: #e25a00;
    font: var(--fa-font-solid);
    font-size: 1.125rem;
}
.abv-home .abv-take-business::before {
    content: "\f54e";
}
.abv-home .abv-take-event::before {
    content: "\f783";
}
.abv-home .abv-take-account::before {
    content: "\f234";
}
.abv-home .abv-take h3 {
    margin: 0 0 var(--abv-s2);
    color: var(--abv-ink);
    font-size: 1.1875rem;
    font-weight: 700;
    line-height: 1.35;
}
.abv-home .abv-take p {
    margin: 0 0 var(--abv-s5);
    color: #3b3f45;
    font-size: 1rem;
    line-height: 1.6;
}
.abv-home .abv-take .wp-block-buttons {
    margin-top: auto;
}
/* The event and account buttons: the business button's two-tone gradient and hover, in their own colours (green for
   events, blue for the account) */
.abv-home .abv-take-event { --abv-take-a: #0b8a55; --abv-take-b: #2cc37e; }
.abv-home .abv-take-account { --abv-take-a: #0a5fc2; --abv-take-b: #3a9bff; }
.abv-home .abv-band :is(.abv-take-event, .abv-take-account) .wp-block-button .wp-block-button__link {
    border: 0;
    background: linear-gradient(to left, var(--abv-take-a), var(--abv-take-b));
    box-shadow: var(--abv-orange-rest);
    color: #fff !important;
    transition: box-shadow var(--abv-medium) ease;
}
[dir="rtl"] .abv-home .abv-band :is(.abv-take-event, .abv-take-account) .wp-block-button .wp-block-button__link {
    background: linear-gradient(to right, var(--abv-take-a), var(--abv-take-b));
}
.abv-home .abv-band :is(.abv-take-event, .abv-take-account) .wp-block-button .wp-block-button__link:is(:hover, :focus) {
    border: 0;
    background: linear-gradient(to left, var(--abv-take-a), var(--abv-take-b));
    box-shadow: inset 0 0 0 100vmax rgb(0 0 0 / 18%);
}
[dir="rtl"] .abv-home .abv-band :is(.abv-take-event, .abv-take-account) .wp-block-button .wp-block-button__link:is(:hover, :focus) {
    background: linear-gradient(to right, var(--abv-take-a), var(--abv-take-b));
}

/* Members already have an account: its column is left out */
.abv-home.logged-in .abv-take-account {
    display: none;
}

/* Buttons: the site's orange button, and a white one with a line */
.abv-home .abv-band .wp-block-buttons {
    gap: var(--abv-s2) var(--abv-s3);
}
.abv-home .abv-band .wp-block-button__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 3rem;
    padding: calc(2 * var(--abv-drop)) var(--abv-s6) 0;
    border: 0;
    border-radius: var(--abv-r-full);
    background: var(--abv-gradient);
    box-shadow: var(--abv-orange-rest);
    color: #fff !important;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: box-shadow var(--abv-medium) ease;
}
.abv-home .abv-band .wp-block-button__link:hover,
.abv-home .abv-band .wp-block-button__link:focus {
    box-shadow: var(--abv-orange-hover);
}
.abv-home .abv-band .is-style-outline .wp-block-button__link {
    border: 1px solid var(--abv-edge);
    background: var(--abv-surface);
    box-shadow: none;
    color: var(--abv-ink) !important;
    transition: background-color var(--abv-medium) var(--abv-ease), border-color var(--abv-medium) var(--abv-ease);
}
.abv-home .abv-band .is-style-outline .wp-block-button__link:hover,
.abv-home .abv-band .is-style-outline .wp-block-button__link:focus {
    border-color: var(--abv-ink);
    background: #f7f7f8;
}
.abv-home .abv-band .wp-block-button__link:focus-visible,
.abv-home .abv-home-owner a:focus-visible,
.abv-home .abv-band p a:focus-visible {
    outline: var(--abv-focus);
    outline-offset: 3px;
}

/* Tablets: two columns of event and magazine cards */
@media (max-width: 1023px) {
    .abv-home .abv-home-posts .wp-block-post-template {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .abv-home .abv-home-take .wp-block-columns {
        flex-wrap: wrap !important;
    }
    .abv-home .abv-home-take .wp-block-column {
        flex-basis: 100% !important;
        padding: var(--abv-s6) 0;
        border-inline-start: 0;
        border-top: 1px solid rgb(0 0 0 / 9%);
    }
    .abv-home .abv-home-take .wp-block-column:first-child {
        padding-top: 0;
        border-top: 0;
    }
}

/* Phones */
@media (max-width: 781px) {
    .abv-home {
        --abv-home-gap: 3rem;
        --abv-home-title: 1.375rem;
    }
    .abv-home .abv-home-hero {
        padding: 1.75rem 0 4.25rem !important;
    }
    .abv-home .abv-home-hero > .wp-block-group__inner-container,
    .abv-home .abv-home-finder {
        width: calc(100% - 2 * var(--abv-s4));
    }
    .abv-home .abv-home-finder {
        margin-top: -2rem !important;
    }
    .abv-home .abv-home-finder .geodir-search-container {
        padding: var(--abv-s1-5);
    }
    .abv-home .abv-home-finder .geodir-search .form-control,
    .abv-home .abv-home-finder .geodir-search .geodir_submit_search {
        height: 3rem;
    }
    .abv-home .abv-home-finder .geodir-search .geodir_submit_search {
        width: 3.25rem !important;
    }
    /* What and the button on the first line, Near under them: both fields wide enough for their words, and the
       suggestions that open under What never cover the button */
    .abv-home .abv-home-finder .geodir-search {
        row-gap: var(--abv-s1-5) !important;
    }
    .abv-home .abv-home-finder .geodir-search .gd-search-field-near {
        order: 3;
        flex: 1 1 100% !important;
    }
    .abv-home .abv-home-finder .geodir-search .gd-search-field-near .form-control {
        border-inline-start: 1px solid var(--abv-edge);
        border-radius: var(--abv-r-container);
    }
    /* The chips in one row to swipe, as on the Location page */
    .abv-home .abv-home-finder .gd-categories-widget .row {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
        overscroll-behavior-x: contain;
        margin-inline: calc(-1 * var(--abv-s4)) !important;
        padding: 2px var(--abv-s4) var(--abv-s2) !important;
        scroll-padding-inline: var(--abv-s4);
        scrollbar-width: none;
    }
    .abv-home .abv-home-finder .gd-categories-widget .row::-webkit-scrollbar {
        display: none;
    }
    .abv-home .abv-home-finder .gd-cptcat-li-sub-container {
        display: none !important;
    }
    .abv-home .entry-content > .abv-band {
        width: calc(100% - 2 * var(--abv-s4));
    }
    /* Cities and countries: two rows of pills to swipe through, so the section stays short */
    .abv-home .abv-home-cities .abv-pill-list {
        display: grid;
        grid-template-rows: repeat(2, auto);
        grid-auto-flow: column;
        grid-auto-columns: max-content;
        overflow-x: auto;
        overscroll-behavior-x: contain;
        margin-inline: calc(-1 * var(--abv-s4));
        padding: 0 var(--abv-s4) var(--abv-s1);
        scroll-padding-inline: var(--abv-s4);
        scrollbar-width: none;
    }
    .abv-home .abv-home-cities .abv-pill-list::-webkit-scrollbar {
        display: none;
    }
    /* Events and posts as a row to swipe through */
    .abv-home .abv-event-list,
    .abv-home .abv-home-posts .wp-block-post-template {
        grid-auto-flow: column;
        grid-auto-columns: 78%;
        grid-template-columns: none;
        gap: var(--abv-s4);
        overflow-x: auto;
        overscroll-behavior-x: contain;
        scroll-snap-type: x mandatory;
        margin-inline: calc(-1 * var(--abv-s4));
        padding: 0 var(--abv-s4) var(--abv-s2);
        scroll-padding-inline: var(--abv-s4);
        scrollbar-width: none;
    }
    .abv-home .abv-event,
    .abv-home .abv-home-posts .wp-block-post {
        scroll-snap-align: start;
    }
    .abv-home .abv-home-no-events {
        padding: var(--abv-s5);
    }
    .abv-home .abv-home-take {
        padding: var(--abv-s8) var(--abv-s5) var(--abv-s5);
        border-radius: var(--abv-r-container);
    }
}

/* Narrow phones: buttons across the width, easy to reach with a thumb */
@media (max-width: 599px) {
    .abv-home .abv-home-take .wp-block-column {
        align-items: stretch;
    }
    .abv-home .abv-home-no-events .wp-block-buttons {
        flex: 1 1 100%;
    }
    .abv-home .abv-band .wp-block-button,
    .abv-home .abv-band .wp-block-button__link {
        flex: 1 1 100%;
        width: 100%;
    }
}

/* Button labels as Tripadvisor centres them (owner's test, 2026-11-18): the button a flex box that centres its line,
   no trimming and no shift */
.abv-home .abv-band .wp-block-button__link,
.abv-home .abv-home-more a,
.abv-home .abv-pill {
    --abv-drop: 0em;
    align-items: center;
    padding-block: 0;
}

/* Arrows on the event and magazine rows that swipe on phones (assets/chip-arrows.js): on the middle of the photos (a
   card is 78% of the row, its photo 3:2), no fade over the cards */
.abv-home .abv-card-row .abv-chip-arrow {
    top: calc(26vw);
}
.abv-home .abv-card-row .abv-chip-arrow::before {
    display: none;
}
.abv-home .abv-card-row .abv-chip-arrow-prev {
    inset-inline-start: calc(-1 * var(--abv-s2));
}

