/* The Guide: area page extras (taxonomy-ec_area.php, inc/ec-area-page.php)
   Enqueued on ec_area pages only, after css/style.css. Written without
   nesting so the .scss and .css are identical and ship without a build step.

   - Hero: "This weekend" chip, booking-link disclosure on the dark hero
   - Compact "Plan your trip" strip under the hero
   - Byline and "At a glance" facts box in the guide
   - Listing cards wrapped with an optional Book / Check rates button
   - Denser List view for "Every place" */

/* ── Hero: weekend chip ─────────────────────────────────────────────── */
.ec-tax-hero__weekend {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-left: 10px;
    padding: 7px 14px;
    border-radius: 100px;
    background: var(--ec-accent-lt);
    color: var(--ec-hero-bg);
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.1;
    text-decoration: none;
    vertical-align: middle;
    transition: background 0.15s ease, color 0.15s ease;
}

.ec-tax-hero__weekend:hover,
.ec-tax-hero__weekend:focus-visible {
    background: #fff;
    color: var(--ec-hero-bg);
}

/* ── Hero: booking-link disclosure (short variant, dark background) ── */
.ec-tax-hero .ec-disclosure {
    max-width: 640px;
    margin: 14px 0 0;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.1);
    border-left: 3px solid var(--ec-accent-lt);
}

.ec-tax-hero .ec-disclosure p,
.ec-tax-hero .ec-disclosure a,
.ec-tax-hero .ec-disclosure__more {
    color: #fff;
    font-size: 14px;
    line-height: 1.5;
}

/* ── Compact "Plan your trip" strip ─────────────────────────────────── */
.ec-area-plan--compact {
    border-bottom: 1px solid var(--ec-border);
}

.ec-area-plan--compact .ec-area-plan__inner {
    display: flex;
    align-items: center;
    gap: 12px 20px;
    padding: 18px 24px;
}

.ec-area-plan--compact .ec-area-plan__heading {
    flex: none;
    font-size: 1.15rem;
    margin: 0;
}

.ec-area-plan--compact .ec-area-plan__list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.ec-area-plan--compact .ec-area-plan__card {
    flex-direction: row;
    padding: 9px 14px;
    border-radius: 100px;
}

.ec-area-plan--compact .ec-area-plan__title {
    font-size: 14px;
    white-space: nowrap;
}

.ec-area-plan--compact .ec-area-plan__desc {
    display: none;
}

@media only screen and (min-width: 801px) {
    .ec-area-plan--compact .ec-area-plan__inner {
        padding: 18px 40px;
    }
}

@media only screen and (max-width: 800px) {
    .ec-area-plan--compact .ec-area-plan__inner {
        flex-direction: column;
        align-items: flex-start;
        padding: 16px 5%;
    }

    .ec-area-plan--compact .ec-area-plan__list {
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: none;
        max-width: 100%;
        padding-bottom: 2px;
    }

    .ec-area-plan--compact .ec-area-plan__list::-webkit-scrollbar {
        display: none;
    }

    .ec-area-plan--compact .ec-area-plan__list li {
        flex: none;
    }
}

/* ── Byline ─────────────────────────────────────────────────────────── */
.ec-area-byline {
    margin: 0 0 20px;
    padding: 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--ec-muted);
}

.ec-area-byline a {
    color: var(--ec-muted);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ec-area-byline a:hover {
    color: var(--ec-accent);
}

/* ── At a glance ────────────────────────────────────────────────────── */
.ec-area-facts {
    box-sizing: border-box;
    margin: 0 0 28px;
    padding: 20px 22px;
    border: 1px solid var(--ec-border);
    border-radius: 12px;
    background: var(--ec-surface);
}

.ec-area-facts__heading {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.2rem;
    font-weight: 600;
    line-height: 1.2;
    margin: 0 0 12px;
    padding: 0 !important;
    color: var(--ec-ink);
}

.ec-area-facts__list {
    margin: 0;
    padding: 0;
}

.ec-area-facts__row {
    display: grid;
    grid-template-columns: 38% 1fr;
    gap: 12px;
    padding: 9px 0;
    border-top: 1px solid var(--ec-border);
}

.ec-area-facts__row:first-child {
    border-top: none;
    padding-top: 0;
}

.ec-area-facts__row dt {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ec-muted);
    margin: 0;
}

.ec-area-facts__row dd {
    font-size: 14.5px;
    line-height: 1.45;
    color: var(--ec-ink);
    margin: 0;
}

@media only screen and (min-width: 1000px) {
    .ec-area-facts {
        float: right;
        width: 340px;
        margin: 0 0 28px 40px;
    }

    .ec-area-guide__section {
        clear: both;
    }
}

/* ── Listing cards: wrapper + Book / Check rates ────────────────────── */
.ec-biz-card-wrap {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.ec-biz-card-wrap[hidden] {
    display: none;
}

.ec-biz-card-wrap > .ec-biz-card {
    flex: 1;
}

/* ── "Every place": List view ───────────────────────────────────────── */
.ec-tax-grid.ec-tax-grid--list {
    grid-template-columns: 1fr;
    gap: 10px;
}

@media only screen and (min-width: 801px) {
    .ec-tax-grid.ec-tax-grid--list {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px 24px;
    }
}

.ec-tax-grid--list .ec-biz-card {
    flex-direction: row;
    align-items: stretch;
    border-radius: 10px;
}

.ec-tax-grid--list .ec-biz-card:hover {
    transform: none;
}

/* The thumbnail fills a fixed-width column; absolute positioning stops the
   <img> height attribute (e.g. 1500) from setting the row height. */
.ec-tax-grid--list .ec-biz-card__img-wrap {
    position: relative;
    flex: none;
    width: 150px;
    min-height: 120px;
    overflow: hidden;
}

@media only screen and (max-width: 540px) {
    .ec-tax-grid--list .ec-biz-card__img-wrap {
        width: 112px;
    }
}

.ec-tax-grid--list .ec-biz-card__img,
.ec-tax-grid--list img.ec-biz-card__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
    object-fit: cover;
    border-radius: 0;
}

.ec-tax-grid--list .ec-biz-card__price,
.ec-tax-grid--list .ec-biz-card__img-wrap > :not(.ec-biz-card__img) {
    display: none;
}

.ec-tax-grid--list .ec-biz-card__body {
    padding: 10px 14px;
    min-width: 0;
}

.ec-tax-grid--list .ec-biz-card__meta-row {
    margin-bottom: 3px;
}

.ec-tax-grid--list .ec-biz-card__name {
    font-size: 1.05rem;
}

.ec-tax-grid--list .ec-biz-card__pills {
    margin-top: 8px;
}

.ec-tax-grid--list .ec-biz-card__tagline {
    margin-top: 3px;
    font-size: 13px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

/* Grid names are <p> when the guide above already has the H3 cards */
p.ec-biz-card__name {
    margin: 0;
    padding: 0;
}

/* Hero chip: beat the hero's generic underlined-link rule */
.ec-tax-hero .ec-tax-hero__weekend,
.ec-tax-hero .ec-tax-hero__weekend:hover {
    text-decoration: none;
}

/* ── Phones: shorter hero (was ~1,060px on a 375x812 screen, now ~760px) ── */
@media only screen and (max-width: 600px) {
    .ec-tax-hero__inner {
        padding-top: 32px;
        padding-bottom: 28px;
        gap: 18px;
    }

    .ec-tax-hero__dek {
        font-size: 15px;
        line-height: 1.5;
    }

    .ec-tax-hero .ec-disclosure {
        margin-top: 12px;
        padding: 8px 12px;
    }

    .ec-tax-hero .ec-disclosure p,
    .ec-tax-hero .ec-disclosure a {
        font-size: 14px;
        line-height: 1.45;
    }

    /* Sub-area chips: one swipeable row, like the jump links */
    .ec-tax-hero__subareas {
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: none;
        margin-right: -5%;
        padding-right: 5%;
    }

    .ec-tax-hero__subareas::-webkit-scrollbar {
        display: none;
    }

    .ec-tax-hero__subarea-pill,
    .ec-tax-hero__subareas-label {
        flex: none;
        white-space: nowrap;
    }
}
