/* desktop.css — Mon 19 Oct desktop pass (Sanjana): DT-01 hero, DT-02 plans, DT-03 footer.
   Loaded last. Every rule is inside min-width 769px, so the phone layout (mobile.css) cannot change. */

/* ---------- DT-01: hero at 1280 / 1440 ---------- */
@media (min-width: 1024px) {
  /* the subheading was boxed at 480px, so at 1440 (23px type) it broke into three lines with
     "80%." left on its own; give it room for two balanced lines */
  .hero .hero__sub,
  #page-home .hero__sub {
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
    text-wrap: balance;
  }
  .hero h1 {
    text-wrap: balance;
  }
  /* 23 Oct: "Trade options with our capital." is a 31-character first line. In the 980px copy column
     at 78px it broke after "options", making a three-line headline; widen the column and cap the type
     at 74px so the headline is two lines (one per sentence) from 1024 up to 1920. */
  .hero__copy {
    max-width: 1240px;
  }
  .hero h1 {
    font-size: clamp(42px, 5.6vw, 74px);
  }
}

/* ---------- DT-02: plans, four across (one per plan) with the 50K highlighted ---------- */
@media (min-width: 769px) {
  /* the "Most popular" badge is meant to sit on the card's top edge (styles.css), but a later
     `position: relative` pulled it into the card as a full-width row, pushing the 50K price and
     every line under it ~14px below the other three cards. Put it back on the edge. */
  .plans .plan .plan__tag {
    position: absolute !important;
    top: -13px;
    left: 50%;
    transform: translateX(-50%);
    width: auto;
    display: inline-flex;
    white-space: nowrap;
    z-index: 2;
  }
  .plans {
    grid-template-columns: repeat(4, minmax(0, 1fr)); /* columns never grow past the container */
    align-items: stretch;
    padding-top: 14px; /* room for the badge above the tallest card */
  }
  .plans .plan {
    display: flex;
    flex-direction: column;
  }
  /* "Start for $…" buttons line up along one bottom edge whatever the copy length */
  .plans .plan > a.btn,
  .plans .plan > .btn {
    margin-top: auto;
  }
  .plans .plan dl {
    margin-bottom: 18px;
  }
}

/* ---------- DT-03: footer columns ---------- */
@media (min-width: 1101px) {
  /* columns now take the width of their content and share the leftover space evenly, instead
     of fixed fractions: the e-mail no longer breaks mid-word, "Accounts & pricing" stays on one
     line and the address keeps its three lines */
  .foot__cols {
    grid-template-columns: repeat(6, auto);
    justify-content: space-between;
    column-gap: 28px;
  }
  .foot__cols > div {
    min-width: 0;
  }
  .foot ul a,
  .foot ul li {
    white-space: nowrap;
  }
  .foot ul a[href^='mailto:'] {
    overflow-wrap: normal;
    word-break: normal;
  }
}
/* the address keeps its three lines where there is room; between 1101 and 1280 it may wrap */
@media (min-width: 1281px) {
  .foot__cols > div:last-child p {
    white-space: nowrap;
  }
}
/* 1101–1250: the three-column layout styles.css already uses below 1100 */
@media (min-width: 1101px) and (max-width: 1250px) {
  .foot__cols {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    justify-content: stretch;
    gap: 36px 24px;
  }
}
/* 1251–1400: six columns do not fit without overlap, so the "Get started" buttons take their own
   row across the top and the five link columns sit below */
@media (min-width: 1251px) and (max-width: 1400px) {
  .foot__cols {
    grid-template-columns: repeat(5, auto);
    row-gap: 36px;
  }
  .foot__cols > div:first-child {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
  }
  .foot__cols > div:first-child h5 {
    width: 100%;
    margin-bottom: 4px;
  }
  .foot__cols > div:first-child .foot__cta {
    margin: 0;
  }
}
