/* ============================================================
   TRAVELEAK ARTICLE SYSTEM: Hotel Editorial blocks (port step 4)
   Source: prototypes/hotel-editorial-prototype.html (locked; unchanged). Loaded ONLY on the hotel-editorial layout
   (inc/article.php); article.css and the Media Grid package are untouched. No media-system rules here.
   Blocks: Essential Information (dl.hotel-facts), Location Map + Contact (.hotel-location), rate CTA (.rate-cta),
   Affiliate Disclosure. The map is a static WebP from the Media Library: no runtime map or SVG.
   ============================================================ */
/* Essential Information = definition list, built from locked tokens */
.article-body .hotel-facts{margin:0;padding:0;}
.article-body .hotel-facts__row{display:grid;grid-template-columns:minmax(120px,200px) minmax(0,1fr);gap:0 24px;padding:11px 0;border-top:1px solid var(--color-border);}
.article-body .hotel-facts dt{margin:0;font:500 10px/1.75 var(--font-sans);letter-spacing:.14em;text-transform:uppercase;color:var(--color-text-muted);padding-top:5px;}
.article-body .hotel-facts dt{text-decoration:underline;text-decoration-color:rgba(176,138,82,.55);text-decoration-thickness:1px;text-underline-offset:6px;}
.article-body .hotel-facts dd{margin:0;font:300 16px/1.75 var(--font-sans);color:var(--color-text);}
@media (max-width:640px){.article-body .hotel-facts__row{grid-template-columns:minmax(0,1fr);gap:8px;padding:10px 0;}.article-body .hotel-facts dt{padding-top:0;text-underline-offset:4px;}}
.article-body .hotel-location{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);gap:0 32px;align-items:start;margin-top:28px;padding-top:28px;border-top:1px solid var(--color-border);}
.article-body .hotel-label{margin:0 0 12px;font:600 12px/1.4 var(--font-sans);letter-spacing:.12em;text-transform:uppercase;color:var(--color-accent);}
.article-body .hotel-map{position:relative;display:block;aspect-ratio:2.25/1;overflow:hidden;background:#e8e7e2;border:0;text-decoration:none;}
.article-body .hotel-map__art{position:absolute;inset:0;width:100%;height:100%;display:block;}
.article-body .hotel-map__expand{position:absolute;top:10px;right:10px;width:28px;height:28px;border-radius:50%;background:rgba(255,255,255,.88);color:#171614;display:flex;align-items:center;justify-content:center;}
.article-body .hotel-map__expand svg{width:14px;height:14px;}
.article-body .hotel-map:focus-visible{outline:2px solid var(--color-accent);outline-offset:2px;}
.article-body .hotel-contact{margin:0;font:300 16px/1.75 var(--font-sans);font-style:normal;color:var(--color-text);}
.article-body .hotel-contact + .hotel-contact{margin-top:12px;}
.article-body .hotel-contact__label{display:block;margin:0 0 4px;font:600 12px/1.4 var(--font-sans);letter-spacing:.12em;text-transform:uppercase;color:var(--color-accent);}
.article-body .affiliate-disclosure{margin:20px 0 0;font:300 12px/1.5 var(--font-sans);letter-spacing:normal;color:var(--color-text-muted);}
.article-body .hotel-contact a{color:var(--color-text);text-decoration:none;border-bottom:1px solid currentColor;overflow-wrap:anywhere;}
.article-body .hotel-contact a:hover{opacity:.8;}
@media (max-width:640px){.article-body .hotel-location{grid-template-columns:minmax(0,1fr);gap:24px 0;}.article-body .hotel-map{aspect-ratio:16/9;}}
/* Contact column starts level with the map image (same alignment as Hotel Review: map label line 12px*1.4 + 12px margin) */
.article-body .hotel-location__contact{padding-top:calc(12px * 1.4 + 12px);}
@media (max-width:640px){.article-body .hotel-location__contact{padding-top:0;}}
/* Desktop/tablet (>640px): map 2:1 so its bottom edge sits near the bottom of the VIEW RATES button (not the Rates via line). Mobile keeps 16:9. */
@media (min-width:641px){
  /* The map grows to end exactly at the bottom of the VIEW RATES button, at any width and with any font metrics.
     The base 2.25:1 ratio stays the minimum height (no CTA = map keeps its normal size). The Rates via line is taken out of the column height (negative bottom margin)
     and the block reserves that space below instead. */
  .article-body .hotel-location__map{display:flex;flex-direction:column;align-self:stretch;}
  .article-body .hotel-map{flex:1 0 auto;} /* base 2.25:1 stays the minimum */
    }
.article-body .rate-cta{margin-top:20px;}
.article-body .rate-cta__btn{display:flex;align-items:center;justify-content:center;min-height:40px;padding:8px 16px;background:var(--color-dark);color:#fff;border:0;border-radius:var(--radius);font:500 12px/1.5 var(--font-sans);letter-spacing:.08em;text-transform:uppercase;text-align:center;text-decoration:none;transition:background .2s var(--ease,ease);}
.article-body .rate-cta__btn:hover{background:#000;color:#fff;}
.article-body .rate-cta__btn:focus-visible{outline:2px solid var(--color-accent);outline-offset:2px;}
.article-body .rate-cta__provider{margin:8px 0 0;font:300 12px/1.5 var(--font-sans);color:var(--color-text-muted);}
/* ---- Step 4.1: "Rates via" and the compare line sit in flow directly under the VIEW RATES button (as in the prototype).
   Alignment rule (map bottom = button bottom) is kept by a spacer in the MAP column: an empty element as wide as the Contact column
   (map column / 1.6) whose invisible text is the same two lines, so both columns end with the same height and the map (flex:1)
   stops exactly at the button. Tablet inherits the desktop rule (>640px); <=640px stacks and needs no spacer. ---- */
.article-body .rate-compare{margin:4px 0 0;font:300 12px/1.5 var(--font-sans);color:var(--color-text-muted);}
.article-body .rate-compare a{color:var(--color-text);border:0;text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:3px;}
.article-body .rate-compare a:hover,.article-body .rate-compare a:focus-visible{color:var(--color-accent);}
.article-body .hotel-location__spacer{width:calc(100% / 1.6);visibility:hidden;pointer-events:none;}
.article-body .hotel-location__spacer::before{content:attr(data-via);display:block;margin:8px 0 0;font:300 12px/1.5 var(--font-sans);}
.article-body .hotel-location__spacer[data-compare]::after{content:attr(data-compare);display:block;margin:4px 0 0;font:300 12px/1.5 var(--font-sans);}
@media (max-width:640px){.article-body .hotel-location__spacer{display:none;}}
/* ---- Additions for the port (the prototype map was a drawn placeholder) ---- */
.article-body .hotel-map__img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;display:block;}
.article-body .hotel-map__attribution{position:absolute;left:8px;bottom:6px;padding:2px 6px;border-radius:2px;background:rgba(255,255,255,.82);font:400 10px/1.4 var(--font-sans);letter-spacing:.01em;color:#4f4f4b;}
/* Neutral fallback when the Property has coordinates but no map image yet: plain surface, no drawn location, a Google Maps button. */
.article-body .hotel-map--fallback{display:flex;align-items:center;justify-content:center;background:var(--color-surface);border:1px solid var(--color-border);}
.article-body .hotel-map__open{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:8px 16px;border:1px solid var(--color-text);color:var(--color-text);font:500 12px/1.5 var(--font-sans);letter-spacing:.08em;text-transform:uppercase;}
.article-body .hotel-map--fallback:hover .hotel-map__open{background:var(--color-dark);color:#fff;}
/* No coordinates and no map image: no map column at all (no invented location); Contact takes the full width and starts at the top. */
.article-body .hotel-location--no-map{grid-template-columns:minmax(0,1fr);}
.article-body .hotel-location--no-map .hotel-location__contact{padding-top:0;}


/* =====================================================================================================================
   Step 5: Hotel Review (loaded with article-hotel.css on the hotel-review layout only). Values copied from prototypes/hotel-review-prototype.html (locked),
   EXCEPT the prototype's own sticky rules (top 16px, CTA->Promo 24px, max-height calc(100vh - 170px)): the approved sidebar system in article.css is reused.
   ===================================================================================================================== */
.article-body .review-facts{margin:12px 0 0;padding:20px 0;border-top:1px solid var(--color-border);border-bottom:1px solid var(--color-border);}
.article-body .review-facts .hotel-label{margin:0;}
.article-body .review-facts__list{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);gap:16px 24px;margin:14px 0 0;padding:0;} /* one row: 4 fields, or 3 without Travelled as */
.article-body .review-facts__item{margin:0;}
.article-body .review-facts dt{margin:0;font:500 10px/1.75 var(--font-sans);letter-spacing:.14em;text-transform:uppercase;color:var(--color-text-muted);text-decoration:underline;text-decoration-color:rgba(176,138,82,.55);text-decoration-thickness:1px;text-underline-offset:6px;}
.article-body .review-facts dd{margin:8px 0 0;font:300 14px/1.5 var(--font-sans);color:var(--color-text);}
.article-body .review-disclosure{margin:16px 0 0;font:300 12px/1.5 var(--font-sans);letter-spacing:normal;color:var(--color-text-muted);}
.article-body .review-list{list-style:none;margin:0 0 16px;padding:0;}
.article-body .review-list li{margin:0;padding:10px 0;border-top:1px solid var(--color-border);font:300 16px/1.6 var(--font-sans);}
.article-body .review-list li:last-child{border-bottom:1px solid var(--color-border);}
.article-body .review-list strong{font-weight:500;}
@media (max-width:640px){.article-body .review-facts__list{grid-auto-flow:row;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 16px;}.article-body .review-facts dt{text-underline-offset:4px;}}
.article-body .how-to-book__loyalty{margin:0 0 16px;padding:16px 0 0;border-top:1px solid var(--color-border);}
.article-body .how-to-book__loyalty .hotel-label{display:block;margin:0 0 6px;}
.article-body .review-trust{position:relative;margin:0 0 16px;padding-left:16px;}
.article-body .review-trust::before{content:"";position:absolute;left:0;top:.5em;bottom:.42em;width:2px;background:var(--color-accent);}
.article-body .review-trust a{font-weight:500;} /* body link style (gold underline) */
.how-to-book .hotel-location__contact{padding-top:calc(12px * 1.4 + 12px);}
.article-body .how-to-book .booking-cta{max-width:calc((100% - 32px) * 1.6 / 2.6);gap:8px;}
.article-body .how-to-book .booking-cta__btn{min-height:44px;padding:10px 20px;}
@media (max-width:640px){.how-to-book .hotel-location__contact{padding-top:0;}.article-body .how-to-book .booking-cta{max-width:none;}}
.booking-cta{display:grid;gap:10px;}
.article-body .booking-cta{margin:28px 0 0;max-width:460px;}
.booking-cta__btn,.article-body .booking-cta__btn{display:flex;align-items:center;justify-content:center;min-height:56px;padding:12px 20px;background:var(--color-dark);color:#fff;border:0;border-radius:var(--radius);font:500 12px/1.5 var(--font-sans);letter-spacing:.12em;text-transform:uppercase;text-align:center;text-decoration:none;transition:background .2s var(--ease,ease);}
.booking-cta__btn:hover,.article-body .booking-cta__btn:hover{background:#000;color:#fff;}
.booking-cta__btn:focus-visible{outline:2px solid var(--color-accent);outline-offset:2px;}
.booking-cta--side{margin-top:48px;gap:6px;}
.booking-cta--side .booking-cta__btn{min-height:32px;padding:6px 14px;letter-spacing:.08em;}
.booking-cta__note{margin:4px 0 0;font:300 11px/1.4 var(--font-sans);color:var(--color-text-muted);}
@media (max-width:1023px){.booking-cta--side,.booking-cta--side + .booking-cta__note{display:none;}}
@media (max-width:640px){.article-body .booking-cta{max-width:none;}}
.article-page .article-eyebrow--review{display:block;margin:0 0 12px;font:500 10px/1.4 var(--font-sans);letter-spacing:.14em;text-transform:uppercase;color:#b08a52;}
.article-page .article-eyebrow--review::after{content:none;display:none;}
.article-page .article-eyebrow--review a{color:inherit;text-decoration:none;border:0;}
.article-page .article-eyebrow--review a:hover{text-decoration:underline;text-underline-offset:3px;}
.article-page .article-eyebrow--review a:focus-visible{outline:2px solid var(--color-accent);outline-offset:2px;}

/* ---- Layout: How to Book is its OWN row under the body, so the sticky sidebar (grid rows 1-2) is released at the START of #how-to-book.
   Rows (>=1024px): 1 title block | 2 hero + body | 3 How to Book | 4 Continue Reading + article end | 5 More from <hub>. Below 1024px the DOM order does the job. ---- */
@media (min-width:1024px){
  .article-page[data-article-type="hotel_review"] .article-how{grid-column:1;grid-row:3;min-width:0;}
  .article-page[data-article-type="hotel_review"] .article-after{grid-row:4;}
  .article-page[data-article-type="hotel_review"] .hub-section{grid-row:5;}
  /* Selected Stays band: row 6, under More from <hub> (row 5). Without this rule the shared article-stays.css puts the band in row 5 too and the two overlap whenever a review has both. */
  .article-page[data-article-type="hotel_review"] .article-layout > .stay-band{grid-row:6;}
}
/* The How to Book block is a separate .article-body: give its H2 the same top gap an H2 has inside the body (article.css: 36px). */
.article-body.article-how > h2:first-child{margin-top:36px;}

/* ---- Sticky group = booking CTA stack + House Promo. Same approved conditions as article.css (>=1024px, min-height 420px, --tl-sticky-top).
   The group is a flex column limited to the room left in the window (same 24px bottom margin the approved promo rule uses): the CTA stack keeps its own
   rendered height and the House Promo takes whatever is left (it shrinks, image cropped). No height estimate anywhere. CTA stack -> promo gap = 24px (approved). ---- */
@media (min-width:1024px) and (min-height:420px){
  .article-page[data-article-type="hotel_review"] .sidebar-sticky{display:flex;flex-direction:column;max-height:calc(100vh - var(--tl-sticky-top) - 24px);}
  .article-page[data-article-type="hotel_review"] .sidebar-sticky .booking-cta--side{flex:0 0 auto;}
  .article-page[data-article-type="hotel_review"] .sidebar-sticky .flexible-promo{flex:1 1 auto;min-height:0;}
}
@media (min-width:1024px){
  .article-page[data-article-type="hotel_review"] .booking-cta--side + .flexible-promo{margin-top:24px;}
  /* The 48px between Featured Stories and the CTA stack lives on the TRACK (outside the sticky group), so it no longer becomes dead space above the group while it is
     stuck: unstuck layout is unchanged, stuck gap = the sticky offset only (24px, 56px with the admin bar) and the promo gets that 48px back. */
  .article-page[data-article-type="hotel_review"] .sidebar-sticky-track.has-cta{margin-top:48px;}
  .article-page[data-article-type="hotel_review"] .sidebar-sticky-track.has-cta .booking-cta--side{margin-top:0;}
}
