/* The marketing pages (home, About, program landings, Emunah Study, ...).
   Separate from the study pages' Materialize styles. */
:root { --navy: #253551; }
* { box-sizing: border-box; }
body { margin: 0; font: 300 15.7px/1.6 Poppins, sans-serif; color: #000; background: #fff; }
a { color: var(--navy); }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: Jost, sans-serif; font-weight: 400; line-height: 1.25; margin: 1.2em 0 0.4em; }
h1 { font-size: 2.8rem; } h2 { font-size: 2.5rem; } h3 { font-size: 2rem; } h4 { font-size: 1.5rem; }
.center { text-align: center; } .right { text-align: right; }

.site-header { display: flex; align-items: center; gap: 1.5rem; padding: 1.8rem 4vw; }
.site-header a { color: #000; text-decoration: none; }
.logo { width: 141px; display: block; }
.site-header nav { display: flex; gap: 1.4rem; margin-left: auto; }
.site-header nav a[aria-current] { text-decoration: underline; text-underline-offset: 4px; }
.social { display: inline-flex; gap: 1.2rem; font-size: 1.3rem; }
.menu-button { display: none; position: relative; width: 47px; height: 37px; margin-left: auto; padding: 0; border: 0; background: none; }
.menu-button i { position: absolute; left: 6px; width: 35px; height: 1px; background: #000; transition: transform 0.2s, top 0.2s, width 0.2s, left 0.2s; }
.menu-button i:first-child { top: 12px; }
.menu-button i:last-child { top: 23px; }

main { max-width: 1000px; margin: 0 auto; padding: 1rem 5vw 4rem; }
main.wide { max-width: 1320px; }
.text > :first-child { margin-top: 0; }
.text { overflow-wrap: anywhere; } /* long URLs in descriptions */
hr { margin: 2.5rem 0; border: 0; border-top: 1px solid #808080; }
.button { display: inline-block; padding: 14px 23px; border: 2px solid var(--navy); background: var(--navy); color: #fff; font-size: 12.3px; text-decoration: none; }
.button:hover { background: #fff; color: var(--navy); }
.video { position: relative; padding-bottom: 56.25%; margin: 1.5rem 0; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.image { margin: 1.5rem 0; text-align: center; }
.image img { max-width: min(100%, 320px); }
.image figcaption { margin-top: 0.5rem; }

.program { display: flex; flex-direction: column; align-items: center; gap: 1rem; margin: 1.5rem 0; }
.program img { width: 100%; max-width: 330px; }
/* Home logo: the SVG and its animation are inline in marketing/logo.svg.html. */
.logo-draw { width: 100%; max-width: 330px; }
.logo-draw svg { display: block; }
@media (prefers-reduced-motion: reduce) { .logo-draw path, .logo-draw polygon { animation: none; } }

.podcasts { display: flex; justify-content: space-around; width: min(100%, 260px); font-size: 28px; }
.podcasts a { color: #000; }
/* Home rows: the icons, the logo and the button side by side */
.program.row { display: grid; grid-template-columns: 1fr minmax(0, 330px) 1fr; align-items: center; gap: 1.5rem; }
.program.row .podcasts { grid-area: 1 / 1; width: auto; }
.program.row img { grid-area: 1 / 2; }
.program.row .button { grid-area: 1 / 3; justify-self: end; }

.cards { display: grid; gap: 2rem; margin: 2rem 0; }
.card { display: grid; grid-template-columns: 2fr 3fr; gap: 2rem; align-items: center; color: inherit; text-decoration: none; }
.card img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.card h3 { margin-top: 0; font-size: 1.8rem; }
.columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2rem; margin: 2rem 0; text-align: center; }
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin: 2rem 0; }

.form { max-width: 560px; margin: 2rem 0; }
.form label, .form legend { display: block; margin-bottom: 1.5rem; }
.form small { color: #666; }
.form input[type=text], .form input[type=email], .form textarea { display: block; width: 100%; padding: 0.6rem 0; border: 0; border-bottom: 1px solid #000; font: inherit; }
.form .button { background: none; color: var(--navy); font: 500 15px "Inter Tight", sans-serif; }
.form .button:hover { background: var(--navy); color: #fff; }
.form.centered .button { display: block; margin: 0 auto; }
.form fieldset { margin: 0 0 1.5rem; padding: 0; border: 0; }
.form .check { display: block; margin-bottom: 0.4rem; }
.embed { display: block; width: 100%; border: 0; }
.donorbox { display: block; width: 100%; max-width: 500px; min-width: 250px; margin: 0 auto; border: 0; }

.pager { display: flex; justify-content: space-between; margin-top: 3rem; font: 1.4rem Jost, sans-serif; }
.pager a { color: #000; text-decoration: none; }

.site-footer { display: grid; grid-template-columns: 2fr 1fr; gap: 2rem; padding: 3rem 4vw; background: var(--navy); color: #fff; font-size: 12.3px; }
.site-footer h2 { margin: 0 0 0.5rem; font-size: 1.5rem; }
.site-footer a { color: #fff; }
.site-footer ul { margin: 1rem 0 0; padding: 0; list-style: none; }

@media (max-width: 767px) {
  .menu-button { display: block; }
  .site-header { padding: 6vw; }
  .logo { width: 94px; }
  .site-header nav { display: none; }
  /* The open menu fills the screen: black, links centred, social icons at the bottom. */
  .site-header.open { position: fixed; inset: 0; z-index: 100; align-items: flex-start; background: #000; }
  .site-header.open nav { display: flex; position: absolute; inset: 0; flex-direction: column; align-items: center; justify-content: center; gap: 0; margin: 0; padding-top: 18px; }
  .site-header.open nav a[aria-current] { text-decoration: none; }
  .site-header.open nav a { padding: 11.65px 0; color: #fff; font-size: 33px; font-weight: 300; line-height: 33px; }
  .site-header.open .social { position: absolute; bottom: 38px; left: 50%; transform: translateX(-50%); gap: 15px; font-size: 20px; }
  .site-header.open .social a { display: flex; align-items: center; justify-content: center; width: 25px; height: 25px; padding: 0; font-size: 20px; line-height: 1; }
  .site-header.open .menu-button { position: relative; z-index: 1; margin-top: 6.5px; }
  .site-header.open .menu-button i { left: 9px; width: 28px; top: 18px; background: #fff; }
  .site-header.open .menu-button i:first-child { transform: rotate(45deg); }
  .site-header.open .menu-button i:last-child { transform: rotate(-45deg); }
  body:has(.site-header.open) { overflow: hidden; }
  .program.row { display: flex; flex-direction: column; }
  .program.row .podcasts { order: -1; width: 100%; }
  .card { grid-template-columns: 1fr; gap: 0.8rem; }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .site-footer { grid-template-columns: 1fr; }
}
