/* Skydive Utah: page-level styles. site.css holds the shared layout; this file holds
   fixes found while comparing each page with the previous site (rules scoped to
   .page-<slug>), plus a few general block rules. Loaded after site.css.
   Author: David Cowman - Datapoint Digital Ltd. */


/* ===== First Skydive pages, videos, calendar, gift cards ===== */

/* GENERAL */
/* Photo strip: a gallery with "aspect": "strip" is one 2:1 frame; the photos keep
   their own shape at full frame height, sit side by side and scroll sideways. */
.b-gallery--strip { display: flex; gap: 0; aspect-ratio: 2 / 1; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; background: #000; }
.b-gallery--strip::-webkit-scrollbar { display: none; }
.b-gallery--strip li { flex: none; height: 100%; scroll-snap-align: center; }
.b-gallery--strip img { height: 100%; width: auto; max-width: none; aspect-ratio: auto; object-fit: contain; }

/* GENERAL */
/* Indented paragraph (FAQ answers): <p class="indent"> inside a text block. */
.b-text p.indent { margin-left: 40px; }

/* GENERAL */
/* A caption directly under a video sits 18px below it, whatever follows the general block gap rule. */
.content > .b-video + .b-video__cap, .b-col > .b-video + .b-video__cap { margin-top: 18px; }

/* /tandemskydive-qr and /espanol use the medium pill (15px, 63px tall). */
.page-tandemskydive-qr .content .pill, .page-espanol .content .pill { font-size: 15px; line-height: 21px; padding: 21px 34px; }
.page-tandemskydive-qr .content > .b-video + .b-heading { margin-top: 20px; }

/* Two page-title lines typed as two h2: a full line apart. */
.page-photo-and-video-packages .content > .b-heading + h2.b-heading:not(.as-h1),
.page-tandemskydive-qr .content > h2.b-heading + h2.b-heading { margin-top: 30px; }

/* /what-to-expect: the rule sits further below the video caption. */
.page-what-to-expect .content > .b-video__cap + .b-rule { margin-top: 52px; }

/* /gift-cards: photo rows have wide gaps. */
.page-gift-cards .b-gallery { gap: 20px; }
.page-gift-cards .content > .b-gallery + .b-heading { margin-top: 52px; }

/* /espanol: the e-mail address is underlined. */
.page-espanol .b-text a[href^="mailto:"] { text-decoration: underline; }

@media (min-width: 641px) {
  /* /photo-and-video-packages: price column is 3 of 12 columns measured with the gutters. */
  .page-photo-and-video-packages .b-columns[style*="3fr 9fr"] { grid-template-columns: calc((100% + var(--gap)) * .25 - var(--gap)) 1fr; }
  /* /espanol: three buttons, one per equal column; a long label wraps inside its column. */
  .page-espanol .b-buttons--row { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); align-items: start; justify-items: center; }
}

/* /tandemskydive: the discount groups are a blank line further apart. */
.page-tandemskydive .content > .has-gap { margin-top: 64px !important; }

/* /facilities: the photo sits well below the text. */
.page-facilities .content > .b-text + .b-image { margin-top: 80px; }


/* ===== Skydive School and Experienced pages ===== */

/* GENERAL */
/* A list that ends a text block keeps the 8px under its last item (it was collapsing into the block gap). */
.b-text > ul:last-child, .b-text > ol:last-child { padding-bottom: 8px; }
.b-text > ul:last-child > li:last-child, .b-text > ol:last-child > li:last-child { margin-bottom: 0; }
/* GENERAL */
/* Price table header row is the same height as the body rows (20px text on a 25.6px line). */
.b-table th { line-height: 25.6px; }

/* An empty line between two text groups (16 + 25.6 + 16), as on /contact-info and /location. */
.page-recurrency .content > .has-gap,
.page-experienced-prices .content > .has-gap,
.page-program-overview .content > .has-gap { margin-top: 57.6px !important; }

/* /why-learn-at-skydive-utah: three medium pills, one per equal column, labels wrap inside the column. */
.page-why-learn-at-skydive-utah .content .pill,
.page-skydive-school-prices .content > .b-buttons:last-child .pill { font-size: 15px; line-height: 21px; padding: 21px 34px; }
@media (min-width: 641px) {
  .page-why-learn-at-skydive-utah .b-buttons--row { display: grid; grid-template-columns: repeat(3, 1fr); align-items: start; justify-items: center; }
}

/* /school-faq: answers sit 40px in from the bold questions. */
.page-school-faq .b-text p:not(:has(strong)) { margin-left: 40px; }

/* /useful-links: the form runs the full column width, like the rule under it. */
.page-useful-links .sform { max-width: none; margin-bottom: 0; }

/* /experienced-prices: the jump price group ends with an empty line before the rule. */
.page-experienced-prices .content > .has-gap { padding-bottom: 41.6px; }
/* /experienced-prices, /exit-order: the page ends with an empty line. */
.page-experienced-prices .content > :last-child { padding-bottom: 41.6px; }
.page-exit-order .content > :last-child { padding-bottom: 25.6px; }

/* /exit-order: the heading is its own block, a full block gap under the intro. */
.page-exit-order .content > .b-text + .b-heading { margin-top: var(--gap); }

/* /learn-to-wingsuit: small 3:2 thumbnails, four slots per row (two on phones), 20px apart. */
.page-learn-to-wingsuit .b-gallery { gap: 20px; }
.page-learn-to-wingsuit .content > .b-gallery + * { margin-top: 54px; }

/* /rigging-experienced, /rigging-1: plain price list, not the dark price table. */
.page-rigging-experienced .b-table table,
.page-rigging-1 .b-table table { margin: 0; background: none; border: 0; font-family: var(--body); }
.page-rigging-experienced .b-table tr th, .page-rigging-experienced .b-table tr td,
.page-rigging-1 .b-table tr th, .page-rigging-1 .b-table tr td { border: 0; background: none; padding: 1px; color: var(--black); font-size: 16px; line-height: 25.6px; text-align: left; }
.page-rigging-experienced .b-table tr th,
.page-rigging-1 .b-table tr th { font-weight: 700; text-align: center; }
.page-rigging-experienced .b-table tr td:last-child, .page-rigging-experienced .b-table tr th:last-child,
.page-rigging-1 .b-table tr td:last-child, .page-rigging-1 .b-table tr th:last-child { padding-left: 14px; text-align: left; }


/* ===== Home, contact, blog, article pages and shared layout corrections ===== */

/* SHARED LAYOUT */
/* Top menu: 4px between items, 17px before the BOOK NOW pill (measured: About starts at x=346 at 1440). */
.topnav__list { gap: 4px; }
.site-header__book { margin-left: 17px; }
/* Menu panel: the close link is for no-script use only (".panel a" was out-ranking its display: none). */
.js .panel .panel__close { display: none; }
/* Menu panel, open folder: children start 3px closer to the label, 22.75px under the last child. */
.panel details ul { margin-top: -3.25px; padding-bottom: 22.75px; }
@media (max-width: 640px) {
  /* Footer: on phones only the word EMAIL shows, not the address as well. */
  .site-footer__line a .only-wide { display: none; }
  /* Section toggle list: first item level with the sign, 48.5px item pitch, content 36px under the last item. */
  .secnav.is-open .secnav__list, .no-js .secnav__list { padding-bottom: 12px; }
  .secnav__list a { padding: 0 0 34.5px; }
  .secnav__list li { display: flex; }
  .secnav__list li:has(a[aria-current]) { display: none; }
}

/* GENERAL */
/* An image that opens a column or the page has no space above it (figure default margin). */
.b-col > .b-image:first-child, .content > .b-image:first-child { margin-top: 0; }
/* Measured space above the footer: 17px more on these pages, and on every page on phones. */
.page-location .content, .page-accommodations .content { padding-bottom: 17px; }
.page-skydiving-licenses-explained .content { padding-bottom: 68px; }
@media (max-width: 640px) { .content, .page-skydiving-licenses-explained .content { padding-bottom: 17px; } }
/* Pages without a section menu start 17px lower on phones. */
@media (max-width: 640px) { body:not(.is-blog) .wrap > .content:first-child { padding-top: 17px; } }

/* /contact-info, /location: an empty line between the text groups (16 + 25.6 + 16). */
.page-contact-info .content > .has-gap, .page-location .content > .has-gap { margin-top: 57.6px !important; }
/* /contact-info: the form runs the full column width, like the rule above it. */
.page-contact-info .sform { max-width: none; margin-bottom: 0; }

/* /accommodations: hotel card, photo left and a small centred sans caption right; stacked on phones. */
.page-accommodations .b-columns { gap: 0; }
.page-accommodations .b-col + .b-col { padding: 22px 15px 0; font-family: Arial, Helvetica, sans-serif; }
.page-accommodations .b-col h3 { font: 400 21.74px/1.1 Arial, Helvetica, sans-serif; padding: 0 20px; }
.page-accommodations .b-col .b-text { margin-top: 13px; font-size: 12px; line-height: 14.4px; }
.page-accommodations .b-col .b-text p { margin: 12px 0; }
.page-accommodations .b-col .b-text > :first-child { margin-top: 0; }
.page-accommodations .b-col .b-text > :last-child { margin-bottom: 0; }
.page-accommodations .b-col a { color: #000; }
@media (max-width: 640px) {
  .page-accommodations .b-col + .b-col { margin-top: 0; padding-top: 15px; }
}

/* Blog index and posts: date, title, author, then the body 35px lower; an empty line where the post has one. */
.is-blog .content > .is-post-date + h1, .is-blog .content > .is-post-date + .as-h1 { margin-top: 12px; }
.is-blog .content > h1 + .is-post-meta, .is-blog .content > .as-h1 + .is-post-meta { margin-top: 12px; }
.is-blog .content > .is-post-meta + * { margin-top: 35px !important; }
.is-blog .content > .has-gap { margin-top: 57.6px !important; }
.is-blog .content > h3.has-gap { margin-top: 61.6px !important; }
/* Index: 128px between posts (80px on phones). */
.is-blog .content > * + .is-post-date { margin-top: 128px !important; }
/* Post links: label on its own line; the older post sits right, the newer one left. */
.is-blog .postnav span { display: block; margin-right: 0; }
@media (max-width: 640px) {
  .is-blog .content > * + .is-post-date { margin-top: 80px !important; }
  .is-blog .content > .is-post-meta + * { margin-top: 29px !important; }
  .page-skydiveutahblog h1, .page-skydiveutahblog .as-h1 { font-size: 26px; }
}

/* ---------- Article pages (no section menu): /aff-guide, /i-got-my-a-license-now-what,
   /skydiving-licenses-explained, /why-should-i-get-my-skydiving-license, /disciplines-of-skydiving ---------- */
/* Empty lines and empty photo slots are blocks like any other: 34px around them. */
:is(.page-aff-guide, .page-i-got-my-a-license-now-what, .page-skydiving-licenses-explained, .page-why-should-i-get-my-skydiving-license, .page-disciplines-of-skydiving) .content :is(.is-blank, .is-placeholder) + *, :is(.page-aff-guide, .page-i-got-my-a-license-now-what, .page-skydiving-licenses-explained, .page-why-should-i-get-my-skydiving-license, .page-disciplines-of-skydiving) .content * + .is-placeholder { margin-top: 34px; }
/* The empty line under each heading, and 52px under a photo. */
:is(.page-aff-guide, .page-i-got-my-a-license-now-what, .page-skydiving-licenses-explained, .page-why-should-i-get-my-skydiving-license, .page-disciplines-of-skydiving) .content .b-heading + .is-blank { margin-top: 16px; }
:is(.page-aff-guide, .page-i-got-my-a-license-now-what, .page-skydiving-licenses-explained, .page-why-should-i-get-my-skydiving-license, .page-disciplines-of-skydiving) .content .b-image + * { margin-top: 52px; }
/* Empty photo slot: keeps the space of a 16:9 photo. */
.is-placeholder { aspect-ratio: 16 / 9; }
/* Small plain icons where a page ends with its own social row. GENERAL */
.b-social a { width: 22px; height: 22px; box-shadow: none; }

/* /aff-guide */
.page-aff-guide .content > .b-text:nth-child(2), .page-skydiving-licenses-explained .content > .b-text:nth-child(2) { max-width: 791px; margin-left: auto; margin-right: auto; }
.page-aff-guide .content > .b-text:nth-child(2) a { text-decoration: underline; }
.page-aff-guide img[src*="img-1829"] { aspect-ratio: 1; object-fit: cover; }
.page-aff-guide .content > .b-rule ~ .b-columns + .b-rule { margin-top: 52px; }

/* /i-got-my-a-license-now-what */
.page-i-got-my-a-license-now-what img[src*="gh010334"] { aspect-ratio: 2 / 1; object-fit: cover; }
.page-i-got-my-a-license-now-what .b-col img { aspect-ratio: 4 / 3; object-fit: cover; }

/* /skydiving-licenses-explained */
.page-skydiving-licenses-explained .b-col img:not([src*="20231105"]) { aspect-ratio: 4 / 3; object-fit: cover; }
.page-skydiving-licenses-explained .content > h1 + .b-text { margin-top: 20px; }

@media (min-width: 641px) {
  .page-aff-guide .content > .b-columns + .b-rule { margin-top: 52px; }
  .page-aff-guide .b-rule ~ .b-rule + .b-columns .b-image { margin-top: 68px; }
  .page-aff-guide .content > .b-columns + .is-blank { margin-top: 52px; }
  .page-i-got-my-a-license-now-what .content > h1 + .b-image { margin-top: 94px; }
  .page-i-got-my-a-license-now-what .b-col:nth-child(1) > :nth-child(4) { margin-top: 102px; }
  .page-i-got-my-a-license-now-what .b-col:nth-child(1) > :nth-child(6) { margin-top: 152px; }
  .page-i-got-my-a-license-now-what .b-col:nth-child(2) > :nth-child(4) { margin-top: 177px; }
  .page-i-got-my-a-license-now-what .b-col:nth-child(2) > :nth-child(6) { margin-top: 119px; }
  .page-skydiving-licenses-explained .content > .b-text + .b-columns { margin-top: 17px; }

  /* /why-should-i-get-my-skydiving-license and /disciplines-of-skydiving: one 461px column in the middle. */
  .page-why-should-i-get-my-skydiving-license .content, .page-disciplines-of-skydiving .content { flex: 0 1 461px; margin: 0 auto; }
  .page-why-should-i-get-my-skydiving-license .content { padding-top: 60px; }
  .page-why-should-i-get-my-skydiving-license .is-blank + :not(.b-rule) { margin-top: 102px; }
  .page-why-should-i-get-my-skydiving-license .is-blank + .b-image:nth-child(3) { margin-top: 93px; }
  .page-disciplines-of-skydiving .content > .is-placeholder + h3:nth-child(2) { margin-top: 94px; }
  .page-disciplines-of-skydiving .content > .is-blank + h3 { margin-top: 101px; }
}
@media (max-width: 640px) {
  /* Stacked columns: 52px under a column that ends with a photo. */
  :is(.page-aff-guide, .page-i-got-my-a-license-now-what, .page-skydiving-licenses-explained) .b-col:has(> .b-image:last-child) + .b-col { margin-top: 52px; }
}

@media (max-width: 640px) {
  /* Keeps the longest heading on one line at 390px. */
  .page-disciplines-of-skydiving h3 { letter-spacing: -.4px; }
}
@media (min-width: 641px) {
  /* /aff-guide: 12-column widths with a 34px gutter (5+7, 8+4, 4+8). */
  .page-aff-guide .b-buttons + .b-columns { grid-template-columns: 379fr 543fr; }
  .page-aff-guide .b-rule + .b-columns { grid-template-columns: 626fr 296fr; }
  .page-aff-guide .b-rule ~ .b-rule + .b-columns { grid-template-columns: 296fr 626fr; }
}
.b-social a svg { width: 28px; height: 28px; flex: none; }

/* ===== Slideshow buttons, post navigation ===== */
.b-strip { position: relative; }
.b-strip__btn { position: absolute; top: 50%; width: 40px; height: 40px; margin-top: -20px; border: 0; padding: 0; background: rgba(0, 0, 0, .12); color: #fff; cursor: pointer; display: grid; place-items: center; }
.b-strip__btn--prev { left: 0; }
.b-strip__btn--next { right: 0; }
.b-strip__btn svg { width: 14px; height: 22px; }
.no-js .b-strip__btn { display: none; }
.is-blog .postnav--newer { text-align: left; }
