/* A shared editorial layout for every public guide. The page source keeps its
   Gutenberg classes, but spacing and width are owned here. */
.guide-page {
  --guide-width: 1100px;
  --guide-gutter: clamp(20px, 4vw, 58px);
  --guide-text: #42564b;
  --guide-line: #d9e2d5;
  background: var(--paper);
}

.guide-page main { overflow: visible; }
.guide-page main :is(.wp-block-group, .wp-block-column, .wp-block-columns, figure) { min-width: 0; }
.guide-page main img { display: block; }
.guide-page [id] { scroll-margin-top: 28px; }

/* Breadcrumbs are readable over the guide hero and in the About article. */
.guide-page .guide-breadcrumbs { margin: 0 0 22px; color: #e4eee2; }
.guide-page .guide-breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 3px 0;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}
.guide-page .guide-breadcrumbs li {
  margin: 0;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.5;
}
.guide-page .guide-breadcrumbs li + li::before {
  content: "/";
  display: inline-block;
  margin: 0 10px;
  opacity: .55;
}
.guide-page .guide-breadcrumbs a { text-decoration: underline; text-underline-offset: 3px; }
.guide-page .guide-breadcrumbs a:hover { color: #d7e9a8; }
.guide-page.simple-guide .guide-breadcrumbs {
  margin-bottom: 34px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--guide-line);
  color: #47705a;
}
.guide-page.simple-guide .guide-breadcrumbs a:hover { color: var(--ink); }

/* The two generations of guide copy use different hero class names. */
.guide-page .al-guide-hero {
  display: flex;
  align-items: center;
  position: relative;
  isolation: isolate;
  min-height: clamp(510px, 49vw, 660px) !important;
  color: #fff;
}
.guide-page .al-guide-hero .wp-block-cover__image-background {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}
.guide-page .al-guide-hero .wp-block-cover__background {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, #092b26e8 0%, #092b26ba 47%, #092b2659 100%) !important;
  z-index: -1;
}
.guide-page .al-guide-hero .wp-block-cover__inner-container {
  width: min(var(--guide-width), calc(100% - var(--guide-gutter) - var(--guide-gutter)));
  max-width: none;
  margin: auto;
  padding: 65px 0;
}
.guide-page .al-guide-hero :is(.al-guide-kicker, .al-eyebrow) {
  display: block;
  max-width: 720px;
  margin: 0 0 19px;
  color: #d9edbb;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.5;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.guide-page .al-guide-hero :is(.al-guide-title, .al-display-heading) {
  max-width: 950px;
  margin: 0 0 25px;
  color: #fff;
  font: normal clamp(49px, 5.8vw, 84px)/1.04 var(--serif);
  letter-spacing: -.048em;
  text-wrap: balance;
}
.guide-page .al-guide-hero :is(.al-guide-lead, .al-lead) {
  max-width: 680px;
  margin: 0;
  color: #ecf4ea;
  font-size: clamp(17px, 1.7vw, 20px);
  line-height: 1.65;
}
.guide-page .al-guide-hero .al-guide-note {
  max-width: 680px;
  margin: 21px 0 0;
  color: #d0dfd0;
  font-size: 12px;
}
.guide-page .wp-block-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 28px 0 0;
}
.guide-page .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 47px;
  padding: 13px 20px;
  background: var(--lime);
  color: var(--deep);
  border-radius: 3px;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
  text-decoration: none;
}
.guide-page .wp-block-button__link:hover { background: #eaf3bd; }

/* Full-bleed colored sections and plain sections share the same content edge. */
.guide-page .al-section {
  width: min(var(--guide-width), calc(100% - var(--guide-gutter) - var(--guide-gutter)));
  max-width: none;
  margin: 0 auto;
  padding: 84px 0;
}
.guide-page .al-section-tint,
.guide-page .al-section-dark {
  width: 100%;
  max-width: none;
  padding: 84px max(var(--guide-gutter), calc((100% - var(--guide-width)) / 2));
}
.guide-page .al-section-tint { background: #edf2e9; }
.guide-page .al-section-dark { background: #163a33; color: #f4f7ed; }
.guide-page .al-section-narrow {
  width: min(940px, calc(100% - var(--guide-gutter) - var(--guide-gutter)));
}
.guide-page .al-section:not(.al-section-tint, .al-section-dark) + .al-section:not(.al-section-tint, .al-section-dark) {
  border-top: 1px solid var(--guide-line);
}
.guide-page .al-section:has(> .al-jump-links:only-child) {
  padding-top: 22px;
  padding-bottom: 25px;
  border-top: 1px solid var(--guide-line);
  border-bottom: 1px solid var(--guide-line);
}
.guide-page .al-section:has(> .al-fact-strip:only-child) { padding-top: 36px; padding-bottom: 36px; }
.guide-page .al-section > :last-child { margin-bottom: 0; }

.guide-page .al-section .al-step-label {
  margin: 0 0 13px;
  color: #407c60;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.5;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.guide-page .al-section-dark .al-step-label { color: #cee4a4; }
.guide-page .al-section h2,
.guide-page .al-section .al-display-heading {
  max-width: 850px;
  margin: 0 0 23px;
  font: normal clamp(35px, 3.6vw, 50px)/1.15 var(--serif);
  letter-spacing: -.038em;
  text-wrap: balance;
}
.guide-page .al-section h3 {
  margin: 0 0 11px;
  font: normal clamp(23px, 2.2vw, 27px)/1.2 var(--serif);
  letter-spacing: -.018em;
}
.guide-page .al-section > h3:not(:first-child) { margin-top: 32px; }
.guide-page .al-section > p:not(.al-step-label, .al-meta-note),
.guide-page .al-section > ul,
.guide-page .al-section > ol {
  max-width: 790px;
}
.guide-page .al-section p,
.guide-page .al-section li {
  line-height: 1.75;
}
.guide-page .al-section > p {
  margin-top: 0;
  margin-bottom: 19px;
  color: var(--guide-text);
  font-size: 17px;
}
/* Match the older WordPress selector's specificity so dark copy stays legible. */
.guide-page .al-section > p:not(.al-step-label):not(.al-meta-note) {
  max-width: 790px;
  margin: 0 0 19px;
  color: var(--guide-text);
  line-height: 1.75;
}
.guide-page .al-section.al-section-dark > p:not(.al-step-label):not(.al-meta-note) {
  color: #dce8de;
}
.guide-page .al-section ul,
.guide-page .al-section ol { padding-left: 24px; margin: 16px 0 25px; }
.guide-page .al-section li { margin: 7px 0; }
.guide-page .al-section a:not(.wp-block-button__link) {
  color: #216349;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.guide-page .al-section-dark a:not(.wp-block-button__link) { color: #dcf0b6; }
.guide-page .al-section .al-meta-note {
  max-width: 790px;
  margin: 27px 0 0;
  padding: 3px 0 3px 17px;
  border-left: 3px solid #88ac70;
  color: #597364;
  font-size: 14px;
  line-height: 1.65;
}
.guide-page .al-section-dark .al-meta-note { color: #dce8de; }

/* Cross-page navigation is compact even when it is its own section. */
.guide-page .al-jump-links,
.guide-page .al-jump-links p { max-width: none; margin: 0; line-height: 2.6; }
.guide-page .al-jump-links a,
.guide-page .al-section .al-jump-links a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  margin: 4px 6px 4px 0;
  padding: 5px 12px;
  border: 1px solid #cbd9c9;
  border-radius: 18px;
  background: #fff;
  color: #275944;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
  vertical-align: middle;
}
.guide-page .al-jump-links a:hover { background: #e7f0df; }

/* Every Gutenberg columns block can shrink inside a narrow viewport. */
.guide-page .wp-block-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 26px;
  margin: 34px 0;
}
.guide-page .wp-block-column { min-width: 0; }
.guide-page .wp-block-column > :first-child,
.guide-page .wp-block-column > .wp-block-group > :first-child { margin-top: 0; }
.guide-page .wp-block-column > :last-child,
.guide-page .wp-block-column > .wp-block-group > :last-child { margin-bottom: 0; }

.guide-page .al-fact-strip {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 32px 0;
  border: 1px solid #d2dfd1;
  background: #f8faf5;
  color: var(--ink);
}
.guide-page .al-fact-strip > .wp-block-column {
  padding: 23px 21px;
  border-right: 1px solid #d2dfd1;
}
.guide-page .al-fact-strip > .wp-block-column:last-child { border-right: 0; }
.guide-page .al-fact-strip h3,
.guide-page .al-fact-strip strong {
  display: block;
  margin: 0 0 7px;
  color: var(--ink);
  font: 800 12px/1.35 var(--sans);
  letter-spacing: .09em;
  text-transform: uppercase;
}
.guide-page .al-fact-strip p {
  margin: 0;
  color: #4c6354;
  font-size: 14px;
  line-height: 1.55;
}
.guide-page .al-fact-strip p + p { margin-top: 5px; }
.guide-page .al-fact-strip p:has(> strong):first-child { margin: 0 0 8px; }
.guide-page .al-fact-strip p strong { margin: 0; }

/* Keep wide comparisons within their own horizontal scroll area. */
.guide-page .al-compare-table,
.guide-page .wp-block-table {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 30px 0;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #d5dfd2;
  background: #fff;
  color: var(--ink);
}
.guide-page table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.5;
}
.guide-page .al-compare-table table:has(th:nth-child(5)) { min-width: 860px; }
.guide-page .al-compare-table table:has(th:nth-child(6)) { min-width: 980px; }
.guide-page th,
.guide-page td {
  padding: 16px 17px;
  border-bottom: 1px solid #d9e2d7;
  color: #263e34;
  text-align: left;
  vertical-align: top;
}
.guide-page tr:last-child td { border-bottom: 0; }
.guide-page th {
  background: #dce9d8;
  color: #1b493a;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .065em;
  text-transform: uppercase;
}
.guide-page td:first-child { font-weight: 750; }
.guide-page .al-section-dark .al-compare-table a { color: #216349; }

/* Cards have the same inset, whether Gutenberg added an inner group or not. */
.guide-page .al-card-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 34px 0;
}
.guide-page .al-card-grid:has(> .wp-block-column:nth-child(2):last-child),
.guide-page .al-card-grid:has(> .wp-block-column:nth-child(4):last-child) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.guide-page .al-card-grid:has(> .wp-block-column:nth-child(5):last-child) {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
.guide-page .al-card-grid:has(> .wp-block-column:nth-child(5):last-child) > .wp-block-column { grid-column: span 2; }
.guide-page .al-card-grid:has(> .wp-block-column:nth-child(5):last-child) > .wp-block-column:nth-child(n+4) { grid-column: span 3; }
.guide-page .al-card-grid > .wp-block-column {
  display: flex;
  flex-direction: column;
  padding: 24px;
  overflow: hidden;
  border: 1px solid #d6e1d3;
  background: #fff;
  color: var(--ink);
}
.guide-page .al-card-grid > .wp-block-column > .wp-block-group {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}
.guide-page .al-card-grid figure.wp-block-image {
  margin: -24px -24px 24px;
  overflow: hidden;
}
.guide-page .al-card-grid figure.wp-block-image img {
  width: 100%;
  height: 205px;
  object-fit: cover;
}
.guide-page .al-card-grid h3 {
  margin: 0 0 12px;
  color: var(--ink);
  font-size: 25px;
}
.guide-page .al-card-grid > .wp-block-column > h3:first-child { margin-top: 0; }
.guide-page .al-card-grid p {
  margin: 0 0 14px;
  color: #4b6154;
  font-size: 15px;
  line-height: 1.7;
}
.guide-page .al-card-grid p:last-child { margin-top: 0; margin-bottom: 0; font-size: 15px; font-weight: 400; }
.guide-page .al-card-grid a:not(.wp-block-button__link),
.guide-page .al-section-dark .al-card-grid a:not(.wp-block-button__link) { color: #216349; }
.guide-page .al-card-grid .al-badge { color: #337155; }

/* Image and copy splits; table variants give the comparison a usable width. */
.guide-page .al-story-split,
.guide-page .al-story-split:nth-of-type(even) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  gap: clamp(28px, 4.5vw, 64px);
  margin: 44px 0 60px;
}
.guide-page .al-story-split:has(.al-compare-table),
.guide-page .al-story-split:nth-of-type(even):has(.al-compare-table) {
  grid-template-columns: minmax(0, 1fr) minmax(240px, .38fr);
  align-items: start;
}
.guide-page .al-story-split figure.wp-block-image { margin: 0; }
.guide-page .al-story-split img {
  width: 100%;
  max-height: 480px;
  object-fit: cover;
}
.guide-page .al-story-split p { margin: 0 0 17px; color: #455e50; font-size: 16px; line-height: 1.75; }
.guide-page .al-story-split h2 { margin: 0 0 19px; }
.guide-page .al-story-split .al-compare-table { margin: 18px 0; }
.guide-page .al-section-dark .al-story-split p { color: #dce8de; }

.guide-page .al-time-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.guide-page .al-time-grid > .wp-block-column {
  padding: 26px;
  background: #f8faf2;
  color: var(--ink);
}
.guide-page .al-time-grid p { color: #465c50; font-size: 15px; }
.guide-page .al-guide-list { gap: 18px; margin: 30px 0; }
.guide-page .al-guide-list-item,
.guide-page .al-review-grid > .wp-block-column {
  padding: 25px;
  border: 1px solid #d6e1d3;
  background: #fff;
  color: var(--ink);
}
.guide-page .al-guide-list-item p,
.guide-page .al-review-grid > .wp-block-column p { color: #4b6154; font-size: 15px; }
.guide-page .al-review-grid { gap: 18px; }

.guide-page .al-faq { max-width: 820px; margin: 25px 0 0; }
.guide-page .al-faq h3 {
  margin: 0 0 12px;
  padding-top: 21px;
  border-top: 1px solid var(--guide-line);
  font-size: 23px;
}
.guide-page .al-faq p { margin: 0 0 19px; color: var(--guide-text); font-size: 16px; line-height: 1.7; }
.guide-page .al-section-dark .al-faq p { color: #dce8de; }
.guide-page .al-booking-box {
  padding: 38px 42px;
  border: 1px solid #d2dfce;
  background: #e7efdf;
  color: var(--ink);
}
.guide-page .al-booking-box p { color: var(--guide-text); }
.guide-page .al-section-dark.al-booking-box {
  width: 100%;
  margin: 0;
  padding: 72px max(var(--guide-gutter), calc((100% - var(--guide-width)) / 2));
  border: 0;
  background: #163a33;
  color: #f4f7ed;
}
.guide-page .al-section-dark.al-booking-box p { color: #dce8de; }
.guide-page .al-section-dark .al-booking-box {
  border-color: #d2dfce;
  background: #e7efdf;
  color: var(--ink);
}
.guide-page .al-section-dark .al-booking-box p { color: var(--guide-text); }

@media (max-width: 900px) {
  .guide-page .al-section { padding-top: 66px; padding-bottom: 66px; }
  .guide-page .al-section:has(> .al-jump-links:only-child) { padding-top: 20px; padding-bottom: 22px; }
  .guide-page .al-section:has(> .al-fact-strip:only-child) { padding-top: 28px; padding-bottom: 28px; }
  .guide-page .al-card-grid,
  .guide-page .al-card-grid:has(> .wp-block-column:nth-child(5):last-child) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .guide-page .al-card-grid > .wp-block-column { grid-column: auto !important; }
  .guide-page .al-fact-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .guide-page .al-fact-strip > .wp-block-column:nth-child(2) { border-right: 0; }
  .guide-page .al-fact-strip > .wp-block-column:nth-child(-n+2) { border-bottom: 1px solid #d2dfd1; }
  .guide-page .al-story-split:has(.al-compare-table),
  .guide-page .al-story-split:nth-of-type(even):has(.al-compare-table) {
    grid-template-columns: minmax(0, 1fr);
  }
  .guide-page .al-story-split:has(.al-compare-table) img { max-height: 330px; }
  .guide-page .al-time-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 650px) {
  .guide-page { --guide-gutter: 20px; }
  .guide-page .al-guide-hero { min-height: 520px !important; }
  .guide-page .al-guide-hero .wp-block-cover__background {
    background: linear-gradient(90deg, #092b26e0, #092b2699) !important;
  }
  .guide-page .al-guide-hero .wp-block-cover__inner-container {
    width: calc(100% - var(--guide-gutter) - var(--guide-gutter));
    margin: auto;
    padding: 62px 0;
  }
  .guide-page .al-guide-hero :is(.al-guide-title, .al-display-heading) {
    font-size: clamp(43px, 11vw, 58px);
    line-height: 1.06;
    overflow-wrap: anywhere;
  }
  .guide-page .al-guide-hero :is(.al-guide-lead, .al-lead) { font-size: 17px; }
  .guide-page .al-section { padding-top: 55px; padding-bottom: 57px; }
  .guide-page .al-section:has(> .al-jump-links:only-child) { padding-top: 17px; padding-bottom: 19px; }
  .guide-page .al-section h2,
  .guide-page .al-section .al-display-heading { font-size: clamp(32px, 8vw, 40px); }
  .guide-page .al-section > p { font-size: 16px; }
  .guide-page .al-card-grid,
  .guide-page .al-card-grid:has(> .wp-block-column:nth-child(5):last-child),
  .guide-page .al-story-split,
  .guide-page .al-story-split:nth-of-type(even),
  .guide-page .al-story-split:has(.al-compare-table),
  .guide-page .al-story-split:nth-of-type(even):has(.al-compare-table),
  .guide-page .al-time-grid,
  .guide-page .al-review-grid,
  .guide-page .wp-block-columns:not(.al-fact-strip),
  .guide-page .al-guide-list { grid-template-columns: minmax(0, 1fr); }
  .guide-page .al-card-grid > .wp-block-column { grid-column: auto !important; }
  .guide-page .al-card-grid figure.wp-block-image img { height: 215px; }
  .guide-page .al-story-split { gap: 23px; margin: 36px 0 48px; }
  .guide-page .al-booking-box { padding: 27px 24px; }
  .guide-page .al-section-dark.al-booking-box { padding-top: 57px; padding-bottom: 60px; }
  .guide-page .al-compare-table,
  .guide-page .wp-block-table { margin: 24px 0; }
  .guide-page table { font-size: 13px; }
}

@media (max-width: 480px) {
  .guide-page .al-fact-strip { grid-template-columns: minmax(0, 1fr); }
  .guide-page .al-fact-strip > .wp-block-column {
    border-right: 0;
    border-bottom: 1px solid #d2dfd1;
    padding: 18px 20px;
  }
  .guide-page .al-fact-strip > .wp-block-column:last-child { border-bottom: 0; }
  .guide-page .al-card-grid > .wp-block-column { padding: 21px; }
  .guide-page .al-card-grid figure.wp-block-image { margin: -21px -21px 21px; }
}

@media (prefers-reduced-motion: reduce) {
  .guide-page .al-card-grid img { transition: none; }
}
