/* Making Christmas a Little Brighter: page-specific layout fixes.
   Loaded after the theme CSS so these rules win. */

/* Campaign image: shrink to fit narrow screens, never stretch past 600px. */
.campaign-image {
  display: block;
  width: 100%;
  max-width: 600px;
  height: auto;
  margin: 1.5rem auto;
}

/* Microsoft Forms embed: full width up to 640px, tall enough to fill most of
   the screen so people aren't scrolling inside a small box. */
.campaign-form {
  display: block;
  width: 100%;
  max-width: 640px;
  height: 80vh;
  min-height: 520px;
  max-height: 900px;
  margin: 0 auto 2rem;
  border: 0;
}

/* Tablets: the theme's 70px title wraps to three lines and only just fits. */
@media (min-width: 768px) and (max-width: 1199px) {
  .banner .banner-wrap .banner-caption h1 {
    font-size: 52px;
  }
}

@media (max-width: 767px) {
  /* Shorter banner with the title centred and sized to fit, instead of a
     50px title that wraps to four lines and runs off the bottom. */
  .banner .banner-wrap {
    height: 200px;
  }
  .banner .banner-wrap .banner-caption {
    top: 50%;
    transform: translateY(-50%);
  }
  .banner .banner-wrap .banner-caption h1 {
    width: 92%;
    margin: 0 auto;
    font-size: 32px;
    line-height: 1.15;
  }

  /* Long paragraphs are easier to read left-aligned on a phone. */
  .campaign-intro p {
    text-align: left;
  }

  /* Terms button: full width, and allowed to wrap. */
  .campaign-terms .btn {
    display: block;
    width: 100%;
    white-space: normal;
  }
}
