/* Shared navigation and content pages for asociacionmariabejarano.com */
:root {
  --amb-ink: #2a292b;
  --amb-muted: #5b5960;
  --amb-accent: #b196f7;
  --amb-accent-dark: #7a5bd6;
  --amb-mint: #58fec6;
  --amb-soft: #f6f3fe;
  --amb-line: #e4dff2;
  --amb-heading: "Noto Sans", Raleway, sans-serif;
  --amb-body: Raleway, sans-serif;
  --amb-ui: "Work Sans", Raleway, sans-serif;
}

/* ---------- Navigation ---------- */
#header-outer #top .col.span_9 {
  display: flex !important;
  align-items: center;
  justify-content: flex-end;
}

.amb-nav {
  display: flex;
  align-items: center;
  height: 100%;
}

.amb-nav__list {
  display: flex;
  gap: 40px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.amb-nav__list li {
  float: none;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Beats the theme's #header-outer.transparent link colours. */
#header-outer #top nav.amb-nav .amb-nav__link,
#header-outer.transparent #top nav.amb-nav .amb-nav__link {
  position: relative;
  display: inline-block;
  padding: 8px 0 !important;
  color: var(--amb-ink) !important;
  font-family: var(--amb-ui);
  font-size: 17px !important;
  font-weight: 600 !important;
  line-height: 1.2 !important;
  text-decoration: none;
  opacity: 1 !important;
}

.amb-nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--amb-accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s ease;
}

.amb-nav__link:hover::after,
.amb-nav__link:focus-visible::after,
.amb-nav__link[aria-current="page"]::after {
  transform: scaleX(1);
}

.amb-nav__toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--amb-ink);
  cursor: pointer;
}

.amb-nav__toggle-bars,
.amb-nav__toggle-bars::before,
.amb-nav__toggle-bars::after {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform .25s ease, opacity .25s ease;
}

.amb-nav__toggle-bars {
  position: relative;
}

.amb-nav__toggle-bars::before,
.amb-nav__toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  transform-origin: center;
}

.amb-nav__toggle-bars::before { top: -7px; }
.amb-nav__toggle-bars::after { top: 7px; }

.amb-nav__toggle[aria-expanded="true"] .amb-nav__toggle-bars { background: transparent; }
.amb-nav__toggle[aria-expanded="true"] .amb-nav__toggle-bars::before { transform: translateY(7px) rotate(45deg); }
.amb-nav__toggle[aria-expanded="true"] .amb-nav__toggle-bars::after { transform: translateY(-7px) rotate(-45deg); }

.amb-nav__link:focus-visible,
.amb-nav__toggle:focus-visible,
.amb-btn:focus-visible,
.amb-faq summary:focus-visible {
  outline: 2px solid var(--amb-accent-dark);
  outline-offset: 4px;
}

@media only screen and (max-width: 999px) {
  /* The theme hides the header nav and centres the logo on mobile. */
  #header-outer #top .col.span_9 {
    pointer-events: none;
  }

  #header-outer #top nav.amb-nav {
    display: flex !important;
    justify-content: flex-end;
    width: 100%;
    pointer-events: auto;
  }

  .amb-nav__toggle {
    display: inline-flex;
  }

  #header-outer #top .amb-nav__list {
    position: absolute !important;
    top: calc(100% + 12px) !important;
    left: 50% !important;
    right: auto !important;
    width: 100vw !important;
    max-width: none !important;
    margin: 0 !important;
    transform: translateX(-50%);
    flex-direction: column;
    gap: 0;
    padding: 8px 24px 20px !important;
    background: #fff;
    text-align: left !important;
    border-top: 1px solid var(--amb-line);
    box-shadow: 0 18px 30px rgba(42, 41, 43, .08);
  }

  .js #header-outer #top .amb-nav__list[data-open="false"] {
    display: none !important;
  }

  #header-outer #top .amb-nav__list li {
    float: none !important;
    width: 100%;
  }

  #header-outer #top .amb-nav__list li + li {
    border-top: 1px solid var(--amb-line);
  }

  #header-outer #top nav.amb-nav .amb-nav__link,
  #header-outer.transparent #top nav.amb-nav .amb-nav__link {
    display: block;
    padding: 16px 0 !important;
    color: var(--amb-ink) !important;
    font-size: 19px !important;
    line-height: 1.3 !important;
  }

  #header-outer #top .amb-nav__link::after {
    display: none;
  }

  #header-outer #top nav.amb-nav .amb-nav__link[aria-current="page"],
  #header-outer.transparent #top nav.amb-nav .amb-nav__link[aria-current="page"] {
    color: var(--amb-accent-dark) !important;
  }

  .amb-hero {
    padding-top: 36px;
  }
}

/* ---------- Content pages ---------- */
.amb-page {
  color: var(--amb-ink);
  font-family: var(--amb-body);
  font-size: 18px;
  line-height: 1.65;
}

.amb-page *,
.amb-page *::before,
.amb-page *::after {
  box-sizing: border-box;
}

.amb-page [id] {
  scroll-margin-top: 140px;
}

.amb-page h1,
.amb-page h2,
.amb-page h3 {
  color: var(--amb-ink);
  font-family: var(--amb-heading);
  letter-spacing: -.01em;
}

.amb-page h1 {
  max-width: 900px;
  margin: 0 0 28px;
  font-size: clamp(38px, 5vw, 64px);
  font-weight: 800;
  line-height: 1.08;
}

.amb-page h2 {
  margin: 0 0 24px;
  font-size: clamp(30px, 3.4vw, 44px);
  font-weight: 700;
  line-height: 1.15;
}

.amb-page h3 {
  margin: 0 0 10px;
  font-size: clamp(20px, 1.8vw, 24px);
  font-weight: 700;
  line-height: 1.3;
}

.amb-page p {
  margin: 0 0 18px;
  padding: 0;
  color: inherit;
  font-size: inherit;
  line-height: inherit;
}

.amb-page p:last-child {
  margin-bottom: 0;
}

.amb-page a:not(.amb-btn) {
  color: var(--amb-accent-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.amb-wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
}

.amb-wrap--narrow {
  max-width: 860px;
}

.amb-section {
  padding: clamp(64px, 8vw, 110px) 0;
}

.amb-section--soft {
  background: var(--amb-soft);
}

.amb-eyebrow {
  display: inline-block;
  margin-bottom: 18px;
  padding: 6px 16px;
  border-radius: 100px;
  background: var(--amb-accent);
  color: #fff;
  font-family: var(--amb-ui);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .02em;
}

.amb-page .amb-lead {
  max-width: 760px;
  font-size: clamp(19px, 1.6vw, 22px);
  line-height: 1.55;
}

.amb-intro {
  max-width: 760px;
  margin-bottom: 44px;
}

/* Hero */
.amb-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(44px, 5vw, 72px) 0 clamp(70px, 8vw, 110px);
  background:
    radial-gradient(60% 70% at 88% 18%, rgba(177, 150, 247, .45), transparent 70%),
    radial-gradient(50% 60% at 8% 95%, rgba(236, 247, 168, .55), transparent 70%),
    radial-gradient(40% 50% at 55% 110%, rgba(88, 254, 198, .25), transparent 70%),
    #fff;
}

.amb-hero__text {
  max-width: 780px;
}

.amb-hero__text p:not(.amb-lead) {
  font-size: clamp(18px, 1.5vw, 21px);
}

/* Buttons */
.amb-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.amb-actions--center {
  justify-content: center;
}

.amb-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 14px 34px;
  border: 1.5px solid var(--amb-ink);
  border-radius: 200px;
  background: transparent;
  color: var(--amb-ink) !important;
  font-family: var(--amb-ui);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  text-decoration: none !important;
  cursor: pointer;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
}

.amb-btn:hover {
  background: var(--amb-ink);
  color: #fff !important;
  transform: translateY(-1px);
}

.amb-btn--primary {
  border-color: var(--amb-accent);
  background: var(--amb-accent);
  color: #fff !important;
}

.amb-btn--primary:hover {
  border-color: var(--amb-accent-dark);
  background: var(--amb-accent-dark);
}

.amb-btn::after {
  content: "→";
  font-size: 1.1em;
  line-height: 1;
}

/* Notice */
.amb-page .amb-notice {
  max-width: 860px;
  margin-top: 44px;
  padding: 22px 26px;
  border-left: 4px solid var(--amb-accent);
  border-radius: 0 16px 16px 0;
  background: rgba(255, 255, 255, .75);
  font-size: 16px;
  line-height: 1.6;
}

/* Lists rendered as layouts: neutralise theme bullets */
.amb-page .amb-bare {
  margin: 0;
  padding: 0;
  list-style: none;
}

.amb-page .amb-bare > li {
  margin: 0;
  list-style: none;
}

.amb-page .amb-bare > li::before {
  display: none;
}

/* Grid of cards */
.amb-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 22px;
}

.amb-grid--2 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
}

.amb-card {
  display: flex;
  flex-direction: column;
}

.amb-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: auto;
  padding-top: 22px;
}

.amb-card {
  padding: 32px 30px;
  border: 1px solid var(--amb-line);
  border-radius: 20px;
  background: #fff;
}

.amb-card p {
  color: var(--amb-muted);
  font-size: 16px;
  line-height: 1.6;
}

.amb-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  margin-bottom: 18px;
  border-radius: 50%;
  background: var(--amb-soft);
  color: var(--amb-accent-dark);
  font-family: var(--amb-heading);
  font-weight: 800;
}

/* Objectives: at most 3 columns; number badges use the session-card gradients */
.amb-goals {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.amb-goals .amb-card__icon {
  background-color: var(--amb-accent);
  background-position: center;
  background-size: cover;
  color: #fff;
  font-weight: 800;
  text-shadow: 0 1px 3px rgba(42, 41, 43, .45);
}

.amb-goals .amb-card:nth-child(3n + 1) .amb-card__icon { background-image: url("/wp-content/uploads/2023/11/Mesh-gradient3.webp"); }
.amb-goals .amb-card:nth-child(3n + 2) .amb-card__icon { background-image: url("/wp-content/uploads/2023/11/Mesh-gradient2.webp"); }
.amb-goals .amb-card:nth-child(3n + 3) .amb-card__icon { background-image: url("/wp-content/uploads/2023/11/Mesh-gradient-5.webp"); }

/* Two columns */
.amb-split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 90px);
  align-items: start;
}

/* Numbered steps (matches the home page style) */
.amb-steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: amb-step;
}

.amb-steps > li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: center;
  margin: 0;
  padding: 34px 0;
  border-bottom: 1px solid var(--amb-ink);
  list-style: none;
  counter-increment: amb-step;
}

.amb-steps > li:first-child {
  padding-top: 0;
}

.amb-steps > li::after {
  content: counter(amb-step, decimal-leading-zero);
  font-family: var(--amb-heading);
  font-size: clamp(48px, 6vw, 88px);
  font-weight: 800;
  line-height: 1;
}

.amb-steps p {
  max-width: 680px;
  color: var(--amb-muted);
  font-size: 17px;
}

.amb-steps .amb-actions {
  margin-top: 20px;
}

/* Bullet list */
.amb-list {
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.amb-list li {
  position: relative;
  margin: 0 0 10px;
  padding-left: 30px;
  list-style: none;
}

.amb-list li::before {
  content: "";
  position: absolute;
  top: .62em;
  left: 4px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--amb-accent);
}

/* Organisations */
.amb-orgs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 40px;
}

.amb-org {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  height: 100%;
  padding: 28px 22px;
  border: 1px solid var(--amb-line);
  border-radius: 20px;
  background: #fff;
  color: var(--amb-ink) !important;
  text-align: center;
  text-decoration: none !important;
  transition: box-shadow .2s ease, transform .2s ease;
}

.amb-org:hover {
  box-shadow: 0 16px 34px rgba(122, 91, 214, .14);
  transform: translateY(-2px);
}

.amb-org img {
  width: auto;
  max-width: 170px;
  height: 90px;
  margin: 0 !important;
  object-fit: contain;
}

.amb-org span {
  font-size: 15px;
  line-height: 1.45;
}

.amb-org small {
  margin-top: auto;
  color: var(--amb-accent-dark);
  font-family: var(--amb-ui);
  font-size: 13px;
  font-weight: 500;
}

/* Session cards */
.amb-sessions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.amb-session {
  display: flex;
  flex-direction: column;
  padding: clamp(28px, 3vw, 44px);
  border-radius: 20px;
  background-position: center;
  background-size: cover;
}

.amb-session:nth-child(1) { background-image: url("/wp-content/uploads/2023/11/Mesh-gradient3.webp"); }
.amb-session:nth-child(2) { background-image: url("/wp-content/uploads/2023/11/Mesh-gradient2.webp"); }
.amb-session:nth-child(3) { background-image: url("/wp-content/uploads/2023/11/Mesh-gradient-5.webp"); }

.amb-session .amb-eyebrow {
  align-self: flex-start;
}

.amb-session h3 {
  margin-bottom: 14px;
  font-size: clamp(22px, 2vw, 28px);
}

.amb-session p {
  font-size: 17px;
  line-height: 1.55;
}

.amb-session__actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  margin-top: auto;
  padding-top: 26px;
}

.amb-session__actions .amb-btn {
  padding-right: 20px;
  padding-left: 20px;
  background: rgba(255, 255, 255, .35);
}

.amb-session__actions .amb-btn:hover {
  background: var(--amb-ink);
}

.amb-session__actions[data-revealed="false"] .amb-session__pay,
.amb-session__actions[data-revealed="true"] .amb-session__join {
  display: none !important;
}

.amb-session__pay {
  display: flex;
  flex-direction: column;
  align-items: inherit;
  gap: 10px;
}

/* Contact / official data */
.amb-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0 40px;
  margin: 0;
}

.amb-facts div {
  padding: 18px 0;
  border-bottom: 1px solid var(--amb-line);
}

.amb-facts dt {
  margin: 0 0 4px;
  color: var(--amb-muted);
  font-family: var(--amb-ui);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .03em;
  text-transform: uppercase;
}

.amb-facts dd {
  margin: 0;
  padding: 0;
  font-size: 17px;
  line-height: 1.5;
}

/* FAQ */
.amb-faq {
  border-top: 1px solid var(--amb-line);
}

.amb-faq details {
  border-bottom: 1px solid var(--amb-line);
}

.amb-faq summary {
  position: relative;
  padding: 26px 56px 26px 0;
  font-family: var(--amb-heading);
  font-size: clamp(18px, 1.6vw, 21px);
  font-weight: 700;
  line-height: 1.35;
  list-style: none;
  cursor: pointer;
}

.amb-faq summary::-webkit-details-marker {
  display: none;
}

.amb-faq summary::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 1.5px solid var(--amb-ink);
  border-radius: 50%;
  font-family: var(--amb-ui);
  font-size: 20px;
  font-weight: 400;
  line-height: 1;
  transform: translateY(-50%);
  transition: transform .25s ease;
}

.amb-faq details[open] summary::after {
  transform: translateY(-50%) rotate(45deg);
}

.amb-faq details > div {
  padding: 0 56px 26px 0;
  color: var(--amb-muted);
  font-size: 17px;
}

/* CTA band */
.amb-cta {
  padding: clamp(40px, 5vw, 64px);
  border-radius: 28px;
  background:
    radial-gradient(70% 90% at 100% 0%, rgba(177, 150, 247, .5), transparent 70%),
    radial-gradient(60% 80% at 0% 100%, rgba(88, 254, 198, .35), transparent 70%),
    var(--amb-soft);
  text-align: center;
}

.amb-cta p {
  max-width: 680px;
  margin-right: auto;
  margin-left: auto;
}

@media only screen and (max-width: 999px) {
  .amb-split,
  .amb-sessions {
    grid-template-columns: 1fr;
  }

  .amb-goals {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media only screen and (max-width: 690px) {
  .amb-goals {
    grid-template-columns: 1fr;
  }
}

@media only screen and (max-width: 690px) {
  .amb-page {
    font-size: 17px;
  }

  .amb-wrap {
    padding: 0 20px;
  }

  .amb-steps > li {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .amb-steps > li::after {
    grid-row: 1;
    font-size: 44px;
  }

  .amb-btn {
    width: 100%;
  }

  .amb-session__actions {
    align-items: stretch;
  }

  .amb-stack .amb-btn {
    width: 100%;
  }

  .amb-faq details > div {
    padding-right: 0;
  }
}

/* ---------- Home: "Próxima sanación" cards use the content-page buttons ---------- */
#sanacion .wpb_wrapper > .nectar-button {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 50px;
  margin: 10px 0 0 !important;
  padding: 14px 20px !important;
  border: 1.5px solid var(--amb-ink) !important;
  border-radius: 200px !important;
  background: rgba(255, 255, 255, .35) !important;
  box-shadow: none !important;
  color: var(--amb-ink) !important;
  font-family: var(--amb-ui) !important;
  font-size: 15px !important;
  font-weight: 500 !important;
  line-height: 1.2 !important;
  text-transform: none !important;
  opacity: 1 !important;
  transition: background-color .2s ease, color .2s ease, transform .2s ease;
}

#sanacion .wpb_wrapper > .nectar-button.btn-hidden {
  display: none !important;
}

#sanacion .wpb_wrapper > .nectar-button span {
  color: inherit !important;
  font: inherit !important;
  text-transform: none !important;
  transform: none !important;
}

#sanacion .wpb_wrapper > .nectar-button::after {
  content: "→";
  position: static;
  display: inline;
  width: auto;
  height: auto;
  background: none;
  font-size: 1.1em;
  line-height: 1;
  opacity: 1;
  transform: none;
}

#sanacion .wpb_wrapper > .nectar-button:hover {
  background: var(--amb-ink) !important;
  color: #fff !important;
  transform: translateY(-1px);
}

/* ---------- Footer credit ---------- */
.amb-credit {
  display: inline-block;
  margin-bottom: 10px;
  vertical-align: baseline;
}

.amb-credit p {
  display: inline-flex;
  align-items: baseline;
  gap: 2px;
  margin: 0;
  padding: 0;
  color: var(--amb-ink);
  font-family: var(--amb-ui);
  /* Same sizing as the theme's footer links (.font_size_desktop_0-9vw). */
  font-size: 0.9vw;
  font-weight: 500;
  line-height: 1.1;
  white-space: nowrap;
}

.amb-credit a {
  color: inherit !important;
  text-decoration: none;
}

.amb-credit a:hover,
.amb-credit a:focus-visible {
  text-decoration: underline;
}

@media only screen and (max-width: 690px) {
  .amb-credit {
    display: block;
    margin-top: 16px;
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .amb-nav__link::after,
  .amb-btn,
  .amb-org,
  .amb-faq summary::after {
    transition: none;
  }
}
