/*
 * JAM WordPress layer.
 *
 * styles.css is the exported visual foundation from the static site. Keep
 * WordPress-specific adjustments here so the foundation remains reusable.
 */

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
}

/* The main class is the stable hook for all site content. Keep the base font
 * here, while the detailed rules below target regular content only. */
.jam-content-area {
  color: var(--jam-ink);
  font-family: "Plus Jakarta Sans", Arial, sans-serif;
}

/* Standard typography for regular WordPress/WPBakery text. Components such
 * as .page-hero are outside these selectors and retain their own visual rules. */
.jam-content-area__inner > :where(h1, h2, h3, h4, h5, h6),
.jam-content-area__inner .wpb_text_column :where(h1, h2, h3, h4, h5, h6),
.jam-content-area__inner .vc_custom_heading:where(h1, h2, h3, h4, h5, h6) {
  color: rgb(17, 63, 120);
  font-family: "Antique Olive Compact", "Arial Narrow", sans-serif;
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 0.92;
  margin: 0 0 1.15rem;
  text-transform: uppercase;
}

/* Add alt-font to a WPBakery Custom Heading's Extra class name field, or
 * directly to a heading, when it should use the site's sans-serif font.
 * Keep jam-title-sans as a backwards-compatible alias. */
.jam-content-area .alt-font,
.jam-content-area .alt-font :where(h1, h2, h3, h4, h5, h6),
.jam-content-area :where(h1, h2, h3, h4, h5, h6).alt-font,
.jam-content-area .jam-title-sans,
.jam-content-area .jam-title-sans :where(h1, h2, h3, h4, h5, h6),
.jam-content-area :where(h1, h2, h3, h4, h5, h6).jam-title-sans {
  font-family: "Plus Jakarta Sans", Arial, sans-serif !important;
  text-transform: none !important;
}

/* Use on a button itself or on a WPBakery button element's wrapper. */
.jam-content-area .bold,
.jam-content-area .bold :where(a, button, input[type="submit"]),
.jam-content-area :where(a, button, input[type="submit"]).bold {
  font-weight: 800 !important;
}

.jam-content-area__inner > :where(h1),
.jam-content-area__inner .wpb_text_column :where(h1),
.jam-content-area__inner .vc_custom_heading:where(h1) {
  font-size: clamp(3.75rem, 6.8vw, 6.5rem);
}

.jam-content-area__inner > :where(h2),
.jam-content-area__inner .wpb_text_column :where(h2),
.jam-content-area__inner .vc_custom_heading:where(h2) {
  font-size: clamp(3.15rem, 5.4vw, 5.1rem);
}

.jam-content-area__inner > :where(h3),
.jam-content-area__inner .wpb_text_column :where(h3),
.jam-content-area__inner .vc_custom_heading:where(h3) {
  font-size: clamp(2.45rem, 4.1vw, 3.8rem);
}

.jam-content-area__inner > :where(h4),
.jam-content-area__inner .wpb_text_column :where(h4),
.jam-content-area__inner .vc_custom_heading:where(h4) {
  font-size: clamp(1.95rem, 3.1vw, 2.85rem);
}

.jam-content-area__inner > :where(h5),
.jam-content-area__inner .wpb_text_column :where(h5),
.jam-content-area__inner .vc_custom_heading:where(h5) {
  font-size: clamp(1.65rem, 2.5vw, 2.35rem);
}

.jam-content-area__inner > :where(h6),
.jam-content-area__inner .wpb_text_column :where(h6),
.jam-content-area__inner .vc_custom_heading:where(h6) {
  font-size: clamp(1.4rem, 2vw, 1.9rem);
}

.jam-content-area__inner > :where(p, li, blockquote, figcaption, label, span),
.jam-content-area__inner .wpb_text_column :where(p, li, blockquote, figcaption, label, span) {
  font-family: inherit;
}

.jam-content-area__inner > :where(p, li, blockquote, figcaption),
.jam-content-area__inner .wpb_text_column :where(p, li, blockquote, figcaption) {
  color: #516273;
  font-size: 1rem;
  line-height: 1.65;
}

.jam-content-area__inner > :where(p),
.jam-content-area__inner .wpb_text_column :where(p) {
  margin: 0 0 1.25rem;
}

.jam-content-area__inner > :where(ul, ol),
.jam-content-area__inner .wpb_text_column :where(ul, ol) {
  list-style: disc;
  margin: 0 0 1.5rem;
  padding-inline-start: 1.25rem;
}

.jam-content-area__inner > :where(ol),
.jam-content-area__inner .wpb_text_column :where(ol) {
  list-style: decimal;
}

.jam-content-area__inner > :where(a:not(.button):not(.text-link):not(.nav-cta)),
.jam-content-area__inner .wpb_text_column :where(a:not(.button):not(.text-link):not(.nav-cta)) {
  color: var(--jam-blue);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.jam-content-area__inner > :where(a:not(.button):not(.text-link):not(.nav-cta)):hover,
.jam-content-area__inner .wpb_text_column :where(a:not(.button):not(.text-link):not(.nav-cta)):hover {
  color: var(--jam-orange);
}

.site-header:not(.site-header--overlay) {
  position: relative;
  background: #fff;
}

.site-header--overlay.site-header--scrolled {
  background: #fff;
  box-shadow: 0 8px 26px rgba(4, 31, 61, 0.12);
}

.site-header--overlay.site-header--scrolled .desktop-nav > a:not(.nav-cta) {
  color: var(--jam-blue);
}

.mobile-menu-panel:not(.is-open) {
  pointer-events: none;
}

.mobile-menu-panel.is-open {
  pointer-events: auto;
}

/* The scrolled overlay header keeps the entrance animation's transform.
 * A transformed ancestor changes the containing block of a fixed menu panel,
 * which can make the panel stop at the header height in desktop emulation. */
body.jam-menu-open .site-header {
  animation: none !important;
  transform: none !important;
}

.mobile-menu-panel {
  box-sizing: border-box;
  height: 100vh;
  height: 100dvh;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.site-header a:focus-visible,
.site-header button:focus-visible,
.site-footer a:focus-visible {
  outline: 3px solid var(--jam-orange);
  outline-offset: 4px;
}

.footer-tagline {
  max-width: 380px;
}

.footer-legal {
  align-items: center;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
}

.footer-legal a {
  color: var(--jam-blue);
  font-weight: 800;
  text-underline-offset: 3px;
}

.footer-legal a:hover {
  color: var(--jam-orange);
  text-decoration: underline;
}

.jam-error-message {
  background: var(--jam-cream);
}

.jam-error-message .button {
  margin-top: 18px;
}

/* Keep normal WPBakery page content inside the JAM shell. The hero remains
 * full bleed so it can keep the same treatment as the static inner pages. */
.page-content__shell {
  width: min(1240px, calc(100% - 48px));
}

.page-content__shell > .wpb-content-wrapper {
  width: 100%;
}

.page-content__shell .vc_row {
  margin-left: 0;
  margin-right: 0;
}

.page-content__shell .page-hero {
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}

.page-content__shell .vc_row:has(.page-hero) .vc_column-inner {
  padding-left: 0;
  padding-right: 0;
}

/* In WPBakery the contact-form class is on the column, while the static
 * design used it on the form itself. Prevent that grid rule from narrowing
 * the Gravity Forms wrapper to one half of the column. */
.page-content__shell .vc_column_container.contact-form {
  display: block;
  grid-template-columns: none;
  background: transparent;
  box-shadow: none;
}

.page-content__shell .vc_column_container.contact-form > .vc_column-inner {
  padding: clamp(26px, 4vw, 52px) !important;
  background: #fff;
  box-shadow: 0 30px 70px #16365217;
}

.jam-content-area .gform-theme--foundation .gform_fields {
  row-gap: 20px !important;
}

.jam-content-area .gform-theme--framework .gfield_list_group_item::before,
.jam-content-area .gform-theme--framework .gform-field-label:where(:not([class*="gform-field-label--type-"])) {
  text-transform: uppercase !important;
}

.jam-content-area .gform_wrapper .gform_button.button {
  width: auto !important;
  min-height: 52px !important;
  padding: 13px 24px !important;
  border: 0 !important;
  border-radius: 2px !important;
  background: #EF8528 !important;
  box-shadow: none;
  color: #08294F !important;
  cursor: pointer;
  font-family: "Plus Jakarta Sans", Arial, sans-serif;
  font-size: 0.82rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.065em !important;
  line-height: 1.2;
  text-transform: uppercase !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.jam-content-area .gform_wrapper .gform_button.button:hover {
  background: #D9721C !important;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
  transform: translateY(-2px);
}

.jam-content-area .gform_wrapper .gform_button.button:focus-visible {
  outline: 3px solid #EF8528;
  outline-offset: 4px;
}

/* The vc_row_inner.php override normalizes the unit-bearing class and lets
 * WPBakery create the visible space between each column's inner surface. */
.jam-content-area .vc_row.wpb_column-gap {
  margin-left: calc((30px + var(--wpb-column-gap, 0px)) / -2) !important;
  margin-right: calc((30px + var(--wpb-column-gap, 0px)) / -2) !important;
}

.jam-content-area .vc_row.wpb_column-gap > .vc_column_container {
  padding: calc(var(--wpb-column-gap, 0px) / 2) !important;
}

/* JAM FAQ component. Keep the component limited to the question list from
 * faq.html; the event-information card is intentionally not rendered here.
 * It stays inside its WPBakery column so neighboring custom content remains
 * visible. */
.jam-content-area .jam-faq {
  width: 100%;
}

.jam-content-area .jam-faq .faq-item__heading {
  margin: 0;
}

.jam-content-area .jam-faq .faq-trigger {
  width: 100%;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  border: 0;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.jam-content-area .jam-faq .faq-trigger:hover {
  text-decoration: none !important;
}

.jam-content-area .jam-faq .faq-trigger > span:first-child {
  min-width: 0;
  flex: 1 1 auto;
}

.jam-content-area .jam-faq .faq-trigger > svg {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  margin-top: 2px;
  transition: transform 0.2s ease;
}

.jam-content-area .jam-faq .faq-trigger[aria-expanded="true"] > svg {
  transform: rotate(180deg);
}

.jam-content-area .jam-faq .faq-panel[hidden] {
  display: none;
}

.jam-content-area .jam-faq .faq-answer__inner > :first-child {
  margin-top: 0;
}

.jam-content-area .jam-faq .faq-answer__inner > :last-child {
  margin-bottom: 0;
}

/* JAM Values component. auto-fit lets 1, 2, 3 or 4 cards fill the available
 * row without leaving an empty fourth track when fewer cards are added. */
.jam-content-area .jam-values .value-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  gap: 14px;
}

.jam-content-area .jam-values .value-card {
  min-width: 0;
}

.jam-content-area .jam-values .value-card__icon {
  display: block;
  width: 34px;
  height: 34px;
  margin-bottom: 60px;
  object-fit: contain;
}

.jam-content-area .jam-values .value-card img.value-card__icon {
  object-position: left center;
}

/* JAM What Moves Us component. The base pillar layout comes from the static
 * visual foundation; these classes let each repeatable item keep its number
 * color when the item is reordered or manually customized in WPBakery. */
.jam-content-area .jam-pillars .pillar__number {
  display: block;
}

.jam-content-area .jam-pillars .pillar--cyan .pillar__number {
  color: var(--jam-cyan);
}

.jam-content-area .jam-pillars .pillar--orange .pillar__number {
  color: var(--jam-orange);
}

.jam-content-area .jam-pillars .pillar--magenta .pillar__number {
  color: var(--jam-magenta);
}

.jam-content-area .jam-pillars .pillar--blue .pillar__number {
  color: var(--jam-blue-bright);
}

.jam-content-area .jam-pillars .pillar h3 {
  color: rgb(17, 63, 120);
  text-transform: uppercase;
}

/* The page template already provides the shared shell. Keep the visit card
 * aligned with that shell instead of applying the static site's second shell
 * width when this block is inserted through WPBakery. */
.jam-content-area .jam-visit-date .visit-card {
  width: 100%;
}

/* Sponsors use a full-bleed background with the content kept inside the
 * site's shared shell, just like the static homepage section. */
.jam-content-area .jam-sponsors {
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}

.jam-content-area .jam-sponsors__inner {
  width: min(1240px, calc(100% - 48px));
}

.page-content__shell .vc_row:has(.jam-sponsors) .vc_column-inner {
  padding-left: 0;
  padding-right: 0;
}

/* Sponsor cards are links only when a sponsor URL is supplied in WPBakery. */
.jam-content-area .jam-sponsors .sponsor-card--linked {
  color: inherit;
  text-decoration: none;
}

.jam-content-area .jam-sponsors .sponsor-card--linked:focus-visible {
  outline: 3px solid var(--jam-orange);
  outline-offset: 4px;
}

.jam-content-area .jam-sponsors .sponsor-card__name {
  color: var(--jam-blue);
  font-size: 0.82rem;
  font-weight: 800;
  text-align: center;
}

@media (max-width: 1000px) {
  .jam-content-area .jam-values .value-card__icon {
    margin-bottom: 32px;
  }
}

/* JAM homepage hero component. Only this component is full bleed: regular
 * WPBakery content keeps the shared shell and column boundaries. */
#home-content .jam-home-hero {
  width: 100vw;
  max-width: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}

#home-content .vc_row:has(.jam-home-hero) .vc_column-inner {
  padding-right: 0;
  padding-left: 0;
}

#home-content .jam-home-hero__title--single span:last-child {
  color: inherit;
}

#home-content .jam-home-hero__image {
  display: block;
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  object-fit: cover;
  object-position: center;
}

/* JAM Lineup component. The static artist-card rules provide the grid,
 * image wash and responsive layout; these additions cover the WordPress
 * link state and the optional borderless card. */
.jam-content-area .jam-lineup .artist-card--linked {
  color: inherit;
  text-decoration: none;
}

.jam-content-area .jam-lineup .artist-card--linked:focus-visible {
  outline: 3px solid var(--jam-orange);
  outline-offset: 4px;
}

.jam-content-area .jam-lineup .artist-card--none {
  border-bottom: 0;
}

@media (prefers-reduced-motion: reduce) {
  .jam-content-area .jam-faq .faq-trigger > svg {
    transition: none;
  }
}

@media (max-width: 1000px) {
  .site-header--overlay.site-header--scrolled {
    box-shadow: 0 6px 22px rgba(4, 31, 61, 0.16);
  }
}

@media (max-width: 720px) {
  #home-content .jam-home-hero .hero__content {
    padding-left: 28px;
  }

  .jam-content-area .jam-faq .faq-trigger > span:first-child {
    overflow-wrap: anywhere;
  }

  .jam-content-area .jam-faq .faq-answer {
    padding-right: 26px;
    padding-left: 0;
  }

  .page-content__shell {
    width: calc(100% - 28px);
  }

  .jam-content-area .jam-sponsors__inner {
    width: calc(100% - 28px);
  }

  .footer-legal {
    justify-content: center;
  }
}
