/* Seven Locks: keep the completion action inside short mobile viewports.
   The backdrop becomes safely scrollable only when needed; the ceremony itself
   is compacted so it normally fits without hiding the primary action. */
@media (max-width: 620px) {
  .weekly-lock-ceremony-backdrop {
    align-items: start;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding: max(8px, env(safe-area-inset-top)) 10px max(18px, env(safe-area-inset-bottom));
  }

  .weekly-lock-ceremony {
    box-sizing: border-box;
    width: min(100%, 420px);
    margin: auto;
    padding: 18px 13px 16px;
    border-radius: 22px;
  }

  .weekly-lock-ceremony .rank-ceremony-close {
    top: 10px;
    right: 10px;
    width: 34px;
    height: 34px;
  }

  .weekly-lock-ceremony .rank-ceremony-eyebrow {
    margin: 2px 38px 5px;
    font-size: 9px;
  }

  .weekly-lock-ceremony h1 {
    margin: 4px 35px 7px;
    font-size: clamp(1.55rem, 7.4vw, 2rem);
    line-height: .98;
  }

  .weekly-lock-ceremony-copy {
    max-width: 330px;
    font-size: .88rem;
    line-height: 1.36;
  }

  .weekly-lock-chest {
    width: min(83vw, 360px);
    margin: 12px auto 7px;
  }

  .weekly-lock-ceremony-progress {
    gap: 8px;
    padding: 10px 11px;
    font-size: .8rem;
  }

  .weekly-lock-ceremony-progress span {
    gap: 6px;
  }

  .weekly-lock-ceremony-progress b {
    font-size: .66rem;
  }

  .weekly-lock-ceremony-next {
    max-width: 320px;
    margin: 10px auto 12px;
    font-size: .82rem;
    line-height: 1.35;
  }

  .weekly-lock-ceremony-continue {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    min-height: 48px;
    margin-bottom: 0;
  }
}

@media (max-width: 380px), (max-height: 690px) {
  .weekly-lock-ceremony {
    padding-top: 14px;
    padding-bottom: 13px;
  }

  .weekly-lock-ceremony h1 {
    font-size: 1.48rem;
  }

  .weekly-lock-chest {
    width: min(79vw, 330px);
    margin-top: 9px;
  }

  .weekly-lock-ceremony-next {
    margin-top: 8px;
    margin-bottom: 10px;
  }
}
