/* PORTUGAL_VIATOR_20260925_R045 — exact R043 approved visual baseline; no visual changes. */
/*
 * PORTUGAL_VIATOR_20260925_R043_destination.css
 * Reusable destination SEO/LLM landing pages for /tours/<destination>/.
 * R034: Softens and slightly shortens the destination hero, gives the primary quick-search area a pale blue-gray surface instead of bright white, reduces the overlap/shadow, and keeps the inputs themselves white. Preserves all R033/R032 behavior.
 * Requires the existing R023 Viator stylesheet. Scoped so /tours/ and the
 * package/reservation stack remain unchanged.
 */

.portugal-viator-destination-page .po-destination-breadcrumb {
    background: #fff;
}

.portugal-viator-destination-page .po-destination-discovery-section {
    padding-top: 0 !important;
    padding-bottom: 46px !important;
}

.portugal-viator-destination-page .po-destination-intro-card {
    position: relative;
    z-index: 5;
    margin: -30px 0 26px;
    padding: 26px 30px 24px;
    border: 1px solid #d9e0eb;
    border-radius: 10px;
    background: rgba(255,255,255,.99);
    box-shadow: 0 8px 28px rgba(32,52,78,.12);
}

.portugal-viator-destination-page .po-destination-intro-card h2,
.portugal-viator-destination-page .po-destination-section-heading h2 {
    margin: 3px 0 10px !important;
    color: #2d4f8e !important;
    font-family: "Trebuchet MS", Arial, sans-serif !important;
    font-size: 29px !important;
    line-height: 1.18 !important;
    font-weight: 700 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
}

.portugal-viator-destination-page .po-destination-intro-copy {
    max-width: 960px;
    color: #4f5965;
    font-size: 16px;
    line-height: 1.7;
}

.portugal-viator-destination-page .po-destination-intro-copy p {
    margin: 0 0 12px;
}

.portugal-viator-destination-page .po-destination-intro-copy p:last-child {
    margin-bottom: 0;
}

.portugal-viator-destination-page .po-destination-topics {
    position: relative;
    z-index: 3;
    margin: 0 0 30px;
}

.portugal-viator-destination-page .po-destination-section-heading {
    max-width: 820px;
    margin: 0 auto 20px;
    text-align: center;
}

.portugal-viator-destination-page .po-destination-section-heading > p:last-child {
    margin: 0;
    color: #66717e;
    font-size: 15px;
    line-height: 1.55;
}

.portugal-viator-destination-page .po-destination-topic-grid {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 14px !important;
    width: 100% !important;
    max-width: none !important;
    margin-left: auto !important;
    margin-right: auto !important;
    align-items: stretch !important;
}

.portugal-viator-destination-page .po-destination-topic-card {
    display: flex;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    justify-self: stretch !important;
    min-height: 150px;
    padding: 18px 18px 16px;
    flex-direction: column;
    border: 1px solid rgba(82,105,151,.24);
    border-radius: 8px;
    background: rgba(255,255,255,.92);
    box-shadow: 0 4px 16px rgba(35,58,93,.07);
    color: #333;
    text-decoration: none !important;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.portugal-viator-destination-page .po-destination-topic-card:hover,
.portugal-viator-destination-page .po-destination-topic-card:focus {
    transform: translateY(-2px);
    border-color: rgba(54,93,166,.5);
    box-shadow: 0 8px 22px rgba(35,58,93,.12);
}

.portugal-viator-destination-page .po-destination-topic-card strong {
    margin-bottom: 7px;
    color: #2d4f8e;
    font-size: 17px;
    line-height: 1.25;
}

.portugal-viator-destination-page .po-destination-topic-card span {
    flex: 1;
    color: #616b76;
    font-size: 14px;
    line-height: 1.48;
}

.portugal-viator-destination-page .po-destination-topic-card em {
    margin-top: 12px;
    color: #315aa8;
    font-size: 13px;
    font-style: normal;
    font-weight: 700;
}

/* On destination pages the funnel follows original SEO content and topic cards,
   so it should not overlap the hero as it does on the main /tours/ hub. */
.portugal-viator-destination-page .po-viator-funnel {
    margin: 28px 0 34px !important;
}

.portugal-viator-destination-page .po-viator-funnel-form-fixed {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.portugal-viator-destination-page .po-destination-advice {
    padding-top: 48px;
}

.portugal-viator-destination-page .po-destination-related,
.portugal-viator-destination-page .po-destination-faq {
    padding: 50px 0;
}

.portugal-viator-destination-page .po-destination-related {
    background: #f6f8fb;
}

.portugal-viator-destination-page .po-destination-related-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    max-width: 980px;
    margin: 0 auto;
}

.portugal-viator-destination-page .po-destination-related-card {
    display: block;
    padding: 18px 20px;
    border: 1px solid #dce3ec;
    border-radius: 7px;
    background: #fff;
    text-decoration: none !important;
}

.portugal-viator-destination-page .po-destination-related-card strong,
.portugal-viator-destination-page .po-destination-related-card span {
    display: block;
}

.portugal-viator-destination-page .po-destination-related-card strong {
    margin-bottom: 5px;
    color: #2d4f8e;
    font-size: 17px;
}

.portugal-viator-destination-page .po-destination-related-card span {
    color: #66717e;
    font-size: 14px;
    line-height: 1.48;
}

.portugal-viator-destination-page .po-destination-faq-list {
    max-width: 900px;
    margin: 0 auto;
}

.portugal-viator-destination-page .po-destination-faq-list details {
    margin: 0 0 10px;
    border: 1px solid #dce3ec;
    border-radius: 7px;
    background: #fff;
}

.portugal-viator-destination-page .po-destination-faq-list summary {
    padding: 16px 44px 16px 18px;
    color: #304e82;
    cursor: pointer;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.35;
}

.portugal-viator-destination-page .po-destination-faq-list details p {
    margin: 0;
    padding: 0 18px 18px;
    color: #5d6671;
    font-size: 15px;
    line-height: 1.6;
}

@media screen and (max-width: 980px) {
    .portugal-viator-destination-page .po-viator-funnel-form-fixed {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-destination-intro-card {
        margin-top: -18px;
        padding: 20px 18px;
    }

    .portugal-viator-destination-page .po-destination-intro-card h2,
    .portugal-viator-destination-page .po-destination-section-heading h2 {
        font-size: 24px !important;
    }

    .portugal-viator-destination-page .po-destination-topic-grid,
    .portugal-viator-destination-page .po-destination-related-grid,
    .portugal-viator-destination-page .po-viator-funnel-form-fixed {
        grid-template-columns: 1fr;
    }

    .portugal-viator-destination-page .po-destination-topic-card {
        min-height: 0;
    }

    .portugal-viator-destination-page .po-destination-related,
    .portugal-viator-destination-page .po-destination-faq {
        padding: 38px 0;
    }
}


/* R029 — editorial HTML lives in the WordPress Tour Category editor. */
.portugal-viator-destination-page .po-destination-editor-content {
    text-align: left;
}

.portugal-viator-destination-page .po-destination-editor-content-before {
    position: relative;
    z-index: 4;
}

.portugal-viator-destination-page .po-destination-editor-content-after {
    padding-top: 6px;
    padding-bottom: 6px;
}

/* Keep section headings centered, but make every content card read naturally. */
.portugal-viator-destination-page .po-destination-intro-card,
.portugal-viator-destination-page .po-destination-intro-card h2,
.portugal-viator-destination-page .po-destination-intro-copy,
.portugal-viator-destination-page .po-destination-topic-card,
.portugal-viator-destination-page .po-destination-topic-card strong,
.portugal-viator-destination-page .po-destination-topic-card span,
.portugal-viator-destination-page .po-destination-topic-card em,
.portugal-viator-destination-page .po-tours-advice-grid article,
.portugal-viator-destination-page .po-destination-related-card,
.portugal-viator-destination-page .po-destination-related-card strong,
.portugal-viator-destination-page .po-destination-related-card span {
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-topic-card {
    align-items: flex-start;
}


/* R030 — force natural left alignment inside content cards. Legacy theme rules
   center anchors and headings globally, so target card descendants explicitly. */
.portugal-viator-destination-page .po-destination-topic-card,
.portugal-viator-destination-page .po-destination-topic-card *,
.portugal-viator-destination-page .po-tours-advice-grid article,
.portugal-viator-destination-page .po-tours-advice-grid article *,
.portugal-viator-destination-page .po-destination-related-card,
.portugal-viator-destination-page .po-destination-related-card * {
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-topic-card {
    align-items: stretch !important;
}

/* Section titles stay centered; only the cards themselves are left aligned. */
.portugal-viator-destination-page .po-destination-section-heading,
.portugal-viator-destination-page .po-destination-section-heading *,
.portugal-viator-destination-page .po-tours-advice-heading,
.portugal-viator-destination-page .po-tours-advice-heading * {
    text-align: center !important;
}

/* Keep the shortcode inventory block from inheriting editorial spacing. */
.portugal-viator-destination-page .po-destination-inventory-anchor {
    margin-top: 28px;
}


/* R032 — WordPress wpautop adds <br> between consecutive anchor cards in editor
   HTML. In CSS Grid those BR elements become real grid items, so every second
   grid cell appears empty. Remove only those direct auto-formatting nodes. */
.portugal-viator-destination-page .po-destination-topic-grid > br,
.portugal-viator-destination-page .po-destination-related-grid > br {
    display: none !important;
}

/* Defensive cleanup in case the classic editor produces empty paragraph nodes
   between cards instead of BR elements. */
.portugal-viator-destination-page .po-destination-topic-grid > p:empty,
.portugal-viator-destination-page .po-destination-related-grid > p:empty {
    display: none !important;
}


/* -------------------------------------------------------------------------
 * R033 — calmer destination shopping flow.
 * Search becomes the primary action directly below the hero; editorial content
 * is quieter; Tour Ideas become compact navigation tiles; advanced filtering is
 * available on demand instead of occupying the whole first screen.
 * ------------------------------------------------------------------------- */

.portugal-viator-destination-page .po-destination-discovery-section {
    padding-top: 0 !important;
    padding-bottom: 42px !important;
}

/* Primary destination search card */
.portugal-viator-destination-page .po-destination-quick-search {
    position: relative;
    z-index: 8;
    margin: -28px 0 30px;
}

.portugal-viator-destination-page .po-destination-quick-search-inner {
    padding: 18px 22px 15px;
    border: 1px solid #d7dfeb;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 9px 26px rgba(32,52,78,.13);
}

.portugal-viator-destination-page .po-destination-quick-search .po-tours-kicker {
    margin: 0 0 8px !important;
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-quick-search-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 138px;
    gap: 10px;
    align-items: stretch;
}

.portugal-viator-destination-page .po-destination-quick-search-form input[type="search"],
.portugal-viator-destination-page .po-destination-quick-search-form input[type="date"] {
    width: 100%;
    height: 48px;
    margin: 0;
    box-sizing: border-box;
    border: 1px solid #cbd3dd;
    border-radius: 6px;
    background: #fff;
    color: #333;
    font-size: 15px;
    line-height: 48px;
}

.portugal-viator-destination-page .po-destination-quick-search-form input[type="search"] {
    padding: 0 15px;
}

.portugal-viator-destination-page .po-destination-quick-search-form input[type="date"] {
    padding: 0 10px;
}

.portugal-viator-destination-page .po-destination-quick-search-form input:focus {
    outline: 2px solid rgba(59,123,205,.25);
    border-color: #3b7bcd;
}

.portugal-viator-destination-page .po-destination-quick-search-form button {
    height: 48px;
    padding: 0 18px;
    border: 0;
    border-radius: 6px;
    background: #3b7bcd;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
}

.portugal-viator-destination-page .po-destination-quick-search-form button:hover,
.portugal-viator-destination-page .po-destination-quick-search-form button:focus {
    background: #286abd;
}

.portugal-viator-destination-page .po-destination-quick-search-help {
    margin: 7px 0 0 !important;
    color: #747d87;
    font-size: 13px;
    line-height: 1.35;
    text-align: left !important;
}

/* The intro is now editorial copy rather than another competing card. */
.portugal-viator-destination-page .po-destination-intro-card {
    position: relative;
    z-index: 2;
    max-width: 980px;
    margin: 0 auto 28px;
    padding: 0 4px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.portugal-viator-destination-page .po-destination-intro-card h2 {
    margin-top: 2px !important;
    font-size: 27px !important;
}

.portugal-viator-destination-page .po-destination-intro-copy {
    max-width: 900px;
    font-size: 15px;
    line-height: 1.62;
}

/* Compact Tour Ideas navigation */
.portugal-viator-destination-page .po-destination-topics {
    margin: 0 0 24px;
}

.portugal-viator-destination-page .po-destination-section-heading {
    margin-bottom: 14px;
}

.portugal-viator-destination-page .po-destination-section-heading h2 {
    font-size: 26px !important;
}

.portugal-viator-destination-page .po-destination-topic-grid {
    gap: 10px !important;
}

.portugal-viator-destination-page .po-destination-topic-card {
    min-height: 82px;
    padding: 14px 15px 12px;
    border-color: #dbe2ec;
    border-radius: 7px;
    background: #fff;
    box-shadow: 0 2px 9px rgba(35,58,93,.05);
}

.portugal-viator-destination-page .po-destination-topic-card strong {
    margin-bottom: 4px;
    font-size: 16px;
    line-height: 1.22;
}

.portugal-viator-destination-page .po-destination-topic-card span {
    display: none;
}

.portugal-viator-destination-page .po-destination-topic-card em {
    margin-top: auto;
    padding-top: 7px;
    font-size: 12px;
}

/* Replace the large fixed-destination funnel with a quiet collapsed control. */
.portugal-viator-destination-page .po-destination-inventory-anchor {
    margin-top: 20px;
}

.portugal-viator-destination-page .po-viator-funnel.po-viator-funnel-fixed-destination.po-viator-funnel-refine {
    margin: 0 0 18px !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

.portugal-viator-destination-page .po-viator-more-filters {
    border: 1px solid #dbe2eb;
    border-radius: 7px;
    background: #fff;
}

.portugal-viator-destination-page .po-viator-more-filters > summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 13px 16px;
    cursor: pointer;
    list-style: none;
    color: #344d79;
}

.portugal-viator-destination-page .po-viator-more-filters > summary::-webkit-details-marker {
    display: none;
}

.portugal-viator-destination-page .po-viator-more-filters-copy {
    display: flex;
    align-items: baseline;
    gap: 10px;
    min-width: 0;
}

.portugal-viator-destination-page .po-viator-more-filters-copy strong {
    font-size: 15px;
    line-height: 1.2;
}

.portugal-viator-destination-page .po-viator-more-filters-copy small {
    color: #75808d;
    font-size: 12px;
    line-height: 1.3;
    font-weight: 400;
}

.portugal-viator-destination-page .po-viator-more-filters-icon {
    position: relative;
    flex: 0 0 12px;
    width: 12px;
    height: 12px;
}

.portugal-viator-destination-page .po-viator-more-filters-icon::before,
.portugal-viator-destination-page .po-viator-more-filters-icon::after {
    content: "";
    position: absolute;
    left: 0;
    top: 5px;
    width: 12px;
    height: 2px;
    background: #526a8e;
    transition: transform .15s ease;
}

.portugal-viator-destination-page .po-viator-more-filters-icon::after {
    transform: rotate(90deg);
}

.portugal-viator-destination-page .po-viator-more-filters[open] .po-viator-more-filters-icon::after {
    transform: rotate(0deg);
}

.portugal-viator-destination-page .po-viator-more-filters-body {
    padding: 16px;
    border-top: 1px solid #e7ebf1;
}

.portugal-viator-destination-page .po-viator-more-filters .po-viator-funnel-form-fixed {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

/* Results begin quickly after the compact navigation. */
.portugal-viator-destination-page .po-viator-results-heading {
    margin-top: 0;
}

@media screen and (max-width: 980px) {
    .portugal-viator-destination-page .po-destination-quick-search-form {
        grid-template-columns: minmax(0, 1fr) 165px 125px;
    }

    .portugal-viator-destination-page .po-viator-more-filters .po-viator-funnel-form-fixed {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-destination-quick-search {
        margin-top: -18px;
        margin-bottom: 24px;
    }

    .portugal-viator-destination-page .po-destination-quick-search-inner {
        padding: 15px;
    }

    .portugal-viator-destination-page .po-destination-quick-search-form {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .portugal-viator-destination-page .po-destination-quick-search-form input[type="search"],
    .portugal-viator-destination-page .po-destination-quick-search-form input[type="date"],
    .portugal-viator-destination-page .po-destination-quick-search-form button {
        height: 46px;
    }

    .portugal-viator-destination-page .po-destination-intro-card {
        margin: 0 0 24px;
        padding: 0;
    }

    .portugal-viator-destination-page .po-destination-topic-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .portugal-viator-destination-page .po-destination-topic-card {
        min-height: 76px;
    }

    .portugal-viator-destination-page .po-viator-more-filters-copy {
        align-items: flex-start;
        flex-direction: column;
        gap: 3px;
    }

    .portugal-viator-destination-page .po-viator-more-filters .po-viator-funnel-form-fixed {
        grid-template-columns: 1fr;
    }
}

@media screen and (max-width: 480px) {
    .portugal-viator-destination-page .po-destination-topic-grid {
        grid-template-columns: 1fr !important;
    }
}

/* -------------------------------------------------------------------------
 * R040 — solid hero/search overlap + restored heading hierarchy.
 * - No fade and no simulated gradient transition below the hero.
 * - The hero remains a solid PortugalOnline blue through its bottom edge.
 * - The quick-search card overlaps the hero by roughly half its desktop height,
 *   so blue naturally sits behind the upper half of the card and white behind
 *   the lower half.
 * - Gives the eyebrow/H1/lead enough vertical room below the black site header.
 * - "Plan Your Sightseeing" / "Popular Ways to Explore" kickers are dark;
 *   their H2 headings use PortugalOnline blue.
 * - Card titles remain dark; links/buttons remain PortugalOnline blue.
 * ------------------------------------------------------------------------- */

:root {
    --po-destination-blue: #3b7bcd;
    --po-destination-blue-dark: #285a8e;
    --po-destination-heading: #27384f;
    --po-destination-card-heading: #2f4058;
}

/* R042 — Darker hero + solid continuation behind upper half of search card.
   Preserve R041 breathing room, typography and content hierarchy.

/* R041 baseline — Add breathing room between the black site header and the hero eyebrow/H1.
   Preserve the R040 solid-blue hero, search-card overlap, colors, content and layout. */
/* HERO — solid blue and enough room for all three lines. */
.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
    display: block !important;
    min-height: 250px !important;
    height: 250px !important;
    padding: 0 !important;
    overflow: hidden !important;
    background: #285a8e !important;
    border-bottom: 0 !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-shell {
    position: relative !important;
    top: auto !important;
    transform: none !important;
    box-sizing: border-box !important;
    padding-top: 54px !important;
    padding-bottom: 28px !important;
    text-align: center !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-eyebrow {
    position: static !important;
    top: auto !important;
    transform: none !important;
    margin: 0 0 8px !important;
    color: rgba(255,255,255,.94) !important;
    text-align: center !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero h1 {
    margin: 0 0 9px !important;
    max-width: none !important;
    color: #fff !important;
    font-size: 40px !important;
    line-height: 1.1 !important;
    text-align: center !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-lead {
    max-width: 900px !important;
    margin: 0 auto !important;
    color: rgba(255,255,255,.96) !important;
    font-size: 17px !important;
    line-height: 1.4 !important;
    text-align: center !important;
}

/* SEARCH TRANSITION — no fade. White section + card physically overlapping
   the solid-blue hero. On desktop the overlap is approximately half the card. */
.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section {
    position: relative !important;
    padding-top: 0 !important;
    padding-bottom: 44px !important;
    background: #fff !important;
}

/* Solid continuation only: carry the darker hero blue to roughly the midpoint
   of the quick-search card. There is intentionally no gradient/fade. */
.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section::before {
    content: "" !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 68px !important;
    background: #285a8e !important;
    z-index: 0 !important;
    pointer-events: none !important;
}

.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section > .po-tours-shell {
    position: relative !important;
    z-index: 1 !important;
}

.portugal-viator-destination-page .po-destination-quick-search {
    position: relative !important;
    z-index: 8 !important;
    margin-top: -82px !important;
    margin-bottom: 34px !important;
}

.portugal-viator-destination-page .po-destination-quick-search-inner {
    padding: 18px 22px 16px !important;
    border: 1px solid #d5dfed !important;
    border-radius: 10px !important;
    background: #f2f6fc !important;
    box-shadow: 0 5px 16px rgba(32,52,78,.09) !important;
}

/* Search heading stays blue. */
.portugal-viator-destination-page .po-destination-quick-search .po-tours-kicker {
    color: var(--po-destination-blue) !important;
}

.portugal-viator-destination-page .po-destination-quick-search-form button,
.portugal-viator-destination-page .po-tours-button,
.portugal-viator-destination-page .po-viator-button {
    background: var(--po-destination-blue) !important;
}

.portugal-viator-destination-page .po-destination-quick-search-form button:hover,
.portugal-viator-destination-page .po-destination-quick-search-form button:focus,
.portugal-viator-destination-page .po-tours-button:hover,
.portugal-viator-destination-page .po-tours-button:focus,
.portugal-viator-destination-page .po-viator-button:hover,
.portugal-viator-destination-page .po-viator-button:focus {
    background: #286abd !important;
}

/* INTRO — centered hierarchy, full-width left-aligned body copy. */
.portugal-viator-destination-page .po-destination-intro-card {
    max-width: none !important;
    margin: 0 0 30px !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

/* These small editorial labels are intentionally dark, per R040. */
.portugal-viator-destination-page .po-destination-intro-card .po-tours-kicker,
.portugal-viator-destination-page .po-destination-section-heading .po-tours-kicker {
    margin: 0 0 6px !important;
    color: var(--po-destination-heading) !important;
    text-align: center !important;
}

/* Main editorial H2s use PortugalOnline blue. */
.portugal-viator-destination-page .po-destination-intro-card h2,
.portugal-viator-destination-page .po-destination-section-heading h2 {
    margin: 0 0 12px !important;
    color: var(--po-destination-blue) !important;
    font-size: 29px !important;
    line-height: 1.2 !important;
    text-align: center !important;
}

.portugal-viator-destination-page .po-destination-intro-copy {
    max-width: none !important;
    color: #4f5965 !important;
    font-size: 15px !important;
    line-height: 1.58 !important;
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-intro-copy p {
    margin: 0 0 12px !important;
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-intro-copy p:last-child {
    margin-bottom: 0 !important;
}

/* TOUR IDEAS — concise blurbs, dark card titles, blue links. */
.portugal-viator-destination-page .po-destination-topics {
    margin: 0 0 28px !important;
}

.portugal-viator-destination-page .po-destination-section-heading {
    margin: 0 auto 18px !important;
    text-align: center !important;
}

.portugal-viator-destination-page .po-destination-topic-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 12px !important;
}

.portugal-viator-destination-page .po-destination-topic-card {
    min-height: 142px !important;
    padding: 18px 18px 15px !important;
    border: 1px solid #dbe2ec !important;
    border-radius: 7px !important;
    background: #fff !important;
    box-shadow: 0 2px 9px rgba(35,58,93,.05) !important;
    align-items: stretch !important;
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-topic-card strong {
    margin-bottom: 8px !important;
    color: var(--po-destination-card-heading) !important;
    font-size: 17px !important;
    line-height: 1.25 !important;
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-topic-card span {
    display: block !important;
    flex: 1 1 auto !important;
    color: #616b76 !important;
    font-size: 13px !important;
    line-height: 1.42 !important;
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-topic-card em {
    margin-top: 10px !important;
    padding-top: 0 !important;
    color: var(--po-destination-blue) !important;
    font-size: 12px !important;
    line-height: 1.3 !important;
    text-align: left !important;
}

/* Inventory and utility headings stay dark; links/actions stay blue. */
.portugal-viator-destination-page .po-viator-results h2,
.portugal-viator-destination-page .po-viator-results h3,
.portugal-viator-destination-page .po-viator-more-filters-copy strong {
    color: var(--po-destination-heading) !important;
}

.portugal-viator-destination-page .po-destination-related-card strong,
.portugal-viator-destination-page .po-destination-faq-list summary {
    color: var(--po-destination-card-heading) !important;
}

.portugal-viator-destination-page .po-destination-topic-card em,
.portugal-viator-destination-page .po-viator-results a:not(.po-tours-button) {
    color: var(--po-destination-blue) !important;
}

@media screen and (max-width: 980px) {
    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero h1 {
        font-size: 36px !important;
    }

    .portugal-viator-destination-page .po-destination-topic-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
        min-height: 184px !important;
        height: auto !important;
    }

    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-shell {
        padding-top: 28px !important;
        padding-bottom: 30px !important;
    }

    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero h1 {
        font-size: 30px !important;
    }

    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-lead {
        font-size: 15px !important;
    }

    .portugal-viator-destination-page .po-destination-quick-search {
        margin-top: -28px !important;
        margin-bottom: 26px !important;
    }

    .portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section::before {
        height: 48px !important;
    }

    .portugal-viator-destination-page .po-destination-intro-card h2,
    .portugal-viator-destination-page .po-destination-section-heading h2 {
        font-size: 25px !important;
    }

    .portugal-viator-destination-page .po-destination-topic-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .portugal-viator-destination-page .po-destination-topic-card {
        min-height: 0 !important;
    }
}

@media screen and (max-width: 480px) {
    .portugal-viator-destination-page .po-destination-topic-grid {
        grid-template-columns: 1fr !important;
    }
}

/* R043 — Stronger hero/H2 separation. Hero and search overlap use #285a8e; H2/accent blue remains #3b7bcd. No layout changes. */


/* R057 — compact destination navigation; approved R043/R045 styling otherwise unchanged. */
.portugal-viator-destination-page .po-destination-switcher {
    max-width: 1180px;
    margin: -16px auto 28px;
    padding: 0 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px 12px;
    flex-wrap: wrap;
    font-size: 13px;
    line-height: 1.35;
}
.portugal-viator-destination-page .po-destination-switcher-label { color: #27384f; font-weight: 700; }
.portugal-viator-destination-page .po-destination-switcher-links { display: flex; align-items: center; justify-content: center; gap: 6px; flex-wrap: wrap; }
.portugal-viator-destination-page .po-destination-switcher a,
.portugal-viator-destination-page .po-destination-switcher .is-current {
    display: inline-block; padding: 5px 9px; border: 1px solid #d5dfed; border-radius: 999px; background: #fff; text-decoration: none; white-space: nowrap;
}
.portugal-viator-destination-page .po-destination-switcher a { color: #3b7bcd; }
.portugal-viator-destination-page .po-destination-switcher a:hover,
.portugal-viator-destination-page .po-destination-switcher a:focus { border-color: #3b7bcd; text-decoration: underline; }
.portugal-viator-destination-page .po-destination-switcher .is-current { border-color: #285a8e; background: #285a8e; color: #fff; font-weight: 700; }
@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-destination-switcher { margin-top: -8px; margin-bottom: 22px; padding-left: 14px; padding-right: 14px; gap: 7px; }
    .portugal-viator-destination-page .po-destination-switcher-label { width: 100%; text-align: center; }
    .portugal-viator-destination-page .po-destination-switcher-links { gap: 5px; }
    .portugal-viator-destination-page .po-destination-switcher a,
    .portugal-viator-destination-page .po-destination-switcher .is-current { padding: 5px 8px; font-size: 12px; }
}

/* -------------------------------------------------------------------------
 * R068 — fix hero destination-switcher presentation.
 * R067 wrote this override block with literal backslash-n characters, so the
 * browser ignored it and fell back to the old white-page switcher styling.
 * Keep R067's placement decisions (switcher in hero, More Filters below search,
 * destination-specific search placeholders) but apply them with valid CSS.
 * No routing, inventory or Tour Ideas behavior changes.
 * ------------------------------------------------------------------------- */

/* Give the hero enough vertical room for a dedicated destination-nav row. */
.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
    min-height: 270px !important;
    height: 270px !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-shell {
    padding-top: 22px !important;
    padding-bottom: 30px !important;
}

/* Destination navigation sits cleanly above the eyebrow/H1. */
.portugal-viator-destination-page .po-destination-hero .po-destination-switcher {
    max-width: 1180px !important;
    margin: 0 auto 17px !important;
    padding: 0 18px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px 12px !important;
    flex-wrap: wrap !important;
    color: #fff !important;
    font-size: 13px !important;
    line-height: 1.35 !important;
}

.portugal-viator-destination-page .po-destination-hero .po-destination-switcher-label {
    color: rgba(255,255,255,.96) !important;
    font-weight: 700 !important;
}

.portugal-viator-destination-page .po-destination-hero .po-destination-switcher-links {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    flex-wrap: wrap !important;
}

.portugal-viator-destination-page .po-destination-hero .po-destination-switcher a,
.portugal-viator-destination-page .po-destination-hero .po-destination-switcher .is-current {
    display: inline-block !important;
    padding: 5px 10px !important;
    border: 1px solid rgba(255,255,255,.72) !important;
    border-radius: 999px !important;
    background: rgba(255,255,255,.08) !important;
    color: #fff !important;
    text-decoration: none !important;
    white-space: nowrap !important;
}

.portugal-viator-destination-page .po-destination-hero .po-destination-switcher a:hover,
.portugal-viator-destination-page .po-destination-hero .po-destination-switcher a:focus {
    border-color: #fff !important;
    background: rgba(255,255,255,.18) !important;
    color: #fff !important;
    text-decoration: none !important;
}

.portugal-viator-destination-page .po-destination-hero .po-destination-switcher .is-current {
    border-color: #fff !important;
    background: #fff !important;
    color: #285a8e !important;
    font-weight: 700 !important;
}

/* Restore normal title spacing now that the switcher owns its own row. */
.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-eyebrow {
    margin: 0 0 7px !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero h1 {
    margin: 0 0 8px !important;
}

/* More Filters remains directly below the primary search card. */
.portugal-viator-destination-page .po-destination-quick-search {
    margin-bottom: 12px !important;
}

.portugal-viator-destination-page .po-destination-quick-search + .po-viator-funnel.po-viator-funnel-fixed-destination.po-viator-funnel-refine {
    margin: 0 0 32px !important;
}

@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
        min-height: 250px !important;
        height: auto !important;
    }

    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-shell {
        padding-top: 20px !important;
        padding-bottom: 34px !important;
    }

    .portugal-viator-destination-page .po-destination-hero .po-destination-switcher {
        margin: 0 auto 16px !important;
        padding: 0 10px !important;
        gap: 7px !important;
    }

    .portugal-viator-destination-page .po-destination-hero .po-destination-switcher-label {
        width: 100% !important;
        text-align: center !important;
    }

    .portugal-viator-destination-page .po-destination-hero .po-destination-switcher-links {
        gap: 5px !important;
    }

    .portugal-viator-destination-page .po-destination-hero .po-destination-switcher a,
    .portugal-viator-destination-page .po-destination-hero .po-destination-switcher .is-current {
        padding: 5px 8px !important;
        font-size: 11px !important;
    }

    .portugal-viator-destination-page .po-destination-quick-search {
        margin-bottom: 10px !important;
    }

    .portugal-viator-destination-page .po-destination-quick-search + .po-viator-funnel.po-viator-funnel-fixed-destination.po-viator-funnel-refine {
        margin-bottom: 26px !important;
    }
}


/* -------------------------------------------------------------------------
 * R069 — add breathing room between the site header and destination switcher.
 * Spacing-only change. No routing, search, inventory, Tour Ideas or editor
 * content changes.
 * ------------------------------------------------------------------------- */

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
    min-height: 294px !important;
    height: 294px !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-shell {
    padding-top: 38px !important;
    padding-bottom: 30px !important;
}

.portugal-viator-destination-page .po-destination-hero .po-destination-switcher {
    margin-top: 0 !important;
    margin-bottom: 18px !important;
}

@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
        min-height: 276px !important;
        height: auto !important;
    }

    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-shell {
        padding-top: 30px !important;
        padding-bottom: 34px !important;
    }
}

/* -------------------------------------------------------------------------
 * R070 — compact live-availability handoff on product detail pages.
 * One primary CTA replaces repeated Continue-to-Viator buttons. Individual
 * product-option variants remain available in a collapsed details panel.
 * ------------------------------------------------------------------------- */
.portugal-viator-destination-page .po-viator-bookable-summary {
    display: block;
}
.portugal-viator-destination-page .po-viator-bookable-primary {
    margin-bottom: 10px;
}
.portugal-viator-destination-page .po-viator-option-details {
    border: 1px solid #d9e2ef;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}
.portugal-viator-destination-page .po-viator-option-details > summary {
    cursor: pointer;
    padding: 10px 12px;
    font-weight: 700;
    color: #285a8e;
    background: #f7f9fc;
}
.portugal-viator-destination-page .po-viator-option-details-list {
    padding: 0 12px 8px;
}
.portugal-viator-destination-page .po-viator-option-detail-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-top: 1px solid #e7edf5;
}
.portugal-viator-destination-page .po-viator-option-detail-row > div {
    min-width: 0;
}
.portugal-viator-destination-page .po-viator-option-detail-row span {
    display: block;
    margin-top: 3px;
    color: #617086;
    font-size: 12px;
}
@media screen and (max-width: 640px) {
    .portugal-viator-destination-page .po-viator-option-detail-row {
        display: block;
    }
    .portugal-viator-destination-page .po-viator-option-detail-row > strong {
        display: block;
        margin-top: 5px;
    }
}


/* -------------------------------------------------------------------------
 * R071 — restore readable primary CTA in the trip-planning panel.
 * Visual-only change. The destination stylesheet's shared blue-button rule
 * was overriding the intended light button treatment inside the blue card.
 * ------------------------------------------------------------------------- */
.portugal-viator-destination-page .po-tours-planning-card .po-tours-button.po-tours-button-light {
    background: #ffffff !important;
    color: var(--po-destination-blue) !important;
    border-color: #ffffff !important;
    text-decoration: none !important;
}

.portugal-viator-destination-page .po-tours-planning-card .po-tours-button.po-tours-button-light:hover,
.portugal-viator-destination-page .po-tours-planning-card .po-tours-button.po-tours-button-light:focus {
    background: #f2f6fc !important;
    color: #204f83 !important;
    border-color: #ffffff !important;
}

/* -------------------------------------------------------------------------
 * R073 — upcoming schedule suggestions after a no-availability response.
 * Schedule dates are only suggestions; clicking one reruns live availability.
 * ------------------------------------------------------------------------- */
.portugal-viator-destination-page .po-viator-next-dates {
    margin: 10px 0 12px;
    padding: 12px;
    border: 1px solid #d9e2ef;
    border-radius: 8px;
    background: #f7f9fc;
}
.portugal-viator-destination-page .po-viator-next-dates > strong {
    display: block;
    margin-bottom: 4px;
    color: #27384f;
    font-size: 14px;
}
.portugal-viator-destination-page .po-viator-next-dates-note {
    display: block;
    color: #617086;
    font-size: 12px;
    line-height: 1.4;
}
.portugal-viator-destination-page .po-viator-next-date-links {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 10px;
}
.portugal-viator-destination-page .po-viator-next-date-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid #b9c9df;
    border-radius: 999px;
    background: #fff;
    color: #285a8e;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
}
.portugal-viator-destination-page .po-viator-next-date-link:hover,
.portugal-viator-destination-page .po-viator-next-date-link:focus {
    border-color: #3b7bcd;
    background: #eef4fb;
    color: #204f83;
    text-decoration: none;
}
.portugal-viator-destination-page .po-viator-next-dates-none {
    margin-top: 10px;
}

/* ==========================================================================
 * R113 — Destination-page visual unification with the main /tours/ page.
 * Presentation only: brand palette, hero spacing, one combined Search/Filters
 * card, and continuous hero blue behind that card. Retrieval/routing untouched.
 * ========================================================================== */

.portugal-viator-destination-page {
    --po-destination-blue: #3B7BCD;
    --po-destination-blue-dark: #326BB3;
    --po-destination-blue-light: #9DBBE2;
    --po-destination-blue-soft: #EEF4FB;
}

/* Match the main /tours/ hero palette and open the hero below the black header. */
.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
    min-height: 0 !important;
    height: auto !important;
    padding: 0 !important;
    overflow: visible !important;
    background-color: var(--po-destination-blue) !important;
    background-image: linear-gradient(135deg, var(--po-destination-blue-dark), var(--po-destination-blue)) !important;
    border-bottom: 0 !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero > .po-tours-shell {
    box-sizing: border-box !important;
    padding-top: 46px !important;
    padding-bottom: 42px !important;
}

.portugal-viator-destination-page .po-destination-hero .po-destination-switcher {
    margin-bottom: 22px !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-eyebrow {
    margin-bottom: 11px !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero h1 {
    margin-bottom: 12px !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero .po-tours-lead {
    line-height: 1.5 !important;
}

/* Continue the same hero blue down through the complete Search + More Filters card.
   The soft tail prevents a hard horizontal color-change line. */
.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section {
    position: relative !important;
    padding-top: 0 !important;
    padding-bottom: 44px !important;
    background: #fff !important;
}

.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section::before {
    content: "" !important;
    position: absolute !important;
    z-index: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 245px !important;
    pointer-events: none !important;
    background: linear-gradient(
        to bottom,
        var(--po-destination-blue) 0,
        var(--po-destination-blue) 205px,
        rgba(59,123,205,.55) 224px,
        rgba(59,123,205,0) 245px
    ) !important;
}

.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section > .po-tours-shell {
    position: relative !important;
    z-index: 1 !important;
}

/* One real card contains both the primary search and More Filters. */
.portugal-viator-destination-page .po-destination-search-card {
    position: relative !important;
    z-index: 8 !important;
    margin: -54px 0 36px !important;
    overflow: hidden !important;
    border: 1px solid rgba(157,187,226,.9) !important;
    border-radius: 12px !important;
    background: #fff !important;
    box-shadow: 0 10px 26px rgba(32,52,78,.13) !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-destination-quick-search {
    margin: 0 !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-destination-quick-search-inner {
    padding: 22px 24px 16px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: #fff !important;
    box-shadow: none !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-destination-quick-search .po-tours-kicker {
    color: var(--po-destination-blue) !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-funnel.po-viator-funnel-fixed-destination.po-viator-funnel-refine {
    margin: 0 !important;
    padding: 0 24px 20px !important;
    border: 0 !important;
    background: #fff !important;
    box-shadow: none !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters {
    border: 0 !important;
    border-top: 1px solid #dfe6ef !important;
    border-radius: 0 !important;
    background: #fff !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters > summary {
    padding: 15px 0 0 !important;
    color: var(--po-destination-blue-dark) !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters-body {
    margin-top: 14px !important;
    padding: 16px 0 0 !important;
    border-top: 1px solid #e7ebf1 !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters-icon::before,
.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters-icon::after {
    background: var(--po-destination-blue-dark) !important;
}

/* Normalize visible destination-page blue accents to the established brand palette. */
.portugal-viator-destination-page .po-destination-quick-search-form button,
.portugal-viator-destination-page .po-tours-button,
.portugal-viator-destination-page .po-viator-button,
.portugal-viator-destination-page .po-viator-search-button,
.portugal-viator-destination-page .po-viator-price-ribbon,
.portugal-viator-destination-page .po-viator-page-link.is-current {
    border-color: var(--po-destination-blue) !important;
    background: var(--po-destination-blue) !important;
}

.portugal-viator-destination-page .po-destination-quick-search-form button:hover,
.portugal-viator-destination-page .po-destination-quick-search-form button:focus,
.portugal-viator-destination-page .po-tours-button:hover,
.portugal-viator-destination-page .po-tours-button:focus,
.portugal-viator-destination-page .po-viator-button:hover,
.portugal-viator-destination-page .po-viator-button:focus,
.portugal-viator-destination-page .po-viator-search-button:hover,
.portugal-viator-destination-page .po-viator-search-button:focus {
    border-color: var(--po-destination-blue-dark) !important;
    background: var(--po-destination-blue-dark) !important;
}

.portugal-viator-destination-page .po-destination-intro-card h2,
.portugal-viator-destination-page .po-destination-section-heading h2,
.portugal-viator-destination-page .po-viator-results-heading h2,
.portugal-viator-destination-page .po-destination-topic-card em,
.portugal-viator-destination-page .po-viator-toolbar a,
.portugal-viator-destination-page .po-viator-page-link {
    color: var(--po-destination-blue) !important;
}

@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero > .po-tours-shell {
        padding-top: 32px !important;
        padding-bottom: 34px !important;
    }

    .portugal-viator-destination-page .po-destination-hero .po-destination-switcher {
        margin-bottom: 16px !important;
    }

    .portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section::before {
        height: 330px !important;
        background: linear-gradient(
            to bottom,
            var(--po-destination-blue) 0,
            var(--po-destination-blue) 285px,
            rgba(59,123,205,.5) 305px,
            rgba(59,123,205,0) 330px
        ) !important;
    }

    .portugal-viator-destination-page .po-destination-search-card {
        margin-top: -34px !important;
        margin-bottom: 30px !important;
    }

    .portugal-viator-destination-page .po-destination-search-card .po-destination-quick-search-inner {
        padding: 18px 16px 14px !important;
    }

    .portugal-viator-destination-page .po-destination-search-card .po-viator-funnel.po-viator-funnel-fixed-destination.po-viator-funnel-refine {
        padding: 0 16px 16px !important;
    }
}

/* ==========================================================================
 * R115 — Region-page visual normalization to the approved /tours/ language.
 * Presentation only. Search/retrieval/routing/product/availability untouched.
 * ========================================================================== */

.portugal-viator-destination-page {
    --po-blue: #3B7BCD;
    --po-blue-dark: #326BB3;
    --po-blue-light: #9DBBE2;
    --po-blue-soft: #EEF4FB;
}

/* HERO: keep only eyebrow + H1 + lead, with the same calm proportions as /tours/. */
.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero {
    min-height: 0 !important;
    height: auto !important;
    padding: 0 !important;
    overflow: visible !important;
    border: 0 !important;
    background-color: var(--po-blue) !important;
    background-image:
        radial-gradient(circle at 84% 42%, rgba(255,255,255,.08) 0 1px, transparent 1px),
        linear-gradient(135deg, var(--po-blue-dark), var(--po-blue)) !important;
    background-size: 24px 24px, auto !important;
}

.portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero > .po-tours-shell {
    box-sizing: border-box !important;
    max-width: 980px !important;
    padding-top: 54px !important;
    padding-bottom: 70px !important;
    text-align: center !important;
}

.portugal-viator-destination-page .po-destination-hero .po-tours-eyebrow {
    margin: 0 0 12px !important;
    color: #fff !important;
    font-size: 13px !important;
    line-height: 1.2 !important;
    letter-spacing: .08em !important;
}

.portugal-viator-destination-page .po-destination-hero h1 {
    margin: 0 auto 14px !important;
    color: #fff !important;
    font-size: clamp(36px, 4.2vw, 50px) !important;
    line-height: 1.08 !important;
}

.portugal-viator-destination-page .po-destination-hero .po-tours-lead {
    max-width: 780px !important;
    margin: 0 auto !important;
    color: #fff !important;
    font-size: 17px !important;
    line-height: 1.55 !important;
}

/* BLUE TAIL: stop just beyond the unified shopping card, not halfway down the page. */
.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section {
    position: relative !important;
    padding-top: 0 !important;
    padding-bottom: 52px !important;
    background: #fff !important;
}

.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section::before {
    content: "" !important;
    position: absolute !important;
    z-index: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 208px !important;
    pointer-events: none !important;
    background: linear-gradient(
        to bottom,
        var(--po-blue) 0,
        var(--po-blue) 178px,
        rgba(59,123,205,.28) 194px,
        rgba(59,123,205,0) 208px
    ) !important;
}

.portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section > .po-tours-shell {
    position: relative !important;
    z-index: 1 !important;
}

/* ONE SHOPPING CARD: Explore row + search + More Filters. */
.portugal-viator-destination-page .po-destination-search-card {
    position: relative !important;
    z-index: 8 !important;
    margin: -42px 0 46px !important;
    overflow: hidden !important;
    border: 1px solid rgba(157,187,226,.88) !important;
    border-radius: 12px !important;
    background: #fff !important;
    box-shadow: 0 12px 30px rgba(32,52,78,.14) !important;
}

.portugal-viator-destination-page .po-destination-search-card-switcher {
    padding: 19px 24px 16px !important;
    border-bottom: 1px solid #dfe6ef !important;
    background: #fff !important;
}

.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    margin: 0 !important;
    padding: 0 !important;
    color: inherit !important;
}

.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher-label {
    flex: 0 0 auto !important;
    color: var(--po-blue) !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    text-transform: none !important;
}

.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher-links {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
}

.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher a,
.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher .is-current {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 36px !important;
    padding: 7px 14px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #f1f4f8 !important;
    color: var(--po-blue-dark) !important;
    font-size: 14px !important;
    line-height: 1.2 !important;
    font-weight: 700 !important;
    text-decoration: none !important;
}

.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher a:hover,
.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher a:focus {
    background: var(--po-blue-soft) !important;
    color: var(--po-blue-dark) !important;
    text-decoration: none !important;
}

.portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher .is-current {
    background: var(--po-blue) !important;
    color: #fff !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-destination-quick-search-inner {
    padding: 20px 24px 16px !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-destination-quick-search .po-tours-kicker {
    margin: 0 0 10px !important;
    color: var(--po-blue) !important;
    text-align: left !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-funnel.po-viator-funnel-fixed-destination.po-viator-funnel-refine {
    padding: 0 24px 20px !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters {
    border-top: 1px solid #dfe6ef !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters > summary {
    padding: 14px 0 0 !important;
    color: #27384f !important;
}

.portugal-viator-destination-page .po-destination-search-card .po-viator-more-filters-copy small {
    color: #6f7a87 !important;
}

/* EDITORIAL TRANSITION: separate shopping controls from editorial content cleanly. */
.portugal-viator-destination-page .po-destination-intro-card {
    max-width: 1040px !important;
    margin: 0 auto 34px !important;
    padding: 0 !important;
}

.portugal-viator-destination-page .po-destination-intro-card .po-tours-kicker,
.portugal-viator-destination-page .po-destination-section-heading .po-tours-kicker {
    margin-bottom: 7px !important;
    color: #27384f !important;
}

.portugal-viator-destination-page .po-destination-intro-card h2,
.portugal-viator-destination-page .po-destination-section-heading h2 {
    color: var(--po-blue) !important;
}

.portugal-viator-destination-page .po-destination-intro-copy {
    max-width: none !important;
    font-size: 15px !important;
    line-height: 1.68 !important;
}

.portugal-viator-destination-page .po-destination-topics {
    margin: 0 0 34px !important;
}

.portugal-viator-destination-page .po-destination-section-heading {
    margin-bottom: 20px !important;
}

.portugal-viator-destination-page .po-destination-topic-grid {
    gap: 12px !important;
}

.portugal-viator-destination-page .po-destination-topic-card {
    min-height: 150px !important;
    padding: 20px 18px 17px !important;
    border-color: #d8e0eb !important;
    border-radius: 8px !important;
    box-shadow: 0 3px 12px rgba(35,58,93,.055) !important;
}

.portugal-viator-destination-page .po-destination-topic-card strong {
    margin-bottom: 8px !important;
    color: #27384f !important;
    font-size: 16px !important;
}

.portugal-viator-destination-page .po-destination-topic-card span {
    display: block !important;
    color: #56616d !important;
    font-size: 13px !important;
    line-height: 1.48 !important;
}

.portugal-viator-destination-page .po-destination-topic-card em {
    margin-top: auto !important;
    padding-top: 12px !important;
    color: var(--po-blue) !important;
    font-size: 12px !important;
}

/* Brand-blue normalization for visible controls. */
.portugal-viator-destination-page .po-destination-quick-search-form button,
.portugal-viator-destination-page .po-viator-button,
.portugal-viator-destination-page .po-viator-search-button,
.portugal-viator-destination-page .po-viator-price-ribbon,
.portugal-viator-destination-page .po-viator-page-link.is-current {
    border-color: var(--po-blue) !important;
    background: var(--po-blue) !important;
}

.portugal-viator-destination-page .po-destination-quick-search-form button:hover,
.portugal-viator-destination-page .po-destination-quick-search-form button:focus,
.portugal-viator-destination-page .po-viator-button:hover,
.portugal-viator-destination-page .po-viator-button:focus,
.portugal-viator-destination-page .po-viator-search-button:hover,
.portugal-viator-destination-page .po-viator-search-button:focus {
    border-color: var(--po-blue-dark) !important;
    background: var(--po-blue-dark) !important;
}

@media screen and (max-width: 980px) {
    .portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher {
        flex-direction: column !important;
        gap: 10px !important;
    }
}

@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-tours-hero.po-tours-hero-compact.po-destination-hero > .po-tours-shell {
        padding-top: 38px !important;
        padding-bottom: 56px !important;
    }

    .portugal-viator-destination-page .po-destination-search-card {
        margin-top: -30px !important;
        margin-bottom: 34px !important;
    }

    .portugal-viator-destination-page .po-viator-search-section.po-destination-discovery-section::before {
        height: 260px !important;
        background: linear-gradient(
            to bottom,
            var(--po-blue) 0,
            var(--po-blue) 220px,
            rgba(59,123,205,.25) 242px,
            rgba(59,123,205,0) 260px
        ) !important;
    }

    .portugal-viator-destination-page .po-destination-search-card-switcher {
        padding: 16px !important;
    }

    .portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher-label {
        width: 100% !important;
        text-align: center !important;
    }

    .portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher a,
    .portugal-viator-destination-page .po-destination-search-card-switcher .po-destination-switcher .is-current {
        min-height: 34px !important;
        padding: 6px 10px !important;
        font-size: 12px !important;
    }

    .portugal-viator-destination-page .po-destination-topic-grid {
        grid-template-columns: 1fr !important;
    }

    .portugal-viator-destination-page .po-destination-topic-card {
        min-height: 0 !important;
    }
}

/* =========================================================
   R116 — Featured-image hero stage for destination pages.
   The WordPress Featured Image spans the hero copy plus the unified
   Explore/Search/More Filters card. Editorial content begins below it.
   ========================================================= */
.portugal-viator-destination-page .po-featured-hero-stage {
    position: relative !important;
    isolation: isolate !important;
    overflow: hidden !important;
    background-color: #326BB3 !important;
    background-position: center 42% !important;
    background-repeat: no-repeat !important;
    background-size: cover !important;
}
.portugal-viator-destination-page .po-featured-hero-stage.has-featured-image {
    background-image:
        linear-gradient(180deg, rgba(13,36,67,.58) 0%, rgba(21,57,96,.44) 58%, rgba(31,72,116,.30) 100%),
        var(--po-featured-hero-image) !important;
}
.portugal-viator-destination-page .po-featured-hero-stage.no-featured-image {
    background-image: linear-gradient(135deg, #326BB3, #3B7BCD) !important;
}
.portugal-viator-destination-page .po-featured-hero-stage .po-tours-hero.po-destination-hero {
    min-height: 0 !important;
    height: auto !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
}
.portugal-viator-destination-page .po-featured-hero-stage .po-destination-hero > .po-tours-shell {
    padding-top: 50px !important;
    padding-bottom: 30px !important;
}
.portugal-viator-destination-page .po-featured-hero-stage .po-destination-hero .po-tours-eyebrow,
.portugal-viator-destination-page .po-featured-hero-stage .po-destination-hero h1,
.portugal-viator-destination-page .po-featured-hero-stage .po-destination-hero .po-tours-lead {
    color: #fff !important;
    text-shadow: 0 2px 10px rgba(0,0,0,.36) !important;
}
.portugal-viator-destination-page .po-featured-hero-stage .po-destination-discovery-section {
    position: relative !important;
    padding: 0 0 34px !important;
    background: transparent !important;
}
.portugal-viator-destination-page .po-featured-hero-stage .po-destination-discovery-section::before {
    display: none !important;
    content: none !important;
}
.portugal-viator-destination-page .po-featured-hero-stage .po-destination-search-card {
    margin: 0 !important;
    border-color: rgba(255,255,255,.58) !important;
    box-shadow: 0 14px 34px rgba(13,32,56,.25) !important;
}
.portugal-viator-destination-page .po-destination-editorial-section {
    padding-top: 46px !important;
    background: #fff !important;
}
@media screen and (max-width: 768px) {
    .portugal-viator-destination-page .po-featured-hero-stage { background-position: center center !important; }
    .portugal-viator-destination-page .po-featured-hero-stage .po-destination-hero > .po-tours-shell {
        padding-top: 36px !important;
        padding-bottom: 24px !important;
    }
    .portugal-viator-destination-page .po-featured-hero-stage .po-destination-discovery-section { padding-bottom: 24px !important; }
    .portugal-viator-destination-page .po-destination-editorial-section { padding-top: 34px !important; }
}
