/*
Theme Name: Right Brain Roots
Theme URI: https://rightbrainroots.org/
Description: Lightweight, accessible block theme for Right Brain Roots.
Version: 0.1.0
Requires at least: 6.5
Requires PHP: 8.0
Text Domain: rightbrainroots
*/

:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 3px;
}

html {
  scroll-behavior: smooth;
}

body {
  background: #fffdf8;
  color: #17191a;
}

.rbr-header,
header > .wp-block-group {
  border-bottom: 3px solid #17191a;
}

.rbr-header__inner,
.rbr-footer__inner,
.rbr-container {
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

.rbr-header__inner,
.rbr-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding-block: 0.85rem;
}

.rbr-brand img {
  display: block;
  width: 7.25rem;
  height: auto;
}

.rbr-navigation {
  max-width: 100%;
}

.rbr-navigation__menu {
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rbr-navigation a {
  color: inherit;
  font-weight: 800;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.22em;
}

.rbr-header .wp-block-image img {
  width: min(12rem, 42vw);
  height: auto;
}

.rbr-header .wp-block-site-title a {
  color: inherit;
  text-decoration: none;
}

.rbr-header .wp-block-navigation a {
  font-weight: 750;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.22em;
}

.rbr-hero,
main > .wp-block-group:first-child {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding-top: clamp(3rem, 8vw, 7rem);
  padding-bottom: clamp(3rem, 8vw, 7rem);
  background: linear-gradient(120deg, #b6ddf3 0%, #72c9cc 38%, #f7ae7b 75%, #f4cf57 100%) !important;
}

.rbr-hero::before,
.rbr-hero::after,
main > .wp-block-group:first-child::before,
main > .wp-block-group:first-child::after {
  position: absolute;
  z-index: -1;
  width: 18rem;
  height: 18rem;
  content: "";
  border: 3px solid #17191a;
  border-radius: 48% 52% 40% 60%;
  opacity: 0.15;
}

.rbr-hero::before,
main > .wp-block-group:first-child::before {
  top: -7rem;
  right: -5rem;
  background: #f36e70;
}

.rbr-hero::after,
main > .wp-block-group:first-child::after {
  bottom: -9rem;
  left: -5rem;
  background: #8ccb72;
}

.rbr-eyebrow {
  margin-bottom: 0.35rem;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.rbr-hero h1,
.rbr-section-heading h2,
.rbr-callout h2 {
  font-weight: 850;
  letter-spacing: -0.04em;
  line-height: 0.98;
}

.rbr-hero h1 {
  max-width: 9ch;
  font-size: clamp(3.25rem, 8vw, 6.75rem);
}

.rbr-hero__content {
  max-width: 900px;
}

.rbr-hero-copy {
  max-width: 39rem;
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  font-weight: 600;
}

.rbr-button .wp-block-button__link {
  padding: 0.78rem 1.15rem;
  border: 2px solid #17191a;
  border-radius: 999px;
  box-shadow: 4px 4px 0 #17191a;
  font-weight: 800;
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.rbr-button .wp-block-button__link:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 #17191a;
}

.rbr-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

.rbr-link-button {
  display: inline-block;
  padding: 0.78rem 1.15rem;
  border: 2px solid #17191a;
  border-radius: 999px;
  box-shadow: 4px 4px 0 #17191a;
  font-weight: 800;
  text-decoration: none;
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.rbr-link-button:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 #17191a;
}

.rbr-link-button--dark { background: #17191a; color: #fffdf8; }
.rbr-link-button--light { background: #fffdf8; color: #17191a; }

.rbr-section,
main > section {
  padding-top: clamp(3.5rem, 8vw, 6.5rem);
  padding-bottom: clamp(3.5rem, 8vw, 6.5rem);
}

.rbr-section-heading,
#programs > .wp-block-group:first-child {
  max-width: 42rem;
}

.rbr-section-heading h2,
#programs > .wp-block-group:first-child h2 {
  font-size: clamp(2.35rem, 5vw, 4rem);
}

.rbr-program-grid,
#programs > .wp-block-columns {
  margin-top: 2.25rem;
}

.rbr-card,
#programs > .wp-block-columns > .wp-block-column > .wp-block-group {
  height: 100%;
  padding: clamp(1.35rem, 3vw, 2.1rem);
  border: 3px solid #17191a;
  border-radius: 1.25rem;
  box-shadow: 7px 7px 0 #17191a;
}

.rbr-card h3,
#programs > .wp-block-columns h3 {
  font-size: 1.45rem;
  font-weight: 850;
}

.rbr-card p,
#programs > .wp-block-columns .wp-block-group p {
  margin-bottom: 0;
}

.rbr-card--aqua,
#programs > .wp-block-columns > .wp-block-column:nth-child(1) > .wp-block-group { background: #b6ddf3; }
.rbr-card--coral,
#programs > .wp-block-columns > .wp-block-column:nth-child(2) > .wp-block-group { background: #f7ae7b; }
.rbr-card--leaf,
#programs > .wp-block-columns > .wp-block-column:nth-child(3) > .wp-block-group { background: #bfe3a8; }

.rbr-story,
#our-approach {
  background: #17191a;
  color: #fffdf8;
}

.rbr-story .wp-block-pullquote {
  max-width: 54rem;
  border: 0;
  font-size: clamp(1.65rem, 3.5vw, 2.7rem);
  font-weight: 750;
  line-height: 1.14;
}

.rbr-callout,
#get-involved > .wp-block-group {
  border: 3px solid #17191a;
  border-radius: 1.5rem;
  background: #f4cf57;
  box-shadow: 8px 8px 0 #17191a;
}

.rbr-footer {
  border-top: 3px solid #17191a;
}

.rbr-footer p {
  margin: 0;
  font-size: 0.9rem;
}

.rbr-blog {
  min-height: 70vh;
  background: linear-gradient(180deg, #fffdf8 0%, #edf9f8 100%);
}

.rbr-blog__header {
  max-width: 42rem;
  margin-bottom: 3.5rem;
}

.rbr-blog__header h1 {
  margin-block: 0.25rem 1rem;
  font-size: clamp(3rem, 7vw, 5.75rem);
  font-weight: 850;
  letter-spacing: -0.05em;
  line-height: 0.95;
}

.rbr-blog__header > p:last-child {
  font-size: 1.2rem;
  font-weight: 600;
}

.rbr-post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
}

.rbr-post-card,
.rbr-empty-state {
  padding: clamp(1.35rem, 3vw, 2rem);
  border: 3px solid #17191a;
  border-radius: 1.25rem;
  background: #fffdf8;
  box-shadow: 6px 6px 0 #17191a;
}

.rbr-post-card:nth-child(3n + 1) { background: #b6ddf3; }
.rbr-post-card:nth-child(3n + 2) { background: #f7ae7b; }
.rbr-post-card:nth-child(3n + 3) { background: #bfe3a8; }

.rbr-post-card__date {
  margin: 0 0 1rem;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.rbr-post-card h2 {
  margin: 0 0 0.85rem;
  font-size: 1.65rem;
  font-weight: 850;
  line-height: 1.05;
}

.rbr-post-card h2 a,
.rbr-text-link {
  color: inherit;
}

.rbr-text-link {
  font-weight: 800;
  text-underline-offset: 0.2em;
}

.rbr-empty-state {
  max-width: 40rem;
  background: #f4cf57;
}

@media (max-width: 800px) {
  .rbr-post-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .rbr-header__inner,
  .rbr-footer__inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .rbr-header .wp-block-group {
    align-items: flex-start;
  }

  .rbr-card {
    box-shadow: 5px 5px 0 #17191a;
  }
}
